9router-proxy 0.6.12 → 0.6.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/app/.next-cli-build/BUILD_ID +1 -1
- package/app/.next-cli-build/app-path-routes-manifest.json +11 -10
- package/app/.next-cli-build/build-manifest.json +3 -3
- package/app/.next-cli-build/prerender-manifest.json +5 -5
- package/app/.next-cli-build/react-loadable-manifest.json +13 -13
- package/app/.next-cli-build/required-server-files.json +2 -1
- package/app/.next-cli-build/routes-manifest.json +6 -0
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page.js +23 -23
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page.js +2 -2
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page.js +2 -2
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/_global-error/page.js +2 -2
- package/app/.next-cli-build/server/app/_global-error/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/_global-error/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/_global-error.html +1 -1
- package/app/.next-cli-build/server/app/_global-error.rsc +1 -1
- package/app/.next-cli-build/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/_not-found/page.js +1 -1
- package/app/.next-cli-build/server/app/_not-found/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/_not-found.html +1 -1
- package/app/.next-cli-build/server/app/_not-found.rsc +5 -5
- package/app/.next-cli-build/server/app/_not-found.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/_not-found.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/api/auth/login/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/login/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/logout/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/logout/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/oidc/callback/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/oidc/callback/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/oidc/start/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/oidc/start/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/oidc/test/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/oidc/test/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/reset-password/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/reset-password/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/saml/acs/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/saml/acs/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/saml/metadata/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/saml/metadata/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/saml/start/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/saml/start/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/saml/test/route.js +2 -2
- package/app/.next-cli-build/server/app/api/auth/saml/test/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/auth/status/route.js +1 -1
- package/app/.next-cli-build/server/app/api/auth/status/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/all-statuses/route.js +5 -5
- package/app/.next-cli-build/server/app/api/cli-tools/all-statuses/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/alias/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/alias/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/route.js +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/claude-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/claude-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/cline-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/cline-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/codewhale-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/codewhale-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/codex-profiles/route.js +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/codex-profiles/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/codex-settings/route.js +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/codex-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/copilot-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/copilot-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-registry/route.js +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-registry/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-tools/route.js +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-tools/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/cowork-settings/route.js +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/cowork-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/crush-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/crush-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/deepseek-tui-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/deepseek-tui-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/devin-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/devin-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/droid-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/droid-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/forge-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/forge-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/grok-build-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/grok-build-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/hermes-profiles/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/hermes-profiles/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/hermes-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/hermes-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/jcode-settings/route.js +3 -3
- package/app/.next-cli-build/server/app/api/cli-tools/jcode-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/kilo-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/kilo-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/omp-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/omp-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/openclaw-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/openclaw-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/opencode-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/opencode-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/pi-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/pi-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/cli-tools/smelt-settings/route.js +2 -2
- package/app/.next-cli-build/server/app/api/cli-tools/smelt-settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/combos/[id]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/combos/[id]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/combos/presets/route.js +1 -1
- package/app/.next-cli-build/server/app/api/combos/presets/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/combos/route.js +1 -1
- package/app/.next-cli-build/server/app/api/combos/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/headroom/extras/route.js +1 -1
- package/app/.next-cli-build/server/app/api/headroom/extras/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/headroom/proxy/[...path]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/headroom/proxy/[...path]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/headroom/restart/route.js +1 -1
- package/app/.next-cli-build/server/app/api/headroom/restart/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/headroom/start/route.js +1 -1
- package/app/.next-cli-build/server/app/api/headroom/start/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/headroom/status/route.js +1 -1
- package/app/.next-cli-build/server/app/api/headroom/status/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/headroom/stop/route.js +1 -1
- package/app/.next-cli-build/server/app/api/headroom/stop/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/health/route.js +1 -1
- package/app/.next-cli-build/server/app/api/health/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/init/route.js +1 -1
- package/app/.next-cli-build/server/app/api/init/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/keys/[id]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/keys/[id]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/keys/route.js +1 -1
- package/app/.next-cli-build/server/app/api/keys/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/locale/route.js +1 -1
- package/app/.next-cli-build/server/app/api/locale/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/mcp/[plugin]/message/route.js +2 -2
- package/app/.next-cli-build/server/app/api/mcp/[plugin]/message/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/mcp/[plugin]/sse/route.js +2 -2
- package/app/.next-cli-build/server/app/api/mcp/[plugin]/sse/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/deepgram/voices/route.js +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/deepgram/voices/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/elevenlabs/voices/route.js +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/elevenlabs/voices/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/inworld/voices/route.js +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/inworld/voices/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/minimax/voices/route.js +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/minimax/voices/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/voices/route.js +1 -1
- package/app/.next-cli-build/server/app/api/media-providers/tts/voices/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/models/alias/route.js +1 -1
- package/app/.next-cli-build/server/app/api/models/alias/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/models/availability/route.js +1 -1
- package/app/.next-cli-build/server/app/api/models/availability/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/models/catalog-sync/route.js +1 -1
- package/app/.next-cli-build/server/app/api/models/catalog-sync/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/models/custom/route.js +1 -1
- package/app/.next-cli-build/server/app/api/models/custom/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/models/disabled/route.js +1 -1
- package/app/.next-cli-build/server/app/api/models/disabled/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/models/route.js +1 -1
- package/app/.next-cli-build/server/app/api/models/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/models/test/route.js +1 -1
- package/app/.next-cli-build/server/app/api/models/test/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/[provider]/[action]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/[provider]/[action]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/codex/bulk-import/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/codex/bulk-import/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/codex/import-token/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/codex/import-token/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/cursor/auto-import/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/cursor/auto-import/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/cursor/import/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/cursor/import/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/gitlab/pat/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/gitlab/pat/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/iflow/cookie/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/iflow/cookie/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/api-key/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/api-key/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/auto-import/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/auto-import/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/import/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/import/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/import-cli-proxy/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/import-cli-proxy/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/social-authorize/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/social-authorize/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/social-exchange/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/kiro/social-exchange/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/api-key/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/api-key/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/auto-import/route.js +2 -2
- package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/auto-import/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/login/start/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/login/start/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/login/status/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/login/status/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/zed/auto-import/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/zed/auto-import/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/oauth/zed/import/route.js +1 -1
- package/app/.next-cli-build/server/app/api/oauth/zed/import/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/pricing/route.js +1 -1
- package/app/.next-cli-build/server/app/api/pricing/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/provider-nodes/[id]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/provider-nodes/[id]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/provider-nodes/route.js +1 -1
- package/app/.next-cli-build/server/app/api/provider-nodes/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/provider-nodes/validate/route.js +1 -1
- package/app/.next-cli-build/server/app/api/provider-nodes/validate/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/models/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/models/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/overrides/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/overrides/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/test/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/test/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/test-models/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/test-models/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/client/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/client/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/kilo/free-models/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/kilo/free-models/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/suggested-models/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/suggested-models/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/test-batch/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/test-batch/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/validate/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/validate/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/providers/web-login/route.js +1 -0
- package/app/.next-cli-build/server/app/api/providers/web-login/route.js.nft.json +1 -0
- package/app/.next-cli-build/server/app/api/providers/web-login/route_client-reference-manifest.js +1 -0
- package/app/.next-cli-build/server/app/api/proxy-pools/[id]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/[id]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/[id]/test/route.js +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/[id]/test/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/cloudflare-deploy/route.js +2 -2
- package/app/.next-cli-build/server/app/api/proxy-pools/cloudflare-deploy/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/deno-deploy/route.js +2 -2
- package/app/.next-cli-build/server/app/api/proxy-pools/deno-deploy/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/netlify-deploy/route.js +2 -2
- package/app/.next-cli-build/server/app/api/proxy-pools/netlify-deploy/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/route.js +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/vercel-deploy/route.js +1 -1
- package/app/.next-cli-build/server/app/api/proxy-pools/vercel-deploy/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/pxpipe/health/route.js +2 -2
- package/app/.next-cli-build/server/app/api/pxpipe/health/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/pxpipe/install/route.js +2 -2
- package/app/.next-cli-build/server/app/api/pxpipe/install/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/pxpipe/logs/route.js +2 -2
- package/app/.next-cli-build/server/app/api/pxpipe/logs/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/pxpipe/restart/route.js +2 -2
- package/app/.next-cli-build/server/app/api/pxpipe/restart/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/pxpipe/start/route.js +2 -2
- package/app/.next-cli-build/server/app/api/pxpipe/start/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/pxpipe/stats/route.js +2 -2
- package/app/.next-cli-build/server/app/api/pxpipe/stats/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/pxpipe/status/route.js +2 -2
- package/app/.next-cli-build/server/app/api/pxpipe/status/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/pxpipe/stop/route.js +2 -2
- package/app/.next-cli-build/server/app/api/pxpipe/stop/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/settings/database/route.js +1 -1
- package/app/.next-cli-build/server/app/api/settings/database/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/settings/proxy-test/route.js +1 -1
- package/app/.next-cli-build/server/app/api/settings/proxy-test/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/settings/require-login/route.js +1 -1
- package/app/.next-cli-build/server/app/api/settings/require-login/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/settings/route.js +1 -1
- package/app/.next-cli-build/server/app/api/settings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/shutdown/route.js +1 -1
- package/app/.next-cli-build/server/app/api/shutdown/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/tags/route.js +1 -1
- package/app/.next-cli-build/server/app/api/tags/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/translator/console-logs/route.js +1 -1
- package/app/.next-cli-build/server/app/api/translator/console-logs/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/translator/console-logs/stream/route.js +2 -2
- package/app/.next-cli-build/server/app/api/translator/console-logs/stream/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/translator/load/route.js +1 -1
- package/app/.next-cli-build/server/app/api/translator/load/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/translator/save/route.js +1 -1
- package/app/.next-cli-build/server/app/api/translator/save/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/translator/send/route.js +1 -1
- package/app/.next-cli-build/server/app/api/translator/send/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/translator/translate/route.js +1 -1
- package/app/.next-cli-build/server/app/api/translator/translate/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/disable/route.js +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/disable/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/enable/route.js +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/enable/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/status/route.js +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/status/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/tailscale-check/route.js +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/tailscale-check/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/tailscale-disable/route.js +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/tailscale-disable/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/tailscale-enable/route.js +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/tailscale-enable/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/tunnel/tailscale-install/route.js +2 -2
- package/app/.next-cli-build/server/app/api/tunnel/tailscale-install/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/[connectionId]/claude-reset/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/[connectionId]/claude-reset/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/[connectionId]/codex-reset-credits/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/[connectionId]/codex-reset-credits/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/[connectionId]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/[connectionId]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/chart/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/chart/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/history/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/history/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/logs/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/logs/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/providers/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/providers/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/request-details/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/request-details/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/request-logs/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/request-logs/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/stats/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/stats/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/usage/stream/route.js +1 -1
- package/app/.next-cli-build/server/app/api/usage/stream/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/api/chat/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/api/chat/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/audio/speech/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/audio/speech/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/audio/transcriptions/route.js +7 -1
- package/app/.next-cli-build/server/app/api/v1/audio/transcriptions/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/audio/voices/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/audio/voices/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/chat/completions/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/chat/completions/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/embeddings/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/embeddings/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/images/generations/route.js +4 -2
- package/app/.next-cli-build/server/app/api/v1/images/generations/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/messages/count_tokens/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/messages/count_tokens/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/messages/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/messages/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/models/[...model]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/models/[...model]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/models/info/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/models/info/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/models/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/models/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/responses/compact/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/responses/compact/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/responses/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/responses/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/search/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/search/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/systemone/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/systemone/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/videos/[id]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/videos/[id]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/videos/edits/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/videos/edits/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/videos/extensions/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/videos/extensions/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/videos/generations/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/videos/generations/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1/web/fetch/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1/web/fetch/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1beta/models/[...path]/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1beta/models/[...path]/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/v1beta/models/route.js +1 -1
- package/app/.next-cli-build/server/app/api/v1beta/models/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/version/route.js +1 -1
- package/app/.next-cli-build/server/app/api/version/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/version/shutdown/route.js +1 -1
- package/app/.next-cli-build/server/app/api/version/shutdown/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/api/version/update/route.js +1 -1
- package/app/.next-cli-build/server/app/api/version/update/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/callback/page.js +1 -1
- package/app/.next-cli-build/server/app/callback/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/callback/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/callback.html +1 -1
- package/app/.next-cli-build/server/app/callback.rsc +5 -5
- package/app/.next-cli-build/server/app/callback.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/callback.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/callback.segments/callback/__PAGE__.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/basic-chat.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/basic-chat.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk/dashboard/basic-chat/__PAGE__.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/cli-tools.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/cli-tools.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk/dashboard/cli-tools/__PAGE__.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/combos.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/combos.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk/dashboard/combos/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/combos.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/combos.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/endpoint.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/endpoint.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk/dashboard/endpoint/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard/media-providers/web/__PAGE__.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/mitm.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/mitm.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk/dashboard/mitm/__PAGE__.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/mitm.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/mitm.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/profile.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/profile.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk/dashboard/profile/__PAGE__.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/profile.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/profile.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/providers/new.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/providers/new.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard/providers/new/__PAGE__.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/providers.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/providers.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk/dashboard/providers/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/providers.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/providers.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk/dashboard/proxy-pools/__PAGE__.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/pxpipe.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/pxpipe.rsc +8 -8
- package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/!KGRhc2hib2FyZCk/dashboard/pxpipe/__PAGE__.segment.rsc +8 -8
- package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/_full.segment.rsc +8 -8
- package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/quota.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/quota.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk/dashboard/quota/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/quota.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/quota.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/settings/pricing/page.js +1 -1
- package/app/.next-cli-build/server/app/dashboard/settings/pricing/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/dashboard/settings/pricing/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/dashboard/settings/pricing/__PAGE__.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/skills.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/skills.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk/dashboard/skills/__PAGE__.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/skills.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/skills.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/token-saver.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/token-saver.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/token-saver.segments/!KGRhc2hib2FyZCk/dashboard/token-saver/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/token-saver.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/token-saver.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/translator.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/translator.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk/dashboard/translator/__PAGE__.segment.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard/translator.segments/_full.segment.rsc +7 -7
- package/app/.next-cli-build/server/app/dashboard/translator.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/usage.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/usage.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk/dashboard/usage/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/usage.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/usage.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard.html +1 -1
- package/app/.next-cli-build/server/app/dashboard.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard.segments/!KGRhc2hib2FyZCk/dashboard/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/favicon.ico/route.js +1 -1
- package/app/.next-cli-build/server/app/favicon.ico/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/index.html +1 -1
- package/app/.next-cli-build/server/app/index.rsc +5 -5
- package/app/.next-cli-build/server/app/index.segments/__PAGE__.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/index.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/index.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/landing/page.js +1 -1
- package/app/.next-cli-build/server/app/landing/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/landing/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/landing.html +1 -1
- package/app/.next-cli-build/server/app/landing.rsc +6 -6
- package/app/.next-cli-build/server/app/landing.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/landing.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/landing.segments/landing/__PAGE__.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/login/page.js +1 -1
- package/app/.next-cli-build/server/app/login/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/login/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/login.html +1 -1
- package/app/.next-cli-build/server/app/login.rsc +5 -5
- package/app/.next-cli-build/server/app/login.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/login.segments/_tree.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/login.segments/login/__PAGE__.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/manifest.webmanifest/route.js +2 -2
- package/app/.next-cli-build/server/app/manifest.webmanifest/route.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/page.js +1 -1
- package/app/.next-cli-build/server/app/page.js.nft.json +1 -1
- package/app/.next-cli-build/server/app/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app-paths-manifest.json +11 -10
- package/app/.next-cli-build/server/chunks/1004.js +1 -0
- package/app/.next-cli-build/server/chunks/1133.js +1 -0
- package/app/.next-cli-build/server/chunks/1329.js +1 -0
- package/app/.next-cli-build/server/chunks/1350.js +1 -1
- package/app/.next-cli-build/server/chunks/1356.js +1 -0
- package/app/.next-cli-build/server/chunks/1757.js +1 -1
- package/app/.next-cli-build/server/chunks/21.js +1 -0
- package/app/.next-cli-build/server/chunks/2214.js +1 -1
- package/app/.next-cli-build/server/chunks/2327.js +9 -0
- package/app/.next-cli-build/server/chunks/24.js +1 -1
- package/app/.next-cli-build/server/chunks/3225.js +2 -2
- package/app/.next-cli-build/server/chunks/{1051.js → 3256.js} +1 -1
- package/app/.next-cli-build/server/chunks/3449.js +1 -1
- package/app/.next-cli-build/server/chunks/3726.js +1 -1
- package/app/.next-cli-build/server/chunks/3943.js +1 -1
- package/app/.next-cli-build/server/chunks/412.js +2 -2
- package/app/.next-cli-build/server/chunks/4123.js +1 -1
- package/app/.next-cli-build/server/chunks/4190.js +1 -1
- package/app/.next-cli-build/server/chunks/4279.js +1 -0
- package/app/.next-cli-build/server/chunks/4882.js +1 -1
- package/app/.next-cli-build/server/chunks/4956.js +2 -0
- package/app/.next-cli-build/server/chunks/{3811.js → 4957.js} +1 -1
- package/app/.next-cli-build/server/chunks/5026.js +1 -1
- package/app/.next-cli-build/server/chunks/5258.js +1 -1
- package/app/.next-cli-build/server/chunks/5308.js +2 -0
- package/app/.next-cli-build/server/chunks/5330.js +180 -20
- package/app/.next-cli-build/server/chunks/5615.js +2 -2
- package/app/.next-cli-build/server/chunks/6070.js +1 -1
- package/app/.next-cli-build/server/chunks/614.js +1 -1
- package/app/.next-cli-build/server/chunks/615.js +1 -1
- package/app/.next-cli-build/server/chunks/6171.js +5 -5
- package/app/.next-cli-build/server/chunks/6638.js +1 -0
- package/app/.next-cli-build/server/chunks/6708.js +1 -1
- package/app/.next-cli-build/server/chunks/6780.js +1 -0
- package/app/.next-cli-build/server/chunks/6877.js +1 -1
- package/app/.next-cli-build/server/chunks/7187.js +1 -0
- package/app/.next-cli-build/server/chunks/{4199.js → 7220.js} +1 -1
- package/app/.next-cli-build/server/chunks/7247.js +1 -1
- package/app/.next-cli-build/server/chunks/7525.js +1 -1
- package/app/.next-cli-build/server/chunks/7557.js +1 -1
- package/app/.next-cli-build/server/chunks/7573.js +1 -0
- package/app/.next-cli-build/server/chunks/7716.js +1 -1
- package/app/.next-cli-build/server/chunks/778.js +1 -0
- package/app/.next-cli-build/server/chunks/7782.js +1 -0
- package/app/.next-cli-build/server/chunks/7801.js +7 -0
- package/app/.next-cli-build/server/chunks/7843.js +3 -3
- package/app/.next-cli-build/server/chunks/794.js +1 -0
- package/app/.next-cli-build/server/chunks/8238.js +1 -0
- package/app/.next-cli-build/server/chunks/8251.js +1 -1
- package/app/.next-cli-build/server/chunks/8271.js +1 -0
- package/app/.next-cli-build/server/chunks/8332.js +1 -0
- package/app/.next-cli-build/server/chunks/8402.js +1 -1
- package/app/.next-cli-build/server/chunks/8416.js +1 -1
- package/app/.next-cli-build/server/chunks/8499.js +11 -11
- package/app/.next-cli-build/server/chunks/8623.js +9 -0
- package/app/.next-cli-build/server/chunks/8767.js +7 -0
- package/app/.next-cli-build/server/chunks/8895.js +38 -38
- package/app/.next-cli-build/server/chunks/9100.js +4 -4
- package/app/.next-cli-build/server/chunks/915.js +1 -1
- package/app/.next-cli-build/server/chunks/9310.js +1 -0
- package/app/.next-cli-build/server/chunks/9318.js +1 -0
- package/app/.next-cli-build/server/chunks/9460.js +1 -0
- package/app/.next-cli-build/server/chunks/9489.js +3 -0
- package/app/.next-cli-build/server/chunks/9609.js +1 -1
- package/app/.next-cli-build/server/chunks/9745.js +1 -0
- package/app/.next-cli-build/server/instrumentation.js +1 -1
- package/app/.next-cli-build/server/instrumentation.js.nft.json +1 -1
- package/app/.next-cli-build/server/middleware-build-manifest.js +1 -1
- package/app/.next-cli-build/server/middleware-react-loadable-manifest.js +1 -1
- package/app/.next-cli-build/server/middleware.js +8 -8
- package/app/.next-cli-build/server/middleware.js.nft.json +1 -1
- package/app/.next-cli-build/server/pages/404.html +1 -1
- package/app/.next-cli-build/server/pages/500.html +1 -1
- package/app/.next-cli-build/server/preview-props.json +3 -3
- package/app/.next-cli-build/server/server-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/server-reference-manifest.json +1 -1
- package/app/.next-cli-build/static/chunks/124.cdfe12e15f8991cc.js +1 -0
- package/app/.next-cli-build/static/chunks/1321-60d7e6d47656619c.js +1 -0
- package/app/.next-cli-build/static/chunks/2435.1eeb203d028eb21f.js +1 -0
- package/app/.next-cli-build/static/chunks/4285-e97c3151f30199d8.js +1 -0
- package/app/.next-cli-build/static/chunks/5462.fed9dc8f008b389c.js +1 -0
- package/app/.next-cli-build/static/chunks/5497-ff26fb5a567cddba.js +7 -0
- package/app/.next-cli-build/static/chunks/{6808-9d9762a52c1840d9.js → 6808-5b23c18782066012.js} +1 -1
- package/app/.next-cli-build/static/chunks/{809-2c4d631176de6bd6.js → 809-bee50a6831a6411a.js} +2 -2
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/combos/page-9f1dd6ca7ceeabb7.js +1 -0
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page-8a571e8e9beccc96.js +69 -0
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/providers/[id]/page-bb1d9c5a0be9fd68.js +27 -0
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/providers/page-68597056465adc3d.js +1 -0
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/pxpipe/page-be8471c465c6fd52.js +1 -0
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/quota/page-27dfae5ff06623e2.js +1 -0
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/token-saver/page-f7d7700d4afd666f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/translator/page-61653073d768f6fd.js +1 -0
- package/app/.next-cli-build/static/chunks/app/(dashboard)/{layout-9b16f294682f60b0.js → layout-6eb55092f278a666.js} +1 -1
- package/app/.next-cli-build/static/chunks/app/_global-error/{page-7ee9602010473e2d.js → page-a70f643786fb402f.js} +1 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/login/{route-7ee9602010473e2d.js → route-a70f643786fb402f.js} +1 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/logout/{route-7ee9602010473e2d.js → route-a70f643786fb402f.js} +1 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/oidc/callback/{route-7ee9602010473e2d.js → route-a70f643786fb402f.js} +1 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/oidc/start/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/auth/oidc/test/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/auth/reset-password/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/auth/saml/acs/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/auth/saml/metadata/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/auth/saml/start/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/auth/saml/test/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/auth/status/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/all-statuses/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/alias/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/claude-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/cline-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/codewhale-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/codex-profiles/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/codex-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/copilot-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-registry/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-tools/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/crush-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/deepseek-tui-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/devin-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/droid-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/forge-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/grok-build-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/hermes-profiles/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/hermes-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/jcode-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/kilo-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/omp-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/openclaw-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/opencode-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/pi-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/smelt-settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/combos/[id]/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/combos/presets/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/combos/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/headroom/extras/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/headroom/proxy/[...path]/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/headroom/restart/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/headroom/start/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/headroom/status/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/headroom/stop/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/health/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/init/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/keys/[id]/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/keys/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/locale/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/message/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/sse/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/deepgram/voices/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/elevenlabs/voices/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/inworld/voices/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/minimax/voices/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/voices/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/models/alias/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/models/availability/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/models/catalog-sync/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/models/custom/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/models/disabled/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/models/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/models/test/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/[provider]/[action]/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/codex/bulk-import/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/codex/import-token/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/cursor/auto-import/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/cursor/import/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/gitlab/pat/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/grok-cli/bulk-import/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/iflow/cookie/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/api-key/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/auto-import/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/import/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/import-cli-proxy/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-authorize/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-exchange/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/xiaomi-mimo/api-key/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/xiaomi-mimo/auto-import/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/xiaomi-mimo/login/start/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/xiaomi-mimo/login/status/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/zed/auto-import/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/oauth/zed/import/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/pricing/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/provider-nodes/[id]/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/provider-nodes/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/provider-nodes/validate/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/models/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/overrides/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/test/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/test-models/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/client/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/kilo/free-models/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/suggested-models/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/test-batch/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/validate/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/providers/web-login/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/test/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/cloudflare-deploy/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/deno-deploy/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/netlify-deploy/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/vercel-deploy/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/health/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/install/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/logs/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/restart/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/start/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/stats/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/status/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/stop/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/settings/database/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/settings/proxy-test/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/settings/require-login/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/settings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/shutdown/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/tags/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/translator/console-logs/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/translator/console-logs/stream/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/translator/load/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/translator/save/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/translator/send/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/translator/translate/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/tunnel/disable/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/tunnel/enable/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/tunnel/status/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-check/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-disable/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-enable/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-install/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/claude-reset/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/codex-reset-credits/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/chart/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/history/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/logs/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/providers/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/request-details/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/request-logs/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/stats/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/usage/stream/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/api/chat/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/audio/speech/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/audio/transcriptions/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/audio/voices/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/chat/completions/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/embeddings/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/images/generations/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/messages/count_tokens/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/messages/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/models/[...model]/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/models/info/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/models/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/responses/compact/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/responses/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/search/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/systemone/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/videos/[id]/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/videos/edits/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/videos/extensions/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/videos/generations/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1/web/fetch/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1beta/models/[...path]/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/v1beta/models/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/version/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/version/shutdown/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/api/version/update/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/landing/page-2915d691a511d8ec.js +1 -0
- package/app/.next-cli-build/static/chunks/app/manifest.webmanifest/route-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/app/page-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/app-error-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/forbidden-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/not-found-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/unauthorized-a70f643786fb402f.js +1 -0
- package/app/.next-cli-build/static/chunks/webpack-9dc40b48930dad72.js +1 -0
- package/app/.next-cli-build/static/css/0a4c443a8a7225f7.css +1 -0
- package/app/.next-cli-build/static/y2h7yx597nXU7_RKFBkM7/_buildManifest.js +1 -0
- package/app/node_modules/baseline-browser-mapping/dist/index.cjs +1 -1
- package/app/node_modules/baseline-browser-mapping/package.json +1 -1
- package/app/open-sse/executors/gemini-web/browserLease.js +59 -0
- package/app/open-sse/lib/deepseek-pow-worker.mjs +20 -0
- package/app/package.json +16 -11
- package/app/public/i18n/literals/fa.json +1 -1
- package/app/public/i18n/literals/id.json +1 -1
- package/app/public/i18n/literals/km.json +1 -1
- package/app/public/i18n/literals/pt-BR.json +1 -1
- package/app/public/i18n/literals/th.json +1 -1
- package/app/public/i18n/literals/zh-CN.json +1 -1
- package/app/public/providers/sensenova.png +0 -0
- package/app/public/providers/uc-web.png +0 -0
- package/app/public/providers/veoaifree-web.png +0 -0
- package/app/server.js +1 -1
- package/app/src/mitm/server.js +24 -24
- package/package.json +1 -1
- package/src/cli/utils/modelSelector.js +2 -0
- package/app/.next-cli-build/server/chunks/1836.js +0 -17
- package/app/.next-cli-build/server/chunks/2132.js +0 -1
- package/app/.next-cli-build/server/chunks/3210.js +0 -2
- package/app/.next-cli-build/server/chunks/4049.js +0 -1
- package/app/.next-cli-build/server/chunks/4230.js +0 -1
- package/app/.next-cli-build/server/chunks/436.js +0 -1
- package/app/.next-cli-build/server/chunks/4798.js +0 -1
- package/app/.next-cli-build/server/chunks/5182.js +0 -1
- package/app/.next-cli-build/server/chunks/5433.js +0 -1
- package/app/.next-cli-build/server/chunks/562.js +0 -1
- package/app/.next-cli-build/server/chunks/5827.js +0 -1
- package/app/.next-cli-build/server/chunks/6069.js +0 -1
- package/app/.next-cli-build/server/chunks/6922.js +0 -1
- package/app/.next-cli-build/server/chunks/7211.js +0 -1
- package/app/.next-cli-build/server/chunks/7877.js +0 -7
- package/app/.next-cli-build/server/chunks/7911.js +0 -1
- package/app/.next-cli-build/server/chunks/8363.js +0 -1
- package/app/.next-cli-build/server/chunks/8635.js +0 -3
- package/app/.next-cli-build/server/chunks/869.js +0 -1
- package/app/.next-cli-build/server/chunks/8910.js +0 -2
- package/app/.next-cli-build/server/chunks/936.js +0 -1
- package/app/.next-cli-build/server/chunks/9604.js +0 -1
- package/app/.next-cli-build/server/chunks/9858.js +0 -1
- package/app/.next-cli-build/static/chunks/124.c092990b4bdb9713.js +0 -1
- package/app/.next-cli-build/static/chunks/1321-d4118b60d25d04d3.js +0 -1
- package/app/.next-cli-build/static/chunks/2435.8a5a02e626c780d0.js +0 -1
- package/app/.next-cli-build/static/chunks/5462.c82c64c26a864ec0.js +0 -1
- package/app/.next-cli-build/static/chunks/5497-6461b116ea130fe9.js +0 -7
- package/app/.next-cli-build/static/chunks/5815-57d2c8f2bf5d101f.js +0 -1
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/combos/page-68f91309eb1f96f4.js +0 -1
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page-46e8e71f59e43a41.js +0 -69
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/providers/[id]/page-c18f2c1a8086dade.js +0 -27
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/providers/page-09aa442e419193bf.js +0 -1
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/pxpipe/page-ce1a79a72b996ef0.js +0 -1
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/quota/page-4dbfaf4b1a0b1c32.js +0 -1
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/token-saver/page-8a823c86edc9c9e9.js +0 -1
- package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/translator/page-4fad5050e91b2d9e.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/oidc/start/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/oidc/test/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/reset-password/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/saml/acs/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/saml/metadata/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/saml/start/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/saml/test/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/auth/status/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/all-statuses/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/alias/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/claude-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/cline-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/codewhale-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/codex-profiles/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/codex-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/copilot-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-registry/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-tools/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/crush-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/deepseek-tui-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/devin-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/droid-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/forge-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/grok-build-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/hermes-profiles/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/hermes-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/jcode-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/kilo-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/omp-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/openclaw-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/opencode-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/pi-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/cli-tools/smelt-settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/combos/[id]/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/combos/presets/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/combos/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/headroom/extras/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/headroom/proxy/[...path]/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/headroom/restart/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/headroom/start/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/headroom/status/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/headroom/stop/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/health/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/init/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/keys/[id]/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/keys/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/locale/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/message/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/sse/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/deepgram/voices/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/elevenlabs/voices/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/inworld/voices/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/minimax/voices/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/voices/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/models/alias/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/models/availability/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/models/catalog-sync/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/models/custom/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/models/disabled/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/models/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/models/test/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/[provider]/[action]/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/codex/bulk-import/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/codex/import-token/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/cursor/auto-import/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/cursor/import/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/gitlab/pat/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/grok-cli/bulk-import/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/iflow/cookie/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/api-key/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/auto-import/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/import/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/import-cli-proxy/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-authorize/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-exchange/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/xiaomi-mimo/api-key/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/xiaomi-mimo/auto-import/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/xiaomi-mimo/login/start/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/xiaomi-mimo/login/status/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/zed/auto-import/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/oauth/zed/import/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/pricing/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/provider-nodes/[id]/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/provider-nodes/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/provider-nodes/validate/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/models/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/overrides/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/test/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/[id]/test-models/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/client/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/kilo/free-models/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/suggested-models/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/test-batch/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/providers/validate/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/test/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/cloudflare-deploy/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/deno-deploy/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/netlify-deploy/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/proxy-pools/vercel-deploy/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/health/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/install/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/logs/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/restart/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/start/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/stats/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/status/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/pxpipe/stop/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/settings/database/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/settings/proxy-test/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/settings/require-login/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/settings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/shutdown/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/tags/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/translator/console-logs/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/translator/console-logs/stream/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/translator/load/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/translator/save/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/translator/send/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/translator/translate/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/tunnel/disable/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/tunnel/enable/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/tunnel/status/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-check/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-disable/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-enable/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-install/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/claude-reset/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/codex-reset-credits/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/chart/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/history/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/logs/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/providers/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/request-details/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/request-logs/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/stats/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/usage/stream/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/api/chat/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/audio/speech/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/audio/transcriptions/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/audio/voices/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/chat/completions/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/embeddings/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/images/generations/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/messages/count_tokens/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/messages/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/models/[...model]/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/models/info/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/models/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/responses/compact/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/responses/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/search/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/systemone/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/videos/[id]/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/videos/edits/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/videos/extensions/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/videos/generations/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1/web/fetch/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1beta/models/[...path]/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/v1beta/models/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/version/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/version/shutdown/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/api/version/update/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/landing/page-5c7fee91d003980e.js +0 -1
- package/app/.next-cli-build/static/chunks/app/manifest.webmanifest/route-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/app/page-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/app-error-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/forbidden-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/not-found-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/unauthorized-7ee9602010473e2d.js +0 -1
- package/app/.next-cli-build/static/chunks/webpack-a59a4f1fec3d2d50.js +0 -1
- package/app/.next-cli-build/static/css/ddd5ce279857f5e9.css +0 -1
- package/app/.next-cli-build/static/kgDBUz73SblEO1KRsJDNC/_buildManifest.js +0 -1
- /package/app/.next-cli-build/static/{kgDBUz73SblEO1KRsJDNC → y2h7yx597nXU7_RKFBkM7}/_ssgManifest.js +0 -0
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2134],{5539:(e,t,s)=>{"use strict";s.d(t,{A:()=>p,w:()=>d});var i=s(95155),a=s(12115),r=s(14051),l=s.n(r),n=s(35497),o=s(73006);let d=new Set(["grok-web","chatgpt-web","gemini-web","muse-web","deepseek-web","uc-web"]),c={default:"person",grok:"bolt",work:"work",personal:"home"},m=[{key:"opening",label:"Opening browser window",icon:"open_in_new"},{key:"waiting",label:"Waiting for you to log in",icon:"hourglass_top"},{key:"saving",label:"Saving connection",icon:"save"}];function p({providerId:e,onConnected:t,size:s="sm"}){let[r,l]=(0,a.useState)(!1),[d,u]=(0,a.useState)("idle"),[x,h]=(0,a.useState)(""),[f,g]=(0,a.useState)(["default"]),[y,b]=(0,a.useState)("default"),v=(0,a.useRef)(null),j=(0,a.useRef)(null),w=(0,a.useCallback)(()=>{v.current&&(clearInterval(v.current),v.current=null)},[]);(0,a.useEffect)(()=>()=>{w(),j.current&&clearTimeout(j.current)},[w]),(0,a.useEffect)(()=>{if(!r)return;let t=!1;return fetch("/api/providers/web-login",{cache:"no-store"}).then(e=>e.json()).then(s=>{if(t||!Array.isArray(s.profiles))return;let i=window.localStorage.getItem(`weblogin:profile:${e}`),a=s.profiles.includes("default")?s.profiles:["default",...s.profiles];g(a),b(i&&a.includes(i)?i:"default")}).catch(()=>{}),()=>{t=!0}},[r,e]);let k=(0,a.useCallback)(t=>{b(t),window.localStorage.setItem(`weblogin:profile:${e}`,t)},[e]),N="opening"===d||"waiting"===d,C=(0,a.useCallback)(()=>{N||(w(),l(!1),"error"===d&&(u("idle"),h("")))},[N,d,w]),S=(0,a.useCallback)(()=>{w(),v.current=setInterval(async()=>{try{let s=await fetch(`/api/providers/web-login?provider=${encodeURIComponent(e)}`,{cache:"no-store"}),i=await s.json();"success"===i.status?(w(),u("success"),h(i.email?`${(0,o.Tl)("Signed in as")} ${i.email}`:"Connection saved"),"function"==typeof t&&t(),j.current=setTimeout(()=>{l(!1),h("")},1500)):"error"===i.status||"timeout"===i.status||"cancelled"===i.status?(w(),u("error"),h(i.error||(0,o.Tl)("Login failed"))):u(e=>"opening"===e?"waiting":e)}catch{}},2e3)},[e,t,w]),A=(0,a.useCallback)(async()=>{u("opening"),h("");try{let t=await fetch("/api/providers/web-login",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({provider:e,profile:y})}),s=await t.json();if(!t.ok){u("error"),h(s.error||(0,o.Tl)("Failed to start login"));return}u("waiting"),h((0,o.Tl)("A browser window has opened — log in there, this page updates itself.")),S()}catch(e){u("error"),h(e?.message||(0,o.Tl)("Failed to start login"))}},[e,y,S]),T=(0,a.useCallback)(()=>{fetch(`/api/providers/web-login?provider=${encodeURIComponent(e)}`,{method:"DELETE"}).catch(()=>{}),w(),u("idle"),h("")},[e,w]),$=(0,a.useCallback)(()=>{let e=window.prompt((0,o.Tl)("New browser profile name (e.g. work, personal):"),"");if(!e)return;let t=e.trim().replace(/[^a-zA-Z0-9_-]/g,"-").slice(0,40);t&&(g(e=>e.includes(t)?e:[...e,t]),k(t))},[k]),O="opening"===d?0:"waiting"===d?1:"success"===d?2:-1;return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(n.$n,{size:s,icon:"success"===d?"check_circle":"language",variant:"secondary",onClick:()=>{u("idle"),h(""),l(!0)},title:(0,o.Tl)("Open a browser window, log in by hand — the cookie is captured automatically"),children:"success"===d?(0,o.Tl)("Connected"):(0,o.Tl)("Login via Browser")}),(0,i.jsx)(n.aF,{isOpen:r,onClose:C,title:(0,o.Tl)("Login via Browser"),size:"sm",children:(0,i.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,i.jsx)("p",{className:"text-xs text-text-muted",children:(0,o.Tl)("A Chrome window opens on a shared browser profile. Log in there — the session is captured automatically. One Google login in a profile makes every other provider a single “Continue with Google” click.")}),(0,i.jsxs)("div",{children:[(0,i.jsxs)("div",{className:"mb-2 flex items-center justify-between",children:[(0,i.jsx)("span",{className:"text-xs font-medium uppercase tracking-wide text-text-muted",children:(0,o.Tl)("Browser profile")}),(0,i.jsxs)("button",{type:"button",onClick:$,disabled:N,className:"flex items-center gap-1 text-xs text-primary hover:underline disabled:opacity-50",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"add"}),(0,o.Tl)("New profile")]})]}),(0,i.jsx)("div",{className:"grid grid-cols-2 gap-2",children:f.map(e=>{let t=e===y;return(0,i.jsxs)("button",{type:"button",disabled:N,onClick:()=>k(e),className:`flex items-center gap-2 rounded border border-accent/30 bg-sidebar p-2 text-left text-sm transition-colors focus:outline-none focus:ring-1 focus:ring-primary disabled:opacity-50 ${t?"border-primary ring-1 ring-primary":"hover:border-accent/60"}`,children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-[18px] text-text-muted",children:function(e){let t=String(e).toLowerCase();for(let[e,s]of Object.entries(c))if(t.includes(e))return s;return"folder_shared"}(e)}),(0,i.jsx)("span",{className:"min-w-0 flex-1 truncate",children:e}),t&&(0,i.jsx)("span",{className:"material-symbols-outlined text-[16px] text-primary",children:"check_circle"})]},e)})})]}),"idle"!==d&&(0,i.jsx)("div",{className:"rounded border border-accent/20 bg-sidebar/50 p-3",children:"success"===d?(0,i.jsxs)("div",{className:"flex items-center gap-2 text-sm font-medium text-green-400",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:"check_circle"}),"✓ ",x||(0,o.Tl)("Connection saved")]}):"error"===d?(0,i.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,i.jsxs)("div",{className:"flex items-center gap-2 text-sm font-medium text-yellow-400",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:"error"}),(0,o.Tl)("Login failed")]}),x&&(0,i.jsx)("p",{className:"pl-6 text-xs text-red-500 break-words",children:x})]}):(0,i.jsxs)("ol",{className:"flex flex-col gap-2",children:[m.map((e,t)=>{let s=t<O,a=t===O;return(0,i.jsxs)("li",{className:`flex items-center gap-2 text-sm ${s?"text-green-400":a?"text-primary":"text-text-muted opacity-50"}`,children:[(0,i.jsx)("span",{className:`material-symbols-outlined text-[18px] ${a?"animate-pulse":""}`,children:s?"check_circle":e.icon}),(0,o.Tl)(e.label)]},e.key)}),x&&(0,i.jsx)("li",{className:"pl-6 text-xs text-text-muted",children:x})]})}),(0,i.jsx)("div",{className:"flex gap-2",children:"success"===d?(0,i.jsx)(n.$n,{onClick:C,fullWidth:!0,children:(0,o.Tl)("Done")}):N?(0,i.jsx)(n.$n,{onClick:T,variant:"ghost",fullWidth:!0,children:(0,o.Tl)("Cancel")}):(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(n.$n,{onClick:A,fullWidth:!0,disabled:"error"===d&&!x,children:(0,o.Tl)("Open Browser & Login")}),(0,i.jsx)(n.$n,{onClick:C,variant:"ghost",fullWidth:!0,disabled:N,children:(0,o.Tl)("Close")})]})})]})})]})}p.propTypes={providerId:l().string.isRequired,onConnected:l().func,size:l().oneOf(["sm","md","lg"])}},56828:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>ea});var i=s(95155),a=s(12115),r=s(73321),l=s(98500),n=s.n(l),o=s(5772),d=s(8247),c=s(35497),m=s(88105),p=s(28777),u=s(67899),x=s(62630);s(67468),s(60950);var h=s(13097);let f=["none","low","medium","high"],g=["none","thinking"],y=["none","low","medium","high","xhigh","max"],b={openai:["none","minimal","low","medium","high","xhigh"],"claude-adaptive":y,"claude-budget":y,"gemini-level":["minimal","low","medium","high"],"gemini-budget":f,zai:g,qwen:f,kimi:["none","low","medium","high","max"],deepseek:["none","high","max"],commandcode:["none","low","medium","high","xhigh","max"],minimax:g,hunyuan:f,step:f,nous:f},v=["none","minimal","low","medium","high","xhigh","max"],j=["none","low","medium","high","max"],w=[{pattern:"*gemini-4*",levels:["low","medium","high"]},{pattern:"*claude*4.6*",levels:j},{pattern:"*claude*4-6*",levels:j},{provider:"codex",pattern:"*gpt-6*",levels:v},{provider:"codex",pattern:"*gpt-5.6-sol*",levels:[...v,"ultra"]},{provider:"codex",pattern:"*gpt-5.6-terra*",levels:[...v,"ultra"]},{provider:"codex",pattern:"*gpt-5.6-luna*",levels:v},{pattern:"*codex*",levels:["low","medium","high","xhigh"]},{provider:"opencode",pattern:"*mimo*v2.6*",levels:["none","minimal","low","medium","high","xhigh","max"]},{pattern:"*mimo*v2.6*",levels:["none","low","medium","high","xhigh"]},{pattern:"*mimo*v2.5-pro*",levels:["none","low","medium","high","xhigh"]},{provider:"codebuddy-cn",pattern:"deepseek-v4-pro",levels:["low","high","xhigh"]},{provider:"codebuddy-cn",pattern:"deepseek-v4.1-flash",levels:["low","high","max"]},{pattern:"*deepseek-v4.1-flash-free*",levels:["low","high","max"]},{pattern:"*deepseek-v4.*",levels:["none","low","medium","high","xhigh","max"]},{provider:"codebuddy-cn",pattern:"glm-5.3",levels:["low","high","max"]},{provider:"codebuddy-cn",pattern:"glm-5.3-flash",levels:["low","high","max"]},{provider:"codebuddy-cn",pattern:"glm-5.2",levels:["high","xhigh"]},{provider:"codebuddy-cn",pattern:"kimi-k2.8-preview",levels:["low","medium","high"]},{provider:"codebuddy-cn",pattern:"hy3",levels:["low","high"]},{provider:"codebuddy-cn",pattern:"hy4-preview",levels:["high"]},{provider:"codebuddy-intl",pattern:"deepseek-v4*",levels:["low","high","xhigh"]},{provider:"minimax-code",pattern:"MiniMax-M3.1*",levels:["low","medium","high","xhigh","max"]},{provider:"minimax-code",pattern:"MiniMax-M3",levels:["none","high"]},{provider:"minimax-code-global",pattern:"MiniMax-M3.1*",levels:["low","medium","high","xhigh","max"]},{provider:"minimax-code-global",pattern:"MiniMax-M3",levels:["none","high"]}];function k(e,t){if("kiro"===e&&null===function(e){if("string"!=typeof e)return null;let t=e.toLowerCase().replace(/-/g,".");if(/(?:^|[/.])gpt[/.]5[/.]6(?:[/.]|$)/.test(t))return"reasoning";if(!t.includes("claude"))return null;let s=function(e){if("string"!=typeof e)return null;let t=e.toLowerCase().replace(/-/g,".").match(/(?:^|[/.])claude(?:[/.][a-z]+)*[/.](\d+)(?:[/.](\d+))?(?:[/.]|$)/);return t?{major:Number(t[1]),minor:void 0===t[2]?null:Number(t[2])}:null}(e);if(!s)return null;let{major:i,minor:a}=s;return i<4||4===i&&(null===a||a<=5||null!==a&&a>=1e3)?null:"output_config"}(t))return null;let s=(0,u.nl)(e,t);if(!s.reasoning)return null;let i=String(t||"").replace(/\([^()]+\)\s*$/,""),a="codex"===e?(0,h.SM)("cx").find(e=>e.id===i)?.thinkingLevels:null,r=w.find(s=>(!s.provider||s.provider===e)&&(0,x.gH)(s.pattern,t)),l=a||r?.levels||b[s.thinkingFormat]||f;return!1===s.thinkingCanDisable&&(l=l.filter(e=>"none"!==e)),l}var N=s(11059),C=s(929),S=s(73006);let A=new Map;async function T(e){if(!e?.url||!e?.type)return[];let t=A.get(e.url);if(t&&Date.now()<t.expiresAt)return t.data;try{let t=new URLSearchParams({url:e.url,type:e.type}),s=await fetch(`/api/providers/suggested-models?${t}`);if(!s.ok)return[];let i=(await s.json()).data??[];return A.set(e.url,{data:i,expiresAt:Date.now()+6e5}),i}catch{return[]}}var $=s(81231),O=s(14051),P=s.n(O);function I({model:e,fullModel:t,aliases:s,copied:a,onCopy:r,testStatus:l,isCustom:n,isFree:o,onDeleteAlias:d,onTest:m,isTesting:p,onDisable:u,onAddAlias:x,onRemoveAlias:h,caps:f,thinkingSuffix:g}){let y=g?`${t}(${g})`:t,b="ok"===l?"#22c55e":"error"===l?"#ef4444":void 0;return(0,i.jsx)("div",{className:`group w-full sm:w-auto min-w-0 max-w-full rounded-lg border px-3 py-2 ${"ok"===l?"border-green-500/40":"error"===l?"border-red-500/40":"border-border"} hover:bg-sidebar/50`,children:(0,i.jsxs)("div",{className:"flex min-w-0 items-start gap-2 sm:items-center",children:[(0,i.jsx)("span",{className:"material-symbols-outlined shrink-0 text-base mt-0.5 sm:mt-0",style:b?{color:b}:void 0,children:"ok"===l?"check_circle":"error"===l?"cancel":"smart_toy"}),(0,i.jsxs)("div",{className:"flex min-w-0 flex-1 flex-col gap-1",children:[(0,i.jsx)("code",{className:"w-fit max-w-full break-all rounded bg-sidebar px-1.5 py-0.5 font-mono text-xs text-text-muted sm:max-w-[360px] sm:truncate",children:y}),(0,i.jsxs)("span",{className:"flex min-w-0 items-center text-[9px] gap-1 pl-1",children:[e.name&&(0,i.jsx)("span",{className:"break-all sm:truncate text-[9px] italic text-text-muted/70",children:e.name}),(0,i.jsx)(c.nh,{caps:f,colorOverride:"text-text-muted/70",size:12})]}),s?.length>0&&(0,i.jsx)("span",{className:"flex min-w-0 flex-wrap items-center gap-1 pl-1",children:s.map(e=>(0,i.jsxs)("span",{className:"flex items-center gap-0.5 rounded bg-sidebar px-1 py-px font-mono text-[9px] text-primary/80",children:[e,h&&(0,i.jsx)("button",{onClick:()=>h(e),title:"Remove shortcut",className:"text-text-muted hover:text-red-500",children:(0,i.jsx)("span",{className:"material-symbols-outlined text-[10px]",children:"close"})})]},e))})]}),(0,i.jsxs)("div",{className:"flex shrink-0 items-center gap-0.5 sm:gap-1",children:[x&&(0,i.jsxs)("div",{className:"relative shrink-0 group/btn",children:[(0,i.jsx)("button",{onClick:()=>{let e=window.prompt(`Shortcut name for ${y}`,""),t=e?.trim().toLowerCase().replace(/[^a-z0-9_-]/g,"");t&&x(t)},className:"rounded p-0.5 text-text-muted opacity-100 transition-opacity hover:bg-sidebar hover:text-primary sm:opacity-0 sm:group-hover:opacity-100",children:(0,i.jsx)("span",{className:"material-symbols-outlined text-sm",children:"label"})}),(0,i.jsx)("span",{className:"pointer-events-none absolute mt-1 top-5 left-1/2 -translate-x-1/2 text-[10px] text-text-muted whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity",children:"Add shortcut"})]}),m&&(0,i.jsxs)("div",{className:"relative shrink-0 group/btn",children:[(0,i.jsx)("button",{onClick:m,disabled:p,className:`rounded p-0.5 text-text-muted transition-opacity hover:bg-sidebar hover:text-primary ${p?"opacity-100":"opacity-100 sm:opacity-0 sm:group-hover:opacity-100"}`,children:(0,i.jsx)("span",{className:"material-symbols-outlined text-sm",style:p?{animation:"spin 1s linear infinite"}:void 0,children:p?"progress_activity":"science"})}),(0,i.jsx)("span",{className:"pointer-events-none absolute mt-1 top-5 left-1/2 -translate-x-1/2 text-[10px] text-text-muted whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity",children:p?"Testing...":"Test"})]}),(0,i.jsxs)("div",{className:"relative shrink-0 group/btn",children:[(0,i.jsx)("button",{onClick:()=>r(y,`model-${e.id}`),className:"rounded p-0.5 text-text-muted hover:bg-sidebar hover:text-primary",children:(0,i.jsx)("span",{className:"material-symbols-outlined text-sm",children:a===`model-${e.id}`?"check":"content_copy"})}),(0,i.jsx)("span",{className:"pointer-events-none absolute mt-1 top-5 left-1/2 -translate-x-1/2 text-[10px] text-text-muted whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity",children:a===`model-${e.id}`?"Copied!":"Copy"})]}),n?(0,i.jsx)("button",{onClick:d,className:"rounded p-0.5 text-text-muted opacity-100 transition-opacity hover:bg-red-500/10 hover:text-red-500 sm:opacity-0 sm:group-hover:opacity-100",title:"Remove custom model",children:(0,i.jsx)("span",{className:"material-symbols-outlined text-sm",children:"close"})}):u?(0,i.jsx)("button",{onClick:u,className:"rounded p-0.5 text-text-muted opacity-100 transition-opacity hover:bg-red-500/10 hover:text-red-500 sm:opacity-0 sm:group-hover:opacity-100",title:"Disable this model",children:(0,i.jsx)("span",{className:"material-symbols-outlined text-sm",children:"close"})}):null]})]})})}function E({modelId:e,fullModel:t,alias:s,copied:a,onCopy:r,onDeleteAlias:l,onTest:n,testStatus:o,isTesting:d}){let c="ok"===o?"#22c55e":"error"===o?"#ef4444":void 0;return(0,i.jsxs)("div",{className:`flex items-center gap-3 p-3 rounded-lg border ${"ok"===o?"border-green-500/40":"error"===o?"border-red-500/40":"border-border"} hover:bg-sidebar/50`,children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-base text-text-muted",style:c?{color:c}:void 0,children:"ok"===o?"check_circle":"error"===o?"cancel":"smart_toy"}),(0,i.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,i.jsx)("p",{className:"text-sm font-medium truncate",children:e}),(0,i.jsxs)("div",{className:"flex items-center gap-1 mt-1",children:[(0,i.jsx)("code",{className:"text-xs text-text-muted font-mono bg-sidebar px-1.5 py-0.5 rounded",children:t}),s&&(0,i.jsx)("span",{className:"rounded bg-sidebar px-1 py-0.5 font-mono text-[9px] text-primary/80",children:s}),(0,i.jsxs)("div",{className:"relative group/btn",children:[(0,i.jsx)("button",{onClick:()=>r(t,`model-${e}`),className:"p-0.5 hover:bg-sidebar rounded text-text-muted hover:text-primary",children:(0,i.jsx)("span",{className:"material-symbols-outlined text-sm",children:a===`model-${e}`?"check":"content_copy"})}),(0,i.jsx)("span",{className:"pointer-events-none absolute top-5 left-1/2 -translate-x-1/2 text-[10px] text-text-muted whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity",children:a===`model-${e}`?"Copied!":"Copy"})]}),n&&(0,i.jsxs)("div",{className:"relative group/btn",children:[(0,i.jsx)("button",{onClick:n,disabled:d,className:"p-0.5 hover:bg-sidebar rounded text-text-muted hover:text-primary transition-colors",children:(0,i.jsx)("span",{className:"material-symbols-outlined text-sm",style:d?{animation:"spin 1s linear infinite"}:void 0,children:d?"progress_activity":"science"})}),(0,i.jsx)("span",{className:"pointer-events-none absolute top-5 left-1/2 -translate-x-1/2 text-[10px] text-text-muted whitespace-nowrap opacity-0 group-hover/btn:opacity-100 transition-opacity",children:d?"Testing...":"Test"})]})]})]}),(0,i.jsx)("button",{onClick:l,className:"p-1 hover:bg-red-50 rounded text-red-500",title:"Remove model",children:(0,i.jsx)("span",{className:"material-symbols-outlined text-sm",children:"delete"})})]})}function R({providerStorageAlias:e,providerDisplayAlias:t,modelAliases:s,customModels:r,copied:l,onCopy:n,onDeleteAlias:o,onAddCustomModel:d,onDeleteCustomModel:m,connections:p,isAnthropic:u}){let[x,h]=(0,a.useState)(""),[f,g]=(0,a.useState)(!1),[y,b]=(0,a.useState)(!1),[v,j]=(0,a.useState)(null),[w,k]=(0,a.useState)({}),N=async t=>{if(!v){j(t);try{let s=await fetch("/api/models/test",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({model:`${e}/${t}`})}),i=await s.json();k(e=>({...e,[t]:i.ok?"ok":"error"}))}catch{k(e=>({...e,[t]:"error"}))}finally{j(null)}}},C=(0,$.R)({customModels:r,modelAliases:s,providerAlias:e,type:"llm"}),S=async()=>{if(!x.trim()||f)return;let e=x.trim();if(C.some(t=>t.id===e))return void alert("Model already exists for this provider.");g(!0);try{await d(e),h("")}catch(e){console.log("Error adding model:",e)}finally{g(!1)}},A=async()=>{if(y)return;let e=p.find(e=>!1!==e.isActive);if(e){b(!0);try{let t=await fetch(`/api/providers/${e.id}/models`),s=await t.json();if(!t.ok)return void alert(s.error||"Failed to import models");let i=s.models||[];if(0===i.length)return void alert("No models returned from /models.");let a=0;for(let e of i){let t=e.id||e.name||e.model;t&&(C.some(e=>e.id===t)||(await d(t),a+=1))}0===a&&alert("No new models were added.")}catch(e){console.log("Error importing models:",e)}finally{b(!1)}}},T=p.some(e=>!1!==e.isActive);return(0,i.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,i.jsxs)("p",{className:"text-sm text-text-muted",children:["Add ",u?"Anthropic":"OpenAI","-compatible models manually or import them from the /models endpoint."]}),(0,i.jsxs)("div",{className:"flex items-end gap-2 flex-wrap",children:[(0,i.jsxs)("div",{className:"flex-1 min-w-[240px]",children:[(0,i.jsx)("label",{htmlFor:"new-compatible-model-input",className:"text-xs text-text-muted mb-1 block",children:"Model ID"}),(0,i.jsx)("input",{id:"new-compatible-model-input",type:"text",value:x,onChange:e=>h(e.target.value),onKeyDown:e=>"Enter"===e.key&&S(),placeholder:u?"claude-3-opus-20240229":"gpt-4o",className:"w-full px-3 py-2 text-sm border border-border rounded-lg bg-background focus:outline-none focus:border-primary"})]}),(0,i.jsx)(c.$n,{size:"sm",icon:"add",onClick:S,disabled:!x.trim()||f,children:f?"Adding...":"Add"}),(0,i.jsx)(c.$n,{size:"sm",variant:"secondary",icon:"download",onClick:A,disabled:!T||y,children:y?"Importing...":"Import from /models"})]}),!T&&(0,i.jsx)("p",{className:"text-xs text-text-muted",children:"Add a connection to enable importing models."}),C.length>0&&(0,i.jsx)("div",{className:"flex flex-col gap-3",children:C.map(({id:s,alias:a,source:r})=>(0,i.jsx)(E,{modelId:s,alias:a,fullModel:`${t}/${s}`,copied:l,onCopy:n,onDeleteAlias:()=>"custom"===r?m(s):o(a),onTest:p.length>0?()=>N(s):void 0,testStatus:w[s],isTesting:v===s},`${r}-${e}/${s}`))})]})}I.propTypes={model:P().shape({id:P().string.isRequired}).isRequired,fullModel:P().string.isRequired,aliases:P().arrayOf(P().string),copied:P().string,onCopy:P().func.isRequired,testStatus:P().oneOf(["ok","error"]),isCustom:P().bool,isFree:P().bool,onDeleteAlias:P().func,onTest:P().func,isTesting:P().bool,onDisable:P().func,onAddAlias:P().func,onRemoveAlias:P().func,caps:P().object,thinkingSuffix:P().string},P().string.isRequired,P().string.isRequired,P().string,P().func.isRequired,P().func.isRequired,P().func,P().oneOf(["ok","error"]),P().bool,P().string.isRequired,P().object.isRequired,P().arrayOf(P().object),P().string,P().func.isRequired,P().func.isRequired,P().func.isRequired,P().func.isRequired,R.propTypes={providerStorageAlias:P().string.isRequired,providerDisplayAlias:P().string.isRequired,modelAliases:P().object.isRequired,customModels:P().arrayOf(P().object),copied:P().string,onCopy:P().func.isRequired,onDeleteAlias:P().func.isRequired,onAddCustomModel:P().func.isRequired,onDeleteCustomModel:P().func.isRequired,connections:P().arrayOf(P().shape({id:P().string,isActive:P().bool})).isRequired,isAnthropic:P().bool};var D=s(47650),z=s(70217);function _({until:e}){let[t,s]=(0,a.useState)("");return((0,a.useEffect)(()=>{let t=()=>{let t=new Date(e).getTime()-Date.now();if(t<=0)return void s("");let i=Math.floor(t/1e3);if(i<60)s(`${i}s`);else if(i<3600)s(`${Math.floor(i/60)}m ${i%60}s`);else{let e=Math.floor(i/3600),t=Math.floor(i%3600/60);s(`${e}h ${t}m`)}};t();let i=setInterval(t,1e3);return()=>clearInterval(i)},[e]),t)?(0,i.jsxs)("span",{className:"text-xs text-orange-500 font-mono",children:["⏱ ",t]}):null}function M({connection:e,proxyPools:t,isOAuth:s,isFirst:r,isLast:l,onMoveUp:n,onMoveDown:o,onToggleActive:d,onUpdateProxy:m,onEdit:p,onDelete:u,oneByOneStatus:x=null,autoPing:h=null}){let[f,g]=(0,a.useState)(!1),[y,b]=(0,a.useState)(!1),v=(0,a.useRef)(null),j=(0,a.useRef)(null),[w,k]=(0,a.useState)(null),N=new Map((t||[]).map(e=>[e.id,e])),C=e.providerSpecificData?.proxyPoolId||null,S=C?N.get(C):null,A=e.providerSpecificData?.connectionProxyEnabled===!0&&!!e.providerSpecificData?.connectionProxyUrl,T=!!C||A,$=S?`Pool: ${S.name}`:C?`Pool: ${C} (inactive/missing)`:A?`Legacy: ${e.providerSpecificData?.connectionProxyUrl}`:"",O=(()=>{if(!h)return"";let e=[];return(h.reactiveOn&&e.push("On reset"),h.scheduleOn&&e.push(`Scheduled (${h.scheduleSummary||"active"})`),e.length>0)?`Auto-ping active: ${e.join(" + ")}. Click to configure.`:"codex"===h.provider?"Auto-starts the next 5h Codex window after reset or on schedule. Click to configure.":"Auto-starts a new window on quota reset or fixed schedule. Click to configure."})(),P="";if(S?.proxyUrl||e.providerSpecificData?.connectionProxyUrl){let t=S?.proxyUrl||e.providerSpecificData?.connectionProxyUrl;try{let e=new URL(t);P=`${e.protocol}//${e.hostname}${e.port?`:${e.port}`:""}`}catch{P=t}}let I=S?.noProxy||e.providerSpecificData?.connectionNoProxy||"",E="default";S?.isActive===!0?E="success":(C||A)&&(E="error"),(0,a.useEffect)(()=>{if(!f)return;let e=e=>{v.current?.contains(e.target)||j.current?.contains(e.target)||g(!1)},t=()=>g(!1);return document.addEventListener("mousedown",e),window.addEventListener("resize",t),document.addEventListener("scroll",t,!0),()=>{document.removeEventListener("mousedown",e),window.removeEventListener("resize",t),document.removeEventListener("scroll",t,!0)}},[f]);let R=async e=>{b(!0);try{await m("__none__"===e?null:e)}finally{b(!1),g(!1)}},q=e.authType||(s?"oauth":"apikey"),U="oauth"===q,F="cookie"===q,K=e.name?.trim()||e.email?.trim()||e.displayName?.trim()||(U?"OAuth Account":F?"Cookie Account":"API Key"),L=e.name?.trim()&&e.email?.trim()&&e.name.trim()!==e.email.trim()?e.email.trim():e.name?.trim()&&e.displayName?.trim()&&e.name.trim()!==e.displayName.trim()?e.displayName.trim():null,[J,W]=(0,a.useState)(!1),H=Object.entries(e).filter(([e])=>e.startsWith("modelLock_")).map(([,e])=>e).filter(e=>!!e).sort()[0]||null;(0,a.useEffect)(()=>{let t=()=>{W(!!Object.entries(e).filter(([e])=>e.startsWith("modelLock_")).map(([,e])=>e).filter(e=>e&&new Date(e).getTime()>Date.now()).sort()[0])};t();let s=H?setInterval(t,1e3):null;return()=>{s&&clearInterval(s)}},[H]);let B="unavailable"!==e.testStatus||J?e.testStatus:"active",G=()=>x?"queued"===x.state?"queued":"testing"===x.state?"testing":"success"===x.state?"success":"failed"===x.state?x.error?`failed: ${x.error}`:"failed":null:null;return(0,i.jsxs)("div",{className:`group flex min-w-0 flex-col gap-3 rounded-lg p-2 transition-colors hover:bg-black/[0.02] dark:hover:bg-white/[0.02] sm:flex-row sm:items-center sm:justify-between ${!1===e.isActive?"opacity-60":""}`,children:[(0,i.jsxs)("div",{className:"flex min-w-0 flex-1 items-start gap-2 sm:items-center sm:gap-3",children:[(0,i.jsxs)("div",{className:"flex shrink-0 flex-col",children:[(0,i.jsx)("button",{onClick:n,disabled:r,className:`p-0.5 rounded ${r?"text-text-muted/30 cursor-not-allowed":"hover:bg-sidebar text-text-muted hover:text-primary"}`,children:(0,i.jsx)("span",{className:"material-symbols-outlined text-sm",children:"keyboard_arrow_up"})}),(0,i.jsx)("button",{onClick:o,disabled:l,className:`p-0.5 rounded ${l?"text-text-muted/30 cursor-not-allowed":"hover:bg-sidebar text-text-muted hover:text-primary"}`,children:(0,i.jsx)("span",{className:"material-symbols-outlined text-sm",children:"keyboard_arrow_down"})})]}),(0,i.jsx)("span",{className:"material-symbols-outlined shrink-0 text-base text-text-muted",children:F?"cookie":U?"lock":"key"}),(0,i.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,i.jsx)("p",{className:"text-sm font-medium truncate",children:K}),L&&(0,i.jsx)("p",{className:"text-xs text-text-muted truncate",children:L}),(0,i.jsxs)("div",{className:"mt-1 flex min-w-0 flex-wrap items-center gap-1.5 sm:gap-2",children:[(0,i.jsx)(c.Ex,{variant:(0,z.g)(e.isActive,B),size:"sm",dot:!0,children:!1===e.isActive?"disabled":B||"Unknown"}),(0,i.jsx)(c.Ex,{variant:"default",size:"sm",children:U?"OAuth":F?"Cookie":"API Key"}),T&&(0,i.jsx)(c.Ex,{variant:E,size:"sm",children:"Proxy"}),J&&!1!==e.isActive&&(0,i.jsx)(_,{until:H}),e.lastError&&!1!==e.isActive&&(0,i.jsx)("span",{className:"max-w-full truncate text-xs text-red-500 sm:max-w-[300px]",title:e.lastError,children:e.lastError}),(0,i.jsxs)("span",{className:"text-xs text-text-muted",children:["#",e.priority]}),e.globalPriority&&(0,i.jsxs)("span",{className:"text-xs text-text-muted",children:["Auto: ",e.globalPriority]}),G()&&(0,i.jsx)(c.Ex,{variant:x?"success"===x.state?"success":"failed"===x.state?"error":"testing"===x.state?"primary":"default":"default",size:"sm",children:G()})]}),T&&(0,i.jsxs)("div",{className:"mt-1 flex items-center gap-2 flex-wrap",children:[(0,i.jsx)("span",{className:"max-w-full truncate text-[11px] text-text-muted sm:max-w-[420px]",title:$,children:$}),P&&(0,i.jsx)("code",{className:"max-w-full truncate rounded bg-black/5 px-1 py-0.5 font-mono text-[10px] text-text-muted dark:bg-white/5 sm:max-w-[260px]",children:P}),I&&(0,i.jsxs)("span",{className:"max-w-full truncate text-[11px] text-text-muted sm:max-w-[320px]",title:I,children:["no_proxy: ",I]})]})]})]}),(0,i.jsxs)("div",{className:"flex w-full items-center justify-between gap-2 sm:w-auto sm:justify-end",children:[(0,i.jsxs)("div",{className:"grid flex-1 grid-cols-3 gap-1 sm:flex sm:flex-none",children:[(t||[]).length>0&&(0,i.jsxs)("div",{children:[(0,i.jsxs)("button",{ref:j,onClick:()=>{if(f)return void g(!1);let e=j.current?.getBoundingClientRect();if(!e)return void g(!0);let s=((t?.length||0)+1)*34+8,i=window.innerHeight-e.bottom,a=i<s&&e.top>i;k({position:"fixed",right:window.innerWidth-e.right,...a?{bottom:window.innerHeight-e.top+4,maxHeight:Math.max(e.top-8,120)}:{top:e.bottom+4,maxHeight:Math.max(i-8,120)}}),g(!0)},className:`flex w-full flex-col items-center rounded px-2 py-1 transition-colors hover:bg-black/5 dark:hover:bg-white/5 ${T?"text-primary":"text-text-muted hover:text-primary"}`,disabled:y,children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:y?"progress_activity":"lan"}),(0,i.jsx)("span",{className:"text-[10px] leading-tight",children:"Proxy"})]}),f&&(0,D.createPortal)((0,i.jsxs)("div",{ref:v,style:w,className:"z-50 max-w-[78vw] min-w-[160px] overflow-y-auto rounded-lg border border-border bg-bg py-1 shadow-lg",children:[(0,i.jsx)("button",{onClick:()=>R("__none__"),className:`w-full text-left px-3 py-1.5 text-sm hover:bg-black/5 dark:hover:bg-white/5 ${!C?"text-primary font-medium":"text-text-main"}`,children:"None"}),(t||[]).map(e=>(0,i.jsx)("button",{onClick:()=>R(e.id),className:`w-full text-left px-3 py-1.5 text-sm hover:bg-black/5 dark:hover:bg-white/5 ${C===e.id?"text-primary font-medium":"text-text-main"}`,children:e.name},e.id))]}),document.body)]}),h&&(0,i.jsx)(c.m_,{text:O,children:(0,i.jsxs)("button",{onClick:h.onConfigure,className:`flex w-full flex-col items-center rounded px-2 py-1 transition-colors hover:bg-black/5 dark:hover:bg-white/5 ${h.isActive?"text-primary":"text-text-muted hover:text-primary"}`,children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:"bolt"}),(0,i.jsx)("span",{className:"text-[10px] leading-tight",children:"Auto-ping"})]})}),(0,i.jsxs)("button",{onClick:p,className:"flex flex-col items-center rounded px-2 py-1 text-text-muted hover:bg-black/5 hover:text-primary dark:hover:bg-white/5",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:"edit"}),(0,i.jsx)("span",{className:"text-[10px] leading-tight",children:"Edit"})]}),(0,i.jsxs)("button",{onClick:u,className:"flex flex-col items-center rounded px-2 py-1 text-red-500 hover:bg-red-500/10",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:"delete"}),(0,i.jsx)("span",{className:"text-[10px] leading-tight",children:"Delete"})]})]}),(0,i.jsx)(c.lM,{size:"sm",checked:e.isActive??!0,onChange:d,title:e.isActive??!0?"Disable connection":"Enable connection"})]})]})}_.propTypes={until:P().string.isRequired},M.propTypes={connection:P().shape({id:P().string,name:P().string,email:P().string,displayName:P().string,modelLockUntil:P().string,testStatus:P().string,isActive:P().bool,lastError:P().string,priority:P().number,globalPriority:P().number}).isRequired,proxyPools:P().arrayOf(P().shape({id:P().string,name:P().string,proxyUrl:P().string,noProxy:P().string,isActive:P().bool})),isOAuth:P().bool.isRequired,isFirst:P().bool.isRequired,isLast:P().bool.isRequired,onMoveUp:P().func.isRequired,onMoveDown:P().func.isRequired,onToggleActive:P().func.isRequired,onUpdateProxy:P().func,onEdit:P().func.isRequired,onDelete:P().func.isRequired,oneByOneStatus:P().shape({state:P().string,error:P().string}),autoPing:P().shape({isActive:P().bool,provider:P().string,reactiveOn:P().bool,scheduleOn:P().bool,scheduleSummary:P().string,onConfigure:P().func})};let q=`name1|sk-key1
|
|
2
|
+
name2|sk-key2
|
|
3
|
+
sk-key-only-auto-named`;function U({isOpen:e,provider:t,providerName:s,isCompatible:r,isAnthropic:l,authType:n,authHint:o,website:d,proxyPools:p,error:u,existingNames:x,onSave:h,onBulkDone:f,onClose:g}){let y="__none__",b="ollama-local"===t,v="cookie"===n,j="xai"===t&&!v,w=v?"Cookie Value":"qoder"===t||"qoder-cn"===t?"Personal Access Token (PAT)":"API Key",k="azure"===t,N="cloudflare-ai"===t,C=m.Q2?.[t]?.credentialForm==="aws",S=m.Q2?.[t]?.apiKeyOptionalWith||null,A=m.Q2?.[t]?.regions||null,T=m.Q2?.[t]?.defaultRegion||A?.[0]?.id||"",[$,O]=(0,a.useState)({name:"",apiKey:"",defaultModel:"",priority:1,proxyPoolId:y,ollamaHostUrl:""}),[P,I]=(0,a.useState)({azureEndpoint:"",apiVersion:"2024-10-01-preview",deployment:"",organization:""}),[E,R]=(0,a.useState)({accountId:""}),[D,z]=(0,a.useState)({profile:"",region:"",accessKeyId:"",sessionToken:""}),[_,M]=(0,a.useState)(T),[F,K]=(0,a.useState)(!1),[L,J]=(0,a.useState)(null),[W,H]=(0,a.useState)(!1),B=N?`name1|sk-key1|acc123456
|
|
4
|
+
name2|sk-key2|def789012
|
|
5
|
+
sk-key-only-auto-named`:"qoder"===t||"qoder-cn"===t?`name1|pt-xxxxx
|
|
6
|
+
name2|pt-yyyyy
|
|
7
|
+
pt-only-auto-named`:q,[G,Z]=(0,a.useState)("single"),[V,Q]=(0,a.useState)(""),[X,Y]=(0,a.useState)(null),ee=()=>{if(b&&$.ollamaHostUrl.trim())return{baseUrl:$.ollamaHostUrl.trim()};if(k)return{azureEndpoint:P.azureEndpoint,apiVersion:P.apiVersion,deployment:P.deployment,organization:P.organization};if(N)return{accountId:E.accountId};if(C){let e={};return D.profile.trim()&&(e.profile=D.profile.trim()),D.region.trim()&&(e.region=D.region.trim()),D.accessKeyId.trim()&&(e.accessKeyId=D.accessKeyId.trim()),D.sessionToken.trim()&&(e.sessionToken=D.sessionToken.trim()),Object.keys(e).length?e:void 0}if(A&&_)return{region:_}},et=()=>{let e=ee();return!!(S&&e?.[S])||(C?!!$.apiKey&&!!e?.accessKeyId:!!$.apiKey)},es=async()=>{K(!0);try{let e=await fetch("/api/providers/validate",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({provider:t,apiKey:$.apiKey,providerSpecificData:ee()})}),s=await e.json();J(s.valid?"success":"failed")}catch{J("failed")}finally{K(!1)}},ei=async()=>{if(t&&(b||et())&&(b||$.name)&&(!r||$.defaultModel.trim())){H(!0);try{let e=!1;try{K(!0),J(null);let s=await fetch("/api/providers/validate",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({provider:t,apiKey:$.apiKey,providerSpecificData:ee()})});e=!!(await s.json()).valid,J(e?"success":"failed")}catch{J("failed")}finally{K(!1)}await h({name:$.name||(b?"Ollama Local":""),apiKey:$.apiKey,defaultModel:r?$.defaultModel.trim():void 0,priority:$.priority,proxyPoolId:$.proxyPoolId===y?null:$.proxyPoolId,testStatus:e?"active":"unknown",providerSpecificData:ee()})}finally{H(!1)}}},ea=async()=>{let e=V.split("\n");if(!e.length)return;let s=function(e,t,s={}){let{isCloudflareAi:i=!1}=s,a=new Set((Array.isArray(t)?t:[]).map(e=>"string"==typeof e?e.toLowerCase():"")),r=[];for(let t of e){let e,s="string"==typeof t?t.trim():"";if(!s)continue;let l=function(e,t={}){let{isCloudflareAi:s=!1}=t,i=e.split("|");if(s&&i.length>=3){let e=i[0].trim();return{baseName:e||"Key",apiKey:i.slice(1,-1).join("|").trim(),providerSpecificData:{accountId:i[i.length-1].trim()}}}return i.length>=2?{baseName:i[0].trim()||"Key",apiKey:i.slice(1).join("|").trim()}:{baseName:"Key",apiKey:i[0].trim()}}(s,{isCloudflareAi:i});if(!l||!l.apiKey)continue;let n=l.baseName,o=1;for(;e=`${n} ${o}`,a.has(e.toLowerCase());)o+=1;a.add(e.toLowerCase());let d={name:e,apiKey:l.apiKey,skipped:!1};l.providerSpecificData&&(d.providerSpecificData=l.providerSpecificData),r.push(d)}return r}(e,x,{isCloudflareAi:N});if(!s.length)return;H(!0),Y(null);let i=0,a=0;for(let e of s)try{let s=!1;try{let i=await fetch("/api/providers/validate",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({provider:t,apiKey:e.apiKey})});s=!!(await i.json().catch(()=>({}))).valid}catch{s=!1}(await fetch("/api/providers",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({provider:t,apiKey:e.apiKey,name:e.name,priority:1,testStatus:s?"active":"unknown",...e.providerSpecificData?{providerSpecificData:e.providerSpecificData}:{}})})).ok?i++:a++}catch{a++}H(!1),Y({success:i,failed:a}),i>0&&f&&f()};return t?(0,i.jsx)(c.aF,{isOpen:e,title:`Add ${s||t} ${w}`,onClose:g,children:(0,i.jsxs)("div",{className:"flex flex-col gap-4",children:[!C&&(0,i.jsxs)("div",{className:"flex gap-2",children:[(0,i.jsx)(c.$n,{size:"sm",variant:"single"===G?"primary":"ghost",onClick:()=>{Z("single"),Y(null)},children:"Single"}),(0,i.jsx)(c.$n,{size:"sm",variant:"bulk"===G?"primary":"ghost",onClick:()=>{Z("bulk"),Y(null)},children:"Bulk Add"})]}),"bulk"===G&&(0,i.jsxs)("div",{className:"flex flex-col gap-3",children:[(0,i.jsx)("p",{className:"text-xs text-text-muted",children:N?(0,i.jsxs)(i.Fragment,{children:["One key per line. Format: ",(0,i.jsx)("code",{children:"name|apiKey|accountId"})," or just ",(0,i.jsx)("code",{children:"apiKey"})," (auto-named by index)."]}):"qoder"===t||"qoder-cn"===t?(0,i.jsxs)(i.Fragment,{children:["One PAT per line. Format: ",(0,i.jsx)("code",{children:"name|pt-..."})," or just ",(0,i.jsx)("code",{children:"pt-..."})," (auto-named by index)."]}):(0,i.jsxs)(i.Fragment,{children:["One key per line. Format: ",(0,i.jsx)("code",{children:"name|apiKey"})," or just ",(0,i.jsx)("code",{children:"apiKey"})," (auto-named by index)."]})}),(0,i.jsx)("textarea",{className:"w-full rounded border border-accent/30 bg-sidebar p-2 text-sm font-mono resize-y min-h-[140px] focus:outline-none focus:ring-1 focus:ring-primary",placeholder:B,value:V,onChange:e=>Q(e.target.value)}),X&&(0,i.jsxs)("div",{className:`text-sm font-medium ${X.failed>0?"text-yellow-400":"text-green-400"}`,children:["✓ ",X.success," added",X.failed>0?`, ✗ ${X.failed} failed`:""]}),(0,i.jsxs)("div",{className:"flex gap-2",children:[(0,i.jsx)(c.$n,{onClick:ea,fullWidth:!0,disabled:W||!V.trim(),children:W?"Adding...":"Add All Keys"}),(0,i.jsx)(c.$n,{onClick:g,variant:"ghost",fullWidth:!0,children:"Cancel"})]})]}),"single"===G&&(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(c.pd,{label:"Name",value:$.name,onChange:e=>O({...$,name:e.target.value}),placeholder:b?"Ollama Local":"Production Key"}),b&&(0,i.jsxs)("div",{className:"flex gap-2",children:[(0,i.jsx)(c.pd,{label:"Ollama Host URL",value:$.ollamaHostUrl,onChange:e=>O({...$,ollamaHostUrl:e.target.value}),placeholder:"http://localhost:11434",className:"flex-1"}),(0,i.jsx)("div",{className:"pt-6",children:(0,i.jsx)(c.$n,{onClick:es,disabled:F||W,variant:"secondary",children:F?"Checking...":"Check"})})]}),!b&&(0,i.jsxs)("div",{className:"flex gap-2",children:[(0,i.jsx)(c.pd,{label:w,type:v?"text":"password",value:$.apiKey,onChange:e=>O({...$,apiKey:e.target.value}),placeholder:v?"grok-web"===t?"sso=xxxxx... or just the raw value":"eyJhbGciOi...":j?"xai-...":"qoder"===t||"qoder-cn"===t?"pt-...":"",className:"flex-1"}),(0,i.jsx)("div",{className:"pt-6",children:(0,i.jsx)(c.$n,{onClick:es,disabled:!et()||F||W,variant:"secondary",children:F?"Checking...":"Check"})})]}),j&&(0,i.jsx)("p",{className:"text-xs text-text-muted",children:"Use a direct xAI API key from console.x.ai. This is separate from Grok Build OAuth."}),v&&o&&(0,i.jsxs)("p",{className:"text-xs text-text-muted",children:[o,d&&(0,i.jsxs)(i.Fragment,{children:[" ",(0,i.jsxs)("a",{href:d,target:"_blank",rel:"noopener noreferrer",className:"text-primary underline",children:["Open ",d.replace(/^https?:\/\//,"")]})]})]}),A&&(0,i.jsx)(c.l6,{label:"Region",value:_,onChange:e=>M(e.target.value),options:A.map(e=>({value:e.id,label:e.label}))}),r&&(0,i.jsx)(c.pd,{label:"Default Model",value:$.defaultModel,onChange:e=>O({...$,defaultModel:e.target.value}),placeholder:l?"claude-3-5-sonnet-latest":"gpt-4o-mini"}),b&&(0,i.jsxs)("p",{className:"text-xs text-text-muted",children:["Leave blank to use ",(0,i.jsx)("code",{children:"http://localhost:11434"}),". For remote Ollama, enter the full host URL (e.g. ",(0,i.jsx)("code",{children:"http://192.168.1.10:11434"}),")."]}),L&&(0,i.jsx)(c.Ex,{variant:"success"===L?"success":"error",children:"success"===L?"Valid":"Invalid"}),u&&(0,i.jsx)("p",{className:"text-xs text-red-500 break-words",children:u}),r&&(0,i.jsx)("p",{className:"text-xs text-text-muted",children:"Enter the model ID exactly as your compatible endpoint expects it. This model will be saved as the connection default."}),N&&(0,i.jsxs)("div",{className:"bg-sidebar/50 p-4 rounded-lg border border-accent/20",children:[(0,i.jsx)("h3",{className:"font-semibold mb-3 text-sm",children:"Cloudflare Workers AI"}),(0,i.jsx)(c.pd,{label:"Account ID",value:E.accountId,onChange:e=>R({...E,accountId:e.target.value}),placeholder:"abc123def456..."}),(0,i.jsxs)("p",{className:"text-xs text-text-muted mt-2",children:["Find your Account ID in the right sidebar of ",(0,i.jsx)("a",{href:"https://dash.cloudflare.com",target:"_blank",rel:"noopener noreferrer",className:"text-primary underline",children:"dash.cloudflare.com"})]})]}),C&&(0,i.jsxs)("div",{className:"bg-sidebar/50 p-4 rounded-lg border border-accent/20",children:[(0,i.jsx)("h3",{className:"font-semibold mb-3 text-sm",children:"AWS Bedrock Credentials"}),(0,i.jsxs)("div",{className:"flex flex-col gap-3",children:[(0,i.jsx)(c.pd,{label:"AWS Profile (SSO — recommended)",value:D.profile,onChange:e=>z({...D,profile:e.target.value}),placeholder:"my-sso-profile"}),(0,i.jsx)(c.pd,{label:"Region",value:D.region,onChange:e=>z({...D,region:e.target.value}),placeholder:"us-east-1"})]}),(0,i.jsxs)("p",{className:"text-xs text-text-muted mt-2",children:["Set a profile from ",(0,i.jsx)("code",{children:"~/.aws/config"})," and leave the API key empty, then run"," ",(0,i.jsxs)("code",{children:["aws sso login --profile ",D.profile||"my-sso-profile"]}),". Credentials refresh automatically."]}),(0,i.jsxs)("div",{className:"flex flex-col gap-3 mt-4",children:[(0,i.jsx)(c.pd,{label:"Access Key ID (only for static keys)",value:D.accessKeyId,onChange:e=>z({...D,accessKeyId:e.target.value}),placeholder:"AKIA..."}),(0,i.jsx)(c.pd,{label:"Session Token (only for temporary ASIA… keys)",type:"password",value:D.sessionToken,onChange:e=>z({...D,sessionToken:e.target.value}),placeholder:"FwoGZXIvYXdz..."})]}),(0,i.jsxs)("p",{className:"text-xs text-text-muted mt-2",children:["For static keys instead: put the AWS ",(0,i.jsx)("strong",{children:"secret"})," access key in the API Key field above and the access key id here. A profile, if set, takes precedence."]})]}),k&&(0,i.jsxs)("div",{className:"bg-sidebar/50 p-4 rounded-lg border border-accent/20",children:[(0,i.jsx)("h3",{className:"font-semibold mb-3 text-sm",children:"Azure OpenAI Configuration"}),(0,i.jsxs)("div",{className:"flex flex-col gap-3",children:[(0,i.jsx)(c.pd,{label:"Azure Endpoint",value:P.azureEndpoint,onChange:e=>I({...P,azureEndpoint:e.target.value}),placeholder:"https://your-resource.openai.azure.com"}),(0,i.jsx)(c.pd,{label:"Deployment Name",value:P.deployment,onChange:e=>I({...P,deployment:e.target.value}),placeholder:"gpt-4"}),(0,i.jsx)(c.pd,{label:"API Version",value:P.apiVersion,onChange:e=>I({...P,apiVersion:e.target.value}),placeholder:"2024-10-01-preview"}),(0,i.jsx)(c.pd,{label:"Organization",value:P.organization,onChange:e=>I({...P,organization:e.target.value}),placeholder:"Organization ID"})]})]}),(0,i.jsx)(c.pd,{label:"Priority",type:"number",value:$.priority,onChange:e=>O({...$,priority:Number.parseInt(e.target.value)||1})}),(0,i.jsx)(c.l6,{label:"Proxy Pool",value:$.proxyPoolId,onChange:e=>O({...$,proxyPoolId:e.target.value}),options:[{value:y,label:"None"},...(p||[]).map(e=>({value:e.id,label:e.name}))],placeholder:"None"}),0===(p||[]).length&&(0,i.jsx)("p",{className:"text-xs text-text-muted",children:"No active proxy pools available. Create one in Proxy Pools page first."}),(0,i.jsx)("p",{className:"text-xs text-text-muted",children:"Legacy manual proxy fields are still accepted by API for backward compatibility."}),(0,i.jsxs)("div",{className:"flex gap-2",children:[(0,i.jsx)(c.$n,{onClick:ei,fullWidth:!0,disabled:W||!b&&(!$.name||!et())||r&&!$.defaultModel.trim()||k&&(!P.azureEndpoint||!P.deployment||!P.organization)||N&&!E.accountId,children:W?"Saving...":"Save"}),(0,i.jsx)(c.$n,{onClick:g,variant:"ghost",fullWidth:!0,children:"Cancel"})]})]})]})}):null}function F({isOpen:e,node:t,onSave:s,onClose:r,isAnthropic:l}){let[n,o]=(0,a.useState)({name:"",prefix:"",apiType:"chat",baseUrl:"https://api.openai.com/v1"}),[d,m]=(0,a.useState)(!1),[p,u]=(0,a.useState)(""),[x,h]=(0,a.useState)(""),[f,g]=(0,a.useState)(!1),[y,b]=(0,a.useState)(null),[v,j]=(0,a.useState)(null);(0,a.useEffect)(()=>{j(null),t&&o({name:t.name||"",prefix:t.prefix||"",apiType:t.apiType||"chat",baseUrl:t.baseUrl||(l?"https://api.anthropic.com/v1":"https://api.openai.com/v1")})},[e,t,l]);let w=async()=>{if(n.name.trim()&&n.prefix.trim()&&n.baseUrl.trim()){m(!0),j(null);try{let e={name:n.name,prefix:n.prefix,baseUrl:n.baseUrl};l||(e.apiType=n.apiType);let t=await s(e);t?.error&&j(t.error)}finally{m(!1)}}},k=async()=>{g(!0);try{let e=await fetch("/api/provider-nodes/validate",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({baseUrl:n.baseUrl,apiKey:p,type:l?"anthropic-compatible":"openai-compatible",modelId:x.trim()||void 0})}),t=await e.json();b(t.valid?"success":"failed")}catch{b("failed")}finally{g(!1)}};return t?(0,i.jsx)(c.aF,{isOpen:e,title:`Edit ${l?"Anthropic":"OpenAI"} Compatible`,onClose:r,children:(0,i.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,i.jsx)(c.pd,{label:"Name",value:n.name,onChange:e=>o({...n,name:e.target.value}),placeholder:`${l?"Anthropic":"OpenAI"} Compatible (Prod)`,hint:"Required. A friendly label for this node."}),(0,i.jsx)(c.pd,{label:"Prefix",value:n.prefix,onChange:e=>o({...n,prefix:e.target.value}),placeholder:l?"ac-prod":"oc-prod",hint:"Required. Used as the provider prefix for model IDs. Must be a name no other provider or node already answers to."}),!l&&(0,i.jsx)(c.l6,{label:"API Type",options:[{value:"chat",label:"Chat Completions"},{value:"responses",label:"Responses API"}],value:n.apiType,onChange:e=>o({...n,apiType:e.target.value})}),(0,i.jsx)(c.pd,{label:"Base URL",value:n.baseUrl,onChange:e=>o({...n,baseUrl:e.target.value}),placeholder:l?"https://api.anthropic.com/v1":"https://api.openai.com/v1",hint:`Use the base URL (ending in /v1) for your ${l?"Anthropic":"OpenAI"}-compatible API.`}),(0,i.jsxs)("div",{className:"flex gap-2",children:[(0,i.jsx)(c.pd,{label:"API Key (for Check)",type:"password",value:p,onChange:e=>u(e.target.value),className:"flex-1"}),(0,i.jsx)("div",{className:"pt-6",children:(0,i.jsx)(c.$n,{onClick:k,disabled:!p||f||!n.baseUrl.trim(),variant:"secondary",children:f?"Checking...":"Check"})})]}),(0,i.jsx)(c.pd,{label:"Model ID (optional)",value:x,onChange:e=>h(e.target.value),placeholder:"e.g. my-model-id",hint:"If provider lacks /models endpoint, enter a model ID to validate via chat/completions instead."}),y&&(0,i.jsx)(c.Ex,{variant:"success"===y?"success":"error",children:"success"===y?"Valid":"Invalid"}),v&&(0,i.jsx)("p",{className:"text-xs text-red-500",children:v}),(0,i.jsxs)("div",{className:"flex gap-2",children:[(0,i.jsx)(c.$n,{onClick:w,fullWidth:!0,disabled:!n.name.trim()||!n.prefix.trim()||!n.baseUrl.trim()||d,children:d?"Saving...":"Save"}),(0,i.jsx)(c.$n,{onClick:r,variant:"ghost",fullWidth:!0,children:"Cancel"})]})]})}):null}U.propTypes={isOpen:P().bool.isRequired,provider:P().string,providerName:P().string,isCompatible:P().bool,isAnthropic:P().bool,authType:P().string,authHint:P().string,website:P().string,proxyPools:P().arrayOf(P().shape({id:P().string,name:P().string})),error:P().string,existingNames:P().arrayOf(P().string),onSave:P().func.isRequired,onBulkDone:P().func,onClose:P().func.isRequired},F.propTypes={isOpen:P().bool.isRequired,node:P().shape({id:P().string,name:P().string,prefix:P().string,apiType:P().string,baseUrl:P().string}),onSave:P().func.isRequired,onClose:P().func.isRequired,isAnthropic:P().bool};let K=()=>Object.fromEntries(Object.keys(p.bs).map(e=>[e,!1]));function L({isOpen:e,providerAlias:t,providerDisplayAlias:s,onSave:r,onClose:l}){let[n,o]=(0,a.useState)(""),[d,m]=(0,a.useState)(K),[u,x]=(0,a.useState)(null),[h,f]=(0,a.useState)(""),[g,y]=(0,a.useState)(!1),[b,v]=(0,a.useState)("");(0,a.useEffect)(()=>{e&&(o(""),m(K()),v(""),x(null),f(""))},[e]);let j=e=>{let s=`${t}/`;return e.startsWith(s)?e.slice(s.length):e},w=async()=>{let e=j(n.trim());if(e){x("testing"),f("");try{let s=await fetch("/api/models/test",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({model:`${t}/${e}`})}),i=await s.json();x(i.ok?"ok":"error"),f(i.error||"")}catch(e){x("error"),f(e.message)}}},k=async()=>{let e=j(n.trim());if(e&&!g){y(!0);try{await r(e,d,d.stt?b:null)}finally{y(!1)}}};return(0,i.jsx)(c.aF,{isOpen:e,onClose:l,title:"Add Custom Model",children:(0,i.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,i.jsxs)("div",{children:[(0,i.jsx)("label",{className:"text-sm font-medium mb-1.5 block",children:"Model ID"}),(0,i.jsxs)("div",{className:"flex gap-2",children:[(0,i.jsx)("input",{type:"text",value:n,onChange:e=>{o(e.target.value),x(null),f("")},onKeyDown:e=>{"Enter"===e.key&&w()},placeholder:"e.g. claude-opus-4-5",className:"flex-1 px-3 py-2 text-sm border border-border rounded-lg bg-background focus:outline-none focus:border-primary",autoFocus:!0}),(0,i.jsx)(c.$n,{variant:"secondary",icon:"science",loading:"testing"===u,onClick:w,disabled:!n.trim()||"testing"===u,children:"testing"===u?"Testing...":"Test"})]}),(0,i.jsxs)("p",{className:"text-xs text-text-muted mt-1",children:["Sent to provider as: ",(0,i.jsx)("code",{className:"font-mono bg-sidebar px-1 rounded",children:j(n.trim())||"model-id"})]})]}),(0,i.jsxs)("div",{children:[(0,i.jsx)("label",{className:"text-sm font-medium mb-1.5 block",children:"Capabilities"}),(0,i.jsx)("div",{className:"flex flex-wrap gap-4",children:Object.entries(p.bs).map(([e,t])=>(0,i.jsx)(c.lM,{checked:!!d[e],onChange:t=>m(s=>({...s,[e]:t})),label:t.label,description:t.desc,size:"sm"},e))})]}),(0,i.jsxs)("div",{children:[(0,i.jsx)(c.lM,{checked:!!d.stt,onChange:e=>{m(t=>({...t,stt:e})),e||v("")},label:"Speech to text",description:"Transcribes audio via /v1/audio/transcriptions",size:"sm"}),d.stt&&(0,i.jsx)("div",{className:"mt-3",children:(0,i.jsx)(c.l6,{label:"Transport",value:b,onChange:e=>v(e.target.value),placeholder:"Provider default (REST)",options:p.vp.map(e=>({value:e,label:p.qw[e].label})),hint:"Realtime transport marker for the STT dispatcher. Empty keeps the provider's REST format."})})]}),"ok"===u&&(0,i.jsxs)("div",{className:"flex items-center gap-2 text-sm text-green-600",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-base",children:"check_circle"}),"Model is reachable"]}),"error"===u&&(0,i.jsxs)("div",{className:"flex items-start gap-2 text-sm text-red-500",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-base shrink-0",children:"cancel"}),(0,i.jsx)("span",{children:h||"Model not reachable"})]}),(0,i.jsxs)("div",{className:"flex gap-2 pt-1",children:[(0,i.jsx)(c.$n,{onClick:l,variant:"ghost",fullWidth:!0,size:"sm",children:"Cancel"}),(0,i.jsx)(c.$n,{onClick:k,fullWidth:!0,size:"sm",disabled:!n.trim()||g,children:g?"Adding...":"Add Model"})]})]})})}L.propTypes={isOpen:P().bool.isRequired,providerAlias:P().string.isRequired,providerDisplayAlias:P().string.isRequired,onSave:P().func.isRequired,onClose:P().func.isRequired};let J=`[
|
|
8
|
+
{
|
|
9
|
+
"accessToken": "eyJhbGc...",
|
|
10
|
+
"refreshToken": "rt_...",
|
|
11
|
+
"idToken": "eyJhbGc...",
|
|
12
|
+
"email": "user@example.com"
|
|
13
|
+
}
|
|
14
|
+
]`;function W({isOpen:e,onClose:t,onSuccess:s}){let[r,l]=(0,a.useState)(""),[n,o]=(0,a.useState)(!1),[d,m]=(0,a.useState)(""),[p,u]=(0,a.useState)(null),x=()=>{n||(l(""),m(""),u(null),t())},h=async()=>{var e;let t;m(""),u(null);let i=r.trim();if(!i)return;try{t=JSON.parse(i)}catch(e){m(`${(0,S.Tl)("Invalid JSON")}: ${e.message}`);return}let a=Array.isArray(e=t)?e:e&&"object"==typeof e?Array.isArray(e.accounts)?e.accounts:[e]:null;if(!a||0===a.length)return void m((0,S.Tl)("No accounts found in input"));o(!0);try{let e=await fetch("/api/oauth/codex/bulk-import",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({accounts:a})}),t=await e.json();if(!e.ok)return void m(t?.error||`Request failed: ${e.status}`);u(t),t.success>0&&"function"==typeof s&&s()}catch(e){m(e.message||(0,S.Tl)("Request failed"))}finally{o(!1)}},f=p?.results?.filter(e=>!e.ok)||[];return(0,i.jsx)(c.aF,{isOpen:e,title:(0,S.Tl)("Bulk Add Codex Accounts"),onClose:x,children:(0,i.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,i.jsx)("p",{className:"text-xs text-text-muted",children:(0,S.Tl)("Paste an array of codex account JSON objects. Each must include accessToken (and ideally refreshToken, idToken).")}),(0,i.jsx)("textarea",{className:"w-full rounded border border-accent/30 bg-sidebar p-2 text-sm font-mono resize-y min-h-[240px] focus:outline-none focus:ring-1 focus:ring-primary",placeholder:J,value:r,onChange:e=>l(e.target.value),disabled:n}),d&&(0,i.jsx)("p",{className:"text-xs text-red-500 break-words",children:d}),p&&(0,i.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,i.jsxs)("div",{className:`text-sm font-medium ${p.failed>0?"text-yellow-400":"text-green-400"}`,children:["✓ ",p.success," ",(0,S.Tl)("added"),p.failed>0?`, ✗ ${p.failed} ${(0,S.Tl)("failed")}`:""]}),f.length>0&&(0,i.jsx)("ul",{className:"rounded border border-accent/20 bg-sidebar/50 p-2 text-xs font-mono max-h-40 overflow-y-auto",children:f.map(e=>(0,i.jsxs)("li",{className:"text-red-400",children:["[",e.index,"] ",e.error]},e.index))})]}),(0,i.jsxs)("div",{className:"flex gap-2",children:[(0,i.jsx)(c.$n,{onClick:h,fullWidth:!0,disabled:n||!r.trim(),children:n?(0,S.Tl)("Importing..."):(0,S.Tl)("Import All")}),(0,i.jsx)(c.$n,{onClick:x,variant:"ghost",fullWidth:!0,disabled:n,children:(0,S.Tl)("Close")})]})]})})}W.propTypes={isOpen:P().bool.isRequired,onClose:P().func.isRequired,onSuccess:P().func};let H=`[
|
|
15
|
+
{
|
|
16
|
+
"access_token": "eyJ0eXAiOiJhdCtqd3Qi...",
|
|
17
|
+
"refresh_token": "LZhriF9bf88pPykpXCuZ9...",
|
|
18
|
+
"id_token": "eyJ0eXAiOiJKV1QiLCJhbGci...",
|
|
19
|
+
"email": "account1@example.com"
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
"access_token": "eyJ0eXAiOiJhdCtqd3Qi...",
|
|
23
|
+
"refresh_token": "LZhriF9bf88pPykpXCuZ9...",
|
|
24
|
+
"id_token": "eyJ0eXAiOiJKV1QiLCJhbGci...",
|
|
25
|
+
"email": "account2@example.com"
|
|
26
|
+
}
|
|
27
|
+
]`;function B(e){let t,s=e.trim();if(!s)return[];try{t=JSON.parse(s)}catch(e){try{let e=s;e.startsWith("[")||((e=e.replace(/\}\s*,\s*\{/g,"},{").replace(/\}\s*\{/g,"},{")).endsWith(",")&&(e=e.slice(0,-1)),e=`[${e}]`),t=JSON.parse(e)}catch{throw e}}if(Array.isArray(t))return t;if(t&&"object"==typeof t)return Array.isArray(t.accounts)?t.accounts:[t];throw Error("Input must be a JSON object or array of objects")}function G({isOpen:e,onClose:t,onSuccess:s}){let[r,l]=(0,a.useState)(""),[n,o]=(0,a.useState)(!1),[d,m]=(0,a.useState)(""),[p,u]=(0,a.useState)(null),[x,h]=(0,a.useState)(!1),[f,g]=(0,a.useState)(null),y=(0,a.useRef)(null),b=()=>{n||(l(""),m(""),u(null),g(null),h(!1),t())},v=async e=>{if(!e||0===e.length)return;m("");let t=Array.from(e).filter(e=>e.name.endsWith(".json")||"application/json"===e.type||""===e.type);if(0===t.length)return void m((0,S.Tl)("Please select valid .json files"));try{let e=[];for(let s of t){let t=await s.text(),i=B(t);Array.isArray(i)?e.push(...i):i&&e.push(i)}if(0===e.length)return void m((0,S.Tl)("No accounts found in selected files"));l(JSON.stringify(e,null,2)),g({filesCount:t.length,accountsCount:e.length})}catch(e){m(`${(0,S.Tl)("Error reading files")}: ${e.message}`)}},j=async()=>{let e;m(""),u(null);try{e=B(r)}catch(e){m(`${(0,S.Tl)("Invalid JSON")}: ${e.message}`);return}if(!e||0===e.length)return void m((0,S.Tl)("No accounts found in input"));o(!0);try{let t=await fetch("/api/oauth/grok-cli/bulk-import",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({accounts:e})}),i=await t.json();if(!t.ok)return void m(i?.error||`Request failed: ${t.status}`);u(i),i.success>0&&"function"==typeof s&&s()}catch(e){m(e.message||(0,S.Tl)("Request failed"))}finally{o(!1)}},w=p?.results?.filter(e=>!e.ok)||[];return(0,i.jsx)(c.aF,{isOpen:e,title:(0,S.Tl)("Bulk Add Grok CLI Accounts"),onClose:b,children:(0,i.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,i.jsxs)("div",{className:"flex flex-wrap items-center justify-between gap-2",children:[(0,i.jsx)("p",{className:"text-xs text-text-muted",children:(0,S.Tl)("Upload multiple .json files or paste JSON array / object.")}),(0,i.jsx)("input",{ref:y,type:"file",accept:".json,application/json",multiple:!0,className:"hidden",onChange:e=>{v(e.target.files),e.target&&(e.target.value="")}}),(0,i.jsx)(c.$n,{type:"button",size:"sm",variant:"secondary",icon:"upload_file",onClick:()=>y.current?.click(),disabled:n,children:(0,S.Tl)("Upload JSON Files")})]}),(0,i.jsxs)("div",{onDragOver:e=>{e.preventDefault(),h(!0)},onDragLeave:e=>{e.preventDefault(),h(!1)},onDrop:e=>{e.preventDefault(),h(!1),e.dataTransfer?.files?.length>0&&v(e.dataTransfer.files)},className:`relative rounded border transition-colors ${x?"border-primary bg-primary/10 ring-2 ring-primary/30":"border-accent/30 bg-sidebar"}`,children:[(0,i.jsx)("textarea",{className:"w-full rounded bg-transparent p-2.5 text-sm font-mono resize-y min-h-[240px] focus:outline-none focus:ring-1 focus:ring-primary",placeholder:H,value:r,onChange:e=>{l(e.target.value),g(null)},disabled:n}),x&&(0,i.jsxs)("div",{className:"absolute inset-0 flex flex-col items-center justify-center bg-sidebar/90 rounded pointer-events-none backdrop-blur-xs",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-3xl text-primary mb-1",children:"upload_file"}),(0,i.jsx)("span",{className:"text-sm font-medium text-primary",children:(0,S.Tl)("Drop .json files here")})]})]}),f&&(0,i.jsxs)("div",{className:"flex items-center gap-1.5 text-xs text-green-400 font-medium bg-green-500/10 border border-green-500/20 px-2.5 py-1.5 rounded",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-sm",children:"check_circle"}),(0,i.jsxs)("span",{children:[(0,S.Tl)("Loaded")," ",f.accountsCount," ",(0,S.Tl)("account(s) from")," ",f.filesCount," ",(0,S.Tl)("file(s)")]})]}),d&&(0,i.jsx)("p",{className:"text-xs text-red-500 break-words",children:d}),p&&p.failed>0&&(0,i.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,i.jsxs)("div",{className:"text-sm font-medium text-yellow-400",children:["✗ ",p.failed," ",(0,S.Tl)("failed")]}),w.length>0&&(0,i.jsx)("ul",{className:"rounded border border-accent/20 bg-sidebar/50 p-2 text-xs font-mono max-h-40 overflow-y-auto",children:w.map(e=>(0,i.jsxs)("li",{className:"text-red-400",children:["[",e.index,"] ",e.error]},e.index))})]}),(0,i.jsxs)("div",{className:"flex gap-2",children:[(0,i.jsx)(c.$n,{onClick:j,fullWidth:!0,disabled:n||!r.trim(),children:n?(0,S.Tl)("Importing..."):(0,S.Tl)("Import All")}),(0,i.jsx)(c.$n,{onClick:b,variant:"ghost",fullWidth:!0,disabled:n,children:(0,S.Tl)("Close")})]})]})})}var Z=s(65921);let V=["host","content-length","content-type","connection","transfer-encoding","authorization","cookie"],Q=/^[A-Za-z0-9-]+$/;function X({providerId:e}){let t=(0,Z.i)(),[s,r]=(0,a.useState)(!1),[l,n]=(0,a.useState)([{name:"",value:""}]),[o,d]=(0,a.useState)({}),[m,p]=(0,a.useState)(!1),[u,x]=(0,a.useState)(!1);(0,a.useEffect)(()=>{let t=!1;return fetch(`/api/providers/${e}/overrides`,{cache:"no-store"}).then(e=>e.ok?e.json():null).then(e=>{if(t||!e)return;let s=e.builtinHeaders||{},i=Object.entries({...s,...e.headers||{}}).map(([e,t])=>({name:e,value:t}));d(s),n(i.length?i:[{name:"",value:""}]),p(Object.keys(e.headers||{}).length>0)}).catch(()=>{}),()=>{t=!0}},[e]);let h=(e,t,s)=>{n(i=>i.map((i,a)=>a===e?{...i,[t]:s}:i))},f=(0,a.useCallback)(async()=>{let s={};for(let e of l.filter(e=>e.name.trim())){let i=e.name.trim();if(!Q.test(i))return void t.error(`Invalid header name: ${i}`);if(V.includes(i.toLowerCase()))return void t.error(`Header ${i} cannot be overridden`);if(i in s)return void t.error(`Duplicate header name: ${i}`);e.value!==o[i]&&(s[i]=e.value)}x(!0);try{let i=await fetch(`/api/providers/${e}/overrides`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({headers:s})});if(!i.ok){let e=await i.json().catch(()=>({}));t.error(e.error||"Failed to save");return}p(Object.keys(s).length>0),t.success("Custom headers saved")}finally{x(!1)}},[l,o,e,t]);return 0!==Object.keys(o).length||m?(0,i.jsxs)(c.Zp,{padding:"xs",children:[(0,i.jsxs)("button",{type:"button",onClick:()=>r(e=>!e),className:"flex w-full items-center justify-between text-left",children:[(0,i.jsxs)("div",{className:"flex items-center gap-2",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-primary text-[20px]",children:"tune"}),(0,i.jsx)("span",{className:"text-sm font-semibold",children:"Custom Headers"}),m&&(0,i.jsx)(c.Ex,{variant:"success",size:"sm",children:"Active"})]}),(0,i.jsx)("span",{className:"material-symbols-outlined text-text-muted",children:s?"expand_less":"expand_more"})]}),s&&(0,i.jsxs)("div",{className:"mt-3 border-t border-border pt-3",children:[(0,i.jsx)("div",{className:"flex flex-col gap-2",children:l.map((e,t)=>{let s=e.name.trim()in o&&e.value!==o[e.name.trim()];return(0,i.jsxs)("div",{className:"flex items-center gap-2",children:[(0,i.jsx)("input",{value:e.name,onChange:e=>h(t,"name",e.target.value),placeholder:"Header-Name",spellCheck:!1,className:"w-44 rounded-md border border-border bg-background px-2 py-1.5 text-sm focus:border-primary focus:outline-none"}),(0,i.jsx)("input",{value:e.value,onChange:e=>h(t,"value",e.target.value),placeholder:"Value",spellCheck:!1,title:s?"Overridden":e.name.trim()in o?"Registry default":"",className:`min-w-0 flex-1 rounded-md border bg-background px-2 py-1.5 text-sm focus:border-primary focus:outline-none ${s?"border-amber-400/60":"border-border"}`}),(0,i.jsx)("button",{type:"button",title:"Remove header",onClick:()=>n(e=>e.length>1?e.filter((e,s)=>s!==t):[{name:"",value:""}]),className:"shrink-0 text-text-muted hover:text-red-500",children:(0,i.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:"delete"})})]},t)})}),(0,i.jsxs)("div",{className:"mt-3 flex items-center justify-between gap-2",children:[(0,i.jsxs)("button",{type:"button",onClick:()=>n(e=>[...e,{name:"",value:""}]),className:"flex items-center gap-1 text-xs text-primary hover:underline",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-[16px]",children:"add"}),"Add header"]}),(0,i.jsxs)("div",{className:"flex gap-2",children:[(0,i.jsx)("button",{type:"button",disabled:u,onClick:()=>{n(Object.entries(o).map(([e,t])=>({name:e,value:t})))},className:"rounded-md border border-border px-3 py-1.5 text-xs hover:bg-black/[0.03] dark:hover:bg-white/[0.03] disabled:opacity-50",children:"Reset"}),(0,i.jsx)("button",{type:"button",disabled:u,onClick:f,className:"rounded-md bg-primary px-3 py-1.5 text-xs font-medium text-white hover:opacity-90 disabled:opacity-50",children:u?"Saving...":"Save"})]})]})]})]}):null}X.propTypes={providerId:P().string.isRequired};var Y=s(97132),ee=s(5539),et=s(93195);let es={claude:"claudeAutoPing",codex:"codexAutoPing"},ei={qoder:"Fetch Qoder Models","qoder-cn":"Fetch Qoder Models","trae-enterprise":"Fetch Trae Enterprise Models",codearts:"Fetch CodeArts Models",minimax:"Fetch MiniMax Models","minimax-cn":"Fetch MiniMax Models"};function ea(){let e,t,s,l,u,x=(0,r.useParams)(),h=(0,r.useRouter)(),f=x.id,{getCaps:g}=(0,C.y)(),[y,b]=(0,a.useState)([]),[v,j]=(0,a.useState)(!0),[w,A]=(0,a.useState)(null),[O,P]=(0,a.useState)([]),[E,D]=(0,a.useState)(!1),[z,_]=(0,a.useState)(!1),[q,K]=(0,a.useState)(!1),[J,H]=(0,a.useState)(!1),[B,Z]=(0,a.useState)(""),[V,Q]=(0,a.useState)(!1),[ea,er]=(0,a.useState)(!1),[el,en]=(0,a.useState)(!1),[eo,ed]=(0,a.useState)(!1),[ec,em]=(0,a.useState)(!1),[ep,eu]=(0,a.useState)(null),[ex,eh]=(0,a.useState)({}),[ef,eg]=(0,a.useState)([]),[ey,eb]=(0,a.useState)(!1),[ev,ej]=(0,a.useState)({}),[ew,ek]=(0,a.useState)(""),[eN,eC]=(0,a.useState)(()=>new Set),[eS,eA]=(0,a.useState)(!1),[eT,e$]=(0,a.useState)([]),[eO,eP]=(0,a.useState)("__none__"),[eI,eE]=(0,a.useState)(!1),[eR,eD]=(0,a.useState)(null),[ez,e_]=(0,a.useState)(""),[eM,eq]=(0,a.useState)("auto"),[eU,eF]=(0,a.useState)({enabled:!1,connections:{},schedules:{}}),[eK,eL]=(0,a.useState)(null),[eJ,eW]=(0,a.useState)([]),[eH,eB]=(0,a.useState)([]),[eG,eZ]=(0,a.useState)(null),[eV,eQ]=(0,a.useState)([]),[eX,eY]=(0,a.useState)([]),[e0,e1]=(0,a.useState)(null),[e2,e5]=(0,a.useState)(!1),[e3,e4]=(0,a.useState)(!1),[e6,e8]=(0,a.useState)(!1),[e9,e7]=(0,a.useState)(null),[te,tt]=(0,a.useState)({}),[ts,ti]=(0,a.useState)(null),ta=(0,a.useRef)(!1),[tr,tl]=(0,a.useState)(!1),[tn,to]=(0,a.useState)(!1),{copied:td,copy:tc}=(0,N.C)(),tm="ag_risk_confirmed",tp=()=>{D(!0)},tu=()=>{"antigravity"===f&&"true"!==window.localStorage.getItem(tm)?e5(!0):"xiaomi-mimo"===f?_(!0):ty?tp():(Z(""),H(!0))},tx=()=>{Z(""),H(!0)},th=()=>{ty?tu():tx()},tf=w?{id:w.id,name:w.name||("anthropic-compatible"===w.type?"Anthropic Compatible":"OpenAI Compatible"),color:"anthropic-compatible"===w.type?"#D97757":"#10A37F",textIcon:"anthropic-compatible"===w.type?"AC":"OC",apiType:w.apiType,baseUrl:w.baseUrl,type:w.type}:m.zN[f]||m.fg[f]||m.IS[f]||m.nJ[f]||m.br[f],tg=tf?.authModes||[],ty=!!m.zN[f]||!!m.IS[f]||tg.includes("oauth"),tb=!!m.fg[f]||tg.includes("apikey"),tv=!!m.IS[f]?.noAuth,tj="antigravity"===f||"gemini-cli"===f,tw=(0,p.KC)(f),tk=("cursor"===f||"zed"===f)&&eH.length>0?eH:tw,tN=(0,m.wG)(f),tC=(0,m.mq)(f),tS=(0,m.gb)(f),tA=tC||tS,tT=!tA&&ty&&tb,t$="xai"===f?"Grok Build OAuth":"grok-cli"===f?"Grok CLI Device Login":"kimi"===f?"Kimi Coding OAuth":"OAuth",tO="xai"===f?"xAI API Key":"kimi"===f?"Kimi API Key":"qoder"===f||"qoder-cn"===f?"PAT":"API Key",tP=e=>{if(!eM||"auto"===eM)return null;let t=k(f,e);return t&&t.includes(eM)?eM:null},tI=tA?f:tN,tE=(()=>{let e=new Set,t=new Set,s=s=>{if(!s||t.has(s))return;t.add(s);let i=k(f,s);i&&i.forEach(t=>{"none"!==t&&e.add(t)})};for(let e of tk)s(e.id);for(let e of eV)s(e.id);for(let e of ef)e.providerAlias===tI&&"llm"===(e.kind||e.type||"llm")&&s(e.id);return e.size?["auto",...e]:null})(),tR=tA?w?.prefix||f:tN,tD=(0,a.useCallback)(async()=>{try{let e=await fetch(`/api/models/disabled?providerAlias=${encodeURIComponent(tI)}`,{cache:"no-store"}),t=await e.json();e.ok&&eY(t.ids||[])}catch(e){console.log("Error fetching disabled models:",e)}},[tI]),tz=async e=>{try{(await fetch("/api/models/disabled",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({providerAlias:tI,ids:[e]})})).ok&&await tD()}catch(e){console.log("Error disabling model:",e)}},t_=async e=>{try{(await fetch(`/api/models/disabled?providerAlias=${encodeURIComponent(tI)}&id=${encodeURIComponent(e)}`,{method:"DELETE"})).ok&&await tD()}catch(e){console.log("Error enabling model:",e)}},tM=async e=>{e.length&&e1({title:"Disable All Models",message:`Disable all ${e.length} model(s)?`,onConfirm:async()=>{e1(null);try{(await fetch("/api/models/disabled",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({providerAlias:tI,ids:e})})).ok&&await tD()}catch(e){console.log("Error disabling all models:",e)}}})},tq=async()=>{try{(await fetch(`/api/models/disabled?providerAlias=${encodeURIComponent(tI)}`,{method:"DELETE"})).ok&&await tD()}catch(e){console.log("Error enabling all models:",e)}},tU=(0,a.useCallback)(async()=>{try{let e=await fetch("/api/models/alias"),t=await e.json();e.ok&&eh(t.aliases||{})}catch(e){console.log("Error fetching aliases:",e)}},[]),tF=(0,a.useCallback)(async()=>{try{let e=await fetch("/api/models/custom",{cache:"no-store"}),t=await e.json();e.ok&&eg(t.models||[])}catch(e){console.log("Error fetching custom models:",e)}},[]);(0,a.useEffect)(()=>{"kilocode"===f&&fetch("/api/providers/kilo/free-models").then(e=>e.json()).then(e=>{e.models?.length&&eQ(e.models)}).catch(()=>{})},[f]);let tK=(0,a.useCallback)(async()=>{try{let[e,t,s,i]=await Promise.all([fetch("/api/providers",{cache:"no-store"}),fetch("/api/provider-nodes",{cache:"no-store"}),fetch("/api/proxy-pools?isActive=true",{cache:"no-store"}),fetch("/api/settings",{cache:"no-store"})]),a=await e.json(),r=await t.json(),l=await s.json(),n=i.ok?await i.json():{};if(e.ok){let e=(a.connections||[]).filter(e=>e.provider===f);b(e)}s.ok&&P(l.proxyPools||[]);let o=(n.providerStrategies||{})[f]||{};eD(o.fallbackStrategy||null),e_(null!=o.stickyRoundRobinLimit?String(o.stickyRoundRobinLimit):"1");let d=(n.providerThinking||{})[f]||{};eq(d.mode||"auto");let c=es[f],m=c&&n[c]||{};if(eF({enabled:!0===m.enabled,connections:m.connections||{},schedules:m.schedules||{}}),t.ok){let e=(r.nodes||[]).find(e=>e.id===f)||null;if(!e&&tA)for(let t=0;t<3;t+=1){await new Promise(e=>setTimeout(e,150));let t=await fetch("/api/provider-nodes",{cache:"no-store"});if(t.ok&&(e=((await t.json()).nodes||[]).find(e=>e.id===f)||null))break}A(e)}}catch(e){console.log("Error fetching connections:",e)}finally{j(!1)}},[f,tA]),tL=async e=>{try{let t=await fetch(`/api/provider-nodes/${f}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)}),s=await t.json();if(!t.ok)return{error:s.error||"Failed to update provider node"};A(s.node),await tK(),ed(!1)}catch(e){return console.log("Error updating provider node:",e),{error:"Failed to update provider node"}}return null},tJ=async(e,t)=>{try{let s=await fetch("/api/settings",{cache:"no-store"}),i=(s.ok?await s.json():{}).providerStrategies||{},a={};e&&(a.fallbackStrategy=e),"round-robin"===e&&""!==t&&(a.stickyRoundRobinLimit=Number(t)||3);let r={...i};0===Object.keys(a).length?delete r[f]:r[f]=a,await fetch("/api/settings",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({providerStrategies:r})})}catch(e){console.log("Error saving provider strategy:",e)}},tW=async e=>{try{let t=await fetch("/api/settings",{cache:"no-store"}),s={...(t.ok?await t.json():{}).providerThinking||{}};e&&"auto"!==e?s[f]={mode:e}:delete s[f],await fetch("/api/settings",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({providerThinking:s})})}catch(e){console.log("Error saving thinking config:",e)}},tH=async e=>{let t=es[f];if(t){eF(e);try{await fetch("/api/settings",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({[t]:e})})}catch(e){console.log("Error saving auto-ping config:",e)}}};(0,a.useEffect)(()=>{tK(),tU(),tF(),tD()},[tK,tU,tF,tD]),(0,a.useEffect)(()=>{if("cursor"!==f&&"zed"!==f)return void eB([]);let e=y.find(e=>!1!==e.isActive);if(!e?.id){eB([]),"zed"===f&&eZ(null);return}let t=!1;return"zed"===f&&eZ(null),fetch(`/api/providers/${e.id}/models`,{cache:"no-store"}).then(async e=>({ok:e.ok,data:await e.json().catch(()=>null)})).then(({ok:e,data:s})=>{if(!t){if(e&&Array.isArray(s?.models)&&s.models.length>0){eB(s.models),"zed"===f&&s?.warning&&eZ(s.warning);return}"zed"===f&&(eB([]),eZ(s?.warning||s?.error||"Zed returned no live models."))}}).catch(()=>{t||"zed"!==f||(eB([]),eZ("Failed to reach the Zed model catalog."))}),()=>{t=!0}},[f,y]),(0,a.useEffect)(()=>{let e=(m.zN[f]||m.fg[f]||m.IS[f]||m.nJ[f])?.modelsFetcher;e&&T(e).then(eW)},[f]);let tB=async(e,t,s=tN)=>{let i=`${s}/${e}`;try{let e=await fetch("/api/models/alias",{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({model:i,alias:t})});if(e.ok)await tU();else{let t=await e.json();alert(t.error||"Failed to set alias")}}catch(e){console.log("Error setting alias:",e)}},tG=async e=>{try{(await fetch(`/api/models/alias?alias=${encodeURIComponent(e)}`,{method:"DELETE"})).ok&&await tU()}catch(e){console.log("Error deleting alias:",e)}},tZ=async(e,t="llm",s=tI,i,a)=>{try{let r=await fetch("/api/models/custom",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({providerAlias:s,id:e,type:t,...i?{caps:i}:{},...a?{transport:a}:{}})});if(r.ok)await tF(),window.dispatchEvent(new CustomEvent("customModelChanged"));else{let e=await r.json();alert(e.error||"Failed to add custom model")}}catch(e){console.log("Error adding custom model:",e)}},tV=async(e,t="llm",s=tI)=>{try{let i=new URLSearchParams({providerAlias:s,id:e,type:t});(await fetch(`/api/models/custom?${i}`,{method:"DELETE"})).ok&&(await tF(),window.dispatchEvent(new CustomEvent("customModelChanged")))}catch(e){console.log("Error deleting custom model:",e)}},tQ=async()=>{if(tr)return;let e=y.find(e=>!1!==e.isActive);if(!e)return void alert((0,S.Tl)("Please add an active connection first"));tl(!0);try{let t=await fetch(`/api/providers/${e.id}/models`),s=await t.json();if(!t.ok)return void alert(s.error||(0,S.Tl)("Failed to fetch models"));let i=s.models||[];if(0===i.length)return void alert((0,S.Tl)("No models returned"));let a=0,r=new Set(tw.map(e=>e.id));for(let e of i){let t=e.id||e.name;if(!t)continue;let s=`${f}/`,i=t.startsWith(s)?t.slice(s.length):t;ef.some(e=>e.providerAlias===tI&&e.id===i&&"llm"===(e.kind||e.type||"llm"))||Object.values(ex).includes(`${tI}/${i}`)||r.has(i)||(await tZ(i,"llm",tI),a+=1)}0===a?alert((0,S.Tl)("All models already exist, no new models added")):alert((0,S.Tl)("Successfully added")+` ${a} `+(0,S.Tl)("models"))}catch(e){console.log("Error importing live models:",e),alert((0,S.Tl)("Error fetching models")+": "+e.message)}finally{tl(!1)}},tX=async()=>{if(tn)return;let e=y.find(e=>!1!==e.isActive);if(!e)return void alert((0,S.Tl)("Please add an active Cline connection first"));to(!0);try{let t=await fetch(`/api/providers/${e.id}/models`),s=await t.json();if(!t.ok)return void alert(s.error||(0,S.Tl)("Failed to fetch models"));let i=s.models||[];if(0===i.length)return void alert((0,S.Tl)("No models returned"));let a=0;for(let e of i){let t=e.id||e.name;t&&(ef.some(e=>e.providerAlias===tI&&e.id===t&&"llm"===(e.kind||e.type||"llm"))||Object.values(ex).includes(`${tI}/${t}`)||(await tZ(t,"llm",tI),a+=1))}0===a?alert((0,S.Tl)("All models already exist, no new models added")):alert((0,S.Tl)("Successfully added")+` ${a} `+(0,S.Tl)("models"))}catch(e){console.log("Error importing Cline models:",e),alert((0,S.Tl)("Error fetching models")+": "+e.message)}finally{to(!1)}},tY=async()=>{if(e3||0===y.length)return;let e=Object.fromEntries(y.map(e=>[e.id,{state:"queued",error:null}]));ta.current=!1,e4(!0),e8(!1),e7(null),tt(e),ti({total:y.length,completed:0,passed:0,failed:0,stopped:!1});let t=0,s=0;try{for(let e=0;e<y.length;e+=1){if(ta.current){ti({total:y.length,completed:e,passed:t,failed:s,stopped:!0});break}let i=y[e];e7(i.id),tt(e=>({...e,[i.id]:{state:"testing",error:null}}));try{let e=await fetch(`/api/providers/${i.id}/test`,{method:"POST"}),a=await e.json(),r=!!a.valid;r?t+=1:s+=1,tt(e=>({...e,[i.id]:{state:r?"success":"failed",error:r?null:a.error||null}}))}catch(e){s+=1,tt(t=>({...t,[i.id]:{state:"failed",error:e.message||"Test failed"}}))}ti({total:y.length,completed:e+1,passed:t,failed:s,stopped:!1}),e<y.length-1&&await new Promise(e=>setTimeout(e,1e3))}}finally{e7(null),e4(!1),e8(!1),ta.current=!1}},t0=async e=>{e1({title:"Delete Connection",message:"Delete this connection?",onConfirm:async()=>{e1(null);try{(await fetch(`/api/providers/${e}`,{method:"DELETE"})).ok&&b(t=>t.filter(t=>t.id!==e))}catch(e){console.log("Error deleting connection:",e)}}})},t1=()=>{tK(),D(!1)},t2=async e=>{Z("");try{let t=await fetch("/api/providers",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({provider:f,...e})}),s=null;try{s=await t.json()}catch{s=null}if(t.ok){await tK(),H(!1);return}Z(s?.error||"Failed to save connection")}catch(e){console.log("Error saving connection:",e),Z("Failed to save connection")}},t5=async e=>{try{(await fetch(`/api/providers/${ep.id}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify(e)})).ok&&(await tK(),en(!1))}catch(e){console.log("Error updating connection:",e)}},t3=async(e,t)=>{try{(await fetch(`/api/providers/${e}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({isActive:t})})).ok&&b(s=>s.map(s=>s.id===e?{...s,isActive:t}:s))}catch(e){console.log("Error updating connection status:",e)}},t4=async(e,t)=>{let s=[...y];[s[e],s[t]]=[s[t],s[e]],b(s);try{await Promise.all([fetch(`/api/providers/${s[e].id}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({priority:e})}),fetch(`/api/providers/${s[t].id}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({priority:t})})])}catch(e){console.log("Error swapping priority:",e),await tK()}},t6=y.filter(e=>eT.includes(e.id)),t8=y.length>0&&eT.length===y.length;(0,a.useEffect)(()=>{e$(e=>e.filter(e=>y.some(t=>t.id===e)))},[y]),(()=>{if(0===t6.length)return;let e=new Set(t6.map(e=>e.providerSpecificData?.proxyPoolId||"__none__"));if(1===e.size){let t=[...e][0];if("__none__"===t)return;let s=O.find(e=>e.id===t);return s?.name}})();let t9=()=>{eI||em(!1)},t7=async e=>{eE(!0);try{let t=0;for(let{connectionId:s,proxyPoolId:i}of e)try{(await fetch(`/api/providers/${s}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({proxyPoolId:i})})).ok||(t+=1)}catch(e){console.log("Error applying proxy for",s,e),t+=1}t>0&&alert(`Updated with ${t} failed request(s).`),await tK(),em(!1)}finally{eE(!1)}},se=e=>t7(y.map(t=>({connectionId:t.id,proxyPoolId:e}))),st=(0,i.jsx)("div",{className:"flex min-w-0 flex-col divide-y divide-black/[0.03] dark:divide-white/[0.03] max-h-[500px] overflow-y-auto pr-1",children:y.map((e,t)=>{let s;return(0,i.jsxs)("div",{className:"flex min-w-0 items-stretch",children:[(0,i.jsx)("div",{className:"flex shrink-0 items-center pl-1 sm:pl-2",children:(0,i.jsx)("input",{type:"checkbox",checked:(s=e.id,eT.includes(s)),onChange:()=>{var t;return t=e.id,void e$(e=>e.includes(t)?e.filter(e=>e!==t):[...e,t])},className:"h-4 w-4 rounded border-gray-300 text-primary focus:ring-primary"})}),(0,i.jsx)("div",{className:"flex-1 min-w-0",children:(0,i.jsx)(M,{connection:e,proxyPools:O,isOAuth:ty,isFirst:0===t,isLast:t===y.length-1,onMoveUp:()=>t4(t,t-1),onMoveDown:()=>t4(t,t+1),onToggleActive:t=>t3(e.id,t),autoPing:es[f]&&"oauth"===e.authType?{isActive:!0===eU.connections[e.id]||eU.schedules?.[e.id]?.enabled===!0,reactiveOn:!0===eU.connections[e.id],provider:f,scheduleOn:eU.schedules?.[e.id]?.enabled===!0,scheduleSummary:(0,et.JW)(eU.schedules?.[e.id]).join(" / "),onConfigure:()=>eL(e)}:null,onUpdateProxy:async t=>{try{(await fetch(`/api/providers/${e.id}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({proxyPoolId:t||null})})).ok&&b(s=>s.map(s=>s.id===e.id?{...s,providerSpecificData:{...s.providerSpecificData,proxyPoolId:t||null}}:s))}catch(e){console.log("Error updating proxy:",e)}},onEdit:()=>{eu(e),en(!0)},onDelete:()=>t0(e.id),oneByOneStatus:te[e.id]||null})})]},e.id)})}),ss=O.filter(e=>!0===e.isActive),si=(0,i.jsx)(c.aF,{isOpen:ec,onClose:t9,title:`Apply Proxy (${y.length} connections)`,children:(0,i.jsxs)("div",{className:"flex flex-col gap-3",children:[(0,i.jsxs)("div",{className:"flex flex-col",children:[(0,i.jsxs)("button",{onClick:()=>{let e=O.filter(e=>!0===e.isActive);return 0===e.length?void alert("No active proxy pools available."):t7(y.map((t,s)=>({connectionId:t.id,proxyPoolId:e[s%e.length].id})))},disabled:eI||0===ss.length,className:"flex items-center gap-2 rounded-lg px-3 py-2 text-left transition-colors hover:bg-black/[0.04] dark:hover:bg-white/[0.04] disabled:cursor-not-allowed disabled:opacity-50",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-text-muted text-[18px]",children:"sync_alt"}),(0,i.jsx)("span",{className:"text-sm text-text-main",children:"One-to-one (rotate)"})]}),(0,i.jsxs)("button",{onClick:()=>se(null),disabled:eI,className:"flex items-center gap-2 rounded-lg px-3 py-2 text-left transition-colors hover:bg-black/[0.04] dark:hover:bg-white/[0.04] disabled:cursor-not-allowed disabled:opacity-50",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-text-muted text-[18px]",children:"link_off"}),(0,i.jsx)("span",{className:"text-sm text-text-main",children:"None (unbind all)"})]}),O.map(e=>(0,i.jsxs)("button",{onClick:()=>se(e.id),disabled:eI||!0!==e.isActive,className:"flex items-center gap-2 rounded-lg px-3 py-2 text-left transition-colors hover:bg-black/[0.04] dark:hover:bg-white/[0.04] disabled:cursor-not-allowed disabled:opacity-50",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-text-muted text-[18px]",children:"lan"}),(0,i.jsx)("span",{className:"truncate text-sm text-text-main",children:e.name}),!0!==e.isActive&&(0,i.jsx)("span",{className:"text-[10px] text-text-muted",children:"(inactive)"})]},e.id))]}),eI&&(0,i.jsx)("p",{className:"text-xs text-text-muted",children:"Applying..."}),(0,i.jsx)(c.$n,{onClick:t9,variant:"ghost",fullWidth:!0,disabled:eI,children:"Cancel"})]})}),sa=async e=>{if(!eN.has(e)){eC(t=>new Set(t).add(e));try{let t=await fetch("/api/models/test",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({model:`${tI}/${e}`})}),s=await t.json();ej(t=>({...t,[e]:s.ok?"ok":"error"})),ek(s.ok?"":s.error||"Model not reachable")}catch{ej(t=>({...t,[e]:"error"})),ek("Network error")}finally{eC(t=>{let s=new Set(t);return s.delete(e),s})}}};if(v)return(0,i.jsxs)("div",{className:"flex flex-col gap-8",children:[(0,i.jsx)(c.Qv,{}),(0,i.jsx)(c.Qv,{})]});if(!tf)return(0,i.jsxs)("div",{className:"text-center py-20",children:[(0,i.jsx)("p",{className:"text-text-muted",children:"Provider not found"}),(0,i.jsx)(n(),{href:"/dashboard/providers",className:"text-primary mt-4 inline-block",children:"Back to Providers"})]});let sr=()=>tC&&tf.apiType?"responses"===tf.apiType?"/providers/oai-r.png":"/providers/oai-cc.png":tS?"/providers/anthropic-m.png":(0,d.HY)(tf.id);return(0,i.jsxs)("div",{className:"flex min-w-0 flex-col gap-6 px-1 sm:gap-8 sm:px-0",children:[(0,i.jsxs)("div",{className:"min-w-0",children:[(0,i.jsxs)(n(),{href:"/dashboard/providers",className:"inline-flex items-center gap-1 text-sm text-text-muted hover:text-primary transition-colors mb-4",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-lg",children:"arrow_back"}),"Back to Providers"]}),(0,i.jsxs)("div",{className:"flex min-w-0 items-center gap-3 sm:gap-4",children:[(0,i.jsx)("div",{className:"flex size-12 shrink-0 items-center justify-center rounded-lg",style:{backgroundColor:`${tf.color}15`},children:ey||!sr()?(0,i.jsx)("span",{className:"text-sm font-bold",style:{color:tf.color},children:tf.textIcon||tf.id.slice(0,2).toUpperCase()}):(0,i.jsx)(o.A,{src:sr(),alt:tf.name,width:48,height:48,className:"max-h-12 max-w-12 rounded-lg object-contain",sizes:"48px",onError:()=>{(0,d.Kw)(tf.id),eb(!0)},loading:"lazy",decoding:"async"})}),(0,i.jsxs)("div",{className:"min-w-0",children:[(0,i.jsxs)("div",{className:"flex items-center gap-3 flex-wrap",children:[(0,i.jsx)("h1",{className:"truncate text-2xl font-semibold tracking-tight sm:text-3xl",children:tf.name}),(tf.notice?.apiKeyUrl||tf.notice?.signupUrl||tf.website)&&(0,i.jsxs)("a",{href:tf.notice?.apiKeyUrl||tf.notice?.signupUrl||tf.website,target:"_blank",rel:"noopener noreferrer",className:"text-xs text-primary hover:underline inline-flex items-center gap-1",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-sm",children:"open_in_new"}),tf.notice?.apiKeyUrl?"Get API Key":"Sign up / Learn more"]})]}),(0,i.jsxs)("p",{className:"text-text-muted",children:[y.length," connection",1===y.length?"":"s"]})]})]})]}),tf.deprecated&&(0,i.jsxs)("div",{className:"flex items-center gap-2 px-3 py-2 rounded-lg bg-yellow-500/10 border border-yellow-500/30",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-[16px] text-yellow-500 mt-0.5 shrink-0",children:"warning"}),(0,i.jsx)("p",{className:"text-xs text-red-600 dark:text-yellow-400 leading-relaxed",children:tf.deprecationNotice})]}),tf.notice?.text&&!tf.deprecated&&(0,i.jsxs)("div",{className:"flex flex-col gap-2 rounded-lg border border-blue-500/30 bg-blue-500/10 px-3 py-2 sm:flex-row sm:items-center",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-[16px] text-blue-500 shrink-0",children:"info"}),(0,i.jsx)("p",{className:"min-w-0 flex-1 text-xs leading-relaxed text-blue-600 dark:text-blue-400",children:tf.notice.text}),tf.notice.apiKeyUrl&&(0,i.jsx)("a",{href:tf.notice.apiKeyUrl,target:"_blank",rel:"noopener noreferrer",className:"inline-flex justify-center rounded bg-blue-500 px-2 py-1 text-xs font-medium text-white transition-colors hover:bg-blue-600 sm:py-0.5",children:"Get API Key →"})]}),tA&&w&&(0,i.jsx)(c.Zp,{children:(0,i.jsxs)("div",{className:"mb-4 flex flex-col gap-3 sm:flex-row sm:items-start sm:justify-between",children:[(0,i.jsxs)("div",{className:"min-w-0",children:[(0,i.jsx)("h2",{className:"text-lg font-semibold",children:tS?"Anthropic Compatible Details":"OpenAI Compatible Details"}),(0,i.jsxs)("p",{className:"break-all text-sm text-text-muted",children:[tS?"Messages API":"responses"===w.apiType?"Responses API":"Chat Completions"," \xb7 ",(w.baseUrl||"").replace(/\/$/,""),"/",tS?"messages":"responses"===w.apiType?"responses":"chat/completions"]})]}),(0,i.jsxs)("div",{className:"grid grid-cols-1 gap-2 sm:flex sm:items-center",children:[(0,i.jsx)(c.$n,{size:"sm",icon:"add",onClick:()=>{Z(""),H(!0)},className:"w-full sm:w-auto",children:"Add API Key"}),(0,i.jsx)(c.$n,{size:"sm",variant:"secondary",icon:"edit",onClick:()=>ed(!0),className:"w-full sm:w-auto",children:"Edit"}),(0,i.jsx)(c.$n,{size:"sm",variant:"secondary",icon:"delete",onClick:async()=>{e1({title:"Delete Compatible Node",message:`Delete this ${tS?"Anthropic":"OpenAI"} Compatible node?`,onConfirm:async()=>{e1(null);try{(await fetch(`/api/provider-nodes/${f}`,{method:"DELETE"})).ok&&h.push("/dashboard/providers")}catch(e){console.log("Error deleting provider node:",e)}}})},className:"w-full sm:w-auto",children:"Delete"})]})]})}),tj&&(0,i.jsx)(c.gw,{providerId:f,title:"Proxy pool for connecting",description:"The OAuth connect flow itself calls Google endpoints. Route it through the selected proxy pool; the pool is then saved onto the new connection."}),tv?(0,i.jsx)(c.gw,{providerId:f}):(0,i.jsxs)(c.Zp,{children:[(0,i.jsxs)("div",{className:"mb-4 flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between",children:[(0,i.jsx)("h2",{className:"text-lg font-semibold",children:"Connections"}),(0,i.jsxs)("div",{className:"flex flex-col gap-3 sm:flex-row sm:items-center sm:gap-4",children:[y.length>0&&O.length>0&&(0,i.jsx)(c.$n,{size:"sm",variant:"secondary",icon:"lan",onClick:()=>em(!0),children:"Apply Proxy"}),y.length>0&&(0,i.jsxs)(i.Fragment,{children:[eT.length>0&&(0,i.jsxs)(c.$n,{size:"sm",variant:"danger",icon:"delete",onClick:()=>{let e=eT.length;0!==e&&e1({title:`Delete ${e} Connection${e>1?"s":""}`,message:`Delete ${e} connection${e>1?"s":""}? This cannot be undone.`,onConfirm:async()=>{e1(null);let e=0,t=[...eT];for(let s of t)try{(await fetch(`/api/providers/${s}`,{method:"DELETE"})).ok||(e+=1)}catch(t){console.log("Error deleting connection:",t),e+=1}b(e=>e.filter(e=>!t.includes(e.id))),e$([]),e>0&&alert(`Deleted ${t.length-e} connection(s), ${e} failed.`)}})},children:["Delete Selected (",eT.length,")"]}),(0,i.jsx)(c.$n,{size:"sm",variant:"secondary",icon:"sync",onClick:tY,disabled:e3,children:e3?"Testing Connection One-by-One...":"Test Connection One-by-One"}),e3&&(0,i.jsx)(c.$n,{size:"sm",variant:"ghost",icon:"stop",onClick:()=>{e3&&(ta.current=!0,e8(!0))},disabled:e6,children:e6?"Stopping...":"Stop"})]}),(0,i.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,i.jsx)("span",{className:"text-xs text-text-muted font-medium",children:"Round Robin"}),(0,i.jsx)(c.lM,{checked:"round-robin"===eR,onChange:e=>{let t=e?"round-robin":null,s=e?ez||"1":ez;e&&!ez&&e_("1"),eD(t),tJ(t,s)}}),"round-robin"===eR&&(0,i.jsxs)("div",{className:"flex items-center gap-1.5",children:[(0,i.jsx)("span",{className:"text-xs text-text-muted",children:"Sticky:"}),(0,i.jsx)("input",{type:"number",min:1,value:ez,onChange:e=>{var t;e_(t=e.target.value),tJ("round-robin",t)},placeholder:"1",className:"w-14 px-2 py-1 text-xs border border-border rounded-md bg-background focus:outline-none focus:border-primary"})]})]})]})]}),0===y.length?(0,i.jsxs)("div",{className:"flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between",children:[(0,i.jsxs)("div",{className:"flex items-center gap-3",children:[(0,i.jsx)("div",{className:"inline-flex items-center justify-center w-9 h-9 rounded-full bg-primary/10 text-primary shrink-0",children:(0,i.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:ty?"lock":"key"})}),(0,i.jsxs)("div",{className:"min-w-0",children:[(0,i.jsx)("p",{className:"text-sm text-text-muted",children:"No connections yet"}),tT&&(0,i.jsxs)("p",{className:"text-xs text-text-muted",children:["Choose ",t$," or ",tO,"."]})]})]}),(0,i.jsx)("div",{className:"flex gap-2",children:tT?(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(c.$n,{size:"sm",icon:"lock",variant:"secondary",onClick:tu,children:t$}),(0,i.jsx)(c.$n,{size:"sm",icon:"key",onClick:tx,children:tO})]}):(0,i.jsxs)(i.Fragment,{children:[!tA&&ee.w.has(f)&&(0,i.jsx)(ee.A,{providerId:f,onConnected:tK}),!tA&&"iflow"===f&&(0,i.jsx)(c.$n,{size:"sm",icon:"cookie",variant:"secondary",onClick:()=>K(!0),children:"Cookie"}),"codex"===f&&(0,i.jsx)(c.$n,{size:"sm",icon:"playlist_add",variant:"secondary",onClick:()=>Q(!0),children:(0,S.Tl)("Bulk Add")}),"grok-cli"===f&&(0,i.jsx)(c.$n,{size:"sm",icon:"playlist_add",variant:"secondary",onClick:()=>er(!0),children:(0,S.Tl)("Bulk Add")}),(0,i.jsx)(c.$n,{size:"sm",icon:"add",onClick:th,children:tA?"Add API Key":"iflow"===f?"OAuth":"Add Connection"})]})})]}):(0,i.jsxs)(i.Fragment,{children:[ts&&(0,i.jsx)("div",{className:"mb-4 rounded-lg border border-black/10 bg-black/[0.02] px-3 py-2 text-xs text-text-muted dark:border-white/10 dark:bg-white/[0.03]",children:(0,i.jsxs)("div",{className:"flex flex-wrap items-center gap-3",children:[(0,i.jsxs)("span",{children:["Total: ",ts.total]}),(0,i.jsxs)("span",{children:["Completed: ",ts.completed]}),(0,i.jsxs)("span",{children:["Passed: ",ts.passed]}),(0,i.jsxs)("span",{children:["Failed: ",ts.failed]}),ts.stopped&&(0,i.jsx)("span",{className:"text-amber-600 dark:text-amber-400",children:"Stopped"}),e3&&e9&&(0,i.jsxs)("span",{children:["Running: ",y.find(e=>e.id===e9)?.name||e9]})]})}),y.length>0&&(0,i.jsx)("div",{className:"mb-3 flex items-center gap-2 border-b border-black/[0.03] pb-2 dark:border-white/[0.03]",children:(0,i.jsxs)("label",{className:"flex cursor-pointer items-center gap-1.5 text-xs text-text-muted hover:text-primary",children:[(0,i.jsx)("input",{type:"checkbox",checked:t8,onChange:()=>{t8?e$([]):e$(y.map(e=>e.id))},className:"h-3.5 w-3.5 rounded border-gray-300 text-primary focus:ring-primary"}),"Select All"]})}),st,!tA&&(0,i.jsxs)("div",{className:"mt-4 grid grid-cols-1 gap-2 sm:flex",children:[ee.w.has(f)&&(0,i.jsx)(ee.A,{providerId:f,onConnected:tK}),"iflow"===f&&(0,i.jsx)(c.$n,{size:"sm",icon:"cookie",variant:"secondary",onClick:()=>K(!0),title:"Add connection using browser cookie",className:"w-full sm:w-auto",children:"Cookie"}),"codex"===f&&(0,i.jsx)(c.$n,{size:"sm",icon:"playlist_add",variant:"secondary",onClick:()=>Q(!0),title:(0,S.Tl)("Bulk import codex accounts from JSON"),className:"w-full sm:w-auto",children:(0,S.Tl)("Bulk Add")}),"grok-cli"===f&&(0,i.jsx)(c.$n,{size:"sm",icon:"playlist_add",variant:"secondary",onClick:()=>er(!0),title:(0,S.Tl)("Bulk import Grok CLI accounts from JSON"),className:"w-full sm:w-auto",children:(0,S.Tl)("Bulk Add")}),tT?(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(c.$n,{size:"sm",icon:"lock",variant:"secondary",onClick:tu,className:"w-full sm:w-auto",children:t$}),(0,i.jsx)(c.$n,{size:"sm",icon:"key",onClick:tx,className:"w-full sm:w-auto",children:tO})]}):(0,i.jsx)(c.$n,{size:"sm",icon:"add",onClick:th,className:"w-full sm:w-auto",children:"Add"})]})]})]}),(0,i.jsx)(X,{providerId:f}),(0,i.jsxs)(c.Zp,{children:[(0,i.jsxs)("div",{className:"mb-4 flex flex-col gap-2 sm:flex-row sm:items-center sm:justify-between",children:[(0,i.jsxs)("div",{className:"flex items-center gap-3",children:[(0,i.jsx)("h2",{className:"text-lg font-semibold",children:"Available Models"}),tE&&(0,i.jsx)("select",{value:eM,onChange:e=>{var t;eq(t=e.target.value),tW(t)},title:"Appends (level) suffix to copied model names",className:"rounded-md border border-border bg-background px-2 py-1 text-xs focus:border-primary focus:outline-none",children:tE.map(e=>(0,i.jsx)("option",{value:e,children:`Thinking: ${e.charAt(0).toUpperCase()+e.slice(1)}`},e))})]}),!tA&&(e=[...tk,...eV.filter(e=>!tk.some(t=>t.id===e.id))].filter(e=>{let t=(0,p.CP)(e);return!t||"llm"===t}).map(e=>e.id).filter(e=>!eX.includes(e)),(0,i.jsxs)("div",{className:"flex gap-2",children:[eX.length>0&&(0,i.jsx)(c.$n,{size:"sm",variant:"secondary",icon:"restart_alt",onClick:tq,children:"Active All"}),e.length>0&&(0,i.jsx)(c.$n,{size:"sm",variant:"secondary",icon:"block",onClick:()=>tM(e),children:"Disable All"})]}))]}),!!ew&&(0,i.jsxs)("div",{className:"mb-3",children:[(0,i.jsx)("p",{className:"text-xs text-red-500 break-words",children:ew}),/RegionError|hosted in China|regionNotAllowed/i.test(ew)&&(s=(t="string"==typeof ew?ew:JSON.stringify(ew)).match(/https:\/\/opencode\.ai\/workspace\/[^\s"')]+/),l=t.match(/wrk_[0-9A-Za-z]+/),u=s?s[0].endsWith("/go")?s[0]:`${s[0]}/go`:l?`https://opencode.ai/workspace/${l[0]}/go`:"https://opencode.ai",(0,i.jsx)("div",{className:"mt-1.5",children:(0,i.jsxs)("a",{href:u,target:"_blank",rel:"noreferrer",className:"inline-flex items-center gap-1 rounded-md bg-amber-500/10 px-2 py-0.5 text-xs font-medium text-amber-600 hover:bg-amber-500/20 dark:text-amber-400 transition-colors",children:[(0,i.jsx)("span",{children:"Allow China-hosted models"}),(0,i.jsx)("span",{className:"material-symbols-outlined text-[13px]",children:"open_in_new"})]})}))]}),"zed"===f&&!!eG&&(0,i.jsx)("p",{className:"text-xs text-red-500 mb-3 break-words",children:eG}),(()=>{let e,t,s;if(tA)return(0,i.jsx)(R,{providerStorageAlias:tI,providerDisplayAlias:tR,modelAliases:ex,customModels:ef,copied:td,onCopy:tc,onDeleteAlias:tG,onAddCustomModel:e=>tZ(e,"llm",tI),onDeleteCustomModel:e=>tV(e,"llm",tI),connections:y,isAnthropic:tS});let a=[...tk,...eV.filter(e=>!tk.some(t=>t.id===e.id))].filter(e=>{let t=(0,p.CP)(e);return!t||"llm"===t}),r=new Set(eX),l=a.filter(e=>!r.has(e.id)),n=a.filter(e=>r.has(e.id)),o=(0,$.R)({customModels:ef,modelAliases:ex,providerAlias:tI,builtInModels:tk,type:"llm"}),d=(0,$.o)(ex),c=(e,t)=>[...new Set([...d[e]||[],...d[t]||[]])];return(0,i.jsxs)("div",{className:"flex flex-wrap gap-3",children:[o.map(e=>(0,i.jsx)(I,{model:{id:e.id,name:e.name},fullModel:`${tR}/${e.id}`,aliases:c(e.fullModel,`${f}/${e.id}`),copied:td,onCopy:tc,onDeleteAlias:()=>{"custom"===e.source?tV(e.id,"llm",tI):tG(e.alias)},onRemoveAlias:tG,onAddAlias:t=>tB(e.id,t,tI),testStatus:ev[e.id],onTest:y.length>0||tv?()=>sa(e.id):void 0,isTesting:eN.has(e.id),isCustom:!0,isFree:!1,caps:g(`${f}/${e.id}`),thinkingSuffix:tP(e.id)},`${e.source}-${e.fullModel}`)),l.map(e=>{let t=`${tI}/${e.id}`;return(0,i.jsx)(I,{model:e,fullModel:`${tR}/${e.id}`,aliases:c(t,`${f}/${e.id}`),copied:td,onCopy:tc,onAddAlias:t=>tB(e.id,t,tI),onRemoveAlias:tG,testStatus:ev[e.id],onTest:y.length>0||tv?()=>sa(e.id):void 0,isTesting:eN.has(e.id),isFree:e.isFree,onDisable:()=>tz(e.id),caps:g(`${f}/${e.id}`),thinkingSuffix:tP(e.id)},e.id)}),(0,i.jsxs)("button",{onClick:()=>eA(!0),className:"flex w-full items-center justify-center gap-1.5 rounded-lg border border-dashed border-primary/40 px-3 py-2 text-xs text-primary transition-colors hover:border-primary hover:bg-primary/5 sm:w-auto",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-sm",children:"add"}),"Add Model"]}),ei[f]&&y.some(e=>!1!==e.isActive)&&(0,i.jsxs)("button",{onClick:tQ,disabled:tr,className:"flex w-full items-center justify-center gap-1.5 rounded-lg border border-dashed border-blue-500/40 px-3 py-2 text-xs text-blue-600 dark:text-blue-400 transition-colors hover:border-blue-500 hover:bg-blue-500/5 sm:w-auto disabled:opacity-50 disabled:cursor-not-allowed",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-sm",style:tr?{animation:"spin 1s linear infinite"}:void 0,children:tr?"progress_activity":"download"}),tr?(0,S.Tl)("Fetching..."):(0,S.Tl)(ei[f])]}),("cline"===f||"clinepass"===f)&&y.some(e=>!1!==e.isActive)&&(0,i.jsxs)("button",{onClick:tX,disabled:tn,className:"flex w-full items-center justify-center gap-1.5 rounded-lg border border-dashed border-blue-500/40 px-3 py-2 text-xs text-blue-600 dark:text-blue-400 transition-colors hover:border-blue-500 hover:bg-blue-500/5 sm:w-auto disabled:opacity-50 disabled:cursor-not-allowed",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-sm",style:tn?{animation:"spin 1s linear infinite"}:void 0,children:tn?"progress_activity":"download"}),tn?(0,S.Tl)("Fetching..."):(0,S.Tl)("Import from /models")]}),eJ.length>0&&(e=new Set([...Object.values(ex),...o.map(e=>e.fullModel)]),t=new Set(tk.map(e=>e.id)),0===(s=eJ.filter(s=>!e.has(`${tI}/${s.id}`)&&!t.has(s.id))).length?null:(0,i.jsxs)("div",{className:"w-full mt-2",children:[(0,i.jsx)("p",{className:"text-xs text-text-muted mb-2",children:"Suggested models:"}),(0,i.jsx)("div",{className:"flex flex-wrap gap-2",children:s.map(e=>(0,i.jsxs)("button",{onClick:async()=>{await tZ(e.id,"llm",tI)},className:"flex items-center gap-1 px-2.5 py-1.5 rounded-lg border border-black/10 dark:border-white/10 text-xs text-text-muted hover:text-primary hover:border-primary/40 hover:bg-primary/5 transition-colors",title:e.contextLength?`${e.name} \xb7 ${(e.contextLength/1e3).toFixed(0)}k ctx`:e.name,children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-[13px]",children:"add"}),e.id.split("/").pop()]},e.id))})]})),n.length>0&&(0,i.jsxs)("div",{className:"w-full mt-2",children:[(0,i.jsxs)("p",{className:"text-xs text-text-muted mb-2",children:["Disabled models (",n.length,"):"]}),(0,i.jsx)("div",{className:"flex flex-wrap gap-2",children:n.map(e=>(0,i.jsxs)("button",{onClick:()=>t_(e.id),className:"flex items-center gap-1 px-2.5 py-1.5 rounded-lg border border-dashed border-black/10 dark:border-white/10 text-xs text-text-muted hover:text-primary hover:border-primary/40 hover:bg-primary/5 transition-colors",title:"Restore model",children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-[13px]",children:"add"}),e.id]},e.id))})]})]})})()]}),si,"kiro"===f?(0,i.jsx)(c.Mh,{isOpen:E,providerInfo:tf,onSuccess:t1,onClose:()=>D(!1)}):"cursor"===f?(0,i.jsx)(c.G9,{isOpen:E,onSuccess:t1,onClose:()=>D(!1)}):"zed"===f?(0,i.jsx)(c.TE,{isOpen:E,providerInfo:tf,onSuccess:t1,onClose:()=>D(!1)}):"gitlab"===f?(0,i.jsx)(c.vj,{isOpen:E,providerInfo:tf,onSuccess:t1,onClose:()=>D(!1)}):(0,i.jsx)(c.LF,{isOpen:E,provider:f,providerInfo:tf,onSuccess:t1,onClose:()=>D(!1)}),(0,i.jsx)(c.LH,{isOpen:z,onSuccess:t1,onClose:()=>_(!1)}),"iflow"===f&&(0,i.jsx)(c.vE,{isOpen:q,onSuccess:()=>{tK(),K(!1)},onClose:()=>K(!1)}),(0,i.jsx)(U,{isOpen:J,provider:f,providerName:tf.name,isCompatible:tA,isAnthropic:tS,authType:tf?.authType,authHint:tf?.authHint,website:tf?.website,proxyPools:O,error:B,existingNames:y.map(e=>e.name).filter(Boolean),onSave:t2,onBulkDone:tK,onClose:()=>{Z(""),H(!1)}}),(0,i.jsx)(c.wI,{isOpen:el,connection:ep,proxyPools:O,onSave:t5,onClose:()=>en(!1)}),tA&&(0,i.jsx)(F,{isOpen:eo,node:w,onSave:tL,onClose:()=>ed(!1),isAnthropic:tS}),!tA&&(0,i.jsx)(L,{isOpen:eS,providerAlias:tI,providerDisplayAlias:tR,onSave:async(e,t,s)=>{await tZ(e,t?.stt?"stt":"llm",tI,t,s),eA(!1)},onClose:()=>eA(!1)}),"codex"===f&&(0,i.jsx)(W,{isOpen:V,onClose:()=>Q(!1),onSuccess:tK}),"grok-cli"===f&&(0,i.jsx)(G,{isOpen:ea,onClose:()=>er(!1),onSuccess:tK}),eK&&(0,i.jsx)(Y.A,{isOpen:!!eK,onClose:()=>eL(null),connection:eK,reactive:!0===eU.connections[eK.id],schedule:eU.schedules?.[eK.id]||null,onSave:e=>((e,{reactive:t,schedule:s})=>{tH({...eU,connections:{...eU.connections,[e]:t},schedules:{...eU.schedules,[e]:s}})})(eK.id,e)}),(0,i.jsx)(c.uo,{isOpen:e2,onClose:()=>e5(!1),onConfirm:()=>{(window.localStorage.setItem(tm,"true"),e5(!1),ty)?tp():tx()},title:"Risk Notice",message:tf?.deprecationNotice,confirmText:"I Understand, Continue",cancelText:"Cancel",variant:"danger"}),(0,i.jsx)(c.uo,{isOpen:!!e0,onClose:()=>e1(null),onConfirm:e0?.onConfirm,title:e0?.title||"Confirm",message:e0?.message,variant:"danger"})]})}},81231:(e,t,s)=>{"use strict";function i(e={}){let t={};for(let[s,i]of Object.entries(e))"string"==typeof i&&(t[i]??=[]).push(s);return t}function a({customModels:e=[],modelAliases:t={},providerAlias:s,builtInModels:i=[],type:r="llm",includeLegacyAliases:l=!0}){let n=new Set(i.map(e=>e.id)),o=new Set,d=[];for(let t of e){if(!t?.id||t.providerAlias!==s)continue;let e=t?.kind||t?.type||"llm";if(r&&e!==r||n.has(t.id))continue;let i=`${s}/${t.id}`;o.has(i)||(o.add(i),d.push({id:t.id,name:t.name||t.id,fullModel:i,source:"custom",type:e}))}if(!l)return d;let c=`${s}/`;for(let[e,s]of Object.entries(t||{})){if("string"!=typeof s||!s.startsWith(c))continue;let t=s.slice(c.length);!t||n.has(t)||o.has(s)||(o.add(s),d.push({id:t,alias:e,fullModel:s,source:"legacyAlias",type:r||"llm"}))}return d}s.d(t,{R:()=>a,o:()=>i})},82837:(e,t,s)=>{Promise.resolve().then(s.bind(s,56828))},93195:(e,t,s)=>{"use strict";function i(){try{return Intl.DateTimeFormat().resolvedOptions().timeZone||"UTC"}catch{return"UTC"}}s.d(t,{JW:()=>o,Vm:()=>i,fB:()=>r,gy:()=>a,nz:()=>l});let a={anchor:"09:30",timezone:i(),windowHours:5,slotsPerDay:3};function r(e){let t=/^(\d{1,2}):(\d{2})$/.exec(String(e||"").trim());if(!t)return null;let s=Number(t[1]),i=Number(t[2]);return s>23||i>59?null:{hour:s,minute:i}}function l(e){return Math.max(1,Math.floor(24/e))}function n(e,t,s,i){let a="number"==typeof e?e:Number(e);return Number.isFinite(a)?Math.min(i,Math.max(s,a)):t}function o(e){let t=function(e){if(!e||!0!==e.enabled)return null;let t=r(e.anchor)||r(a.anchor),s=`${String(t.hour).padStart(2,"0")}:${String(t.minute).padStart(2,"0")}`,i=!function(e){if(!e||"string"!=typeof e)return!1;try{return new Intl.DateTimeFormat("en-US",{timeZone:e}),!0}catch{return!1}}(e.timezone)?a.timezone:e.timezone,o=n(e.windowHours,a.windowHours,.5,24),d=Math.round(n(e.slotsPerDay,a.slotsPerDay,1,l(o)));return{enabled:!0,anchor:s,timezone:i,windowHours:o,slotsPerDay:d}}(e);if(!t)return[];let{hour:s,minute:i}=r(t.anchor),o=60*s+i;return Array.from({length:t.slotsPerDay},(e,s)=>{let i=Math.round(o+s*t.windowHours*60)%1440;return`${String(Math.floor(i/60)).padStart(2,"0")}:${String(i%60).padStart(2,"0")}`})}},97132:(e,t,s)=>{"use strict";s.d(t,{A:()=>m});var i=s(95155),a=s(12115),r=s(14051),l=s.n(r),n=s(35497),o=s(31474),d=s(93195);let c=[{value:"off",label:"Off",icon:"block"},{value:"reset",label:"On reset",icon:"bolt"},{value:"schedule",label:"Schedule",icon:"schedule"}];function m({isOpen:e,onClose:t,onSave:s,connection:r,reactive:l=!1,schedule:p=null}){let[u,x]=(0,a.useState)(()=>({mode:p?.enabled===!0?"schedule":!0===l?"reset":"off",anchor:p?.anchor||d.gy.anchor,timezone:(0,d.Vm)(),windowHours:String(p?.windowHours??d.gy.windowHours),slotsPerDay:String(p?.slotsPerDay??d.gy.slotsPerDay)})),h=Number(u.windowHours),f=Number(u.slotsPerDay),g=!!(0,d.fB)(u.anchor),y=Number.isFinite(h)&&h>=.5&&h<=24,b=y?(0,d.nz)(h):24,v=Number.isInteger(f)&&f>=1&&f<=b,j=g&&y&&v,w="schedule"!==u.mode||j,k=j?(0,d.JW)({enabled:!0,...u,windowHours:h,slotsPerDay:f}):[],N=k.length&&y?(()=>{let{hour:e,minute:t}=(0,d.fB)(u.anchor),s=Math.round(60*e+t+f*h*60)%1440;return`${String(Math.floor(s/60)).padStart(2,"0")}:${String(s%60).padStart(2,"0")}`})():"",C=e=>x(t=>({...t,...e}));return(0,i.jsx)(n.aF,{isOpen:e,onClose:t,title:"Auto-ping settings",size:"lg",footer:(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(n.$n,{variant:"secondary",onClick:t,children:"Cancel"}),(0,i.jsx)(n.$n,{onClick:()=>{w&&(s({reactive:"reset"===u.mode,schedule:"schedule"===u.mode?{enabled:!0,anchor:u.anchor,timezone:u.timezone,windowHours:h,slotsPerDay:f}:{enabled:!1}}),t())},disabled:!w,children:"Save"})]}),children:(0,i.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,i.jsxs)("p",{className:"text-sm text-text-muted",children:["Configure automated quota pings",r?.name?` for ${r.name}`:""," — pick one mode."]}),(0,i.jsx)("div",{className:"grid grid-cols-3 gap-1 rounded-[10px] bg-surface-2 p-1",children:c.map(e=>{let t=u.mode===e.value;return(0,i.jsxs)("button",{type:"button",onClick:()=>C({mode:e.value}),className:(0,o.cn)("flex h-9 items-center justify-center gap-1.5 rounded-[8px] px-3 text-sm font-medium transition-all",t?"bg-surface text-text-main shadow-sm":"text-text-muted hover:text-text-main"),children:[(0,i.jsx)("span",{className:"material-symbols-outlined text-[15px] leading-none",children:e.icon}),(0,i.jsx)("span",{children:e.label})]},e.value)})}),"reset"===u.mode&&(0,i.jsx)("p",{className:"text-xs text-text-muted",children:"Pings right after the 5h quota window resets, so a new window starts immediately."}),"schedule"===u.mode&&(0,i.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,i.jsx)("p",{className:"text-xs text-text-muted",children:"Pings at fixed local times so the 5h windows align with your workday."}),(0,i.jsxs)("div",{className:"grid grid-cols-1 gap-4 sm:grid-cols-3",children:[(0,i.jsx)(n.pd,{label:"Anchor time",type:"time",value:u.anchor,onChange:e=>C({anchor:e.target.value}),error:g?"":"Use HH:MM",inputClassName:"ring-1 ring-black/10 dark:ring-white/15"}),(0,i.jsx)(n.pd,{label:"Window (hours)",type:"number",min:"0.5",max:"24",step:"0.5",value:u.windowHours,onChange:e=>C({windowHours:e.target.value}),error:y?"":"0.5 – 24",inputClassName:"ring-1 ring-black/10 dark:ring-white/15"}),(0,i.jsx)(n.pd,{label:"Pings per day",type:"number",min:"1",max:String(b),step:"1",value:u.slotsPerDay,onChange:e=>C({slotsPerDay:e.target.value}),error:v?"":`1 – ${b}`,hint:v?`Max ${b}`:"",inputClassName:"ring-1 ring-black/10 dark:ring-white/15"})]}),k.length>0&&(0,i.jsxs)("div",{className:"rounded-[10px] bg-surface-2 px-3 py-2.5",children:[(0,i.jsxs)("p",{className:"text-xs font-medium uppercase tracking-wide text-text-muted",children:["Daily slots (",u.timezone,")"]}),(0,i.jsx)("p",{className:"mt-1 text-sm font-medium text-text-main",children:k.join(" → ")}),(0,i.jsxs)("p",{className:"mt-1 text-xs text-text-muted",children:["Covers ",k[0]," – ",N,", then pauses until ",k[0]," next day."]})]})]})]})})}m.propTypes={isOpen:l().bool.isRequired,onClose:l().func.isRequired,onSave:l().func.isRequired,connection:l().object,reactive:l().bool,schedule:l().object}}},e=>{e.O(0,[763,5772,1321,705,5497,8441,3794,7358],()=>e(e.s=82837)),_N_E=e.O()}]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8460],{1525:(e,t,r)=>{Promise.resolve().then(r.bind(r,29450))},29450:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>w});var s=r(95155),a=r(12115),l=r(14051),i=r.n(l),n=r(35497),o=r(57250),d=r(8247),c=r(90620),p=r(88105),m=r(98500),x=r.n(m),u=r(65921),h=r(38003);let f={available:{icon:"check_circle",color:"#22c55e",label:"Available"},cooldown:{icon:"schedule",color:"#f59e0b",label:"Cooldown"},unavailable:{icon:"error",color:"#ef4444",label:"Unavailable"},unknown:{icon:"help",color:"#6b7280",label:"Unknown"}};function b(){let[e,t]=(0,a.useState)(null),[r,l]=(0,a.useState)(!0),[i,o]=(0,a.useState)(!1),[d,c]=(0,a.useState)(null),p=(0,a.useRef)(null),m=(0,u.i)(),x=(0,a.useCallback)(async()=>{try{let e=await fetch("/api/models/availability");if(e.ok){let r=await e.json();t(r)}}catch{}finally{l(!1)}},[]);(0,a.useEffect)(()=>{x();let e=setInterval(x,3e4);return()=>clearInterval(e)},[x]),(0,a.useEffect)(()=>{let e=e=>{p.current&&!p.current.contains(e.target)&&o(!1)};return i&&document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[i]);let h=async(e,t)=>{c(`${e}:${t}`);try{(await fetch("/api/models/availability",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({action:"clearCooldown",provider:e,model:t})})).ok?(m.success(`Cooldown cleared for ${t}`),await x()):m.error("Failed to clear cooldown")}catch{m.error("Failed to clear cooldown")}finally{c(null)}};if(r)return null;let b=e?.models||[],g=0===(e?.unavailableCount||b.filter(e=>"available"!==e.status).length),v={};return b.forEach(e=>{if("available"===e.status)return;let t=e.provider||"unknown";v[t]||(v[t]=[]),v[t].push(e)}),(0,s.jsx)("div",{className:"relative",ref:p,children:i&&(0,s.jsxs)("div",{className:"absolute top-full right-0 mt-2 w-80 bg-surface border border-border rounded-xl shadow-2xl z-50 overflow-hidden",children:[(0,s.jsxs)("div",{className:"flex items-center justify-between px-4 py-3 border-b border-border bg-bg",children:[(0,s.jsxs)("div",{className:"flex items-center gap-2",children:[(0,s.jsx)("span",{className:"material-symbols-outlined text-[16px]",style:{color:g?"#22c55e":"#f59e0b"},children:g?"verified":"warning"}),(0,s.jsx)("span",{className:"text-sm font-semibold text-text-main",children:"Model Status"})]}),(0,s.jsx)("button",{onClick:x,className:"p-1 rounded-lg hover:bg-surface text-text-muted hover:text-text-main transition-colors",title:"Refresh",children:(0,s.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"refresh"})})]}),(0,s.jsx)("div",{className:"px-4 py-3 max-h-60 overflow-y-auto",children:g?(0,s.jsx)("p",{className:"text-sm text-text-muted text-center py-2",children:"All models are responding normally."}):(0,s.jsx)("div",{className:"flex flex-col gap-2.5",children:Object.entries(v).map(([e,t])=>(0,s.jsxs)("div",{children:[(0,s.jsx)("p",{className:"text-xs font-semibold text-text-main mb-1.5 capitalize",children:e}),(0,s.jsx)("div",{className:"flex flex-col gap-1",children:t.map(e=>{let t=f[e.status]||f.unknown,r=d===`${e.provider}:${e.model}`;return(0,s.jsxs)("div",{className:"flex items-center justify-between px-2.5 py-1.5 rounded-lg bg-surface/30",children:[(0,s.jsxs)("div",{className:"flex items-center gap-1.5 min-w-0",children:[(0,s.jsx)("span",{className:"material-symbols-outlined text-[14px] shrink-0",style:{color:t.color},children:t.icon}),(0,s.jsx)("span",{className:"font-mono text-xs text-text-main truncate",children:e.model})]}),"cooldown"===e.status&&(0,s.jsx)(n.$n,{size:"sm",variant:"ghost",onClick:()=>h(e.provider,e.model),disabled:r,className:"text-[10px] px-1.5! py-0.5! ml-2",children:r?"...":"Clear"})]},`${e.provider}-${e.model}`)})})]},e))})})]})})}let g={openai:{title:"Add OpenAI Compatible",type:"openai-compatible",defaultBaseUrl:"https://api.openai.com/v1",namePlaceholder:"OpenAI Compatible (Prod)",prefixPlaceholder:"oc-prod",baseUrlHint:"Use the base URL (ending in /v1) for your OpenAI-compatible API.",modelIdPlaceholder:"e.g. gpt-4, claude-3-opus",errorLabel:"OpenAI Compatible",hasApiType:!0},anthropic:{title:"Add Anthropic Compatible",type:"anthropic-compatible",defaultBaseUrl:"https://api.anthropic.com/v1",namePlaceholder:"Anthropic Compatible (Prod)",prefixPlaceholder:"ac-prod",baseUrlHint:"Use the base URL (ending in /v1) for your Anthropic-compatible API. The system will append /messages.",modelIdPlaceholder:"e.g. claude-3-opus",errorLabel:"Anthropic Compatible",hasApiType:!1}},v=[{value:"chat",label:"Chat Completions"},{value:"responses",label:"Responses API"}];function y({variant:e,isOpen:t,onClose:r,onCreated:l}){let i=g[e],o=()=>({name:"",prefix:"",...i.hasApiType?{apiType:"chat"}:{},baseUrl:i.defaultBaseUrl}),[d,c]=(0,a.useState)(o),[p,m]=(0,a.useState)(!1),[x,u]=(0,a.useState)(""),[h,f]=(0,a.useState)(""),[b,j]=(0,a.useState)(!1),[N,w]=(0,a.useState)(null),[k,C]=(0,a.useState)(null);(0,a.useEffect)(()=>{i.hasApiType?c(e=>({...e,baseUrl:i.defaultBaseUrl})):t&&(w(null),C(null),u(""),f(""))},[i.hasApiType?d.apiType:t]);let T=async()=>{if(d.name.trim()&&d.prefix.trim()&&d.baseUrl.trim()){m(!0),C(null);try{let e=await fetch("/api/provider-nodes",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:d.name,prefix:d.prefix,...i.hasApiType?{apiType:d.apiType}:{},baseUrl:d.baseUrl,type:i.type})}),t=await e.json();e.ok?(l(t.node),c(o()),u(""),w(null)):C(t.error||"Failed to create node")}catch(e){C("Failed to create node"),console.log(`Error creating ${i.errorLabel} node:`,e)}finally{m(!1)}}},A=async()=>{j(!0);try{let e=await fetch("/api/provider-nodes/validate",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({baseUrl:d.baseUrl,apiKey:x,type:i.type,modelId:h.trim()||void 0})}),t=await e.json();w(t)}catch{w({valid:!1,error:"Network error"})}finally{j(!1)}};return(0,s.jsx)(n.aF,{isOpen:t,title:i.title,onClose:r,children:(0,s.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,s.jsx)(n.pd,{label:"Name",value:d.name,onChange:e=>c({...d,name:e.target.value}),placeholder:i.namePlaceholder,hint:"Required. A friendly label for this node."}),(0,s.jsx)(n.pd,{label:"Prefix",value:d.prefix,onChange:e=>c({...d,prefix:e.target.value}),placeholder:i.prefixPlaceholder,hint:"Required. Used as the provider prefix for model IDs. Must be a name no other provider or node already answers to."}),i.hasApiType&&(0,s.jsx)(n.l6,{label:"API Type",options:v,value:d.apiType,onChange:e=>c({...d,apiType:e.target.value})}),(0,s.jsx)(n.pd,{label:"Base URL",value:d.baseUrl,onChange:e=>c({...d,baseUrl:e.target.value}),placeholder:i.defaultBaseUrl,hint:i.baseUrlHint}),(0,s.jsx)(n.pd,{label:"API Key (for Check)",type:"password",value:x,onChange:e=>u(e.target.value)}),(0,s.jsx)(n.pd,{label:"Model ID (optional)",value:h,onChange:e=>f(e.target.value),placeholder:i.modelIdPlaceholder,hint:"If provider lacks /models endpoint, enter a model ID to validate via chat/completions instead."}),(0,s.jsxs)("div",{className:"flex flex-col gap-3 sm:flex-row sm:items-center",children:[(0,s.jsx)(n.$n,{onClick:A,disabled:!x||b||!d.baseUrl.trim(),variant:"secondary",className:"w-full sm:w-auto",children:b?"Checking...":"Check"}),(()=>{if(!N)return null;let{valid:e,error:t,method:r}=N;return e?(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(n.Ex,{variant:"success",children:"Valid"}),"chat"===r&&(0,s.jsx)("span",{className:"text-sm text-text-muted",children:"(via inference test)"})]}):(0,s.jsxs)("div",{className:"flex flex-col gap-1",children:[(0,s.jsx)(n.Ex,{variant:"error",children:"Invalid"}),t&&(0,s.jsx)("span",{className:"text-sm text-red-500",children:t})]})})()]}),k&&(0,s.jsx)("p",{className:"text-xs text-red-500",children:k}),(0,s.jsxs)("div",{className:"flex flex-col gap-2 sm:flex-row",children:[(0,s.jsx)(n.$n,{onClick:T,fullWidth:!0,disabled:!d.name.trim()||!d.prefix.trim()||!d.baseUrl.trim()||p,children:p?"Creating...":"Create"}),(0,s.jsx)(n.$n,{onClick:r,variant:"ghost",fullWidth:!0,children:"Cancel"})]})]})})}y.propTypes={variant:i().oneOf(["openai","anthropic"]).isRequired,isOpen:i().bool.isRequired,onClose:i().func.isRequired,onCreated:i().func.isRequired};let j=[{value:"all",label:"All"},{value:"active",label:"Active"},{value:"inactive",label:"Inactive"},{value:"none",label:"No connection"}];function N(e,t,r){let a=[];if(e>0&&a.push((0,s.jsxs)(n.Ex,{variant:"success",size:"sm",dot:!0,children:[e," Connected"]},"connected")),t>0){let e=r?`${t} Error (${r})`:`${t} Error`;a.push((0,s.jsx)(n.Ex,{variant:"error",size:"sm",dot:!0,children:e},"error"))}return 0===a.length?(0,s.jsx)("span",{className:"text-text-muted",children:"No connections"}):a}function w(){let e,t,[r,l]=(0,a.useState)([]),[i,o]=(0,a.useState)([]),[d,m]=(0,a.useState)(!0),[x,f]=(0,a.useState)(!1),[g,v]=(0,a.useState)(!1),[N,w]=(0,a.useState)(!1),[A,I]=(0,a.useState)(null),[E,$]=(0,a.useState)(null),[O,P]=(0,a.useState)("all"),R=(0,u.i)(),S=(0,h.C)(e=>e.query),U=(0,h.C)(e=>e.register),_=(0,h.C)(e=>e.unregister);(0,a.useEffect)(()=>(U("Search providers..."),()=>_()),[U,_]);let z=e=>!S.trim()||!!e&&e.toLowerCase().includes(S.trim().toLowerCase());(0,a.useEffect)(()=>{(async()=>{try{let[e,t]=await Promise.all([fetch("/api/providers"),fetch("/api/provider-nodes")]),r=await e.json(),s=await t.json();e.ok&&l(r.connections||[]),t.ok&&o(s.nodes||[])}catch(e){console.log("Error fetching data:",e)}finally{m(!1)}})()},[]);let q=(e,t)=>{let s=Array.isArray(t)?t:[t],a=r.filter(t=>t.provider===e&&s.includes(t.authType)),l=e=>{let t=Object.entries(e).some(([e,t])=>e.startsWith("modelLock_")&&t&&new Date(t).getTime()>Date.now());return"unavailable"!==e.testStatus||t?e.testStatus:"active"},i=a.filter(e=>{let t=l(e);return"active"===t||"success"===t}).length,n=a.filter(e=>{let t=l(e);return"error"===t||"expired"===t||"unavailable"===t}),o=n.length,d=a.length,c=d>0&&a.every(e=>!1===e.isActive),p=n.sort((e,t)=>new Date(t.lastErrorAt||0)-new Date(e.lastErrorAt||0))[0];return{connected:i,error:o,total:d,errorCode:p?function(e){if(!e)return null;let t=e.lastErrorType;if("runtime_error"===t)return"RUNTIME";if("upstream_auth_error"===t||"auth_missing"===t||"token_refresh_failed"===t||"token_expired"===t)return"AUTH";if("upstream_rate_limited"===t)return"429";if("upstream_unavailable"===t)return"5XX";if("network_error"===t)return"NET";let r=Number(e.errorCode);if(Number.isFinite(r)&&r>=400)return String(r);let s=function(e){if(!e)return null;let t=e.match(/\b([45]\d{2})\b/);return t?t[1]:"ERR"}(e.lastError);if("401"===s||"403"===s)return"AUTH";if(s&&"ERR"!==s)return s;let a=(e.lastError||"").toLowerCase();return a.includes("runtime")||a.includes("not runnable")||a.includes("not installed")?"RUNTIME":a.includes("invalid api key")||a.includes("token invalid")||a.includes("revoked")||a.includes("unauthorized")?"AUTH":"ERR"}(p):null,errorTime:p?.lastErrorAt?function(e){if(!e)return"";let t=Math.floor((Date.now()-new Date(e).getTime())/6e4);if(t<1)return"just now";if(t<60)return`${t}m ago`;let r=Math.floor(t/60);if(r<24)return`${r}h ago`;let s=Math.floor(r/24);return`${s}d ago`}(p.lastErrorAt):null,allDisabled:c}},D=(e,t)=>(function(e,t,r=!1){return"all"===e||function(e,t=!1){return t?"active":e&&0!==e.total?e.allDisabled?"inactive":"active":"none"}(t,r)===e})(O,e,t),F=async(e,t,s)=>{let a=Array.isArray(t)?t:[t],i=t=>t.provider===e&&a.includes(t.authType),n=r.filter(i);l(e=>e.map(e=>i(e)?{...e,isActive:s}:e)),await Promise.allSettled(n.map(e=>fetch(`/api/providers/${e.id}`,{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({isActive:s})})))},M=async(e,t=null)=>{if(!A){I("provider"===e?t:e),$(null);try{let r=await fetch("/api/providers/test-batch",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({mode:e,providerId:t})}),s=await r.json();if($(s),s.summary){let{passed:e,failed:t,total:r}=s.summary;0===t?R.success(`All ${r} tests passed`):R.warning(`${e}/${r} passed, ${t} failed`)}}catch(e){$({error:"Test request failed"}),R.error("Provider test failed")}finally{I(null)}}},L=i.filter(e=>"openai-compatible"===e.type).map(e=>({id:e.id,name:e.name||"OpenAI Compatible",color:"#10A37F",textIcon:"OC",apiType:e.apiType})).filter(e=>z(e.name)&&D(q(e.id,"apikey"))),K=i.filter(e=>"anthropic-compatible"===e.type).map(e=>({id:e.id,name:e.name||"Anthropic Compatible",color:"#D97757",textIcon:"AC"})).filter(e=>z(e.name)&&D(q(e.id,"apikey"))),H=(e,t)=>{if("kiro"===t)return["oauth","apikey","api_key"];let r=e?.authModes;return Array.isArray(r)?r.includes("apikey")?["oauth","apikey","api_key"]:"oauth":t in p.nJ||t in c.fg?["oauth","apikey","api_key"]:"oauth"},J=(e=Object.entries(c.zN).filter(([e,t])=>!t.hidden&&z(t.name)&&D(q(e,H(t,e)),t.noAuth)),t="oauth",[...e].sort(([e,r],[s,a])=>{let l=r.priority??999,i=a.priority??999;if(l!==i)return l-i;let n=q(e,t),o=q(s,t),d=+(n.connected>0),c=+(o.connected>0);return d!==c?c-d:(r.name||"").localeCompare(a.name||"")})),B=Object.entries(p.IS).filter(([e,t])=>!t.hidden&&z(t.name)&&D(q(e,H(t,e)),t.noAuth)).sort(([,e],[,t])=>!!t.noAuth-!!e.noAuth),W=Object.entries(p.nJ).filter(([e,t])=>!t.hidden&&z(t.name)&&(t.serviceKinds??["llm"]).includes("llm")&&D(q(e,H(t,e)),t.noAuth)).sort(([e,t],[r,s])=>{let a=t.priority??999,l=s.priority??999;if(a!==l)return a-l;let i=!!s.noAuth-!!t.noAuth;if(0!==i)return i;let n=q(e,H(t,e)).connected>0?0:1,o=q(r,H(s,r)).connected>0?0:1;return n!==o?n-o:(t.name||"").localeCompare(s.name||"")}),Q=Object.entries(c.fg).filter(([e,t])=>!t.hidden&&(t.serviceKinds??["llm"]).includes("llm")&&z(t.name)&&D(q(e,"apikey"),t.noAuth)).sort(([e,t],[r,s])=>{let a=q(e,"apikey").total>0?0:1,l=q(r,"apikey").total>0?0:1;return a!==l?a-l:(t.name||"").localeCompare(s.name||"")}),X=!!S.trim()||"all"!==O,Z=X||x?Q:Q.slice(0,20),V=Q.length-20,Y=Object.entries(p.br).filter(([e,t])=>!t.hidden&&(t.serviceKinds??["llm"]).includes("llm")&&z(t.name)&&D(q(e,"cookie"),t.noAuth)).sort(([e,t],[r,s])=>{let a=q(e,"cookie").total>0?0:1,l=q(r,"cookie").total>0?0:1;return a!==l?a-l:(t.name||"").localeCompare(s.name||"")});if(d)return(0,s.jsxs)("div",{className:"flex flex-col gap-8",children:[(0,s.jsx)(n.Qv,{}),(0,s.jsx)(n.Qv,{})]});let G=J.length>0||B.length>0||W.length>0||Q.length>0||Y.length>0||L.length>0||K.length>0;return(0,s.jsxs)("div",{className:"flex min-w-0 flex-col gap-6 px-1 sm:px-0",children:[(0,s.jsx)("div",{className:"flex items-center justify-end",children:(0,s.jsx)("select",{value:O,onChange:e=>P(e.target.value),className:"h-8 rounded-lg border border-black/10 bg-black/[0.02] px-2 text-xs text-text-primary outline-none transition-colors hover:bg-black/5 dark:border-white/10 dark:bg-white/[0.03] dark:hover:bg-white/10","aria-label":"Filter providers by connection status",children:j.map(e=>(0,s.jsx)("option",{value:e.value,children:e.label},e.value))})}),!G&&(0,s.jsxs)("div",{className:"text-center py-8 border border-dashed border-border rounded-xl",children:[(0,s.jsx)("span",{className:"material-symbols-outlined text-[32px] text-text-muted mb-2",children:"search_off"}),(0,s.jsx)("p",{className:"text-text-muted text-sm",children:"No providers match your search or filters"})]}),(0,s.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,s.jsxs)("div",{className:"flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between",children:[(0,s.jsxs)("h2",{className:"text-lg sm:text-xl font-semibold flex items-center gap-2 leading-tight",children:["Custom Providers (OpenAI/Anthropic Compatible)"," "]}),(0,s.jsxs)("div",{className:"grid grid-cols-1 gap-2 sm:flex sm:w-auto",children:[(0,s.jsx)(n.$n,{size:"sm",icon:"add",onClick:()=>w(!0),className:"w-full sm:w-auto",children:"Add Anthropic Compatible"}),(0,s.jsx)(n.$n,{size:"sm",variant:"secondary",icon:"add",onClick:()=>v(!0),className:"w-full !bg-white !text-black hover:!bg-gray-100 sm:w-auto",children:"Add OpenAI Compatible"})]})]}),0===L.length&&0===K.length?(0,s.jsxs)("div",{className:"flex items-center justify-center gap-2 py-2 border border-dashed border-border rounded-xl text-text-muted text-sm",children:[(0,s.jsx)("span",{className:"material-symbols-outlined text-[18px]",children:"extension"}),(0,s.jsx)("span",{children:"No custom providers — use buttons above to add OpenAI/Anthropic compatible endpoints"})]}):(0,s.jsx)("div",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2 sm:gap-4 lg:grid-cols-3 xl:grid-cols-4",children:[...L,...K].map(e=>(0,s.jsx)(C,{providerId:e.id,provider:e,stats:q(e.id,"apikey"),authType:"compatible",onToggle:t=>F(e.id,"apikey",t)},e.id))})]}),J.length>0&&(0,s.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,s.jsxs)("div",{className:"flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between",children:[(0,s.jsx)("h2",{className:"text-lg sm:text-xl font-semibold flex items-center gap-2 leading-tight",children:"OAuth Providers"}),(0,s.jsxs)("div",{className:"flex w-full flex-col gap-2 sm:w-auto sm:flex-row sm:items-center",children:[(0,s.jsx)(b,{}),(0,s.jsxs)("button",{onClick:()=>M("oauth"),disabled:!!A,className:`flex w-full items-center justify-center gap-1.5 rounded-lg border px-3 py-2 text-xs font-medium transition-colors sm:w-auto sm:py-1.5 ${"oauth"===A?"bg-primary/20 border-primary/40 text-primary animate-pulse":"bg-bg border-border text-text-muted hover:text-text-main hover:border-primary/40"}`,title:"Test all OAuth connections","aria-label":"Test all OAuth connections",children:[(0,s.jsx)("span",{className:`material-symbols-outlined text-[14px]${"oauth"===A?" animate-spin":""}`,children:"play_arrow"}),"oauth"===A?"Testing...":"Test All"]})]})]}),(0,s.jsx)("div",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2 sm:gap-4 lg:grid-cols-3 xl:grid-cols-4",children:J.map(([e,t])=>{let r=H(t,e);return(0,s.jsx)(k,{providerId:e,provider:t,stats:q(e,r),authType:"oauth",onToggle:t=>F(e,r,t)},e)})})]}),(B.length>0||W.length>0)&&(0,s.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,s.jsxs)("div",{className:"flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between",children:[(0,s.jsx)("h2",{className:"text-lg sm:text-xl font-semibold flex items-center gap-2 leading-tight",children:"Free Tier Providers"}),(0,s.jsxs)("button",{onClick:()=>M("free"),disabled:!!A,className:`flex w-full items-center justify-center gap-1.5 rounded-lg border px-3 py-2 text-xs font-medium transition-colors sm:w-auto sm:py-1.5 ${"free"===A?"bg-primary/20 border-primary/40 text-primary animate-pulse":"bg-bg border-border text-text-muted hover:text-text-main hover:border-primary/40"}`,title:"Test all Free connections","aria-label":"Test all Free provider connections",children:[(0,s.jsx)("span",{className:`material-symbols-outlined text-[14px]${"free"===A?" animate-spin":""}`,children:"play_arrow"}),"free"===A?"Testing...":"Test All"]})]}),(0,s.jsxs)("div",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2 sm:gap-4 lg:grid-cols-3 xl:grid-cols-4",children:[B.map(([e,t])=>{let r=H(t,e);return(0,s.jsx)(k,{providerId:e,provider:t,stats:q(e,r),authType:"free",onToggle:t=>F(e,r,t)},e)}),W.map(([e,t])=>{let r=H(t,e);return(0,s.jsx)(C,{providerId:e,provider:t,stats:q(e,r),authType:Array.isArray(r)?r[0]??"apikey":r,onToggle:t=>F(e,r,t)},e)})]})]}),Q.length>0&&(0,s.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,s.jsxs)("div",{className:"flex flex-col gap-3 sm:flex-row sm:items-center sm:justify-between",children:[(0,s.jsxs)("h2",{className:"text-lg sm:text-xl font-semibold flex items-center gap-2 leading-tight",children:["API Key Providers"," "]}),(0,s.jsxs)("button",{onClick:()=>M("apikey"),disabled:!!A,className:`flex w-full items-center justify-center gap-1.5 rounded-lg border px-3 py-2 text-xs font-medium transition-colors sm:w-auto sm:py-1.5 ${"apikey"===A?"bg-primary/20 border-primary/40 text-primary animate-pulse":"bg-bg border-border text-text-muted hover:text-text-main hover:border-primary/40"}`,title:"Test all API Key connections","aria-label":"Test all API Key connections",children:[(0,s.jsx)("span",{className:`material-symbols-outlined text-[14px]${"apikey"===A?" animate-spin":""}`,children:"play_arrow"}),"apikey"===A?"Testing...":"Test All"]})]}),(0,s.jsxs)("div",{className:"grid grid-cols-1 gap-3 sm:grid-cols-2 sm:gap-4 lg:grid-cols-3 xl:grid-cols-4",children:[Z.map(([e,t])=>(0,s.jsx)(C,{providerId:e,provider:t,stats:q(e,"apikey"),authType:"apikey",onToggle:t=>F(e,"apikey",t)},e)),Y.map(([e,t])=>(0,s.jsx)(C,{providerId:e,provider:t,stats:q(e,"cookie"),authType:"cookie",onToggle:t=>F(e,"cookie",t)},e))]}),!X&&!x&&V>0&&(0,s.jsxs)("button",{onClick:()=>f(!0),className:"flex w-full items-center justify-center gap-1.5 rounded-lg border border-dashed border-primary/40 px-3 py-2.5 text-sm font-medium text-primary transition-colors hover:border-primary hover:bg-primary/5",children:[(0,s.jsx)("span",{className:"material-symbols-outlined text-[16px]",children:"expand_more"}),"Show all ",Q.length," providers"]})]}),(0,s.jsx)(y,{variant:"openai",isOpen:g,onClose:()=>v(!1),onCreated:e=>{o(t=>[...t,e]),v(!1)}}),(0,s.jsx)(y,{variant:"anthropic",isOpen:N,onClose:()=>w(!1),onCreated:e=>{o(t=>[...t,e]),w(!1)}}),E&&(0,s.jsxs)("div",{className:"fixed inset-0 z-50 flex items-start justify-center px-3 pt-[6vh] sm:pt-[10vh]",onClick:()=>$(null),children:[(0,s.jsx)("div",{className:"absolute inset-0 bg-black/60 backdrop-blur-sm"}),(0,s.jsxs)("div",{className:"relative bg-surface border border-border rounded-xl w-full max-w-[600px] max-h-[86vh] sm:max-h-[80vh] overflow-y-auto shadow-2xl",onClick:e=>e.stopPropagation(),children:[(0,s.jsxs)("div",{className:"sticky top-0 z-10 flex items-center justify-between px-5 py-3 border-b border-border bg-surface/95 backdrop-blur-sm rounded-t-xl",children:[(0,s.jsx)("h3",{className:"font-semibold",children:"Test Results"}),(0,s.jsx)("button",{onClick:()=>$(null),className:"p-1 rounded-lg hover:bg-bg text-text-muted hover:text-text-main transition-colors","aria-label":"Close test results",children:(0,s.jsx)("span",{className:"material-symbols-outlined text-lg",children:"close"})})]}),(0,s.jsx)("div",{className:"p-5",children:(0,s.jsx)(T,{results:E})})]})]})]})}function k({providerId:e,provider:t,stats:r,authType:a,onToggle:l}){let{connected:i,error:d,errorCode:c,errorTime:p,allDisabled:m}=r,u=!!t.noAuth;return(0,s.jsx)(x(),{href:`/dashboard/providers/${e}`,className:"group min-w-0",children:(0,s.jsx)(n.Zp,{padding:"xs",className:`h-full hover:bg-black/[0.01] dark:hover:bg-white/[0.01] transition-colors cursor-pointer ${m?"opacity-50":""}`,children:(0,s.jsxs)("div",{className:"flex min-w-0 items-center justify-between gap-3",children:[(0,s.jsxs)("div",{className:"flex min-w-0 items-center gap-3",children:[(0,s.jsx)("div",{className:"size-8 shrink-0 rounded-lg flex items-center justify-center",style:{backgroundColor:`${t.color?.length>7?t.color:t.color+"15"}`},children:(0,s.jsx)(o.A,{src:`/providers/${t.id}.png`,alt:t.name,size:30,className:"object-contain rounded-lg max-w-[32px] max-h-[32px]",fallbackText:t.textIcon||t.id.slice(0,2).toUpperCase(),fallbackColor:t.color})}),(0,s.jsxs)("div",{className:"min-w-0",children:[(0,s.jsx)("h3",{className:"truncate font-semibold",children:t.name}),(0,s.jsx)("div",{className:"flex min-w-0 items-center gap-1.5 text-xs flex-wrap",children:m?(0,s.jsx)(n.Ex,{variant:"default",size:"sm",children:(0,s.jsxs)("span",{className:"flex items-center gap-1",children:[(0,s.jsx)("span",{className:"material-symbols-outlined text-[12px]",children:"pause_circle"}),"Disabled"]})}):u?(0,s.jsx)(n.Ex,{variant:"success",size:"sm",dot:!0,children:"Ready"}):(0,s.jsxs)(s.Fragment,{children:[N(i,d,c),p&&(0,s.jsx)("span",{className:"text-text-muted",children:p})]})})]})]}),(0,s.jsx)("div",{className:"flex shrink-0 items-center gap-2",children:r.total>0&&(0,s.jsx)("div",{className:"opacity-100 transition-opacity sm:opacity-0 sm:group-hover:opacity-100",onClick:e=>{e.preventDefault(),e.stopPropagation(),l(!!m)},children:(0,s.jsx)(n.lM,{size:"sm",checked:!m,onChange:()=>{},title:m?"Enable provider":"Disable provider"})})})]})})})}function C({providerId:e,provider:t,stats:r,authType:a,onToggle:l}){let{connected:i,error:c,errorCode:m,errorTime:u,allDisabled:h}=r,f=e.startsWith(p.JH),b=e.startsWith(p.DI);return(0,s.jsx)(x(),{href:`/dashboard/providers/${e}`,className:"group min-w-0",children:(0,s.jsx)(n.Zp,{padding:"xs",className:`h-full hover:bg-black/[0.01] dark:hover:bg-white/[0.01] transition-colors cursor-pointer ${h?"opacity-50":""}`,children:(0,s.jsxs)("div",{className:"flex min-w-0 items-center justify-between gap-3",children:[(0,s.jsxs)("div",{className:"flex min-w-0 items-center gap-3",children:[(0,s.jsx)("div",{className:"size-8 shrink-0 rounded-lg flex items-center justify-center",style:{backgroundColor:`${t.color?.length>7?t.color:t.color+"15"}`},children:(0,s.jsx)(o.A,{src:f&&t.apiType?"responses"===t.apiType?"/providers/oai-r.png":"/providers/oai-cc.png":b?"/providers/anthropic-m.png":(0,d.HY)(t.id),alt:t.name,size:30,className:"object-contain rounded-lg max-w-[30px] max-h-[30px]",fallbackText:t.textIcon||t.id.slice(0,2).toUpperCase(),fallbackColor:t.color})}),(0,s.jsxs)("div",{className:"min-w-0",children:[(0,s.jsx)("h3",{className:"truncate font-semibold",children:t.name}),(0,s.jsx)("div",{className:"flex min-w-0 items-center gap-1.5 text-xs flex-wrap",children:h?(0,s.jsx)(n.Ex,{variant:"default",size:"sm",children:(0,s.jsxs)("span",{className:"flex items-center gap-1",children:[(0,s.jsx)("span",{className:"material-symbols-outlined text-[12px]",children:"pause_circle"}),"Disabled"]})}):(0,s.jsxs)(s.Fragment,{children:[N(i,c,m),f&&(0,s.jsx)(n.Ex,{variant:"default",size:"sm",children:"responses"===t.apiType?"Responses":"Chat"}),b&&(0,s.jsx)(n.Ex,{variant:"default",size:"sm",children:"Messages"}),u&&(0,s.jsx)("span",{className:"text-text-muted",children:u})]})})]})]}),(0,s.jsx)("div",{className:"flex shrink-0 items-center gap-2",children:r.total>0&&(0,s.jsx)("div",{className:"opacity-100 transition-opacity sm:opacity-0 sm:group-hover:opacity-100",onClick:e=>{e.preventDefault(),e.stopPropagation(),l(!!h)},children:(0,s.jsx)(n.lM,{size:"sm",checked:!h,onChange:()=>{},title:h?"Enable provider":"Disable provider"})})})]})})})}function T({results:e}){if(e.error&&!e.results)return(0,s.jsxs)("div",{className:"text-center py-6",children:[(0,s.jsx)("span",{className:"material-symbols-outlined text-red-500 text-[32px] mb-2 block",children:"error"}),(0,s.jsx)("p",{className:"text-sm text-red-400",children:e.error})]});let{summary:t,mode:r}=e,a=e.results||[];return(0,s.jsxs)("div",{className:"flex min-w-0 flex-col gap-3",children:[t&&(0,s.jsxs)("div",{className:"flex flex-wrap items-center gap-2 text-xs mb-1 sm:gap-3",children:[(0,s.jsxs)("span",{className:"text-text-muted",children:[{oauth:"OAuth",free:"Free",apikey:"API Key",provider:"Provider",all:"All"}[r]||r," Test"]}),(0,s.jsxs)("span",{className:"px-2 py-0.5 rounded bg-emerald-500/15 text-emerald-400 font-medium",children:[t.passed," passed"]}),t.failed>0&&(0,s.jsxs)("span",{className:"px-2 py-0.5 rounded bg-red-500/15 text-red-400 font-medium",children:[t.failed," failed"]}),(0,s.jsxs)("span",{className:"text-text-muted sm:ml-auto",children:[t.total," tested"]})]}),a.map((e,t)=>(0,s.jsxs)("div",{className:"flex min-w-0 flex-wrap items-center gap-2 rounded-lg bg-black/[0.03] px-3 py-2 text-xs dark:bg-white/[0.03] sm:flex-nowrap",children:[(0,s.jsx)("span",{className:`material-symbols-outlined text-[16px] ${e.valid?"text-emerald-500":"text-red-500"}`,children:e.valid?"check_circle":"error"}),(0,s.jsxs)("div",{className:"min-w-0 flex-[1_1_160px]",children:[(0,s.jsx)("span",{className:"block truncate font-medium sm:inline",children:e.connectionName}),(0,s.jsxs)("span",{className:"block truncate text-text-muted sm:ml-1.5 sm:inline",children:["(",e.provider,")"]})]}),void 0!==e.latencyMs&&(0,s.jsxs)("span",{className:"shrink-0 text-text-muted font-mono tabular-nums",children:[e.latencyMs,"ms"]}),(0,s.jsx)("span",{className:`shrink-0 text-[10px] uppercase font-bold px-1.5 py-0.5 rounded ${e.valid?"bg-emerald-500/15 text-emerald-400":"bg-red-500/15 text-red-400"}`,children:e.valid?"OK":e.diagnosis?.type||"ERROR"})]},e.connectionId||t)),0===a.length&&(0,s.jsx)("div",{className:"text-center py-4 text-text-muted text-sm",children:"No active connections found for this group."})]})}k.propTypes={providerId:i().string.isRequired,provider:i().shape({id:i().string.isRequired,name:i().string.isRequired,color:i().string,textIcon:i().string}).isRequired,stats:i().shape({connected:i().number,error:i().number,errorCode:i().string,errorTime:i().string}).isRequired,authType:i().string,onToggle:i().func},C.propTypes={providerId:i().string.isRequired,provider:i().shape({id:i().string.isRequired,name:i().string.isRequired,color:i().string,textIcon:i().string,apiType:i().string}).isRequired,stats:i().shape({connected:i().number,error:i().number,errorCode:i().string,errorTime:i().string}).isRequired,authType:i().string,onToggle:i().func},T.propTypes={results:i().shape({mode:i().string,results:i().array,summary:i().shape({total:i().number,passed:i().number,failed:i().number}),error:i().string}).isRequired}}},e=>{e.O(0,[763,1321,705,5497,8441,3794,7358],()=>e(e.s=1525)),_N_E=e.O()}]);
|
package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/pxpipe/page-be8471c465c6fd52.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7414],{29216:(e,t,s)=>{Promise.resolve().then(s.bind(s,71470))},71470:(e,t,s)=>{"use strict";s.d(t,{default:()=>j});var a=s(95155),l=s(12115),r=s(21742),i=s(90639),d=s(77496),n=s(32539),o=s(59656),x=s(1162),c=s(97779),m=s(35497);let p=e=>e>=1e6?`${(e/1e6).toFixed(2)}M`:e>=1e3?`${(e/1e3).toFixed(1)}K`:String(e||0),h=[{id:"today",label:"Today"},{id:"yesterday",label:"Yesterday"},{id:"last7d",label:"7 days"},{id:"last30d",label:"30 days"},{id:"all",label:"All time"}],u={applied:"Prompt exceeded threshold",below_threshold:"Below size threshold",not_profitable:"Compression not profitable",below_min_chars:"Below minimum chars",below_min_tokens:"Below minimum tokens",unsupported_model:"Model not in allowlist",unsupported_format:"Non-Claude request format",timeout:"Compression timed out",transform_error:"Transform error",passthrough:"Passthrough",disabled:"Disabled",not_installed:"Not installed"};function g({label:e,value:t,sub:s,tone:l}){return(0,a.jsxs)(m.Zp,{className:"p-4",children:[(0,a.jsx)("p",{className:"text-xs text-text-muted uppercase tracking-wide",children:e}),(0,a.jsx)("p",{className:`text-xl font-semibold mt-1 ${l||""}`,children:t}),s&&(0,a.jsx)("p",{className:"text-xs text-text-muted mt-0.5",children:s})]})}function j(){let[e,t]=(0,l.useState)(null),[s,j]=(0,l.useState)(null),[b,f]=(0,l.useState)(null),[N,y]=(0,l.useState)(null),[v,w]=(0,l.useState)("last7d"),[k,S]=(0,l.useState)(!0),P=(0,l.useCallback)(async()=>{S(!0);try{let[e,s,a]=await Promise.all([fetch("/api/pxpipe/status",{headers:{"Cache-Control":"no-store"}}),fetch("/api/pxpipe/stats"),fetch("/api/pxpipe/logs?limit=50")]);t(await e.json()),f(await s.json()),y(await a.json());let l=await fetch("/api/pxpipe/health",{method:"POST"});j(await l.json())}catch{}finally{S(!1)}},[]);(0,l.useEffect)(()=>{P()},[P]);let E=b?.windows?.[v],$=e?e.installed?s?.healthy?"Healthy":e.running?"Running":"Stopped":"Not installed":"—";return(0,a.jsxs)("div",{className:"space-y-6 p-6",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between flex-wrap gap-3",children:[(0,a.jsxs)("h2",{className:"text-lg font-semibold flex items-center gap-2",children:[(0,a.jsx)("span",{className:"material-symbols-outlined text-primary",children:"image"}),"PXPIPE Dashboard"]}),(0,a.jsxs)("div",{className:"flex items-center gap-2",children:[(0,a.jsx)("a",{href:"/dashboard/token-saver",className:"text-xs text-primary underline hover:opacity-80",children:"Token Saver settings"}),(0,a.jsx)(m.$n,{size:"sm",variant:"ghost",onClick:P,disabled:k,children:k?"Refreshing…":"Refresh"})]})]}),(0,a.jsxs)("div",{className:"grid grid-cols-2 md:grid-cols-3 lg:grid-cols-6 gap-3",children:[(0,a.jsx)(g,{label:"Status",value:$,tone:s?.healthy?"text-success":e?.installed?"text-warning":"text-text-muted",sub:e?.enabled?"Enabled in pipeline":"Disabled in pipeline"}),(0,a.jsx)(g,{label:"Version",value:e?.version?`v${e.version}`:"—",sub:"pxpipe-proxy"}),(0,a.jsx)(g,{label:"Uptime",value:(e=>{if(!e||e<=0)return"—";let t=Math.floor(e/6e4),s=Math.floor(t/60);return s>0?`${s}h${String(t%60).padStart(2,"0")}m`:`${t}m`})(e?.uptimeMs),sub:"module loaded"}),(0,a.jsx)(g,{label:"Requests",value:E?E.requests.toLocaleString():"—"}),(0,a.jsx)(g,{label:"Compressed",value:E?E.compressed.toLocaleString():"—",tone:"text-success"}),(0,a.jsx)(g,{label:"Bypassed",value:E?E.bypassed.toLocaleString():"—"})]}),(0,a.jsxs)(m.Zp,{className:"p-4",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between flex-wrap gap-3 mb-4",children:[(0,a.jsx)("h3",{className:"font-medium",children:"Token savings (estimated)"}),(0,a.jsx)("div",{className:"flex items-center gap-1 rounded-lg border border-border bg-bg-subtle p-1",children:h.map(e=>(0,a.jsx)("button",{onClick:()=>w(e.id),className:`px-3 py-1 rounded-md text-xs font-medium transition-colors ${v===e.id?"bg-primary text-white shadow-sm":"text-text-muted hover:text-text hover:bg-bg-hover"}`,children:e.label},e.id))})]}),(0,a.jsxs)("div",{className:"grid grid-cols-2 md:grid-cols-4 gap-4 text-center",children:[(0,a.jsxs)("div",{children:[(0,a.jsx)("p",{className:"text-xs text-text-muted",children:"Original tokens"}),(0,a.jsx)("p",{className:"text-lg font-semibold",children:E?p(E.tokensBeforeEst):"—"})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("p",{className:"text-xs text-text-muted",children:"After PXPIPE"}),(0,a.jsx)("p",{className:"text-lg font-semibold",children:E?p(E.tokensAfterEst):"—"})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("p",{className:"text-xs text-text-muted",children:"Saved"}),(0,a.jsx)("p",{className:"text-lg font-semibold text-success",children:E?p(E.tokensSavedEst):"—"})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("p",{className:"text-xs text-text-muted",children:"Reduction"}),(0,a.jsx)("p",{className:"text-lg font-semibold text-success",children:E?`${E.savedPct}%`:"—"})]})]}),(0,a.jsxs)("p",{className:"text-xs text-text-muted mt-3",children:["Estimates from body size before/after imaging; billed usage per request (recorded on the Usage page) remains the ground truth. Images generated:"," ",E?E.imagesGenerated.toLocaleString():"—"," \xb7 avg compression time:"," ",E?`${E.avgCompressionMs}ms`:"—"," \xb7 errors: ",E?E.errors:"—"]})]}),(0,a.jsxs)(m.Zp,{className:"p-4",children:[(0,a.jsx)("h3",{className:"font-medium mb-3",children:"Tokens saved — last 30 days"}),b?.timeline?.some(e=>e.tokensSavedEst>0)?(0,a.jsx)(r.u,{width:"100%",height:220,children:(0,a.jsxs)(i.Q,{data:b.timeline,margin:{top:4,right:8,left:0,bottom:0},children:[(0,a.jsx)("defs",{children:(0,a.jsxs)("linearGradient",{id:"gradPxpipe",x1:"0",y1:"0",x2:"0",y2:"1",children:[(0,a.jsx)("stop",{offset:"5%",stopColor:"#10b981",stopOpacity:.25}),(0,a.jsx)("stop",{offset:"95%",stopColor:"#10b981",stopOpacity:0})]})}),(0,a.jsx)(d.d,{strokeDasharray:"3 3",strokeOpacity:.2}),(0,a.jsx)(n.W,{dataKey:"date",tick:{fontSize:11},tickFormatter:e=>e.slice(5)}),(0,a.jsx)(o.h,{tick:{fontSize:11},tickFormatter:p,width:48}),(0,a.jsx)(x.m,{formatter:e=>[p(e),"Tokens saved"],labelFormatter:e=>e}),(0,a.jsx)(c.Gk,{type:"monotone",dataKey:"tokensSavedEst",stroke:"#10b981",fill:"url(#gradPxpipe)",strokeWidth:2})]})}):(0,a.jsx)("div",{className:"h-32 flex items-center justify-center text-text-muted text-sm",children:"No savings recorded yet — enable PXPIPE in the Token Saver and route a large Claude-format request."})]}),(0,a.jsxs)(m.Zp,{className:"p-4",children:[(0,a.jsx)("h3",{className:"font-medium mb-3",children:"History"}),(0,a.jsx)("div",{className:"overflow-x-auto",children:(0,a.jsxs)("table",{className:"w-full text-sm",children:[(0,a.jsx)("thead",{children:(0,a.jsxs)("tr",{className:"text-left text-xs text-text-muted border-b border-border",children:[(0,a.jsx)("th",{className:"py-2 pr-3",children:"Time"}),(0,a.jsx)("th",{className:"py-2 pr-3",children:"Model"}),(0,a.jsx)("th",{className:"py-2 pr-3 text-right",children:"Original"}),(0,a.jsx)("th",{className:"py-2 pr-3 text-right",children:"Compressed"}),(0,a.jsx)("th",{className:"py-2 pr-3 text-right",children:"Saved"}),(0,a.jsx)("th",{className:"py-2 pr-3 text-right",children:"%"}),(0,a.jsx)("th",{className:"py-2 pr-3 text-right",children:"Duration"}),(0,a.jsx)("th",{className:"py-2",children:"Status"})]})}),(0,a.jsxs)("tbody",{children:[(b?.recent||[]).slice(0,50).map((e,t)=>(0,a.jsxs)("tr",{className:"border-b border-border/50",children:[(0,a.jsx)("td",{className:"py-1.5 pr-3 whitespace-nowrap text-text-muted",children:new Date(e.ts).toLocaleString()}),(0,a.jsx)("td",{className:"py-1.5 pr-3 font-mono text-xs",children:e.provider?`${e.provider}/${e.model}`:e.model||"—"}),(0,a.jsx)("td",{className:"py-1.5 pr-3 text-right font-mono text-xs",children:e.applied?p(e.tokensBeforeEst):"—"}),(0,a.jsx)("td",{className:"py-1.5 pr-3 text-right font-mono text-xs",children:e.applied?p(e.tokensAfterEst):"—"}),(0,a.jsx)("td",{className:"py-1.5 pr-3 text-right font-mono text-xs text-success",children:e.applied?p(e.tokensSavedEst):"—"}),(0,a.jsx)("td",{className:"py-1.5 pr-3 text-right font-mono text-xs",children:e.applied?`${e.savedPct}%`:"—"}),(0,a.jsx)("td",{className:"py-1.5 pr-3 text-right font-mono text-xs",children:null!=e.durationMs?`${e.durationMs}ms`:"—"}),(0,a.jsx)("td",{className:"py-1.5",children:(0,a.jsx)("span",{className:`text-xs px-2 py-0.5 rounded ${e.applied?"bg-success/15 text-success":"transform_error"===e.reason||"timeout"===e.reason?"bg-danger/15 text-danger":"bg-warning/15 text-warning"}`,title:e.detail||"",children:e.applied?"Compressed":u[e.reason]||e.reason})})]},`${e.ts}-${t}`)),(!b?.recent||0===b.recent.length)&&(0,a.jsx)("tr",{children:(0,a.jsx)("td",{colSpan:8,className:"py-6 text-center text-text-muted text-sm",children:"No PXPIPE activity yet"})})]})]})})]}),(0,a.jsxs)(m.Zp,{className:"p-4",id:"logs",children:[(0,a.jsx)("h3",{className:"font-medium mb-3",children:"PXPIPE Logs"}),N?.installLog?(0,a.jsx)("pre",{className:"rounded bg-black/5 dark:bg-white/5 p-3 text-xs font-mono overflow-x-auto max-h-64 overflow-y-auto whitespace-pre-wrap",children:N.installLog}):(0,a.jsx)("p",{className:"text-sm text-text-muted",children:"No install log yet."})]})]})}}},e=>{e.O(0,[763,3842,4285,1649,1321,705,5497,8441,3794,7358],()=>e(e.s=29216)),_N_E=e.O()}]);
|