zevairouter 1.0.210 → 1.0.212
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/CHANGELOG.md +10 -0
- package/cli/app/.next-cli-build/BUILD_ID +1 -1
- package/cli/app/.next-cli-build/app-path-routes-manifest.json +4 -3
- package/cli/app/.next-cli-build/build-manifest.json +2 -2
- package/cli/app/.next-cli-build/routes-manifest.json +6 -0
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/automation/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/automation/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page.js +3 -3
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/context/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/context/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/playground/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/playground/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page.js +3 -3
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/settings/pricing/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/settings/pricing/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/terminal/page.js +3 -3
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/terminal/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/_global-error/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/_global-error/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/_global-error.html +1 -1
- package/cli/app/.next-cli-build/server/app/_global-error.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/_global-error.segments/_global-error.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/_global-error.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/_global-error.segments/_index.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/_not-found/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/_not-found.html +1 -1
- package/cli/app/.next-cli-build/server/app/_not-found.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/_not-found.segments/_full.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/_not-found.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/_not-found.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/_not-found.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/api/auth/login/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/auth/logout/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/auth/oidc/callback/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/auth/oidc/start/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/auth/oidc/test/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/auth/status/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cache/stats/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/changelog/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/all-statuses/route.js +3 -3
- package/cli/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/alias/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/claude-settings/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/cline-settings/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/codex-gateway/accounts/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/codex-settings/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/copilot-settings/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-registry/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-tools/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/cowork-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/deepseek-tui-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/droid-settings/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/grok-build-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/hermes-settings/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/jcode-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/kilo-settings/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/cli-tools/openclaw-settings/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/cli-tools/opencode-settings/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/combos/[id]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/combos/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/context/[id]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/context/bulk/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/context/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/dashboard/chat/completions/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/dashboard/cli-tools/keys/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/dashboard/media/[operation]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/dashboard/media/videos/[id]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/headroom/enable/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/headroom/extras/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/headroom/proxy/[...path]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/headroom/restart/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/headroom/start/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/headroom/status/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/headroom/stop/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/health/ready/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/health/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/init/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/keys/[id]/rotate/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/keys/[id]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/keys/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/locale/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/mcp/[plugin]/message/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/mcp/[plugin]/sse/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/media-providers/tts/deepgram/voices/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/media-providers/tts/elevenlabs/voices/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/media-providers/tts/inworld/voices/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/media-providers/tts/minimax/voices/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/media-providers/tts/voices/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/metrics/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/models/alias/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/models/availability/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/models/custom/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/models/disabled/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/models/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/models/test/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/[provider]/[action]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/antigravity/bulk-import/[jobId]/cancel/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/antigravity/bulk-import/[jobId]/manual/[workerId]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/antigravity/bulk-import/[jobId]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/antigravity/bulk-import/latest/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/antigravity/bulk-import/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/cloudflare-ai/bulk-import/[jobId]/cancel/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/cloudflare-ai/bulk-import/[jobId]/manual/[workerId]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/cloudflare-ai/bulk-import/[jobId]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/cloudflare-ai/bulk-import/latest/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/cloudflare-ai/bulk-import/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy/bulk-import/[jobId]/cancel/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy/bulk-import/[jobId]/manual/[workerId]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy/bulk-import/[jobId]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy/bulk-import/latest/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy/bulk-import/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy/bulk-token/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy/quota-cookie/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy-cn/bulk-import/[jobId]/cancel/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy-cn/bulk-import/[jobId]/manual/[workerId]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy-cn/bulk-import/[jobId]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy-cn/bulk-import/latest/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy-cn/bulk-import/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy-cn/bulk-token/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codebuddy-cn/quota-cookie/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/codex/import-token/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/cursor/auto-import/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/oauth/cursor/import/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/gitlab/pat/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/[jobId]/cancel/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/[jobId]/manual/[workerId]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/[jobId]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/latest/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-token/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/iflow/cookie/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/api-key/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/auto-import/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/bulk-import/[jobId]/cancel/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/bulk-import/[jobId]/manual/[workerId]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/bulk-import/[jobId]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/bulk-import/latest/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/bulk-import/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/import/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/import-cli-proxy/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/social-authorize/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/kiro/social-exchange/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/qoder/bulk-import/[jobId]/cancel/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/qoder/bulk-import/[jobId]/manual/[workerId]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/qoder/bulk-import/[jobId]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/qoder/bulk-import/latest/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/oauth/qoder/bulk-import/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/pricing/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/provider-nodes/[id]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/provider-nodes/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/provider-nodes/validate/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/[id]/models/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/[id]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/[id]/test/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/[id]/test-models/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/bulk-delete/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/client/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/codebuddy/discover-models/route.js +5 -0
- package/cli/app/.next-cli-build/server/app/api/providers/codebuddy/discover-models/route.js.nft.json +1 -0
- package/cli/app/.next-cli-build/server/app/api/providers/codebuddy/discover-models/route_client-reference-manifest.js +1 -0
- package/cli/app/.next-cli-build/server/app/api/providers/kilo/free-models/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/suggested-models/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/test-batch/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/providers/validate/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/proxy-pools/[id]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/proxy-pools/[id]/test/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/proxy-pools/cloudflare-deploy/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/proxy-pools/deno-deploy/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/proxy-pools/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/proxy-pools/vercel-deploy/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/pxpipe/health/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/pxpipe/install/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/pxpipe/restart/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/pxpipe/start/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/pxpipe/stats/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/pxpipe/status/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/pxpipe/stop/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/settings/database/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/settings/proxy-test/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/settings/require-login/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/settings/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/shutdown/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/tags/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/terminal/auth/setup/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/terminal/auth/status/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/terminal/auth/unlock/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/terminal/session/[id]/input/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/terminal/session/[id]/resize/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/terminal/session/[id]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/terminal/session/[id]/stream/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/terminal/session/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/translator/console-logs/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/translator/console-logs/stream/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/translator/load/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/translator/save/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/translator/send/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/translator/translate/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/tunnel/disable/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/tunnel/enable/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/tunnel/status/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/tunnel/tailscale-check/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/tunnel/tailscale-disable/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/tunnel/tailscale-enable/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/tunnel/tailscale-install/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/usage/[connectionId]/codex-reset-credits/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/[connectionId]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/aggregate/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/chart/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/history/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/providers/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/request-details/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/request-logs/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/stats/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/usage/stream/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/api/v1/api/chat/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/audio/speech/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/audio/transcriptions/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/audio/voices/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/chat/completions/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/embeddings/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/images/generations/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/messages/count_tokens/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/messages/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/models/[kind]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/models/info/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/models/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/responses/compact/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/responses/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/search/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/videos/[id]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/videos/edits/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/videos/extensions/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/videos/generations/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1/web/fetch/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1beta/models/[...path]/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/v1beta/models/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/version/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/version/shutdown/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/api/version/update/route.js +1 -1
- package/cli/app/.next-cli-build/server/app/callback/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/callback/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/callback.html +1 -1
- package/cli/app/.next-cli-build/server/app/callback.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/callback.segments/_full.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/callback.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/callback.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/callback.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/callback.segments/callback/__PAGE__.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/callback.segments/callback.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/automation.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/automation.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/automation.segments/!KGRhc2hib2FyZCk/dashboard/automation/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/automation.segments/!KGRhc2hib2FyZCk/dashboard/automation.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/automation.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/automation.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/automation.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/automation.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/automation.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/automation.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/basic-chat.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/basic-chat.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk/dashboard/basic-chat/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk/dashboard/basic-chat.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/cli-tools.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/cli-tools.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk/dashboard/cli-tools/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk/dashboard/cli-tools.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/combos.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/combos.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk/dashboard/combos/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk/dashboard/combos.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/combos.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/combos.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/combos.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/combos.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/context.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/context.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/context.segments/!KGRhc2hib2FyZCk/dashboard/context/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/context.segments/!KGRhc2hib2FyZCk/dashboard/context.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/context.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/context.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/context.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/context.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/context.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/context.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/endpoint.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/endpoint.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk/dashboard/endpoint/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk/dashboard/endpoint.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/endpoint.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/endpoint.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/endpoint.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/endpoint.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/media-providers/web.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/media-providers/web.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard/media-providers/web/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard/media-providers/web.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard/media-providers.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/mitm.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/mitm.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk/dashboard/mitm/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk/dashboard/mitm.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/mitm.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/mitm.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/mitm.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/mitm.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/playground.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/playground.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/playground.segments/!KGRhc2hib2FyZCk/dashboard/playground/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/playground.segments/!KGRhc2hib2FyZCk/dashboard/playground.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/playground.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/playground.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/playground.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/playground.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/playground.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/playground.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/profile.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/profile.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk/dashboard/profile/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk/dashboard/profile.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/profile.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/profile.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/profile.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/profile.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/providers/new.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/providers/new.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard/providers/new/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard/providers/new.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard/providers.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/providers/new.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/providers/new.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/providers/new.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/providers/new.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/providers.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/providers.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk/dashboard/providers/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk/dashboard/providers.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/providers.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/providers.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/providers.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/providers.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/proxy-pools.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/proxy-pools.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk/dashboard/proxy-pools/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk/dashboard/proxy-pools.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/pxpipe.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/pxpipe.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/pxpipe.segments/!KGRhc2hib2FyZCk/dashboard/pxpipe/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/pxpipe.segments/!KGRhc2hib2FyZCk/dashboard/pxpipe.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/pxpipe.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/pxpipe.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/pxpipe.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/pxpipe.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/pxpipe.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/pxpipe.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/quota.html +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/quota.rsc +7 -7
- package/cli/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk/dashboard/quota/__PAGE__.segment.rsc +3 -3
- package/cli/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk/dashboard/quota.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/quota.segments/_full.segment.rsc +7 -7
- package/cli/app/.next-cli-build/server/app/dashboard/quota.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/quota.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/quota.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/settings/pricing.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/settings/pricing.rsc +5 -5
- package/cli/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/!KGRhc2hib2FyZCk/dashboard/settings/pricing/__PAGE__.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/!KGRhc2hib2FyZCk/dashboard/settings/pricing.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/!KGRhc2hib2FyZCk/dashboard/settings.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_full.segment.rsc +5 -5
- package/cli/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/skills.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/skills.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk/dashboard/skills/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk/dashboard/skills.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/skills.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/skills.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/skills.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/skills.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/token-saver.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/token-saver.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/token-saver.segments/!KGRhc2hib2FyZCk/dashboard/token-saver/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/token-saver.segments/!KGRhc2hib2FyZCk/dashboard/token-saver.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/token-saver.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/token-saver.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/token-saver.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/token-saver.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/token-saver.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/token-saver.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/translator.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/translator.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk/dashboard/translator/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk/dashboard/translator.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/translator.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/translator.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/translator.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/translator.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/usage.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/usage.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk/dashboard/usage/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk/dashboard/usage.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard/usage.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard/usage.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard/usage.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard/usage.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard.html +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard.segments/!KGRhc2hib2FyZCk/dashboard/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/dashboard.segments/_full.segment.rsc +6 -6
- package/cli/app/.next-cli-build/server/app/dashboard.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/dashboard.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/dashboard.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/index.html +1 -1
- package/cli/app/.next-cli-build/server/app/index.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/index.segments/__PAGE__.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/index.segments/_full.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/index.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/index.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/index.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/landing/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/landing/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/landing.html +1 -1
- package/cli/app/.next-cli-build/server/app/landing.rsc +5 -5
- package/cli/app/.next-cli-build/server/app/landing.segments/_full.segment.rsc +5 -5
- package/cli/app/.next-cli-build/server/app/landing.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/landing.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/landing.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/landing.segments/landing/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/landing.segments/landing.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/login/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/login/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/login.html +1 -1
- package/cli/app/.next-cli-build/server/app/login.rsc +5 -5
- package/cli/app/.next-cli-build/server/app/login.segments/_full.segment.rsc +5 -5
- package/cli/app/.next-cli-build/server/app/login.segments/_head.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/login.segments/_index.segment.rsc +4 -4
- package/cli/app/.next-cli-build/server/app/login.segments/_tree.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/login.segments/login/__PAGE__.segment.rsc +2 -2
- package/cli/app/.next-cli-build/server/app/login.segments/login.segment.rsc +1 -1
- package/cli/app/.next-cli-build/server/app/manifest.webmanifest/route.js +2 -2
- package/cli/app/.next-cli-build/server/app/page.js +2 -2
- package/cli/app/.next-cli-build/server/app/page_client-reference-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/app/provider-icons/[provider]/route.js +2 -2
- package/cli/app/.next-cli-build/server/app-paths-manifest.json +4 -3
- package/cli/app/.next-cli-build/server/chunks/1131.js +1 -1
- package/cli/app/.next-cli-build/server/chunks/3949.js +1 -1
- package/cli/app/.next-cli-build/server/chunks/3999.js +7 -7
- package/cli/app/.next-cli-build/server/chunks/4404.js +1 -1
- package/cli/app/.next-cli-build/server/chunks/4621.js +1 -1
- package/cli/app/.next-cli-build/server/chunks/4827.js +1 -1
- package/cli/app/.next-cli-build/server/chunks/7276.js +1 -1
- package/cli/app/.next-cli-build/server/chunks/7319.js +7 -7
- package/cli/app/.next-cli-build/server/chunks/8306.js +1 -1
- package/cli/app/.next-cli-build/server/middleware-build-manifest.js +1 -1
- package/cli/app/.next-cli-build/server/middleware.js +3 -3
- package/cli/app/.next-cli-build/server/pages/404.html +1 -1
- package/cli/app/.next-cli-build/server/pages/500.html +1 -1
- package/cli/app/.next-cli-build/static/BzMsXv9ScXjwLLAPOA1s5/_buildManifest.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/620-88bb27b140bd0326.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/providers/[id]/page-7aeac0028e9fd7e6.js +3 -0
- package/cli/app/.next-cli-build/static/chunks/app/_global-error/{page-3c4f5e0ab9b5451e.js → page-aff892d0f9519e0d.js} +1 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/auth/login/{route-3c4f5e0ab9b5451e.js → route-aff892d0f9519e0d.js} +1 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/auth/logout/{route-3c4f5e0ab9b5451e.js → route-aff892d0f9519e0d.js} +1 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/auth/oidc/callback/{route-3c4f5e0ab9b5451e.js → route-aff892d0f9519e0d.js} +1 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/auth/oidc/start/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/auth/oidc/test/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/auth/status/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cache/stats/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/changelog/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/all-statuses/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/alias/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/claude-settings/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/cline-settings/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/codex-gateway/accounts/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/codex-settings/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/copilot-settings/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-registry/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-tools/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-settings/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/deepseek-tui-settings/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/droid-settings/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/grok-build-settings/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/hermes-settings/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/jcode-settings/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/kilo-settings/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/openclaw-settings/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/opencode-settings/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/combos/[id]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/combos/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/context/[id]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/context/bulk/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/context/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/dashboard/chat/completions/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/dashboard/cli-tools/keys/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/dashboard/media/[operation]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/dashboard/media/videos/[id]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/headroom/enable/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/headroom/extras/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/headroom/proxy/[...path]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/headroom/restart/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/headroom/start/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/headroom/status/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/headroom/stop/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/health/ready/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/health/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/init/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/keys/[id]/rotate/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/keys/[id]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/keys/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/locale/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/message/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/sse/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/media-providers/tts/deepgram/voices/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/media-providers/tts/elevenlabs/voices/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/media-providers/tts/inworld/voices/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/media-providers/tts/minimax/voices/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/media-providers/tts/voices/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/metrics/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/models/alias/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/models/availability/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/models/custom/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/models/disabled/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/models/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/models/test/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/[provider]/[action]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/antigravity/bulk-import/[jobId]/cancel/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/antigravity/bulk-import/[jobId]/manual/[workerId]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/antigravity/bulk-import/[jobId]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/antigravity/bulk-import/latest/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/antigravity/bulk-import/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/cloudflare-ai/bulk-import/[jobId]/cancel/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/cloudflare-ai/bulk-import/[jobId]/manual/[workerId]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/cloudflare-ai/bulk-import/[jobId]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/cloudflare-ai/bulk-import/latest/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/cloudflare-ai/bulk-import/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy/bulk-import/[jobId]/cancel/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy/bulk-import/[jobId]/manual/[workerId]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy/bulk-import/[jobId]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy/bulk-import/latest/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy/bulk-import/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy/bulk-token/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy/quota-cookie/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy-cn/bulk-import/[jobId]/cancel/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy-cn/bulk-import/[jobId]/manual/[workerId]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy-cn/bulk-import/[jobId]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy-cn/bulk-import/latest/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy-cn/bulk-import/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy-cn/bulk-token/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy-cn/quota-cookie/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codex/import-token/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/cursor/auto-import/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/cursor/import/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/gitlab/pat/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/grok-cli/bulk-import/[jobId]/cancel/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/grok-cli/bulk-import/[jobId]/manual/[workerId]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/grok-cli/bulk-import/[jobId]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/grok-cli/bulk-import/latest/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/grok-cli/bulk-import/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/grok-cli/bulk-token/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/iflow/cookie/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/api-key/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/auto-import/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/bulk-import/[jobId]/cancel/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/bulk-import/[jobId]/manual/[workerId]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/bulk-import/[jobId]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/bulk-import/latest/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/bulk-import/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/import/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/import-cli-proxy/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-authorize/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-exchange/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/qoder/bulk-import/[jobId]/cancel/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/qoder/bulk-import/[jobId]/manual/[workerId]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/qoder/bulk-import/[jobId]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/qoder/bulk-import/latest/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/qoder/bulk-import/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/pricing/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/provider-nodes/[id]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/provider-nodes/validate/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/[id]/models/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/[id]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/[id]/test/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/[id]/test-models/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/bulk-delete/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/client/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/codebuddy/discover-models/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/kilo/free-models/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/suggested-models/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/test-batch/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/validate/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/test/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/proxy-pools/cloudflare-deploy/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/proxy-pools/deno-deploy/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/proxy-pools/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/proxy-pools/vercel-deploy/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/pxpipe/health/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/pxpipe/install/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/pxpipe/restart/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/pxpipe/start/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/pxpipe/stats/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/pxpipe/status/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/pxpipe/stop/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/settings/database/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/settings/proxy-test/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/settings/require-login/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/settings/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/shutdown/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/tags/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/terminal/auth/setup/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/terminal/auth/status/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/terminal/auth/unlock/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/terminal/session/[id]/input/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/terminal/session/[id]/resize/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/terminal/session/[id]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/terminal/session/[id]/stream/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/terminal/session/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/translator/console-logs/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/translator/console-logs/stream/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/translator/load/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/translator/save/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/translator/send/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/translator/translate/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/tunnel/disable/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/tunnel/enable/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/tunnel/status/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-check/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-disable/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-enable/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-install/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/codex-reset-credits/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/aggregate/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/chart/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/history/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/providers/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/request-details/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/request-logs/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/stats/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/stream/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/api/chat/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/audio/speech/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/audio/transcriptions/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/audio/voices/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/chat/completions/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/embeddings/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/images/generations/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/messages/count_tokens/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/messages/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/models/[kind]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/models/info/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/models/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/responses/compact/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/responses/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/search/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/videos/[id]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/videos/edits/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/videos/extensions/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/videos/generations/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/web/fetch/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1beta/models/[...path]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/v1beta/models/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/version/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/version/shutdown/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/api/version/update/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/manifest.webmanifest/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/page-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/app/provider-icons/[provider]/route-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/app-error-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/forbidden-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/not-found-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/unauthorized-aff892d0f9519e0d.js +1 -0
- package/cli/app/.next-cli-build/static/css/cfc8890c2da36deb.css +1 -0
- package/cli/app/CHANGELOG.md +10 -0
- package/cli/app/package.json +1 -1
- package/cli/package.json +1 -1
- package/package.json +1 -1
- package/cli/app/.next-cli-build/static/SZLutmtD5A-psdTs5ry4r/_buildManifest.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/620-f4e89661a47d7d77.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/providers/[id]/page-02e4cc59850ca612.js +0 -3
- package/cli/app/.next-cli-build/static/chunks/app/api/auth/oidc/start/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/auth/oidc/test/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/auth/status/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cache/stats/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/changelog/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/all-statuses/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/alias/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/claude-settings/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/cline-settings/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/codex-gateway/accounts/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/codex-settings/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/copilot-settings/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-registry/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-tools/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-settings/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/deepseek-tui-settings/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/droid-settings/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/grok-build-settings/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/hermes-settings/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/jcode-settings/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/kilo-settings/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/openclaw-settings/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/cli-tools/opencode-settings/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/combos/[id]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/combos/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/context/[id]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/context/bulk/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/context/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/dashboard/chat/completions/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/dashboard/cli-tools/keys/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/dashboard/media/[operation]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/dashboard/media/videos/[id]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/headroom/enable/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/headroom/extras/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/headroom/proxy/[...path]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/headroom/restart/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/headroom/start/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/headroom/status/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/headroom/stop/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/health/ready/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/health/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/init/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/keys/[id]/rotate/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/keys/[id]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/keys/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/locale/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/message/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/sse/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/media-providers/tts/deepgram/voices/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/media-providers/tts/elevenlabs/voices/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/media-providers/tts/inworld/voices/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/media-providers/tts/minimax/voices/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/media-providers/tts/voices/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/metrics/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/models/alias/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/models/availability/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/models/custom/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/models/disabled/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/models/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/models/test/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/[provider]/[action]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/antigravity/bulk-import/[jobId]/cancel/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/antigravity/bulk-import/[jobId]/manual/[workerId]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/antigravity/bulk-import/[jobId]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/antigravity/bulk-import/latest/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/antigravity/bulk-import/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/cloudflare-ai/bulk-import/[jobId]/cancel/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/cloudflare-ai/bulk-import/[jobId]/manual/[workerId]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/cloudflare-ai/bulk-import/[jobId]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/cloudflare-ai/bulk-import/latest/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/cloudflare-ai/bulk-import/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy/bulk-import/[jobId]/cancel/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy/bulk-import/[jobId]/manual/[workerId]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy/bulk-import/[jobId]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy/bulk-import/latest/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy/bulk-import/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy/bulk-token/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy/quota-cookie/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy-cn/bulk-import/[jobId]/cancel/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy-cn/bulk-import/[jobId]/manual/[workerId]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy-cn/bulk-import/[jobId]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy-cn/bulk-import/latest/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy-cn/bulk-import/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy-cn/bulk-token/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codebuddy-cn/quota-cookie/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/codex/import-token/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/cursor/auto-import/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/cursor/import/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/gitlab/pat/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/grok-cli/bulk-import/[jobId]/cancel/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/grok-cli/bulk-import/[jobId]/manual/[workerId]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/grok-cli/bulk-import/[jobId]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/grok-cli/bulk-import/latest/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/grok-cli/bulk-import/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/grok-cli/bulk-token/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/iflow/cookie/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/api-key/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/auto-import/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/bulk-import/[jobId]/cancel/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/bulk-import/[jobId]/manual/[workerId]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/bulk-import/[jobId]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/bulk-import/latest/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/bulk-import/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/import/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/import-cli-proxy/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-authorize/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-exchange/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/qoder/bulk-import/[jobId]/cancel/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/qoder/bulk-import/[jobId]/manual/[workerId]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/qoder/bulk-import/[jobId]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/qoder/bulk-import/latest/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/oauth/qoder/bulk-import/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/pricing/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/provider-nodes/[id]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/provider-nodes/validate/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/[id]/models/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/[id]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/[id]/test/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/[id]/test-models/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/bulk-delete/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/client/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/kilo/free-models/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/suggested-models/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/test-batch/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/providers/validate/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/test/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/proxy-pools/cloudflare-deploy/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/proxy-pools/deno-deploy/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/proxy-pools/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/proxy-pools/vercel-deploy/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/pxpipe/health/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/pxpipe/install/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/pxpipe/restart/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/pxpipe/start/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/pxpipe/stats/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/pxpipe/status/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/pxpipe/stop/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/settings/database/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/settings/proxy-test/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/settings/require-login/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/settings/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/shutdown/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/tags/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/terminal/auth/setup/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/terminal/auth/status/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/terminal/auth/unlock/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/terminal/session/[id]/input/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/terminal/session/[id]/resize/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/terminal/session/[id]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/terminal/session/[id]/stream/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/terminal/session/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/translator/console-logs/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/translator/console-logs/stream/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/translator/load/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/translator/save/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/translator/send/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/translator/translate/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/tunnel/disable/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/tunnel/enable/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/tunnel/status/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-check/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-disable/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-enable/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-install/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/codex-reset-credits/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/aggregate/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/chart/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/history/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/providers/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/request-details/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/request-logs/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/stats/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/usage/stream/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/api/chat/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/audio/speech/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/audio/transcriptions/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/audio/voices/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/chat/completions/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/embeddings/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/images/generations/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/messages/count_tokens/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/messages/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/models/[kind]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/models/info/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/models/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/responses/compact/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/responses/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/search/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/videos/[id]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/videos/edits/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/videos/extensions/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/videos/generations/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1/web/fetch/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1beta/models/[...path]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/v1beta/models/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/version/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/version/shutdown/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/api/version/update/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/manifest.webmanifest/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/page-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/app/provider-icons/[provider]/route-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/app-error-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/forbidden-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/not-found-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/unauthorized-3c4f5e0ab9b5451e.js +0 -1
- package/cli/app/.next-cli-build/static/css/6cb80a431dc9a5ae.css +0 -1
- /package/cli/app/.next-cli-build/static/{SZLutmtD5A-psdTs5ry4r → BzMsXv9ScXjwLLAPOA1s5}/_ssgManifest.js +0 -0
|
@@ -2,4 +2,4 @@ exports.id=3949,exports.ids=[3949],exports.modules={12897:(a,b,c)=>{"use strict"
|
|
|
2
2
|
${b?.stderr||""}
|
|
3
3
|
${b?.message||""}`),/(?:invalid choice|unknown (?:command|subcommand)|unrecognized (?:argument|command)|no such command)/i.test(a))return null;throw new u(`Failed to discover the active Hermes ${e} path`,{code:"HERMES_PATH_DISCOVERY_FAILED",status:422})}return function(a,{platform:b,label:c}){let d="win32"===b?i().win32:i().posix,e=String(a??""),f=e.endsWith("\r\n")?e.slice(0,-2):e.endsWith("\n")?e.slice(0,-1):e;if(!(f.length>0&&f.length<=32768&&f===f.trim()&&!/[\u0000-\u001f\u007f]/.test(f)&&d.isAbsolute(f)))throw new u(`Hermes returned an invalid ${c} path`,{code:"HERMES_PATH_INVALID",status:422});return d.normalize(f)}(f?.stdout,{platform:c,label:e})},f=await e("path","config");if(!f)return b;let g=await e("env-path","environment");if(!g)return b;let h="win32"===c?i().win32:i().posix;if(y(h.dirname(f),c)!==y(h.dirname(g),c))throw new u("Hermes config and environment paths use different profiles",{code:"HERMES_PATH_INVALID",status:422});return{...b,configDir:h.dirname(f),configPath:f,envPath:g}}async function X({env:a=process.env,platform:b=n().platform(),homedir:c=n().homedir(),access:d=g().access,realpath:e=g().realpath,runVersion:f=U}={}){let h="win32"===b?l.constants.F_OK:l.constants.X_OK;for(let g of function({env:a,platform:b,homedir:c}){let d="win32"===b?i().win32:i().posix,e=x({env:a,platform:b,homedir:c}).configDir,f="win32"===b?["hermes.exe","hermes"]:["hermes"],g=String(a.PATH||"").split(d.delimiter).map(a=>a.trim().replace(/^"|"$/g,"")).filter(Boolean).flatMap(a=>f.map(b=>d.resolve(a,b)));return"win32"===b?g.push(d.join(e,"hermes-agent","venv","Scripts","hermes.exe")):(g.push(d.join(e,"hermes-agent","venv","bin","hermes")),g.push(d.join(c,".local","bin","hermes")),g.push("/usr/local/bin/hermes"),a.PREFIX&&g.push(d.join(a.PREFIX,"bin","hermes"))),[...new Set(g)]}({env:a,platform:b,homedir:c})){try{await d(g,h)}catch{continue}for(let a of[["--version"],["version"]])try{let b=await f(g,a),c=function(a){let b=S(a).match(/(?:^|\r?\n)\s*Hermes Agent\s+v?(\d+\.\d+\.\d+(?:[-+][0-9A-Za-z.-]+)?)(?:\s|$)/i);return b?.[1]||null}(`${b?.stdout||""}
|
|
4
4
|
${b?.stderr||""}`);if(!c)continue;let d=g;try{d=await e(g)}catch{}return{installed:!0,binaryPath:d,version:c}}catch{}}return{installed:!1,binaryPath:null,version:null}}var Y=c(30869),Z=c(24424);let $="zevairouter-host",_=Promise.resolve();function aa(a){let b=String(a??"");if(!/^[0-9]+$/.test(b))return null;let c=Number(b);return Number.isSafeInteger(c)&&c>=1&&c<=65535?c:null}function ab(a){let b=_.then(a,a);return _=b.catch(()=>{}),b}function ac(a,b){return{installationTarget:$,platform:process.platform,configDir:a.configDir,configPath:a.configPath,envPath:a.envPath,binaryPath:b?.binaryPath||null,version:b?.version||null,supported:!!(b?.installed&&T(b.version)),localBaseUrl:function(){let a=aa(process.env.PORT)??aa(Y.h0.appPort);if(null===a)throw Error("ZevaiRouter app port configuration is invalid");return`http://127.0.0.1:${a}/v1`}()}}function ad(a,b=!1){return{available:a,restorable:b,conflict:a&&!b}}function ae(a,b){return a instanceof u?j.NextResponse.json({error:a.message,code:a.code,installationTarget:$},{status:a.status}):a instanceof SyntaxError?j.NextResponse.json({error:"Request body must be valid JSON",code:"INVALID_HERMES_SETTINGS",installationTarget:$},{status:400}):(console.error(b,a instanceof Error?a.message:a),j.NextResponse.json({error:b,code:"HERMES_IO_ERROR",installationTarget:$},{status:500}))}async function af(a,b){let c;try{let d;c=await g().open(a,"r");let e=await c.stat();if(!e.isFile())throw new u("Hermes settings path is not a regular file",{code:"HERMES_PATH_INVALID",status:422});if(e.size>b)throw new u("Hermes settings file is too large to update safely",{code:"HERMES_FILE_TOO_LARGE",status:422});let f=Buffer.allocUnsafe(b+1),h=0;for(;h<f.length;){let{bytesRead:a}=await c.read(f,h,f.length-h,h);if(0===a)break;h+=a}if(h>b)throw new u("Hermes settings file is too large to update safely",{code:"HERMES_FILE_TOO_LARGE",status:422});let i=f.subarray(0,h);try{d=new TextDecoder("utf-8",{fatal:!0}).decode(i)}catch{throw new u("Hermes settings file is not valid UTF-8",{code:"HERMES_FILE_ENCODING_INVALID",status:422})}return{exists:!0,text:d,mode:511&e.mode,uid:"win32"===process.platform?null:e.uid,gid:"win32"===process.platform?null:e.gid}}catch(a){if(a?.code==="ENOENT")return{exists:!1,text:"",mode:null,uid:null,gid:null};throw a}finally{c&&await c.close().catch(()=>{})}}async function ag(a){try{let b=await g().stat(a,{bigint:!0});if(!b.isFile())throw new u("Hermes backup path is not a regular file",{code:"HERMES_PATH_INVALID",status:422});return{exists:!0,dev:b.dev,ino:b.ino,size:b.size,mode:b.mode,uid:b.uid,gid:b.gid,mtimeNs:b.mtimeNs,ctimeNs:b.ctimeNs}}catch(a){if(a?.code==="ENOENT")return{exists:!1};throw a}}async function ah(a,b){let c=await ag(a);if(!["exists","dev","ino","size","mode","uid","gid","mtimeNs","ctimeNs"].every(a=>c[a]===b[a]))throw new u("Hermes backup changed while it was being discarded",{code:"HERMES_CONFIG_CHANGED",status:409})}async function ai(a){let b;if("win32"!==process.platform)try{b=await g().open(a,"r"),await b.sync()}catch(a){if(!["EBADF","EINVAL","ENOTSUP"].includes(a?.code))throw a}finally{b&&await b.close().catch(()=>{})}}async function aj(a,b,c,{uid:d=null,gid:f=null}={}){let h,j=i().dirname(a);await g().mkdir(j,{recursive:!0,mode:448});let k=i().join(j,`.${i().basename(a)}.${process.pid}.${(0,e.randomUUID)()}.tmp`);try{h=await g().open(k,"wx",c),await h.writeFile(b,"utf8"),"win32"!==process.platform&&Number.isInteger(d)&&Number.isInteger(f)&&(d!==process.getuid()||f!==process.getgid())&&await h.chown(d,f),await h.chmod(c),await h.sync(),await h.close(),h=null,await g().rename(k,a),await ai(j)}finally{h&&await h.close().catch(()=>{}),await g().unlink(k).catch(()=>{})}}async function ak(a){try{await g().unlink(a),await ai(i().dirname(a))}catch(a){if(a?.code!=="ENOENT")throw a}}async function al(a,b){let{exists:c,text:d,mode:e}=b;c?await aj(a,d,e??384,b):await ak(a)}async function am(a,b,c){let d=await af(a,c);if(d.exists!==b.exists||d.text!==b.text||d.mode!==b.mode||d.uid!==b.uid||d.gid!==b.gid)throw new u("Hermes settings changed while the operation was in progress",{code:"HERMES_CONFIG_CHANGED",status:409})}function an(a,b){return a.exists===b.exists&&(!a.exists||a.text===b.text&&a.mode===b.mode&&(null===b.uid||a.uid===b.uid)&&(null===b.gid||a.gid===b.gid))}function ao(a,b){return null!==a?a:"win32"===process.platform?null:b()}async function ap(a,b,c,d){try{let e=await af(a,d),f=an(e,c),g=an(e,b);return f&&await al(a,b),f||g}catch{return!1}}async function aq(a){let b=await af(a.backupPath,262144);return{snapshot:b,backup:b.exists?function(a){let b;try{b=JSON.parse(a)}catch{throw new u("Hermes ZevaiRouter backup is not valid JSON",{code:"HERMES_BACKUP_INVALID",status:409})}if(!(b?.version===1&&b.paths&&"string"==typeof b.paths.configPath&&"string"==typeof b.paths.envPath&&"boolean"==typeof b.before?.configFileExisted&&"boolean"==typeof b.before?.envFileExisted&&Q(b.before.configMode)&&Q(b.before.envMode)&&P(b.before.model)&&"boolean"==typeof b.before?.env?.exists&&(!b.before.env.exists||"string"==typeof b.before.env.line)&&P(b.applied?.model)&&"string"==typeof b.applied?.envHash&&Q(b.applied?.configMode)&&Q(b.applied?.envMode)))throw new u("Hermes ZevaiRouter backup has an unsupported format",{code:"HERMES_BACKUP_INVALID",status:409});return b}(b.text):null}}async function ar(a,b,c){try{let{backup:d}=await aq(a);if(!d)return ad(!1);let e=R(d,{configText:b.text,envText:c.text,configPath:a.configPath,envPath:a.envPath,configMode:b.mode,envMode:c.mode});return ad(!0,e)}catch{return ad(!0,!1)}}function as(a){if(!function(a,{platform:b=n().platform()}={}){let c=[a.configPath,a.envPath,a.backupPath].map(a=>y(a,b));return new Set(c).size===c.length}(a))throw new u("Hermes config, environment, and backup paths must be different",{code:"HERMES_PATH_INVALID",status:422})}async function at(a){try{return await g().realpath(a)}catch(a){if(a?.code!=="ENOENT")throw a}try{if((await g().lstat(a)).isSymbolicLink())throw new u("Hermes settings path is a dangling symbolic link",{code:"HERMES_PATH_INVALID",status:422})}catch(a){if(a?.code!=="ENOENT")throw a}let b=i().dirname(a),c=[i().basename(a)];for(;;){try{let a=await g().realpath(b);return i().join(a,...c)}catch(a){if(a?.code!=="ENOENT")throw a}let d=i().dirname(b);if(d===b)return a;c.unshift(i().basename(b)),b=d}}async function au(a){let[b,c,d]=await Promise.all([at(a.configPath),at(a.envPath),at(a.backupPath)]);return{...a,configDir:i().dirname(b),configPath:b,envPath:c,backupPath:d}}async function av({useBackupPathsWhenUnavailable:a=!1}={}){let b,c=await X(),d=x();if(c.installed)b=await W({installation:c,fallbackPaths:d});else if(a){let a=await au(d);try{let{backup:c}=await aq(a);b=c?function(a,b){if([b?.paths?.configPath,b?.paths?.envPath].some(a=>"string"!=typeof a||!i().isAbsolute(a)||/[\u0000-\u001f\u007f]/.test(a)))throw new u("Hermes backup contains invalid settings paths",{code:"HERMES_BACKUP_INVALID",status:409});return{...a,configDir:i().dirname(b.paths.configPath),configPath:b.paths.configPath,envPath:b.paths.envPath}}(d,c):d}catch{b=d}}else b=d;let e=await au(b);return as(e),{installation:c,paths:e}}async function aw(){try{let{installation:a,paths:b}=await av({useBackupPathsWhenUnavailable:!0}),c=await af(b.configPath,5242880),d=await af(b.envPath,1048576),e=await ar(b,c,d);if(!a.installed)return j.NextResponse.json({installed:!1,...ac(b,a),settings:{model:null},hasZevai:!1,backup:e,message:"Hermes Agent is not installed on the ZevaiRouter host"});let f=function(a){let b=A(a),c=b.get("model",!0);if(!(0,p.jh)(c))return{model:null,hasZevai:!1};let d=C(b)?.model,e=a=>{let b=d?.[a];return"string"==typeof b?b:null},f=e("provider"),g=e("base_url"),h=e("api_key"),i=e("api_mode"),j=null;try{let a=new URL(g);["http:","https:"].includes(a.protocol)&&(a.username="",a.password="",a.search="",a.hash="",j=a.toString().replace(/\/$/,""))}catch{}let k={default:e("default"),provider:f,base_url:j,api_mode:i},l=!1;try{l=["http:","https:"].includes(new URL(g).protocol)}catch{}return{model:k,hasZevai:("custom"===f||f?.startsWith("custom:"))&&l&&h===s&&"chat_completions"===i}}(c.text);return j.NextResponse.json({installed:!0,...ac(b,a),settings:{model:f.model},hasZevai:f.hasZevai,backup:e})}catch(a){return ae(a,"Failed to inspect Hermes settings on the ZevaiRouter host")}}async function ax(a){return ab(async()=>{try{var b;let c=function(a){let b;(!a||"object"!=typeof a||Array.isArray(a))&&v("Request body must be an object");let c=z(a.model,"model",512);(c.toLowerCase().endsWith("/model-id")||/[<>]/.test(c))&&v("model must be a real model identifier, not a placeholder");let d=z(a.apiKey,"apiKey",8192);/^[A-Za-z0-9._~+/=@:%-]+$/.test(d)||v("apiKey contains unsupported characters");let e=z(a.baseUrl,"baseUrl",2048);try{b=new URL(e)}catch{v("baseUrl must be a valid URL")}b&&["http:","https:"].includes(b.protocol)&&b.hostname||v("baseUrl must use http or https"),(b.username||b.password||b.search||b.hash)&&v("baseUrl must not include credentials, a query, or a fragment");let f=b.pathname.replace(/\/+$/,"");return b.pathname=/\/v1$/i.test(f)?`${f.slice(0,-3)}/v1`:`${f}/v1`,{model:c,apiKey:d,baseUrl:b.toString().replace(/\/$/,"")}}(await a.json()),{installation:d,paths:e}=await av();if(!d.installed)throw new u("Hermes Agent is not installed on the ZevaiRouter host",{code:"HERMES_NOT_INSTALLED",status:409});if(!T(d.version))throw new u("Hermes Agent 0.4.0 or newer is required for ZevaiRouter-managed API keys",{code:"HERMES_VERSION_UNSUPPORTED",status:422});let f=await af(e.configPath,5242880),g=await af(e.envPath,1048576),h=await aq(e),i=h.backup;if(i&&!R(i,{configText:f.text,envText:g.text,configPath:e.configPath,envPath:e.envPath,configMode:f.mode,envMode:g.mode}))throw new u("Hermes settings changed after the previous ZevaiRouter Apply; reset or reconcile them first",{code:"HERMES_CONFIG_CHANGED",status:409});let k=function(a,{model:b,baseUrl:c}){let d=A(a),e=F(d),f=d.get("model",!0);for(let[a,e]of((0,p.jh)(f)||(f=H(d,"model",{})),Object.entries({default:b,provider:"custom",base_url:c,api_key:s,api_mode:"chat_completions"})))H(f,a,e);return{text:d.toString(),before:e,applied:F(d)}}(f.text,c),l=function(a,b){let c=M(a),d=c?{exists:!0,line:c.content}:{exists:!1},e=`${r}=${b}`,f=J(a);if(c)f[c.index]=`${e}${L(c.line)}`;else{if(f.length>0&&!/(?:\r\n|\n|\r)$/.test(f.at(-1))){let b=a.includes("\r\n")?"\r\n":"\n";f[f.length-1]+=b}let b=a.includes("\r\n")?"\r\n":"\n";f.push(`${e}${b}`)}return{text:f.join(""),before:d,appliedHash:N(e)}}(g.text,c.apiKey),m=(b=function({paths:a,priorBackup:b=null,configFileExisted:c,envFileExisted:d,configMode:e,envMode:f,configBefore:g,envBefore:h,configApplied:i,envAppliedHash:j,configAppliedMode:k,envAppliedMode:l,now:m=new Date}){return{version:1,createdAt:b?.createdAt||m.toISOString(),updatedAt:m.toISOString(),paths:{configPath:a.configPath,envPath:a.envPath},before:b?.before||{configFileExisted:c,envFileExisted:d,configMode:e,envMode:f,model:g,env:h},applied:{model:i,envHash:j,configMode:k,envMode:l}}}({paths:e,priorBackup:i,configFileExisted:f.exists,envFileExisted:g.exists,configMode:f.mode,envMode:g.mode,configBefore:k.before,envBefore:l.before,configApplied:k.applied,envAppliedHash:l.appliedHash,configAppliedMode:"win32"===process.platform?null:f.mode??384,envAppliedMode:"win32"===process.platform?null:384}),`${JSON.stringify(b,null,2)}
|
|
5
|
-
`);if(Buffer.byteLength(m,"utf8")>262144)throw new u("Hermes managed settings are too large to back up safely",{code:"HERMES_BACKUP_TOO_LARGE",status:422});await am(e.configPath,f,5242880),await am(e.envPath,g,1048576),await am(e.backupPath,h.snapshot,262144);let n={exists:!0,text:m,mode:384,uid:ao(h.snapshot.uid,()=>process.getuid()),gid:ao(h.snapshot.gid,()=>process.getgid())},o={exists:!0,text:k.text,mode:f.mode??384,uid:ao(f.uid,()=>process.getuid()),gid:ao(f.gid,()=>process.getgid())},q={exists:!0,text:l.text,mode:384,uid:ao(g.uid,()=>process.getuid()),gid:ao(g.gid,()=>process.getgid())};try{await al(e.backupPath,n),await al(e.configPath,o),await al(e.envPath,q)}catch(d){let a=await ap(e.envPath,g,q,1048576),b=await ap(e.configPath,f,o,5242880),c=!!a&&!!b&&await ap(e.backupPath,h.snapshot,n,262144);throw a&&b&&c||console.error("Hermes Apply rollback could not safely restore every file"),d}return j.NextResponse.json({success:!0,message:"Hermes settings applied on the ZevaiRouter host",...ac(e,d),backup:ad(!0,!0)})}catch(a){return ae(a,"Failed to update Hermes settings on the ZevaiRouter host")}})}async function ay(a){return ab(async()=>{try{if(a?.url&&"1"===new URL(a.url,"http://localhost").searchParams.get("discard")){let a=await au(x());as(a);let b=await ag(a.backupPath);if(!b.exists)throw new u("No ZevaiRouter Hermes backup is available to discard",{code:"HERMES_BACKUP_NOT_FOUND",status:404});return await ah(a.backupPath,b),await ak(a.backupPath),j.NextResponse.json({success:!0,discarded:!0,message:"Hermes backup discarded; config and environment settings were not changed",installationTarget:$,configPath:a.configPath,envPath:a.envPath,backup:ad(!1)})}let{paths:b}=await av({useBackupPathsWhenUnavailable:!0}),c=await af(b.configPath,5242880),d=await af(b.envPath,1048576),e=await aq(b);if(!e.backup)throw new u("No ZevaiRouter Hermes backup is available to restore",{code:"HERMES_BACKUP_NOT_FOUND",status:404});let f=e.backup;if(!R(f,{configText:c.text,envText:d.text,configPath:b.configPath,envPath:b.envPath,configMode:c.mode,envMode:d.mode}))throw new u("Hermes managed settings changed after ZevaiRouter applied them",{code:"HERMES_CONFIG_CHANGED",status:409});let g=I(c.text,f.before.model,f.applied.model),h=O(d.text,f.before.env,f.applied.envHash),i={exists:f.before.configFileExisted||"{}"!==g.trim(),text:g,mode:f.before.configMode??384,uid:c.uid,gid:c.gid},k={exists:f.before.envFileExisted||h.trim().length>0,text:h,mode:f.before.envMode??384,uid:d.uid,gid:d.gid};await am(b.configPath,c,5242880),await am(b.envPath,d,1048576),await am(b.backupPath,e.snapshot,262144);try{await al(b.configPath,i),await al(b.envPath,k),await ak(b.backupPath)}catch(f){let a=await ap(b.envPath,d,k,1048576),e=await ap(b.configPath,c,i,5242880);throw a&&e||console.error("Hermes Reset rollback could not safely restore every file"),f}return j.NextResponse.json({success:!0,message:"Previous Hermes settings restored on the ZevaiRouter host",installationTarget:$,configPath:b.configPath,envPath:b.envPath,backup:ad(!1)})}catch(b){let a=ae(b,"Failed to restore Hermes settings on the ZevaiRouter host");if(b instanceof u&&"HERMES_CONFIG_CHANGED"===b.code)return j.NextResponse.json({error:b.message,code:b.code,installationTarget:$,backup:ad(!0,!1)},{status:b.status});return a}})}(0,Z.D)([aw,ax,ay]),(0,d.A)(aw,"00ba3352bae61e90fe842da8971769749305cc5ce8",null),(0,d.A)(ax,"40634a43bd5ceded48b51bd424b01b8e681a76eed0",null),(0,d.A)(ay,"40f13f03b31ba8f5619033b52eaea86644ad879468",null)},30869:(a,b,c)=>{"use strict";c.d(b,{UY:()=>h,X3:()=>j,eh:()=>f.eh,fg:()=>e.fg,h0:()=>g,oc:()=>i});var d=c(39006),e=c(75681),f=c(81329);d.version;let g={npmPackageName:"zevairouter",installCmd:"npm i -g zevairouter",installCmdLatest:"npm i -g zevairouter@latest --prefer-online",shutdownCountdownSec:3,exitDelayMs:500,statusPort:20129,statusPollIntervalMs:1e3,statusLogTailLines:8,installRetries:3,installRetryDelayMs:5e3,lingerAfterDoneMs:3e4,waitForExitMinMs:5e3,waitForExitMaxMs:2e4,waitForExitCheckMs:500,appPort:1997},h={maxLines:200,pollIntervalMs:1e3},i={tickIntervalMs:6e4,pingLeadMs:5e3,refreshAheadMs:3e5,failureCooldownMs:9e5,providers:{claude:{settingsKey:"claudeAutoPing",quotaKey:"session (5h)",pingModel:"claude-haiku-4-5-20251001",pingText:"hi",pingMaxTokens:1},codex:{settingsKey:"codexAutoPing",quotaKey:"session",pingWhenResetAtSlides:!0,resetAtDriftMs:3e4,minPingIntervalMs:6e5,skipWhenBlockingQuotaExhausted:!0,pingModel:"gpt-5.5",pingText:"hi",pingInstructions:"Reply with OK.",pingReasoningEffort:"none"}}},j={openrouter:"https://openrouter.ai/api/v1/chat/completions",glm:"https://api.z.ai/api/anthropic/v1/messages","glm-cn":"https://open.bigmodel.cn/api/coding/paas/v4/chat/completions",kimi:"https://api.kimi.com/coding/v1/messages",minimax:"https://api.minimax.io/anthropic/v1/messages","minimax-cn":"https://api.minimaxi.com/anthropic/v1/messages",alicode:"https://coding.dashscope.aliyuncs.com/v1/chat/completions","alicode-intl":"https://coding-intl.dashscope.aliyuncs.com/v1/chat/completions","volcengine-ark":"https://ark.cn-beijing.volces.com/api/coding/v3/chat/completions",byteplus:"https://ark.ap-southeast.bytepluses.com/api/coding/v3/chat/completions",openai:"https://api.openai.com/v1/chat/completions","vercel-ai-gateway":"https://ai-gateway.vercel.sh/v1/chat/completions",anthropic:"https://api.anthropic.com/v1/messages",gemini:"https://generativelanguage.googleapis.com/v1beta/models",ollama:"https://ollama.com/api/chat","ollama-local":"http://localhost:11434/api/chat","notion-ai":"https://app.notion.com/api/v3/runInferenceTranscript"}},39006:a=>{"use strict";a.exports=JSON.parse('{"name":"zevairouter","version":"1.0.
|
|
5
|
+
`);if(Buffer.byteLength(m,"utf8")>262144)throw new u("Hermes managed settings are too large to back up safely",{code:"HERMES_BACKUP_TOO_LARGE",status:422});await am(e.configPath,f,5242880),await am(e.envPath,g,1048576),await am(e.backupPath,h.snapshot,262144);let n={exists:!0,text:m,mode:384,uid:ao(h.snapshot.uid,()=>process.getuid()),gid:ao(h.snapshot.gid,()=>process.getgid())},o={exists:!0,text:k.text,mode:f.mode??384,uid:ao(f.uid,()=>process.getuid()),gid:ao(f.gid,()=>process.getgid())},q={exists:!0,text:l.text,mode:384,uid:ao(g.uid,()=>process.getuid()),gid:ao(g.gid,()=>process.getgid())};try{await al(e.backupPath,n),await al(e.configPath,o),await al(e.envPath,q)}catch(d){let a=await ap(e.envPath,g,q,1048576),b=await ap(e.configPath,f,o,5242880),c=!!a&&!!b&&await ap(e.backupPath,h.snapshot,n,262144);throw a&&b&&c||console.error("Hermes Apply rollback could not safely restore every file"),d}return j.NextResponse.json({success:!0,message:"Hermes settings applied on the ZevaiRouter host",...ac(e,d),backup:ad(!0,!0)})}catch(a){return ae(a,"Failed to update Hermes settings on the ZevaiRouter host")}})}async function ay(a){return ab(async()=>{try{if(a?.url&&"1"===new URL(a.url,"http://localhost").searchParams.get("discard")){let a=await au(x());as(a);let b=await ag(a.backupPath);if(!b.exists)throw new u("No ZevaiRouter Hermes backup is available to discard",{code:"HERMES_BACKUP_NOT_FOUND",status:404});return await ah(a.backupPath,b),await ak(a.backupPath),j.NextResponse.json({success:!0,discarded:!0,message:"Hermes backup discarded; config and environment settings were not changed",installationTarget:$,configPath:a.configPath,envPath:a.envPath,backup:ad(!1)})}let{paths:b}=await av({useBackupPathsWhenUnavailable:!0}),c=await af(b.configPath,5242880),d=await af(b.envPath,1048576),e=await aq(b);if(!e.backup)throw new u("No ZevaiRouter Hermes backup is available to restore",{code:"HERMES_BACKUP_NOT_FOUND",status:404});let f=e.backup;if(!R(f,{configText:c.text,envText:d.text,configPath:b.configPath,envPath:b.envPath,configMode:c.mode,envMode:d.mode}))throw new u("Hermes managed settings changed after ZevaiRouter applied them",{code:"HERMES_CONFIG_CHANGED",status:409});let g=I(c.text,f.before.model,f.applied.model),h=O(d.text,f.before.env,f.applied.envHash),i={exists:f.before.configFileExisted||"{}"!==g.trim(),text:g,mode:f.before.configMode??384,uid:c.uid,gid:c.gid},k={exists:f.before.envFileExisted||h.trim().length>0,text:h,mode:f.before.envMode??384,uid:d.uid,gid:d.gid};await am(b.configPath,c,5242880),await am(b.envPath,d,1048576),await am(b.backupPath,e.snapshot,262144);try{await al(b.configPath,i),await al(b.envPath,k),await ak(b.backupPath)}catch(f){let a=await ap(b.envPath,d,k,1048576),e=await ap(b.configPath,c,i,5242880);throw a&&e||console.error("Hermes Reset rollback could not safely restore every file"),f}return j.NextResponse.json({success:!0,message:"Previous Hermes settings restored on the ZevaiRouter host",installationTarget:$,configPath:b.configPath,envPath:b.envPath,backup:ad(!1)})}catch(b){let a=ae(b,"Failed to restore Hermes settings on the ZevaiRouter host");if(b instanceof u&&"HERMES_CONFIG_CHANGED"===b.code)return j.NextResponse.json({error:b.message,code:b.code,installationTarget:$,backup:ad(!0,!1)},{status:b.status});return a}})}(0,Z.D)([aw,ax,ay]),(0,d.A)(aw,"00ba3352bae61e90fe842da8971769749305cc5ce8",null),(0,d.A)(ax,"40634a43bd5ceded48b51bd424b01b8e681a76eed0",null),(0,d.A)(ay,"40f13f03b31ba8f5619033b52eaea86644ad879468",null)},30869:(a,b,c)=>{"use strict";c.d(b,{UY:()=>h,X3:()=>j,eh:()=>f.eh,fg:()=>e.fg,h0:()=>g,oc:()=>i});var d=c(39006),e=c(75681),f=c(81329);d.version;let g={npmPackageName:"zevairouter",installCmd:"npm i -g zevairouter",installCmdLatest:"npm i -g zevairouter@latest --prefer-online",shutdownCountdownSec:3,exitDelayMs:500,statusPort:20129,statusPollIntervalMs:1e3,statusLogTailLines:8,installRetries:3,installRetryDelayMs:5e3,lingerAfterDoneMs:3e4,waitForExitMinMs:5e3,waitForExitMaxMs:2e4,waitForExitCheckMs:500,appPort:1997},h={maxLines:200,pollIntervalMs:1e3},i={tickIntervalMs:6e4,pingLeadMs:5e3,refreshAheadMs:3e5,failureCooldownMs:9e5,providers:{claude:{settingsKey:"claudeAutoPing",quotaKey:"session (5h)",pingModel:"claude-haiku-4-5-20251001",pingText:"hi",pingMaxTokens:1},codex:{settingsKey:"codexAutoPing",quotaKey:"session",pingWhenResetAtSlides:!0,resetAtDriftMs:3e4,minPingIntervalMs:6e5,skipWhenBlockingQuotaExhausted:!0,pingModel:"gpt-5.5",pingText:"hi",pingInstructions:"Reply with OK.",pingReasoningEffort:"none"}}},j={openrouter:"https://openrouter.ai/api/v1/chat/completions",glm:"https://api.z.ai/api/anthropic/v1/messages","glm-cn":"https://open.bigmodel.cn/api/coding/paas/v4/chat/completions",kimi:"https://api.kimi.com/coding/v1/messages",minimax:"https://api.minimax.io/anthropic/v1/messages","minimax-cn":"https://api.minimaxi.com/anthropic/v1/messages",alicode:"https://coding.dashscope.aliyuncs.com/v1/chat/completions","alicode-intl":"https://coding-intl.dashscope.aliyuncs.com/v1/chat/completions","volcengine-ark":"https://ark.cn-beijing.volces.com/api/coding/v3/chat/completions",byteplus:"https://ark.ap-southeast.bytepluses.com/api/coding/v3/chat/completions",openai:"https://api.openai.com/v1/chat/completions","vercel-ai-gateway":"https://ai-gateway.vercel.sh/v1/chat/completions",anthropic:"https://api.anthropic.com/v1/messages",gemini:"https://generativelanguage.googleapis.com/v1beta/models",ollama:"https://ollama.com/api/chat","ollama-local":"http://localhost:11434/api/chat","notion-ai":"https://app.notion.com/api/v3/runInferenceTranscript"}},39006:a=>{"use strict";a.exports=JSON.parse('{"name":"zevairouter","version":"1.0.212","description":"Self-hosted AI router: many providers, one OpenAI-compatible /v1 endpoint and dashboard","bin":{"zevai":"cli/cli.js"},"files":["cli/cli.js","cli/app/","cli/hooks/","cli/src/","cli/package.json","cli/README.md","cli/LICENSE","scripts/start-standalone.mjs","README.md","README.zh-CN.md","DOCKER.md","LICENSE","CHANGELOG.md"],"scripts":{"dev":"next dev --webpack --port 1997","build":"node scripts/build-app.mjs","start":"node ./scripts/start-standalone.mjs","dev:bun":"bun --bun next dev --webpack --port 1997","build:bun":"bun --bun next build --webpack","start:bun":"bun ./.next/standalone/server.js","lint":"eslint .","test":"vitest run --config tests/vitest.config.js","build:cli":"node cli/scripts/build-cli.js","audit:package":"node cli/scripts/audit-package.mjs","smoke:package":"node cli/scripts/smoke-package.mjs","release":"node cli/scripts/release.js","prepack":"npm run build:cli && npm run audit:package","postinstall":"node cli/hooks/postinstall.js"},"dependencies":{"next":"16.2.12","node-machine-id":"1.1.12","react":"19.2.4","react-dom":"19.2.4","sql.js":"1.14.1","yaml":"2.9.0"},"comment_optional_runtime":"Optional packages are installed into ~/.zevai/runtime instead of the published tarball. Automation uses CloakBrowser with playwright-core; ZEVAI_MINIMAL_POSTINSTALL=1 skips its browser download. Other lazy runtimes are better-sqlite3, node-pty, and systray2.","overrides":{"body-parser":"^2.3.0","brace-expansion":"5.0.9","dompurify":"^3.4.12","ip-address":"^10.4.0","postcss":"^8.5.10","sharp":"^0.35.0"},"comment_overrides":"Security floors for transitive dependencies. ESLint\'s legacy minimatch is a private, source-pinned 3.1.5 compatibility package backed by brace-expansion 5.0.9; modern minimatch uses 5.0.9 directly. Monaco still pins an old DOMPurify; Express and Next may resolve vulnerable body-parser/sharp releases. Recheck and remove overrides once parent packages require fixed versions.","devDependencies":{"@dnd-kit/core":"^6.3.1","@dnd-kit/modifiers":"^9.0.0","@dnd-kit/sortable":"^10.0.0","@dnd-kit/utilities":"^3.2.2","@monaco-editor/react":"^4.7.0","@tailwindcss/postcss":"^4.1.18","@xterm/addon-fit":"^0.11.0","@xterm/addon-web-links":"^0.12.0","@xterm/xterm":"^6.0.0","@xyflow/react":"^12.10.1","bcryptjs":"^3.0.3","better-sqlite3":"^12.6.2","chalk":"^4.1.2","minimatch":"file:vendor/minimatch3-secure","confbox":"^0.2.4","dompurify":"^3.4.12","esbuild":"^0.28.1","eslint":"^9","eslint-config-next":"16.2.9","express":"^5.2.1","http-proxy-middleware":"^3.0.7","jose":"^6.1.3","marked":"^18.0.1","material-symbols":"^0.45.1","monaco-editor":"^0.55.1","node-forge":"^1.3.3","open":"^11.0.0","ora":"^9.1.0","postcss":"^8.5.10","prop-types":"^15.8.1","react-is":"^19.2.7","recharts":"^3.7.0","selfsigned":"^5.5.0","socks":"^2.8.9","socks-proxy-agent":"^10.1.0","tailwindcss":"^4","undici":"^8.10.0","uuid":"^14.0.1","vitest":"^4.1.10","zustand":"^5.0.10"},"engines":{"node":">=22.5.0"},"keywords":["zevairouter","zevai","ai","router","proxy","kiro","codebuddy","claude","openai","api","quota","automation"],"license":"MIT","repository":{"type":"git","url":"git+https://github.com/Verifiedlabs/zevairouter.git"},"bugs":{"url":"https://github.com/Verifiedlabs/zevairouter/issues"},"homepage":"https://github.com/Verifiedlabs/zevairouter"}')},78335:()=>{},81329:(a,b,c)=>{"use strict";c.d(b,{Xg:()=>d.Xg,eh:()=>e,vq:()=>d.vq});var d=c(44404);Object.entries(c(75681).AI_PROVIDERS).filter(([,a])=>a.passthroughModels).map(([a])=>a);let e=Object.entries(d.vq).flatMap(([a,b])=>b.map(b=>({provider:a,model:b.id,name:b.name})))},96487:()=>{}};
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
"use strict";exports.id=3999,exports.ids=[3999],exports.modules={644:(a,b,c)=>{function d(a,b=null){if(null==a)return b;if("string"!=typeof a)return a;try{return JSON.parse(a)}catch{return b}}function e(a){return JSON.stringify(a??null)}c.d(b,{q:()=>d,s:()=>e})},1129:(a,b,c)=>{c.r(b),c.d(b,{createProviderNode:()=>l,deleteProviderNode:()=>n,getProviderNodeById:()=>k,getProviderNodes:()=>j,updateProviderNode:()=>m});var d=c(47293),e=c(36366),f=c(644),g=c(9460);function h(a){return a?{...(0,f.q)(a.data,{}),id:a.id,type:a.type,name:a.name,createdAt:a.createdAt,updatedAt:a.updatedAt}:null}function i(a,b){let c=function(a){let{id:b,type:c,name:d,createdAt:e,updatedAt:g,...h}=a;return{id:b,type:c??null,name:d??null,data:(0,f.s)(h),createdAt:e,updatedAt:g}}(b);a.run(`INSERT INTO providerNodes(id, type, name, data, createdAt, updatedAt)
|
|
2
2
|
VALUES(?, ?, ?, ?, ?, ?)
|
|
3
3
|
ON CONFLICT(id) DO UPDATE SET
|
|
4
|
-
type=excluded.type, name=excluded.name, data=excluded.data, updatedAt=excluded.updatedAt`,[c.id,c.type,c.name,c.data,c.createdAt,c.updatedAt])}async function j(a={}){let b=await (0,e.
|
|
4
|
+
type=excluded.type, name=excluded.name, data=excluded.data, updatedAt=excluded.updatedAt`,[c.id,c.type,c.name,c.data,c.createdAt,c.updatedAt])}async function j(a={}){let b=await (0,e.getAdapter)(),c=[],d=[];a.type&&(c.push("type = ?"),d.push(a.type));let f=`SELECT * FROM providerNodes${c.length?` WHERE ${c.join(" AND ")}`:""}`;return b.all(f,d).map(h)}async function k(a){return h((await (0,e.getAdapter)()).get("SELECT * FROM providerNodes WHERE id = ?",[a]))}async function l(a){let b=await (0,e.getAdapter)(),c=new Date().toISOString(),f={id:a.id||(0,d.A)(),type:a.type,name:a.name,prefix:a.prefix,apiType:a.apiType,baseUrl:a.baseUrl,createdAt:c,updatedAt:c};return i(b,f),f}async function m(a,b){let c=await (0,e.getAdapter)(),d=null;return c.transaction(()=>{let e=c.get("SELECT * FROM providerNodes WHERE id = ?",[a]);if(!e)return;let f={...h(e),...b,updatedAt:new Date().toISOString()};i(c,f),d=f}),d}async function n(a){let b=await (0,e.getAdapter)(),c=null;return b.transaction(()=>{let d=b.get("SELECT * FROM providerNodes WHERE id = ?",[a]);d&&(c=h(d),(0,g.sI)(b,c),b.run("DELETE FROM providerNodes WHERE id = ?",[a]))}),c}},5781:(a,b,c)=>{c.r(b),c.d(b,{cleanupProviderConnections:()=>s,createProviderConnection:()=>m,deleteProviderConnection:()=>p,deleteProviderConnectionsByProvider:()=>q,getProviderConnectionById:()=>k,getProviderConnections:()=>j,mutateProviderConnection:()=>o,reorderProviderConnections:()=>r,updateProviderConnection:()=>n});var d=c(47293),e=c(36366),f=c(644);let g=["displayName","email","globalPriority","defaultModel","accessToken","refreshToken","expiresAt","tokenType","scope","projectId","apiKey","testStatus","lastTested","lastError","lastErrorAt","rateLimitedUntil","expiresIn","errorCode","consecutiveUseCount","idToken","lastRefreshAt"];function h(a){return a?{...(0,f.q)(a.data,{}),id:a.id,provider:a.provider,authType:a.authType,name:a.name,email:a.email,priority:a.priority,isActive:1===a.isActive||!0===a.isActive,createdAt:a.createdAt,updatedAt:a.updatedAt}:null}function i(a,b){let c=function(a){let{id:b,provider:c,authType:d,name:e,email:g,priority:h,isActive:i,createdAt:j,updatedAt:k,...l}=a;return{id:b,provider:c,authType:d,name:e??null,email:g??null,priority:h??null,isActive:+(!1!==i),data:(0,f.s)(l),createdAt:j,updatedAt:k}}(b);a.run(`INSERT INTO providerConnections(id, provider, authType, name, email, priority, isActive, data, createdAt, updatedAt)
|
|
5
5
|
VALUES(?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
|
|
6
6
|
ON CONFLICT(id) DO UPDATE SET
|
|
7
7
|
provider=excluded.provider, authType=excluded.authType, name=excluded.name,
|
|
8
8
|
email=excluded.email, priority=excluded.priority, isActive=excluded.isActive,
|
|
9
|
-
data=excluded.data, updatedAt=excluded.updatedAt`,[c.id,c.provider,c.authType,c.name,c.email,c.priority,c.isActive,c.data,c.createdAt,c.updatedAt])}async function j(a={}){let b=await (0,e.
|
|
10
|
-
ON CONFLICT(connectionId) DO UPDATE SET provider = excluded.provider, data = excluded.data, fetchedAt = excluded.fetchedAt`,[a,b||"",(0,e.s)(c||{}),g])}function g(a){return a?{connectionId:a.connectionId,provider:a.provider,fetchedAt:a.fetchedAt,usage:(0,e.q)(a.data,{})}:null}async function h(a){return a?g((await (0,d.
|
|
9
|
+
data=excluded.data, updatedAt=excluded.updatedAt`,[c.id,c.provider,c.authType,c.name,c.email,c.priority,c.isActive,c.data,c.createdAt,c.updatedAt])}async function j(a={}){let b=await (0,e.getAdapter)(),c=[],d=[];a.provider&&(c.push("provider = ?"),d.push(a.provider)),void 0!==a.isActive&&(c.push("isActive = ?"),d.push(+!!a.isActive));let f=`SELECT * FROM providerConnections${c.length?` WHERE ${c.join(" AND ")}`:""}`,g=b.all(f,d).map(h);return g.sort((a,b)=>(a.priority||999)-(b.priority||999)),g}async function k(a){return h((await (0,e.getAdapter)()).get("SELECT * FROM providerConnections WHERE id = ?",[a]))}function l(a,b,c=null){let d=a.all("SELECT * FROM providerConnections WHERE provider = ?",[b]).map(h);if(d.sort((a,b)=>{let c=(a.priority||0)-(b.priority||0);return 0!==c?c:a.id.localeCompare(b.id)}),c){let a=d.findIndex(a=>a.id===c);if(-1!==a){let[b]=d.splice(a,1),c=Number(b.priority),e=Math.max(0,Math.min(Number.isFinite(c)?Math.ceil(c)-1:d.length,d.length));d.splice(e,0,b)}}d.forEach((b,c)=>{a.run("UPDATE providerConnections SET priority = ? WHERE id = ?",[c+1,b.id])})}async function m(a){let b,c=await (0,e.getAdapter)(),f=new Date().toISOString();return c.transaction(()=>{let e=c.all("SELECT * FROM providerConnections WHERE provider = ?",[a.provider]).map(h),j=null;if("oauth"===a.authType&&a.email){let b=a.providerSpecificData?.chatgptAccountId;j=e.find(c=>{if("oauth"!==c.authType||c.email!==a.email)return!1;let d=c.providerSpecificData?.chatgptAccountId;return!b||!d||b===d})}else"apikey"===a.authType&&a.name&&(j=e.find(b=>"apikey"===b.authType&&b.name===a.name));if(j){let d={...j,...a,updatedAt:f};if("codex"===a.provider&&a.refreshToken){let a={...d.providerSpecificData||{}};delete a.codexRefreshBlockedAt,delete a.codexRefreshErrorCode,Object.keys(a).length>0?d.providerSpecificData=a:delete d.providerSpecificData}i(c,d),void 0!==a.priority?(l(c,j.provider,j.id),b=h(c.get("SELECT * FROM providerConnections WHERE id = ?",[j.id]))):b=d;return}let k=a.name||null;k||"oauth"!==a.authType&&"access_token"!==a.authType||(k=a.email||`Account ${e.length+1}`);let m=a.priority;m||(m=e.reduce((a,b)=>Math.max(a,b.priority||0),0)+1);let n={id:(0,d.A)(),provider:a.provider,authType:a.authType||"oauth",name:k,priority:m,isActive:void 0===a.isActive||a.isActive,createdAt:f,updatedAt:f};for(let b of g)void 0!==a[b]&&null!==a[b]&&(n[b]=a[b]);a.providerSpecificData&&Object.keys(a.providerSpecificData).length>0&&(n.providerSpecificData=a.providerSpecificData),void 0!==a.email&&(n.email=a.email),i(c,n),l(c,a.provider,n.id),b=h(c.get("SELECT * FROM providerConnections WHERE id = ?",[n.id]))}),b}async function n(a,b){let c,d=await (0,e.getAdapter)();return d.transaction(()=>{let e=d.get("SELECT * FROM providerConnections WHERE id = ?",[a]);if(!e){c=null;return}let f=h(e),g={...f,...b,updatedAt:new Date().toISOString()};i(d,g),void 0!==b.priority?(l(d,f.provider,a),c=h(d.get("SELECT * FROM providerConnections WHERE id = ?",[a]))):c=g}),c}async function o(a,b){if("function"!=typeof b)throw TypeError("mutator must be a function");let c=await (0,e.getAdapter)(),d=null;return c.transaction(()=>{let e=c.get("SELECT * FROM providerConnections WHERE id = ?",[a]);if(!e)return;let f=h(e),g=b(f);if(g&&"function"==typeof g.then)throw TypeError("connection mutator must be synchronous");if(!g||"object"!=typeof g||Array.isArray(g))return;let j={...f,...g,updatedAt:new Date().toISOString()};i(c,j),void 0!==g.priority&&l(c,f.provider,a),d=void 0!==g.priority?h(c.get("SELECT * FROM providerConnections WHERE id = ?",[a])):j}),d}async function p(a){let b=await (0,e.getAdapter)(),c=!1;return b.transaction(()=>{let d=b.get("SELECT provider FROM providerConnections WHERE id = ?",[a]);d&&(b.run("DELETE FROM providerConnections WHERE id = ?",[a]),l(b,d.provider),c=!0)}),c}async function q(a){let b=await (0,e.getAdapter)(),c=b.get("SELECT COUNT(*) AS n FROM providerConnections WHERE provider = ?",[a]);return b.run("DELETE FROM providerConnections WHERE provider = ?",[a]),c?.n||0}async function r(a){let b=await (0,e.getAdapter)();b.transaction(()=>l(b,a))}async function s(){let a=await (0,e.getAdapter)(),b=["displayName","email","globalPriority","defaultModel","accessToken","refreshToken","expiresAt","tokenType","scope","projectId","apiKey","testStatus","lastTested","lastError","lastErrorAt","rateLimitedUntil","expiresIn","consecutiveUseCount","idToken","lastRefreshAt"],c=0;return a.transaction(()=>{for(let d of a.all("SELECT * FROM providerConnections")){let e=h(d),f=!1;for(let a of b)(null===e[a]||void 0===e[a])&&a in e&&(delete e[a],c++,f=!0);e.providerSpecificData&&0===Object.keys(e.providerSpecificData).length&&(delete e.providerSpecificData,c++,f=!0),f&&i(a,e)}}),c}},9460:(a,b,c)=>{c.d(b,{Kg:()=>p,L9:()=>w,OM:()=>n,S8:()=>t,fv:()=>q,getMitmAlias:()=>v,jS:()=>m,o5:()=>o,sI:()=>l,uL:()=>u,uv:()=>s});var d=c(36366),e=c(644),f=c(22846);let g=(0,f.U)("modelAliases"),h=(0,f.U)("customModels"),i=(0,f.U)("mitmAlias"),j=["openai-compatible-","anthropic-compatible-","custom-embedding-"];function k(a){if("string"==typeof a){let b=a.indexOf("/");return b>0?a.slice(0,b):null}return a&&"object"==typeof a&&"string"==typeof a.provider?a.provider:null}function l(a,b){let c=new Set([b?.id,b?.prefix].filter(Boolean)),d=0,f=0;for(let b of a.all("SELECT key, value FROM kv WHERE scope = 'modelAliases'"))c.has(k((0,e.q)(b.value)))&&(a.run("DELETE FROM kv WHERE scope = 'modelAliases' AND key = ?",[b.key]),d+=1);for(let b of a.all("SELECT key, value FROM kv WHERE scope = 'customModels'")){let d=(0,e.q)(b.value,{});c.has(d?.providerAlias)&&(a.run("DELETE FROM kv WHERE scope = 'customModels' AND key = ?",[b.key]),f+=1)}return{aliases:d,customModels:f}}function m(a){let b=new Set;for(let c of a.all("SELECT id, data FROM providerNodes")){b.add(c.id);let a=(0,e.q)(c.data,{})?.prefix;a&&b.add(a)}let c=0;for(let d of a.all("SELECT key, value FROM kv WHERE scope = 'modelAliases'")){let f=k((0,e.q)(d.value));!function(a){return j.some(b=>a?.startsWith(b))}(f)||b.has(f)||(a.run("DELETE FROM kv WHERE scope = 'modelAliases' AND key = ?",[d.key]),c+=1)}return c}async function n(){return await g.getAll()}async function o(a,b){await g.set(a,b)}async function p(a){await g.setMany(a)}async function q(a){await g.remove(a)}function r(a,b,c){return`${a}|${b}|${c}`}async function s(){return Object.values(await h.getAll())}async function t({providerAlias:a,id:b,type:c="llm",name:f}){let g=r(a,b,c),h=await (0,d.getAdapter)(),i=!1;return h.transaction(()=>{if(h.get("SELECT 1 FROM kv WHERE scope = 'customModels' AND key = ?",[g]))return;let d=(0,e.s)({providerAlias:a,id:b,type:c,name:f||b});h.run("INSERT INTO kv(scope, key, value) VALUES('customModels', ?, ?)",[g,d]),i=!0}),i}async function u({providerAlias:a,id:b,type:c="llm"}){await h.remove(r(a,b,c))}async function v(a){return a?await i.get(a)||{}:await i.getAll()}async function w(a,b){await i.set(a,b||{})}},22846:(a,b,c)=>{c.d(b,{U:()=>f});var d=c(36366),e=c(644);function f(a){return{async get(b,c=null){let f=(await (0,d.getAdapter)()).get("SELECT value FROM kv WHERE scope = ? AND key = ?",[a,b]);return f?(0,e.q)(f.value,c):c},async getAll(){let b=(await (0,d.getAdapter)()).all("SELECT key, value FROM kv WHERE scope = ?",[a]),c={};for(let a of b)c[a.key]=(0,e.q)(a.value);return c},async set(b,c){(await (0,d.getAdapter)()).run("INSERT INTO kv(scope, key, value) VALUES(?, ?, ?) ON CONFLICT(scope, key) DO UPDATE SET value = excluded.value",[a,b,(0,e.s)(c)])},async setMany(b){let c=await (0,d.getAdapter)();c.transaction(()=>{for(let[d,f]of Object.entries(b))c.run("INSERT INTO kv(scope, key, value) VALUES(?, ?, ?) ON CONFLICT(scope, key) DO UPDATE SET value = excluded.value",[a,d,(0,e.s)(f)])})},async remove(b){(await (0,d.getAdapter)()).run("DELETE FROM kv WHERE scope = ? AND key = ?",[a,b])},async clear(){(await (0,d.getAdapter)()).run("DELETE FROM kv WHERE scope = ?",[a])}}}},26556:(a,b,c)=>{c.d(b,{KK:()=>f,LF:()=>h,tV:()=>i});var d=c(36366),e=c(644);async function f(a,b,c){if(!a)return;let f=await (0,d.getAdapter)(),g=new Date().toISOString();f.run(`INSERT INTO quotaCache(connectionId, provider, data, fetchedAt) VALUES(?, ?, ?, ?)
|
|
10
|
+
ON CONFLICT(connectionId) DO UPDATE SET provider = excluded.provider, data = excluded.data, fetchedAt = excluded.fetchedAt`,[a,b||"",(0,e.s)(c||{}),g])}function g(a){return a?{connectionId:a.connectionId,provider:a.provider,fetchedAt:a.fetchedAt,usage:(0,e.q)(a.data,{})}:null}async function h(a){return a?g((await (0,d.getAdapter)()).get("SELECT connectionId, provider, data, fetchedAt FROM quotaCache WHERE connectionId = ?",[a])):null}async function i(a=null){let b=await (0,d.getAdapter)();return(a?b.all("SELECT connectionId, provider, data, fetchedAt FROM quotaCache WHERE provider = ?",[a]):b.all("SELECT connectionId, provider, data, fetchedAt FROM quotaCache")).map(g)}},31763:(a,b,c)=>{c.d(b,{KQ:()=>o,AL:()=>n,HG:()=>m,Or:()=>p,Jh:()=>q});var d=c(76760),e=c.n(d),f=c(73024),g=c.n(f),h=c(49120),i=c(48161),j=c.n(i);let k=String.fromCharCode(57,114,111,117,116,101,114),l=".migrated-from-legacy",m=e().join(h.DATA_DIR,"db"),n=e().join(m,"data.sqlite"),o=e().join(m,"backups"),p={main:e().join(h.DATA_DIR,"db.json"),usage:e().join(h.DATA_DIR,"usage.json"),disabled:e().join(h.DATA_DIR,"disabledModels.json"),details:e().join(h.DATA_DIR,"request-details.json")};function q(){for(let a of(!function(a){if(!a||process.env.DATA_DIR)return;let b=e().join(a,l);if(g().existsSync(b))return;let c="win32"===process.platform?e().join(process.env.APPDATA||e().join(j().homedir(),"AppData","Roaming"),k):e().join(j().homedir(),`.${k}`);if(g().existsSync(c))try{if(g().existsSync(a)){if(g().readdirSync(a).filter(a=>a!==l).length>0)return void g().writeFileSync(b,new Date().toISOString())}else g().mkdirSync(a,{recursive:!0});g().cpSync(c,a,{recursive:!0,force:!1,errorOnExist:!1}),g().writeFileSync(b,new Date().toISOString()),console.log(`[dataDir] Migrated legacy data from ${c} → ${a}`)}catch(a){console.warn(`[dataDir] Legacy migration skipped: ${a?.message||a}`)}}(h.DATA_DIR),[h.DATA_DIR,m,o]))g().existsSync(a)||g().mkdirSync(a,{recursive:!0})}},36366:(a,b,c)=>{c.d(b,{getAdapter:()=>k});var d=c(31763);global._dbAdapter||(global._dbAdapter={instance:null,initPromise:null,closePromise:null,logged:!1});let e=global._dbAdapter;async function f(){if(!process.versions.bun)return null;try{let{createBunSqliteAdapter:a}=await c.e(4739).then(c.bind(c,24739));return await a(d.AL)}catch(a){return console.warn(`[DB] bun:sqlite unavailable: ${a.message}`),null}}async function g(){if(process.versions.bun)return null;try{let{createBetterSqliteAdapter:a}=await c.e(5258).then(c.bind(c,25258));return a(d.AL)}catch(a){return console.warn(`[DB] better-sqlite3 unavailable: ${a.message}`),null}}async function h(){if(process.versions.bun)return null;let[a,b]=process.versions.node.split(".").map(Number);if(a<22||22===a&&b<5)return null;try{let{createNodeSqliteAdapter:a}=await c.e(8520).then(c.bind(c,88520));return await a(d.AL)}catch(a){return console.warn(`[DB] node:sqlite unavailable: ${a.message}`),null}}async function i(){try{let{createSqlJsAdapter:a}=await c.e(3593).then(c.bind(c,53593));return await a(d.AL)}catch(a){return console.warn(`[DB] sql.js unavailable: ${a.message}`),null}}async function j(){(0,d.Jh)();let a=await f();if(a||(a=await h()),a||(a=await g()),a||(a=await i()),!a)throw Error("[DB] No SQLite driver available (bun/node/better/sql.js all failed)");e.logged||(console.log(`[DB] Driver: ${a.driver} | file: ${d.AL}`),e.logged=!0);try{let{runMigrationOnce:b}=await c.e(5217).then(c.bind(c,45217));await b(a);let{runStartupMaintenanceOnce:d}=await c.e(4229).then(c.bind(c,14229));return d(a),a}catch(b){try{await a.close?.()}catch(a){console.warn(`[DB] failed to close partially initialized adapter: ${a.message}`)}throw b}}async function k(){if(e.instance)return e.instance;if(!e.initPromise){let a=j().then(a=>(e.instance=a,a)).catch(b=>{throw e.initPromise===a&&(e.initPromise=null),b});e.initPromise=a}return e.initPromise}"closePromise"in e||(e.closePromise=null)},42655:(a,b,c)=>{c.d(b,{Xx:()=>j,exportSettings:()=>k,getSettings:()=>i});var d=c(36366),e=c(644);let f={cloudEnabled:!1,tunnelEnabled:!1,tunnelUrl:"",tunnelProvider:"cloudflare",tailscaleEnabled:!1,tailscaleUrl:"",stickyRoundRobinLimit:3,providerStrategies:{},comboStrategy:"fallback",comboStickyRoundRobinLimit:1,comboStrategies:{},responseCacheEnabled:!1,requireLogin:!0,tunnelDashboardAccess:!0,authMode:"password",oidcIssuerUrl:"",oidcClientId:"",oidcClientSecret:"",oidcScopes:"openid profile email",oidcLoginLabel:"Sign in with OIDC",enableObservability:!0,observabilityMaxRecords:1e3,observabilityBatchSize:20,observabilityFlushIntervalMs:5e3,observabilityMaxJsonSize:5,outboundProxyEnabled:!1,outboundProxyUrl:"",outboundNoProxy:"",mitmRouterBaseUrl:"http://localhost:1997",dnsToolEnabled:{},rtkEnabled:!0,headroomEnabled:!1,headroomUrl:"http://localhost:8787",headroomCompressUserMessages:!1,headroomCodeAware:!1,headroomKompress:!0,cavemanEnabled:!1,cavemanLevel:"full",ponytailEnabled:!1,ponytailLevel:"full",pxpipeEnabled:!1,pxpipeAutoInstall:!0,pxpipeMinChars:25e3,pxpipeTimeoutMs:15e3,contextInjectionEnabled:!1,fiveSimApiKey:""};async function g(){let a=(await (0,d.getAdapter)()).get("SELECT data FROM settings WHERE id = 1");return a?(0,e.q)(a.data,{}):{}}function h(a){let b={...f,...a||{}};for(let[a,c]of Object.entries(f))void 0===b[a]&&("outboundProxyEnabled"===a&&"string"==typeof b.outboundProxyUrl&&b.outboundProxyUrl.trim()?b[a]=!0:b[a]=c);return b}async function i(){return h(await g())}async function j(a){let b,c=await (0,d.getAdapter)();return c.transaction(()=>{let d=c.get("SELECT data FROM settings WHERE id = 1");b={...d?(0,e.q)(d.data,{}):{},...a},c.run("INSERT INTO settings(id, data) VALUES(1, ?) ON CONFLICT(id) DO UPDATE SET data = excluded.data",[(0,e.s)(b)])}),h(b)}async function k(){return await g()}},49120:(a,b,c)=>{c.r(b),c.d(b,{DATA_DIR:()=>m,getDataDir:()=>l});var d=c(73024),e=c.n(d),f=c(33873),g=c.n(f),h=c(21820),i=c.n(h);let j="zevai";function k(){return"win32"===process.platform?g().join(process.env.APPDATA||g().join(i().homedir(),"AppData","Roaming"),j):g().join(i().homedir(),`.${j}`)}function l(){let a=process.env.DATA_DIR;if(!a)return k();try{return e().mkdirSync(a,{recursive:!0}),a}catch(b){if(b?.code==="EACCES"||b?.code==="EPERM")return console.warn(`[DATA_DIR] '${a}' not writable → fallback ~/.${j}`),k();throw b}}let m=l()},62674:(a,b,c)=>{function d(a,b,c=null){let e=a.get("SELECT value FROM _meta WHERE key = ?",[b]);return e?e.value:c}function e(a,b,c){a.run("INSERT INTO _meta(key, value) VALUES(?, ?) ON CONFLICT(key) DO UPDATE SET value = excluded.value",[b,String(c)])}c.d(b,{dy:()=>d,np:()=>e}),c(36366)},63775:(a,b,c)=>{c.d(b,{CG:()=>e,oG:()=>d,zE:()=>f});let d=`
|
|
11
11
|
PRAGMA journal_mode = WAL;
|
|
12
12
|
PRAGMA synchronous = NORMAL;
|
|
13
13
|
PRAGMA temp_store = MEMORY;
|
|
@@ -15,10 +15,10 @@ PRAGMA mmap_size = 30000000;
|
|
|
15
15
|
PRAGMA cache_size = -64000;
|
|
16
16
|
PRAGMA foreign_keys = ON;
|
|
17
17
|
PRAGMA busy_timeout = 5000;
|
|
18
|
-
`,e={_meta:{columns:{key:"TEXT PRIMARY KEY",value:"TEXT NOT NULL"}},settings:{columns:{id:"INTEGER PRIMARY KEY CHECK (id = 1)",data:"TEXT NOT NULL"}},providerConnections:{columns:{id:"TEXT PRIMARY KEY",provider:"TEXT NOT NULL",authType:"TEXT NOT NULL",name:"TEXT",email:"TEXT",priority:"INTEGER",isActive:"INTEGER DEFAULT 1",data:"TEXT NOT NULL",createdAt:"TEXT NOT NULL",updatedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_pc_provider ON providerConnections(provider)","CREATE INDEX IF NOT EXISTS idx_pc_provider_active ON providerConnections(provider, isActive)","CREATE INDEX IF NOT EXISTS idx_pc_priority ON providerConnections(provider, priority)"]},providerNodes:{columns:{id:"TEXT PRIMARY KEY",type:"TEXT",name:"TEXT",data:"TEXT NOT NULL",createdAt:"TEXT NOT NULL",updatedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_pn_type ON providerNodes(type)"]},proxyPools:{columns:{id:"TEXT PRIMARY KEY",isActive:"INTEGER DEFAULT 1",testStatus:"TEXT",data:"TEXT NOT NULL",createdAt:"TEXT NOT NULL",updatedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_pp_active ON proxyPools(isActive)","CREATE INDEX IF NOT EXISTS idx_pp_status ON proxyPools(testStatus)"]},apiKeys:{columns:{id:"TEXT PRIMARY KEY",key:"TEXT UNIQUE NOT NULL",name:"TEXT",machineId:"TEXT",isActive:"INTEGER DEFAULT 1",createdAt:"TEXT NOT NULL",budgetDaily:"REAL DEFAULT 0",budgetMonthly:"REAL DEFAULT 0",requestsPerMinute:"INTEGER DEFAULT 0",allowedModels:"TEXT",allowedConnectionIds:"TEXT"},indexes:["CREATE INDEX IF NOT EXISTS idx_ak_key ON apiKeys(key)"]},combos:{columns:{id:"TEXT PRIMARY KEY",name:"TEXT UNIQUE NOT NULL",kind:"TEXT",models:"TEXT NOT NULL",createdAt:"TEXT NOT NULL",updatedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_combo_name ON combos(name)"]},kv:{columns:{scope:"TEXT NOT NULL",key:"TEXT NOT NULL",value:"TEXT NOT NULL"},primaryKey:"PRIMARY KEY (scope, key)",indexes:["CREATE INDEX IF NOT EXISTS idx_kv_scope ON kv(scope)"]},usageHistory:{columns:{id:"INTEGER PRIMARY KEY AUTOINCREMENT",timestamp:"TEXT NOT NULL",provider:"TEXT",model:"TEXT",connectionId:"TEXT",apiKey:"TEXT",endpoint:"TEXT",promptTokens:"INTEGER DEFAULT 0",completionTokens:"INTEGER DEFAULT 0",cost:"REAL DEFAULT 0",status:"TEXT",tokens:"TEXT",meta:"TEXT"},indexes:["CREATE INDEX IF NOT EXISTS idx_uh_ts ON usageHistory(timestamp DESC)","CREATE INDEX IF NOT EXISTS idx_uh_provider ON usageHistory(provider)","CREATE INDEX IF NOT EXISTS idx_uh_model ON usageHistory(model)","CREATE INDEX IF NOT EXISTS idx_uh_conn ON usageHistory(connectionId)"]},usageDaily:{columns:{dateKey:"TEXT PRIMARY KEY",data:"TEXT NOT NULL"}},requestDetails:{columns:{id:"TEXT PRIMARY KEY",timestamp:"TEXT NOT NULL",provider:"TEXT",model:"TEXT",connectionId:"TEXT",status:"TEXT",data:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_rd_ts ON requestDetails(timestamp DESC)","CREATE INDEX IF NOT EXISTS idx_rd_provider ON requestDetails(provider)","CREATE INDEX IF NOT EXISTS idx_rd_model ON requestDetails(model)","CREATE INDEX IF NOT EXISTS idx_rd_conn ON requestDetails(connectionId)"]},quotaCache:{columns:{connectionId:"TEXT PRIMARY KEY",provider:"TEXT",data:"TEXT NOT NULL",fetchedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_qc_provider ON quotaCache(provider)"]},contextFiles:{columns:{id:"TEXT PRIMARY KEY",name:"TEXT NOT NULL",content:"TEXT NOT NULL",enabled:"INTEGER DEFAULT 1",priority:"INTEGER DEFAULT 0",createdAt:"TEXT NOT NULL",updatedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_cf_enabled ON contextFiles(enabled, priority)"]}};function f(a,b){let c=Object.entries(b.columns).map(([a,b])=>`${a} ${b}`);return b.primaryKey&&c.push(b.primaryKey),`CREATE TABLE IF NOT EXISTS ${a} (${c.join(", ")})`}},74452:(a,b,c)=>{c.r(b),c.d(b,{admitApiKeyRequest:()=>q,checkApiKeyBudget:()=>u,createApiKey:()=>n,deleteApiKey:()=>r,getApiKeyById:()=>m,getApiKeyConnectionPolicy:()=>t,getApiKeys:()=>l,maskApiKey:()=>j,rotateApiKey:()=>p,updateApiKey:()=>o,validateApiKey:()=>s});var d=c(47293),e=c(36366);let f=new Map,g=new Map;function h(a){if(Array.isArray(a))return a;if(!a)return[];try{return JSON.parse(a)}catch{return[]}}function i(a){let b=a;if(!Array.isArray(b)){if(!b)return[];try{b=JSON.parse(b)}catch{return[]}}return Array.isArray(b)?[...new Set(b.filter(a=>"string"==typeof a).map(a=>a.trim()).filter(Boolean))]:[]}function j(a){return a?a.length<=12?`${a.slice(0,4)}…`:`${a.slice(0,8)}…${a.slice(-4)}`:null}function k(a,b=!1){return a?{id:a.id,key:b?a.key:void 0,maskedKey:j(a.key),name:a.name,machineId:a.machineId,isActive:1===a.isActive||!0===a.isActive,createdAt:a.createdAt,budgetDaily:a.budgetDaily||0,budgetMonthly:a.budgetMonthly||0,requestsPerMinute:a.requestsPerMinute||0,allowedModels:h(a.allowedModels),allowedConnectionIds:i(a.allowedConnectionIds)}:null}async function l(a=!1){return(await (0,e.cK)()).all("SELECT * FROM apiKeys ORDER BY createdAt ASC").map(b=>k(b,a))}async function m(a,b=!1){return k((await (0,e.cK)()).get("SELECT * FROM apiKeys WHERE id = ?",[a]),b)}async function n(a,b){if(!b)throw Error("machineId is required");let f=await (0,e.cK)(),{generateApiKeyWithMachine:g}=await c.e(6844).then(c.bind(c,86844)),h=g(b),i={id:(0,d.A)(),name:a,key:h.key,machineId:b,isActive:!0,createdAt:new Date().toISOString()};return f.run("INSERT INTO apiKeys(id, key, name, machineId, isActive, createdAt) VALUES(?, ?, ?, ?, ?, ?)",[i.id,i.key,i.name,i.machineId,1,i.createdAt]),i}async function o(a,b){let c=await (0,e.cK)(),d=null;return c.transaction(()=>{let e=c.get("SELECT * FROM apiKeys WHERE id = ?",[a]);if(!e)return;let f={...k(e,!0),...b};c.run("UPDATE apiKeys SET key = ?, name = ?, machineId = ?, isActive = ?, budgetDaily = ?, budgetMonthly = ?, requestsPerMinute = ?, allowedModels = ?, allowedConnectionIds = ? WHERE id = ?",[f.key,f.name,f.machineId,+!!f.isActive,Number(f.budgetDaily)||0,Number(f.budgetMonthly)||0,Number(f.requestsPerMinute)||0,JSON.stringify(f.allowedModels||[]),JSON.stringify(i(f.allowedConnectionIds)),a]),d=f}),d}async function p(a){let b=await (0,e.cK)(),d=b.get("SELECT * FROM apiKeys WHERE id = ?",[a]);if(!d)return null;let{generateApiKeyWithMachine:f}=await c.e(6844).then(c.bind(c,86844)),g=f(d.machineId).key;return b.run("UPDATE apiKeys SET key = ? WHERE id = ?",[g,a]),{...k({...d,key:g}),key:g}}async function q(a,b){let c=(await (0,e.cK)()).get("SELECT budgetDaily, budgetMonthly, requestsPerMinute, allowedModels FROM apiKeys WHERE key = ?",[a]);if(!c)return{allowed:!0,touch(){},release(){}};let d=h(c.allowedModels);if(d.length>0&&!d.includes(b))return{allowed:!1,status:403,reason:`Model ${b} is not allowed for this API key`};let i=Number(c.requestsPerMinute)||0;if(i>0){let b=Date.now(),c=(g.get(a)||[]).filter(a=>b-a<6e4);if(c.length>=i){let d=Math.max(1,Math.ceil((6e4-(b-c[0]))/1e3));return g.set(a,c),{allowed:!1,status:429,retryAfter:d,reason:"API key rate limit exceeded"}}c.push(b),!g.has(a)&&g.size>=1e4&&function(a){for(let[b,c]of g)(0===c.length||a-c[c.length-1]>=6e4)&&g.delete(b)}(b),g.set(a,c)}if(!(Number(c.budgetDaily)>0||Number(c.budgetMonthly)>0))return{allowed:!0,touch(){},release(){}};let j=Date.now(),k=f.get(a);if(k&&j-k.activeAt<6e4)return{allowed:!1,status:429,retryAfter:1,reason:"A budgeted request is already in progress"};let l={token:Symbol("budget-slot"),activeAt:j};return f.set(a,l),{allowed:!0,touch:()=>{let b=f.get(a);b?.token===l.token&&(b.activeAt=Date.now())},release:()=>{f.get(a)?.token===l.token&&f.delete(a)}}}async function r(a){let b=(await (0,e.cK)()).run("DELETE FROM apiKeys WHERE id = ?",[a]);return(b?.changes??0)>0}async function s(a){let b=(await (0,e.cK)()).get("SELECT isActive FROM apiKeys WHERE key = ?",[a]);return!!b&&(1===b.isActive||!0===b.isActive)}async function t(a){if(!a)return null;let b=(await (0,e.cK)()).get("SELECT allowedConnectionIds FROM apiKeys WHERE key = ?",[a]);return b?i(b.allowedConnectionIds):null}async function u(a){let b=await (0,e.cK)(),c=b.get("SELECT budgetDaily, budgetMonthly FROM apiKeys WHERE key = ?",[a]);if(!c)return{allowed:!0};let d=c.budgetDaily||0,f=c.budgetMonthly||0;if(d<=0&&f<=0)return{allowed:!0,budgetDaily:d,budgetMonthly:f};let g=0,h=0;try{if(d>0){let c=new Date;c.setHours(0,0,0,0);let d=b.get("SELECT COALESCE(SUM(cost), 0) AS total FROM usageHistory WHERE apiKey = ? AND timestamp >= ?",[a,c.toISOString()]);g=d?.total||0}if(f>0){let c=new Date;c.setDate(1),c.setHours(0,0,0,0);let d=b.get("SELECT COALESCE(SUM(cost), 0) AS total FROM usageHistory WHERE apiKey = ? AND timestamp >= ?",[a,c.toISOString()]);h=d?.total||0}}catch(a){return{allowed:!1,error:!0,reason:"Budget accounting unavailable"}}return d>0&&g>=d?{allowed:!1,reason:`Daily budget exceeded ($${g.toFixed(4)} / $${d})`,spentDaily:g,spentMonthly:h,budgetDaily:d,budgetMonthly:f}:f>0&&h>=f?{allowed:!1,reason:`Monthly budget exceeded ($${h.toFixed(4)} / $${f})`,spentDaily:g,spentMonthly:h,budgetDaily:d,budgetMonthly:f}:{allowed:!0,spentDaily:g,spentMonthly:h,budgetDaily:d,budgetMonthly:f}}},93999:(a,b,c)=>{c.d(b,{S8:()=>L.S8,admitApiKeyRequest:()=>D.admitApiKeyRequest,E5:()=>as,checkApiKeyBudget:()=>D.checkApiKeyBudget,Iq:()=>D.createApiKey,jd:()=>I,QI:()=>z,p3:()=>C,iE:()=>h.createProviderConnection,i0:()=>i.createProviderNode,ZO:()=>o,Lh:()=>D.deleteApiKey,CG:()=>K,NR:()=>B,uL:()=>L.uL,fv:()=>L.fv,fK:()=>h.deleteProviderConnection,op:()=>h.deleteProviderConnectionsByProvider,Pc:()=>i.deleteProviderNode,Yd:()=>q,tm:()=>P,oF:()=>Q,zP:()=>aI,rg:()=>al,tV:()=>r.tV,yg:()=>D.getApiKeyById,ME:()=>D.getApiKeyConnectionPolicy,PX:()=>D.getApiKeys,j$:()=>aq,L:()=>G,Dj:()=>H,Uv:()=>F,yW:()=>y,uv:()=>L.uv,vF:()=>O,qd:()=>x,getLatencyStats:()=>ar,c:()=>L.getMitmAlias,OM:()=>L.OM,r4:()=>M.r4,Mc:()=>h.getProviderConnectionById,P:()=>h.getProviderConnections,Qu:()=>i.getProviderNodeById,Fh:()=>i.getProviderNodes,hr:()=>n,ui:()=>m,LF:()=>r.LF,Zx:()=>at,SL:()=>aF,mt:()=>g.getSettings,BY:()=>ap,K1:()=>aJ,zY:()=>w,Op:()=>h.mutateProviderConnection,VT:()=>M.VT,yF:()=>M.yF,Pb:()=>D.rotateApiKey,KK:()=>r.KK,ox:()=>aE,sZ:()=>an,L9:()=>L.L9,o5:()=>L.o5,Kg:()=>L.Kg,_V:()=>Z,uw:()=>ak,XW:()=>D.updateApiKey,oG:()=>J,dK:()=>A,KJ:()=>M.KJ,rj:()=>h.updateProviderConnection,ho:()=>i.updateProviderNode,Q_:()=>p,Xx:()=>g.Xx,ek:()=>D.validateApiKey});var d=c(36366),e=c(63775),f=c(644),g=c(42655),h=c(5781),i=c(1129),j=c(47293);function k(a){return a?{...(0,f.q)(a.data,{}),id:a.id,isActive:1===a.isActive||!0===a.isActive,testStatus:a.testStatus,createdAt:a.createdAt,updatedAt:a.updatedAt}:null}function l(a,b){let c=function(a){let{id:b,isActive:c,testStatus:d,createdAt:e,updatedAt:g,...h}=a;return{id:b,isActive:+(!1!==c),testStatus:d??null,data:(0,f.s)(h),createdAt:e,updatedAt:g}}(b);a.run(`INSERT INTO proxyPools(id, isActive, testStatus, data, createdAt, updatedAt)
|
|
18
|
+
`,e={_meta:{columns:{key:"TEXT PRIMARY KEY",value:"TEXT NOT NULL"}},settings:{columns:{id:"INTEGER PRIMARY KEY CHECK (id = 1)",data:"TEXT NOT NULL"}},providerConnections:{columns:{id:"TEXT PRIMARY KEY",provider:"TEXT NOT NULL",authType:"TEXT NOT NULL",name:"TEXT",email:"TEXT",priority:"INTEGER",isActive:"INTEGER DEFAULT 1",data:"TEXT NOT NULL",createdAt:"TEXT NOT NULL",updatedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_pc_provider ON providerConnections(provider)","CREATE INDEX IF NOT EXISTS idx_pc_provider_active ON providerConnections(provider, isActive)","CREATE INDEX IF NOT EXISTS idx_pc_priority ON providerConnections(provider, priority)"]},providerNodes:{columns:{id:"TEXT PRIMARY KEY",type:"TEXT",name:"TEXT",data:"TEXT NOT NULL",createdAt:"TEXT NOT NULL",updatedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_pn_type ON providerNodes(type)"]},proxyPools:{columns:{id:"TEXT PRIMARY KEY",isActive:"INTEGER DEFAULT 1",testStatus:"TEXT",data:"TEXT NOT NULL",createdAt:"TEXT NOT NULL",updatedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_pp_active ON proxyPools(isActive)","CREATE INDEX IF NOT EXISTS idx_pp_status ON proxyPools(testStatus)"]},apiKeys:{columns:{id:"TEXT PRIMARY KEY",key:"TEXT UNIQUE NOT NULL",name:"TEXT",machineId:"TEXT",isActive:"INTEGER DEFAULT 1",createdAt:"TEXT NOT NULL",budgetDaily:"REAL DEFAULT 0",budgetMonthly:"REAL DEFAULT 0",requestsPerMinute:"INTEGER DEFAULT 0",allowedModels:"TEXT",allowedConnectionIds:"TEXT"},indexes:["CREATE INDEX IF NOT EXISTS idx_ak_key ON apiKeys(key)"]},combos:{columns:{id:"TEXT PRIMARY KEY",name:"TEXT UNIQUE NOT NULL",kind:"TEXT",models:"TEXT NOT NULL",createdAt:"TEXT NOT NULL",updatedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_combo_name ON combos(name)"]},kv:{columns:{scope:"TEXT NOT NULL",key:"TEXT NOT NULL",value:"TEXT NOT NULL"},primaryKey:"PRIMARY KEY (scope, key)",indexes:["CREATE INDEX IF NOT EXISTS idx_kv_scope ON kv(scope)"]},usageHistory:{columns:{id:"INTEGER PRIMARY KEY AUTOINCREMENT",timestamp:"TEXT NOT NULL",provider:"TEXT",model:"TEXT",connectionId:"TEXT",apiKey:"TEXT",endpoint:"TEXT",promptTokens:"INTEGER DEFAULT 0",completionTokens:"INTEGER DEFAULT 0",cost:"REAL DEFAULT 0",status:"TEXT",tokens:"TEXT",meta:"TEXT"},indexes:["CREATE INDEX IF NOT EXISTS idx_uh_ts ON usageHistory(timestamp DESC)","CREATE INDEX IF NOT EXISTS idx_uh_provider ON usageHistory(provider)","CREATE INDEX IF NOT EXISTS idx_uh_model ON usageHistory(model)","CREATE INDEX IF NOT EXISTS idx_uh_conn ON usageHistory(connectionId)"]},usageDaily:{columns:{dateKey:"TEXT PRIMARY KEY",data:"TEXT NOT NULL"}},requestDetails:{columns:{id:"TEXT PRIMARY KEY",timestamp:"TEXT NOT NULL",provider:"TEXT",model:"TEXT",connectionId:"TEXT",status:"TEXT",data:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_rd_ts ON requestDetails(timestamp DESC)","CREATE INDEX IF NOT EXISTS idx_rd_provider ON requestDetails(provider)","CREATE INDEX IF NOT EXISTS idx_rd_model ON requestDetails(model)","CREATE INDEX IF NOT EXISTS idx_rd_conn ON requestDetails(connectionId)"]},quotaCache:{columns:{connectionId:"TEXT PRIMARY KEY",provider:"TEXT",data:"TEXT NOT NULL",fetchedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_qc_provider ON quotaCache(provider)"]},contextFiles:{columns:{id:"TEXT PRIMARY KEY",name:"TEXT NOT NULL",content:"TEXT NOT NULL",enabled:"INTEGER DEFAULT 1",priority:"INTEGER DEFAULT 0",createdAt:"TEXT NOT NULL",updatedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_cf_enabled ON contextFiles(enabled, priority)"]}};function f(a,b){let c=Object.entries(b.columns).map(([a,b])=>`${a} ${b}`);return b.primaryKey&&c.push(b.primaryKey),`CREATE TABLE IF NOT EXISTS ${a} (${c.join(", ")})`}},74452:(a,b,c)=>{c.r(b),c.d(b,{admitApiKeyRequest:()=>q,checkApiKeyBudget:()=>u,createApiKey:()=>n,deleteApiKey:()=>r,getApiKeyById:()=>m,getApiKeyConnectionPolicy:()=>t,getApiKeys:()=>l,maskApiKey:()=>j,rotateApiKey:()=>p,updateApiKey:()=>o,validateApiKey:()=>s});var d=c(47293),e=c(36366);let f=new Map,g=new Map;function h(a){if(Array.isArray(a))return a;if(!a)return[];try{return JSON.parse(a)}catch{return[]}}function i(a){let b=a;if(!Array.isArray(b)){if(!b)return[];try{b=JSON.parse(b)}catch{return[]}}return Array.isArray(b)?[...new Set(b.filter(a=>"string"==typeof a).map(a=>a.trim()).filter(Boolean))]:[]}function j(a){return a?a.length<=12?`${a.slice(0,4)}…`:`${a.slice(0,8)}…${a.slice(-4)}`:null}function k(a,b=!1){return a?{id:a.id,key:b?a.key:void 0,maskedKey:j(a.key),name:a.name,machineId:a.machineId,isActive:1===a.isActive||!0===a.isActive,createdAt:a.createdAt,budgetDaily:a.budgetDaily||0,budgetMonthly:a.budgetMonthly||0,requestsPerMinute:a.requestsPerMinute||0,allowedModels:h(a.allowedModels),allowedConnectionIds:i(a.allowedConnectionIds)}:null}async function l(a=!1){return(await (0,e.getAdapter)()).all("SELECT * FROM apiKeys ORDER BY createdAt ASC").map(b=>k(b,a))}async function m(a,b=!1){return k((await (0,e.getAdapter)()).get("SELECT * FROM apiKeys WHERE id = ?",[a]),b)}async function n(a,b){if(!b)throw Error("machineId is required");let f=await (0,e.getAdapter)(),{generateApiKeyWithMachine:g}=await c.e(6844).then(c.bind(c,86844)),h=g(b),i={id:(0,d.A)(),name:a,key:h.key,machineId:b,isActive:!0,createdAt:new Date().toISOString()};return f.run("INSERT INTO apiKeys(id, key, name, machineId, isActive, createdAt) VALUES(?, ?, ?, ?, ?, ?)",[i.id,i.key,i.name,i.machineId,1,i.createdAt]),i}async function o(a,b){let c=await (0,e.getAdapter)(),d=null;return c.transaction(()=>{let e=c.get("SELECT * FROM apiKeys WHERE id = ?",[a]);if(!e)return;let f={...k(e,!0),...b};c.run("UPDATE apiKeys SET key = ?, name = ?, machineId = ?, isActive = ?, budgetDaily = ?, budgetMonthly = ?, requestsPerMinute = ?, allowedModels = ?, allowedConnectionIds = ? WHERE id = ?",[f.key,f.name,f.machineId,+!!f.isActive,Number(f.budgetDaily)||0,Number(f.budgetMonthly)||0,Number(f.requestsPerMinute)||0,JSON.stringify(f.allowedModels||[]),JSON.stringify(i(f.allowedConnectionIds)),a]),d=f}),d}async function p(a){let b=await (0,e.getAdapter)(),d=b.get("SELECT * FROM apiKeys WHERE id = ?",[a]);if(!d)return null;let{generateApiKeyWithMachine:f}=await c.e(6844).then(c.bind(c,86844)),g=f(d.machineId).key;return b.run("UPDATE apiKeys SET key = ? WHERE id = ?",[g,a]),{...k({...d,key:g}),key:g}}async function q(a,b){let c=(await (0,e.getAdapter)()).get("SELECT budgetDaily, budgetMonthly, requestsPerMinute, allowedModels FROM apiKeys WHERE key = ?",[a]);if(!c)return{allowed:!0,touch(){},release(){}};let d=h(c.allowedModels);if(d.length>0&&!d.includes(b))return{allowed:!1,status:403,reason:`Model ${b} is not allowed for this API key`};let i=Number(c.requestsPerMinute)||0;if(i>0){let b=Date.now(),c=(g.get(a)||[]).filter(a=>b-a<6e4);if(c.length>=i){let d=Math.max(1,Math.ceil((6e4-(b-c[0]))/1e3));return g.set(a,c),{allowed:!1,status:429,retryAfter:d,reason:"API key rate limit exceeded"}}c.push(b),!g.has(a)&&g.size>=1e4&&function(a){for(let[b,c]of g)(0===c.length||a-c[c.length-1]>=6e4)&&g.delete(b)}(b),g.set(a,c)}if(!(Number(c.budgetDaily)>0||Number(c.budgetMonthly)>0))return{allowed:!0,touch(){},release(){}};let j=Date.now(),k=f.get(a);if(k&&j-k.activeAt<6e4)return{allowed:!1,status:429,retryAfter:1,reason:"A budgeted request is already in progress"};let l={token:Symbol("budget-slot"),activeAt:j};return f.set(a,l),{allowed:!0,touch:()=>{let b=f.get(a);b?.token===l.token&&(b.activeAt=Date.now())},release:()=>{f.get(a)?.token===l.token&&f.delete(a)}}}async function r(a){let b=(await (0,e.getAdapter)()).run("DELETE FROM apiKeys WHERE id = ?",[a]);return(b?.changes??0)>0}async function s(a){let b=(await (0,e.getAdapter)()).get("SELECT isActive FROM apiKeys WHERE key = ?",[a]);return!!b&&(1===b.isActive||!0===b.isActive)}async function t(a){if(!a)return null;let b=(await (0,e.getAdapter)()).get("SELECT allowedConnectionIds FROM apiKeys WHERE key = ?",[a]);return b?i(b.allowedConnectionIds):null}async function u(a){let b=await (0,e.getAdapter)(),c=b.get("SELECT budgetDaily, budgetMonthly FROM apiKeys WHERE key = ?",[a]);if(!c)return{allowed:!0};let d=c.budgetDaily||0,f=c.budgetMonthly||0;if(d<=0&&f<=0)return{allowed:!0,budgetDaily:d,budgetMonthly:f};let g=0,h=0;try{if(d>0){let c=new Date;c.setHours(0,0,0,0);let d=b.get("SELECT COALESCE(SUM(cost), 0) AS total FROM usageHistory WHERE apiKey = ? AND timestamp >= ?",[a,c.toISOString()]);g=d?.total||0}if(f>0){let c=new Date;c.setDate(1),c.setHours(0,0,0,0);let d=b.get("SELECT COALESCE(SUM(cost), 0) AS total FROM usageHistory WHERE apiKey = ? AND timestamp >= ?",[a,c.toISOString()]);h=d?.total||0}}catch(a){return{allowed:!1,error:!0,reason:"Budget accounting unavailable"}}return d>0&&g>=d?{allowed:!1,reason:`Daily budget exceeded ($${g.toFixed(4)} / $${d})`,spentDaily:g,spentMonthly:h,budgetDaily:d,budgetMonthly:f}:f>0&&h>=f?{allowed:!1,reason:`Monthly budget exceeded ($${h.toFixed(4)} / $${f})`,spentDaily:g,spentMonthly:h,budgetDaily:d,budgetMonthly:f}:{allowed:!0,spentDaily:g,spentMonthly:h,budgetDaily:d,budgetMonthly:f}}},93999:(a,b,c)=>{c.d(b,{S8:()=>L.S8,admitApiKeyRequest:()=>D.admitApiKeyRequest,E5:()=>as,checkApiKeyBudget:()=>D.checkApiKeyBudget,Iq:()=>D.createApiKey,jd:()=>I,QI:()=>z,p3:()=>C,iE:()=>h.createProviderConnection,i0:()=>i.createProviderNode,ZO:()=>o,Lh:()=>D.deleteApiKey,CG:()=>K,NR:()=>B,uL:()=>L.uL,fv:()=>L.fv,fK:()=>h.deleteProviderConnection,op:()=>h.deleteProviderConnectionsByProvider,Pc:()=>i.deleteProviderNode,Yd:()=>q,tm:()=>P,oF:()=>Q,zP:()=>aI,rg:()=>al,tV:()=>r.tV,yg:()=>D.getApiKeyById,ME:()=>D.getApiKeyConnectionPolicy,PX:()=>D.getApiKeys,j$:()=>aq,L:()=>G,Dj:()=>H,Uv:()=>F,yW:()=>y,uv:()=>L.uv,vF:()=>O,qd:()=>x,getLatencyStats:()=>ar,c:()=>L.getMitmAlias,OM:()=>L.OM,r4:()=>M.r4,Mc:()=>h.getProviderConnectionById,P:()=>h.getProviderConnections,Qu:()=>i.getProviderNodeById,Fh:()=>i.getProviderNodes,hr:()=>n,ui:()=>m,LF:()=>r.LF,Zx:()=>at,SL:()=>aF,mt:()=>g.getSettings,BY:()=>ap,K1:()=>aJ,zY:()=>w,Op:()=>h.mutateProviderConnection,VT:()=>M.VT,yF:()=>M.yF,Pb:()=>D.rotateApiKey,KK:()=>r.KK,ox:()=>aE,sZ:()=>an,L9:()=>L.L9,o5:()=>L.o5,Kg:()=>L.Kg,_V:()=>Z,uw:()=>ak,XW:()=>D.updateApiKey,oG:()=>J,dK:()=>A,KJ:()=>M.KJ,rj:()=>h.updateProviderConnection,ho:()=>i.updateProviderNode,Q_:()=>p,Xx:()=>g.Xx,ek:()=>D.validateApiKey});var d=c(36366),e=c(63775),f=c(644),g=c(42655),h=c(5781),i=c(1129),j=c(47293);function k(a){return a?{...(0,f.q)(a.data,{}),id:a.id,isActive:1===a.isActive||!0===a.isActive,testStatus:a.testStatus,createdAt:a.createdAt,updatedAt:a.updatedAt}:null}function l(a,b){let c=function(a){let{id:b,isActive:c,testStatus:d,createdAt:e,updatedAt:g,...h}=a;return{id:b,isActive:+(!1!==c),testStatus:d??null,data:(0,f.s)(h),createdAt:e,updatedAt:g}}(b);a.run(`INSERT INTO proxyPools(id, isActive, testStatus, data, createdAt, updatedAt)
|
|
19
19
|
VALUES(?, ?, ?, ?, ?, ?)
|
|
20
20
|
ON CONFLICT(id) DO UPDATE SET
|
|
21
21
|
isActive=excluded.isActive, testStatus=excluded.testStatus,
|
|
22
|
-
data=excluded.data, updatedAt=excluded.updatedAt`,[c.id,c.isActive,c.testStatus,c.data,c.createdAt,c.updatedAt])}async function m(a={}){let b=await (0,d.
|
|
23
|
-
VALUES(?, ?, ?, ?, ?, ?, ?)`,[g,String(a||"untitled"),String(b||""),+!!c,Number(e)||0,h,h]),u(),y(g)}async function A(a,b={}){let c=await y(a);if(!c)return null;let e=await (0,d.
|
|
24
|
-
VALUES(?, ?, ?, 0, ?, ?, ?)`,[g,a,d,e,h,h]),f.push({id:g,name:a}),e+=1}}),u(),f}var D=c(74452);function E(a){return a?{id:a.id,name:a.name,kind:a.kind,models:(0,f.q)(a.models,[]),createdAt:a.createdAt,updatedAt:a.updatedAt}:null}async function F(){return(await (0,d.cK)()).all("SELECT * FROM combos ORDER BY createdAt ASC").map(E)}async function G(a){return E((await (0,d.cK)()).get("SELECT * FROM combos WHERE id = ?",[a]))}async function H(a){return E((await (0,d.cK)()).get("SELECT * FROM combos WHERE name = ?",[a]))}async function I(a){let b=await (0,d.cK)(),c=new Date().toISOString(),e={id:(0,j.A)(),name:a.name,kind:a.kind||null,models:a.models||[],createdAt:c,updatedAt:c};return b.run("INSERT INTO combos(id, name, kind, models, createdAt, updatedAt) VALUES(?, ?, ?, ?, ?, ?)",[e.id,e.name,e.kind,(0,f.s)(e.models),e.createdAt,e.updatedAt]),e}async function J(a,b){let c=await (0,d.cK)(),e=null;return c.transaction(()=>{let d=c.get("SELECT * FROM combos WHERE id = ?",[a]);if(!d)return;let g={...E(d),...b,updatedAt:new Date().toISOString()};c.run("UPDATE combos SET name = ?, kind = ?, models = ?, updatedAt = ? WHERE id = ?",[g.name,g.kind,(0,f.s)(g.models||[]),g.updatedAt,a]),e=g}),e}async function K(a){let b=(await (0,d.cK)()).run("DELETE FROM combos WHERE id = ?",[a]);return(b?.changes??0)>0}var L=c(9460),M=c(97914);let N="disabledModels";async function O(){let a=(await (0,d.cK)()).all("SELECT key, value FROM kv WHERE scope = ?",[N]),b={};for(let c of a)b[c.key]=(0,f.q)(c.value,[]);return b}async function P(a,b){if(!a||!Array.isArray(b))return;let c=await (0,d.cK)();c.transaction(()=>{let d=c.get("SELECT value FROM kv WHERE scope = ? AND key = ?",[N,a]),e=[...new Set([...d&&(0,f.q)(d.value,[])||[],...b])];c.run("INSERT INTO kv(scope, key, value) VALUES(?, ?, ?) ON CONFLICT(scope, key) DO UPDATE SET value = excluded.value",[N,a,(0,f.s)(e)])})}async function Q(a,b){if(!a)return;let c=await (0,d.cK)();c.transaction(()=>{if(!Array.isArray(b)||0===b.length)return void c.run("DELETE FROM kv WHERE scope = ? AND key = ?",[N,a]);let d=c.get("SELECT value FROM kv WHERE scope = ? AND key = ?",[N,a]),e=d&&(0,f.q)(d.value,[])||[],g=new Set(b),h=e.filter(a=>!g.has(a));0===h.length?c.run("DELETE FROM kv WHERE scope = ? AND key = ?",[N,a]):c.run("INSERT INTO kv(scope, key, value) VALUES(?, ?, ?) ON CONFLICT(scope, key) DO UPDATE SET value = excluded.value",[N,a,(0,f.s)(h)])})}var R=c(94735),S=c(77598);c(62674);global._pendingRequests||(global._pendingRequests={byModel:{},byAccount:{}}),global._lastErrorProvider||(global._lastErrorProvider={provider:"",ts:0}),global._statsEmitter||(global._statsEmitter=new R.EventEmitter,global._statsEmitter.setMaxListeners(50)),global._pendingTimers||(global._pendingTimers={}),global._recentRing||(global._recentRing={items:[],initialized:!1}),global._connectionMapCache||(global._connectionMapCache={map:{},ts:0}),global._usageWritesInFlight||(global._usageWritesInFlight=new Set);let T=global._pendingRequests,U=global._lastErrorProvider,V=global._pendingTimers,W=global._recentRing,X=global._connectionMapCache,Y=global._usageWritesInFlight,Z=global._statsEmitter;function $(a){let b=a?new Date(a):new Date;return`${b.getFullYear()}-${String(b.getMonth()+1).padStart(2,"0")}-${String(b.getDate()).padStart(2,"0")}`}function _(a,b,c){a[b]||(a[b]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0}),a[b].requests+=c.requests||1,a[b].promptTokens+=c.promptTokens||0,a[b].completionTokens+=c.completionTokens||0,a[b].cachedTokens=(a[b].cachedTokens||0)+(c.cachedTokens||0),a[b].cost+=c.cost||0,c.meta&&Object.assign(a[b],c.meta)}function aa(a){return a&&"object"==typeof a&&(a.cached_tokens||a.prompt_tokens_details?.cached_tokens||a.cache_read_input_tokens)||0}function ab(a,b,c){return`${a}|${b||"unknown"}|${c||"unknown"}`}function ac(a,b,c){return`${a||"local-no-key"}|${b||"unknown"}|${c||"unknown"}`}function ad(a){return(0,S.createHash)("sha256").update(String(a)).digest("hex").slice(0,20)}function ae(a,b){return a?b?.name||`External Key ${ad(a).slice(0,8)}`:"Local (No API Key)"}async function af(){if(Date.now()-X.ts<3e4)return X.map;try{let{getProviderConnections:a}=await Promise.resolve().then(c.bind(c,5781)),b=await a(),d={};for(let a of b)d[a.id]=a.name||a.email||a.id;X.map=d,X.ts=Date.now()}catch{}return X.map}async function ag(){if(!W.initialized){W.initialized=!0;try{W.items=(await (0,d.cK)()).all("SELECT timestamp, provider, model, connectionId, apiKey, endpoint, cost, status, tokens FROM usageHistory ORDER BY id DESC LIMIT ?",[50]).reverse().map(a=>({timestamp:a.timestamp,provider:a.provider,model:a.model,connectionId:a.connectionId,apiKey:a.apiKey,endpoint:a.endpoint,cost:a.cost,status:a.status,tokens:(0,f.q)(a.tokens,{})}))}catch{}}}async function ah(a,b,d){if(!d||!a||!b)return 0;try{let{getPricingForModel:e}=await Promise.resolve().then(c.bind(c,97914)),f=await e(a,b);if(!f)return 0;let g=0,h=d.prompt_tokens||d.input_tokens||0,i=aa(d),j=void 0!==d.cached_tokens||d.prompt_tokens_details?.cached_tokens!==void 0?Math.max(0,h-i):h;if(g+=j*(f.input/1e6),i>0){let a=f.cached||f.input;g+=a/1e6*i}let k=d.completion_tokens||d.output_tokens||0;g+=k*(f.output/1e6);let l=d.reasoning_tokens||0;if(l>0){let a=f.reasoning||f.output;g+=a/1e6*l}let m=d.cache_creation_input_tokens||0;if(m>0){let a=f.cache_creation||f.input;g+=a/1e6*m}return g}catch(a){return console.error("Error calculating cost:",a),0}}function ai(a,b=20){let c=new Set;return a.filter(a=>{if(0===a.promptTokens&&0===a.completionTokens)return!1;let b=JSON.stringify([a.timestamp,a.model,a.provider,a.promptTokens,a.completionTokens]);return!c.has(b)&&(c.add(b),!0)}).slice(0,b)}function aj(a,b,c){T.byModel[a]||(T.byModel[a]=0),T.byModel[a]=Math.max(0,T.byModel[a]+c),0===T.byModel[a]&&delete T.byModel[a],b&&(T.byAccount[b]||(T.byAccount[b]={}),T.byAccount[b][a]||(T.byAccount[b][a]=0),T.byAccount[b][a]=Math.max(0,T.byAccount[b][a]+c),0===T.byAccount[b][a]&&(delete T.byAccount[b][a],0===Object.keys(T.byAccount[b]).length&&delete T.byAccount[b]))}function ak(a,b,c,d,e=!1){let f=b?`${a} (${b})`:a,g=`${c}|${f}`;if(aj(f,c,d?1:-1),d){let a=function(a,b,c){let d=V[a];if(Array.isArray(d))return d;d&&(clearTimeout(d),aj(b,c,-1));let e=[];return V[a]=e,e}(g,f,c),b=setTimeout(()=>{let a=V[g];if(Array.isArray(a)){let c=a.indexOf(b);c>=0&&a.splice(c,1),0===a.length&&delete V[g]}aj(f,c,-1),Z.emit("pending")},6e4);b.unref?.(),a.push(b)}else{let a=V[g];if(Array.isArray(a)){let b=a.shift();b&&clearTimeout(b),0===a.length&&delete V[g]}else a&&(clearTimeout(a),delete V[g])}!d&&e&&b&&(U.provider=b.toLowerCase(),U.ts=Date.now()),Z.emit("pending")}async function al(){let a=[],b=await af();for(let[c,d]of Object.entries(T.byAccount))for(let[e,f]of Object.entries(d))if(f>0){let d=b[c]||`Account ${c.slice(0,8)}...`,g=e.match(/^(.*) \((.*)\)$/);a.push({model:g?g[1]:e,provider:g?g[2]:"unknown",account:d,count:f})}return await ag(),{activeRequests:a,recentRequests:ai([...W.items].sort((a,b)=>new Date(b.timestamp)-new Date(a.timestamp)).map(a=>{let b=a.tokens||{};return{timestamp:a.timestamp,model:a.model,provider:a.provider||"",promptTokens:b.prompt_tokens||b.input_tokens||0,completionTokens:b.completion_tokens||b.output_tokens||0,status:a.status||"ok"}})),errorProvider:Date.now()-U.ts<1e4?U.provider:""}}async function am(a){try{let b=await (0,d.cK)();a.timestamp||(a.timestamp=new Date().toISOString()),a.cost=await ah(a.provider,a.model,a.tokens);let c=a.tokens||{},e=c.prompt_tokens||c.input_tokens||0,g=c.completion_tokens||c.output_tokens||0;b.transaction(()=>{b.run("INSERT INTO usageHistory(timestamp, provider, model, connectionId, apiKey, endpoint, promptTokens, completionTokens, cost, status, tokens, meta) VALUES(?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)",[a.timestamp,a.provider||null,a.model||null,a.connectionId||null,a.apiKey||null,a.endpoint||null,e,g,a.cost||0,a.status||"ok",(0,f.s)(c),(0,f.s)(a.latency&&"object"==typeof a.latency?{latency:{ttft:a.latency.ttft||0,total:a.latency.total||0}}:{})]);let d=$(a.timestamp),h=b.get("SELECT data FROM usageDaily WHERE dateKey = ?",[d]),i=h?(0,f.q)(h.data,{}):{requests:0,promptTokens:0,completionTokens:0,cost:0,byProvider:{},byModel:{},byAccount:{},byApiKey:{},byEndpoint:{}};!function(a,b){let c=b.tokens?.prompt_tokens||b.tokens?.input_tokens||0,d=b.tokens?.completion_tokens||b.tokens?.output_tokens||0,e=aa(b.tokens),f=b.cost||0,g={promptTokens:c,completionTokens:d,cachedTokens:e,cost:f};a.requests=(a.requests||0)+1,a.promptTokens=(a.promptTokens||0)+c,a.completionTokens=(a.completionTokens||0)+d,a.cachedTokens=(a.cachedTokens||0)+e,a.cost=(a.cost||0)+f,a.byProvider||={},a.byModel||={},a.byAccount||={},a.byApiKey||={},a.byEndpoint||={},b.provider&&_(a.byProvider,b.provider,g);let h=b.provider?`${b.model}|${b.provider}`:b.model;if(_(a.byModel,h,{...g,meta:{rawModel:b.model,provider:b.provider}}),b.connectionId){let c=ab(b.connectionId,b.model,b.provider);_(a.byAccount,c,{...g,meta:{connectionId:b.connectionId,rawModel:b.model,provider:b.provider}})}let i=ac(b.apiKey&&"string"==typeof b.apiKey?b.apiKey:null,b.model,b.provider);_(a.byApiKey,i,{...g,meta:{rawModel:b.model,provider:b.provider,apiKey:b.apiKey||null}});let j=b.endpoint||"Unknown",k=`${j}|${b.model}|${b.provider||"unknown"}`;_(a.byEndpoint,k,{...g,meta:{endpoint:j,rawModel:b.model,provider:b.provider}})}(i,a),b.run("INSERT INTO usageDaily(dateKey, data) VALUES(?, ?) ON CONFLICT(dateKey) DO UPDATE SET data = excluded.data",[d,(0,f.s)(i)]);let j=b.get("SELECT value FROM _meta WHERE key = 'totalRequestsLifetime'"),k=(j?parseInt(j.value,10):0)+1;b.run("INSERT INTO _meta(key, value) VALUES('totalRequestsLifetime', ?) ON CONFLICT(key) DO UPDATE SET value = excluded.value",[String(k)])}),W.items.push(a),W.items.length>50&&(W.items=W.items.slice(-50)),Z.emit("update")}catch(a){console.error("Failed to save usage stats:",a)}}function an(a){let b=am(a);return Y.add(b),b.finally(()=>Y.delete(b)),b}function ao(a,b){if(null==b)return a.all("SELECT dateKey, data FROM usageDaily");let c=new Date,d=new Date(c.getFullYear(),c.getMonth(),c.getDate()-b+1),e=`${d.getFullYear()}-${String(d.getMonth()+1).padStart(2,"0")}-${String(d.getDate()).padStart(2,"0")}`;return a.all("SELECT dateKey, data FROM usageDaily WHERE dateKey >= ?",[e])}async function ap(a="all"){let b=await (0,d.cK)(),[{getProviderConnections:e},{getApiKeys:g},{getProviderNodes:h}]=await Promise.all([Promise.resolve().then(c.bind(c,5781)),Promise.resolve().then(c.bind(c,74452)),Promise.resolve().then(c.bind(c,1129))]),i=[];try{i=await e()}catch{}let j={};for(let a of i)j[a.id]=a.name||a.email||a.id;let k={};try{for(let a of(await h()))a.id&&a.name&&(k[a.id]=a.name)}catch{}let l=[];try{l=await g(!0)}catch{}let m={};for(let a of l)m[a.key]={name:a.name,id:a.id,createdAt:a.createdAt};let n={totalRequests:0,totalPromptTokens:0,totalCompletionTokens:0,totalCachedTokens:0,totalCost:0,byProvider:{},byModel:{},byAccount:{},byApiKey:{},byEndpoint:{},last10Minutes:[],pending:T,activeRequests:[],recentRequests:ai(b.all("SELECT timestamp, provider, model, tokens, status FROM usageHistory ORDER BY id DESC LIMIT 100").map(a=>{let b=(0,f.q)(a.tokens,{})||{};return{timestamp:a.timestamp,model:a.model,provider:a.provider||"",promptTokens:b.prompt_tokens||b.input_tokens||0,completionTokens:b.completion_tokens||b.output_tokens||0,status:a.status||"ok"}})),errorProvider:Date.now()-U.ts<1e4?U.provider:""};for(let[a,b]of Object.entries(T.byAccount))for(let[c,d]of Object.entries(b))if(d>0){let b=j[a]||`Account ${a.slice(0,8)}...`,e=c.match(/^(.*) \((.*)\)$/);n.activeRequests.push({model:e?e[1]:c,provider:e?e[2]:"unknown",account:b,count:d})}let o=new Date,p=new Date(6e4*Math.floor(o.getTime()/6e4)),q=new Date(p.getTime()-54e4),r={};for(let a=0;a<10;a++){let b=p.getTime()-(9-a)*6e4;r[b]={requests:0,promptTokens:0,completionTokens:0,cost:0},n.last10Minutes.push(r[b])}for(let a of b.all("SELECT timestamp, promptTokens, completionTokens, cost FROM usageHistory WHERE timestamp >= ? AND timestamp <= ?",[q.toISOString(),o.toISOString()])){let b=6e4*Math.floor(new Date(a.timestamp).getTime()/6e4);r[b]&&(r[b].requests++,r[b].promptTokens+=a.promptTokens||0,r[b].completionTokens+=a.completionTokens||0,r[b].cost+=a.cost||0)}if("24h"!==a&&"today"!==a){let c={"7d":7,"30d":30,"60d":60}[a]||null,d=ao(b,c),e=c?Date.now()-864e5*c:0,g=b.all("SELECT timestamp, provider, model, connectionId, apiKey, endpoint, promptTokens, completionTokens, cost, tokens FROM usageHistory WHERE timestamp >= ?",[new Date(e).toISOString()]),h={};for(let a of g){let b=$(a.timestamp);(h[b]||=[]).push(a)}for(let a of d){let b=a.dateKey,c=(0,f.q)(a.data,{});for(let[a,b]of(n.totalPromptTokens+=c.promptTokens||0,n.totalCompletionTokens+=c.completionTokens||0,n.totalCachedTokens+=c.cachedTokens||0,n.totalCost+=c.cost||0,Object.entries(c.byProvider||{})))n.byProvider[a]||(n.byProvider[a]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0}),n.byProvider[a].requests+=b.requests||0,n.byProvider[a].promptTokens+=b.promptTokens||0,n.byProvider[a].completionTokens+=b.completionTokens||0,n.byProvider[a].cachedTokens=(n.byProvider[a].cachedTokens||0)+(b.cachedTokens||0),n.byProvider[a].cost+=b.cost||0;for(let[a,d]of Object.entries(c.byModel||{})){let c=d.rawModel||a.split("|")[0],e=d.provider||a.split("|")[1]||"",f=e?`${c} (${e})`:c,g=k[e]||e;n.byModel[f]||(n.byModel[f]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0,rawModel:c,provider:g,lastUsed:b}),n.byModel[f].requests+=d.requests||0,n.byModel[f].promptTokens+=d.promptTokens||0,n.byModel[f].completionTokens+=d.completionTokens||0,n.byModel[f].cachedTokens+=d.cachedTokens||0,n.byModel[f].cost+=d.cost||0,b>(n.byModel[f].lastUsed||"")&&(n.byModel[f].lastUsed=b)}let d=c.byAccount||{},e=Object.values(d).some(a=>!a?.connectionId),g=h[b]||[];for(let[a,h]of(e&&g.length===(c.requests||0)&&(d=function(a){let b={};for(let c of a){if(!c.connectionId)continue;let a=(0,f.q)(c.tokens,{})||{},d=c.promptTokens||a.prompt_tokens||a.input_tokens||0,e=c.completionTokens||a.completion_tokens||a.output_tokens||0;_(b,ab(c.connectionId,c.model,c.provider),{requests:1,promptTokens:d,completionTokens:e,cachedTokens:aa(a),cost:c.cost||0,meta:{connectionId:c.connectionId,rawModel:c.model||"",provider:c.provider||""}})}return b}(g)),Object.entries(d))){let c=h.connectionId||a,d=j[c]||`Account ${c.slice(0,8)}...`,e=h.rawModel||"",f=h.provider||"",g=k[f]||f,i=ab(c,e,f);n.byAccount[i]||(n.byAccount[i]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0,rawModel:e,provider:g,providerId:f,connectionId:c,accountName:d,lastUsed:b}),n.byAccount[i].requests+=h.requests||0,n.byAccount[i].promptTokens+=h.promptTokens||0,n.byAccount[i].completionTokens+=h.completionTokens||0,n.byAccount[i].cachedTokens+=h.cachedTokens||0,n.byAccount[i].cost+=h.cost||0,b>(n.byAccount[i].lastUsed||"")&&(n.byAccount[i].lastUsed=b)}for(let[a,d]of Object.entries(c.byApiKey||{})){let c=d.rawModel||"",e=d.provider||"",f=k[e]||e,g=d.apiKey,h=g?m[g]:null,i=ae(g,h),j=g||"local-no-key";n.byApiKey[a]||(n.byApiKey[a]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0,rawModel:c,provider:f,apiKey:g,keyName:i,apiKeyKey:j,lastUsed:b}),n.byApiKey[a].requests+=d.requests||0,n.byApiKey[a].promptTokens+=d.promptTokens||0,n.byApiKey[a].completionTokens+=d.completionTokens||0,n.byApiKey[a].cachedTokens+=d.cachedTokens||0,n.byApiKey[a].cost+=d.cost||0,b>(n.byApiKey[a].lastUsed||"")&&(n.byApiKey[a].lastUsed=b)}for(let[a,d]of Object.entries(c.byEndpoint||{})){let c=d.endpoint||a.split("|")[0]||"Unknown",e=d.rawModel||"",f=d.provider||"",g=k[f]||f;n.byEndpoint[a]||(n.byEndpoint[a]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0,endpoint:c,rawModel:e,provider:g,lastUsed:b}),n.byEndpoint[a].requests+=d.requests||0,n.byEndpoint[a].promptTokens+=d.promptTokens||0,n.byEndpoint[a].completionTokens+=d.completionTokens||0,n.byEndpoint[a].cachedTokens+=d.cachedTokens||0,n.byEndpoint[a].cost+=d.cost||0,b>(n.byEndpoint[a].lastUsed||"")&&(n.byEndpoint[a].lastUsed=b)}}for(let a of g){let b=a.timestamp,c=a.provider?`${a.model} (${a.provider})`:a.model;if(n.byModel[c]&&new Date(b)>new Date(n.byModel[c].lastUsed)&&(n.byModel[c].lastUsed=b),a.connectionId){let c=ab(a.connectionId,a.model,a.provider);n.byAccount[c]&&new Date(b)>new Date(n.byAccount[c].lastUsed)&&(n.byAccount[c].lastUsed=b)}let d=ac(a.apiKey&&"string"==typeof a.apiKey?a.apiKey:null,a.model,a.provider);n.byApiKey[d]&&new Date(b)>new Date(n.byApiKey[d].lastUsed)&&(n.byApiKey[d].lastUsed=b);let e=a.endpoint||"Unknown",f=`${e}|${a.model}|${a.provider||"unknown"}`;n.byEndpoint[f]&&new Date(b)>new Date(n.byEndpoint[f].lastUsed)&&(n.byEndpoint[f].lastUsed=b)}}else{let c;if("today"===a){let a=new Date;a.setHours(0,0,0,0),c=a.toISOString()}else c=new Date(Date.now()-864e5).toISOString();for(let a of b.all("SELECT timestamp, provider, model, connectionId, apiKey, endpoint, promptTokens, completionTokens, cost, tokens FROM usageHistory WHERE timestamp >= ?",[c])){let b=(0,f.q)(a.tokens,{})||{},c=b.prompt_tokens||b.input_tokens||0,d=b.completion_tokens||b.output_tokens||0,e=aa(b),g=a.cost||0,h=k[a.provider]||a.provider;n.totalPromptTokens+=c,n.totalCompletionTokens+=d,n.totalCachedTokens+=e,n.totalCost+=g,n.byProvider[a.provider]||(n.byProvider[a.provider]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0}),n.byProvider[a.provider].requests++,n.byProvider[a.provider].promptTokens+=c,n.byProvider[a.provider].completionTokens+=d,n.byProvider[a.provider].cachedTokens=(n.byProvider[a.provider].cachedTokens||0)+e,n.byProvider[a.provider].cost+=g;let i=a.provider?`${a.model} (${a.provider})`:a.model;if(n.byModel[i]||(n.byModel[i]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0,rawModel:a.model,provider:h,lastUsed:a.timestamp}),n.byModel[i].requests++,n.byModel[i].promptTokens+=c,n.byModel[i].completionTokens+=d,n.byModel[i].cachedTokens+=e,n.byModel[i].cost+=g,new Date(a.timestamp)>new Date(n.byModel[i].lastUsed)&&(n.byModel[i].lastUsed=a.timestamp),a.connectionId){let b=j[a.connectionId]||`Account ${a.connectionId.slice(0,8)}...`,f=ab(a.connectionId,a.model,a.provider);n.byAccount[f]||(n.byAccount[f]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0,rawModel:a.model,provider:h,providerId:a.provider,connectionId:a.connectionId,accountName:b,lastUsed:a.timestamp}),n.byAccount[f].requests++,n.byAccount[f].promptTokens+=c,n.byAccount[f].completionTokens+=d,n.byAccount[f].cachedTokens+=e,n.byAccount[f].cost+=g,new Date(a.timestamp)>new Date(n.byAccount[f].lastUsed)&&(n.byAccount[f].lastUsed=a.timestamp)}if(a.apiKey&&"string"==typeof a.apiKey){let b=m[a.apiKey],f=ae(a.apiKey,b),i=ac(a.apiKey,a.model,a.provider);n.byApiKey[i]||(n.byApiKey[i]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0,rawModel:a.model,provider:h,apiKey:a.apiKey,keyName:f,apiKeyKey:a.apiKey,lastUsed:a.timestamp});let j=n.byApiKey[i];j.requests++,j.promptTokens+=c,j.completionTokens+=d,j.cachedTokens+=e,j.cost+=g,new Date(a.timestamp)>new Date(j.lastUsed)&&(j.lastUsed=a.timestamp)}else{let b=ac(null,a.model,a.provider);n.byApiKey[b]||(n.byApiKey[b]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0,rawModel:a.model,provider:h,apiKey:null,keyName:"Local (No API Key)",apiKeyKey:"local-no-key",lastUsed:a.timestamp});let f=n.byApiKey[b];f.requests++,f.promptTokens+=c,f.completionTokens+=d,f.cachedTokens+=e,f.cost+=g,new Date(a.timestamp)>new Date(f.lastUsed)&&(f.lastUsed=a.timestamp)}let l=a.endpoint||"Unknown",o=`${l}|${a.model}|${a.provider||"unknown"}`;n.byEndpoint[o]||(n.byEndpoint[o]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0,endpoint:l,rawModel:a.model,provider:h,lastUsed:a.timestamp});let p=n.byEndpoint[o];p.requests++,p.promptTokens+=c,p.completionTokens+=d,p.cachedTokens+=e,p.cost+=g,new Date(a.timestamp)>new Date(p.lastUsed)&&(p.lastUsed=a.timestamp)}}return n.totalRequests=Object.values(n.byProvider).reduce((a,b)=>a+(b.requests||0),0),n.byApiKey=function(a,b){let c={};for(let[d,e]of Object.entries(a||{})){let a="string"==typeof e.apiKey&&e.apiKey?e.apiKey:null,f=a?b[a]:null,g=a?f?.id||`external-${ad(a)}`:"local-no-key",h={...e,apiKeyKey:g};delete h.apiKey,c[`bucket-${ad(d)}`]=h}return c}(n.byApiKey,m),n}async function aq(a="7d"){let b=await (0,d.cK)(),c=Date.now();if("today"===a){let a=new Date;a.setHours(0,0,0,0);let c=a.getTime(),d=c+864e5,e=Array.from({length:24},(a,b)=>({label:new Date(c+36e5*b).toLocaleTimeString("en-US",{hour:"2-digit",minute:"2-digit",hour12:!1}),tokens:0,cost:0}));for(let a of b.all("SELECT timestamp, promptTokens, completionTokens, cost FROM usageHistory WHERE timestamp >= ?",[new Date(c).toISOString()])){let b=new Date(a.timestamp).getTime();if(b<c||b>=d)continue;let f=Math.floor((b-c)/36e5);f>=0&&f<24&&(e[f].tokens+=(a.promptTokens||0)+(a.completionTokens||0),e[f].cost+=a.cost||0)}return e}if("24h"===a){let a=c-864e5,d=Array.from({length:24},(b,c)=>({label:new Date(a+36e5*c).toLocaleTimeString("en-US",{hour:"2-digit",minute:"2-digit",hour12:!1}),tokens:0,cost:0}));for(let e of b.all("SELECT timestamp, promptTokens, completionTokens, cost FROM usageHistory WHERE timestamp >= ?",[new Date(a).toISOString()])){let b=new Date(e.timestamp).getTime();if(b<a||b>c)continue;let f=Math.min(Math.floor((b-a)/36e5),23);d[f].tokens+=(e.promptTokens||0)+(e.completionTokens||0),d[f].cost+=e.cost||0}return d}let e="7d"===a?7:"30d"===a?30:60,g=new Date,h=ao(b,e),i={};for(let a of h)i[a.dateKey]=(0,f.q)(a.data,{});return Array.from({length:e},(a,b)=>{let c=new Date(g);c.setDate(c.getDate()-(e-1-b));let d=i[`${c.getFullYear()}-${String(c.getMonth()+1).padStart(2,"0")}-${String(c.getDate()).padStart(2,"0")}`];return{label:c.toLocaleDateString("en-US",{month:"short",day:"numeric"}),tokens:d?(d.promptTokens||0)+(d.completionTokens||0):0,cost:d&&d.cost||0}})}async function ar(a=3e5,b=2){let c=new Map;try{let e=await (0,d.cK)(),g=new Date(Date.now()-a).toISOString(),h=e.all("SELECT provider, connectionId, meta FROM usageHistory WHERE timestamp >= ? AND status = 'ok'",[g]),i=new Map;for(let a of h){if(!a.provider||!a.connectionId)continue;let b=(0,f.q)(a.meta,{}),c=b?.latency?.total;if("number"!=typeof c||c<=0)continue;let d=`${a.provider}|${a.connectionId}`,e=i.get(d)||{total:0,count:0};e.total+=c,e.count+=1,i.set(d,e)}for(let[a,d]of i.entries())d.count>=b&&c.set(a,{avgMs:Math.round(d.total/d.count),samples:d.count})}catch(a){console.error("[usageRepo] getLatencyStats failed:",a.message)}return c}async function as(){}async function at(a=200){try{let b=(await (0,d.cK)()).all("SELECT timestamp, provider, model, connectionId, promptTokens, completionTokens, status, tokens FROM usageHistory ORDER BY id DESC LIMIT ?",[a]);if(!b.length)return[];let e={};try{let{getProviderConnections:a}=await Promise.resolve().then(c.bind(c,5781));for(let b of(await a()))e[b.id]=b.name||b.email||""}catch{}return b.map(a=>{let b=function(a=new Date){let b=a=>String(a).padStart(2,"0");return`${b(a.getDate())}-${b(a.getMonth()+1)}-${a.getFullYear()} ${b(a.getHours())}:${b(a.getMinutes())}:${b(a.getSeconds())}`}(new Date(a.timestamp)),c=a.provider?.toUpperCase()||"-",d=a.model||"-",g=e[a.connectionId]||(a.connectionId?a.connectionId.slice(0,8):"-"),h=a.tokens?(0,f.q)(a.tokens,{}):{},i=a.promptTokens??h.prompt_tokens??"-",j=a.completionTokens??h.completion_tokens??"-";return`${b} | ${d} | ${c} | ${g} | ${i} | ${j} | ${a.status||"-"}`})}catch(a){return console.error("[usageRepo] getRecentLogs failed:",a.message),[]}}let au=null,av=0;async function aw(){if(au&&Date.now()-av<5e3)return au;try{let{getSettings:a}=await Promise.resolve().then(c.bind(c,42655)),b=await a(),d="false"!==process.env.OBSERVABILITY_ENABLED;au={enabled:"boolean"==typeof b.enableObservability?b.enableObservability:d,maxRecords:b.observabilityMaxRecords||parseInt(process.env.OBSERVABILITY_MAX_RECORDS||String(200),10),batchSize:b.observabilityBatchSize||parseInt(process.env.OBSERVABILITY_BATCH_SIZE||String(20),10),flushIntervalMs:b.observabilityFlushIntervalMs||parseInt(process.env.OBSERVABILITY_FLUSH_INTERVAL_MS||String(5e3),10),maxJsonSize:1024*(b.observabilityMaxJsonSize||parseInt(process.env.OBSERVABILITY_MAX_JSON_SIZE||"5",10))}}catch{au={enabled:!1,maxRecords:200,batchSize:20,flushIntervalMs:5e3,maxJsonSize:5120}}return av=Date.now(),au}let ax=[],ay=null,az=!1,aA=!1;function aB(a){let b=new WeakSet;return JSON.stringify(a??{},(a,c)=>{if("bigint"==typeof c)return c.toString();if(c&&"object"==typeof c){if(b.has(c))return"[Circular]";b.add(c)}return c})}function aC(a){return Math.min(1e3,Math.max(100,4*a))}async function aD(){if(az)return!1;if(0===ax.length)return!0;az=!0;let a=null,b=[],c=!1;try{a=await aw(),b=ax.splice(0,Math.max(1,a.batchSize));let e=await (0,d.cK)();e.transaction(()=>{for(let a of b)e.run("INSERT INTO requestDetails(id, timestamp, provider, model, connectionId, status, data) VALUES(?, ?, ?, ?, ?, ?, ?) ON CONFLICT(id) DO UPDATE SET timestamp = excluded.timestamp, provider = excluded.provider, model = excluded.model, connectionId = excluded.connectionId, status = excluded.status, data = excluded.data",[a.id,a.timestamp,a.provider,a.model,a.connectionId,a.status,(0,f.s)(a)]);let c=e.get("SELECT COUNT(*) as c FROM requestDetails");c&&c.c>a.maxRecords&&e.run("DELETE FROM requestDetails WHERE id IN (SELECT id FROM requestDetails ORDER BY timestamp ASC LIMIT ?)",[c.c-a.maxRecords])}),c=!0}catch(c){if(b.length>0){ax=[...b,...ax];let c=aC(a?.batchSize||20);ax.length>c&&(ax.splice(0,ax.length-c),aA||(aA=!0,console.warn(`[requestDetailsRepo] Buffer limit reached (${c}); dropping oldest observability records`)))}console.error("[requestDetailsRepo] Batch write failed:",c)}finally{az=!1,0===ax.length?aA=!1:ay||(ay=setTimeout(()=>{ay=null,aD().catch(()=>{})},c?0:Math.max(250,Math.min(a?.flushIntervalMs||5e3,5e3))),ay.unref?.())}return c}async function aE(a){let b=await aw();if(b.enabled){let c;c=aC(b.batchSize),ax.length>=c&&(ax.splice(0,ax.length-c+1),aA||(aA=!0,console.warn(`[requestDetailsRepo] Buffer limit reached (${c}); dropping oldest observability records`))),ax.push(function(a,b=5120){var c,d;let e,f,g,h=(c=a?.provider,Math.max(1024,Math.min(Number.isFinite(b)?b:5120,"kiro"===c?16384:65536))),i=a=>{try{let b=aB(a);if(b.length>h)return{_truncated:!0,_originalSize:b.length,_preview:b.substring(0,200)};return JSON.parse(b)}catch(a){return{_truncated:!0,_serializationError:a.message}}},j=a?.request&&"object"==typeof a.request?{...a.request,headers:function(a){if(!a||"object"!=typeof a)return{};let b=["authorization","x-api-key","cookie","token","api-key"],c={...a};for(let a of Object.keys(c))b.some(b=>a.toLowerCase().includes(b))&&delete c[a];return c}(a.request.headers)}:a?.request;return{id:a?.id||(d=a?.model,e=new Date().toISOString(),f=Math.random().toString(36).substring(2,8),g=d?d.replace(/[^a-zA-Z0-9-]/g,"-"):"unknown",`${e}-${f}-${g}`),provider:a?.provider||null,model:a?.model||null,connectionId:a?.connectionId||null,timestamp:a?.timestamp||new Date().toISOString(),status:a?.status||null,latency:i(a?.latency),tokens:i(a?.tokens),request:i(j),providerRequest:i(a?.providerRequest),providerResponse:i(a?.providerResponse),response:(a=>{let b=i(a);if(!b?._truncated||!Array.isArray(a?.tool_calls)||0===a.tool_calls.length)return b;let c=a.tool_calls.slice(0,8),d=Math.min(512,Math.max(64,Math.floor(h/Math.max(2*c.length,1))));return{...b,type:a.type,finish_reason:a.finish_reason,tool_calls:c.map(a=>{let b="string"==typeof a?.function?.arguments?a.function.arguments:aB(a?.function?.arguments),c=b.length>d;return{id:"string"==typeof a?.id?a.id.slice(0,256):null,type:"function",function:{name:"string"==typeof a?.function?.name?a.function.name.slice(0,256):"unknown",arguments:c?b.slice(0,d):b,...c?{arguments_truncated:!0,original_arguments_size:b.length}:{}}}}),...a.tool_calls.length>c.length?{tool_calls_truncated:!0,original_tool_call_count:a.tool_calls.length}:{}}})(a?.response)}}(a,b.maxJsonSize)),ax.length>=b.batchSize?(ay&&(clearTimeout(ay),ay=null),aD().catch(a=>console.error("[requestDetailsRepo] flush err:",a))):ay||(ay=setTimeout(()=>{ay=null,aD().catch(()=>{})},b.flushIntervalMs))}}async function aF(a={}){let b=await (0,d.cK)(),c=[],e=[];a.provider&&(c.push("provider = ?"),e.push(a.provider)),a.model&&(c.push("model = ?"),e.push(a.model)),a.connectionId&&(c.push("connectionId = ?"),e.push(a.connectionId)),a.status&&(c.push("status = ?"),e.push(a.status)),a.startDate&&(c.push("timestamp >= ?"),e.push(new Date(a.startDate).toISOString())),a.endDate&&(c.push("timestamp <= ?"),e.push(new Date(a.endDate).toISOString()));let g=c.length?`WHERE ${c.join(" AND ")}`:"",h=b.get(`SELECT COUNT(*) as c FROM requestDetails ${g}`,e),i=h?h.c:0,j=Number.isFinite(Number(a.page))?Math.max(1,Math.trunc(Number(a.page))):1,k=Number.isFinite(Number(a.pageSize))?Math.max(1,Math.trunc(Number(a.pageSize))):50,l=Math.max(1,Math.ceil(i/k)),m=Math.min(j,l);return{details:b.all(`SELECT data FROM requestDetails ${g} ORDER BY timestamp DESC LIMIT ? OFFSET ?`,[...e,k,(m-1)*k]).map(a=>(0,f.q)(a.data,{})),pagination:{page:m,pageSize:k,totalItems:i,totalPages:l,hasNext:m<l,hasPrev:m>1}}}let aG=new Set(["usageHistory","requestDetails","quotaCache"]),aH=new Set(["_meta"]);async function aI(){let a=await (0,d.cK)(),{exportSettings:b}=await Promise.resolve().then(c.bind(c,42655)),g=Object.keys(e.CG).filter(a=>!aG.has(a)),h={settings:await b(),providerConnections:a.all("SELECT * FROM providerConnections").map(a=>({...(0,f.q)(a.data,{}),id:a.id,provider:a.provider,authType:a.authType,name:a.name,email:a.email,priority:a.priority,isActive:1===a.isActive,createdAt:a.createdAt,updatedAt:a.updatedAt})),providerNodes:a.all("SELECT * FROM providerNodes").map(a=>({...(0,f.q)(a.data,{}),id:a.id,type:a.type,name:a.name,createdAt:a.createdAt,updatedAt:a.updatedAt})),proxyPools:a.all("SELECT * FROM proxyPools").map(a=>({...(0,f.q)(a.data,{}),id:a.id,isActive:1===a.isActive,testStatus:a.testStatus,createdAt:a.createdAt,updatedAt:a.updatedAt})),apiKeys:a.all("SELECT * FROM apiKeys").map(a=>({id:a.id,key:a.key,name:a.name,machineId:a.machineId,isActive:1===a.isActive,createdAt:a.createdAt,budgetDaily:a.budgetDaily||0,budgetMonthly:a.budgetMonthly||0,requestsPerMinute:a.requestsPerMinute||0,allowedModels:(0,f.q)(a.allowedModels,[]),allowedConnectionIds:(0,f.q)(a.allowedConnectionIds,[])})),combos:a.all("SELECT * FROM combos").map(a=>({id:a.id,name:a.name,kind:a.kind,models:(0,f.q)(a.models,[]),createdAt:a.createdAt,updatedAt:a.updatedAt})),modelAliases:{},customModels:[],mitmAlias:{},pricing:{},tables:Object.fromEntries(g.map(b=>[b,a.all(`SELECT * FROM "${b}"`)])),excludedTables:[...aG]};for(let b of a.all("SELECT key, value FROM kv WHERE scope = 'modelAliases'"))h.modelAliases[b.key]=(0,f.q)(b.value);for(let b of a.all("SELECT key, value FROM kv WHERE scope = 'customModels'"))h.customModels.push((0,f.q)(b.value));for(let b of a.all("SELECT key, value FROM kv WHERE scope = 'mitmAlias'"))h.mitmAlias[b.key]=(0,f.q)(b.value);for(let b of a.all("SELECT key, value FROM kv WHERE scope = 'pricing'"))h.pricing[b.key]=(0,f.q)(b.value);return h}async function aJ(a){if(!a||"object"!=typeof a||Array.isArray(a))throw Error("Invalid database payload");let b=await (0,d.cK)();return b.transaction(()=>{if(a.tables&&"object"==typeof a.tables&&!Array.isArray(a.tables)){for(let a of Object.keys(e.CG).reverse())!aG.has(a)&&(aH.has(a)||b.run(`DELETE FROM "${a}"`));for(let[c,d]of Object.entries(a.tables))if(e.CG[c]&&Array.isArray(d)&&!aH.has(c))for(let a of d){let d=Object.keys(a).filter(a=>e.CG[c].columns[a]);0!==d.length&&b.run(`INSERT INTO "${c}" (${d.map(a=>`"${a}"`).join(", ")}) VALUES (${d.map(()=>"?").join(", ")})`,d.map(b=>a[b]))}return}for(let c of(b.run("DELETE FROM settings"),b.run("DELETE FROM providerConnections"),b.run("DELETE FROM providerNodes"),b.run("DELETE FROM proxyPools"),b.run("DELETE FROM apiKeys"),b.run("DELETE FROM combos"),b.run("DELETE FROM kv WHERE scope IN ('modelAliases', 'customModels', 'mitmAlias', 'pricing')"),a.settings&&b.run("INSERT INTO settings(id, data) VALUES(1, ?) ON CONFLICT(id) DO UPDATE SET data = excluded.data",[(0,f.s)(a.settings)]),a.providerConnections||[])){let{id:a,provider:d,authType:e,name:g,email:h,priority:i,isActive:j,createdAt:k,updatedAt:l,...m}=c;b.run("INSERT OR REPLACE INTO providerConnections(id, provider, authType, name, email, priority, isActive, data, createdAt, updatedAt) VALUES(?, ?, ?, ?, ?, ?, ?, ?, ?, ?)",[a,d,e||"oauth",g||null,h||null,i||null,+(!1!==j),(0,f.s)(m),k||new Date().toISOString(),l||new Date().toISOString()])}for(let c of a.providerNodes||[]){let{id:a,type:d,name:e,createdAt:g,updatedAt:h,...i}=c;b.run("INSERT OR REPLACE INTO providerNodes(id, type, name, data, createdAt, updatedAt) VALUES(?, ?, ?, ?, ?, ?)",[a,d||null,e||null,(0,f.s)(i),g||new Date().toISOString(),h||new Date().toISOString()])}for(let c of a.proxyPools||[]){let{id:a,isActive:d,testStatus:e,createdAt:g,updatedAt:h,...i}=c;b.run("INSERT OR REPLACE INTO proxyPools(id, isActive, testStatus, data, createdAt, updatedAt) VALUES(?, ?, ?, ?, ?, ?)",[a,+(!1!==d),e||"unknown",(0,f.s)(i),g||new Date().toISOString(),h||new Date().toISOString()])}for(let c of a.apiKeys||[])b.run("INSERT OR REPLACE INTO apiKeys(id, key, name, machineId, isActive, createdAt, budgetDaily, budgetMonthly, requestsPerMinute, allowedModels, allowedConnectionIds) VALUES(?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)",[c.id,c.key,c.name||null,c.machineId||null,+(!1!==c.isActive),c.createdAt||new Date().toISOString(),Number(c.budgetDaily)||0,Number(c.budgetMonthly)||0,Number(c.requestsPerMinute)||0,(0,f.s)(c.allowedModels||[]),(0,f.s)(c.allowedConnectionIds||[])]);for(let c of a.combos||[])b.run("INSERT OR REPLACE INTO combos(id, name, kind, models, createdAt, updatedAt) VALUES(?, ?, ?, ?, ?, ?)",[c.id,c.name,c.kind||null,(0,f.s)(c.models||[]),c.createdAt||new Date().toISOString(),c.updatedAt||new Date().toISOString()]);for(let[c,d]of Object.entries(a.modelAliases||{}))b.run("INSERT OR REPLACE INTO kv(scope, key, value) VALUES('modelAliases', ?, ?)",[c,(0,f.s)(d)]);for(let c of a.customModels||[]){let a=`${c.providerAlias}|${c.id}|${c.type||"llm"}`;b.run("INSERT OR REPLACE INTO kv(scope, key, value) VALUES('customModels', ?, ?)",[a,(0,f.s)(c)])}for(let[c,d]of Object.entries(a.mitmAlias||{}))b.run("INSERT OR REPLACE INTO kv(scope, key, value) VALUES('mitmAlias', ?, ?)",[c,(0,f.s)(d||{})]);for(let[c,d]of Object.entries(a.pricing||{}))b.run("INSERT OR REPLACE INTO kv(scope, key, value) VALUES('pricing', ?, ?)",[c,(0,f.s)(d||{})])}),await aI()}},97914:(a,b,c)=>{c.d(b,{KJ:()=>l,VT:()=>n,getPricingForModel:()=>k,r4:()=>j,yF:()=>m});var d=c(36366),e=c(644);let f=(0,c(22846).U)("pricing"),g={value:null,expiresAt:0};function h(){g={value:null,expiresAt:0}}async function i(){return await f.getAll()}async function j(){let a=Date.now();if(g.value&&g.expiresAt>a)return g.value;let b=await i(),{PROVIDER_PRICING:d}=await c.e(7341).then(c.bind(c,57341)),e={};for(let[a,c]of Object.entries(d))if(e[a]={...c},b[a])for(let[c,d]of Object.entries(b[a]))e[a][c]=e[a][c]?{...e[a][c],...d}:d;for(let[a,c]of Object.entries(b))if(e[a])for(let[b,d]of Object.entries(c))e[a][b]||(e[a][b]=d);else e[a]={...c};return g={value:e,expiresAt:a+5e3},e}async function k(a,b){if(!b)return null;let d=await i();if(a&&d[a]?.[b])return d[a][b];let{getPricingForModel:e}=await c.e(7341).then(c.bind(c,57341));return e(a,b)}async function l(a){let b=await (0,d.cK)();return b.transaction(()=>{for(let[c,d]of Object.entries(a)){let a=b.get("SELECT value FROM kv WHERE scope = 'pricing' AND key = ?",[c]),f={...a&&(0,e.q)(a.value,{})||{}};for(let[a,b]of Object.entries(d))f[a]=b;b.run("INSERT INTO kv(scope, key, value) VALUES('pricing', ?, ?) ON CONFLICT(scope, key) DO UPDATE SET value = excluded.value",[c,(0,e.s)(f)])}}),h(),await i()}async function m(a,b){if(!a)return await i();let c=await (0,d.cK)();return c.transaction(()=>{if(!b)return void c.run("DELETE FROM kv WHERE scope = 'pricing' AND key = ?",[a]);let d=c.get("SELECT value FROM kv WHERE scope = 'pricing' AND key = ?",[a]),f=d&&(0,e.q)(d.value,{})||{};delete f[b],0===Object.keys(f).length?c.run("DELETE FROM kv WHERE scope = 'pricing' AND key = ?",[a]):c.run("INSERT INTO kv(scope, key, value) VALUES('pricing', ?, ?) ON CONFLICT(scope, key) DO UPDATE SET value = excluded.value",[a,(0,e.s)(f)])}),h(),await i()}async function n(){return await f.clear(),h(),{}}}};
|
|
22
|
+
data=excluded.data, updatedAt=excluded.updatedAt`,[c.id,c.isActive,c.testStatus,c.data,c.createdAt,c.updatedAt])}async function m(a={}){let b=await (0,d.getAdapter)(),c=[],e=[];void 0!==a.isActive&&(c.push("isActive = ?"),e.push(+!!a.isActive)),a.testStatus&&(c.push("testStatus = ?"),e.push(a.testStatus));let f=`SELECT * FROM proxyPools${c.length?` WHERE ${c.join(" AND ")}`:""}`,g=b.all(f,e).map(k);return g.sort((a,b)=>new Date(b.updatedAt||0)-new Date(a.updatedAt||0)),g}async function n(a){return k((await (0,d.getAdapter)()).get("SELECT * FROM proxyPools WHERE id = ?",[a]))}async function o(a){let b=await (0,d.getAdapter)(),c=new Date().toISOString(),e={id:a.id||(0,j.A)(),name:a.name,proxyUrl:a.proxyUrl,noProxy:a.noProxy||"",type:a.type||"http",isActive:void 0===a.isActive||a.isActive,strictProxy:!0===a.strictProxy,testStatus:a.testStatus||"unknown",lastTestedAt:a.lastTestedAt||null,lastError:a.lastError||null,createdAt:c,updatedAt:c};return l(b,e),e}async function p(a,b){let c=await (0,d.getAdapter)(),e=null;return c.transaction(()=>{let d=c.get("SELECT * FROM proxyPools WHERE id = ?",[a]);if(!d)return;let f={...k(d),...b,updatedAt:new Date().toISOString()};l(c,f),e=f}),e}async function q(a){let b=await (0,d.getAdapter)(),c=null;return b.transaction(()=>{let d=b.get("SELECT * FROM proxyPools WHERE id = ?",[a]);d&&(c=k(d),b.run("DELETE FROM proxyPools WHERE id = ?",[a]))}),c}var r=c(26556);let s=null,t=0;function u(){s=null,t=0}function v(a){return a?{id:a.id,name:a.name,content:a.content,enabled:1===a.enabled||!0===a.enabled,priority:Number(a.priority)||0,createdAt:a.createdAt,updatedAt:a.updatedAt}:null}async function w(){return(await (0,d.getAdapter)()).all("SELECT * FROM contextFiles ORDER BY priority ASC, createdAt ASC").map(v)}async function x(){let a=Date.now();return s&&a-t<5e3||(s=(await (0,d.getAdapter)()).all("SELECT * FROM contextFiles WHERE enabled = 1 ORDER BY priority ASC, createdAt ASC").map(v),t=a),s}async function y(a){return v((await (0,d.getAdapter)()).get("SELECT * FROM contextFiles WHERE id = ?",[a]))}async function z({name:a,content:b="",enabled:c=!0,priority:e=0}){let f=await (0,d.getAdapter)(),g=(0,j.A)(),h=new Date().toISOString();return f.run(`INSERT INTO contextFiles(id, name, content, enabled, priority, createdAt, updatedAt)
|
|
23
|
+
VALUES(?, ?, ?, ?, ?, ?, ?)`,[g,String(a||"untitled"),String(b||""),+!!c,Number(e)||0,h,h]),u(),y(g)}async function A(a,b={}){let c=await y(a);if(!c)return null;let e=await (0,d.getAdapter)(),f={name:void 0!==b.name?String(b.name):c.name,content:void 0!==b.content?String(b.content):c.content,enabled:void 0!==b.enabled?+!!b.enabled:+!!c.enabled,priority:void 0!==b.priority?Number(b.priority)||0:c.priority};return e.run("UPDATE contextFiles SET name = ?, content = ?, enabled = ?, priority = ?, updatedAt = ? WHERE id = ?",[f.name,f.content,f.enabled,f.priority,new Date().toISOString(),a]),u(),y(a)}async function B(a){return(await (0,d.getAdapter)()).run("DELETE FROM contextFiles WHERE id = ?",[a]),u(),!0}async function C(a=[]){if(!Array.isArray(a)||0===a.length)return[];let b=await (0,d.getAdapter)(),c=b.get("SELECT COALESCE(MAX(priority), -1) AS maxp FROM contextFiles"),e=(Number(c?.maxp)||-1)+1,f=[];return b.transaction(()=>{for(let c of a){let a=String(c?.name||"untitled").trim()||"untitled",d=String(c?.content||""),g=(0,j.A)(),h=new Date().toISOString();b.run(`INSERT INTO contextFiles(id, name, content, enabled, priority, createdAt, updatedAt)
|
|
24
|
+
VALUES(?, ?, ?, 0, ?, ?, ?)`,[g,a,d,e,h,h]),f.push({id:g,name:a}),e+=1}}),u(),f}var D=c(74452);function E(a){return a?{id:a.id,name:a.name,kind:a.kind,models:(0,f.q)(a.models,[]),createdAt:a.createdAt,updatedAt:a.updatedAt}:null}async function F(){return(await (0,d.getAdapter)()).all("SELECT * FROM combos ORDER BY createdAt ASC").map(E)}async function G(a){return E((await (0,d.getAdapter)()).get("SELECT * FROM combos WHERE id = ?",[a]))}async function H(a){return E((await (0,d.getAdapter)()).get("SELECT * FROM combos WHERE name = ?",[a]))}async function I(a){let b=await (0,d.getAdapter)(),c=new Date().toISOString(),e={id:(0,j.A)(),name:a.name,kind:a.kind||null,models:a.models||[],createdAt:c,updatedAt:c};return b.run("INSERT INTO combos(id, name, kind, models, createdAt, updatedAt) VALUES(?, ?, ?, ?, ?, ?)",[e.id,e.name,e.kind,(0,f.s)(e.models),e.createdAt,e.updatedAt]),e}async function J(a,b){let c=await (0,d.getAdapter)(),e=null;return c.transaction(()=>{let d=c.get("SELECT * FROM combos WHERE id = ?",[a]);if(!d)return;let g={...E(d),...b,updatedAt:new Date().toISOString()};c.run("UPDATE combos SET name = ?, kind = ?, models = ?, updatedAt = ? WHERE id = ?",[g.name,g.kind,(0,f.s)(g.models||[]),g.updatedAt,a]),e=g}),e}async function K(a){let b=(await (0,d.getAdapter)()).run("DELETE FROM combos WHERE id = ?",[a]);return(b?.changes??0)>0}var L=c(9460),M=c(97914);let N="disabledModels";async function O(){let a=(await (0,d.getAdapter)()).all("SELECT key, value FROM kv WHERE scope = ?",[N]),b={};for(let c of a)b[c.key]=(0,f.q)(c.value,[]);return b}async function P(a,b){if(!a||!Array.isArray(b))return;let c=await (0,d.getAdapter)();c.transaction(()=>{let d=c.get("SELECT value FROM kv WHERE scope = ? AND key = ?",[N,a]),e=[...new Set([...d&&(0,f.q)(d.value,[])||[],...b])];c.run("INSERT INTO kv(scope, key, value) VALUES(?, ?, ?) ON CONFLICT(scope, key) DO UPDATE SET value = excluded.value",[N,a,(0,f.s)(e)])})}async function Q(a,b){if(!a)return;let c=await (0,d.getAdapter)();c.transaction(()=>{if(!Array.isArray(b)||0===b.length)return void c.run("DELETE FROM kv WHERE scope = ? AND key = ?",[N,a]);let d=c.get("SELECT value FROM kv WHERE scope = ? AND key = ?",[N,a]),e=d&&(0,f.q)(d.value,[])||[],g=new Set(b),h=e.filter(a=>!g.has(a));0===h.length?c.run("DELETE FROM kv WHERE scope = ? AND key = ?",[N,a]):c.run("INSERT INTO kv(scope, key, value) VALUES(?, ?, ?) ON CONFLICT(scope, key) DO UPDATE SET value = excluded.value",[N,a,(0,f.s)(h)])})}var R=c(94735),S=c(77598);c(62674);global._pendingRequests||(global._pendingRequests={byModel:{},byAccount:{}}),global._lastErrorProvider||(global._lastErrorProvider={provider:"",ts:0}),global._statsEmitter||(global._statsEmitter=new R.EventEmitter,global._statsEmitter.setMaxListeners(50)),global._pendingTimers||(global._pendingTimers={}),global._recentRing||(global._recentRing={items:[],initialized:!1}),global._connectionMapCache||(global._connectionMapCache={map:{},ts:0}),global._usageWritesInFlight||(global._usageWritesInFlight=new Set);let T=global._pendingRequests,U=global._lastErrorProvider,V=global._pendingTimers,W=global._recentRing,X=global._connectionMapCache,Y=global._usageWritesInFlight,Z=global._statsEmitter;function $(a){let b=a?new Date(a):new Date;return`${b.getFullYear()}-${String(b.getMonth()+1).padStart(2,"0")}-${String(b.getDate()).padStart(2,"0")}`}function _(a,b,c){a[b]||(a[b]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0}),a[b].requests+=c.requests||1,a[b].promptTokens+=c.promptTokens||0,a[b].completionTokens+=c.completionTokens||0,a[b].cachedTokens=(a[b].cachedTokens||0)+(c.cachedTokens||0),a[b].cost+=c.cost||0,c.meta&&Object.assign(a[b],c.meta)}function aa(a){return a&&"object"==typeof a&&(a.cached_tokens||a.prompt_tokens_details?.cached_tokens||a.cache_read_input_tokens)||0}function ab(a,b,c){return`${a}|${b||"unknown"}|${c||"unknown"}`}function ac(a,b,c){return`${a||"local-no-key"}|${b||"unknown"}|${c||"unknown"}`}function ad(a){return(0,S.createHash)("sha256").update(String(a)).digest("hex").slice(0,20)}function ae(a,b){return a?b?.name||`External Key ${ad(a).slice(0,8)}`:"Local (No API Key)"}async function af(){if(Date.now()-X.ts<3e4)return X.map;try{let{getProviderConnections:a}=await Promise.resolve().then(c.bind(c,5781)),b=await a(),d={};for(let a of b)d[a.id]=a.name||a.email||a.id;X.map=d,X.ts=Date.now()}catch{}return X.map}async function ag(){if(!W.initialized){W.initialized=!0;try{W.items=(await (0,d.getAdapter)()).all("SELECT timestamp, provider, model, connectionId, apiKey, endpoint, cost, status, tokens FROM usageHistory ORDER BY id DESC LIMIT ?",[50]).reverse().map(a=>({timestamp:a.timestamp,provider:a.provider,model:a.model,connectionId:a.connectionId,apiKey:a.apiKey,endpoint:a.endpoint,cost:a.cost,status:a.status,tokens:(0,f.q)(a.tokens,{})}))}catch{}}}async function ah(a,b,d){if(!d||!a||!b)return 0;try{let{getPricingForModel:e}=await Promise.resolve().then(c.bind(c,97914)),f=await e(a,b);if(!f)return 0;let g=0,h=d.prompt_tokens||d.input_tokens||0,i=aa(d),j=void 0!==d.cached_tokens||d.prompt_tokens_details?.cached_tokens!==void 0?Math.max(0,h-i):h;if(g+=j*(f.input/1e6),i>0){let a=f.cached||f.input;g+=a/1e6*i}let k=d.completion_tokens||d.output_tokens||0;g+=k*(f.output/1e6);let l=d.reasoning_tokens||0;if(l>0){let a=f.reasoning||f.output;g+=a/1e6*l}let m=d.cache_creation_input_tokens||0;if(m>0){let a=f.cache_creation||f.input;g+=a/1e6*m}return g}catch(a){return console.error("Error calculating cost:",a),0}}function ai(a,b=20){let c=new Set;return a.filter(a=>{if(0===a.promptTokens&&0===a.completionTokens)return!1;let b=JSON.stringify([a.timestamp,a.model,a.provider,a.promptTokens,a.completionTokens]);return!c.has(b)&&(c.add(b),!0)}).slice(0,b)}function aj(a,b,c){T.byModel[a]||(T.byModel[a]=0),T.byModel[a]=Math.max(0,T.byModel[a]+c),0===T.byModel[a]&&delete T.byModel[a],b&&(T.byAccount[b]||(T.byAccount[b]={}),T.byAccount[b][a]||(T.byAccount[b][a]=0),T.byAccount[b][a]=Math.max(0,T.byAccount[b][a]+c),0===T.byAccount[b][a]&&(delete T.byAccount[b][a],0===Object.keys(T.byAccount[b]).length&&delete T.byAccount[b]))}function ak(a,b,c,d,e=!1){let f=b?`${a} (${b})`:a,g=`${c}|${f}`;if(aj(f,c,d?1:-1),d){let a=function(a,b,c){let d=V[a];if(Array.isArray(d))return d;d&&(clearTimeout(d),aj(b,c,-1));let e=[];return V[a]=e,e}(g,f,c),b=setTimeout(()=>{let a=V[g];if(Array.isArray(a)){let c=a.indexOf(b);c>=0&&a.splice(c,1),0===a.length&&delete V[g]}aj(f,c,-1),Z.emit("pending")},6e4);b.unref?.(),a.push(b)}else{let a=V[g];if(Array.isArray(a)){let b=a.shift();b&&clearTimeout(b),0===a.length&&delete V[g]}else a&&(clearTimeout(a),delete V[g])}!d&&e&&b&&(U.provider=b.toLowerCase(),U.ts=Date.now()),Z.emit("pending")}async function al(){let a=[],b=await af();for(let[c,d]of Object.entries(T.byAccount))for(let[e,f]of Object.entries(d))if(f>0){let d=b[c]||`Account ${c.slice(0,8)}...`,g=e.match(/^(.*) \((.*)\)$/);a.push({model:g?g[1]:e,provider:g?g[2]:"unknown",account:d,count:f})}return await ag(),{activeRequests:a,recentRequests:ai([...W.items].sort((a,b)=>new Date(b.timestamp)-new Date(a.timestamp)).map(a=>{let b=a.tokens||{};return{timestamp:a.timestamp,model:a.model,provider:a.provider||"",promptTokens:b.prompt_tokens||b.input_tokens||0,completionTokens:b.completion_tokens||b.output_tokens||0,status:a.status||"ok"}})),errorProvider:Date.now()-U.ts<1e4?U.provider:""}}async function am(a){try{let b=await (0,d.getAdapter)();a.timestamp||(a.timestamp=new Date().toISOString()),a.cost=await ah(a.provider,a.model,a.tokens);let c=a.tokens||{},e=c.prompt_tokens||c.input_tokens||0,g=c.completion_tokens||c.output_tokens||0;b.transaction(()=>{b.run("INSERT INTO usageHistory(timestamp, provider, model, connectionId, apiKey, endpoint, promptTokens, completionTokens, cost, status, tokens, meta) VALUES(?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)",[a.timestamp,a.provider||null,a.model||null,a.connectionId||null,a.apiKey||null,a.endpoint||null,e,g,a.cost||0,a.status||"ok",(0,f.s)(c),(0,f.s)(a.latency&&"object"==typeof a.latency?{latency:{ttft:a.latency.ttft||0,total:a.latency.total||0}}:{})]);let d=$(a.timestamp),h=b.get("SELECT data FROM usageDaily WHERE dateKey = ?",[d]),i=h?(0,f.q)(h.data,{}):{requests:0,promptTokens:0,completionTokens:0,cost:0,byProvider:{},byModel:{},byAccount:{},byApiKey:{},byEndpoint:{}};!function(a,b){let c=b.tokens?.prompt_tokens||b.tokens?.input_tokens||0,d=b.tokens?.completion_tokens||b.tokens?.output_tokens||0,e=aa(b.tokens),f=b.cost||0,g={promptTokens:c,completionTokens:d,cachedTokens:e,cost:f};a.requests=(a.requests||0)+1,a.promptTokens=(a.promptTokens||0)+c,a.completionTokens=(a.completionTokens||0)+d,a.cachedTokens=(a.cachedTokens||0)+e,a.cost=(a.cost||0)+f,a.byProvider||={},a.byModel||={},a.byAccount||={},a.byApiKey||={},a.byEndpoint||={},b.provider&&_(a.byProvider,b.provider,g);let h=b.provider?`${b.model}|${b.provider}`:b.model;if(_(a.byModel,h,{...g,meta:{rawModel:b.model,provider:b.provider}}),b.connectionId){let c=ab(b.connectionId,b.model,b.provider);_(a.byAccount,c,{...g,meta:{connectionId:b.connectionId,rawModel:b.model,provider:b.provider}})}let i=ac(b.apiKey&&"string"==typeof b.apiKey?b.apiKey:null,b.model,b.provider);_(a.byApiKey,i,{...g,meta:{rawModel:b.model,provider:b.provider,apiKey:b.apiKey||null}});let j=b.endpoint||"Unknown",k=`${j}|${b.model}|${b.provider||"unknown"}`;_(a.byEndpoint,k,{...g,meta:{endpoint:j,rawModel:b.model,provider:b.provider}})}(i,a),b.run("INSERT INTO usageDaily(dateKey, data) VALUES(?, ?) ON CONFLICT(dateKey) DO UPDATE SET data = excluded.data",[d,(0,f.s)(i)]);let j=b.get("SELECT value FROM _meta WHERE key = 'totalRequestsLifetime'"),k=(j?parseInt(j.value,10):0)+1;b.run("INSERT INTO _meta(key, value) VALUES('totalRequestsLifetime', ?) ON CONFLICT(key) DO UPDATE SET value = excluded.value",[String(k)])}),W.items.push(a),W.items.length>50&&(W.items=W.items.slice(-50)),Z.emit("update")}catch(a){console.error("Failed to save usage stats:",a)}}function an(a){let b=am(a);return Y.add(b),b.finally(()=>Y.delete(b)),b}function ao(a,b){if(null==b)return a.all("SELECT dateKey, data FROM usageDaily");let c=new Date,d=new Date(c.getFullYear(),c.getMonth(),c.getDate()-b+1),e=`${d.getFullYear()}-${String(d.getMonth()+1).padStart(2,"0")}-${String(d.getDate()).padStart(2,"0")}`;return a.all("SELECT dateKey, data FROM usageDaily WHERE dateKey >= ?",[e])}async function ap(a="all"){let b=await (0,d.getAdapter)(),[{getProviderConnections:e},{getApiKeys:g},{getProviderNodes:h}]=await Promise.all([Promise.resolve().then(c.bind(c,5781)),Promise.resolve().then(c.bind(c,74452)),Promise.resolve().then(c.bind(c,1129))]),i=[];try{i=await e()}catch{}let j={};for(let a of i)j[a.id]=a.name||a.email||a.id;let k={};try{for(let a of(await h()))a.id&&a.name&&(k[a.id]=a.name)}catch{}let l=[];try{l=await g(!0)}catch{}let m={};for(let a of l)m[a.key]={name:a.name,id:a.id,createdAt:a.createdAt};let n={totalRequests:0,totalPromptTokens:0,totalCompletionTokens:0,totalCachedTokens:0,totalCost:0,byProvider:{},byModel:{},byAccount:{},byApiKey:{},byEndpoint:{},last10Minutes:[],pending:T,activeRequests:[],recentRequests:ai(b.all("SELECT timestamp, provider, model, tokens, status FROM usageHistory ORDER BY id DESC LIMIT 100").map(a=>{let b=(0,f.q)(a.tokens,{})||{};return{timestamp:a.timestamp,model:a.model,provider:a.provider||"",promptTokens:b.prompt_tokens||b.input_tokens||0,completionTokens:b.completion_tokens||b.output_tokens||0,status:a.status||"ok"}})),errorProvider:Date.now()-U.ts<1e4?U.provider:""};for(let[a,b]of Object.entries(T.byAccount))for(let[c,d]of Object.entries(b))if(d>0){let b=j[a]||`Account ${a.slice(0,8)}...`,e=c.match(/^(.*) \((.*)\)$/);n.activeRequests.push({model:e?e[1]:c,provider:e?e[2]:"unknown",account:b,count:d})}let o=new Date,p=new Date(6e4*Math.floor(o.getTime()/6e4)),q=new Date(p.getTime()-54e4),r={};for(let a=0;a<10;a++){let b=p.getTime()-(9-a)*6e4;r[b]={requests:0,promptTokens:0,completionTokens:0,cost:0},n.last10Minutes.push(r[b])}for(let a of b.all("SELECT timestamp, promptTokens, completionTokens, cost FROM usageHistory WHERE timestamp >= ? AND timestamp <= ?",[q.toISOString(),o.toISOString()])){let b=6e4*Math.floor(new Date(a.timestamp).getTime()/6e4);r[b]&&(r[b].requests++,r[b].promptTokens+=a.promptTokens||0,r[b].completionTokens+=a.completionTokens||0,r[b].cost+=a.cost||0)}if("24h"!==a&&"today"!==a){let c={"7d":7,"30d":30,"60d":60}[a]||null,d=ao(b,c),e=c?Date.now()-864e5*c:0,g=b.all("SELECT timestamp, provider, model, connectionId, apiKey, endpoint, promptTokens, completionTokens, cost, tokens FROM usageHistory WHERE timestamp >= ?",[new Date(e).toISOString()]),h={};for(let a of g){let b=$(a.timestamp);(h[b]||=[]).push(a)}for(let a of d){let b=a.dateKey,c=(0,f.q)(a.data,{});for(let[a,b]of(n.totalPromptTokens+=c.promptTokens||0,n.totalCompletionTokens+=c.completionTokens||0,n.totalCachedTokens+=c.cachedTokens||0,n.totalCost+=c.cost||0,Object.entries(c.byProvider||{})))n.byProvider[a]||(n.byProvider[a]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0}),n.byProvider[a].requests+=b.requests||0,n.byProvider[a].promptTokens+=b.promptTokens||0,n.byProvider[a].completionTokens+=b.completionTokens||0,n.byProvider[a].cachedTokens=(n.byProvider[a].cachedTokens||0)+(b.cachedTokens||0),n.byProvider[a].cost+=b.cost||0;for(let[a,d]of Object.entries(c.byModel||{})){let c=d.rawModel||a.split("|")[0],e=d.provider||a.split("|")[1]||"",f=e?`${c} (${e})`:c,g=k[e]||e;n.byModel[f]||(n.byModel[f]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0,rawModel:c,provider:g,lastUsed:b}),n.byModel[f].requests+=d.requests||0,n.byModel[f].promptTokens+=d.promptTokens||0,n.byModel[f].completionTokens+=d.completionTokens||0,n.byModel[f].cachedTokens+=d.cachedTokens||0,n.byModel[f].cost+=d.cost||0,b>(n.byModel[f].lastUsed||"")&&(n.byModel[f].lastUsed=b)}let d=c.byAccount||{},e=Object.values(d).some(a=>!a?.connectionId),g=h[b]||[];for(let[a,h]of(e&&g.length===(c.requests||0)&&(d=function(a){let b={};for(let c of a){if(!c.connectionId)continue;let a=(0,f.q)(c.tokens,{})||{},d=c.promptTokens||a.prompt_tokens||a.input_tokens||0,e=c.completionTokens||a.completion_tokens||a.output_tokens||0;_(b,ab(c.connectionId,c.model,c.provider),{requests:1,promptTokens:d,completionTokens:e,cachedTokens:aa(a),cost:c.cost||0,meta:{connectionId:c.connectionId,rawModel:c.model||"",provider:c.provider||""}})}return b}(g)),Object.entries(d))){let c=h.connectionId||a,d=j[c]||`Account ${c.slice(0,8)}...`,e=h.rawModel||"",f=h.provider||"",g=k[f]||f,i=ab(c,e,f);n.byAccount[i]||(n.byAccount[i]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0,rawModel:e,provider:g,providerId:f,connectionId:c,accountName:d,lastUsed:b}),n.byAccount[i].requests+=h.requests||0,n.byAccount[i].promptTokens+=h.promptTokens||0,n.byAccount[i].completionTokens+=h.completionTokens||0,n.byAccount[i].cachedTokens+=h.cachedTokens||0,n.byAccount[i].cost+=h.cost||0,b>(n.byAccount[i].lastUsed||"")&&(n.byAccount[i].lastUsed=b)}for(let[a,d]of Object.entries(c.byApiKey||{})){let c=d.rawModel||"",e=d.provider||"",f=k[e]||e,g=d.apiKey,h=g?m[g]:null,i=ae(g,h),j=g||"local-no-key";n.byApiKey[a]||(n.byApiKey[a]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0,rawModel:c,provider:f,apiKey:g,keyName:i,apiKeyKey:j,lastUsed:b}),n.byApiKey[a].requests+=d.requests||0,n.byApiKey[a].promptTokens+=d.promptTokens||0,n.byApiKey[a].completionTokens+=d.completionTokens||0,n.byApiKey[a].cachedTokens+=d.cachedTokens||0,n.byApiKey[a].cost+=d.cost||0,b>(n.byApiKey[a].lastUsed||"")&&(n.byApiKey[a].lastUsed=b)}for(let[a,d]of Object.entries(c.byEndpoint||{})){let c=d.endpoint||a.split("|")[0]||"Unknown",e=d.rawModel||"",f=d.provider||"",g=k[f]||f;n.byEndpoint[a]||(n.byEndpoint[a]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0,endpoint:c,rawModel:e,provider:g,lastUsed:b}),n.byEndpoint[a].requests+=d.requests||0,n.byEndpoint[a].promptTokens+=d.promptTokens||0,n.byEndpoint[a].completionTokens+=d.completionTokens||0,n.byEndpoint[a].cachedTokens+=d.cachedTokens||0,n.byEndpoint[a].cost+=d.cost||0,b>(n.byEndpoint[a].lastUsed||"")&&(n.byEndpoint[a].lastUsed=b)}}for(let a of g){let b=a.timestamp,c=a.provider?`${a.model} (${a.provider})`:a.model;if(n.byModel[c]&&new Date(b)>new Date(n.byModel[c].lastUsed)&&(n.byModel[c].lastUsed=b),a.connectionId){let c=ab(a.connectionId,a.model,a.provider);n.byAccount[c]&&new Date(b)>new Date(n.byAccount[c].lastUsed)&&(n.byAccount[c].lastUsed=b)}let d=ac(a.apiKey&&"string"==typeof a.apiKey?a.apiKey:null,a.model,a.provider);n.byApiKey[d]&&new Date(b)>new Date(n.byApiKey[d].lastUsed)&&(n.byApiKey[d].lastUsed=b);let e=a.endpoint||"Unknown",f=`${e}|${a.model}|${a.provider||"unknown"}`;n.byEndpoint[f]&&new Date(b)>new Date(n.byEndpoint[f].lastUsed)&&(n.byEndpoint[f].lastUsed=b)}}else{let c;if("today"===a){let a=new Date;a.setHours(0,0,0,0),c=a.toISOString()}else c=new Date(Date.now()-864e5).toISOString();for(let a of b.all("SELECT timestamp, provider, model, connectionId, apiKey, endpoint, promptTokens, completionTokens, cost, tokens FROM usageHistory WHERE timestamp >= ?",[c])){let b=(0,f.q)(a.tokens,{})||{},c=b.prompt_tokens||b.input_tokens||0,d=b.completion_tokens||b.output_tokens||0,e=aa(b),g=a.cost||0,h=k[a.provider]||a.provider;n.totalPromptTokens+=c,n.totalCompletionTokens+=d,n.totalCachedTokens+=e,n.totalCost+=g,n.byProvider[a.provider]||(n.byProvider[a.provider]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0}),n.byProvider[a.provider].requests++,n.byProvider[a.provider].promptTokens+=c,n.byProvider[a.provider].completionTokens+=d,n.byProvider[a.provider].cachedTokens=(n.byProvider[a.provider].cachedTokens||0)+e,n.byProvider[a.provider].cost+=g;let i=a.provider?`${a.model} (${a.provider})`:a.model;if(n.byModel[i]||(n.byModel[i]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0,rawModel:a.model,provider:h,lastUsed:a.timestamp}),n.byModel[i].requests++,n.byModel[i].promptTokens+=c,n.byModel[i].completionTokens+=d,n.byModel[i].cachedTokens+=e,n.byModel[i].cost+=g,new Date(a.timestamp)>new Date(n.byModel[i].lastUsed)&&(n.byModel[i].lastUsed=a.timestamp),a.connectionId){let b=j[a.connectionId]||`Account ${a.connectionId.slice(0,8)}...`,f=ab(a.connectionId,a.model,a.provider);n.byAccount[f]||(n.byAccount[f]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0,rawModel:a.model,provider:h,providerId:a.provider,connectionId:a.connectionId,accountName:b,lastUsed:a.timestamp}),n.byAccount[f].requests++,n.byAccount[f].promptTokens+=c,n.byAccount[f].completionTokens+=d,n.byAccount[f].cachedTokens+=e,n.byAccount[f].cost+=g,new Date(a.timestamp)>new Date(n.byAccount[f].lastUsed)&&(n.byAccount[f].lastUsed=a.timestamp)}if(a.apiKey&&"string"==typeof a.apiKey){let b=m[a.apiKey],f=ae(a.apiKey,b),i=ac(a.apiKey,a.model,a.provider);n.byApiKey[i]||(n.byApiKey[i]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0,rawModel:a.model,provider:h,apiKey:a.apiKey,keyName:f,apiKeyKey:a.apiKey,lastUsed:a.timestamp});let j=n.byApiKey[i];j.requests++,j.promptTokens+=c,j.completionTokens+=d,j.cachedTokens+=e,j.cost+=g,new Date(a.timestamp)>new Date(j.lastUsed)&&(j.lastUsed=a.timestamp)}else{let b=ac(null,a.model,a.provider);n.byApiKey[b]||(n.byApiKey[b]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0,rawModel:a.model,provider:h,apiKey:null,keyName:"Local (No API Key)",apiKeyKey:"local-no-key",lastUsed:a.timestamp});let f=n.byApiKey[b];f.requests++,f.promptTokens+=c,f.completionTokens+=d,f.cachedTokens+=e,f.cost+=g,new Date(a.timestamp)>new Date(f.lastUsed)&&(f.lastUsed=a.timestamp)}let l=a.endpoint||"Unknown",o=`${l}|${a.model}|${a.provider||"unknown"}`;n.byEndpoint[o]||(n.byEndpoint[o]={requests:0,promptTokens:0,completionTokens:0,cachedTokens:0,cost:0,endpoint:l,rawModel:a.model,provider:h,lastUsed:a.timestamp});let p=n.byEndpoint[o];p.requests++,p.promptTokens+=c,p.completionTokens+=d,p.cachedTokens+=e,p.cost+=g,new Date(a.timestamp)>new Date(p.lastUsed)&&(p.lastUsed=a.timestamp)}}return n.totalRequests=Object.values(n.byProvider).reduce((a,b)=>a+(b.requests||0),0),n.byApiKey=function(a,b){let c={};for(let[d,e]of Object.entries(a||{})){let a="string"==typeof e.apiKey&&e.apiKey?e.apiKey:null,f=a?b[a]:null,g=a?f?.id||`external-${ad(a)}`:"local-no-key",h={...e,apiKeyKey:g};delete h.apiKey,c[`bucket-${ad(d)}`]=h}return c}(n.byApiKey,m),n}async function aq(a="7d"){let b=await (0,d.getAdapter)(),c=Date.now();if("today"===a){let a=new Date;a.setHours(0,0,0,0);let c=a.getTime(),d=c+864e5,e=Array.from({length:24},(a,b)=>({label:new Date(c+36e5*b).toLocaleTimeString("en-US",{hour:"2-digit",minute:"2-digit",hour12:!1}),tokens:0,cost:0}));for(let a of b.all("SELECT timestamp, promptTokens, completionTokens, cost FROM usageHistory WHERE timestamp >= ?",[new Date(c).toISOString()])){let b=new Date(a.timestamp).getTime();if(b<c||b>=d)continue;let f=Math.floor((b-c)/36e5);f>=0&&f<24&&(e[f].tokens+=(a.promptTokens||0)+(a.completionTokens||0),e[f].cost+=a.cost||0)}return e}if("24h"===a){let a=c-864e5,d=Array.from({length:24},(b,c)=>({label:new Date(a+36e5*c).toLocaleTimeString("en-US",{hour:"2-digit",minute:"2-digit",hour12:!1}),tokens:0,cost:0}));for(let e of b.all("SELECT timestamp, promptTokens, completionTokens, cost FROM usageHistory WHERE timestamp >= ?",[new Date(a).toISOString()])){let b=new Date(e.timestamp).getTime();if(b<a||b>c)continue;let f=Math.min(Math.floor((b-a)/36e5),23);d[f].tokens+=(e.promptTokens||0)+(e.completionTokens||0),d[f].cost+=e.cost||0}return d}let e="7d"===a?7:"30d"===a?30:60,g=new Date,h=ao(b,e),i={};for(let a of h)i[a.dateKey]=(0,f.q)(a.data,{});return Array.from({length:e},(a,b)=>{let c=new Date(g);c.setDate(c.getDate()-(e-1-b));let d=i[`${c.getFullYear()}-${String(c.getMonth()+1).padStart(2,"0")}-${String(c.getDate()).padStart(2,"0")}`];return{label:c.toLocaleDateString("en-US",{month:"short",day:"numeric"}),tokens:d?(d.promptTokens||0)+(d.completionTokens||0):0,cost:d&&d.cost||0}})}async function ar(a=3e5,b=2){let c=new Map;try{let e=await (0,d.getAdapter)(),g=new Date(Date.now()-a).toISOString(),h=e.all("SELECT provider, connectionId, meta FROM usageHistory WHERE timestamp >= ? AND status = 'ok'",[g]),i=new Map;for(let a of h){if(!a.provider||!a.connectionId)continue;let b=(0,f.q)(a.meta,{}),c=b?.latency?.total;if("number"!=typeof c||c<=0)continue;let d=`${a.provider}|${a.connectionId}`,e=i.get(d)||{total:0,count:0};e.total+=c,e.count+=1,i.set(d,e)}for(let[a,d]of i.entries())d.count>=b&&c.set(a,{avgMs:Math.round(d.total/d.count),samples:d.count})}catch(a){console.error("[usageRepo] getLatencyStats failed:",a.message)}return c}async function as(){}async function at(a=200){try{let b=(await (0,d.getAdapter)()).all("SELECT timestamp, provider, model, connectionId, promptTokens, completionTokens, status, tokens FROM usageHistory ORDER BY id DESC LIMIT ?",[a]);if(!b.length)return[];let e={};try{let{getProviderConnections:a}=await Promise.resolve().then(c.bind(c,5781));for(let b of(await a()))e[b.id]=b.name||b.email||""}catch{}return b.map(a=>{let b=function(a=new Date){let b=a=>String(a).padStart(2,"0");return`${b(a.getDate())}-${b(a.getMonth()+1)}-${a.getFullYear()} ${b(a.getHours())}:${b(a.getMinutes())}:${b(a.getSeconds())}`}(new Date(a.timestamp)),c=a.provider?.toUpperCase()||"-",d=a.model||"-",g=e[a.connectionId]||(a.connectionId?a.connectionId.slice(0,8):"-"),h=a.tokens?(0,f.q)(a.tokens,{}):{},i=a.promptTokens??h.prompt_tokens??"-",j=a.completionTokens??h.completion_tokens??"-";return`${b} | ${d} | ${c} | ${g} | ${i} | ${j} | ${a.status||"-"}`})}catch(a){return console.error("[usageRepo] getRecentLogs failed:",a.message),[]}}let au=null,av=0;async function aw(){if(au&&Date.now()-av<5e3)return au;try{let{getSettings:a}=await Promise.resolve().then(c.bind(c,42655)),b=await a(),d="false"!==process.env.OBSERVABILITY_ENABLED;au={enabled:"boolean"==typeof b.enableObservability?b.enableObservability:d,maxRecords:b.observabilityMaxRecords||parseInt(process.env.OBSERVABILITY_MAX_RECORDS||String(200),10),batchSize:b.observabilityBatchSize||parseInt(process.env.OBSERVABILITY_BATCH_SIZE||String(20),10),flushIntervalMs:b.observabilityFlushIntervalMs||parseInt(process.env.OBSERVABILITY_FLUSH_INTERVAL_MS||String(5e3),10),maxJsonSize:1024*(b.observabilityMaxJsonSize||parseInt(process.env.OBSERVABILITY_MAX_JSON_SIZE||"5",10))}}catch{au={enabled:!1,maxRecords:200,batchSize:20,flushIntervalMs:5e3,maxJsonSize:5120}}return av=Date.now(),au}let ax=[],ay=null,az=!1,aA=!1;function aB(a){let b=new WeakSet;return JSON.stringify(a??{},(a,c)=>{if("bigint"==typeof c)return c.toString();if(c&&"object"==typeof c){if(b.has(c))return"[Circular]";b.add(c)}return c})}function aC(a){return Math.min(1e3,Math.max(100,4*a))}async function aD(){if(az)return!1;if(0===ax.length)return!0;az=!0;let a=null,b=[],c=!1;try{a=await aw(),b=ax.splice(0,Math.max(1,a.batchSize));let e=await (0,d.getAdapter)();e.transaction(()=>{for(let a of b)e.run("INSERT INTO requestDetails(id, timestamp, provider, model, connectionId, status, data) VALUES(?, ?, ?, ?, ?, ?, ?) ON CONFLICT(id) DO UPDATE SET timestamp = excluded.timestamp, provider = excluded.provider, model = excluded.model, connectionId = excluded.connectionId, status = excluded.status, data = excluded.data",[a.id,a.timestamp,a.provider,a.model,a.connectionId,a.status,(0,f.s)(a)]);let c=e.get("SELECT COUNT(*) as c FROM requestDetails");c&&c.c>a.maxRecords&&e.run("DELETE FROM requestDetails WHERE id IN (SELECT id FROM requestDetails ORDER BY timestamp ASC LIMIT ?)",[c.c-a.maxRecords])}),c=!0}catch(c){if(b.length>0){ax=[...b,...ax];let c=aC(a?.batchSize||20);ax.length>c&&(ax.splice(0,ax.length-c),aA||(aA=!0,console.warn(`[requestDetailsRepo] Buffer limit reached (${c}); dropping oldest observability records`)))}console.error("[requestDetailsRepo] Batch write failed:",c)}finally{az=!1,0===ax.length?aA=!1:ay||(ay=setTimeout(()=>{ay=null,aD().catch(()=>{})},c?0:Math.max(250,Math.min(a?.flushIntervalMs||5e3,5e3))),ay.unref?.())}return c}async function aE(a){let b=await aw();if(b.enabled){let c;c=aC(b.batchSize),ax.length>=c&&(ax.splice(0,ax.length-c+1),aA||(aA=!0,console.warn(`[requestDetailsRepo] Buffer limit reached (${c}); dropping oldest observability records`))),ax.push(function(a,b=5120){var c,d;let e,f,g,h=(c=a?.provider,Math.max(1024,Math.min(Number.isFinite(b)?b:5120,"kiro"===c?16384:65536))),i=a=>{try{let b=aB(a);if(b.length>h)return{_truncated:!0,_originalSize:b.length,_preview:b.substring(0,200)};return JSON.parse(b)}catch(a){return{_truncated:!0,_serializationError:a.message}}},j=a?.request&&"object"==typeof a.request?{...a.request,headers:function(a){if(!a||"object"!=typeof a)return{};let b=["authorization","x-api-key","cookie","token","api-key"],c={...a};for(let a of Object.keys(c))b.some(b=>a.toLowerCase().includes(b))&&delete c[a];return c}(a.request.headers)}:a?.request;return{id:a?.id||(d=a?.model,e=new Date().toISOString(),f=Math.random().toString(36).substring(2,8),g=d?d.replace(/[^a-zA-Z0-9-]/g,"-"):"unknown",`${e}-${f}-${g}`),provider:a?.provider||null,model:a?.model||null,connectionId:a?.connectionId||null,timestamp:a?.timestamp||new Date().toISOString(),status:a?.status||null,latency:i(a?.latency),tokens:i(a?.tokens),request:i(j),providerRequest:i(a?.providerRequest),providerResponse:i(a?.providerResponse),response:(a=>{let b=i(a);if(!b?._truncated||!Array.isArray(a?.tool_calls)||0===a.tool_calls.length)return b;let c=a.tool_calls.slice(0,8),d=Math.min(512,Math.max(64,Math.floor(h/Math.max(2*c.length,1))));return{...b,type:a.type,finish_reason:a.finish_reason,tool_calls:c.map(a=>{let b="string"==typeof a?.function?.arguments?a.function.arguments:aB(a?.function?.arguments),c=b.length>d;return{id:"string"==typeof a?.id?a.id.slice(0,256):null,type:"function",function:{name:"string"==typeof a?.function?.name?a.function.name.slice(0,256):"unknown",arguments:c?b.slice(0,d):b,...c?{arguments_truncated:!0,original_arguments_size:b.length}:{}}}}),...a.tool_calls.length>c.length?{tool_calls_truncated:!0,original_tool_call_count:a.tool_calls.length}:{}}})(a?.response)}}(a,b.maxJsonSize)),ax.length>=b.batchSize?(ay&&(clearTimeout(ay),ay=null),aD().catch(a=>console.error("[requestDetailsRepo] flush err:",a))):ay||(ay=setTimeout(()=>{ay=null,aD().catch(()=>{})},b.flushIntervalMs))}}async function aF(a={}){let b=await (0,d.getAdapter)(),c=[],e=[];a.provider&&(c.push("provider = ?"),e.push(a.provider)),a.model&&(c.push("model = ?"),e.push(a.model)),a.connectionId&&(c.push("connectionId = ?"),e.push(a.connectionId)),a.status&&(c.push("status = ?"),e.push(a.status)),a.startDate&&(c.push("timestamp >= ?"),e.push(new Date(a.startDate).toISOString())),a.endDate&&(c.push("timestamp <= ?"),e.push(new Date(a.endDate).toISOString()));let g=c.length?`WHERE ${c.join(" AND ")}`:"",h=b.get(`SELECT COUNT(*) as c FROM requestDetails ${g}`,e),i=h?h.c:0,j=Number.isFinite(Number(a.page))?Math.max(1,Math.trunc(Number(a.page))):1,k=Number.isFinite(Number(a.pageSize))?Math.max(1,Math.trunc(Number(a.pageSize))):50,l=Math.max(1,Math.ceil(i/k)),m=Math.min(j,l);return{details:b.all(`SELECT data FROM requestDetails ${g} ORDER BY timestamp DESC LIMIT ? OFFSET ?`,[...e,k,(m-1)*k]).map(a=>(0,f.q)(a.data,{})),pagination:{page:m,pageSize:k,totalItems:i,totalPages:l,hasNext:m<l,hasPrev:m>1}}}let aG=new Set(["usageHistory","requestDetails","quotaCache"]),aH=new Set(["_meta"]);async function aI(){let a=await (0,d.getAdapter)(),{exportSettings:b}=await Promise.resolve().then(c.bind(c,42655)),g=Object.keys(e.CG).filter(a=>!aG.has(a)),h={settings:await b(),providerConnections:a.all("SELECT * FROM providerConnections").map(a=>({...(0,f.q)(a.data,{}),id:a.id,provider:a.provider,authType:a.authType,name:a.name,email:a.email,priority:a.priority,isActive:1===a.isActive,createdAt:a.createdAt,updatedAt:a.updatedAt})),providerNodes:a.all("SELECT * FROM providerNodes").map(a=>({...(0,f.q)(a.data,{}),id:a.id,type:a.type,name:a.name,createdAt:a.createdAt,updatedAt:a.updatedAt})),proxyPools:a.all("SELECT * FROM proxyPools").map(a=>({...(0,f.q)(a.data,{}),id:a.id,isActive:1===a.isActive,testStatus:a.testStatus,createdAt:a.createdAt,updatedAt:a.updatedAt})),apiKeys:a.all("SELECT * FROM apiKeys").map(a=>({id:a.id,key:a.key,name:a.name,machineId:a.machineId,isActive:1===a.isActive,createdAt:a.createdAt,budgetDaily:a.budgetDaily||0,budgetMonthly:a.budgetMonthly||0,requestsPerMinute:a.requestsPerMinute||0,allowedModels:(0,f.q)(a.allowedModels,[]),allowedConnectionIds:(0,f.q)(a.allowedConnectionIds,[])})),combos:a.all("SELECT * FROM combos").map(a=>({id:a.id,name:a.name,kind:a.kind,models:(0,f.q)(a.models,[]),createdAt:a.createdAt,updatedAt:a.updatedAt})),modelAliases:{},customModels:[],mitmAlias:{},pricing:{},tables:Object.fromEntries(g.map(b=>[b,a.all(`SELECT * FROM "${b}"`)])),excludedTables:[...aG]};for(let b of a.all("SELECT key, value FROM kv WHERE scope = 'modelAliases'"))h.modelAliases[b.key]=(0,f.q)(b.value);for(let b of a.all("SELECT key, value FROM kv WHERE scope = 'customModels'"))h.customModels.push((0,f.q)(b.value));for(let b of a.all("SELECT key, value FROM kv WHERE scope = 'mitmAlias'"))h.mitmAlias[b.key]=(0,f.q)(b.value);for(let b of a.all("SELECT key, value FROM kv WHERE scope = 'pricing'"))h.pricing[b.key]=(0,f.q)(b.value);return h}async function aJ(a){if(!a||"object"!=typeof a||Array.isArray(a))throw Error("Invalid database payload");let b=await (0,d.getAdapter)();return b.transaction(()=>{if(a.tables&&"object"==typeof a.tables&&!Array.isArray(a.tables)){for(let a of Object.keys(e.CG).reverse())!aG.has(a)&&(aH.has(a)||b.run(`DELETE FROM "${a}"`));for(let[c,d]of Object.entries(a.tables))if(e.CG[c]&&Array.isArray(d)&&!aH.has(c))for(let a of d){let d=Object.keys(a).filter(a=>e.CG[c].columns[a]);0!==d.length&&b.run(`INSERT INTO "${c}" (${d.map(a=>`"${a}"`).join(", ")}) VALUES (${d.map(()=>"?").join(", ")})`,d.map(b=>a[b]))}return}for(let c of(b.run("DELETE FROM settings"),b.run("DELETE FROM providerConnections"),b.run("DELETE FROM providerNodes"),b.run("DELETE FROM proxyPools"),b.run("DELETE FROM apiKeys"),b.run("DELETE FROM combos"),b.run("DELETE FROM kv WHERE scope IN ('modelAliases', 'customModels', 'mitmAlias', 'pricing')"),a.settings&&b.run("INSERT INTO settings(id, data) VALUES(1, ?) ON CONFLICT(id) DO UPDATE SET data = excluded.data",[(0,f.s)(a.settings)]),a.providerConnections||[])){let{id:a,provider:d,authType:e,name:g,email:h,priority:i,isActive:j,createdAt:k,updatedAt:l,...m}=c;b.run("INSERT OR REPLACE INTO providerConnections(id, provider, authType, name, email, priority, isActive, data, createdAt, updatedAt) VALUES(?, ?, ?, ?, ?, ?, ?, ?, ?, ?)",[a,d,e||"oauth",g||null,h||null,i||null,+(!1!==j),(0,f.s)(m),k||new Date().toISOString(),l||new Date().toISOString()])}for(let c of a.providerNodes||[]){let{id:a,type:d,name:e,createdAt:g,updatedAt:h,...i}=c;b.run("INSERT OR REPLACE INTO providerNodes(id, type, name, data, createdAt, updatedAt) VALUES(?, ?, ?, ?, ?, ?)",[a,d||null,e||null,(0,f.s)(i),g||new Date().toISOString(),h||new Date().toISOString()])}for(let c of a.proxyPools||[]){let{id:a,isActive:d,testStatus:e,createdAt:g,updatedAt:h,...i}=c;b.run("INSERT OR REPLACE INTO proxyPools(id, isActive, testStatus, data, createdAt, updatedAt) VALUES(?, ?, ?, ?, ?, ?)",[a,+(!1!==d),e||"unknown",(0,f.s)(i),g||new Date().toISOString(),h||new Date().toISOString()])}for(let c of a.apiKeys||[])b.run("INSERT OR REPLACE INTO apiKeys(id, key, name, machineId, isActive, createdAt, budgetDaily, budgetMonthly, requestsPerMinute, allowedModels, allowedConnectionIds) VALUES(?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)",[c.id,c.key,c.name||null,c.machineId||null,+(!1!==c.isActive),c.createdAt||new Date().toISOString(),Number(c.budgetDaily)||0,Number(c.budgetMonthly)||0,Number(c.requestsPerMinute)||0,(0,f.s)(c.allowedModels||[]),(0,f.s)(c.allowedConnectionIds||[])]);for(let c of a.combos||[])b.run("INSERT OR REPLACE INTO combos(id, name, kind, models, createdAt, updatedAt) VALUES(?, ?, ?, ?, ?, ?)",[c.id,c.name,c.kind||null,(0,f.s)(c.models||[]),c.createdAt||new Date().toISOString(),c.updatedAt||new Date().toISOString()]);for(let[c,d]of Object.entries(a.modelAliases||{}))b.run("INSERT OR REPLACE INTO kv(scope, key, value) VALUES('modelAliases', ?, ?)",[c,(0,f.s)(d)]);for(let c of a.customModels||[]){let a=`${c.providerAlias}|${c.id}|${c.type||"llm"}`;b.run("INSERT OR REPLACE INTO kv(scope, key, value) VALUES('customModels', ?, ?)",[a,(0,f.s)(c)])}for(let[c,d]of Object.entries(a.mitmAlias||{}))b.run("INSERT OR REPLACE INTO kv(scope, key, value) VALUES('mitmAlias', ?, ?)",[c,(0,f.s)(d||{})]);for(let[c,d]of Object.entries(a.pricing||{}))b.run("INSERT OR REPLACE INTO kv(scope, key, value) VALUES('pricing', ?, ?)",[c,(0,f.s)(d||{})])}),await aI()}},97914:(a,b,c)=>{c.d(b,{KJ:()=>l,VT:()=>n,getPricingForModel:()=>k,r4:()=>j,yF:()=>m});var d=c(36366),e=c(644);let f=(0,c(22846).U)("pricing"),g={value:null,expiresAt:0};function h(){g={value:null,expiresAt:0}}async function i(){return await f.getAll()}async function j(){let a=Date.now();if(g.value&&g.expiresAt>a)return g.value;let b=await i(),{PROVIDER_PRICING:d}=await c.e(7341).then(c.bind(c,57341)),e={};for(let[a,c]of Object.entries(d))if(e[a]={...c},b[a])for(let[c,d]of Object.entries(b[a]))e[a][c]=e[a][c]?{...e[a][c],...d}:d;for(let[a,c]of Object.entries(b))if(e[a])for(let[b,d]of Object.entries(c))e[a][b]||(e[a][b]=d);else e[a]={...c};return g={value:e,expiresAt:a+5e3},e}async function k(a,b){if(!b)return null;let d=await i();if(a&&d[a]?.[b])return d[a][b];let{getPricingForModel:e}=await c.e(7341).then(c.bind(c,57341));return e(a,b)}async function l(a){let b=await (0,d.getAdapter)();return b.transaction(()=>{for(let[c,d]of Object.entries(a)){let a=b.get("SELECT value FROM kv WHERE scope = 'pricing' AND key = ?",[c]),f={...a&&(0,e.q)(a.value,{})||{}};for(let[a,b]of Object.entries(d))f[a]=b;b.run("INSERT INTO kv(scope, key, value) VALUES('pricing', ?, ?) ON CONFLICT(scope, key) DO UPDATE SET value = excluded.value",[c,(0,e.s)(f)])}}),h(),await i()}async function m(a,b){if(!a)return await i();let c=await (0,d.getAdapter)();return c.transaction(()=>{if(!b)return void c.run("DELETE FROM kv WHERE scope = 'pricing' AND key = ?",[a]);let d=c.get("SELECT value FROM kv WHERE scope = 'pricing' AND key = ?",[a]),f=d&&(0,e.q)(d.value,{})||{};delete f[b],0===Object.keys(f).length?c.run("DELETE FROM kv WHERE scope = 'pricing' AND key = ?",[a]):c.run("INSERT INTO kv(scope, key, value) VALUES('pricing', ?, ?) ON CONFLICT(scope, key) DO UPDATE SET value = excluded.value",[a,(0,e.s)(f)])}),h(),await i()}async function n(){return await f.clear(),h(),{}}}};
|