@itsazni/9router 0.4.52 → 0.4.53
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/app/.next-cli-build/BUILD_ID +1 -1
- package/app/.next-cli-build/app-path-routes-manifest.json +5 -5
- package/app/.next-cli-build/build-manifest.json +2 -2
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/_global-error/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/_global-error.html +1 -1
- package/app/.next-cli-build/server/app/_global-error.rsc +1 -1
- package/app/.next-cli-build/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/_global-error.segments/_global-error.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/_global-error.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/_global-error.segments/_index.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/_not-found.html +1 -1
- package/app/.next-cli-build/server/app/_not-found.rsc +3 -3
- package/app/.next-cli-build/server/app/_not-found.segments/_full.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/_not-found.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/_not-found.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/_not-found.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/api/models/route.js +1 -1
- package/app/.next-cli-build/server/app/api/models/test/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/[id]/test-models/route.js +1 -1
- package/app/.next-cli-build/server/app/api/providers/route.js +1 -1
- package/app/.next-cli-build/server/app/api/translator/console-logs/route.js +1 -1
- package/app/.next-cli-build/server/app/api/translator/console-logs/stream/route.js +1 -1
- package/app/.next-cli-build/server/app/api/version/route.js +1 -1
- package/app/.next-cli-build/server/app/api/version/shutdown/route.js +1 -1
- package/app/.next-cli-build/server/app/api/version/update/route.js +1 -1
- package/app/.next-cli-build/server/app/callback/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/callback.html +1 -1
- package/app/.next-cli-build/server/app/callback.rsc +3 -3
- package/app/.next-cli-build/server/app/callback.segments/_full.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/callback.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/callback.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/callback.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/callback.segments/callback/__PAGE__.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/callback.segments/callback.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/basic-chat.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/basic-chat.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk/dashboard/basic-chat/__PAGE__.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk/dashboard/basic-chat.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/cli-tools.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/cli-tools.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk/dashboard/cli-tools/__PAGE__.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk/dashboard/cli-tools.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/combos.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/combos.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk/dashboard/combos/__PAGE__.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk/dashboard/combos.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/combos.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/combos.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/combos.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard/combos.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/endpoint.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/endpoint.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk/dashboard/endpoint/__PAGE__.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk/dashboard/endpoint.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard/media-providers/web/__PAGE__.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard/media-providers/web.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard/media-providers.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/mitm.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/mitm.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk/dashboard/mitm/__PAGE__.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk/dashboard/mitm.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/mitm.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/mitm.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/mitm.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard/mitm.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/profile.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/profile.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk/dashboard/profile/__PAGE__.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk/dashboard/profile.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/profile.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/profile.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/profile.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard/profile.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/providers/new.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/providers/new.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard/providers/new/__PAGE__.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard/providers/new.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard/providers.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/providers.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/providers.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk/dashboard/providers/__PAGE__.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk/dashboard/providers.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/providers.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/providers.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/providers.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard/providers.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk/dashboard/proxy-pools/__PAGE__.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk/dashboard/proxy-pools.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/quota.html +2 -2
- package/app/.next-cli-build/server/app/dashboard/quota.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk/dashboard/quota/__PAGE__.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk/dashboard/quota.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/quota.segments/_full.segment.rsc +6 -6
- package/app/.next-cli-build/server/app/dashboard/quota.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/quota.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard/quota.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/settings/pricing/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_full.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/dashboard/settings/pricing/__PAGE__.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/dashboard/settings/pricing.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/dashboard/settings.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/dashboard.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/skills.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/skills.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk/dashboard/skills/__PAGE__.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk/dashboard/skills.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/skills.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/skills.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/skills.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard/skills.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/translator.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/translator.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk/dashboard/translator/__PAGE__.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk/dashboard/translator.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/translator.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/translator.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/translator.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard/translator.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/usage.html +1 -1
- package/app/.next-cli-build/server/app/dashboard/usage.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk/dashboard/usage/__PAGE__.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk/dashboard/usage.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard/usage.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard/usage.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard/usage.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard/usage.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard.html +1 -1
- package/app/.next-cli-build/server/app/dashboard.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard.segments/!KGRhc2hib2FyZCk/dashboard/__PAGE__.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/dashboard.segments/_full.segment.rsc +5 -5
- package/app/.next-cli-build/server/app/dashboard.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/dashboard.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/dashboard.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/index.html +1 -1
- package/app/.next-cli-build/server/app/index.rsc +3 -3
- package/app/.next-cli-build/server/app/index.segments/__PAGE__.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/index.segments/_full.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/index.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/index.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/index.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/landing/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/landing.html +1 -1
- package/app/.next-cli-build/server/app/landing.rsc +3 -3
- package/app/.next-cli-build/server/app/landing.segments/_full.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/landing.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/landing.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/landing.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/landing.segments/landing/__PAGE__.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/landing.segments/landing.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/login/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app/login.html +1 -1
- package/app/.next-cli-build/server/app/login.rsc +4 -4
- package/app/.next-cli-build/server/app/login.segments/_full.segment.rsc +4 -4
- package/app/.next-cli-build/server/app/login.segments/_head.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/login.segments/_index.segment.rsc +3 -3
- package/app/.next-cli-build/server/app/login.segments/_tree.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/login.segments/login/__PAGE__.segment.rsc +2 -2
- package/app/.next-cli-build/server/app/login.segments/login.segment.rsc +1 -1
- package/app/.next-cli-build/server/app/page_client-reference-manifest.js +1 -1
- package/app/.next-cli-build/server/app-paths-manifest.json +5 -5
- package/app/.next-cli-build/server/chunks/3033.js +1 -1
- package/app/.next-cli-build/server/chunks/3680.js +1 -1
- package/app/.next-cli-build/server/chunks/5702.js +1 -1
- package/app/.next-cli-build/server/chunks/8567.js +1 -1
- package/app/.next-cli-build/server/middleware-build-manifest.js +1 -1
- package/app/.next-cli-build/server/pages/404.html +1 -1
- package/app/.next-cli-build/server/pages/500.html +1 -1
- package/app/.next-cli-build/static/chunks/{2425-3d54b718276d063b.js → 2425-d8d32a42f08b8397.js} +1 -1
- package/app/cli/.build-home/.9router/db/data.sqlite +0 -0
- package/app/package.json +1 -1
- package/package.json +2 -1
- /package/app/.next-cli-build/static/{Igw0na0QbaekWXhgkPVEF → aCEFcAyJ00QIU75jSO50U}/_buildManifest.js +0 -0
- /package/app/.next-cli-build/static/{Igw0na0QbaekWXhgkPVEF → aCEFcAyJ00QIU75jSO50U}/_ssgManifest.js +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(()=>{var a={};a.id=8648,a.ids=[8648],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},3295:a=>{a.exports=require("next/dist/server/app-render/after-task-async-storage.external.js")},4220:(a,b,c)=>{c.d(b,{Fh:()=>d.Fh,L9:()=>d.L9,Mc:()=>d.Mc,OM:()=>d.OM,P:()=>d.getProviderConnections,Pc:()=>d.Pc,Q_:()=>d.Q_,Qu:()=>d.Qu,S8:()=>d.S8,Yd:()=>d.Yd,ZO:()=>d.ZO,c:()=>d.c,createProviderConnection:()=>d.iE,fK:()=>d.fK,fv:()=>d.fv,ho:()=>d.ho,hr:()=>d.hr,i0:()=>d.i0,o5:()=>d.o5,op:()=>d.op,rj:()=>d.updateProviderConnection,uL:()=>d.uL,ui:()=>d.ui,uv:()=>d.uv});var d=c(78028)},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},11212:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>J,patchFetch:()=>I,routeModule:()=>E,serverHooks:()=>H,workAsyncStorage:()=>F,workUnitAsyncStorage:()=>G});var d={};c.r(d),c.d(d,{GET:()=>C,POST:()=>D,dynamic:()=>A});var e=c(71832),f=c(43805),g=c(93004),h=c(98942),i=c(2052),j=c(43404),k=c(261),l=c(21330),m=c(54832),n=c(85968),o=c(32163),p=c(19133),q=c(45391),r=c(62033),s=c(58742),t=c(86439),u=c(42108),v=c(3601),w=c(4220),x=c(46715),y=c(3811),z=c(65139);let A="force-dynamic";async function B(a){if(null==a||""===a||"__none__"===a)return{proxyPoolId:null};let b=String(a).trim();return b?await (0,w.hr)(b)?{proxyPoolId:b}:{error:"Proxy pool not found"}:{proxyPoolId:null}}async function C(){try{let a=await (0,w.P)(),b={};try{for(let a of(await (0,w.Fh)()))a.id&&a.name&&(b[a.id]=a.name)}catch{}let c=a.map(a=>{let c=(0,y.mq)(a.provider)||(0,y.gb)(a.provider)?a.name||b[a.provider]||a.providerSpecificData?.nodeName||a.provider:a.name;return{...a,name:c,apiKey:void 0,accessToken:void 0,refreshToken:void 0,idToken:void 0}});return v.NextResponse.json({connections:c})}catch(a){return console.log("Error fetching providers:",a),v.NextResponse.json({error:"Failed to fetch providers"},{status:500})}}async function D(a){try{let b=await a.json(),c=(0,z.o)(b.provider),{apiKey:d,name:e,displayName:f,priority:g,globalPriority:h,defaultModel:i,testStatus:j}=b,k=function(a={}){let b=a?.connectionProxyEnabled===!0,c="string"==typeof a?.connectionProxyUrl?a.connectionProxyUrl.trim():"",d="string"==typeof a?.connectionNoProxy?a.connectionNoProxy.trim():"";return b&&!c?{error:"Connection proxy URL is required when connection proxy is enabled"}:{connectionProxyEnabled:b,connectionProxyUrl:c,connectionNoProxy:d}}(b);if(k.error)return v.NextResponse.json({error:k.error},{status:400});let l=await B(b.proxyPoolId);if(l.error)return v.NextResponse.json({error:l.error},{status:400});let m=l.proxyPoolId,n=!!y.br[c],o=x.fg[c]||y.nJ[c]||n||(0,y.mq)(c)||(0,y.gb)(c)||(0,y.gC)(c);if(!c||!o)return v.NextResponse.json({error:"Invalid provider"},{status:400});if(!d&&"ollama-local"!==c)return v.NextResponse.json({error:`${n?"Cookie value":"API Key"} is required`},{status:400});let p=e||f||y.AI_PROVIDERS[c]?.name;if(!p)return v.NextResponse.json({error:"Name is required"},{status:400});let q=(0,z.F)(c,b,b.providerSpecificData);if((0,y.mq)(c)){let a=await (0,w.Qu)(c);if(!a)return v.NextResponse.json({error:"OpenAI Compatible node not found"},{status:404});q={prefix:a.prefix,apiType:a.apiType,baseUrl:a.baseUrl,nodeName:a.name}}else if((0,y.gb)(c)){let a=await (0,w.Qu)(c);if(!a)return v.NextResponse.json({error:"Anthropic Compatible node not found"},{status:404});q={prefix:a.prefix,baseUrl:a.baseUrl,nodeName:a.name}}else if((0,y.gC)(c)){let a=await (0,w.Qu)(c);if(!a)return v.NextResponse.json({error:"Custom Embedding node not found"},{status:404});q={prefix:a.prefix,baseUrl:a.baseUrl,nodeName:a.name}}let r={...q||{},connectionProxyEnabled:k.connectionProxyEnabled,connectionProxyUrl:k.connectionProxyUrl,connectionNoProxy:k.connectionNoProxy};null!==m&&(r.proxyPoolId=m);let s={...await (0,w.createProviderConnection)({provider:c,authType:n?"cookie":"apikey",name:p,apiKey:d||"",priority:g||1,globalPriority:h||null,defaultModel:i||null,providerSpecificData:r,isActive:!0,testStatus:j||"unknown"})};return delete s.apiKey,v.NextResponse.json({connection:s},{status:201})}catch(a){return console.log("Error creating provider:",a),v.NextResponse.json({error:"Failed to create provider"},{status:500})}}let E=new e.AppRouteRouteModule({definition:{kind:f.RouteKind.APP_ROUTE,page:"/api/providers/route",pathname:"/api/providers",filename:"route",bundlePath:"app/api/providers/route"},distDir:".next-cli-build",relativeProjectDir:"",resolvedPagePath:"/home/itsazni/projects/scripts/9router/src/app/api/providers/route.js",nextConfigOutput:"standalone",userland:d,...{}}),{workAsyncStorage:F,workUnitAsyncStorage:G,serverHooks:H}=E;function I(){return(0,g.patchFetch)({workAsyncStorage:F,workUnitAsyncStorage:G})}async function J(a,b,c){c.requestMeta&&(0,h.setRequestMeta)(a,c.requestMeta),E.isDev&&(0,h.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/providers/route";"/index"===d&&(d="/");let e=await E.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!e)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:g,deploymentId:v,params:w,nextConfig:x,parsedUrl:y,isDraftMode:z,prerenderManifest:A,routerServerContext:B,isOnDemandRevalidate:C,revalidateOnlyGenerated:D,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=e,I=(0,k.normalizeAppPath)(d),J=!!(A.dynamicRoutes[I]||A.routes[F]),K=async()=>((null==B?void 0:B.render404)?await B.render404(a,b,y,!1):b.end("This page could not be found"),null);if(J&&!z){let a=!!A.routes[F],b=A.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(x.adapterPath)return await K();throw new t.NoFallbackError}}let L=null;!J||E.isDev||z||(L="/index"===(L=F)?"/":L);let M=!0===E.isDev||!J,N=J&&!M;H&&G&&(0,j.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,i.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==B?void 0:B.isWrappedByNextServer),S=!!(0,h.getRequestMeta)(a,"minimalMode"),T=(0,h.getRequestMeta)(a,"incrementalCache")||await E.getIncrementalCache(a,x,A,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:w,previewProps:A.preview,renderOpts:{experimental:{authInterrupts:!!x.experimental.authInterrupts},cacheComponents:!!x.cacheComponents,supportsDynamicResponse:M,incrementalCache:T,cacheLifeProfiles:x.cacheLife,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>E.onRequestError(a,b,d,e,B)},sharedContext:{buildId:g,deploymentId:v}},V=new l.NodeNextRequest(a),W=new l.NodeNextResponse(b),X=m.NextRequestAdapter.fromNodeNextRequest(V,(0,m.signalFromNodeResponse)(b));try{let e,g=async a=>E.handle(X,U).finally(()=>{if(!a)return;a.setAttributes({"http.status_code":b.statusCode,"next.rsc":!1});let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==n.BaseServerSpan.handleRequest)return void console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let f=c.get("next.route");if(f){let b=`${O} ${f}`;a.setAttributes({"next.route":f,"http.route":f,"next.span_name":b}),a.updateName(b),e&&e!==a&&(e.setAttribute("http.route",f),e.updateName(b))}else a.updateName(`${O} ${d}`)}),h=async e=>{var h,i;let j=async({previousCacheEntry:f})=>{try{if(!S&&C&&D&&!f)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await g(e);a.fetchMetrics=U.renderOpts.fetchMetrics;let h=U.renderOpts.pendingWaitUntil;h&&c.waitUntil&&(c.waitUntil(h),h=void 0);let i=U.renderOpts.collectedTags;if(!J)return await (0,p.I)(V,W,d,U.renderOpts.pendingWaitUntil),null;{let a=await d.blob(),b=(0,q.toNodeOutgoingHttpHeaders)(d.headers);i&&(b[s.NEXT_CACHE_TAGS_HEADER]=i),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=s.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=s.INFINITE_CACHE?void 0:U.renderOpts.collectedExpire;return{value:{kind:u.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==f?void 0:f.isStale)&&await E.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:C})},!1,B),b}},k=await E.handleResponse({req:a,nextConfig:x,cacheKey:L,routeKind:f.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:A,isRoutePPREnabled:!1,isOnDemandRevalidate:C,revalidateOnlyGenerated:D,responseGenerator:j,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return null;if((null==k||null==(h=k.value)?void 0:h.kind)!==u.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==k||null==(i=k.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",C?"REVALIDATED":k.isMiss?"MISS":k.isStale?"STALE":"HIT"),z&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let l=(0,q.fromNodeOutgoingHttpHeaders)(k.value.headers);return S&&J||l.delete(s.NEXT_CACHE_TAGS_HEADER),!k.cacheControl||b.getHeader("Cache-Control")||l.get("Cache-Control")||l.set("Cache-Control",(0,r.getCacheControlHeader)(k.cacheControl)),await (0,p.I)(V,W,new Response(k.value.body,{headers:l,status:k.value.status||200})),null};R&&Q?await h(Q):(e=P.getActiveScopeSpan(),await P.withPropagatedContext(a.headers,()=>P.trace(n.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:i.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},h),void 0,!R))}catch(b){if(b instanceof t.NoFallbackError||await E.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:C})},!1,B),J)throw b;return await (0,p.I)(V,W,new Response(null,{status:500})),null}}},21820:a=>{a.exports=require("os")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},33873:a=>{a.exports=require("path")},39006:a=>{a.exports={rE:"0.4.52"}},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},46293:a=>{a.exports=require("sql.js")},46715:(a,b,c)=>{c.d(b,{UY:()=>h,X3:()=>i,eh:()=>f.eh,fg:()=>e.fg,h0:()=>g});var d=c(39006),e=c(3811),f=c(75491);d.rE;let g={npmPackageName:"9router",installCmd:"npm i -g 9router",installCmdLatest:"npm i -g 9router@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:20128},h={maxLines:200,pollIntervalMs:1e3},i={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"}},52727:(a,b,c)=>{c.d(b,{k:()=>e});let d=[];for(let a=0;a<256;++a)d.push((a+256).toString(16).slice(1));function e(a,b=0){return(d[a[b+0]]+d[a[b+1]]+d[a[b+2]]+d[a[b+3]]+"-"+d[a[b+4]]+d[a[b+5]]+"-"+d[a[b+6]]+d[a[b+7]]+"-"+d[a[b+8]]+d[a[b+9]]+"-"+d[a[b+10]]+d[a[b+11]]+d[a[b+12]]+d[a[b+13]]+d[a[b+14]]+d[a[b+15]]).toLowerCase()}},55511:a=>{a.exports=require("crypto")},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},65139:(a,b,c)=>{c.d(b,{F:()=>f,o:()=>e});var d=c(3811);function e(a){if("string"!=typeof a)return a;let b=a.trim();if(d.AI_PROVIDERS[b])return b;let c=b.toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/^-|-$/g,"");if(d.AI_PROVIDERS[c])return c;let e=Object.values(d.AI_PROVIDERS).find(a=>a.name?.toLowerCase()===b.toLowerCase());return e?.id||b}function f(a,b={},c=null){let d=c&&"object"==typeof c?{...c}:{};if("ollama-local"===a){let a=(d.baseUrl||b.baseUrl||b.baseURL||b.ollamaHostUrl||"").trim();a&&(d.baseUrl=a)}return Object.keys(d).length>0?d:null}},73024:a=>{a.exports=require("node:fs")},75491:(a,b,c)=>{c.d(b,{Xg:()=>d.Xg,eh:()=>e,vq:()=>d.vq});var d=c(17785);Object.entries(c(3811).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})))},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},78028:(a,b,c)=>{c.d(b,{CG:()=>d.CG,Dj:()=>d.Dj,Fh:()=>d.Fh,Iq:()=>d.Iq,K1:()=>d.K1,KJ:()=>d.KJ,L:()=>d.L,L9:()=>d.L9,Lh:()=>d.Lh,Mc:()=>d.Mc,OM:()=>d.OM,PX:()=>d.PX,Pc:()=>d.Pc,Q_:()=>d.Q_,Qu:()=>d.Qu,S8:()=>d.S8,Uv:()=>d.Uv,VT:()=>d.VT,XW:()=>d.XW,Xx:()=>d.Xx,Yd:()=>d.Yd,ZO:()=>d.ZO,c:()=>d.c,ek:()=>d.ek,fK:()=>d.fK,fv:()=>d.fv,getProviderConnections:()=>d.P,ho:()=>d.ho,hr:()=>d.hr,i0:()=>d.i0,iE:()=>d.iE,jd:()=>d.jd,mt:()=>d.mt,o5:()=>d.o5,oG:()=>d.oG,op:()=>d.op,r4:()=>d.r4,uL:()=>d.uL,ui:()=>d.ui,updateProviderConnection:()=>d.rj,uv:()=>d.uv,yF:()=>d.yF,yg:()=>d.yg,zP:()=>d.zP});var d=c(96269)},79868:a=>{a.exports=require("node:sqlite")},81787:a=>{a.exports=require("bun:sqlite")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},87550:a=>{a.exports=require("better-sqlite3")},94735:a=>{a.exports=require("events")},99344:(a,b,c)=>{c.d(b,{A:()=>i});var d=c(77598);let e={randomUUID:d.randomUUID},f=new Uint8Array(256),g=f.length;var h=c(52727);let i=function(a,b,c){if(e.randomUUID&&!b&&!a)return e.randomUUID();var i=a,j=c;let k=(i=i||{}).random??i.rng?.()??(g>f.length-16&&((0,d.randomFillSync)(f),g=0),f.slice(g,g+=16));if(k.length<16)throw Error("Random bytes length must be >= 16");if(k[6]=15&k[6]|64,k[8]=63&k[8]|128,b){if((j=j||0)<0||j+16>b.length)throw RangeError(`UUID byte range ${j}:${j+15} is out of buffer bounds`);for(let a=0;a<16;++a)b[j+a]=k[a];return b}return(0,h.k)(k)}}};var b=require("../../../webpack-runtime.js");b.C(a);var c=b.X(0,[7426,9004,3267,3811,7785],()=>b(b.s=11212));module.exports=c})();
|
|
1
|
+
"use strict";(()=>{var a={};a.id=8648,a.ids=[8648],a.modules={261:a=>{a.exports=require("next/dist/shared/lib/router/utils/app-paths")},3295:a=>{a.exports=require("next/dist/server/app-render/after-task-async-storage.external.js")},4220:(a,b,c)=>{c.d(b,{Fh:()=>d.Fh,L9:()=>d.L9,Mc:()=>d.Mc,OM:()=>d.OM,P:()=>d.getProviderConnections,Pc:()=>d.Pc,Q_:()=>d.Q_,Qu:()=>d.Qu,S8:()=>d.S8,Yd:()=>d.Yd,ZO:()=>d.ZO,c:()=>d.c,createProviderConnection:()=>d.iE,fK:()=>d.fK,fv:()=>d.fv,ho:()=>d.ho,hr:()=>d.hr,i0:()=>d.i0,o5:()=>d.o5,op:()=>d.op,rj:()=>d.updateProviderConnection,uL:()=>d.uL,ui:()=>d.ui,uv:()=>d.uv});var d=c(78028)},10846:a=>{a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},11212:(a,b,c)=>{c.r(b),c.d(b,{handler:()=>J,patchFetch:()=>I,routeModule:()=>E,serverHooks:()=>H,workAsyncStorage:()=>F,workUnitAsyncStorage:()=>G});var d={};c.r(d),c.d(d,{GET:()=>C,POST:()=>D,dynamic:()=>A});var e=c(71832),f=c(43805),g=c(93004),h=c(98942),i=c(2052),j=c(43404),k=c(261),l=c(21330),m=c(54832),n=c(85968),o=c(32163),p=c(19133),q=c(45391),r=c(62033),s=c(58742),t=c(86439),u=c(42108),v=c(3601),w=c(4220),x=c(46715),y=c(3811),z=c(65139);let A="force-dynamic";async function B(a){if(null==a||""===a||"__none__"===a)return{proxyPoolId:null};let b=String(a).trim();return b?await (0,w.hr)(b)?{proxyPoolId:b}:{error:"Proxy pool not found"}:{proxyPoolId:null}}async function C(){try{let a=await (0,w.P)(),b={};try{for(let a of(await (0,w.Fh)()))a.id&&a.name&&(b[a.id]=a.name)}catch{}let c=a.map(a=>{let c=(0,y.mq)(a.provider)||(0,y.gb)(a.provider)?a.name||b[a.provider]||a.providerSpecificData?.nodeName||a.provider:a.name;return{...a,name:c,apiKey:void 0,accessToken:void 0,refreshToken:void 0,idToken:void 0}});return v.NextResponse.json({connections:c})}catch(a){return console.log("Error fetching providers:",a),v.NextResponse.json({error:"Failed to fetch providers"},{status:500})}}async function D(a){try{let b=await a.json(),c=(0,z.o)(b.provider),{apiKey:d,name:e,displayName:f,priority:g,globalPriority:h,defaultModel:i,testStatus:j}=b,k=function(a={}){let b=a?.connectionProxyEnabled===!0,c="string"==typeof a?.connectionProxyUrl?a.connectionProxyUrl.trim():"",d="string"==typeof a?.connectionNoProxy?a.connectionNoProxy.trim():"";return b&&!c?{error:"Connection proxy URL is required when connection proxy is enabled"}:{connectionProxyEnabled:b,connectionProxyUrl:c,connectionNoProxy:d}}(b);if(k.error)return v.NextResponse.json({error:k.error},{status:400});let l=await B(b.proxyPoolId);if(l.error)return v.NextResponse.json({error:l.error},{status:400});let m=l.proxyPoolId,n=!!y.br[c],o=x.fg[c]||y.nJ[c]||n||(0,y.mq)(c)||(0,y.gb)(c)||(0,y.gC)(c);if(!c||!o)return v.NextResponse.json({error:"Invalid provider"},{status:400});if(!d&&"ollama-local"!==c)return v.NextResponse.json({error:`${n?"Cookie value":"API Key"} is required`},{status:400});let p=e||f||y.AI_PROVIDERS[c]?.name;if(!p)return v.NextResponse.json({error:"Name is required"},{status:400});let q=(0,z.F)(c,b,b.providerSpecificData);if((0,y.mq)(c)){let a=await (0,w.Qu)(c);if(!a)return v.NextResponse.json({error:"OpenAI Compatible node not found"},{status:404});q={prefix:a.prefix,apiType:a.apiType,baseUrl:a.baseUrl,nodeName:a.name}}else if((0,y.gb)(c)){let a=await (0,w.Qu)(c);if(!a)return v.NextResponse.json({error:"Anthropic Compatible node not found"},{status:404});q={prefix:a.prefix,baseUrl:a.baseUrl,nodeName:a.name}}else if((0,y.gC)(c)){let a=await (0,w.Qu)(c);if(!a)return v.NextResponse.json({error:"Custom Embedding node not found"},{status:404});q={prefix:a.prefix,baseUrl:a.baseUrl,nodeName:a.name}}let r={...q||{},connectionProxyEnabled:k.connectionProxyEnabled,connectionProxyUrl:k.connectionProxyUrl,connectionNoProxy:k.connectionNoProxy};null!==m&&(r.proxyPoolId=m);let s={...await (0,w.createProviderConnection)({provider:c,authType:n?"cookie":"apikey",name:p,apiKey:d||"",priority:g||1,globalPriority:h||null,defaultModel:i||null,providerSpecificData:r,isActive:!0,testStatus:j||"unknown"})};return delete s.apiKey,v.NextResponse.json({connection:s},{status:201})}catch(a){return console.log("Error creating provider:",a),v.NextResponse.json({error:"Failed to create provider"},{status:500})}}let E=new e.AppRouteRouteModule({definition:{kind:f.RouteKind.APP_ROUTE,page:"/api/providers/route",pathname:"/api/providers",filename:"route",bundlePath:"app/api/providers/route"},distDir:".next-cli-build",relativeProjectDir:"",resolvedPagePath:"/home/itsazni/projects/scripts/9router/src/app/api/providers/route.js",nextConfigOutput:"standalone",userland:d,...{}}),{workAsyncStorage:F,workUnitAsyncStorage:G,serverHooks:H}=E;function I(){return(0,g.patchFetch)({workAsyncStorage:F,workUnitAsyncStorage:G})}async function J(a,b,c){c.requestMeta&&(0,h.setRequestMeta)(a,c.requestMeta),E.isDev&&(0,h.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/providers/route";"/index"===d&&(d="/");let e=await E.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!e)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:g,deploymentId:v,params:w,nextConfig:x,parsedUrl:y,isDraftMode:z,prerenderManifest:A,routerServerContext:B,isOnDemandRevalidate:C,revalidateOnlyGenerated:D,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=e,I=(0,k.normalizeAppPath)(d),J=!!(A.dynamicRoutes[I]||A.routes[F]),K=async()=>((null==B?void 0:B.render404)?await B.render404(a,b,y,!1):b.end("This page could not be found"),null);if(J&&!z){let a=!!A.routes[F],b=A.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(x.adapterPath)return await K();throw new t.NoFallbackError}}let L=null;!J||E.isDev||z||(L="/index"===(L=F)?"/":L);let M=!0===E.isDev||!J,N=J&&!M;H&&G&&(0,j.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,i.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==B?void 0:B.isWrappedByNextServer),S=!!(0,h.getRequestMeta)(a,"minimalMode"),T=(0,h.getRequestMeta)(a,"incrementalCache")||await E.getIncrementalCache(a,x,A,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:w,previewProps:A.preview,renderOpts:{experimental:{authInterrupts:!!x.experimental.authInterrupts},cacheComponents:!!x.cacheComponents,supportsDynamicResponse:M,incrementalCache:T,cacheLifeProfiles:x.cacheLife,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>E.onRequestError(a,b,d,e,B)},sharedContext:{buildId:g,deploymentId:v}},V=new l.NodeNextRequest(a),W=new l.NodeNextResponse(b),X=m.NextRequestAdapter.fromNodeNextRequest(V,(0,m.signalFromNodeResponse)(b));try{let e,g=async a=>E.handle(X,U).finally(()=>{if(!a)return;a.setAttributes({"http.status_code":b.statusCode,"next.rsc":!1});let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==n.BaseServerSpan.handleRequest)return void console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let f=c.get("next.route");if(f){let b=`${O} ${f}`;a.setAttributes({"next.route":f,"http.route":f,"next.span_name":b}),a.updateName(b),e&&e!==a&&(e.setAttribute("http.route",f),e.updateName(b))}else a.updateName(`${O} ${d}`)}),h=async e=>{var h,i;let j=async({previousCacheEntry:f})=>{try{if(!S&&C&&D&&!f)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await g(e);a.fetchMetrics=U.renderOpts.fetchMetrics;let h=U.renderOpts.pendingWaitUntil;h&&c.waitUntil&&(c.waitUntil(h),h=void 0);let i=U.renderOpts.collectedTags;if(!J)return await (0,p.I)(V,W,d,U.renderOpts.pendingWaitUntil),null;{let a=await d.blob(),b=(0,q.toNodeOutgoingHttpHeaders)(d.headers);i&&(b[s.NEXT_CACHE_TAGS_HEADER]=i),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=s.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=s.INFINITE_CACHE?void 0:U.renderOpts.collectedExpire;return{value:{kind:u.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==f?void 0:f.isStale)&&await E.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:C})},!1,B),b}},k=await E.handleResponse({req:a,nextConfig:x,cacheKey:L,routeKind:f.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:A,isRoutePPREnabled:!1,isOnDemandRevalidate:C,revalidateOnlyGenerated:D,responseGenerator:j,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return null;if((null==k||null==(h=k.value)?void 0:h.kind)!==u.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==k||null==(i=k.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",C?"REVALIDATED":k.isMiss?"MISS":k.isStale?"STALE":"HIT"),z&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let l=(0,q.fromNodeOutgoingHttpHeaders)(k.value.headers);return S&&J||l.delete(s.NEXT_CACHE_TAGS_HEADER),!k.cacheControl||b.getHeader("Cache-Control")||l.get("Cache-Control")||l.set("Cache-Control",(0,r.getCacheControlHeader)(k.cacheControl)),await (0,p.I)(V,W,new Response(k.value.body,{headers:l,status:k.value.status||200})),null};R&&Q?await h(Q):(e=P.getActiveScopeSpan(),await P.withPropagatedContext(a.headers,()=>P.trace(n.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:i.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},h),void 0,!R))}catch(b){if(b instanceof t.NoFallbackError||await E.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:C})},!1,B),J)throw b;return await (0,p.I)(V,W,new Response(null,{status:500})),null}}},21820:a=>{a.exports=require("os")},29294:a=>{a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},33873:a=>{a.exports=require("path")},39006:a=>{a.exports={rE:"0.4.53"}},44870:a=>{a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},46293:a=>{a.exports=require("sql.js")},46715:(a,b,c)=>{c.d(b,{UY:()=>h,X3:()=>i,eh:()=>f.eh,fg:()=>e.fg,h0:()=>g});var d=c(39006),e=c(3811),f=c(75491);d.rE;let g={npmPackageName:"9router",installCmd:"npm i -g 9router",installCmdLatest:"npm i -g 9router@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:20128},h={maxLines:200,pollIntervalMs:1e3},i={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"}},52727:(a,b,c)=>{c.d(b,{k:()=>e});let d=[];for(let a=0;a<256;++a)d.push((a+256).toString(16).slice(1));function e(a,b=0){return(d[a[b+0]]+d[a[b+1]]+d[a[b+2]]+d[a[b+3]]+"-"+d[a[b+4]]+d[a[b+5]]+"-"+d[a[b+6]]+d[a[b+7]]+"-"+d[a[b+8]]+d[a[b+9]]+"-"+d[a[b+10]]+d[a[b+11]]+d[a[b+12]]+d[a[b+13]]+d[a[b+14]]+d[a[b+15]]).toLowerCase()}},55511:a=>{a.exports=require("crypto")},63033:a=>{a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},65139:(a,b,c)=>{c.d(b,{F:()=>f,o:()=>e});var d=c(3811);function e(a){if("string"!=typeof a)return a;let b=a.trim();if(d.AI_PROVIDERS[b])return b;let c=b.toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/^-|-$/g,"");if(d.AI_PROVIDERS[c])return c;let e=Object.values(d.AI_PROVIDERS).find(a=>a.name?.toLowerCase()===b.toLowerCase());return e?.id||b}function f(a,b={},c=null){let d=c&&"object"==typeof c?{...c}:{};if("ollama-local"===a){let a=(d.baseUrl||b.baseUrl||b.baseURL||b.ollamaHostUrl||"").trim();a&&(d.baseUrl=a)}return Object.keys(d).length>0?d:null}},73024:a=>{a.exports=require("node:fs")},75491:(a,b,c)=>{c.d(b,{Xg:()=>d.Xg,eh:()=>e,vq:()=>d.vq});var d=c(17785);Object.entries(c(3811).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})))},76760:a=>{a.exports=require("node:path")},77598:a=>{a.exports=require("node:crypto")},78028:(a,b,c)=>{c.d(b,{CG:()=>d.CG,Dj:()=>d.Dj,Fh:()=>d.Fh,Iq:()=>d.Iq,K1:()=>d.K1,KJ:()=>d.KJ,L:()=>d.L,L9:()=>d.L9,Lh:()=>d.Lh,Mc:()=>d.Mc,OM:()=>d.OM,PX:()=>d.PX,Pc:()=>d.Pc,Q_:()=>d.Q_,Qu:()=>d.Qu,S8:()=>d.S8,Uv:()=>d.Uv,VT:()=>d.VT,XW:()=>d.XW,Xx:()=>d.Xx,Yd:()=>d.Yd,ZO:()=>d.ZO,c:()=>d.c,ek:()=>d.ek,fK:()=>d.fK,fv:()=>d.fv,getProviderConnections:()=>d.P,ho:()=>d.ho,hr:()=>d.hr,i0:()=>d.i0,iE:()=>d.iE,jd:()=>d.jd,mt:()=>d.mt,o5:()=>d.o5,oG:()=>d.oG,op:()=>d.op,r4:()=>d.r4,uL:()=>d.uL,ui:()=>d.ui,updateProviderConnection:()=>d.rj,uv:()=>d.uv,yF:()=>d.yF,yg:()=>d.yg,zP:()=>d.zP});var d=c(96269)},79868:a=>{a.exports=require("node:sqlite")},81787:a=>{a.exports=require("bun:sqlite")},86439:a=>{a.exports=require("next/dist/shared/lib/no-fallback-error.external")},87550:a=>{a.exports=require("better-sqlite3")},94735:a=>{a.exports=require("events")},99344:(a,b,c)=>{c.d(b,{A:()=>i});var d=c(77598);let e={randomUUID:d.randomUUID},f=new Uint8Array(256),g=f.length;var h=c(52727);let i=function(a,b,c){if(e.randomUUID&&!b&&!a)return e.randomUUID();var i=a,j=c;let k=(i=i||{}).random??i.rng?.()??(g>f.length-16&&((0,d.randomFillSync)(f),g=0),f.slice(g,g+=16));if(k.length<16)throw Error("Random bytes length must be >= 16");if(k[6]=15&k[6]|64,k[8]=63&k[8]|128,b){if((j=j||0)<0||j+16>b.length)throw RangeError(`UUID byte range ${j}:${j+15} is out of buffer bounds`);for(let a=0;a<16;++a)b[j+a]=k[a];return b}return(0,h.k)(k)}}};var b=require("../../../webpack-runtime.js");b.C(a);var c=b.X(0,[7426,9004,3267,3811,7785],()=>b(b.s=11212));module.exports=c})();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(()=>{var a={};a.id=5226,a.ids=[5226],a.modules={261:a=>{"use strict";a.exports=require("next/dist/shared/lib/router/utils/app-paths")},3295:a=>{"use strict";a.exports=require("next/dist/server/app-render/after-task-async-storage.external.js")},10846:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},13630:(a,b,c)=>{"use strict";c.d(b,{KM:()=>m,fO:()=>l,up:()=>n,wJ:()=>k});var d=c(94735),e=c(46715);let f=["log","info","warn","error","debug"];global._consoleLogBufferState||(global._consoleLogBufferState={logs:[],patched:!1,originals:{},emitter:new d.EventEmitter},global._consoleLogBufferState.emitter.setMaxListeners(50));let g=global._consoleLogBufferState;g.emitter||(g.emitter=new d.EventEmitter,g.emitter.setMaxListeners(50));let h=/\x1b\[[0-9;]*m/g;function i(a){return a.replace(h,"")}function j(a){if("string"==typeof a)return i(a);if(a instanceof Error)return i(a.stack||a.message||String(a));try{return i(JSON.stringify(a))}catch{return i(String(a))}}function k(){if(!g.patched){for(let a of f)g.originals[a]=console[a],console[a]=(...b)=>{!function(a){g.logs.push(a);let b=e.UY.maxLines;g.logs.length>b&&(g.logs=g.logs.slice(-b)),g.emitter.emit("line",a)}(b.map(j).join(" ")),g.originals[a](...b)};g.patched=!0}}function l(){return g.logs}function m(){g.logs=[],g.emitter.emit("clear")}function n(){return g.emitter}},15616:()=>{},21820:a=>{"use strict";a.exports=require("os")},29294:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},39006:a=>{"use strict";a.exports={rE:"0.4.52"}},44870:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},46715:(a,b,c)=>{"use strict";c.d(b,{UY:()=>h,X3:()=>i,eh:()=>f.eh,fg:()=>e.fg,h0:()=>g});var d=c(39006),e=c(3811),f=c(75491);d.rE;let g={npmPackageName:"9router",installCmd:"npm i -g 9router",installCmdLatest:"npm i -g 9router@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:20128},h={maxLines:200,pollIntervalMs:1e3},i={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"}},52064:()=>{},63033:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},70541:(a,b,c)=>{"use strict";c.r(b),c.d(b,{handler:()=>E,patchFetch:()=>D,routeModule:()=>z,serverHooks:()=>C,workAsyncStorage:()=>A,workUnitAsyncStorage:()=>B});var d={};c.r(d),c.d(d,{DELETE:()=>y,GET:()=>x});var e=c(71832),f=c(43805),g=c(93004),h=c(98942),i=c(2052),j=c(43404),k=c(261),l=c(21330),m=c(54832),n=c(85968),o=c(32163),p=c(19133),q=c(45391),r=c(62033),s=c(58742),t=c(86439),u=c(42108),v=c(3601),w=c(13630);async function x(){try{let a=(0,w.fO)();return v.NextResponse.json({success:!0,logs:a})}catch(a){return console.error("Error getting console logs:",a),v.NextResponse.json({success:!1,error:a.message},{status:500})}}async function y(){try{return(0,w.KM)(),v.NextResponse.json({success:!0})}catch(a){return console.error("Error clearing console logs:",a),v.NextResponse.json({success:!1,error:a.message},{status:500})}}(0,w.wJ)();let z=new e.AppRouteRouteModule({definition:{kind:f.RouteKind.APP_ROUTE,page:"/api/translator/console-logs/route",pathname:"/api/translator/console-logs",filename:"route",bundlePath:"app/api/translator/console-logs/route"},distDir:".next-cli-build",relativeProjectDir:"",resolvedPagePath:"/home/itsazni/projects/scripts/9router/src/app/api/translator/console-logs/route.js",nextConfigOutput:"standalone",userland:d,...{}}),{workAsyncStorage:A,workUnitAsyncStorage:B,serverHooks:C}=z;function D(){return(0,g.patchFetch)({workAsyncStorage:A,workUnitAsyncStorage:B})}async function E(a,b,c){c.requestMeta&&(0,h.setRequestMeta)(a,c.requestMeta),z.isDev&&(0,h.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/translator/console-logs/route";"/index"===d&&(d="/");let e=await z.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!e)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:g,deploymentId:v,params:w,nextConfig:x,parsedUrl:y,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=e,I=(0,k.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,y,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(x.adapterPath)return await K();throw new t.NoFallbackError}}let L=null;!J||z.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===z.isDev||!J,N=J&&!M;H&&G&&(0,j.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,i.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,h.getRequestMeta)(a,"minimalMode"),T=(0,h.getRequestMeta)(a,"incrementalCache")||await z.getIncrementalCache(a,x,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:w,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!x.experimental.authInterrupts},cacheComponents:!!x.cacheComponents,supportsDynamicResponse:M,incrementalCache:T,cacheLifeProfiles:x.cacheLife,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>z.onRequestError(a,b,d,e,C)},sharedContext:{buildId:g,deploymentId:v}},V=new l.NodeNextRequest(a),W=new l.NodeNextResponse(b),X=m.NextRequestAdapter.fromNodeNextRequest(V,(0,m.signalFromNodeResponse)(b));try{let e,g=async a=>z.handle(X,U).finally(()=>{if(!a)return;a.setAttributes({"http.status_code":b.statusCode,"next.rsc":!1});let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==n.BaseServerSpan.handleRequest)return void console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let f=c.get("next.route");if(f){let b=`${O} ${f}`;a.setAttributes({"next.route":f,"http.route":f,"next.span_name":b}),a.updateName(b),e&&e!==a&&(e.setAttribute("http.route",f),e.updateName(b))}else a.updateName(`${O} ${d}`)}),h=async e=>{var h,i;let j=async({previousCacheEntry:f})=>{try{if(!S&&D&&E&&!f)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await g(e);a.fetchMetrics=U.renderOpts.fetchMetrics;let h=U.renderOpts.pendingWaitUntil;h&&c.waitUntil&&(c.waitUntil(h),h=void 0);let i=U.renderOpts.collectedTags;if(!J)return await (0,p.I)(V,W,d,U.renderOpts.pendingWaitUntil),null;{let a=await d.blob(),b=(0,q.toNodeOutgoingHttpHeaders)(d.headers);i&&(b[s.NEXT_CACHE_TAGS_HEADER]=i),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=s.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=s.INFINITE_CACHE?void 0:U.renderOpts.collectedExpire;return{value:{kind:u.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==f?void 0:f.isStale)&&await z.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},k=await z.handleResponse({req:a,nextConfig:x,cacheKey:L,routeKind:f.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:j,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return null;if((null==k||null==(h=k.value)?void 0:h.kind)!==u.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==k||null==(i=k.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":k.isMiss?"MISS":k.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let l=(0,q.fromNodeOutgoingHttpHeaders)(k.value.headers);return S&&J||l.delete(s.NEXT_CACHE_TAGS_HEADER),!k.cacheControl||b.getHeader("Cache-Control")||l.get("Cache-Control")||l.set("Cache-Control",(0,r.getCacheControlHeader)(k.cacheControl)),await (0,p.I)(V,W,new Response(k.value.body,{headers:l,status:k.value.status||200})),null};R&&Q?await h(Q):(e=P.getActiveScopeSpan(),await P.withPropagatedContext(a.headers,()=>P.trace(n.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:i.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},h),void 0,!R))}catch(b){if(b instanceof t.NoFallbackError||await z.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;return await (0,p.I)(V,W,new Response(null,{status:500})),null}}},75491:(a,b,c)=>{"use strict";c.d(b,{Xg:()=>d.Xg,eh:()=>e,vq:()=>d.vq});var d=c(17785);Object.entries(c(3811).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})))},86439:a=>{"use strict";a.exports=require("next/dist/shared/lib/no-fallback-error.external")},94735:a=>{"use strict";a.exports=require("events")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[7426,9004,3811,7785],()=>b(b.s=70541));module.exports=c})();
|
|
1
|
+
(()=>{var a={};a.id=5226,a.ids=[5226],a.modules={261:a=>{"use strict";a.exports=require("next/dist/shared/lib/router/utils/app-paths")},3295:a=>{"use strict";a.exports=require("next/dist/server/app-render/after-task-async-storage.external.js")},10846:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},13630:(a,b,c)=>{"use strict";c.d(b,{KM:()=>m,fO:()=>l,up:()=>n,wJ:()=>k});var d=c(94735),e=c(46715);let f=["log","info","warn","error","debug"];global._consoleLogBufferState||(global._consoleLogBufferState={logs:[],patched:!1,originals:{},emitter:new d.EventEmitter},global._consoleLogBufferState.emitter.setMaxListeners(50));let g=global._consoleLogBufferState;g.emitter||(g.emitter=new d.EventEmitter,g.emitter.setMaxListeners(50));let h=/\x1b\[[0-9;]*m/g;function i(a){return a.replace(h,"")}function j(a){if("string"==typeof a)return i(a);if(a instanceof Error)return i(a.stack||a.message||String(a));try{return i(JSON.stringify(a))}catch{return i(String(a))}}function k(){if(!g.patched){for(let a of f)g.originals[a]=console[a],console[a]=(...b)=>{!function(a){g.logs.push(a);let b=e.UY.maxLines;g.logs.length>b&&(g.logs=g.logs.slice(-b)),g.emitter.emit("line",a)}(b.map(j).join(" ")),g.originals[a](...b)};g.patched=!0}}function l(){return g.logs}function m(){g.logs=[],g.emitter.emit("clear")}function n(){return g.emitter}},15616:()=>{},21820:a=>{"use strict";a.exports=require("os")},29294:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},39006:a=>{"use strict";a.exports={rE:"0.4.53"}},44870:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},46715:(a,b,c)=>{"use strict";c.d(b,{UY:()=>h,X3:()=>i,eh:()=>f.eh,fg:()=>e.fg,h0:()=>g});var d=c(39006),e=c(3811),f=c(75491);d.rE;let g={npmPackageName:"9router",installCmd:"npm i -g 9router",installCmdLatest:"npm i -g 9router@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:20128},h={maxLines:200,pollIntervalMs:1e3},i={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"}},52064:()=>{},63033:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},70541:(a,b,c)=>{"use strict";c.r(b),c.d(b,{handler:()=>E,patchFetch:()=>D,routeModule:()=>z,serverHooks:()=>C,workAsyncStorage:()=>A,workUnitAsyncStorage:()=>B});var d={};c.r(d),c.d(d,{DELETE:()=>y,GET:()=>x});var e=c(71832),f=c(43805),g=c(93004),h=c(98942),i=c(2052),j=c(43404),k=c(261),l=c(21330),m=c(54832),n=c(85968),o=c(32163),p=c(19133),q=c(45391),r=c(62033),s=c(58742),t=c(86439),u=c(42108),v=c(3601),w=c(13630);async function x(){try{let a=(0,w.fO)();return v.NextResponse.json({success:!0,logs:a})}catch(a){return console.error("Error getting console logs:",a),v.NextResponse.json({success:!1,error:a.message},{status:500})}}async function y(){try{return(0,w.KM)(),v.NextResponse.json({success:!0})}catch(a){return console.error("Error clearing console logs:",a),v.NextResponse.json({success:!1,error:a.message},{status:500})}}(0,w.wJ)();let z=new e.AppRouteRouteModule({definition:{kind:f.RouteKind.APP_ROUTE,page:"/api/translator/console-logs/route",pathname:"/api/translator/console-logs",filename:"route",bundlePath:"app/api/translator/console-logs/route"},distDir:".next-cli-build",relativeProjectDir:"",resolvedPagePath:"/home/itsazni/projects/scripts/9router/src/app/api/translator/console-logs/route.js",nextConfigOutput:"standalone",userland:d,...{}}),{workAsyncStorage:A,workUnitAsyncStorage:B,serverHooks:C}=z;function D(){return(0,g.patchFetch)({workAsyncStorage:A,workUnitAsyncStorage:B})}async function E(a,b,c){c.requestMeta&&(0,h.setRequestMeta)(a,c.requestMeta),z.isDev&&(0,h.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/translator/console-logs/route";"/index"===d&&(d="/");let e=await z.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!e)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:g,deploymentId:v,params:w,nextConfig:x,parsedUrl:y,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=e,I=(0,k.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,y,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(x.adapterPath)return await K();throw new t.NoFallbackError}}let L=null;!J||z.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===z.isDev||!J,N=J&&!M;H&&G&&(0,j.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,i.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,h.getRequestMeta)(a,"minimalMode"),T=(0,h.getRequestMeta)(a,"incrementalCache")||await z.getIncrementalCache(a,x,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:w,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!x.experimental.authInterrupts},cacheComponents:!!x.cacheComponents,supportsDynamicResponse:M,incrementalCache:T,cacheLifeProfiles:x.cacheLife,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>z.onRequestError(a,b,d,e,C)},sharedContext:{buildId:g,deploymentId:v}},V=new l.NodeNextRequest(a),W=new l.NodeNextResponse(b),X=m.NextRequestAdapter.fromNodeNextRequest(V,(0,m.signalFromNodeResponse)(b));try{let e,g=async a=>z.handle(X,U).finally(()=>{if(!a)return;a.setAttributes({"http.status_code":b.statusCode,"next.rsc":!1});let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==n.BaseServerSpan.handleRequest)return void console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let f=c.get("next.route");if(f){let b=`${O} ${f}`;a.setAttributes({"next.route":f,"http.route":f,"next.span_name":b}),a.updateName(b),e&&e!==a&&(e.setAttribute("http.route",f),e.updateName(b))}else a.updateName(`${O} ${d}`)}),h=async e=>{var h,i;let j=async({previousCacheEntry:f})=>{try{if(!S&&D&&E&&!f)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await g(e);a.fetchMetrics=U.renderOpts.fetchMetrics;let h=U.renderOpts.pendingWaitUntil;h&&c.waitUntil&&(c.waitUntil(h),h=void 0);let i=U.renderOpts.collectedTags;if(!J)return await (0,p.I)(V,W,d,U.renderOpts.pendingWaitUntil),null;{let a=await d.blob(),b=(0,q.toNodeOutgoingHttpHeaders)(d.headers);i&&(b[s.NEXT_CACHE_TAGS_HEADER]=i),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=s.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=s.INFINITE_CACHE?void 0:U.renderOpts.collectedExpire;return{value:{kind:u.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==f?void 0:f.isStale)&&await z.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},k=await z.handleResponse({req:a,nextConfig:x,cacheKey:L,routeKind:f.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:j,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return null;if((null==k||null==(h=k.value)?void 0:h.kind)!==u.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==k||null==(i=k.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":k.isMiss?"MISS":k.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let l=(0,q.fromNodeOutgoingHttpHeaders)(k.value.headers);return S&&J||l.delete(s.NEXT_CACHE_TAGS_HEADER),!k.cacheControl||b.getHeader("Cache-Control")||l.get("Cache-Control")||l.set("Cache-Control",(0,r.getCacheControlHeader)(k.cacheControl)),await (0,p.I)(V,W,new Response(k.value.body,{headers:l,status:k.value.status||200})),null};R&&Q?await h(Q):(e=P.getActiveScopeSpan(),await P.withPropagatedContext(a.headers,()=>P.trace(n.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:i.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},h),void 0,!R))}catch(b){if(b instanceof t.NoFallbackError||await z.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;return await (0,p.I)(V,W,new Response(null,{status:500})),null}}},75491:(a,b,c)=>{"use strict";c.d(b,{Xg:()=>d.Xg,eh:()=>e,vq:()=>d.vq});var d=c(17785);Object.entries(c(3811).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})))},86439:a=>{"use strict";a.exports=require("next/dist/shared/lib/no-fallback-error.external")},94735:a=>{"use strict";a.exports=require("events")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[7426,9004,3811,7785],()=>b(b.s=70541));module.exports=c})();
|
|
@@ -4,4 +4,4 @@
|
|
|
4
4
|
|
|
5
5
|
`))}catch{e()}},d.sendClear=()=>{if(!d.closed)try{a.enqueue(b.encode(`data: ${JSON.stringify({type:"clear"})}
|
|
6
6
|
|
|
7
|
-
`))}catch{e()}},c.on("line",d.send),c.on("clear",d.sendClear),d.keepalive=setInterval(()=>{if(d.closed)return void clearInterval(d.keepalive);try{a.enqueue(b.encode(": ping\n\n"))}catch{e()}},25e3)},cancel(){e()}}),{headers:{"Content-Type":"text/event-stream","Cache-Control":"no-cache",Connection:"keep-alive"}})}(0,v.wJ)();let y=new e.AppRouteRouteModule({definition:{kind:f.RouteKind.APP_ROUTE,page:"/api/translator/console-logs/stream/route",pathname:"/api/translator/console-logs/stream",filename:"route",bundlePath:"app/api/translator/console-logs/stream/route"},distDir:".next-cli-build",relativeProjectDir:"",resolvedPagePath:"/home/itsazni/projects/scripts/9router/src/app/api/translator/console-logs/stream/route.js",nextConfigOutput:"standalone",userland:d,...{}}),{workAsyncStorage:z,workUnitAsyncStorage:A,serverHooks:B}=y;function C(){return(0,g.patchFetch)({workAsyncStorage:z,workUnitAsyncStorage:A})}async function D(a,b,c){c.requestMeta&&(0,h.setRequestMeta)(a,c.requestMeta),y.isDev&&(0,h.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/translator/console-logs/stream/route";"/index"===d&&(d="/");let e=await y.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!e)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:g,deploymentId:v,params:w,nextConfig:x,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=e,I=(0,k.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(x.adapterPath)return await K();throw new t.NoFallbackError}}let L=null;!J||y.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===y.isDev||!J,N=J&&!M;H&&G&&(0,j.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,i.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,h.getRequestMeta)(a,"minimalMode"),T=(0,h.getRequestMeta)(a,"incrementalCache")||await y.getIncrementalCache(a,x,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:w,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!x.experimental.authInterrupts},cacheComponents:!!x.cacheComponents,supportsDynamicResponse:M,incrementalCache:T,cacheLifeProfiles:x.cacheLife,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>y.onRequestError(a,b,d,e,C)},sharedContext:{buildId:g,deploymentId:v}},V=new l.NodeNextRequest(a),W=new l.NodeNextResponse(b),X=m.NextRequestAdapter.fromNodeNextRequest(V,(0,m.signalFromNodeResponse)(b));try{let e,g=async a=>y.handle(X,U).finally(()=>{if(!a)return;a.setAttributes({"http.status_code":b.statusCode,"next.rsc":!1});let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==n.BaseServerSpan.handleRequest)return void console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let f=c.get("next.route");if(f){let b=`${O} ${f}`;a.setAttributes({"next.route":f,"http.route":f,"next.span_name":b}),a.updateName(b),e&&e!==a&&(e.setAttribute("http.route",f),e.updateName(b))}else a.updateName(`${O} ${d}`)}),h=async e=>{var h,i;let j=async({previousCacheEntry:f})=>{try{if(!S&&D&&E&&!f)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await g(e);a.fetchMetrics=U.renderOpts.fetchMetrics;let h=U.renderOpts.pendingWaitUntil;h&&c.waitUntil&&(c.waitUntil(h),h=void 0);let i=U.renderOpts.collectedTags;if(!J)return await (0,p.I)(V,W,d,U.renderOpts.pendingWaitUntil),null;{let a=await d.blob(),b=(0,q.toNodeOutgoingHttpHeaders)(d.headers);i&&(b[s.NEXT_CACHE_TAGS_HEADER]=i),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=s.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=s.INFINITE_CACHE?void 0:U.renderOpts.collectedExpire;return{value:{kind:u.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==f?void 0:f.isStale)&&await y.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},k=await y.handleResponse({req:a,nextConfig:x,cacheKey:L,routeKind:f.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:j,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return null;if((null==k||null==(h=k.value)?void 0:h.kind)!==u.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==k||null==(i=k.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":k.isMiss?"MISS":k.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let l=(0,q.fromNodeOutgoingHttpHeaders)(k.value.headers);return S&&J||l.delete(s.NEXT_CACHE_TAGS_HEADER),!k.cacheControl||b.getHeader("Cache-Control")||l.get("Cache-Control")||l.set("Cache-Control",(0,r.getCacheControlHeader)(k.cacheControl)),await (0,p.I)(V,W,new Response(k.value.body,{headers:l,status:k.value.status||200})),null};R&&Q?await h(Q):(e=P.getActiveScopeSpan(),await P.withPropagatedContext(a.headers,()=>P.trace(n.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:i.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},h),void 0,!R))}catch(b){if(b instanceof t.NoFallbackError||await y.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;return await (0,p.I)(V,W,new Response(null,{status:500})),null}}},29294:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},39006:a=>{"use strict";a.exports={rE:"0.4.
|
|
7
|
+
`))}catch{e()}},c.on("line",d.send),c.on("clear",d.sendClear),d.keepalive=setInterval(()=>{if(d.closed)return void clearInterval(d.keepalive);try{a.enqueue(b.encode(": ping\n\n"))}catch{e()}},25e3)},cancel(){e()}}),{headers:{"Content-Type":"text/event-stream","Cache-Control":"no-cache",Connection:"keep-alive"}})}(0,v.wJ)();let y=new e.AppRouteRouteModule({definition:{kind:f.RouteKind.APP_ROUTE,page:"/api/translator/console-logs/stream/route",pathname:"/api/translator/console-logs/stream",filename:"route",bundlePath:"app/api/translator/console-logs/stream/route"},distDir:".next-cli-build",relativeProjectDir:"",resolvedPagePath:"/home/itsazni/projects/scripts/9router/src/app/api/translator/console-logs/stream/route.js",nextConfigOutput:"standalone",userland:d,...{}}),{workAsyncStorage:z,workUnitAsyncStorage:A,serverHooks:B}=y;function C(){return(0,g.patchFetch)({workAsyncStorage:z,workUnitAsyncStorage:A})}async function D(a,b,c){c.requestMeta&&(0,h.setRequestMeta)(a,c.requestMeta),y.isDev&&(0,h.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/translator/console-logs/stream/route";"/index"===d&&(d="/");let e=await y.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!e)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:g,deploymentId:v,params:w,nextConfig:x,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=e,I=(0,k.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(x.adapterPath)return await K();throw new t.NoFallbackError}}let L=null;!J||y.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===y.isDev||!J,N=J&&!M;H&&G&&(0,j.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,i.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,h.getRequestMeta)(a,"minimalMode"),T=(0,h.getRequestMeta)(a,"incrementalCache")||await y.getIncrementalCache(a,x,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:w,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!x.experimental.authInterrupts},cacheComponents:!!x.cacheComponents,supportsDynamicResponse:M,incrementalCache:T,cacheLifeProfiles:x.cacheLife,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>y.onRequestError(a,b,d,e,C)},sharedContext:{buildId:g,deploymentId:v}},V=new l.NodeNextRequest(a),W=new l.NodeNextResponse(b),X=m.NextRequestAdapter.fromNodeNextRequest(V,(0,m.signalFromNodeResponse)(b));try{let e,g=async a=>y.handle(X,U).finally(()=>{if(!a)return;a.setAttributes({"http.status_code":b.statusCode,"next.rsc":!1});let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==n.BaseServerSpan.handleRequest)return void console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let f=c.get("next.route");if(f){let b=`${O} ${f}`;a.setAttributes({"next.route":f,"http.route":f,"next.span_name":b}),a.updateName(b),e&&e!==a&&(e.setAttribute("http.route",f),e.updateName(b))}else a.updateName(`${O} ${d}`)}),h=async e=>{var h,i;let j=async({previousCacheEntry:f})=>{try{if(!S&&D&&E&&!f)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await g(e);a.fetchMetrics=U.renderOpts.fetchMetrics;let h=U.renderOpts.pendingWaitUntil;h&&c.waitUntil&&(c.waitUntil(h),h=void 0);let i=U.renderOpts.collectedTags;if(!J)return await (0,p.I)(V,W,d,U.renderOpts.pendingWaitUntil),null;{let a=await d.blob(),b=(0,q.toNodeOutgoingHttpHeaders)(d.headers);i&&(b[s.NEXT_CACHE_TAGS_HEADER]=i),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=s.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=s.INFINITE_CACHE?void 0:U.renderOpts.collectedExpire;return{value:{kind:u.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==f?void 0:f.isStale)&&await y.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},k=await y.handleResponse({req:a,nextConfig:x,cacheKey:L,routeKind:f.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:j,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return null;if((null==k||null==(h=k.value)?void 0:h.kind)!==u.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==k||null==(i=k.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":k.isMiss?"MISS":k.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let l=(0,q.fromNodeOutgoingHttpHeaders)(k.value.headers);return S&&J||l.delete(s.NEXT_CACHE_TAGS_HEADER),!k.cacheControl||b.getHeader("Cache-Control")||l.get("Cache-Control")||l.set("Cache-Control",(0,r.getCacheControlHeader)(k.cacheControl)),await (0,p.I)(V,W,new Response(k.value.body,{headers:l,status:k.value.status||200})),null};R&&Q?await h(Q):(e=P.getActiveScopeSpan(),await P.withPropagatedContext(a.headers,()=>P.trace(n.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:i.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},h),void 0,!R))}catch(b){if(b instanceof t.NoFallbackError||await y.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;return await (0,p.I)(V,W,new Response(null,{status:500})),null}}},29294:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},39006:a=>{"use strict";a.exports={rE:"0.4.53"}},44870:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},46715:(a,b,c)=>{"use strict";c.d(b,{UY:()=>h,X3:()=>i,eh:()=>f.eh,fg:()=>e.fg,h0:()=>g});var d=c(39006),e=c(3811),f=c(75491);d.rE;let g={npmPackageName:"9router",installCmd:"npm i -g 9router",installCmdLatest:"npm i -g 9router@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:20128},h={maxLines:200,pollIntervalMs:1e3},i={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"}},52064:()=>{},63033:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},71832:(a,b,c)=>{"use strict";a.exports=c(44870)},75491:(a,b,c)=>{"use strict";c.d(b,{Xg:()=>d.Xg,eh:()=>e,vq:()=>d.vq});var d=c(17785);Object.entries(c(3811).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})))},86439:a=>{"use strict";a.exports=require("next/dist/shared/lib/no-fallback-error.external")},94735:a=>{"use strict";a.exports=require("events")}};var b=require("../../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[7426,3811,7785],()=>b(b.s=26305));module.exports=c})();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(()=>{var a={};a.id=2922,a.ids=[2922],a.modules={261:a=>{"use strict";a.exports=require("next/dist/shared/lib/router/utils/app-paths")},10846:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},15616:()=>{},19133:(a,b,c)=>{"use strict";Object.defineProperty(b,"I",{enumerable:!0,get:function(){return g}});let d=c(28485),e=c(32336),f=c(45391);async function g(a,b,c,g){if((0,d.isNodeNextResponse)(b)){var h;b.statusCode=c.status,b.statusMessage=c.statusText;let d=["set-cookie","www-authenticate","proxy-authenticate","vary"];null==(h=c.headers)||h.forEach((a,c)=>{if("x-middleware-set-cookie"!==c.toLowerCase())if("set-cookie"===c.toLowerCase())for(let d of(0,f.splitCookiesString)(a))b.appendHeader(c,d);else{let e=void 0!==b.getHeader(c);(d.includes(c.toLowerCase())||!e)&&b.appendHeader(c,a)}});let{originalResponse:i}=b;c.body&&"HEAD"!==a.method?await (0,e.pipeToNodeResponse)(c.body,i,g):i.end()}}},29294:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},39006:a=>{"use strict";a.exports={rE:"0.4.
|
|
1
|
+
(()=>{var a={};a.id=2922,a.ids=[2922],a.modules={261:a=>{"use strict";a.exports=require("next/dist/shared/lib/router/utils/app-paths")},10846:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},15616:()=>{},19133:(a,b,c)=>{"use strict";Object.defineProperty(b,"I",{enumerable:!0,get:function(){return g}});let d=c(28485),e=c(32336),f=c(45391);async function g(a,b,c,g){if((0,d.isNodeNextResponse)(b)){var h;b.statusCode=c.status,b.statusMessage=c.statusText;let d=["set-cookie","www-authenticate","proxy-authenticate","vary"];null==(h=c.headers)||h.forEach((a,c)=>{if("x-middleware-set-cookie"!==c.toLowerCase())if("set-cookie"===c.toLowerCase())for(let d of(0,f.splitCookiesString)(a))b.appendHeader(c,d);else{let e=void 0!==b.getHeader(c);(d.includes(c.toLowerCase())||!e)&&b.appendHeader(c,a)}});let{originalResponse:i}=b;c.body&&"HEAD"!==a.method?await (0,e.pipeToNodeResponse)(c.body,i,g):i.end()}}},29294:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},39006:a=>{"use strict";a.exports={rE:"0.4.53"}},44870:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},52064:()=>{},55591:a=>{"use strict";a.exports=require("https")},56294:(a,b,c)=>{"use strict";c.r(b),c.d(b,{handler:()=>E,patchFetch:()=>D,routeModule:()=>z,serverHooks:()=>C,workAsyncStorage:()=>A,workUnitAsyncStorage:()=>B});var d={};c.r(d),c.d(d,{GET:()=>y});var e=c(71832),f=c(43805),g=c(93004),h=c(98942),i=c(2052),j=c(43404),k=c(261),l=c(21330),m=c(54832),n=c(85968),o=c(32163),p=c(19133),q=c(45391),r=c(62033),s=c(58742),t=c(86439),u=c(42108),v=c(55591),w=c.n(v),x=c(39006);async function y(){let a=await new Promise(a=>{let b=w().get("https://registry.npmjs.org/9router/latest",{timeout:4e3},b=>{let c="";b.on("data",a=>c+=a),b.on("end",()=>{try{a(JSON.parse(c).version||null)}catch{a(null)}})});b.on("error",()=>a(null)),b.on("timeout",()=>{b.destroy(),a(null)})}),b=x.rE,c=!!a&&function(a,b){let c=a.split(".").map(Number),d=b.split(".").map(Number);for(let a=0;a<3;a++){if(c[a]>d[a])return 1;if(c[a]<d[a])return -1}return 0}(a,b)>0;return Response.json({currentVersion:b,latestVersion:a,hasUpdate:c})}let z=new e.AppRouteRouteModule({definition:{kind:f.RouteKind.APP_ROUTE,page:"/api/version/route",pathname:"/api/version",filename:"route",bundlePath:"app/api/version/route"},distDir:".next-cli-build",relativeProjectDir:"",resolvedPagePath:"/home/itsazni/projects/scripts/9router/src/app/api/version/route.js",nextConfigOutput:"standalone",userland:d,...{}}),{workAsyncStorage:A,workUnitAsyncStorage:B,serverHooks:C}=z;function D(){return(0,g.patchFetch)({workAsyncStorage:A,workUnitAsyncStorage:B})}async function E(a,b,c){c.requestMeta&&(0,h.setRequestMeta)(a,c.requestMeta),z.isDev&&(0,h.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/version/route";"/index"===d&&(d="/");let e=await z.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!e)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:g,deploymentId:v,params:w,nextConfig:x,parsedUrl:y,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=e,I=(0,k.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,y,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(x.adapterPath)return await K();throw new t.NoFallbackError}}let L=null;!J||z.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===z.isDev||!J,N=J&&!M;H&&G&&(0,j.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,i.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,h.getRequestMeta)(a,"minimalMode"),T=(0,h.getRequestMeta)(a,"incrementalCache")||await z.getIncrementalCache(a,x,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:w,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!x.experimental.authInterrupts},cacheComponents:!!x.cacheComponents,supportsDynamicResponse:M,incrementalCache:T,cacheLifeProfiles:x.cacheLife,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>z.onRequestError(a,b,d,e,C)},sharedContext:{buildId:g,deploymentId:v}},V=new l.NodeNextRequest(a),W=new l.NodeNextResponse(b),X=m.NextRequestAdapter.fromNodeNextRequest(V,(0,m.signalFromNodeResponse)(b));try{let e,g=async a=>z.handle(X,U).finally(()=>{if(!a)return;a.setAttributes({"http.status_code":b.statusCode,"next.rsc":!1});let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==n.BaseServerSpan.handleRequest)return void console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let f=c.get("next.route");if(f){let b=`${O} ${f}`;a.setAttributes({"next.route":f,"http.route":f,"next.span_name":b}),a.updateName(b),e&&e!==a&&(e.setAttribute("http.route",f),e.updateName(b))}else a.updateName(`${O} ${d}`)}),h=async e=>{var h,i;let j=async({previousCacheEntry:f})=>{try{if(!S&&D&&E&&!f)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await g(e);a.fetchMetrics=U.renderOpts.fetchMetrics;let h=U.renderOpts.pendingWaitUntil;h&&c.waitUntil&&(c.waitUntil(h),h=void 0);let i=U.renderOpts.collectedTags;if(!J)return await (0,p.I)(V,W,d,U.renderOpts.pendingWaitUntil),null;{let a=await d.blob(),b=(0,q.toNodeOutgoingHttpHeaders)(d.headers);i&&(b[s.NEXT_CACHE_TAGS_HEADER]=i),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=s.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=s.INFINITE_CACHE?void 0:U.renderOpts.collectedExpire;return{value:{kind:u.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==f?void 0:f.isStale)&&await z.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},k=await z.handleResponse({req:a,nextConfig:x,cacheKey:L,routeKind:f.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:j,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return null;if((null==k||null==(h=k.value)?void 0:h.kind)!==u.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==k||null==(i=k.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":k.isMiss?"MISS":k.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let l=(0,q.fromNodeOutgoingHttpHeaders)(k.value.headers);return S&&J||l.delete(s.NEXT_CACHE_TAGS_HEADER),!k.cacheControl||b.getHeader("Cache-Control")||l.get("Cache-Control")||l.set("Cache-Control",(0,r.getCacheControlHeader)(k.cacheControl)),await (0,p.I)(V,W,new Response(k.value.body,{headers:l,status:k.value.status||200})),null};R&&Q?await h(Q):(e=P.getActiveScopeSpan(),await P.withPropagatedContext(a.headers,()=>P.trace(n.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:i.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},h),void 0,!R))}catch(b){if(b instanceof t.NoFallbackError||await z.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;return await (0,p.I)(V,W,new Response(null,{status:500})),null}}},63033:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},71832:(a,b,c)=>{"use strict";a.exports=c(44870)},86439:a=>{"use strict";a.exports=require("next/dist/shared/lib/no-fallback-error.external")}};var b=require("../../../webpack-runtime.js");b.C(a);var c=b.X(0,[7426],()=>b(b.s=56294));module.exports=c})();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(()=>{var a={};a.id=1907,a.ids=[1907],a.modules={261:a=>{"use strict";a.exports=require("next/dist/shared/lib/router/utils/app-paths")},3295:a=>{"use strict";a.exports=require("next/dist/server/app-render/after-task-async-storage.external.js")},10846:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},15616:()=>{},21820:a=>{"use strict";a.exports=require("os")},29021:a=>{"use strict";a.exports=require("fs")},29294:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},33873:a=>{"use strict";a.exports=require("path")},39006:a=>{"use strict";a.exports={rE:"0.4.52"}},43640:(a,b,c)=>{"use strict";c.r(b),c.d(b,{handler:()=>D,patchFetch:()=>C,routeModule:()=>y,serverHooks:()=>B,workAsyncStorage:()=>z,workUnitAsyncStorage:()=>A});var d={};c.r(d),c.d(d,{POST:()=>x});var e=c(71832),f=c(43805),g=c(93004),h=c(98942),i=c(2052),j=c(43404),k=c(261),l=c(21330),m=c(54832),n=c(85968),o=c(32163),p=c(19133),q=c(45391),r=c(62033),s=c(58742),t=c(86439),u=c(42108),v=c(3601),w=c(45769);async function x(){try{await (0,w.l)()}catch{}let a=v.NextResponse.json({success:!0,message:"Shutting down for manual update..."});return setTimeout(()=>process.exit(0),500),a}let y=new e.AppRouteRouteModule({definition:{kind:f.RouteKind.APP_ROUTE,page:"/api/version/shutdown/route",pathname:"/api/version/shutdown",filename:"route",bundlePath:"app/api/version/shutdown/route"},distDir:".next-cli-build",relativeProjectDir:"",resolvedPagePath:"/home/itsazni/projects/scripts/9router/src/app/api/version/shutdown/route.js",nextConfigOutput:"standalone",userland:d,...{}}),{workAsyncStorage:z,workUnitAsyncStorage:A,serverHooks:B}=y;function C(){return(0,g.patchFetch)({workAsyncStorage:z,workUnitAsyncStorage:A})}async function D(a,b,c){c.requestMeta&&(0,h.setRequestMeta)(a,c.requestMeta),y.isDev&&(0,h.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/version/shutdown/route";"/index"===d&&(d="/");let e=await y.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!e)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:g,deploymentId:v,params:w,nextConfig:x,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=e,I=(0,k.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(x.adapterPath)return await K();throw new t.NoFallbackError}}let L=null;!J||y.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===y.isDev||!J,N=J&&!M;H&&G&&(0,j.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,i.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,h.getRequestMeta)(a,"minimalMode"),T=(0,h.getRequestMeta)(a,"incrementalCache")||await y.getIncrementalCache(a,x,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:w,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!x.experimental.authInterrupts},cacheComponents:!!x.cacheComponents,supportsDynamicResponse:M,incrementalCache:T,cacheLifeProfiles:x.cacheLife,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>y.onRequestError(a,b,d,e,C)},sharedContext:{buildId:g,deploymentId:v}},V=new l.NodeNextRequest(a),W=new l.NodeNextResponse(b),X=m.NextRequestAdapter.fromNodeNextRequest(V,(0,m.signalFromNodeResponse)(b));try{let e,g=async a=>y.handle(X,U).finally(()=>{if(!a)return;a.setAttributes({"http.status_code":b.statusCode,"next.rsc":!1});let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==n.BaseServerSpan.handleRequest)return void console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let f=c.get("next.route");if(f){let b=`${O} ${f}`;a.setAttributes({"next.route":f,"http.route":f,"next.span_name":b}),a.updateName(b),e&&e!==a&&(e.setAttribute("http.route",f),e.updateName(b))}else a.updateName(`${O} ${d}`)}),h=async e=>{var h,i;let j=async({previousCacheEntry:f})=>{try{if(!S&&D&&E&&!f)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await g(e);a.fetchMetrics=U.renderOpts.fetchMetrics;let h=U.renderOpts.pendingWaitUntil;h&&c.waitUntil&&(c.waitUntil(h),h=void 0);let i=U.renderOpts.collectedTags;if(!J)return await (0,p.I)(V,W,d,U.renderOpts.pendingWaitUntil),null;{let a=await d.blob(),b=(0,q.toNodeOutgoingHttpHeaders)(d.headers);i&&(b[s.NEXT_CACHE_TAGS_HEADER]=i),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=s.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=s.INFINITE_CACHE?void 0:U.renderOpts.collectedExpire;return{value:{kind:u.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==f?void 0:f.isStale)&&await y.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},k=await y.handleResponse({req:a,nextConfig:x,cacheKey:L,routeKind:f.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:j,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return null;if((null==k||null==(h=k.value)?void 0:h.kind)!==u.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==k||null==(i=k.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":k.isMiss?"MISS":k.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let l=(0,q.fromNodeOutgoingHttpHeaders)(k.value.headers);return S&&J||l.delete(s.NEXT_CACHE_TAGS_HEADER),!k.cacheControl||b.getHeader("Cache-Control")||l.get("Cache-Control")||l.set("Cache-Control",(0,r.getCacheControlHeader)(k.cacheControl)),await (0,p.I)(V,W,new Response(k.value.body,{headers:l,status:k.value.status||200})),null};R&&Q?await h(Q):(e=P.getActiveScopeSpan(),await P.withPropagatedContext(a.headers,()=>P.trace(n.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:i.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},h),void 0,!R))}catch(b){if(b instanceof t.NoFallbackError||await y.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;return await (0,p.I)(V,W,new Response(null,{status:500})),null}}},44870:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},45769:(a,b,c)=>{"use strict";c.d(b,{g:()=>m,l:()=>l});var d=c(79646),e=c(33873),f=c.n(e),g=c(29021),h=c.n(g),i=c(21820),j=c.n(i),k=c(46715);async function l(){!function(){try{let a=f().join("win32"===process.platform?f().join(process.env.APPDATA||"","9router"):f().join(j().homedir(),".9router"),"mitm",".mitm.pid");if(!h().existsSync(a))return;let b=parseInt(h().readFileSync(a,"utf8").trim(),10);if(!b)return;if("win32"===process.platform)try{(0,d.execSync)(`taskkill /F /T /PID ${b}`,{stdio:"ignore",windowsHide:!0,timeout:3e3})}catch{try{(0,d.execSync)(`powershell -NonInteractive -WindowStyle Hidden -Command "Stop-Process -Id ${b} -Force"`,{stdio:"ignore",windowsHide:!0,timeout:3e3})}catch{}}else try{(0,d.execSync)(`sudo -n kill -9 ${b} 2>/dev/null`,{stdio:"ignore",timeout:3e3})}catch{try{process.kill(b,"SIGKILL")}catch{}}try{h().unlinkSync(a)}catch{}}catch{}}();let a=function(){let a=[];if("win32"===process.platform){try{(0,d.execSync)('powershell -NonInteractive -WindowStyle Hidden -Command "Get-WmiObject Win32_Process -Filter \'Name=\\"node.exe\\"\' | Select-Object ProcessId,CommandLine | ConvertTo-Csv -NoTypeInformation"',{encoding:"utf8",windowsHide:!0,timeout:5e3}).split("\n").slice(1).filter(a=>a.trim()).forEach(b=>{let c=b.toLowerCase();if(c.includes("9router")||c.includes("next-server")||c.includes("\\bin\\app\\")||c.includes("/bin/app/")||c.includes("cli.js")){let c=b.match(/^"(\d+)"/);c&&c[1]&&c[1]!==process.pid.toString()&&a.push(c[1])}})}catch{}for(let b of["cloudflared","tray_windows_release"])try{let c=`powershell -NonInteractive -WindowStyle Hidden -Command "Get-Process ${b} -ErrorAction SilentlyContinue | Select-Object -ExpandProperty Id"`;(0,d.execSync)(c,{encoding:"utf8",windowsHide:!0,timeout:5e3}).split("\n").forEach(b=>{let c=b.trim();c&&!isNaN(c)&&a.push(c)})}catch{}}else try{(0,d.execSync)("ps aux 2>/dev/null",{encoding:"utf8",timeout:5e3}).split("\n").forEach(b=>{if(b.includes("9router")||b.includes("next-server")||b.includes("cloudflared")||b.includes("/bin/app/")||b.includes("tray_darwin")||b.includes("tray_linux")){let c=b.trim().split(/\s+/)[1];c&&!isNaN(c)&&c!==process.pid.toString()&&a.push(c)}})}catch{}return a}(),b=process.platform;a.forEach(a=>{try{"win32"===b?(0,d.execSync)(`taskkill /F /PID ${a} 2>nul`,{stdio:"ignore",shell:!0,windowsHide:!0,timeout:3e3}):(0,d.execSync)(`kill -9 ${a} 2>/dev/null`,{stdio:"ignore",timeout:3e3})}catch{}}),a.length>0&&await new Promise(a=>setTimeout(a,1500))}function m(a=k.h0.npmPackageName){let b=function(a){try{if(!a||!h().existsSync(a))return a;let b=f().join(process.env.DATA_DIR?process.env.DATA_DIR:"win32"===process.platform?f().join(process.env.APPDATA||f().join(j().homedir(),"AppData","Roaming"),"9router"):f().join(j().homedir(),".9router"),"runtime","updater"),c=f().join(b,"updater.js");if(h().existsSync(c))try{if(h().statSync(a).size===h().statSync(c).size)return c}catch{}return h().mkdirSync(b,{recursive:!0}),h().copyFileSync(a,c),c}catch{return a}}(function(){if(process.env.UPDATER_SCRIPT_PATH&&h().existsSync(process.env.UPDATER_SCRIPT_PATH))return process.env.UPDATER_SCRIPT_PATH;let a=f().join(process.cwd(),"src","lib","updater","updater.js");if(h().existsSync(a))return a;let b=f().join(process.cwd(),"..","src","lib","updater","updater.js");return h().existsSync(b)?b:a}()),c="1"===process.env.TRAY_MODE,e={cmd:"win32"===process.platform?"npx.cmd":"npx",args:[k.h0.npmPackageName]},g=c?[...e.args,"--tray","--skip-update"]:[...e.args,"--skip-update"];(0,d.spawn)(process.execPath,[b],{detached:!0,stdio:"ignore",windowsHide:!0,env:{...process.env,UPDATER_PKG_NAME:a,UPDATER_PORT:String(k.h0.statusPort),UPDATER_TAIL_LINES:String(k.h0.statusLogTailLines),UPDATER_RETRIES:String(k.h0.installRetries),UPDATER_RETRY_DELAY_MS:String(k.h0.installRetryDelayMs),UPDATER_LINGER_MS:String(k.h0.lingerAfterDoneMs),UPDATER_WAIT_MIN_MS:String(k.h0.waitForExitMinMs),UPDATER_WAIT_MAX_MS:String(k.h0.waitForExitMaxMs),UPDATER_WAIT_CHECK_MS:String(k.h0.waitForExitCheckMs),UPDATER_APP_PORT:String(k.h0.appPort),UPDATER_RELAUNCH:"1",UPDATER_RELAUNCH_CMD:e.cmd,UPDATER_RELAUNCH_ARGS:JSON.stringify(g)}}).unref(),setTimeout(()=>process.exit(0),k.h0.exitDelayMs)}},46715:(a,b,c)=>{"use strict";c.d(b,{UY:()=>h,X3:()=>i,eh:()=>f.eh,fg:()=>e.fg,h0:()=>g});var d=c(39006),e=c(3811),f=c(75491);d.rE;let g={npmPackageName:"9router",installCmd:"npm i -g 9router",installCmdLatest:"npm i -g 9router@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:20128},h={maxLines:200,pollIntervalMs:1e3},i={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"}},52064:()=>{},63033:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},75491:(a,b,c)=>{"use strict";c.d(b,{Xg:()=>d.Xg,eh:()=>e,vq:()=>d.vq});var d=c(17785);Object.entries(c(3811).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})))},79646:a=>{"use strict";a.exports=require("child_process")},86439:a=>{"use strict";a.exports=require("next/dist/shared/lib/no-fallback-error.external")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[7426,9004,3811,7785],()=>b(b.s=43640));module.exports=c})();
|
|
1
|
+
(()=>{var a={};a.id=1907,a.ids=[1907],a.modules={261:a=>{"use strict";a.exports=require("next/dist/shared/lib/router/utils/app-paths")},3295:a=>{"use strict";a.exports=require("next/dist/server/app-render/after-task-async-storage.external.js")},10846:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},15616:()=>{},21820:a=>{"use strict";a.exports=require("os")},29021:a=>{"use strict";a.exports=require("fs")},29294:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},33873:a=>{"use strict";a.exports=require("path")},39006:a=>{"use strict";a.exports={rE:"0.4.53"}},43640:(a,b,c)=>{"use strict";c.r(b),c.d(b,{handler:()=>D,patchFetch:()=>C,routeModule:()=>y,serverHooks:()=>B,workAsyncStorage:()=>z,workUnitAsyncStorage:()=>A});var d={};c.r(d),c.d(d,{POST:()=>x});var e=c(71832),f=c(43805),g=c(93004),h=c(98942),i=c(2052),j=c(43404),k=c(261),l=c(21330),m=c(54832),n=c(85968),o=c(32163),p=c(19133),q=c(45391),r=c(62033),s=c(58742),t=c(86439),u=c(42108),v=c(3601),w=c(45769);async function x(){try{await (0,w.l)()}catch{}let a=v.NextResponse.json({success:!0,message:"Shutting down for manual update..."});return setTimeout(()=>process.exit(0),500),a}let y=new e.AppRouteRouteModule({definition:{kind:f.RouteKind.APP_ROUTE,page:"/api/version/shutdown/route",pathname:"/api/version/shutdown",filename:"route",bundlePath:"app/api/version/shutdown/route"},distDir:".next-cli-build",relativeProjectDir:"",resolvedPagePath:"/home/itsazni/projects/scripts/9router/src/app/api/version/shutdown/route.js",nextConfigOutput:"standalone",userland:d,...{}}),{workAsyncStorage:z,workUnitAsyncStorage:A,serverHooks:B}=y;function C(){return(0,g.patchFetch)({workAsyncStorage:z,workUnitAsyncStorage:A})}async function D(a,b,c){c.requestMeta&&(0,h.setRequestMeta)(a,c.requestMeta),y.isDev&&(0,h.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/version/shutdown/route";"/index"===d&&(d="/");let e=await y.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!e)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:g,deploymentId:v,params:w,nextConfig:x,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=e,I=(0,k.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(x.adapterPath)return await K();throw new t.NoFallbackError}}let L=null;!J||y.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===y.isDev||!J,N=J&&!M;H&&G&&(0,j.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,i.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,h.getRequestMeta)(a,"minimalMode"),T=(0,h.getRequestMeta)(a,"incrementalCache")||await y.getIncrementalCache(a,x,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:w,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!x.experimental.authInterrupts},cacheComponents:!!x.cacheComponents,supportsDynamicResponse:M,incrementalCache:T,cacheLifeProfiles:x.cacheLife,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>y.onRequestError(a,b,d,e,C)},sharedContext:{buildId:g,deploymentId:v}},V=new l.NodeNextRequest(a),W=new l.NodeNextResponse(b),X=m.NextRequestAdapter.fromNodeNextRequest(V,(0,m.signalFromNodeResponse)(b));try{let e,g=async a=>y.handle(X,U).finally(()=>{if(!a)return;a.setAttributes({"http.status_code":b.statusCode,"next.rsc":!1});let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==n.BaseServerSpan.handleRequest)return void console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let f=c.get("next.route");if(f){let b=`${O} ${f}`;a.setAttributes({"next.route":f,"http.route":f,"next.span_name":b}),a.updateName(b),e&&e!==a&&(e.setAttribute("http.route",f),e.updateName(b))}else a.updateName(`${O} ${d}`)}),h=async e=>{var h,i;let j=async({previousCacheEntry:f})=>{try{if(!S&&D&&E&&!f)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await g(e);a.fetchMetrics=U.renderOpts.fetchMetrics;let h=U.renderOpts.pendingWaitUntil;h&&c.waitUntil&&(c.waitUntil(h),h=void 0);let i=U.renderOpts.collectedTags;if(!J)return await (0,p.I)(V,W,d,U.renderOpts.pendingWaitUntil),null;{let a=await d.blob(),b=(0,q.toNodeOutgoingHttpHeaders)(d.headers);i&&(b[s.NEXT_CACHE_TAGS_HEADER]=i),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=s.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=s.INFINITE_CACHE?void 0:U.renderOpts.collectedExpire;return{value:{kind:u.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==f?void 0:f.isStale)&&await y.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},k=await y.handleResponse({req:a,nextConfig:x,cacheKey:L,routeKind:f.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:j,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return null;if((null==k||null==(h=k.value)?void 0:h.kind)!==u.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==k||null==(i=k.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":k.isMiss?"MISS":k.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let l=(0,q.fromNodeOutgoingHttpHeaders)(k.value.headers);return S&&J||l.delete(s.NEXT_CACHE_TAGS_HEADER),!k.cacheControl||b.getHeader("Cache-Control")||l.get("Cache-Control")||l.set("Cache-Control",(0,r.getCacheControlHeader)(k.cacheControl)),await (0,p.I)(V,W,new Response(k.value.body,{headers:l,status:k.value.status||200})),null};R&&Q?await h(Q):(e=P.getActiveScopeSpan(),await P.withPropagatedContext(a.headers,()=>P.trace(n.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:i.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},h),void 0,!R))}catch(b){if(b instanceof t.NoFallbackError||await y.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;return await (0,p.I)(V,W,new Response(null,{status:500})),null}}},44870:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},45769:(a,b,c)=>{"use strict";c.d(b,{g:()=>m,l:()=>l});var d=c(79646),e=c(33873),f=c.n(e),g=c(29021),h=c.n(g),i=c(21820),j=c.n(i),k=c(46715);async function l(){!function(){try{let a=f().join("win32"===process.platform?f().join(process.env.APPDATA||"","9router"):f().join(j().homedir(),".9router"),"mitm",".mitm.pid");if(!h().existsSync(a))return;let b=parseInt(h().readFileSync(a,"utf8").trim(),10);if(!b)return;if("win32"===process.platform)try{(0,d.execSync)(`taskkill /F /T /PID ${b}`,{stdio:"ignore",windowsHide:!0,timeout:3e3})}catch{try{(0,d.execSync)(`powershell -NonInteractive -WindowStyle Hidden -Command "Stop-Process -Id ${b} -Force"`,{stdio:"ignore",windowsHide:!0,timeout:3e3})}catch{}}else try{(0,d.execSync)(`sudo -n kill -9 ${b} 2>/dev/null`,{stdio:"ignore",timeout:3e3})}catch{try{process.kill(b,"SIGKILL")}catch{}}try{h().unlinkSync(a)}catch{}}catch{}}();let a=function(){let a=[];if("win32"===process.platform){try{(0,d.execSync)('powershell -NonInteractive -WindowStyle Hidden -Command "Get-WmiObject Win32_Process -Filter \'Name=\\"node.exe\\"\' | Select-Object ProcessId,CommandLine | ConvertTo-Csv -NoTypeInformation"',{encoding:"utf8",windowsHide:!0,timeout:5e3}).split("\n").slice(1).filter(a=>a.trim()).forEach(b=>{let c=b.toLowerCase();if(c.includes("9router")||c.includes("next-server")||c.includes("\\bin\\app\\")||c.includes("/bin/app/")||c.includes("cli.js")){let c=b.match(/^"(\d+)"/);c&&c[1]&&c[1]!==process.pid.toString()&&a.push(c[1])}})}catch{}for(let b of["cloudflared","tray_windows_release"])try{let c=`powershell -NonInteractive -WindowStyle Hidden -Command "Get-Process ${b} -ErrorAction SilentlyContinue | Select-Object -ExpandProperty Id"`;(0,d.execSync)(c,{encoding:"utf8",windowsHide:!0,timeout:5e3}).split("\n").forEach(b=>{let c=b.trim();c&&!isNaN(c)&&a.push(c)})}catch{}}else try{(0,d.execSync)("ps aux 2>/dev/null",{encoding:"utf8",timeout:5e3}).split("\n").forEach(b=>{if(b.includes("9router")||b.includes("next-server")||b.includes("cloudflared")||b.includes("/bin/app/")||b.includes("tray_darwin")||b.includes("tray_linux")){let c=b.trim().split(/\s+/)[1];c&&!isNaN(c)&&c!==process.pid.toString()&&a.push(c)}})}catch{}return a}(),b=process.platform;a.forEach(a=>{try{"win32"===b?(0,d.execSync)(`taskkill /F /PID ${a} 2>nul`,{stdio:"ignore",shell:!0,windowsHide:!0,timeout:3e3}):(0,d.execSync)(`kill -9 ${a} 2>/dev/null`,{stdio:"ignore",timeout:3e3})}catch{}}),a.length>0&&await new Promise(a=>setTimeout(a,1500))}function m(a=k.h0.npmPackageName){let b=function(a){try{if(!a||!h().existsSync(a))return a;let b=f().join(process.env.DATA_DIR?process.env.DATA_DIR:"win32"===process.platform?f().join(process.env.APPDATA||f().join(j().homedir(),"AppData","Roaming"),"9router"):f().join(j().homedir(),".9router"),"runtime","updater"),c=f().join(b,"updater.js");if(h().existsSync(c))try{if(h().statSync(a).size===h().statSync(c).size)return c}catch{}return h().mkdirSync(b,{recursive:!0}),h().copyFileSync(a,c),c}catch{return a}}(function(){if(process.env.UPDATER_SCRIPT_PATH&&h().existsSync(process.env.UPDATER_SCRIPT_PATH))return process.env.UPDATER_SCRIPT_PATH;let a=f().join(process.cwd(),"src","lib","updater","updater.js");if(h().existsSync(a))return a;let b=f().join(process.cwd(),"..","src","lib","updater","updater.js");return h().existsSync(b)?b:a}()),c="1"===process.env.TRAY_MODE,e={cmd:"win32"===process.platform?"npx.cmd":"npx",args:[k.h0.npmPackageName]},g=c?[...e.args,"--tray","--skip-update"]:[...e.args,"--skip-update"];(0,d.spawn)(process.execPath,[b],{detached:!0,stdio:"ignore",windowsHide:!0,env:{...process.env,UPDATER_PKG_NAME:a,UPDATER_PORT:String(k.h0.statusPort),UPDATER_TAIL_LINES:String(k.h0.statusLogTailLines),UPDATER_RETRIES:String(k.h0.installRetries),UPDATER_RETRY_DELAY_MS:String(k.h0.installRetryDelayMs),UPDATER_LINGER_MS:String(k.h0.lingerAfterDoneMs),UPDATER_WAIT_MIN_MS:String(k.h0.waitForExitMinMs),UPDATER_WAIT_MAX_MS:String(k.h0.waitForExitMaxMs),UPDATER_WAIT_CHECK_MS:String(k.h0.waitForExitCheckMs),UPDATER_APP_PORT:String(k.h0.appPort),UPDATER_RELAUNCH:"1",UPDATER_RELAUNCH_CMD:e.cmd,UPDATER_RELAUNCH_ARGS:JSON.stringify(g)}}).unref(),setTimeout(()=>process.exit(0),k.h0.exitDelayMs)}},46715:(a,b,c)=>{"use strict";c.d(b,{UY:()=>h,X3:()=>i,eh:()=>f.eh,fg:()=>e.fg,h0:()=>g});var d=c(39006),e=c(3811),f=c(75491);d.rE;let g={npmPackageName:"9router",installCmd:"npm i -g 9router",installCmdLatest:"npm i -g 9router@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:20128},h={maxLines:200,pollIntervalMs:1e3},i={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"}},52064:()=>{},63033:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},75491:(a,b,c)=>{"use strict";c.d(b,{Xg:()=>d.Xg,eh:()=>e,vq:()=>d.vq});var d=c(17785);Object.entries(c(3811).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})))},79646:a=>{"use strict";a.exports=require("child_process")},86439:a=>{"use strict";a.exports=require("next/dist/shared/lib/no-fallback-error.external")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[7426,9004,3811,7785],()=>b(b.s=43640));module.exports=c})();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(()=>{var a={};a.id=2198,a.ids=[2198],a.modules={261:a=>{"use strict";a.exports=require("next/dist/shared/lib/router/utils/app-paths")},3295:a=>{"use strict";a.exports=require("next/dist/server/app-render/after-task-async-storage.external.js")},10846:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},13919:(a,b,c)=>{"use strict";c.r(b),c.d(b,{handler:()=>D,patchFetch:()=>C,routeModule:()=>y,serverHooks:()=>B,workAsyncStorage:()=>z,workUnitAsyncStorage:()=>A});var d={};c.r(d),c.d(d,{POST:()=>x});var e=c(71832),f=c(43805),g=c(93004),h=c(98942),i=c(2052),j=c(43404),k=c(261),l=c(21330),m=c(54832),n=c(85968),o=c(32163),p=c(19133),q=c(45391),r=c(62033),s=c(58742),t=c(86439),u=c(42108),v=c(3601),w=c(45769);async function x(){try{await (0,w.l)()}catch{}return(0,w.g)(),v.NextResponse.json({success:!0,message:"Updater started. This app will exit shortly."})}let y=new e.AppRouteRouteModule({definition:{kind:f.RouteKind.APP_ROUTE,page:"/api/version/update/route",pathname:"/api/version/update",filename:"route",bundlePath:"app/api/version/update/route"},distDir:".next-cli-build",relativeProjectDir:"",resolvedPagePath:"/home/itsazni/projects/scripts/9router/src/app/api/version/update/route.js",nextConfigOutput:"standalone",userland:d,...{}}),{workAsyncStorage:z,workUnitAsyncStorage:A,serverHooks:B}=y;function C(){return(0,g.patchFetch)({workAsyncStorage:z,workUnitAsyncStorage:A})}async function D(a,b,c){c.requestMeta&&(0,h.setRequestMeta)(a,c.requestMeta),y.isDev&&(0,h.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/version/update/route";"/index"===d&&(d="/");let e=await y.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!e)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:g,deploymentId:v,params:w,nextConfig:x,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=e,I=(0,k.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(x.adapterPath)return await K();throw new t.NoFallbackError}}let L=null;!J||y.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===y.isDev||!J,N=J&&!M;H&&G&&(0,j.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,i.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,h.getRequestMeta)(a,"minimalMode"),T=(0,h.getRequestMeta)(a,"incrementalCache")||await y.getIncrementalCache(a,x,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:w,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!x.experimental.authInterrupts},cacheComponents:!!x.cacheComponents,supportsDynamicResponse:M,incrementalCache:T,cacheLifeProfiles:x.cacheLife,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>y.onRequestError(a,b,d,e,C)},sharedContext:{buildId:g,deploymentId:v}},V=new l.NodeNextRequest(a),W=new l.NodeNextResponse(b),X=m.NextRequestAdapter.fromNodeNextRequest(V,(0,m.signalFromNodeResponse)(b));try{let e,g=async a=>y.handle(X,U).finally(()=>{if(!a)return;a.setAttributes({"http.status_code":b.statusCode,"next.rsc":!1});let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==n.BaseServerSpan.handleRequest)return void console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let f=c.get("next.route");if(f){let b=`${O} ${f}`;a.setAttributes({"next.route":f,"http.route":f,"next.span_name":b}),a.updateName(b),e&&e!==a&&(e.setAttribute("http.route",f),e.updateName(b))}else a.updateName(`${O} ${d}`)}),h=async e=>{var h,i;let j=async({previousCacheEntry:f})=>{try{if(!S&&D&&E&&!f)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await g(e);a.fetchMetrics=U.renderOpts.fetchMetrics;let h=U.renderOpts.pendingWaitUntil;h&&c.waitUntil&&(c.waitUntil(h),h=void 0);let i=U.renderOpts.collectedTags;if(!J)return await (0,p.I)(V,W,d,U.renderOpts.pendingWaitUntil),null;{let a=await d.blob(),b=(0,q.toNodeOutgoingHttpHeaders)(d.headers);i&&(b[s.NEXT_CACHE_TAGS_HEADER]=i),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=s.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=s.INFINITE_CACHE?void 0:U.renderOpts.collectedExpire;return{value:{kind:u.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==f?void 0:f.isStale)&&await y.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},k=await y.handleResponse({req:a,nextConfig:x,cacheKey:L,routeKind:f.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:j,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return null;if((null==k||null==(h=k.value)?void 0:h.kind)!==u.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==k||null==(i=k.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":k.isMiss?"MISS":k.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let l=(0,q.fromNodeOutgoingHttpHeaders)(k.value.headers);return S&&J||l.delete(s.NEXT_CACHE_TAGS_HEADER),!k.cacheControl||b.getHeader("Cache-Control")||l.get("Cache-Control")||l.set("Cache-Control",(0,r.getCacheControlHeader)(k.cacheControl)),await (0,p.I)(V,W,new Response(k.value.body,{headers:l,status:k.value.status||200})),null};R&&Q?await h(Q):(e=P.getActiveScopeSpan(),await P.withPropagatedContext(a.headers,()=>P.trace(n.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:i.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},h),void 0,!R))}catch(b){if(b instanceof t.NoFallbackError||await y.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;return await (0,p.I)(V,W,new Response(null,{status:500})),null}}},15616:()=>{},21820:a=>{"use strict";a.exports=require("os")},29021:a=>{"use strict";a.exports=require("fs")},29294:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},33873:a=>{"use strict";a.exports=require("path")},39006:a=>{"use strict";a.exports={rE:"0.4.52"}},44870:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},45769:(a,b,c)=>{"use strict";c.d(b,{g:()=>m,l:()=>l});var d=c(79646),e=c(33873),f=c.n(e),g=c(29021),h=c.n(g),i=c(21820),j=c.n(i),k=c(46715);async function l(){!function(){try{let a=f().join("win32"===process.platform?f().join(process.env.APPDATA||"","9router"):f().join(j().homedir(),".9router"),"mitm",".mitm.pid");if(!h().existsSync(a))return;let b=parseInt(h().readFileSync(a,"utf8").trim(),10);if(!b)return;if("win32"===process.platform)try{(0,d.execSync)(`taskkill /F /T /PID ${b}`,{stdio:"ignore",windowsHide:!0,timeout:3e3})}catch{try{(0,d.execSync)(`powershell -NonInteractive -WindowStyle Hidden -Command "Stop-Process -Id ${b} -Force"`,{stdio:"ignore",windowsHide:!0,timeout:3e3})}catch{}}else try{(0,d.execSync)(`sudo -n kill -9 ${b} 2>/dev/null`,{stdio:"ignore",timeout:3e3})}catch{try{process.kill(b,"SIGKILL")}catch{}}try{h().unlinkSync(a)}catch{}}catch{}}();let a=function(){let a=[];if("win32"===process.platform){try{(0,d.execSync)('powershell -NonInteractive -WindowStyle Hidden -Command "Get-WmiObject Win32_Process -Filter \'Name=\\"node.exe\\"\' | Select-Object ProcessId,CommandLine | ConvertTo-Csv -NoTypeInformation"',{encoding:"utf8",windowsHide:!0,timeout:5e3}).split("\n").slice(1).filter(a=>a.trim()).forEach(b=>{let c=b.toLowerCase();if(c.includes("9router")||c.includes("next-server")||c.includes("\\bin\\app\\")||c.includes("/bin/app/")||c.includes("cli.js")){let c=b.match(/^"(\d+)"/);c&&c[1]&&c[1]!==process.pid.toString()&&a.push(c[1])}})}catch{}for(let b of["cloudflared","tray_windows_release"])try{let c=`powershell -NonInteractive -WindowStyle Hidden -Command "Get-Process ${b} -ErrorAction SilentlyContinue | Select-Object -ExpandProperty Id"`;(0,d.execSync)(c,{encoding:"utf8",windowsHide:!0,timeout:5e3}).split("\n").forEach(b=>{let c=b.trim();c&&!isNaN(c)&&a.push(c)})}catch{}}else try{(0,d.execSync)("ps aux 2>/dev/null",{encoding:"utf8",timeout:5e3}).split("\n").forEach(b=>{if(b.includes("9router")||b.includes("next-server")||b.includes("cloudflared")||b.includes("/bin/app/")||b.includes("tray_darwin")||b.includes("tray_linux")){let c=b.trim().split(/\s+/)[1];c&&!isNaN(c)&&c!==process.pid.toString()&&a.push(c)}})}catch{}return a}(),b=process.platform;a.forEach(a=>{try{"win32"===b?(0,d.execSync)(`taskkill /F /PID ${a} 2>nul`,{stdio:"ignore",shell:!0,windowsHide:!0,timeout:3e3}):(0,d.execSync)(`kill -9 ${a} 2>/dev/null`,{stdio:"ignore",timeout:3e3})}catch{}}),a.length>0&&await new Promise(a=>setTimeout(a,1500))}function m(a=k.h0.npmPackageName){let b=function(a){try{if(!a||!h().existsSync(a))return a;let b=f().join(process.env.DATA_DIR?process.env.DATA_DIR:"win32"===process.platform?f().join(process.env.APPDATA||f().join(j().homedir(),"AppData","Roaming"),"9router"):f().join(j().homedir(),".9router"),"runtime","updater"),c=f().join(b,"updater.js");if(h().existsSync(c))try{if(h().statSync(a).size===h().statSync(c).size)return c}catch{}return h().mkdirSync(b,{recursive:!0}),h().copyFileSync(a,c),c}catch{return a}}(function(){if(process.env.UPDATER_SCRIPT_PATH&&h().existsSync(process.env.UPDATER_SCRIPT_PATH))return process.env.UPDATER_SCRIPT_PATH;let a=f().join(process.cwd(),"src","lib","updater","updater.js");if(h().existsSync(a))return a;let b=f().join(process.cwd(),"..","src","lib","updater","updater.js");return h().existsSync(b)?b:a}()),c="1"===process.env.TRAY_MODE,e={cmd:"win32"===process.platform?"npx.cmd":"npx",args:[k.h0.npmPackageName]},g=c?[...e.args,"--tray","--skip-update"]:[...e.args,"--skip-update"];(0,d.spawn)(process.execPath,[b],{detached:!0,stdio:"ignore",windowsHide:!0,env:{...process.env,UPDATER_PKG_NAME:a,UPDATER_PORT:String(k.h0.statusPort),UPDATER_TAIL_LINES:String(k.h0.statusLogTailLines),UPDATER_RETRIES:String(k.h0.installRetries),UPDATER_RETRY_DELAY_MS:String(k.h0.installRetryDelayMs),UPDATER_LINGER_MS:String(k.h0.lingerAfterDoneMs),UPDATER_WAIT_MIN_MS:String(k.h0.waitForExitMinMs),UPDATER_WAIT_MAX_MS:String(k.h0.waitForExitMaxMs),UPDATER_WAIT_CHECK_MS:String(k.h0.waitForExitCheckMs),UPDATER_APP_PORT:String(k.h0.appPort),UPDATER_RELAUNCH:"1",UPDATER_RELAUNCH_CMD:e.cmd,UPDATER_RELAUNCH_ARGS:JSON.stringify(g)}}).unref(),setTimeout(()=>process.exit(0),k.h0.exitDelayMs)}},46715:(a,b,c)=>{"use strict";c.d(b,{UY:()=>h,X3:()=>i,eh:()=>f.eh,fg:()=>e.fg,h0:()=>g});var d=c(39006),e=c(3811),f=c(75491);d.rE;let g={npmPackageName:"9router",installCmd:"npm i -g 9router",installCmdLatest:"npm i -g 9router@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:20128},h={maxLines:200,pollIntervalMs:1e3},i={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"}},52064:()=>{},63033:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},75491:(a,b,c)=>{"use strict";c.d(b,{Xg:()=>d.Xg,eh:()=>e,vq:()=>d.vq});var d=c(17785);Object.entries(c(3811).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})))},79646:a=>{"use strict";a.exports=require("child_process")},86439:a=>{"use strict";a.exports=require("next/dist/shared/lib/no-fallback-error.external")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[7426,9004,3811,7785],()=>b(b.s=13919));module.exports=c})();
|
|
1
|
+
(()=>{var a={};a.id=2198,a.ids=[2198],a.modules={261:a=>{"use strict";a.exports=require("next/dist/shared/lib/router/utils/app-paths")},3295:a=>{"use strict";a.exports=require("next/dist/server/app-render/after-task-async-storage.external.js")},10846:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},13919:(a,b,c)=>{"use strict";c.r(b),c.d(b,{handler:()=>D,patchFetch:()=>C,routeModule:()=>y,serverHooks:()=>B,workAsyncStorage:()=>z,workUnitAsyncStorage:()=>A});var d={};c.r(d),c.d(d,{POST:()=>x});var e=c(71832),f=c(43805),g=c(93004),h=c(98942),i=c(2052),j=c(43404),k=c(261),l=c(21330),m=c(54832),n=c(85968),o=c(32163),p=c(19133),q=c(45391),r=c(62033),s=c(58742),t=c(86439),u=c(42108),v=c(3601),w=c(45769);async function x(){try{await (0,w.l)()}catch{}return(0,w.g)(),v.NextResponse.json({success:!0,message:"Updater started. This app will exit shortly."})}let y=new e.AppRouteRouteModule({definition:{kind:f.RouteKind.APP_ROUTE,page:"/api/version/update/route",pathname:"/api/version/update",filename:"route",bundlePath:"app/api/version/update/route"},distDir:".next-cli-build",relativeProjectDir:"",resolvedPagePath:"/home/itsazni/projects/scripts/9router/src/app/api/version/update/route.js",nextConfigOutput:"standalone",userland:d,...{}}),{workAsyncStorage:z,workUnitAsyncStorage:A,serverHooks:B}=y;function C(){return(0,g.patchFetch)({workAsyncStorage:z,workUnitAsyncStorage:A})}async function D(a,b,c){c.requestMeta&&(0,h.setRequestMeta)(a,c.requestMeta),y.isDev&&(0,h.addRequestMeta)(a,"devRequestTimingInternalsEnd",process.hrtime.bigint());let d="/api/version/update/route";"/index"===d&&(d="/");let e=await y.prepare(a,b,{srcPage:d,multiZoneDraftMode:!1});if(!e)return b.statusCode=400,b.end("Bad Request"),null==c.waitUntil||c.waitUntil.call(c,Promise.resolve()),null;let{buildId:g,deploymentId:v,params:w,nextConfig:x,parsedUrl:z,isDraftMode:A,prerenderManifest:B,routerServerContext:C,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,resolvedPathname:F,clientReferenceManifest:G,serverActionsManifest:H}=e,I=(0,k.normalizeAppPath)(d),J=!!(B.dynamicRoutes[I]||B.routes[F]),K=async()=>((null==C?void 0:C.render404)?await C.render404(a,b,z,!1):b.end("This page could not be found"),null);if(J&&!A){let a=!!B.routes[F],b=B.dynamicRoutes[I];if(b&&!1===b.fallback&&!a){if(x.adapterPath)return await K();throw new t.NoFallbackError}}let L=null;!J||y.isDev||A||(L="/index"===(L=F)?"/":L);let M=!0===y.isDev||!J,N=J&&!M;H&&G&&(0,j.setManifestsSingleton)({page:d,clientReferenceManifest:G,serverActionsManifest:H});let O=a.method||"GET",P=(0,i.getTracer)(),Q=P.getActiveScopeSpan(),R=!!(null==C?void 0:C.isWrappedByNextServer),S=!!(0,h.getRequestMeta)(a,"minimalMode"),T=(0,h.getRequestMeta)(a,"incrementalCache")||await y.getIncrementalCache(a,x,B,S);null==T||T.resetRequestCache(),globalThis.__incrementalCache=T;let U={params:w,previewProps:B.preview,renderOpts:{experimental:{authInterrupts:!!x.experimental.authInterrupts},cacheComponents:!!x.cacheComponents,supportsDynamicResponse:M,incrementalCache:T,cacheLifeProfiles:x.cacheLife,waitUntil:c.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:void 0,onInstrumentationRequestError:(b,c,d,e)=>y.onRequestError(a,b,d,e,C)},sharedContext:{buildId:g,deploymentId:v}},V=new l.NodeNextRequest(a),W=new l.NodeNextResponse(b),X=m.NextRequestAdapter.fromNodeNextRequest(V,(0,m.signalFromNodeResponse)(b));try{let e,g=async a=>y.handle(X,U).finally(()=>{if(!a)return;a.setAttributes({"http.status_code":b.statusCode,"next.rsc":!1});let c=P.getRootSpanAttributes();if(!c)return;if(c.get("next.span_type")!==n.BaseServerSpan.handleRequest)return void console.warn(`Unexpected root span type '${c.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let f=c.get("next.route");if(f){let b=`${O} ${f}`;a.setAttributes({"next.route":f,"http.route":f,"next.span_name":b}),a.updateName(b),e&&e!==a&&(e.setAttribute("http.route",f),e.updateName(b))}else a.updateName(`${O} ${d}`)}),h=async e=>{var h,i;let j=async({previousCacheEntry:f})=>{try{if(!S&&D&&E&&!f)return b.statusCode=404,b.setHeader("x-nextjs-cache","REVALIDATED"),b.end("This page could not be found"),null;let d=await g(e);a.fetchMetrics=U.renderOpts.fetchMetrics;let h=U.renderOpts.pendingWaitUntil;h&&c.waitUntil&&(c.waitUntil(h),h=void 0);let i=U.renderOpts.collectedTags;if(!J)return await (0,p.I)(V,W,d,U.renderOpts.pendingWaitUntil),null;{let a=await d.blob(),b=(0,q.toNodeOutgoingHttpHeaders)(d.headers);i&&(b[s.NEXT_CACHE_TAGS_HEADER]=i),!b["content-type"]&&a.type&&(b["content-type"]=a.type);let c=void 0!==U.renderOpts.collectedRevalidate&&!(U.renderOpts.collectedRevalidate>=s.INFINITE_CACHE)&&U.renderOpts.collectedRevalidate,e=void 0===U.renderOpts.collectedExpire||U.renderOpts.collectedExpire>=s.INFINITE_CACHE?void 0:U.renderOpts.collectedExpire;return{value:{kind:u.CachedRouteKind.APP_ROUTE,status:d.status,body:Buffer.from(await a.arrayBuffer()),headers:b},cacheControl:{revalidate:c,expire:e}}}}catch(b){throw(null==f?void 0:f.isStale)&&await y.onRequestError(a,b,{routerKind:"App Router",routePath:d,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),b}},k=await y.handleResponse({req:a,nextConfig:x,cacheKey:L,routeKind:f.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:B,isRoutePPREnabled:!1,isOnDemandRevalidate:D,revalidateOnlyGenerated:E,responseGenerator:j,waitUntil:c.waitUntil,isMinimalMode:S});if(!J)return null;if((null==k||null==(h=k.value)?void 0:h.kind)!==u.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==k||null==(i=k.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});S||b.setHeader("x-nextjs-cache",D?"REVALIDATED":k.isMiss?"MISS":k.isStale?"STALE":"HIT"),A&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let l=(0,q.fromNodeOutgoingHttpHeaders)(k.value.headers);return S&&J||l.delete(s.NEXT_CACHE_TAGS_HEADER),!k.cacheControl||b.getHeader("Cache-Control")||l.get("Cache-Control")||l.set("Cache-Control",(0,r.getCacheControlHeader)(k.cacheControl)),await (0,p.I)(V,W,new Response(k.value.body,{headers:l,status:k.value.status||200})),null};R&&Q?await h(Q):(e=P.getActiveScopeSpan(),await P.withPropagatedContext(a.headers,()=>P.trace(n.BaseServerSpan.handleRequest,{spanName:`${O} ${d}`,kind:i.SpanKind.SERVER,attributes:{"http.method":O,"http.target":a.url}},h),void 0,!R))}catch(b){if(b instanceof t.NoFallbackError||await y.onRequestError(a,b,{routerKind:"App Router",routePath:I,routeType:"route",revalidateReason:(0,o.c)({isStaticGeneration:N,isOnDemandRevalidate:D})},!1,C),J)throw b;return await (0,p.I)(V,W,new Response(null,{status:500})),null}}},15616:()=>{},21820:a=>{"use strict";a.exports=require("os")},29021:a=>{"use strict";a.exports=require("fs")},29294:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},33873:a=>{"use strict";a.exports=require("path")},39006:a=>{"use strict";a.exports={rE:"0.4.53"}},44870:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-route.runtime.prod.js")},45769:(a,b,c)=>{"use strict";c.d(b,{g:()=>m,l:()=>l});var d=c(79646),e=c(33873),f=c.n(e),g=c(29021),h=c.n(g),i=c(21820),j=c.n(i),k=c(46715);async function l(){!function(){try{let a=f().join("win32"===process.platform?f().join(process.env.APPDATA||"","9router"):f().join(j().homedir(),".9router"),"mitm",".mitm.pid");if(!h().existsSync(a))return;let b=parseInt(h().readFileSync(a,"utf8").trim(),10);if(!b)return;if("win32"===process.platform)try{(0,d.execSync)(`taskkill /F /T /PID ${b}`,{stdio:"ignore",windowsHide:!0,timeout:3e3})}catch{try{(0,d.execSync)(`powershell -NonInteractive -WindowStyle Hidden -Command "Stop-Process -Id ${b} -Force"`,{stdio:"ignore",windowsHide:!0,timeout:3e3})}catch{}}else try{(0,d.execSync)(`sudo -n kill -9 ${b} 2>/dev/null`,{stdio:"ignore",timeout:3e3})}catch{try{process.kill(b,"SIGKILL")}catch{}}try{h().unlinkSync(a)}catch{}}catch{}}();let a=function(){let a=[];if("win32"===process.platform){try{(0,d.execSync)('powershell -NonInteractive -WindowStyle Hidden -Command "Get-WmiObject Win32_Process -Filter \'Name=\\"node.exe\\"\' | Select-Object ProcessId,CommandLine | ConvertTo-Csv -NoTypeInformation"',{encoding:"utf8",windowsHide:!0,timeout:5e3}).split("\n").slice(1).filter(a=>a.trim()).forEach(b=>{let c=b.toLowerCase();if(c.includes("9router")||c.includes("next-server")||c.includes("\\bin\\app\\")||c.includes("/bin/app/")||c.includes("cli.js")){let c=b.match(/^"(\d+)"/);c&&c[1]&&c[1]!==process.pid.toString()&&a.push(c[1])}})}catch{}for(let b of["cloudflared","tray_windows_release"])try{let c=`powershell -NonInteractive -WindowStyle Hidden -Command "Get-Process ${b} -ErrorAction SilentlyContinue | Select-Object -ExpandProperty Id"`;(0,d.execSync)(c,{encoding:"utf8",windowsHide:!0,timeout:5e3}).split("\n").forEach(b=>{let c=b.trim();c&&!isNaN(c)&&a.push(c)})}catch{}}else try{(0,d.execSync)("ps aux 2>/dev/null",{encoding:"utf8",timeout:5e3}).split("\n").forEach(b=>{if(b.includes("9router")||b.includes("next-server")||b.includes("cloudflared")||b.includes("/bin/app/")||b.includes("tray_darwin")||b.includes("tray_linux")){let c=b.trim().split(/\s+/)[1];c&&!isNaN(c)&&c!==process.pid.toString()&&a.push(c)}})}catch{}return a}(),b=process.platform;a.forEach(a=>{try{"win32"===b?(0,d.execSync)(`taskkill /F /PID ${a} 2>nul`,{stdio:"ignore",shell:!0,windowsHide:!0,timeout:3e3}):(0,d.execSync)(`kill -9 ${a} 2>/dev/null`,{stdio:"ignore",timeout:3e3})}catch{}}),a.length>0&&await new Promise(a=>setTimeout(a,1500))}function m(a=k.h0.npmPackageName){let b=function(a){try{if(!a||!h().existsSync(a))return a;let b=f().join(process.env.DATA_DIR?process.env.DATA_DIR:"win32"===process.platform?f().join(process.env.APPDATA||f().join(j().homedir(),"AppData","Roaming"),"9router"):f().join(j().homedir(),".9router"),"runtime","updater"),c=f().join(b,"updater.js");if(h().existsSync(c))try{if(h().statSync(a).size===h().statSync(c).size)return c}catch{}return h().mkdirSync(b,{recursive:!0}),h().copyFileSync(a,c),c}catch{return a}}(function(){if(process.env.UPDATER_SCRIPT_PATH&&h().existsSync(process.env.UPDATER_SCRIPT_PATH))return process.env.UPDATER_SCRIPT_PATH;let a=f().join(process.cwd(),"src","lib","updater","updater.js");if(h().existsSync(a))return a;let b=f().join(process.cwd(),"..","src","lib","updater","updater.js");return h().existsSync(b)?b:a}()),c="1"===process.env.TRAY_MODE,e={cmd:"win32"===process.platform?"npx.cmd":"npx",args:[k.h0.npmPackageName]},g=c?[...e.args,"--tray","--skip-update"]:[...e.args,"--skip-update"];(0,d.spawn)(process.execPath,[b],{detached:!0,stdio:"ignore",windowsHide:!0,env:{...process.env,UPDATER_PKG_NAME:a,UPDATER_PORT:String(k.h0.statusPort),UPDATER_TAIL_LINES:String(k.h0.statusLogTailLines),UPDATER_RETRIES:String(k.h0.installRetries),UPDATER_RETRY_DELAY_MS:String(k.h0.installRetryDelayMs),UPDATER_LINGER_MS:String(k.h0.lingerAfterDoneMs),UPDATER_WAIT_MIN_MS:String(k.h0.waitForExitMinMs),UPDATER_WAIT_MAX_MS:String(k.h0.waitForExitMaxMs),UPDATER_WAIT_CHECK_MS:String(k.h0.waitForExitCheckMs),UPDATER_APP_PORT:String(k.h0.appPort),UPDATER_RELAUNCH:"1",UPDATER_RELAUNCH_CMD:e.cmd,UPDATER_RELAUNCH_ARGS:JSON.stringify(g)}}).unref(),setTimeout(()=>process.exit(0),k.h0.exitDelayMs)}},46715:(a,b,c)=>{"use strict";c.d(b,{UY:()=>h,X3:()=>i,eh:()=>f.eh,fg:()=>e.fg,h0:()=>g});var d=c(39006),e=c(3811),f=c(75491);d.rE;let g={npmPackageName:"9router",installCmd:"npm i -g 9router",installCmdLatest:"npm i -g 9router@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:20128},h={maxLines:200,pollIntervalMs:1e3},i={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"}},52064:()=>{},63033:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},75491:(a,b,c)=>{"use strict";c.d(b,{Xg:()=>d.Xg,eh:()=>e,vq:()=>d.vq});var d=c(17785);Object.entries(c(3811).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})))},79646:a=>{"use strict";a.exports=require("child_process")},86439:a=>{"use strict";a.exports=require("next/dist/shared/lib/no-fallback-error.external")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[7426,9004,3811,7785],()=>b(b.s=13919));module.exports=c})();
|