Skillpedia
الأمان84k · #1420

omni-auth

ما الذي تفعله

تُظهر هذه المهارة كيف تصادق على واجهة OmniRoute البرمجية ولوحة التحكم. وهي للمطورين والمسؤولين الذين يحتاجون إلى تسجيل الدخول أو الحصول على جلسة أو ضبط خيارات الدخول.

متى تستخدمها

  • ✓عندما يحتاج أحد إلى مصادقة طلب برمز bearer.
  • ✓عندما يحتاج أحد إلى تسجيل الدخول إلى لوحة OmniRoute أو الحصول على كوكي جلسة.
  • ✓عندما يريد أحد إعداد تسجيل دخول موحد أو تغيير متطلبات الدخول.

رابط المهارة

https://github.com/cheaper-inference/OmniRoute/blob/release/v3.8.53/skills/omni-auth/SKILL.md

انسخه والصقه في الذكاء الاصطناعي الذي تستخدمه (Claude أو ChatGPT أو Cursor) واطلب منه اتباع التعليمات.

طريقة الاستخدام

أسهل طريقة: انسخ الرسالة والصقها في الذكاء الاصطناعي الذي تستخدمه. سيقرأ المهارة وينفّذ تعليماتها.

رسالة جاهزة للصق

استخدم هذه المهارة لمساعدتي: https://github.com/cheaper-inference/OmniRoute/blob/release/v3.8.53/skills/omni-auth/SKILL.md اقرأ ملف SKILL.md في هذا الرابط ونفّذ تعليماته لمهمتي.
تريد أن يجد الذكاء الاصطناعي مهارات مثل هذه بنفسه؟ثبّت خادم Skillpedia MCP المجاني: سطر واحد، ويبحث في 15,000+ مهارة قبل كل مهمة.ثبّته في دقيقة واحدة →

مثال على ما تطلبه من الذكاء الاصطناعي

“كيف أسجّل الدخول إلى OmniRoute من سكربتي للحصول على رمز الوصول؟”

5 مهارات جديدة كل أسبوع. قراءة في دقيقة واحدة.

كيف تعمل

تسرد المهارة نقطة تسجيل الدخول، التي تقبل كلمة مرور الإدارة وتعيد كوكي جلسة، ونقطة تسجيل الخروج، التي تحتاج إلى رمز أمان. وتصف أيضًا خيار تسجيل دخول موحد للوحة.

المحتوى التقني (ملف SKILL.md الأصلي)

النص الأصلي من المؤلف، مباشرة من GitHub.

<!-- generated by src/lib/agentSkills/generator.ts; manual edits will be overwritten -->

Overview

Manage API key authentication and session tokens. Start here to authenticate requests via Bearer token, obtain session cookies, and configure login requirements for the OmniRoute API.

Authentication

Remote API requests use a Bearer credential. Dashboard login is different: POST /api/auth/login accepts a management password and returns an auth_token session cookie.

Endpoints

POST /api/auth/login

Authenticate user

curl -X POST http://localhost:20128/api/auth/login \
  -H "Content-Type: application/json" \
  -c cookie.jar \
  -d '{"password":"<management-password>"}'

POST /api/auth/logout

Log out

CSRF_TOKEN=$(curl -s http://localhost:20128/api/auth/csrf -b cookie.jar | jq -r .token)
curl -X POST http://localhost:20128/api/auth/logout \
  -b cookie.jar \
  -H "x-omniroute-csrf: $CSRF_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{}'

GET /api/auth/oidc/login

Start OIDC login for the dashboard admin gate

Builds an authorization URL from the configured OIDC issuer/client (discovered via {issuer}/.well-known/openid-configuration, falling back to {issuer}/authorize), sets a short-lived oidc_state cookie, and redirects the browser. Password login remains available as a fallback while OIDC is enabled.

curl http://localhost:20128/api/auth/oidc/login \
  -b cookie.jar

GET /api/auth/oidc/callback

Complete OIDC login for the dashboard admin gate

Validates the state cookie, exchanges the authorization code for tokens, verifies the ID token against the issuer's JWKS (audience = client id), and requires at least one dashboard admission policy: oidcAllowedSubjects (matching sub or verified email) or oidcAdmissionClaim (matching a configured array claim in the verified ID token). When both are present, both must match. Without either policy the callback returns not_configured. On success it mints the same 30-day auth_token dashboard-session JWT used by password login and redirects to /dashboard.

curl http://localhost:20128/api/auth/oidc/callback \
  -b cookie.jar

GET /api/auth/csrf

GET auth › csrf

curl http://localhost:20128/api/auth/csrf \
  -b cookie.jar

GET /api/auth/status

GET auth › status

curl http://localhost:20128/api/auth/status \
  -b cookie.jar

Payloads

See the full OpenAPI specification at GET /api/openapi/spec or docs/openapi.yaml for detailed request/response schemas.

<!-- skill:custom-start --> <!-- Migrated from skills/omniroute/SKILL.md (preserved curated content) -->

OmniRoute

Local/remote AI gateway exposing OpenAI-compatible REST. One key, 380 providers, auto-fallback, RTK token saver, MCP server, A2A agents.

Setup

export OMNIROUTE_URL="http://localhost:20128"      # or VPS / tunnel URL
export OMNIROUTE_KEY="sk-..."                       # from Dashboard → API Keys

All requests: ${OMNIROUTE_URL}/v1/... with Authorization: Bearer ${OMNIROUTE_KEY}.

Verify: curl $OMNIROUTE_URL/api/health → {"ok":true}

Discover models

curl $OMNIROUTE_URL/v1/models                  # chat/LLM (default)
curl $OMNIROUTE_URL/v1/models/image            # image-gen
curl $OMNIROUTE_URL/v1/models/tts              # text-to-speech
curl $OMNIROUTE_URL/v1/models/embedding        # embeddings
curl $OMNIROUTE_URL/v1/models/web              # web search + fetch
curl $OMNIROUTE_URL/v1/models/stt              # speech-to-text

Use data[].id as model field in requests. Combos appear with owned_by:"combo".

Capability skills

Capability Raw URL
Chat / code-gen https://raw.githubusercontent.com/diegosouzapw/OmniRoute/main/skills/omni-inference/SKILL.md
Image generation https://raw.githubusercontent.com/diegosouzapw/OmniRoute/main/skills/omni-inference/SKILL.md
Text-to-speech https://raw.githubusercontent.com/diegosouzapw/OmniRoute/main/skills/omni-inference/SKILL.md
Speech-to-text https://raw.githubusercontent.com/diegosouzapw/OmniRoute/main/skills/omni-inference/SKILL.md
Embeddings https://raw.githubuserconten
الأسئلة الشائعة

ما الفرق بين رمز bearer وتسجيل الدخول إلى اللوحة؟

تستخدم الطلبات البعيدة للواجهة البرمجية بيانات اعتماد من نوع bearer، بينما يستخدم تسجيل الدخول إلى اللوحة كلمة مرور الإدارة، وتعيد كوكي جلسة.

هل تدعم تسجيل الدخول الموحد؟

نعم. تصف المهارة تسجيل دخول OIDC للوحة، ويبقى تسجيل الدخول بكلمة المرور كخيار احتياطي.

هل أستطيع تجاوز تسجيل الدخول في التطوير المحلي؟

تقول المهارة إن شرط المفتاح يمكن إيقافه في بيئة التطوير المحلية.

التفاصيل

الوصف الأصلي من المؤلف

Manage API key authentication and session tokens. Start here to authenticate requests via Bearer token, obtain session cookies, and configure login requirements for the OmniRoute API.

repo: cheaper-inference/OmniRoute

الشعبية

نجوم GitHub
84k
الترتيب
#1420
الترخيص
MIT
آخر تحديث
2‏/11‏/2026

هل هذه المهارة مفيدة؟

0

سجّل الدخول للتصويت.

التعليقات

  • …

المزيد من المهارات من هذا المستودع

مهارات مشابهة