@m1nh/9router 0.5.86 → 0.5.87

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.
Files changed (965) hide show
  1. package/app/.next-cli-build/BUILD_ID +1 -1
  2. package/app/.next-cli-build/app-path-routes-manifest.json +17 -16
  3. package/app/.next-cli-build/build-manifest.json +2 -2
  4. package/app/.next-cli-build/prerender-manifest.json +3 -3
  5. package/app/.next-cli-build/routes-manifest.json +8 -0
  6. package/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page.js +1 -1
  7. package/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page.js.nft.json +1 -1
  8. package/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page_client-reference-manifest.js +1 -1
  9. package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page.js +1 -1
  10. package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page.js.nft.json +1 -1
  11. package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page_client-reference-manifest.js +1 -1
  12. package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page.js +1 -1
  13. package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page.js.nft.json +1 -1
  14. package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page_client-reference-manifest.js +1 -1
  15. package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page.js +1 -1
  16. package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page.js.nft.json +1 -1
  17. package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page_client-reference-manifest.js +1 -1
  18. package/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page.js +1 -1
  19. package/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page.js.nft.json +1 -1
  20. package/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page_client-reference-manifest.js +1 -1
  21. package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page.js +1 -1
  22. package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page.js.nft.json +1 -1
  23. package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page_client-reference-manifest.js +1 -1
  24. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page.js +2 -2
  25. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page.js.nft.json +1 -1
  26. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page_client-reference-manifest.js +1 -1
  27. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page.js +1 -1
  28. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page.js.nft.json +1 -1
  29. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page_client-reference-manifest.js +1 -1
  30. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page.js +1 -1
  31. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page.js.nft.json +1 -1
  32. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page_client-reference-manifest.js +1 -1
  33. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page.js +1 -1
  34. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page.js.nft.json +1 -1
  35. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page_client-reference-manifest.js +1 -1
  36. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page.js +1 -1
  37. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page.js.nft.json +1 -1
  38. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page_client-reference-manifest.js +1 -1
  39. package/app/.next-cli-build/server/app/(dashboard)/dashboard/page.js +1 -1
  40. package/app/.next-cli-build/server/app/(dashboard)/dashboard/page.js.nft.json +1 -1
  41. package/app/.next-cli-build/server/app/(dashboard)/dashboard/page_client-reference-manifest.js +1 -1
  42. package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page.js +1 -1
  43. package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page.js.nft.json +1 -1
  44. package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page_client-reference-manifest.js +1 -1
  45. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page.js +5 -5
  46. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page.js.nft.json +1 -1
  47. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page_client-reference-manifest.js +1 -1
  48. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page.js +1 -1
  49. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page.js.nft.json +1 -1
  50. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page_client-reference-manifest.js +1 -1
  51. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page.js +1 -1
  52. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page.js.nft.json +1 -1
  53. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page_client-reference-manifest.js +1 -1
  54. package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page.js +1 -1
  55. package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page.js.nft.json +1 -1
  56. package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page_client-reference-manifest.js +1 -1
  57. package/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page.js +1 -1
  58. package/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page.js.nft.json +1 -1
  59. package/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page_client-reference-manifest.js +1 -1
  60. package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page.js +1 -1
  61. package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page.js.nft.json +1 -1
  62. package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page_client-reference-manifest.js +1 -1
  63. package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page.js +1 -1
  64. package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page.js.nft.json +1 -1
  65. package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page_client-reference-manifest.js +1 -1
  66. package/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page.js +1 -1
  67. package/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page.js.nft.json +1 -1
  68. package/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page_client-reference-manifest.js +1 -1
  69. package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page.js +1 -1
  70. package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page.js.nft.json +1 -1
  71. package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page_client-reference-manifest.js +1 -1
  72. package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page.js +1 -1
  73. package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page.js.nft.json +1 -1
  74. package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page_client-reference-manifest.js +1 -1
  75. package/app/.next-cli-build/server/app/_global-error/page.js +1 -1
  76. package/app/.next-cli-build/server/app/_global-error/page.js.nft.json +1 -1
  77. package/app/.next-cli-build/server/app/_global-error/page_client-reference-manifest.js +1 -1
  78. package/app/.next-cli-build/server/app/_global-error.html +1 -1
  79. package/app/.next-cli-build/server/app/_global-error.rsc +1 -1
  80. package/app/.next-cli-build/server/app/_global-error.segments/_full.segment.rsc +1 -1
  81. package/app/.next-cli-build/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
  82. package/app/.next-cli-build/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  83. package/app/.next-cli-build/server/app/_not-found/page.js +1 -1
  84. package/app/.next-cli-build/server/app/_not-found/page.js.nft.json +1 -1
  85. package/app/.next-cli-build/server/app/_not-found/page_client-reference-manifest.js +1 -1
  86. package/app/.next-cli-build/server/app/_not-found.html +1 -1
  87. package/app/.next-cli-build/server/app/_not-found.rsc +5 -5
  88. package/app/.next-cli-build/server/app/_not-found.segments/_full.segment.rsc +5 -5
  89. package/app/.next-cli-build/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +5 -5
  90. package/app/.next-cli-build/server/app/_not-found.segments/_tree.segment.rsc +2 -2
  91. package/app/.next-cli-build/server/app/api/auth/login/route.js +1 -1
  92. package/app/.next-cli-build/server/app/api/auth/login/route.js.nft.json +1 -1
  93. package/app/.next-cli-build/server/app/api/auth/logout/route.js +1 -1
  94. package/app/.next-cli-build/server/app/api/auth/logout/route.js.nft.json +1 -1
  95. package/app/.next-cli-build/server/app/api/auth/oidc/callback/route.js +1 -1
  96. package/app/.next-cli-build/server/app/api/auth/oidc/callback/route.js.nft.json +1 -1
  97. package/app/.next-cli-build/server/app/api/auth/oidc/start/route.js +1 -1
  98. package/app/.next-cli-build/server/app/api/auth/oidc/start/route.js.nft.json +1 -1
  99. package/app/.next-cli-build/server/app/api/auth/oidc/test/route.js +1 -1
  100. package/app/.next-cli-build/server/app/api/auth/oidc/test/route.js.nft.json +1 -1
  101. package/app/.next-cli-build/server/app/api/auth/reset-password/route.js +1 -1
  102. package/app/.next-cli-build/server/app/api/auth/reset-password/route.js.nft.json +1 -1
  103. package/app/.next-cli-build/server/app/api/auth/saml/acs/route.js +2 -2
  104. package/app/.next-cli-build/server/app/api/auth/saml/acs/route.js.nft.json +1 -1
  105. package/app/.next-cli-build/server/app/api/auth/saml/metadata/route.js +1 -1
  106. package/app/.next-cli-build/server/app/api/auth/saml/metadata/route.js.nft.json +1 -1
  107. package/app/.next-cli-build/server/app/api/auth/saml/start/route.js +2 -2
  108. package/app/.next-cli-build/server/app/api/auth/saml/start/route.js.nft.json +1 -1
  109. package/app/.next-cli-build/server/app/api/auth/saml/test/route.js +1 -1
  110. package/app/.next-cli-build/server/app/api/auth/saml/test/route.js.nft.json +1 -1
  111. package/app/.next-cli-build/server/app/api/auth/status/route.js +2 -2
  112. package/app/.next-cli-build/server/app/api/auth/status/route.js.nft.json +1 -1
  113. package/app/.next-cli-build/server/app/api/cli-tools/all-statuses/route.js +6 -6
  114. package/app/.next-cli-build/server/app/api/cli-tools/all-statuses/route.js.nft.json +1 -1
  115. package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/alias/route.js +2 -2
  116. package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/alias/route.js.nft.json +1 -1
  117. package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/route.js +1 -1
  118. package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/route.js.nft.json +1 -1
  119. package/app/.next-cli-build/server/app/api/cli-tools/claude-settings/route.js +2 -2
  120. package/app/.next-cli-build/server/app/api/cli-tools/claude-settings/route.js.nft.json +1 -1
  121. package/app/.next-cli-build/server/app/api/cli-tools/cline-settings/route.js +2 -2
  122. package/app/.next-cli-build/server/app/api/cli-tools/cline-settings/route.js.nft.json +1 -1
  123. package/app/.next-cli-build/server/app/api/cli-tools/codewhale-settings/route.js +1 -1
  124. package/app/.next-cli-build/server/app/api/cli-tools/codewhale-settings/route.js.nft.json +1 -1
  125. package/app/.next-cli-build/server/app/api/cli-tools/codex-settings/route.js +1 -1
  126. package/app/.next-cli-build/server/app/api/cli-tools/codex-settings/route.js.nft.json +1 -1
  127. package/app/.next-cli-build/server/app/api/cli-tools/copilot-settings/route.js +2 -2
  128. package/app/.next-cli-build/server/app/api/cli-tools/copilot-settings/route.js.nft.json +1 -1
  129. package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-registry/route.js +2 -2
  130. package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-registry/route.js.nft.json +1 -1
  131. package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-tools/route.js +1 -1
  132. package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-tools/route.js.nft.json +1 -1
  133. package/app/.next-cli-build/server/app/api/cli-tools/cowork-settings/route.js +2 -2
  134. package/app/.next-cli-build/server/app/api/cli-tools/cowork-settings/route.js.nft.json +1 -1
  135. package/app/.next-cli-build/server/app/api/cli-tools/crush-settings/route.js +2 -2
  136. package/app/.next-cli-build/server/app/api/cli-tools/crush-settings/route.js.nft.json +1 -1
  137. package/app/.next-cli-build/server/app/api/cli-tools/deepseek-tui-settings/route.js +3 -3
  138. package/app/.next-cli-build/server/app/api/cli-tools/deepseek-tui-settings/route.js.nft.json +1 -1
  139. package/app/.next-cli-build/server/app/api/cli-tools/droid-settings/route.js +1 -1
  140. package/app/.next-cli-build/server/app/api/cli-tools/droid-settings/route.js.nft.json +1 -1
  141. package/app/.next-cli-build/server/app/api/cli-tools/forge-settings/route.js +1 -1
  142. package/app/.next-cli-build/server/app/api/cli-tools/forge-settings/route.js.nft.json +1 -1
  143. package/app/.next-cli-build/server/app/api/cli-tools/grok-build-settings/route.js +1 -1
  144. package/app/.next-cli-build/server/app/api/cli-tools/grok-build-settings/route.js.nft.json +1 -1
  145. package/app/.next-cli-build/server/app/api/cli-tools/hermes-settings/route.js +3 -3
  146. package/app/.next-cli-build/server/app/api/cli-tools/hermes-settings/route.js.nft.json +1 -1
  147. package/app/.next-cli-build/server/app/api/cli-tools/jcode-settings/route.js +2 -2
  148. package/app/.next-cli-build/server/app/api/cli-tools/jcode-settings/route.js.nft.json +1 -1
  149. package/app/.next-cli-build/server/app/api/cli-tools/kilo-settings/route.js +2 -2
  150. package/app/.next-cli-build/server/app/api/cli-tools/kilo-settings/route.js.nft.json +1 -1
  151. package/app/.next-cli-build/server/app/api/cli-tools/omp-settings/route.js +2 -2
  152. package/app/.next-cli-build/server/app/api/cli-tools/omp-settings/route.js.nft.json +1 -1
  153. package/app/.next-cli-build/server/app/api/cli-tools/openclaw-settings/route.js +2 -2
  154. package/app/.next-cli-build/server/app/api/cli-tools/openclaw-settings/route.js.nft.json +1 -1
  155. package/app/.next-cli-build/server/app/api/cli-tools/opencode-settings/route.js +1 -1
  156. package/app/.next-cli-build/server/app/api/cli-tools/opencode-settings/route.js.nft.json +1 -1
  157. package/app/.next-cli-build/server/app/api/cli-tools/pi-settings/route.js +1 -1
  158. package/app/.next-cli-build/server/app/api/cli-tools/pi-settings/route.js.nft.json +1 -1
  159. package/app/.next-cli-build/server/app/api/cli-tools/smelt-settings/route.js +1 -1
  160. package/app/.next-cli-build/server/app/api/cli-tools/smelt-settings/route.js.nft.json +1 -1
  161. package/app/.next-cli-build/server/app/api/combos/[id]/route.js +1 -1
  162. package/app/.next-cli-build/server/app/api/combos/[id]/route.js.nft.json +1 -1
  163. package/app/.next-cli-build/server/app/api/combos/presets/route.js +1 -1
  164. package/app/.next-cli-build/server/app/api/combos/presets/route.js.nft.json +1 -1
  165. package/app/.next-cli-build/server/app/api/combos/route.js +1 -1
  166. package/app/.next-cli-build/server/app/api/combos/route.js.nft.json +1 -1
  167. package/app/.next-cli-build/server/app/api/headroom/extras/route.js +1 -1
  168. package/app/.next-cli-build/server/app/api/headroom/extras/route.js.nft.json +1 -1
  169. package/app/.next-cli-build/server/app/api/headroom/proxy/[...path]/route.js +1 -1
  170. package/app/.next-cli-build/server/app/api/headroom/proxy/[...path]/route.js.nft.json +1 -1
  171. package/app/.next-cli-build/server/app/api/headroom/restart/route.js +1 -1
  172. package/app/.next-cli-build/server/app/api/headroom/restart/route.js.nft.json +1 -1
  173. package/app/.next-cli-build/server/app/api/headroom/start/route.js +1 -1
  174. package/app/.next-cli-build/server/app/api/headroom/start/route.js.nft.json +1 -1
  175. package/app/.next-cli-build/server/app/api/headroom/status/route.js +1 -1
  176. package/app/.next-cli-build/server/app/api/headroom/status/route.js.nft.json +1 -1
  177. package/app/.next-cli-build/server/app/api/headroom/stop/route.js +1 -1
  178. package/app/.next-cli-build/server/app/api/headroom/stop/route.js.nft.json +1 -1
  179. package/app/.next-cli-build/server/app/api/health/route.js +1 -1
  180. package/app/.next-cli-build/server/app/api/health/route.js.nft.json +1 -1
  181. package/app/.next-cli-build/server/app/api/init/route.js +1 -1
  182. package/app/.next-cli-build/server/app/api/init/route.js.nft.json +1 -1
  183. package/app/.next-cli-build/server/app/api/keys/[id]/route.js +1 -1
  184. package/app/.next-cli-build/server/app/api/keys/[id]/route.js.nft.json +1 -1
  185. package/app/.next-cli-build/server/app/api/keys/route.js +1 -1
  186. package/app/.next-cli-build/server/app/api/keys/route.js.nft.json +1 -1
  187. package/app/.next-cli-build/server/app/api/locale/route.js +1 -1
  188. package/app/.next-cli-build/server/app/api/locale/route.js.nft.json +1 -1
  189. package/app/.next-cli-build/server/app/api/mcp/[plugin]/message/route.js +2 -2
  190. package/app/.next-cli-build/server/app/api/mcp/[plugin]/message/route.js.nft.json +1 -1
  191. package/app/.next-cli-build/server/app/api/mcp/[plugin]/sse/route.js +2 -2
  192. package/app/.next-cli-build/server/app/api/mcp/[plugin]/sse/route.js.nft.json +1 -1
  193. package/app/.next-cli-build/server/app/api/media-providers/tts/deepgram/voices/route.js +1 -1
  194. package/app/.next-cli-build/server/app/api/media-providers/tts/deepgram/voices/route.js.nft.json +1 -1
  195. package/app/.next-cli-build/server/app/api/media-providers/tts/elevenlabs/voices/route.js +1 -1
  196. package/app/.next-cli-build/server/app/api/media-providers/tts/elevenlabs/voices/route.js.nft.json +1 -1
  197. package/app/.next-cli-build/server/app/api/media-providers/tts/inworld/voices/route.js +1 -1
  198. package/app/.next-cli-build/server/app/api/media-providers/tts/inworld/voices/route.js.nft.json +1 -1
  199. package/app/.next-cli-build/server/app/api/media-providers/tts/minimax/voices/route.js +1 -1
  200. package/app/.next-cli-build/server/app/api/media-providers/tts/minimax/voices/route.js.nft.json +1 -1
  201. package/app/.next-cli-build/server/app/api/media-providers/tts/voices/route.js +1 -1
  202. package/app/.next-cli-build/server/app/api/media-providers/tts/voices/route.js.nft.json +1 -1
  203. package/app/.next-cli-build/server/app/api/models/alias/route.js +1 -1
  204. package/app/.next-cli-build/server/app/api/models/alias/route.js.nft.json +1 -1
  205. package/app/.next-cli-build/server/app/api/models/availability/route.js +1 -1
  206. package/app/.next-cli-build/server/app/api/models/availability/route.js.nft.json +1 -1
  207. package/app/.next-cli-build/server/app/api/models/catalog-sync/route.js +1 -1
  208. package/app/.next-cli-build/server/app/api/models/catalog-sync/route.js.nft.json +1 -1
  209. package/app/.next-cli-build/server/app/api/models/custom/route.js +1 -1
  210. package/app/.next-cli-build/server/app/api/models/custom/route.js.nft.json +1 -1
  211. package/app/.next-cli-build/server/app/api/models/disabled/route.js +1 -1
  212. package/app/.next-cli-build/server/app/api/models/disabled/route.js.nft.json +1 -1
  213. package/app/.next-cli-build/server/app/api/models/route.js +1 -1
  214. package/app/.next-cli-build/server/app/api/models/route.js.nft.json +1 -1
  215. package/app/.next-cli-build/server/app/api/models/test/route.js +1 -1
  216. package/app/.next-cli-build/server/app/api/models/test/route.js.nft.json +1 -1
  217. package/app/.next-cli-build/server/app/api/oauth/[provider]/[action]/route.js +1 -1
  218. package/app/.next-cli-build/server/app/api/oauth/[provider]/[action]/route.js.nft.json +1 -1
  219. package/app/.next-cli-build/server/app/api/oauth/codex/bulk-import/route.js +1 -1
  220. package/app/.next-cli-build/server/app/api/oauth/codex/bulk-import/route.js.nft.json +1 -1
  221. package/app/.next-cli-build/server/app/api/oauth/codex/import-token/route.js +1 -1
  222. package/app/.next-cli-build/server/app/api/oauth/codex/import-token/route.js.nft.json +1 -1
  223. package/app/.next-cli-build/server/app/api/oauth/cursor/auto-import/route.js +1 -1
  224. package/app/.next-cli-build/server/app/api/oauth/cursor/auto-import/route.js.nft.json +1 -1
  225. package/app/.next-cli-build/server/app/api/oauth/cursor/import/route.js +1 -1
  226. package/app/.next-cli-build/server/app/api/oauth/cursor/import/route.js.nft.json +1 -1
  227. package/app/.next-cli-build/server/app/api/oauth/gitlab/pat/route.js +1 -1
  228. package/app/.next-cli-build/server/app/api/oauth/gitlab/pat/route.js.nft.json +1 -1
  229. package/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/route.js +1 -1
  230. package/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/route.js.nft.json +1 -1
  231. package/app/.next-cli-build/server/app/api/oauth/iflow/cookie/route.js +1 -1
  232. package/app/.next-cli-build/server/app/api/oauth/iflow/cookie/route.js.nft.json +1 -1
  233. package/app/.next-cli-build/server/app/api/oauth/kiro/api-key/route.js +1 -1
  234. package/app/.next-cli-build/server/app/api/oauth/kiro/api-key/route.js.nft.json +1 -1
  235. package/app/.next-cli-build/server/app/api/oauth/kiro/auto-import/route.js +1 -1
  236. package/app/.next-cli-build/server/app/api/oauth/kiro/auto-import/route.js.nft.json +1 -1
  237. package/app/.next-cli-build/server/app/api/oauth/kiro/import/route.js +1 -1
  238. package/app/.next-cli-build/server/app/api/oauth/kiro/import/route.js.nft.json +1 -1
  239. package/app/.next-cli-build/server/app/api/oauth/kiro/import-cli-proxy/route.js +1 -1
  240. package/app/.next-cli-build/server/app/api/oauth/kiro/import-cli-proxy/route.js.nft.json +1 -1
  241. package/app/.next-cli-build/server/app/api/oauth/kiro/social-authorize/route.js +1 -1
  242. package/app/.next-cli-build/server/app/api/oauth/kiro/social-authorize/route.js.nft.json +1 -1
  243. package/app/.next-cli-build/server/app/api/oauth/kiro/social-exchange/route.js +1 -1
  244. package/app/.next-cli-build/server/app/api/oauth/kiro/social-exchange/route.js.nft.json +1 -1
  245. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/api-key/route.js +1 -1
  246. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/api-key/route.js.nft.json +1 -1
  247. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/auto-import/route.js +2 -2
  248. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/auto-import/route.js.nft.json +1 -1
  249. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/login/start/route.js +1 -1
  250. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/login/start/route.js.nft.json +1 -1
  251. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/login/status/route.js +1 -1
  252. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/login/status/route.js.nft.json +1 -1
  253. package/app/.next-cli-build/server/app/api/pricing/route.js +1 -1
  254. package/app/.next-cli-build/server/app/api/pricing/route.js.nft.json +1 -1
  255. package/app/.next-cli-build/server/app/api/provider-nodes/[id]/route.js +1 -1
  256. package/app/.next-cli-build/server/app/api/provider-nodes/[id]/route.js.nft.json +1 -1
  257. package/app/.next-cli-build/server/app/api/provider-nodes/route.js +1 -1
  258. package/app/.next-cli-build/server/app/api/provider-nodes/route.js.nft.json +1 -1
  259. package/app/.next-cli-build/server/app/api/provider-nodes/validate/route.js +1 -1
  260. package/app/.next-cli-build/server/app/api/provider-nodes/validate/route.js.nft.json +1 -1
  261. package/app/.next-cli-build/server/app/api/providers/[id]/models/route.js +1 -1
  262. package/app/.next-cli-build/server/app/api/providers/[id]/models/route.js.nft.json +1 -1
  263. package/app/.next-cli-build/server/app/api/providers/[id]/route.js +1 -1
  264. package/app/.next-cli-build/server/app/api/providers/[id]/route.js.nft.json +1 -1
  265. package/app/.next-cli-build/server/app/api/providers/[id]/test/route.js +1 -1
  266. package/app/.next-cli-build/server/app/api/providers/[id]/test/route.js.nft.json +1 -1
  267. package/app/.next-cli-build/server/app/api/providers/[id]/test-models/route.js +1 -1
  268. package/app/.next-cli-build/server/app/api/providers/[id]/test-models/route.js.nft.json +1 -1
  269. package/app/.next-cli-build/server/app/api/providers/client/route.js +1 -1
  270. package/app/.next-cli-build/server/app/api/providers/client/route.js.nft.json +1 -1
  271. package/app/.next-cli-build/server/app/api/providers/kilo/free-models/route.js +1 -1
  272. package/app/.next-cli-build/server/app/api/providers/kilo/free-models/route.js.nft.json +1 -1
  273. package/app/.next-cli-build/server/app/api/providers/route.js +1 -1
  274. package/app/.next-cli-build/server/app/api/providers/route.js.nft.json +1 -1
  275. package/app/.next-cli-build/server/app/api/providers/suggested-models/route.js +1 -1
  276. package/app/.next-cli-build/server/app/api/providers/suggested-models/route.js.nft.json +1 -1
  277. package/app/.next-cli-build/server/app/api/providers/test-batch/route.js +1 -1
  278. package/app/.next-cli-build/server/app/api/providers/test-batch/route.js.nft.json +1 -1
  279. package/app/.next-cli-build/server/app/api/providers/validate/route.js +1 -1
  280. package/app/.next-cli-build/server/app/api/providers/validate/route.js.nft.json +1 -1
  281. package/app/.next-cli-build/server/app/api/proxy-pools/[id]/route.js +1 -1
  282. package/app/.next-cli-build/server/app/api/proxy-pools/[id]/route.js.nft.json +1 -1
  283. package/app/.next-cli-build/server/app/api/proxy-pools/[id]/test/route.js +1 -1
  284. package/app/.next-cli-build/server/app/api/proxy-pools/[id]/test/route.js.nft.json +1 -1
  285. package/app/.next-cli-build/server/app/api/proxy-pools/cloudflare-deploy/route.js +2 -2
  286. package/app/.next-cli-build/server/app/api/proxy-pools/cloudflare-deploy/route.js.nft.json +1 -1
  287. package/app/.next-cli-build/server/app/api/proxy-pools/deno-deploy/route.js +2 -2
  288. package/app/.next-cli-build/server/app/api/proxy-pools/deno-deploy/route.js.nft.json +1 -1
  289. package/app/.next-cli-build/server/app/api/proxy-pools/route.js +1 -1
  290. package/app/.next-cli-build/server/app/api/proxy-pools/route.js.nft.json +1 -1
  291. package/app/.next-cli-build/server/app/api/proxy-pools/vercel-deploy/route.js +2 -2
  292. package/app/.next-cli-build/server/app/api/proxy-pools/vercel-deploy/route.js.nft.json +1 -1
  293. package/app/.next-cli-build/server/app/api/pxpipe/health/route.js +2 -2
  294. package/app/.next-cli-build/server/app/api/pxpipe/health/route.js.nft.json +1 -1
  295. package/app/.next-cli-build/server/app/api/pxpipe/install/route.js +2 -2
  296. package/app/.next-cli-build/server/app/api/pxpipe/install/route.js.nft.json +1 -1
  297. package/app/.next-cli-build/server/app/api/pxpipe/logs/route.js +2 -2
  298. package/app/.next-cli-build/server/app/api/pxpipe/logs/route.js.nft.json +1 -1
  299. package/app/.next-cli-build/server/app/api/pxpipe/restart/route.js +2 -2
  300. package/app/.next-cli-build/server/app/api/pxpipe/restart/route.js.nft.json +1 -1
  301. package/app/.next-cli-build/server/app/api/pxpipe/start/route.js +2 -2
  302. package/app/.next-cli-build/server/app/api/pxpipe/start/route.js.nft.json +1 -1
  303. package/app/.next-cli-build/server/app/api/pxpipe/stats/route.js +2 -2
  304. package/app/.next-cli-build/server/app/api/pxpipe/stats/route.js.nft.json +1 -1
  305. package/app/.next-cli-build/server/app/api/pxpipe/status/route.js +2 -2
  306. package/app/.next-cli-build/server/app/api/pxpipe/status/route.js.nft.json +1 -1
  307. package/app/.next-cli-build/server/app/api/pxpipe/stop/route.js +2 -2
  308. package/app/.next-cli-build/server/app/api/pxpipe/stop/route.js.nft.json +1 -1
  309. package/app/.next-cli-build/server/app/api/settings/database/route.js +1 -1
  310. package/app/.next-cli-build/server/app/api/settings/database/route.js.nft.json +1 -1
  311. package/app/.next-cli-build/server/app/api/settings/proxy-test/route.js +1 -1
  312. package/app/.next-cli-build/server/app/api/settings/proxy-test/route.js.nft.json +1 -1
  313. package/app/.next-cli-build/server/app/api/settings/require-login/route.js +1 -1
  314. package/app/.next-cli-build/server/app/api/settings/require-login/route.js.nft.json +1 -1
  315. package/app/.next-cli-build/server/app/api/settings/route.js +1 -1
  316. package/app/.next-cli-build/server/app/api/settings/route.js.nft.json +1 -1
  317. package/app/.next-cli-build/server/app/api/shutdown/route.js +1 -1
  318. package/app/.next-cli-build/server/app/api/shutdown/route.js.nft.json +1 -1
  319. package/app/.next-cli-build/server/app/api/tags/route.js +1 -1
  320. package/app/.next-cli-build/server/app/api/tags/route.js.nft.json +1 -1
  321. package/app/.next-cli-build/server/app/api/translator/console-logs/route.js +1 -1
  322. package/app/.next-cli-build/server/app/api/translator/console-logs/route.js.nft.json +1 -1
  323. package/app/.next-cli-build/server/app/api/translator/console-logs/stream/route.js +2 -2
  324. package/app/.next-cli-build/server/app/api/translator/console-logs/stream/route.js.nft.json +1 -1
  325. package/app/.next-cli-build/server/app/api/translator/load/route.js +1 -1
  326. package/app/.next-cli-build/server/app/api/translator/load/route.js.nft.json +1 -1
  327. package/app/.next-cli-build/server/app/api/translator/save/route.js +1 -1
  328. package/app/.next-cli-build/server/app/api/translator/save/route.js.nft.json +1 -1
  329. package/app/.next-cli-build/server/app/api/translator/send/route.js +1 -1
  330. package/app/.next-cli-build/server/app/api/translator/send/route.js.nft.json +1 -1
  331. package/app/.next-cli-build/server/app/api/translator/translate/route.js +1 -1
  332. package/app/.next-cli-build/server/app/api/translator/translate/route.js.nft.json +1 -1
  333. package/app/.next-cli-build/server/app/api/tunnel/disable/route.js +1 -1
  334. package/app/.next-cli-build/server/app/api/tunnel/disable/route.js.nft.json +1 -1
  335. package/app/.next-cli-build/server/app/api/tunnel/enable/route.js +1 -1
  336. package/app/.next-cli-build/server/app/api/tunnel/enable/route.js.nft.json +1 -1
  337. package/app/.next-cli-build/server/app/api/tunnel/status/route.js +1 -1
  338. package/app/.next-cli-build/server/app/api/tunnel/status/route.js.nft.json +1 -1
  339. package/app/.next-cli-build/server/app/api/tunnel/tailscale-check/route.js +1 -1
  340. package/app/.next-cli-build/server/app/api/tunnel/tailscale-check/route.js.nft.json +1 -1
  341. package/app/.next-cli-build/server/app/api/tunnel/tailscale-disable/route.js +1 -1
  342. package/app/.next-cli-build/server/app/api/tunnel/tailscale-disable/route.js.nft.json +1 -1
  343. package/app/.next-cli-build/server/app/api/tunnel/tailscale-enable/route.js +1 -1
  344. package/app/.next-cli-build/server/app/api/tunnel/tailscale-enable/route.js.nft.json +1 -1
  345. package/app/.next-cli-build/server/app/api/tunnel/tailscale-install/route.js +2 -2
  346. package/app/.next-cli-build/server/app/api/tunnel/tailscale-install/route.js.nft.json +1 -1
  347. package/app/.next-cli-build/server/app/api/usage/[connectionId]/claude-reset/route.js +1 -0
  348. package/app/.next-cli-build/server/app/api/usage/[connectionId]/claude-reset/route.js.nft.json +1 -0
  349. package/app/.next-cli-build/server/app/api/usage/[connectionId]/claude-reset/route_client-reference-manifest.js +1 -0
  350. package/app/.next-cli-build/server/app/api/usage/[connectionId]/codex-reset-credits/route.js +1 -1
  351. package/app/.next-cli-build/server/app/api/usage/[connectionId]/codex-reset-credits/route.js.nft.json +1 -1
  352. package/app/.next-cli-build/server/app/api/usage/[connectionId]/route.js +1 -1
  353. package/app/.next-cli-build/server/app/api/usage/[connectionId]/route.js.nft.json +1 -1
  354. package/app/.next-cli-build/server/app/api/usage/chart/route.js +1 -1
  355. package/app/.next-cli-build/server/app/api/usage/chart/route.js.nft.json +1 -1
  356. package/app/.next-cli-build/server/app/api/usage/history/route.js +1 -1
  357. package/app/.next-cli-build/server/app/api/usage/history/route.js.nft.json +1 -1
  358. package/app/.next-cli-build/server/app/api/usage/logs/route.js +1 -1
  359. package/app/.next-cli-build/server/app/api/usage/logs/route.js.nft.json +1 -1
  360. package/app/.next-cli-build/server/app/api/usage/providers/route.js +1 -1
  361. package/app/.next-cli-build/server/app/api/usage/providers/route.js.nft.json +1 -1
  362. package/app/.next-cli-build/server/app/api/usage/request-details/route.js +1 -1
  363. package/app/.next-cli-build/server/app/api/usage/request-details/route.js.nft.json +1 -1
  364. package/app/.next-cli-build/server/app/api/usage/request-logs/route.js +1 -1
  365. package/app/.next-cli-build/server/app/api/usage/request-logs/route.js.nft.json +1 -1
  366. package/app/.next-cli-build/server/app/api/usage/stats/route.js +1 -1
  367. package/app/.next-cli-build/server/app/api/usage/stats/route.js.nft.json +1 -1
  368. package/app/.next-cli-build/server/app/api/usage/stream/route.js +1 -1
  369. package/app/.next-cli-build/server/app/api/usage/stream/route.js.nft.json +1 -1
  370. package/app/.next-cli-build/server/app/api/v1/api/chat/route.js +1 -1
  371. package/app/.next-cli-build/server/app/api/v1/api/chat/route.js.nft.json +1 -1
  372. package/app/.next-cli-build/server/app/api/v1/audio/speech/route.js +1 -1
  373. package/app/.next-cli-build/server/app/api/v1/audio/speech/route.js.nft.json +1 -1
  374. package/app/.next-cli-build/server/app/api/v1/audio/transcriptions/route.js +1 -1
  375. package/app/.next-cli-build/server/app/api/v1/audio/transcriptions/route.js.nft.json +1 -1
  376. package/app/.next-cli-build/server/app/api/v1/audio/voices/route.js +1 -1
  377. package/app/.next-cli-build/server/app/api/v1/audio/voices/route.js.nft.json +1 -1
  378. package/app/.next-cli-build/server/app/api/v1/chat/completions/route.js +1 -1
  379. package/app/.next-cli-build/server/app/api/v1/chat/completions/route.js.nft.json +1 -1
  380. package/app/.next-cli-build/server/app/api/v1/embeddings/route.js +1 -1
  381. package/app/.next-cli-build/server/app/api/v1/embeddings/route.js.nft.json +1 -1
  382. package/app/.next-cli-build/server/app/api/v1/images/generations/route.js +1 -1
  383. package/app/.next-cli-build/server/app/api/v1/images/generations/route.js.nft.json +1 -1
  384. package/app/.next-cli-build/server/app/api/v1/messages/count_tokens/route.js +1 -1
  385. package/app/.next-cli-build/server/app/api/v1/messages/count_tokens/route.js.nft.json +1 -1
  386. package/app/.next-cli-build/server/app/api/v1/messages/route.js +1 -1
  387. package/app/.next-cli-build/server/app/api/v1/messages/route.js.nft.json +1 -1
  388. package/app/.next-cli-build/server/app/api/v1/models/[...model]/route.js +1 -1
  389. package/app/.next-cli-build/server/app/api/v1/models/[...model]/route.js.nft.json +1 -1
  390. package/app/.next-cli-build/server/app/api/v1/models/info/route.js +1 -1
  391. package/app/.next-cli-build/server/app/api/v1/models/info/route.js.nft.json +1 -1
  392. package/app/.next-cli-build/server/app/api/v1/models/route.js +1 -1
  393. package/app/.next-cli-build/server/app/api/v1/models/route.js.nft.json +1 -1
  394. package/app/.next-cli-build/server/app/api/v1/responses/compact/route.js +1 -1
  395. package/app/.next-cli-build/server/app/api/v1/responses/compact/route.js.nft.json +1 -1
  396. package/app/.next-cli-build/server/app/api/v1/responses/route.js +1 -1
  397. package/app/.next-cli-build/server/app/api/v1/responses/route.js.nft.json +1 -1
  398. package/app/.next-cli-build/server/app/api/v1/route.js +1 -1
  399. package/app/.next-cli-build/server/app/api/v1/route.js.nft.json +1 -1
  400. package/app/.next-cli-build/server/app/api/v1/search/route.js +1 -1
  401. package/app/.next-cli-build/server/app/api/v1/search/route.js.nft.json +1 -1
  402. package/app/.next-cli-build/server/app/api/v1/systemone/route.js +1 -1
  403. package/app/.next-cli-build/server/app/api/v1/systemone/route.js.nft.json +1 -1
  404. package/app/.next-cli-build/server/app/api/v1/videos/[id]/route.js +1 -1
  405. package/app/.next-cli-build/server/app/api/v1/videos/[id]/route.js.nft.json +1 -1
  406. package/app/.next-cli-build/server/app/api/v1/videos/edits/route.js +1 -1
  407. package/app/.next-cli-build/server/app/api/v1/videos/edits/route.js.nft.json +1 -1
  408. package/app/.next-cli-build/server/app/api/v1/videos/extensions/route.js +1 -1
  409. package/app/.next-cli-build/server/app/api/v1/videos/extensions/route.js.nft.json +1 -1
  410. package/app/.next-cli-build/server/app/api/v1/videos/generations/route.js +1 -1
  411. package/app/.next-cli-build/server/app/api/v1/videos/generations/route.js.nft.json +1 -1
  412. package/app/.next-cli-build/server/app/api/v1/web/fetch/route.js +1 -1
  413. package/app/.next-cli-build/server/app/api/v1/web/fetch/route.js.nft.json +1 -1
  414. package/app/.next-cli-build/server/app/api/v1beta/models/[...path]/route.js +1 -1
  415. package/app/.next-cli-build/server/app/api/v1beta/models/[...path]/route.js.nft.json +1 -1
  416. package/app/.next-cli-build/server/app/api/v1beta/models/route.js +1 -1
  417. package/app/.next-cli-build/server/app/api/v1beta/models/route.js.nft.json +1 -1
  418. package/app/.next-cli-build/server/app/api/version/route.js +1 -1
  419. package/app/.next-cli-build/server/app/api/version/route.js.nft.json +1 -1
  420. package/app/.next-cli-build/server/app/api/version/shutdown/route.js +1 -1
  421. package/app/.next-cli-build/server/app/api/version/shutdown/route.js.nft.json +1 -1
  422. package/app/.next-cli-build/server/app/api/version/update/route.js +1 -1
  423. package/app/.next-cli-build/server/app/api/version/update/route.js.nft.json +1 -1
  424. package/app/.next-cli-build/server/app/callback/page.js +1 -1
  425. package/app/.next-cli-build/server/app/callback/page.js.nft.json +1 -1
  426. package/app/.next-cli-build/server/app/callback/page_client-reference-manifest.js +1 -1
  427. package/app/.next-cli-build/server/app/callback.html +1 -1
  428. package/app/.next-cli-build/server/app/callback.rsc +5 -5
  429. package/app/.next-cli-build/server/app/callback.segments/_full.segment.rsc +5 -5
  430. package/app/.next-cli-build/server/app/callback.segments/_tree.segment.rsc +2 -2
  431. package/app/.next-cli-build/server/app/callback.segments/callback/__PAGE__.segment.rsc +5 -5
  432. package/app/.next-cli-build/server/app/dashboard/basic-chat.html +1 -1
  433. package/app/.next-cli-build/server/app/dashboard/basic-chat.rsc +7 -7
  434. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk/dashboard/basic-chat/__PAGE__.segment.rsc +7 -7
  435. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_full.segment.rsc +7 -7
  436. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_tree.segment.rsc +2 -2
  437. package/app/.next-cli-build/server/app/dashboard/cli-tools.html +1 -1
  438. package/app/.next-cli-build/server/app/dashboard/cli-tools.rsc +7 -7
  439. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk/dashboard/cli-tools/__PAGE__.segment.rsc +7 -7
  440. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_full.segment.rsc +7 -7
  441. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_tree.segment.rsc +2 -2
  442. package/app/.next-cli-build/server/app/dashboard/combos.html +1 -1
  443. package/app/.next-cli-build/server/app/dashboard/combos.rsc +7 -7
  444. package/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk/dashboard/combos/__PAGE__.segment.rsc +7 -7
  445. package/app/.next-cli-build/server/app/dashboard/combos.segments/_full.segment.rsc +7 -7
  446. package/app/.next-cli-build/server/app/dashboard/combos.segments/_tree.segment.rsc +2 -2
  447. package/app/.next-cli-build/server/app/dashboard/endpoint.html +1 -1
  448. package/app/.next-cli-build/server/app/dashboard/endpoint.rsc +7 -7
  449. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk/dashboard/endpoint/__PAGE__.segment.rsc +7 -7
  450. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_full.segment.rsc +7 -7
  451. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_tree.segment.rsc +2 -2
  452. package/app/.next-cli-build/server/app/dashboard/media-providers/web.html +1 -1
  453. package/app/.next-cli-build/server/app/dashboard/media-providers/web.rsc +7 -7
  454. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard/media-providers/web/__PAGE__.segment.rsc +7 -7
  455. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_full.segment.rsc +7 -7
  456. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_tree.segment.rsc +2 -2
  457. package/app/.next-cli-build/server/app/dashboard/mitm.html +1 -1
  458. package/app/.next-cli-build/server/app/dashboard/mitm.rsc +7 -7
  459. package/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk/dashboard/mitm/__PAGE__.segment.rsc +7 -7
  460. package/app/.next-cli-build/server/app/dashboard/mitm.segments/_full.segment.rsc +7 -7
  461. package/app/.next-cli-build/server/app/dashboard/mitm.segments/_tree.segment.rsc +2 -2
  462. package/app/.next-cli-build/server/app/dashboard/profile.html +1 -1
  463. package/app/.next-cli-build/server/app/dashboard/profile.rsc +7 -7
  464. package/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk/dashboard/profile/__PAGE__.segment.rsc +7 -7
  465. package/app/.next-cli-build/server/app/dashboard/profile.segments/_full.segment.rsc +7 -7
  466. package/app/.next-cli-build/server/app/dashboard/profile.segments/_tree.segment.rsc +2 -2
  467. package/app/.next-cli-build/server/app/dashboard/providers/new.html +1 -1
  468. package/app/.next-cli-build/server/app/dashboard/providers/new.rsc +7 -7
  469. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard/providers/new/__PAGE__.segment.rsc +7 -7
  470. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_full.segment.rsc +7 -7
  471. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_tree.segment.rsc +2 -2
  472. package/app/.next-cli-build/server/app/dashboard/providers.html +1 -1
  473. package/app/.next-cli-build/server/app/dashboard/providers.rsc +7 -7
  474. package/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk/dashboard/providers/__PAGE__.segment.rsc +7 -7
  475. package/app/.next-cli-build/server/app/dashboard/providers.segments/_full.segment.rsc +7 -7
  476. package/app/.next-cli-build/server/app/dashboard/providers.segments/_tree.segment.rsc +2 -2
  477. package/app/.next-cli-build/server/app/dashboard/proxy-pools.html +1 -1
  478. package/app/.next-cli-build/server/app/dashboard/proxy-pools.rsc +7 -7
  479. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk/dashboard/proxy-pools/__PAGE__.segment.rsc +7 -7
  480. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_full.segment.rsc +7 -7
  481. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_tree.segment.rsc +2 -2
  482. package/app/.next-cli-build/server/app/dashboard/pxpipe.html +1 -1
  483. package/app/.next-cli-build/server/app/dashboard/pxpipe.rsc +7 -7
  484. package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/!KGRhc2hib2FyZCk/dashboard/pxpipe/__PAGE__.segment.rsc +7 -7
  485. package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/_full.segment.rsc +7 -7
  486. package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/_tree.segment.rsc +2 -2
  487. package/app/.next-cli-build/server/app/dashboard/quota.html +2 -2
  488. package/app/.next-cli-build/server/app/dashboard/quota.rsc +8 -8
  489. package/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk/dashboard/quota/__PAGE__.segment.rsc +8 -8
  490. package/app/.next-cli-build/server/app/dashboard/quota.segments/_full.segment.rsc +8 -8
  491. package/app/.next-cli-build/server/app/dashboard/quota.segments/_tree.segment.rsc +2 -2
  492. package/app/.next-cli-build/server/app/dashboard/settings/pricing/page.js +1 -1
  493. package/app/.next-cli-build/server/app/dashboard/settings/pricing/page.js.nft.json +1 -1
  494. package/app/.next-cli-build/server/app/dashboard/settings/pricing/page_client-reference-manifest.js +1 -1
  495. package/app/.next-cli-build/server/app/dashboard/settings/pricing.html +1 -1
  496. package/app/.next-cli-build/server/app/dashboard/settings/pricing.rsc +6 -6
  497. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_full.segment.rsc +6 -6
  498. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_tree.segment.rsc +2 -2
  499. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/dashboard/settings/pricing/__PAGE__.segment.rsc +6 -6
  500. package/app/.next-cli-build/server/app/dashboard/skills.html +1 -1
  501. package/app/.next-cli-build/server/app/dashboard/skills.rsc +7 -7
  502. package/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk/dashboard/skills/__PAGE__.segment.rsc +7 -7
  503. package/app/.next-cli-build/server/app/dashboard/skills.segments/_full.segment.rsc +7 -7
  504. package/app/.next-cli-build/server/app/dashboard/skills.segments/_tree.segment.rsc +2 -2
  505. package/app/.next-cli-build/server/app/dashboard/token-saver.html +1 -1
  506. package/app/.next-cli-build/server/app/dashboard/token-saver.rsc +7 -7
  507. package/app/.next-cli-build/server/app/dashboard/token-saver.segments/!KGRhc2hib2FyZCk/dashboard/token-saver/__PAGE__.segment.rsc +7 -7
  508. package/app/.next-cli-build/server/app/dashboard/token-saver.segments/_full.segment.rsc +7 -7
  509. package/app/.next-cli-build/server/app/dashboard/token-saver.segments/_tree.segment.rsc +2 -2
  510. package/app/.next-cli-build/server/app/dashboard/translator.html +1 -1
  511. package/app/.next-cli-build/server/app/dashboard/translator.rsc +7 -7
  512. package/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk/dashboard/translator/__PAGE__.segment.rsc +7 -7
  513. package/app/.next-cli-build/server/app/dashboard/translator.segments/_full.segment.rsc +7 -7
  514. package/app/.next-cli-build/server/app/dashboard/translator.segments/_tree.segment.rsc +2 -2
  515. package/app/.next-cli-build/server/app/dashboard/usage.html +1 -1
  516. package/app/.next-cli-build/server/app/dashboard/usage.rsc +7 -7
  517. package/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk/dashboard/usage/__PAGE__.segment.rsc +7 -7
  518. package/app/.next-cli-build/server/app/dashboard/usage.segments/_full.segment.rsc +7 -7
  519. package/app/.next-cli-build/server/app/dashboard/usage.segments/_tree.segment.rsc +2 -2
  520. package/app/.next-cli-build/server/app/dashboard.html +1 -1
  521. package/app/.next-cli-build/server/app/dashboard.rsc +7 -7
  522. package/app/.next-cli-build/server/app/dashboard.segments/!KGRhc2hib2FyZCk/dashboard/__PAGE__.segment.rsc +7 -7
  523. package/app/.next-cli-build/server/app/dashboard.segments/_full.segment.rsc +7 -7
  524. package/app/.next-cli-build/server/app/dashboard.segments/_tree.segment.rsc +2 -2
  525. package/app/.next-cli-build/server/app/favicon.ico/route.js +1 -1
  526. package/app/.next-cli-build/server/app/favicon.ico/route.js.nft.json +1 -1
  527. package/app/.next-cli-build/server/app/index.html +1 -1
  528. package/app/.next-cli-build/server/app/index.rsc +5 -5
  529. package/app/.next-cli-build/server/app/index.segments/__PAGE__.segment.rsc +5 -5
  530. package/app/.next-cli-build/server/app/index.segments/_full.segment.rsc +5 -5
  531. package/app/.next-cli-build/server/app/index.segments/_tree.segment.rsc +2 -2
  532. package/app/.next-cli-build/server/app/landing/page.js +1 -1
  533. package/app/.next-cli-build/server/app/landing/page.js.nft.json +1 -1
  534. package/app/.next-cli-build/server/app/landing/page_client-reference-manifest.js +1 -1
  535. package/app/.next-cli-build/server/app/landing.html +1 -1
  536. package/app/.next-cli-build/server/app/landing.rsc +5 -5
  537. package/app/.next-cli-build/server/app/landing.segments/_full.segment.rsc +5 -5
  538. package/app/.next-cli-build/server/app/landing.segments/_tree.segment.rsc +2 -2
  539. package/app/.next-cli-build/server/app/landing.segments/landing/__PAGE__.segment.rsc +5 -5
  540. package/app/.next-cli-build/server/app/login/page.js +1 -1
  541. package/app/.next-cli-build/server/app/login/page.js.nft.json +1 -1
  542. package/app/.next-cli-build/server/app/login/page_client-reference-manifest.js +1 -1
  543. package/app/.next-cli-build/server/app/login.html +1 -1
  544. package/app/.next-cli-build/server/app/login.rsc +6 -6
  545. package/app/.next-cli-build/server/app/login.segments/_full.segment.rsc +6 -6
  546. package/app/.next-cli-build/server/app/login.segments/_tree.segment.rsc +2 -2
  547. package/app/.next-cli-build/server/app/login.segments/login/__PAGE__.segment.rsc +6 -6
  548. package/app/.next-cli-build/server/app/manifest.webmanifest/route.js +2 -2
  549. package/app/.next-cli-build/server/app/manifest.webmanifest/route.js.nft.json +1 -1
  550. package/app/.next-cli-build/server/app/page.js +1 -1
  551. package/app/.next-cli-build/server/app/page.js.nft.json +1 -1
  552. package/app/.next-cli-build/server/app/page_client-reference-manifest.js +1 -1
  553. package/app/.next-cli-build/server/app-paths-manifest.json +17 -16
  554. package/app/.next-cli-build/server/chunks/1679.js +1 -1
  555. package/app/.next-cli-build/server/chunks/24.js +1 -1
  556. package/app/.next-cli-build/server/chunks/2778.js +1 -1
  557. package/app/.next-cli-build/server/chunks/3943.js +1 -1
  558. package/app/.next-cli-build/server/chunks/4037.js +1 -1
  559. package/app/.next-cli-build/server/chunks/4049.js +1 -1
  560. package/app/.next-cli-build/server/chunks/412.js +1 -1
  561. package/app/.next-cli-build/server/chunks/4123.js +1 -1
  562. package/app/.next-cli-build/server/chunks/4572.js +1 -1
  563. package/app/.next-cli-build/server/chunks/4961.js +1 -1
  564. package/app/.next-cli-build/server/chunks/5237.js +1 -1
  565. package/app/.next-cli-build/server/chunks/5330.js +5 -5
  566. package/app/.next-cli-build/server/chunks/5524.js +1 -1
  567. package/app/.next-cli-build/server/chunks/5615.js +2 -2
  568. package/app/.next-cli-build/server/chunks/5670.js +1 -1
  569. package/app/.next-cli-build/server/chunks/6070.js +1 -1
  570. package/app/.next-cli-build/server/chunks/6249.js +2 -2
  571. package/app/.next-cli-build/server/chunks/6763.js +1 -1
  572. package/app/.next-cli-build/server/chunks/6777.js +1 -1
  573. package/app/.next-cli-build/server/chunks/6877.js +1 -1
  574. package/app/.next-cli-build/server/chunks/6922.js +1 -1
  575. package/app/.next-cli-build/server/chunks/7211.js +1 -1
  576. package/app/.next-cli-build/server/chunks/7220.js +1 -1
  577. package/app/.next-cli-build/server/chunks/7247.js +1 -1
  578. package/app/.next-cli-build/server/chunks/7716.js +1 -1
  579. package/app/.next-cli-build/server/chunks/8145.js +1 -1
  580. package/app/.next-cli-build/server/chunks/827.js +1 -1
  581. package/app/.next-cli-build/server/chunks/8363.js +1 -1
  582. package/app/.next-cli-build/server/chunks/8402.js +1 -1
  583. package/app/.next-cli-build/server/chunks/8499.js +11 -11
  584. package/app/.next-cli-build/server/chunks/8587.js +1 -0
  585. package/app/.next-cli-build/server/chunks/8635.js +1 -1
  586. package/app/.next-cli-build/server/chunks/8895.js +10 -10
  587. package/app/.next-cli-build/server/chunks/8920.js +1 -1
  588. package/app/.next-cli-build/server/chunks/9076.js +1 -1
  589. package/app/.next-cli-build/server/chunks/9128.js +1 -1
  590. package/app/.next-cli-build/server/chunks/9181.js +1 -1
  591. package/app/.next-cli-build/server/chunks/9765.js +1 -0
  592. package/app/.next-cli-build/server/instrumentation.js +1 -1
  593. package/app/.next-cli-build/server/instrumentation.js.nft.json +1 -1
  594. package/app/.next-cli-build/server/middleware-build-manifest.js +1 -1
  595. package/app/.next-cli-build/server/middleware.js +3 -3
  596. package/app/.next-cli-build/server/middleware.js.nft.json +1 -1
  597. package/app/.next-cli-build/server/pages/404.html +1 -1
  598. package/app/.next-cli-build/server/pages/500.html +1 -1
  599. package/app/.next-cli-build/server/server-reference-manifest.js +1 -1
  600. package/app/.next-cli-build/server/server-reference-manifest.json +1 -1
  601. package/app/.next-cli-build/static/chunks/1321-ba798be7ef223475.js +1 -0
  602. package/app/.next-cli-build/static/chunks/{5497-0a176f0c561c3ed0.js → 5497-7130e302b038bd53.js} +2 -2
  603. package/app/.next-cli-build/static/chunks/{6447-7dc1a52c10964d06.js → 6447-8c30ca0cd19a2827.js} +1 -1
  604. package/app/.next-cli-build/static/chunks/705-295d5a491126ba0f.js +1 -0
  605. package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/providers/[id]/page-e5b2b18f79f00d51.js +27 -0
  606. package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/quota/page-4f578f99d7b58b82.js +1 -0
  607. package/app/.next-cli-build/static/chunks/app/_global-error/page-1b9308dbbaa9a160.js +1 -0
  608. package/app/.next-cli-build/static/chunks/app/api/auth/login/route-1b9308dbbaa9a160.js +1 -0
  609. package/app/.next-cli-build/static/chunks/app/api/auth/logout/route-1b9308dbbaa9a160.js +1 -0
  610. package/app/.next-cli-build/static/chunks/app/api/auth/oidc/callback/route-1b9308dbbaa9a160.js +1 -0
  611. package/app/.next-cli-build/static/chunks/app/api/auth/oidc/start/route-1b9308dbbaa9a160.js +1 -0
  612. package/app/.next-cli-build/static/chunks/app/api/auth/oidc/test/route-1b9308dbbaa9a160.js +1 -0
  613. package/app/.next-cli-build/static/chunks/app/api/auth/reset-password/route-1b9308dbbaa9a160.js +1 -0
  614. package/app/.next-cli-build/static/chunks/app/api/auth/saml/acs/route-1b9308dbbaa9a160.js +1 -0
  615. package/app/.next-cli-build/static/chunks/app/api/auth/saml/metadata/route-1b9308dbbaa9a160.js +1 -0
  616. package/app/.next-cli-build/static/chunks/app/api/auth/saml/start/route-1b9308dbbaa9a160.js +1 -0
  617. package/app/.next-cli-build/static/chunks/app/api/auth/saml/test/route-1b9308dbbaa9a160.js +1 -0
  618. package/app/.next-cli-build/static/chunks/app/api/auth/status/route-1b9308dbbaa9a160.js +1 -0
  619. package/app/.next-cli-build/static/chunks/app/api/cli-tools/all-statuses/route-1b9308dbbaa9a160.js +1 -0
  620. package/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/alias/route-1b9308dbbaa9a160.js +1 -0
  621. package/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/route-1b9308dbbaa9a160.js +1 -0
  622. package/app/.next-cli-build/static/chunks/app/api/cli-tools/claude-settings/route-1b9308dbbaa9a160.js +1 -0
  623. package/app/.next-cli-build/static/chunks/app/api/cli-tools/cline-settings/route-1b9308dbbaa9a160.js +1 -0
  624. package/app/.next-cli-build/static/chunks/app/api/cli-tools/codewhale-settings/route-1b9308dbbaa9a160.js +1 -0
  625. package/app/.next-cli-build/static/chunks/app/api/cli-tools/codex-settings/route-1b9308dbbaa9a160.js +1 -0
  626. package/app/.next-cli-build/static/chunks/app/api/cli-tools/copilot-settings/route-1b9308dbbaa9a160.js +1 -0
  627. package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-registry/route-1b9308dbbaa9a160.js +1 -0
  628. package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-tools/route-1b9308dbbaa9a160.js +1 -0
  629. package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-settings/route-1b9308dbbaa9a160.js +1 -0
  630. package/app/.next-cli-build/static/chunks/app/api/cli-tools/crush-settings/route-1b9308dbbaa9a160.js +1 -0
  631. package/app/.next-cli-build/static/chunks/app/api/cli-tools/deepseek-tui-settings/route-1b9308dbbaa9a160.js +1 -0
  632. package/app/.next-cli-build/static/chunks/app/api/cli-tools/droid-settings/route-1b9308dbbaa9a160.js +1 -0
  633. package/app/.next-cli-build/static/chunks/app/api/cli-tools/forge-settings/route-1b9308dbbaa9a160.js +1 -0
  634. package/app/.next-cli-build/static/chunks/app/api/cli-tools/grok-build-settings/route-1b9308dbbaa9a160.js +1 -0
  635. package/app/.next-cli-build/static/chunks/app/api/cli-tools/hermes-settings/route-1b9308dbbaa9a160.js +1 -0
  636. package/app/.next-cli-build/static/chunks/app/api/cli-tools/jcode-settings/route-1b9308dbbaa9a160.js +1 -0
  637. package/app/.next-cli-build/static/chunks/app/api/cli-tools/kilo-settings/route-1b9308dbbaa9a160.js +1 -0
  638. package/app/.next-cli-build/static/chunks/app/api/cli-tools/omp-settings/route-1b9308dbbaa9a160.js +1 -0
  639. package/app/.next-cli-build/static/chunks/app/api/cli-tools/openclaw-settings/route-1b9308dbbaa9a160.js +1 -0
  640. package/app/.next-cli-build/static/chunks/app/api/cli-tools/opencode-settings/route-1b9308dbbaa9a160.js +1 -0
  641. package/app/.next-cli-build/static/chunks/app/api/cli-tools/pi-settings/route-1b9308dbbaa9a160.js +1 -0
  642. package/app/.next-cli-build/static/chunks/app/api/cli-tools/smelt-settings/route-1b9308dbbaa9a160.js +1 -0
  643. package/app/.next-cli-build/static/chunks/app/api/combos/[id]/route-1b9308dbbaa9a160.js +1 -0
  644. package/app/.next-cli-build/static/chunks/app/api/combos/presets/route-1b9308dbbaa9a160.js +1 -0
  645. package/app/.next-cli-build/static/chunks/app/api/combos/route-1b9308dbbaa9a160.js +1 -0
  646. package/app/.next-cli-build/static/chunks/app/api/headroom/extras/route-1b9308dbbaa9a160.js +1 -0
  647. package/app/.next-cli-build/static/chunks/app/api/headroom/proxy/[...path]/route-1b9308dbbaa9a160.js +1 -0
  648. package/app/.next-cli-build/static/chunks/app/api/headroom/restart/route-1b9308dbbaa9a160.js +1 -0
  649. package/app/.next-cli-build/static/chunks/app/api/headroom/start/route-1b9308dbbaa9a160.js +1 -0
  650. package/app/.next-cli-build/static/chunks/app/api/headroom/status/route-1b9308dbbaa9a160.js +1 -0
  651. package/app/.next-cli-build/static/chunks/app/api/headroom/stop/route-1b9308dbbaa9a160.js +1 -0
  652. package/app/.next-cli-build/static/chunks/app/api/health/route-1b9308dbbaa9a160.js +1 -0
  653. package/app/.next-cli-build/static/chunks/app/api/init/route-1b9308dbbaa9a160.js +1 -0
  654. package/app/.next-cli-build/static/chunks/app/api/keys/[id]/route-1b9308dbbaa9a160.js +1 -0
  655. package/app/.next-cli-build/static/chunks/app/api/keys/route-1b9308dbbaa9a160.js +1 -0
  656. package/app/.next-cli-build/static/chunks/app/api/locale/route-1b9308dbbaa9a160.js +1 -0
  657. package/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/message/route-1b9308dbbaa9a160.js +1 -0
  658. package/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/sse/route-1b9308dbbaa9a160.js +1 -0
  659. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/deepgram/voices/route-1b9308dbbaa9a160.js +1 -0
  660. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/elevenlabs/voices/route-1b9308dbbaa9a160.js +1 -0
  661. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/inworld/voices/route-1b9308dbbaa9a160.js +1 -0
  662. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/minimax/voices/route-1b9308dbbaa9a160.js +1 -0
  663. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/voices/route-1b9308dbbaa9a160.js +1 -0
  664. package/app/.next-cli-build/static/chunks/app/api/models/alias/route-1b9308dbbaa9a160.js +1 -0
  665. package/app/.next-cli-build/static/chunks/app/api/models/availability/route-1b9308dbbaa9a160.js +1 -0
  666. package/app/.next-cli-build/static/chunks/app/api/models/catalog-sync/route-1b9308dbbaa9a160.js +1 -0
  667. package/app/.next-cli-build/static/chunks/app/api/models/custom/route-1b9308dbbaa9a160.js +1 -0
  668. package/app/.next-cli-build/static/chunks/app/api/models/disabled/route-1b9308dbbaa9a160.js +1 -0
  669. package/app/.next-cli-build/static/chunks/app/api/models/route-1b9308dbbaa9a160.js +1 -0
  670. package/app/.next-cli-build/static/chunks/app/api/models/test/route-1b9308dbbaa9a160.js +1 -0
  671. package/app/.next-cli-build/static/chunks/app/api/oauth/[provider]/[action]/route-1b9308dbbaa9a160.js +1 -0
  672. package/app/.next-cli-build/static/chunks/app/api/oauth/codex/bulk-import/route-1b9308dbbaa9a160.js +1 -0
  673. package/app/.next-cli-build/static/chunks/app/api/oauth/codex/import-token/route-1b9308dbbaa9a160.js +1 -0
  674. package/app/.next-cli-build/static/chunks/app/api/oauth/cursor/auto-import/route-1b9308dbbaa9a160.js +1 -0
  675. package/app/.next-cli-build/static/chunks/app/api/oauth/cursor/import/route-1b9308dbbaa9a160.js +1 -0
  676. package/app/.next-cli-build/static/chunks/app/api/oauth/gitlab/pat/route-1b9308dbbaa9a160.js +1 -0
  677. package/app/.next-cli-build/static/chunks/app/api/oauth/grok-cli/bulk-import/route-1b9308dbbaa9a160.js +1 -0
  678. package/app/.next-cli-build/static/chunks/app/api/oauth/iflow/cookie/route-1b9308dbbaa9a160.js +1 -0
  679. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/api-key/route-1b9308dbbaa9a160.js +1 -0
  680. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/auto-import/route-1b9308dbbaa9a160.js +1 -0
  681. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/import/route-1b9308dbbaa9a160.js +1 -0
  682. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/import-cli-proxy/route-1b9308dbbaa9a160.js +1 -0
  683. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-authorize/route-1b9308dbbaa9a160.js +1 -0
  684. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-exchange/route-1b9308dbbaa9a160.js +1 -0
  685. package/app/.next-cli-build/static/chunks/app/api/oauth/xiaomi-mimo/api-key/route-1b9308dbbaa9a160.js +1 -0
  686. package/app/.next-cli-build/static/chunks/app/api/oauth/xiaomi-mimo/auto-import/route-1b9308dbbaa9a160.js +1 -0
  687. package/app/.next-cli-build/static/chunks/app/api/oauth/xiaomi-mimo/login/start/route-1b9308dbbaa9a160.js +1 -0
  688. package/app/.next-cli-build/static/chunks/app/api/oauth/xiaomi-mimo/login/status/route-1b9308dbbaa9a160.js +1 -0
  689. package/app/.next-cli-build/static/chunks/app/api/pricing/route-1b9308dbbaa9a160.js +1 -0
  690. package/app/.next-cli-build/static/chunks/app/api/provider-nodes/[id]/route-1b9308dbbaa9a160.js +1 -0
  691. package/app/.next-cli-build/static/chunks/app/api/provider-nodes/route-1b9308dbbaa9a160.js +1 -0
  692. package/app/.next-cli-build/static/chunks/app/api/provider-nodes/validate/route-1b9308dbbaa9a160.js +1 -0
  693. package/app/.next-cli-build/static/chunks/app/api/providers/[id]/models/route-1b9308dbbaa9a160.js +1 -0
  694. package/app/.next-cli-build/static/chunks/app/api/providers/[id]/route-1b9308dbbaa9a160.js +1 -0
  695. package/app/.next-cli-build/static/chunks/app/api/providers/[id]/test/route-1b9308dbbaa9a160.js +1 -0
  696. package/app/.next-cli-build/static/chunks/app/api/providers/[id]/test-models/route-1b9308dbbaa9a160.js +1 -0
  697. package/app/.next-cli-build/static/chunks/app/api/providers/client/route-1b9308dbbaa9a160.js +1 -0
  698. package/app/.next-cli-build/static/chunks/app/api/providers/kilo/free-models/route-1b9308dbbaa9a160.js +1 -0
  699. package/app/.next-cli-build/static/chunks/app/api/providers/route-1b9308dbbaa9a160.js +1 -0
  700. package/app/.next-cli-build/static/chunks/app/api/providers/suggested-models/route-1b9308dbbaa9a160.js +1 -0
  701. package/app/.next-cli-build/static/chunks/app/api/providers/test-batch/route-1b9308dbbaa9a160.js +1 -0
  702. package/app/.next-cli-build/static/chunks/app/api/providers/validate/route-1b9308dbbaa9a160.js +1 -0
  703. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/route-1b9308dbbaa9a160.js +1 -0
  704. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/test/route-1b9308dbbaa9a160.js +1 -0
  705. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/cloudflare-deploy/route-1b9308dbbaa9a160.js +1 -0
  706. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/deno-deploy/route-1b9308dbbaa9a160.js +1 -0
  707. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/route-1b9308dbbaa9a160.js +1 -0
  708. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/vercel-deploy/route-1b9308dbbaa9a160.js +1 -0
  709. package/app/.next-cli-build/static/chunks/app/api/pxpipe/health/route-1b9308dbbaa9a160.js +1 -0
  710. package/app/.next-cli-build/static/chunks/app/api/pxpipe/install/route-1b9308dbbaa9a160.js +1 -0
  711. package/app/.next-cli-build/static/chunks/app/api/pxpipe/logs/route-1b9308dbbaa9a160.js +1 -0
  712. package/app/.next-cli-build/static/chunks/app/api/pxpipe/restart/route-1b9308dbbaa9a160.js +1 -0
  713. package/app/.next-cli-build/static/chunks/app/api/pxpipe/start/route-1b9308dbbaa9a160.js +1 -0
  714. package/app/.next-cli-build/static/chunks/app/api/pxpipe/stats/route-1b9308dbbaa9a160.js +1 -0
  715. package/app/.next-cli-build/static/chunks/app/api/pxpipe/status/route-1b9308dbbaa9a160.js +1 -0
  716. package/app/.next-cli-build/static/chunks/app/api/pxpipe/stop/route-1b9308dbbaa9a160.js +1 -0
  717. package/app/.next-cli-build/static/chunks/app/api/settings/database/route-1b9308dbbaa9a160.js +1 -0
  718. package/app/.next-cli-build/static/chunks/app/api/settings/proxy-test/route-1b9308dbbaa9a160.js +1 -0
  719. package/app/.next-cli-build/static/chunks/app/api/settings/require-login/route-1b9308dbbaa9a160.js +1 -0
  720. package/app/.next-cli-build/static/chunks/app/api/settings/route-1b9308dbbaa9a160.js +1 -0
  721. package/app/.next-cli-build/static/chunks/app/api/shutdown/route-1b9308dbbaa9a160.js +1 -0
  722. package/app/.next-cli-build/static/chunks/app/api/tags/route-1b9308dbbaa9a160.js +1 -0
  723. package/app/.next-cli-build/static/chunks/app/api/translator/console-logs/route-1b9308dbbaa9a160.js +1 -0
  724. package/app/.next-cli-build/static/chunks/app/api/translator/console-logs/stream/route-1b9308dbbaa9a160.js +1 -0
  725. package/app/.next-cli-build/static/chunks/app/api/translator/load/route-1b9308dbbaa9a160.js +1 -0
  726. package/app/.next-cli-build/static/chunks/app/api/translator/save/route-1b9308dbbaa9a160.js +1 -0
  727. package/app/.next-cli-build/static/chunks/app/api/translator/send/route-1b9308dbbaa9a160.js +1 -0
  728. package/app/.next-cli-build/static/chunks/app/api/translator/translate/route-1b9308dbbaa9a160.js +1 -0
  729. package/app/.next-cli-build/static/chunks/app/api/tunnel/disable/route-1b9308dbbaa9a160.js +1 -0
  730. package/app/.next-cli-build/static/chunks/app/api/tunnel/enable/route-1b9308dbbaa9a160.js +1 -0
  731. package/app/.next-cli-build/static/chunks/app/api/tunnel/status/route-1b9308dbbaa9a160.js +1 -0
  732. package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-check/route-1b9308dbbaa9a160.js +1 -0
  733. package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-disable/route-1b9308dbbaa9a160.js +1 -0
  734. package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-enable/route-1b9308dbbaa9a160.js +1 -0
  735. package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-install/route-1b9308dbbaa9a160.js +1 -0
  736. package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/claude-reset/route-1b9308dbbaa9a160.js +1 -0
  737. package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/codex-reset-credits/route-1b9308dbbaa9a160.js +1 -0
  738. package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/route-1b9308dbbaa9a160.js +1 -0
  739. package/app/.next-cli-build/static/chunks/app/api/usage/chart/route-1b9308dbbaa9a160.js +1 -0
  740. package/app/.next-cli-build/static/chunks/app/api/usage/history/route-1b9308dbbaa9a160.js +1 -0
  741. package/app/.next-cli-build/static/chunks/app/api/usage/logs/route-1b9308dbbaa9a160.js +1 -0
  742. package/app/.next-cli-build/static/chunks/app/api/usage/providers/route-1b9308dbbaa9a160.js +1 -0
  743. package/app/.next-cli-build/static/chunks/app/api/usage/request-details/route-1b9308dbbaa9a160.js +1 -0
  744. package/app/.next-cli-build/static/chunks/app/api/usage/request-logs/route-1b9308dbbaa9a160.js +1 -0
  745. package/app/.next-cli-build/static/chunks/app/api/usage/stats/route-1b9308dbbaa9a160.js +1 -0
  746. package/app/.next-cli-build/static/chunks/app/api/usage/stream/route-1b9308dbbaa9a160.js +1 -0
  747. package/app/.next-cli-build/static/chunks/app/api/v1/api/chat/route-1b9308dbbaa9a160.js +1 -0
  748. package/app/.next-cli-build/static/chunks/app/api/v1/audio/speech/route-1b9308dbbaa9a160.js +1 -0
  749. package/app/.next-cli-build/static/chunks/app/api/v1/audio/transcriptions/route-1b9308dbbaa9a160.js +1 -0
  750. package/app/.next-cli-build/static/chunks/app/api/v1/audio/voices/route-1b9308dbbaa9a160.js +1 -0
  751. package/app/.next-cli-build/static/chunks/app/api/v1/chat/completions/route-1b9308dbbaa9a160.js +1 -0
  752. package/app/.next-cli-build/static/chunks/app/api/v1/embeddings/route-1b9308dbbaa9a160.js +1 -0
  753. package/app/.next-cli-build/static/chunks/app/api/v1/images/generations/route-1b9308dbbaa9a160.js +1 -0
  754. package/app/.next-cli-build/static/chunks/app/api/v1/messages/count_tokens/route-1b9308dbbaa9a160.js +1 -0
  755. package/app/.next-cli-build/static/chunks/app/api/v1/messages/route-1b9308dbbaa9a160.js +1 -0
  756. package/app/.next-cli-build/static/chunks/app/api/v1/models/[...model]/route-1b9308dbbaa9a160.js +1 -0
  757. package/app/.next-cli-build/static/chunks/app/api/v1/models/info/route-1b9308dbbaa9a160.js +1 -0
  758. package/app/.next-cli-build/static/chunks/app/api/v1/models/route-1b9308dbbaa9a160.js +1 -0
  759. package/app/.next-cli-build/static/chunks/app/api/v1/responses/compact/route-1b9308dbbaa9a160.js +1 -0
  760. package/app/.next-cli-build/static/chunks/app/api/v1/responses/route-1b9308dbbaa9a160.js +1 -0
  761. package/app/.next-cli-build/static/chunks/app/api/v1/route-1b9308dbbaa9a160.js +1 -0
  762. package/app/.next-cli-build/static/chunks/app/api/v1/search/route-1b9308dbbaa9a160.js +1 -0
  763. package/app/.next-cli-build/static/chunks/app/api/v1/systemone/route-1b9308dbbaa9a160.js +1 -0
  764. package/app/.next-cli-build/static/chunks/app/api/v1/videos/[id]/route-1b9308dbbaa9a160.js +1 -0
  765. package/app/.next-cli-build/static/chunks/app/api/v1/videos/edits/route-1b9308dbbaa9a160.js +1 -0
  766. package/app/.next-cli-build/static/chunks/app/api/v1/videos/extensions/route-1b9308dbbaa9a160.js +1 -0
  767. package/app/.next-cli-build/static/chunks/app/api/v1/videos/generations/route-1b9308dbbaa9a160.js +1 -0
  768. package/app/.next-cli-build/static/chunks/app/api/v1/web/fetch/route-1b9308dbbaa9a160.js +1 -0
  769. package/app/.next-cli-build/static/chunks/app/api/v1beta/models/[...path]/route-1b9308dbbaa9a160.js +1 -0
  770. package/app/.next-cli-build/static/chunks/app/api/v1beta/models/route-1b9308dbbaa9a160.js +1 -0
  771. package/app/.next-cli-build/static/chunks/app/api/version/route-1b9308dbbaa9a160.js +1 -0
  772. package/app/.next-cli-build/static/chunks/app/api/version/shutdown/route-1b9308dbbaa9a160.js +1 -0
  773. package/app/.next-cli-build/static/chunks/app/api/version/update/route-1b9308dbbaa9a160.js +1 -0
  774. package/app/.next-cli-build/static/chunks/app/manifest.webmanifest/route-1b9308dbbaa9a160.js +1 -0
  775. package/app/.next-cli-build/static/chunks/app/page-1b9308dbbaa9a160.js +1 -0
  776. package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/app-error-1b9308dbbaa9a160.js +1 -0
  777. package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/forbidden-1b9308dbbaa9a160.js +1 -0
  778. package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/not-found-1b9308dbbaa9a160.js +1 -0
  779. package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/unauthorized-1b9308dbbaa9a160.js +1 -0
  780. package/app/.next-cli-build/static/css/83c41073a41a81a0.css +1 -0
  781. package/app/cli/.build-home/.9router/db/data.sqlite +0 -0
  782. package/app/cli/package.json +1 -1
  783. package/app/package.json +1 -1
  784. package/package.json +1 -1
  785. package/app/.next-cli-build/server/chunks/5827.js +0 -1
  786. package/app/.next-cli-build/server/chunks/8526.js +0 -1
  787. package/app/.next-cli-build/static/chunks/1321-9f55771ea8555497.js +0 -1
  788. package/app/.next-cli-build/static/chunks/705-f07c546a169bc3d2.js +0 -1
  789. package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/providers/[id]/page-f51632c292437ed4.js +0 -27
  790. package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/quota/page-f69d369b55f53879.js +0 -1
  791. package/app/.next-cli-build/static/chunks/app/_global-error/page-88e4f99cb546d1f2.js +0 -1
  792. package/app/.next-cli-build/static/chunks/app/api/auth/login/route-88e4f99cb546d1f2.js +0 -1
  793. package/app/.next-cli-build/static/chunks/app/api/auth/logout/route-88e4f99cb546d1f2.js +0 -1
  794. package/app/.next-cli-build/static/chunks/app/api/auth/oidc/callback/route-88e4f99cb546d1f2.js +0 -1
  795. package/app/.next-cli-build/static/chunks/app/api/auth/oidc/start/route-88e4f99cb546d1f2.js +0 -1
  796. package/app/.next-cli-build/static/chunks/app/api/auth/oidc/test/route-88e4f99cb546d1f2.js +0 -1
  797. package/app/.next-cli-build/static/chunks/app/api/auth/reset-password/route-88e4f99cb546d1f2.js +0 -1
  798. package/app/.next-cli-build/static/chunks/app/api/auth/saml/acs/route-88e4f99cb546d1f2.js +0 -1
  799. package/app/.next-cli-build/static/chunks/app/api/auth/saml/metadata/route-88e4f99cb546d1f2.js +0 -1
  800. package/app/.next-cli-build/static/chunks/app/api/auth/saml/start/route-88e4f99cb546d1f2.js +0 -1
  801. package/app/.next-cli-build/static/chunks/app/api/auth/saml/test/route-88e4f99cb546d1f2.js +0 -1
  802. package/app/.next-cli-build/static/chunks/app/api/auth/status/route-88e4f99cb546d1f2.js +0 -1
  803. package/app/.next-cli-build/static/chunks/app/api/cli-tools/all-statuses/route-88e4f99cb546d1f2.js +0 -1
  804. package/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/alias/route-88e4f99cb546d1f2.js +0 -1
  805. package/app/.next-cli-build/static/chunks/app/api/cli-tools/antigravity-mitm/route-88e4f99cb546d1f2.js +0 -1
  806. package/app/.next-cli-build/static/chunks/app/api/cli-tools/claude-settings/route-88e4f99cb546d1f2.js +0 -1
  807. package/app/.next-cli-build/static/chunks/app/api/cli-tools/cline-settings/route-88e4f99cb546d1f2.js +0 -1
  808. package/app/.next-cli-build/static/chunks/app/api/cli-tools/codewhale-settings/route-88e4f99cb546d1f2.js +0 -1
  809. package/app/.next-cli-build/static/chunks/app/api/cli-tools/codex-settings/route-88e4f99cb546d1f2.js +0 -1
  810. package/app/.next-cli-build/static/chunks/app/api/cli-tools/copilot-settings/route-88e4f99cb546d1f2.js +0 -1
  811. package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-registry/route-88e4f99cb546d1f2.js +0 -1
  812. package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-mcp-tools/route-88e4f99cb546d1f2.js +0 -1
  813. package/app/.next-cli-build/static/chunks/app/api/cli-tools/cowork-settings/route-88e4f99cb546d1f2.js +0 -1
  814. package/app/.next-cli-build/static/chunks/app/api/cli-tools/crush-settings/route-88e4f99cb546d1f2.js +0 -1
  815. package/app/.next-cli-build/static/chunks/app/api/cli-tools/deepseek-tui-settings/route-88e4f99cb546d1f2.js +0 -1
  816. package/app/.next-cli-build/static/chunks/app/api/cli-tools/droid-settings/route-88e4f99cb546d1f2.js +0 -1
  817. package/app/.next-cli-build/static/chunks/app/api/cli-tools/forge-settings/route-88e4f99cb546d1f2.js +0 -1
  818. package/app/.next-cli-build/static/chunks/app/api/cli-tools/grok-build-settings/route-88e4f99cb546d1f2.js +0 -1
  819. package/app/.next-cli-build/static/chunks/app/api/cli-tools/hermes-settings/route-88e4f99cb546d1f2.js +0 -1
  820. package/app/.next-cli-build/static/chunks/app/api/cli-tools/jcode-settings/route-88e4f99cb546d1f2.js +0 -1
  821. package/app/.next-cli-build/static/chunks/app/api/cli-tools/kilo-settings/route-88e4f99cb546d1f2.js +0 -1
  822. package/app/.next-cli-build/static/chunks/app/api/cli-tools/omp-settings/route-88e4f99cb546d1f2.js +0 -1
  823. package/app/.next-cli-build/static/chunks/app/api/cli-tools/openclaw-settings/route-88e4f99cb546d1f2.js +0 -1
  824. package/app/.next-cli-build/static/chunks/app/api/cli-tools/opencode-settings/route-88e4f99cb546d1f2.js +0 -1
  825. package/app/.next-cli-build/static/chunks/app/api/cli-tools/pi-settings/route-88e4f99cb546d1f2.js +0 -1
  826. package/app/.next-cli-build/static/chunks/app/api/cli-tools/smelt-settings/route-88e4f99cb546d1f2.js +0 -1
  827. package/app/.next-cli-build/static/chunks/app/api/combos/[id]/route-88e4f99cb546d1f2.js +0 -1
  828. package/app/.next-cli-build/static/chunks/app/api/combos/presets/route-88e4f99cb546d1f2.js +0 -1
  829. package/app/.next-cli-build/static/chunks/app/api/combos/route-88e4f99cb546d1f2.js +0 -1
  830. package/app/.next-cli-build/static/chunks/app/api/headroom/extras/route-88e4f99cb546d1f2.js +0 -1
  831. package/app/.next-cli-build/static/chunks/app/api/headroom/proxy/[...path]/route-88e4f99cb546d1f2.js +0 -1
  832. package/app/.next-cli-build/static/chunks/app/api/headroom/restart/route-88e4f99cb546d1f2.js +0 -1
  833. package/app/.next-cli-build/static/chunks/app/api/headroom/start/route-88e4f99cb546d1f2.js +0 -1
  834. package/app/.next-cli-build/static/chunks/app/api/headroom/status/route-88e4f99cb546d1f2.js +0 -1
  835. package/app/.next-cli-build/static/chunks/app/api/headroom/stop/route-88e4f99cb546d1f2.js +0 -1
  836. package/app/.next-cli-build/static/chunks/app/api/health/route-88e4f99cb546d1f2.js +0 -1
  837. package/app/.next-cli-build/static/chunks/app/api/init/route-88e4f99cb546d1f2.js +0 -1
  838. package/app/.next-cli-build/static/chunks/app/api/keys/[id]/route-88e4f99cb546d1f2.js +0 -1
  839. package/app/.next-cli-build/static/chunks/app/api/keys/route-88e4f99cb546d1f2.js +0 -1
  840. package/app/.next-cli-build/static/chunks/app/api/locale/route-88e4f99cb546d1f2.js +0 -1
  841. package/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/message/route-88e4f99cb546d1f2.js +0 -1
  842. package/app/.next-cli-build/static/chunks/app/api/mcp/[plugin]/sse/route-88e4f99cb546d1f2.js +0 -1
  843. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/deepgram/voices/route-88e4f99cb546d1f2.js +0 -1
  844. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/elevenlabs/voices/route-88e4f99cb546d1f2.js +0 -1
  845. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/inworld/voices/route-88e4f99cb546d1f2.js +0 -1
  846. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/minimax/voices/route-88e4f99cb546d1f2.js +0 -1
  847. package/app/.next-cli-build/static/chunks/app/api/media-providers/tts/voices/route-88e4f99cb546d1f2.js +0 -1
  848. package/app/.next-cli-build/static/chunks/app/api/models/alias/route-88e4f99cb546d1f2.js +0 -1
  849. package/app/.next-cli-build/static/chunks/app/api/models/availability/route-88e4f99cb546d1f2.js +0 -1
  850. package/app/.next-cli-build/static/chunks/app/api/models/catalog-sync/route-88e4f99cb546d1f2.js +0 -1
  851. package/app/.next-cli-build/static/chunks/app/api/models/custom/route-88e4f99cb546d1f2.js +0 -1
  852. package/app/.next-cli-build/static/chunks/app/api/models/disabled/route-88e4f99cb546d1f2.js +0 -1
  853. package/app/.next-cli-build/static/chunks/app/api/models/route-88e4f99cb546d1f2.js +0 -1
  854. package/app/.next-cli-build/static/chunks/app/api/models/test/route-88e4f99cb546d1f2.js +0 -1
  855. package/app/.next-cli-build/static/chunks/app/api/oauth/[provider]/[action]/route-88e4f99cb546d1f2.js +0 -1
  856. package/app/.next-cli-build/static/chunks/app/api/oauth/codex/bulk-import/route-88e4f99cb546d1f2.js +0 -1
  857. package/app/.next-cli-build/static/chunks/app/api/oauth/codex/import-token/route-88e4f99cb546d1f2.js +0 -1
  858. package/app/.next-cli-build/static/chunks/app/api/oauth/cursor/auto-import/route-88e4f99cb546d1f2.js +0 -1
  859. package/app/.next-cli-build/static/chunks/app/api/oauth/cursor/import/route-88e4f99cb546d1f2.js +0 -1
  860. package/app/.next-cli-build/static/chunks/app/api/oauth/gitlab/pat/route-88e4f99cb546d1f2.js +0 -1
  861. package/app/.next-cli-build/static/chunks/app/api/oauth/grok-cli/bulk-import/route-88e4f99cb546d1f2.js +0 -1
  862. package/app/.next-cli-build/static/chunks/app/api/oauth/iflow/cookie/route-88e4f99cb546d1f2.js +0 -1
  863. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/api-key/route-88e4f99cb546d1f2.js +0 -1
  864. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/auto-import/route-88e4f99cb546d1f2.js +0 -1
  865. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/import/route-88e4f99cb546d1f2.js +0 -1
  866. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/import-cli-proxy/route-88e4f99cb546d1f2.js +0 -1
  867. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-authorize/route-88e4f99cb546d1f2.js +0 -1
  868. package/app/.next-cli-build/static/chunks/app/api/oauth/kiro/social-exchange/route-88e4f99cb546d1f2.js +0 -1
  869. package/app/.next-cli-build/static/chunks/app/api/oauth/xiaomi-mimo/api-key/route-88e4f99cb546d1f2.js +0 -1
  870. package/app/.next-cli-build/static/chunks/app/api/oauth/xiaomi-mimo/auto-import/route-88e4f99cb546d1f2.js +0 -1
  871. package/app/.next-cli-build/static/chunks/app/api/oauth/xiaomi-mimo/login/start/route-88e4f99cb546d1f2.js +0 -1
  872. package/app/.next-cli-build/static/chunks/app/api/oauth/xiaomi-mimo/login/status/route-88e4f99cb546d1f2.js +0 -1
  873. package/app/.next-cli-build/static/chunks/app/api/pricing/route-88e4f99cb546d1f2.js +0 -1
  874. package/app/.next-cli-build/static/chunks/app/api/provider-nodes/[id]/route-88e4f99cb546d1f2.js +0 -1
  875. package/app/.next-cli-build/static/chunks/app/api/provider-nodes/route-88e4f99cb546d1f2.js +0 -1
  876. package/app/.next-cli-build/static/chunks/app/api/provider-nodes/validate/route-88e4f99cb546d1f2.js +0 -1
  877. package/app/.next-cli-build/static/chunks/app/api/providers/[id]/models/route-88e4f99cb546d1f2.js +0 -1
  878. package/app/.next-cli-build/static/chunks/app/api/providers/[id]/route-88e4f99cb546d1f2.js +0 -1
  879. package/app/.next-cli-build/static/chunks/app/api/providers/[id]/test/route-88e4f99cb546d1f2.js +0 -1
  880. package/app/.next-cli-build/static/chunks/app/api/providers/[id]/test-models/route-88e4f99cb546d1f2.js +0 -1
  881. package/app/.next-cli-build/static/chunks/app/api/providers/client/route-88e4f99cb546d1f2.js +0 -1
  882. package/app/.next-cli-build/static/chunks/app/api/providers/kilo/free-models/route-88e4f99cb546d1f2.js +0 -1
  883. package/app/.next-cli-build/static/chunks/app/api/providers/route-88e4f99cb546d1f2.js +0 -1
  884. package/app/.next-cli-build/static/chunks/app/api/providers/suggested-models/route-88e4f99cb546d1f2.js +0 -1
  885. package/app/.next-cli-build/static/chunks/app/api/providers/test-batch/route-88e4f99cb546d1f2.js +0 -1
  886. package/app/.next-cli-build/static/chunks/app/api/providers/validate/route-88e4f99cb546d1f2.js +0 -1
  887. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/route-88e4f99cb546d1f2.js +0 -1
  888. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/[id]/test/route-88e4f99cb546d1f2.js +0 -1
  889. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/cloudflare-deploy/route-88e4f99cb546d1f2.js +0 -1
  890. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/deno-deploy/route-88e4f99cb546d1f2.js +0 -1
  891. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/route-88e4f99cb546d1f2.js +0 -1
  892. package/app/.next-cli-build/static/chunks/app/api/proxy-pools/vercel-deploy/route-88e4f99cb546d1f2.js +0 -1
  893. package/app/.next-cli-build/static/chunks/app/api/pxpipe/health/route-88e4f99cb546d1f2.js +0 -1
  894. package/app/.next-cli-build/static/chunks/app/api/pxpipe/install/route-88e4f99cb546d1f2.js +0 -1
  895. package/app/.next-cli-build/static/chunks/app/api/pxpipe/logs/route-88e4f99cb546d1f2.js +0 -1
  896. package/app/.next-cli-build/static/chunks/app/api/pxpipe/restart/route-88e4f99cb546d1f2.js +0 -1
  897. package/app/.next-cli-build/static/chunks/app/api/pxpipe/start/route-88e4f99cb546d1f2.js +0 -1
  898. package/app/.next-cli-build/static/chunks/app/api/pxpipe/stats/route-88e4f99cb546d1f2.js +0 -1
  899. package/app/.next-cli-build/static/chunks/app/api/pxpipe/status/route-88e4f99cb546d1f2.js +0 -1
  900. package/app/.next-cli-build/static/chunks/app/api/pxpipe/stop/route-88e4f99cb546d1f2.js +0 -1
  901. package/app/.next-cli-build/static/chunks/app/api/settings/database/route-88e4f99cb546d1f2.js +0 -1
  902. package/app/.next-cli-build/static/chunks/app/api/settings/proxy-test/route-88e4f99cb546d1f2.js +0 -1
  903. package/app/.next-cli-build/static/chunks/app/api/settings/require-login/route-88e4f99cb546d1f2.js +0 -1
  904. package/app/.next-cli-build/static/chunks/app/api/settings/route-88e4f99cb546d1f2.js +0 -1
  905. package/app/.next-cli-build/static/chunks/app/api/shutdown/route-88e4f99cb546d1f2.js +0 -1
  906. package/app/.next-cli-build/static/chunks/app/api/tags/route-88e4f99cb546d1f2.js +0 -1
  907. package/app/.next-cli-build/static/chunks/app/api/translator/console-logs/route-88e4f99cb546d1f2.js +0 -1
  908. package/app/.next-cli-build/static/chunks/app/api/translator/console-logs/stream/route-88e4f99cb546d1f2.js +0 -1
  909. package/app/.next-cli-build/static/chunks/app/api/translator/load/route-88e4f99cb546d1f2.js +0 -1
  910. package/app/.next-cli-build/static/chunks/app/api/translator/save/route-88e4f99cb546d1f2.js +0 -1
  911. package/app/.next-cli-build/static/chunks/app/api/translator/send/route-88e4f99cb546d1f2.js +0 -1
  912. package/app/.next-cli-build/static/chunks/app/api/translator/translate/route-88e4f99cb546d1f2.js +0 -1
  913. package/app/.next-cli-build/static/chunks/app/api/tunnel/disable/route-88e4f99cb546d1f2.js +0 -1
  914. package/app/.next-cli-build/static/chunks/app/api/tunnel/enable/route-88e4f99cb546d1f2.js +0 -1
  915. package/app/.next-cli-build/static/chunks/app/api/tunnel/status/route-88e4f99cb546d1f2.js +0 -1
  916. package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-check/route-88e4f99cb546d1f2.js +0 -1
  917. package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-disable/route-88e4f99cb546d1f2.js +0 -1
  918. package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-enable/route-88e4f99cb546d1f2.js +0 -1
  919. package/app/.next-cli-build/static/chunks/app/api/tunnel/tailscale-install/route-88e4f99cb546d1f2.js +0 -1
  920. package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/codex-reset-credits/route-88e4f99cb546d1f2.js +0 -1
  921. package/app/.next-cli-build/static/chunks/app/api/usage/[connectionId]/route-88e4f99cb546d1f2.js +0 -1
  922. package/app/.next-cli-build/static/chunks/app/api/usage/chart/route-88e4f99cb546d1f2.js +0 -1
  923. package/app/.next-cli-build/static/chunks/app/api/usage/history/route-88e4f99cb546d1f2.js +0 -1
  924. package/app/.next-cli-build/static/chunks/app/api/usage/logs/route-88e4f99cb546d1f2.js +0 -1
  925. package/app/.next-cli-build/static/chunks/app/api/usage/providers/route-88e4f99cb546d1f2.js +0 -1
  926. package/app/.next-cli-build/static/chunks/app/api/usage/request-details/route-88e4f99cb546d1f2.js +0 -1
  927. package/app/.next-cli-build/static/chunks/app/api/usage/request-logs/route-88e4f99cb546d1f2.js +0 -1
  928. package/app/.next-cli-build/static/chunks/app/api/usage/stats/route-88e4f99cb546d1f2.js +0 -1
  929. package/app/.next-cli-build/static/chunks/app/api/usage/stream/route-88e4f99cb546d1f2.js +0 -1
  930. package/app/.next-cli-build/static/chunks/app/api/v1/api/chat/route-88e4f99cb546d1f2.js +0 -1
  931. package/app/.next-cli-build/static/chunks/app/api/v1/audio/speech/route-88e4f99cb546d1f2.js +0 -1
  932. package/app/.next-cli-build/static/chunks/app/api/v1/audio/transcriptions/route-88e4f99cb546d1f2.js +0 -1
  933. package/app/.next-cli-build/static/chunks/app/api/v1/audio/voices/route-88e4f99cb546d1f2.js +0 -1
  934. package/app/.next-cli-build/static/chunks/app/api/v1/chat/completions/route-88e4f99cb546d1f2.js +0 -1
  935. package/app/.next-cli-build/static/chunks/app/api/v1/embeddings/route-88e4f99cb546d1f2.js +0 -1
  936. package/app/.next-cli-build/static/chunks/app/api/v1/images/generations/route-88e4f99cb546d1f2.js +0 -1
  937. package/app/.next-cli-build/static/chunks/app/api/v1/messages/count_tokens/route-88e4f99cb546d1f2.js +0 -1
  938. package/app/.next-cli-build/static/chunks/app/api/v1/messages/route-88e4f99cb546d1f2.js +0 -1
  939. package/app/.next-cli-build/static/chunks/app/api/v1/models/[...model]/route-88e4f99cb546d1f2.js +0 -1
  940. package/app/.next-cli-build/static/chunks/app/api/v1/models/info/route-88e4f99cb546d1f2.js +0 -1
  941. package/app/.next-cli-build/static/chunks/app/api/v1/models/route-88e4f99cb546d1f2.js +0 -1
  942. package/app/.next-cli-build/static/chunks/app/api/v1/responses/compact/route-88e4f99cb546d1f2.js +0 -1
  943. package/app/.next-cli-build/static/chunks/app/api/v1/responses/route-88e4f99cb546d1f2.js +0 -1
  944. package/app/.next-cli-build/static/chunks/app/api/v1/route-88e4f99cb546d1f2.js +0 -1
  945. package/app/.next-cli-build/static/chunks/app/api/v1/search/route-88e4f99cb546d1f2.js +0 -1
  946. package/app/.next-cli-build/static/chunks/app/api/v1/systemone/route-88e4f99cb546d1f2.js +0 -1
  947. package/app/.next-cli-build/static/chunks/app/api/v1/videos/[id]/route-88e4f99cb546d1f2.js +0 -1
  948. package/app/.next-cli-build/static/chunks/app/api/v1/videos/edits/route-88e4f99cb546d1f2.js +0 -1
  949. package/app/.next-cli-build/static/chunks/app/api/v1/videos/extensions/route-88e4f99cb546d1f2.js +0 -1
  950. package/app/.next-cli-build/static/chunks/app/api/v1/videos/generations/route-88e4f99cb546d1f2.js +0 -1
  951. package/app/.next-cli-build/static/chunks/app/api/v1/web/fetch/route-88e4f99cb546d1f2.js +0 -1
  952. package/app/.next-cli-build/static/chunks/app/api/v1beta/models/[...path]/route-88e4f99cb546d1f2.js +0 -1
  953. package/app/.next-cli-build/static/chunks/app/api/v1beta/models/route-88e4f99cb546d1f2.js +0 -1
  954. package/app/.next-cli-build/static/chunks/app/api/version/route-88e4f99cb546d1f2.js +0 -1
  955. package/app/.next-cli-build/static/chunks/app/api/version/shutdown/route-88e4f99cb546d1f2.js +0 -1
  956. package/app/.next-cli-build/static/chunks/app/api/version/update/route-88e4f99cb546d1f2.js +0 -1
  957. package/app/.next-cli-build/static/chunks/app/manifest.webmanifest/route-88e4f99cb546d1f2.js +0 -1
  958. package/app/.next-cli-build/static/chunks/app/page-88e4f99cb546d1f2.js +0 -1
  959. package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/app-error-88e4f99cb546d1f2.js +0 -1
  960. package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/forbidden-88e4f99cb546d1f2.js +0 -1
  961. package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/not-found-88e4f99cb546d1f2.js +0 -1
  962. package/app/.next-cli-build/static/chunks/next/dist/client/components/builtin/unauthorized-88e4f99cb546d1f2.js +0 -1
  963. package/app/.next-cli-build/static/css/8cc306fc3760c2a2.css +0 -1
  964. /package/app/.next-cli-build/static/{OYb5Yq4NL-wta-dTiS5U2 → PZvA43-na7jomNlixbKIv}/_buildManifest.js +0 -0
  965. /package/app/.next-cli-build/static/{OYb5Yq4NL-wta-dTiS5U2 → PZvA43-na7jomNlixbKIv}/_ssgManifest.js +0 -0
@@ -1,4 +1,4 @@
1
- "use strict";exports.id=2778,exports.ids=[2778],exports.modules={8019:(a,b,c)=>{c.d(b,{Tk:()=>C,aG:()=>P,Ah:()=>D,Q6:()=>O,lF:()=>S,a7:()=>L,ZM:()=>F,WE:()=>_,E_:()=>Z,RF:()=>I,mW:()=>T,c9:()=>Q,gY:()=>ag,tA:()=>ab,kn:()=>ad,yZ:()=>G,qO:()=>M});var d=c(48249),e=c(67484),f=c(50412),g=c(81220),h=c(37837);function i({storageKey:a,changeEvent:b,itemField:c,normalize:d=a=>a,defaultName:e=a=>a}){let f=()=>[],g=a=>{};return{read:f,subscribe:a=>()=>{},upsert:(a,b)=>{let h=d(a);if(!h)return null;let i=f(),j=i.find(a=>d(a[c])===h);if(j&&!b)return j.name;let k=(b||e(h)).trim();return k?(g([...i.filter(a=>a.name!==k&&d(a[c])!==h),{name:k,[c]:h}].sort((a,b)=>a.name.localeCompare(b.name))),k):null},remove:a=>g(f().filter(b=>b.name!==a))}}let j=a=>(a||"").replace(/\/+$/,""),k=i({storageKey:"9router.cliToolEndpointPresets",changeEvent:"9router:endpoint-presets-changed",itemField:"baseUrl",normalize:j,defaultName:a=>{try{return new URL(a).host}catch{return a}}}),l=i({storageKey:"9router.cliToolApiKeyPresets",changeEvent:"9router:api-key-presets-changed",itemField:"key"});k.read,k.subscribe;let m=k.upsert,n=k.remove;l.read,l.subscribe;let o=l.upsert,p=l.remove;function q(a,{tunnelPublicUrl:b,tailscaleUrl:c,cloudUrl:d}={}){let e=j(a);return!e||[`http://127.0.0.1:${h.h0.appPort}`,b,c,d].filter(Boolean).flatMap(a=>[j(a),`${j(a)}/v1`]).includes(e)?null:m(e)}let r="__custom__",s="__save__";function t({value:a,onChange:b,requiresExternalUrl:c=!1,tunnelEnabled:f=!1,tunnelPublicUrl:g="",tailscaleEnabled:i=!1,tailscaleUrl:j="",cloudEnabled:k=!1,cloudUrl:l="",withV1:o=!0,currentUrl:p=""}){let[q,u]=(0,e.useState)([]),[v,w]=(0,e.useState)(!1),[x,y]=(0,e.useState)(""),[z,A]=(0,e.useState)("");(0,e.useRef)(!1);let B=(0,e.useRef)(""),C=(0,e.useMemo)(()=>(({requiresExternalUrl:a,tunnelEnabled:b,tunnelPublicUrl:c,tailscaleEnabled:d,tailscaleUrl:e,cloudEnabled:f,cloudUrl:g,savedPresets:i,withV1:j})=>{let k=[],l=a=>{let b;return j?(b=(a||"").replace(/\/+$/,""))?/\/v1$/.test(b)?b:`${b}/v1`:"":(a||"").replace(/\/+$/,"")};if(!a){let a=l(`http://127.0.0.1:${h.h0.appPort}`);k.push({value:"local",label:a,url:a})}if(b&&c){let a=l(c);k.push({value:"tunnel",label:a,url:a})}if(d&&e){let a=l(e);k.push({value:"tailscale",label:a,url:a})}if(f&&g){let a=l(g);k.push({value:"cloud",label:a,url:a})}return i.forEach(a=>{k.push({value:`saved:${a.name}`,label:a.baseUrl,url:a.baseUrl,saved:!0})}),k.push({value:r,label:"Custom URL...",url:""}),k})({requiresExternalUrl:c,tunnelEnabled:f,tunnelPublicUrl:g,tailscaleEnabled:i,tailscaleUrl:j,cloudEnabled:k,cloudUrl:l,savedPresets:q,withV1:o}),[c,f,g,i,j,k,l,q,o]),D=x.startsWith("saved:"),E=x===r,F=E&&(z||"").trim().length>0;return(0,d.jsxs)("div",{className:"flex flex-col gap-1.5",children:[(0,d.jsxs)("div",{className:"flex items-center gap-2",children:[(0,d.jsxs)("select",{value:x,onChange:c=>{let d=c.target.value;if(d===s){let b=(a||"").trim();if(!b)return;let c=b;try{c=new URL(b).host}catch{}let d=window.prompt("Save endpoint as:",c),e=d?.trim()?m(b,d.trim()):null;e&&y(`saved:${e}`);return}if(y(d),d===r){A(""),b("");return}let e=C.find(a=>a.value===d);e&&b(e.url)},className:"flex-1 min-w-0 px-2 py-2 bg-surface rounded text-xs border border-border focus:outline-none focus:ring-1 focus:ring-primary/50 sm:py-1.5",children:[C.map(a=>(0,d.jsx)("option",{value:a.value,children:a.label},a.value)),F&&(0,d.jsx)("option",{value:s,children:"+ Save current as..."})]}),D&&(0,d.jsx)("button",{type:"button",onClick:()=>{if(!x.startsWith("saved:"))return;n(x.slice(6)),A("");let a=C.find(a=>a.value!==r&&a.value!==x);a?(y(a.value),b(a.url)):(y(r),b(""))},className:"p-1 text-text-muted hover:text-red-500 rounded transition-colors shrink-0",title:"Delete saved endpoint",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"delete"})})]}),E&&(0,d.jsx)("input",{type:"text",value:z,onChange:a=>{let c=a.target.value;B.current=c,A(c),b(c)},placeholder:o?"https://example.com/v1":"https://example.com",className:"w-full min-w-0 px-2 py-2 bg-surface rounded border border-border text-xs focus:outline-none focus:ring-1 focus:ring-primary/50 sm:py-1.5"})]})}let u="__custom__",v="__save_key__";function w({value:a,onChange:b,apiKeys:c=[],cloudEnabled:f=!1,className:g=""}){let[h,i]=(0,e.useState)([]),[j,k]=(0,e.useState)(!1),[l,m]=(0,e.useState)(""),n=(0,e.useMemo)(()=>[...c.map(a=>({value:a.key,label:a.key})),...h.map(a=>({value:`saved:${a.name}`,label:a.key,url:a.key,saved:!0})),{value:u,label:"Custom...",url:""}],[c,h]),q=a?n.find(b=>b.value===a||b.url===a):null,r=q?q.value:j||a?u:n[0]?.value??u,s=j?l:a||"",t="string"==typeof r&&r.startsWith("saved:"),x=r===u,y=x&&(a||"").trim().length>0&&!c.some(b=>b.key===a);return 0!==c.length||0!==h.length||j||a?(0,d.jsxs)("div",{className:`flex flex-col gap-1.5 ${g}`,children:[(0,d.jsxs)("div",{className:"flex items-center gap-2",children:[(0,d.jsxs)("select",{value:r,onChange:c=>{let d=c.target.value;if(d===v)return void o((a||"").trim());if(d===u){k(!0),m(""),b("");return}k(!1),m("");let e=n.find(a=>a.value===d);e&&b(e.url??e.value)},className:"flex-1 min-w-0 px-2 py-2 bg-surface rounded text-xs border border-border focus:outline-none focus:ring-1 focus:ring-primary/50 sm:py-1.5",children:[n.map(a=>(0,d.jsx)("option",{value:a.value,children:a.label},a.value)),y&&(0,d.jsx)("option",{value:v,children:"+ Save current as..."})]}),t&&(0,d.jsx)("button",{type:"button",onClick:()=>{if(!t)return;p(r.slice(6)),k(!1),m("");let a=n.find(a=>a.value!==u&&a.value!==r);b(a?a.url??a.value:"")},className:"p-1 text-text-muted hover:text-red-500 rounded transition-colors shrink-0",title:"Delete saved key",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"delete"})})]}),x&&(0,d.jsx)("input",{type:"text",value:s,onChange:a=>{let c=a.target.value;k(!0),m(c),b(c)},placeholder:"sk-...",className:"w-full min-w-0 px-2 py-2 bg-surface rounded border border-border text-xs focus:outline-none focus:ring-1 focus:ring-primary/50 sm:py-1.5"})]}):(0,d.jsx)("span",{className:`min-w-0 rounded bg-surface/40 px-2 py-2 text-xs text-text-muted sm:py-1.5 ${g}`,children:f?"No API keys - Create one in Keys page":"sk_9router (default)"})}let x=a=>(a||"").replace(/\/+$/,"");function y(a,b={}){if(!a)return!1;let c=x(a),{tunnelPublicUrl:d,tailscaleUrl:e,cloudUrl:f}=b;return!!(/localhost|127\.0\.0\.1|0\.0\.0\.0/.test(c)||d&&c.startsWith(x(d))||e&&c.startsWith(x(e))||f&&c.startsWith(x(f)))}let z=/\[1m\]$/i,A=process.env.NEXT_PUBLIC_CLOUD_URL,B=[{label:"Default",value:""},{label:"200K",value:"198000"},{label:"300K",value:"298000"},{label:"500K",value:"498000"},{label:"700K",value:"698000"}];function C({tool:a,isExpanded:b,onToggle:c,activeProviders:h,modelMappings:i,onModelMappingChange:j,baseUrl:k,hasActiveProviders:l,apiKeys:m,cloudEnabled:n,initialStatus:o,tunnelEnabled:p,tunnelPublicUrl:r,tailscaleEnabled:s,tailscaleUrl:u}){let v,x,D,[E,F]=(0,e.useState)(o||null),[G,H]=(0,e.useState)(!1),[I,J]=(0,e.useState)(!1),[K,L]=(0,e.useState)(!1),[M,N]=(0,e.useState)(null),[O,P]=(0,e.useState)(!1),[Q,R]=(0,e.useState)(!1),[S,T]=(0,e.useState)(null),[U,V]=(0,e.useState)(""),[W,X]=(0,e.useState)({}),[Y,Z]=(0,e.useState)(!1),[$,_]=(0,e.useState)(""),[aa,ab]=(0,e.useState)(!1),[ac,ad]=(0,e.useState)(!1),[ae,af]=(0,e.useState)(""),[ag,ah]=(0,e.useState)(!1);(0,e.useRef)(!1);let ai=E?.settings?.env?.ANTHROPIC_BASE_URL||"",aj=(()=>{if(!E?.installed)return null;let a=E.settings?.env?.ANTHROPIC_BASE_URL;return a?y(a,{tunnelPublicUrl:r,tailscaleUrl:u,cloudUrl:n?A:null})?"configured":"other":"not_configured"})(),ak=async a=>{let b=a.target.checked;ab(b),await fetch("/api/settings",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({ccFilterNaming:b})}).catch(()=>{})},al=()=>{let a=$||k;return a.endsWith("/v1")?a:`${a}/v1`},am=async()=>{J(!0),N(null);try{let b={ANTHROPIC_BASE_URL:al()},c=U?.trim()||(m?.length>0?m[0].key:null)||(n?null:"sk_9router");c&&(b.ANTHROPIC_AUTH_TOKEN=c),a.defaultModels.forEach(a=>{let c=i[a.alias];c&&a.envKey&&(b[a.envKey]=c)}),ae&&(b.CLAUDE_CODE_AUTO_COMPACT_WINDOW=ae);let d=await fetch("/api/cli-tools/claude-settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({env:b,exaMcpEnabled:ac,autoCompactWindow:ae})}),e=await d.json();d.ok?(q(al(),{tunnelPublicUrl:r,tailscaleUrl:u}),N({type:"success",text:"Settings applied successfully!"}),F(a=>({...a,hasBackup:!0,settings:{...a?.settings,env:b},exaMcpEnabled:ac}))):N({type:"error",text:e.error||"Failed to apply settings"})}catch(a){N({type:"error",text:a.message})}finally{J(!1)}},an=async()=>{L(!0),N(null);try{let b=await fetch("/api/cli-tools/claude-settings",{method:"DELETE"}),c=await b.json();b.ok?(N({type:"success",text:"Settings reset successfully!"}),a.defaultModels.forEach(a=>j(a.alias,a.defaultValue||"")),V(""),ad(!1),af(""),ah(!1)):N({type:"error",text:c.error||"Failed to reset settings"})}catch(a){N({type:"error",text:a.message})}finally{L(!1)}};return(0,d.jsxs)(f.Zp,{padding:"xs",className:"overflow-hidden",children:[(0,d.jsxs)("div",{className:"flex items-start justify-between gap-3 hover:cursor-pointer sm:items-center",onClick:c,children:[(0,d.jsxs)("div",{className:"flex min-w-0 items-center gap-3",children:[(0,d.jsx)("div",{className:"size-8 flex items-center justify-center shrink-0",children:(0,d.jsx)(g.default,{src:"/providers/claude.png",alt:a.name,width:32,height:32,className:"size-8 object-contain rounded-lg",sizes:"32px",onError:a=>{a.target.style.display="none"},loading:"lazy",decoding:"async"})}),(0,d.jsxs)("div",{className:"min-w-0",children:[(0,d.jsxs)("div",{className:"flex min-w-0 flex-wrap items-center gap-2",children:[(0,d.jsx)("h3",{className:"font-medium text-sm",children:a.name}),"configured"===aj&&(0,d.jsx)("span",{className:"px-1.5 py-0.5 text-[10px] font-medium bg-green-500/10 text-green-600 dark:text-green-400 rounded-full",children:"Connected"}),"not_configured"===aj&&(0,d.jsx)("span",{className:"px-1.5 py-0.5 text-[10px] font-medium bg-yellow-500/10 text-yellow-600 dark:text-yellow-400 rounded-full",children:"Not configured"}),"other"===aj&&(0,d.jsx)("span",{className:"px-1.5 py-0.5 text-[10px] font-medium bg-blue-500/10 text-blue-600 dark:text-blue-400 rounded-full",children:"Other"})]}),(0,d.jsx)("p",{className:"text-xs text-text-muted truncate",children:a.description})]})]}),(0,d.jsx)("span",{className:`material-symbols-outlined text-text-muted text-[20px] transition-transform ${b?"rotate-180":""}`,children:"expand_more"})]}),b&&(0,d.jsxs)("div",{className:"mt-4 pt-4 border-t border-border flex flex-col gap-4",children:[G&&(0,d.jsxs)("div",{className:"flex items-center gap-2 text-text-muted",children:[(0,d.jsx)("span",{className:"material-symbols-outlined animate-spin",children:"progress_activity"}),(0,d.jsx)("span",{children:"Checking Claude CLI..."})]}),!G&&E&&!E.installed&&(0,d.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,d.jsxs)("div",{className:"flex flex-col gap-3 p-4 bg-yellow-500/10 border border-yellow-500/30 rounded-lg",children:[(0,d.jsxs)("div",{className:"flex items-start gap-3",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-yellow-500",children:"warning"}),(0,d.jsxs)("div",{className:"flex-1",children:[(0,d.jsx)("p",{className:"font-medium text-yellow-600 dark:text-yellow-400",children:"Claude CLI not detected locally"}),(0,d.jsx)("p",{className:"text-sm text-text-muted",children:"Manual configuration is still available if 9router is deployed on a remote server."})]})]}),(0,d.jsxs)("div",{className:"flex items-center gap-2 pl-9",children:[(0,d.jsxs)(f.$n,{variant:"secondary",size:"sm",onClick:()=>Z(!0),className:"!bg-yellow-500/20 !border-yellow-500/40 !text-yellow-700 dark:!text-yellow-300 hover:!bg-yellow-500/30",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[18px] mr-1",children:"content_copy"}),"Manual Config"]}),(0,d.jsxs)(f.$n,{variant:"outline",size:"sm",onClick:()=>P(!O),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[18px] mr-1",children:O?"expand_less":"help"}),O?"Hide":"How to Install"]})]})]}),O&&(0,d.jsxs)("div",{className:"p-4 bg-surface border border-border rounded-lg",children:[(0,d.jsx)("h4",{className:"font-medium mb-3",children:"Installation Guide"}),(0,d.jsxs)("div",{className:"space-y-3 text-sm",children:[(0,d.jsxs)("div",{children:[(0,d.jsx)("p",{className:"text-text-muted mb-1",children:"macOS / Linux / Windows:"}),(0,d.jsx)("code",{className:"block px-3 py-2 bg-black/5 dark:bg-white/5 rounded font-mono text-xs",children:"npm install -g @anthropic-ai/claude-code"})]}),(0,d.jsxs)("p",{className:"text-text-muted",children:["After installation, run ",(0,d.jsx)("code",{className:"px-1 bg-black/5 dark:bg-white/5 rounded",children:"claude"})," to verify."]})]})]})]}),!G&&E?.installed&&(0,d.jsxs)(d.Fragment,{children:[(0,d.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"Select Endpoint"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsx)(t,{value:$||((v=$||k).endsWith("/v1")?v:`${v}/v1`),onChange:_,requiresExternalUrl:a.requiresExternalUrl,tunnelEnabled:p,tunnelPublicUrl:r,tailscaleEnabled:s,tailscaleUrl:u,currentUrl:ai})]}),E?.settings?.env?.ANTHROPIC_BASE_URL&&(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"Current"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsx)("span",{className:"min-w-0 truncate rounded bg-surface/40 px-2 py-2 text-xs text-text-muted sm:py-1.5",children:E.settings.env.ANTHROPIC_BASE_URL})]}),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"API Key"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsx)(w,{value:U,onChange:V,apiKeys:m,cloudEnabled:n})]}),a.defaultModels.map(a=>(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:a.name}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsxs)("div",{className:"relative w-full min-w-0",children:[(0,d.jsx)("input",{type:"text",value:i[a.alias]||"",onChange:b=>j(a.alias,b.target.value),placeholder:"provider/model-id",className:"w-full min-w-0 pl-2 pr-7 py-2 bg-surface rounded border border-border text-xs focus:outline-none focus:ring-1 focus:ring-primary/50 sm:py-1.5"}),i[a.alias]&&(0,d.jsx)("button",{onClick:()=>j(a.alias,""),className:"absolute right-1 top-1/2 -translate-y-1/2 p-0.5 text-text-muted hover:text-red-500 rounded transition-colors",title:"Clear",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"close"})})]}),(0,d.jsx)("button",{onClick:()=>{T(a.alias),R(!0)},disabled:!l,className:`w-full sm:w-auto rounded border px-2 py-2 text-xs transition-colors sm:py-1.5 whitespace-nowrap sm:shrink-0 ${l?"bg-surface border-border text-text-main hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Select Model"})]},a.alias)),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"Auto-compact"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsx)("select",{value:ae,onChange:a=>af(a.target.value),className:"w-full min-w-0 px-2 py-2 bg-surface rounded border border-border text-xs focus:outline-none focus:ring-1 focus:ring-primary/50 sm:py-1.5",children:B.map(a=>(0,d.jsx)("option",{value:a.value,children:a.label},a.label))})]}),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"1M context"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsxs)("label",{className:"flex items-center gap-1.5 cursor-pointer select-none",children:[(0,d.jsx)("input",{type:"checkbox",checked:ag,onChange:b=>{var c;ah(c=b.target.checked),a.defaultModels.forEach(a=>{let b=i[a.alias];b&&j(a.alias,((a,b)=>{let{model:c}=function(a){if("string"!=typeof a)return{model:a,contextMarker:null};let b=a.trim(),c=b.match(z);return c?{model:b.slice(0,-c[0].length),contextMarker:c[0].slice(1,-1).toLowerCase()}:{model:a,contextMarker:null}}(a);return b?`${c}[1m]`:c})(b,c))})},className:"w-3.5 h-3.5 accent-primary cursor-pointer"}),(0,d.jsx)("span",{className:"text-xs text-text-muted",children:"Append [1m] to the model name"}),(0,d.jsx)(f.m_,{text:"Claude Code otherwise assumes a 200K window, which clamps the auto-compact window above. Applied to every mapped model — only enable it for models that really accept 1M.",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-text-muted text-[14px] cursor-help",children:"info"})})]})]}),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"Filter naming"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsxs)("label",{className:"flex items-center gap-1.5 cursor-pointer select-none",children:[(0,d.jsx)("input",{type:"checkbox",checked:aa,onChange:ak,className:"w-3.5 h-3.5 accent-primary cursor-pointer"}),(0,d.jsx)("span",{className:"text-xs text-text-muted",children:"Filter naming requests"}),(0,d.jsx)(f.m_,{text:"Intercepts Claude Code's topic-naming requests and returns a fake response locally, saving API tokens.",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-text-muted text-[14px] cursor-help",children:"info"})})]})]}),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"Web Search"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsxs)("label",{className:"flex items-center gap-1.5 cursor-pointer select-none",children:[(0,d.jsx)("input",{type:"checkbox",checked:ac,onChange:a=>ad(a.target.checked),className:"w-3.5 h-3.5 accent-primary cursor-pointer"}),(0,d.jsx)("span",{className:"text-xs text-text-muted",children:"Exa MCP"}),(0,d.jsx)(f.m_,{text:"Injects Exa MCP into ~/.claude.json so non-Claude models gain web search. Restart Claude Code after Apply.",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-text-muted text-[14px] cursor-help",children:"info"})})]})]})]}),M&&(0,d.jsxs)("div",{className:`flex items-center gap-2 px-2 py-1.5 rounded text-xs ${"success"===M.type?"bg-green-500/10 text-green-600":"bg-red-500/10 text-red-600"}`,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"success"===M.type?"check_circle":"error"}),(0,d.jsx)("span",{children:M.text})]}),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-2 sm:flex sm:items-center",children:[(0,d.jsxs)(f.$n,{variant:"primary",size:"sm",onClick:am,disabled:!l,loading:I,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"save"}),"Apply"]}),(0,d.jsxs)(f.$n,{variant:"outline",size:"sm",onClick:an,disabled:!E?.has9Router,loading:K,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"restore"}),"Reset"]}),(0,d.jsxs)(f.$n,{variant:"ghost",size:"sm",onClick:()=>Z(!0),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"content_copy"}),"Manual Config"]})]})]})]}),Q&&(0,d.jsx)(f.rq,{isOpen:Q,onClose:()=>R(!1),onSelect:a=>{S&&j(S,a.value)},selectedModel:S?i[S]:null,activeProviders:h,modelAliases:W,title:`Select model for ${S}`}),(0,d.jsx)(f.uR,{isOpen:Y,onClose:()=>Z(!1),title:"Claude CLI - Manual Configuration",configs:(x=U&&U.trim()?U:n?"<API_KEY_FROM_DASHBOARD>":"sk_9router",D={ANTHROPIC_BASE_URL:al(),ANTHROPIC_AUTH_TOKEN:x},a.defaultModels.forEach(a=>{let b=i[a.alias];b&&a.envKey&&(D[a.envKey]=b)}),ae&&(D.CLAUDE_CODE_AUTO_COMPACT_WINDOW=ae),[{filename:"~/.claude/settings.json",content:JSON.stringify({hasCompletedOnboarding:!0,env:D},null,2)}])})]})}function D({tool:a,isExpanded:b,onToggle:c,baseUrl:h,apiKeys:i,activeProviders:j,cloudEnabled:k,initialStatus:l,tunnelEnabled:m,tunnelPublicUrl:n,tailscaleEnabled:o,tailscaleUrl:p}){let r,s,u,[v,x]=(0,e.useState)(l||null),[z,A]=(0,e.useState)(!1),[B,C]=(0,e.useState)(!1),[E,F]=(0,e.useState)(!1),[G,H]=(0,e.useState)(null),[I,J]=(0,e.useState)(!1),[K,L]=(0,e.useState)(""),[M,N]=(0,e.useState)(""),[O,P]=(0,e.useState)(""),[Q,R]=(0,e.useState)(!1),[S,T]=(0,e.useState)(!1),[U,V]=(0,e.useState)({}),[W,X]=(0,e.useState)(!1),[Y,Z]=(0,e.useState)(""),$=(r=v?.config?.match(/base_url\s*=\s*"([^"]+)"/))?r[1]:"",_=v?.installed?v.config?y($,{tunnelPublicUrl:n,tailscaleUrl:p})?"configured":"other":"not_configured":null,aa=()=>{let a=Y||`${h}/v1`;return a.endsWith("/v1")?a:`${a}/v1`},ab=async()=>{A(!0);try{let a=await fetch("/api/cli-tools/codex-settings"),b=await a.json();x(b)}catch(a){x({installed:!1,error:a.message})}finally{A(!1)}},ac=async()=>{C(!0),H(null);try{let a=K&&K.trim()||k?K:"sk_9router",b=await fetch("/api/cli-tools/codex-settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({baseUrl:aa(),apiKey:a,model:M,subagentModel:O||M})}),c=await b.json();b.ok?(q(aa(),{tunnelPublicUrl:n,tailscaleUrl:p}),H({type:"success",text:"Settings applied successfully!"}),ab()):H({type:"error",text:c.error||"Failed to apply settings"})}catch(a){H({type:"error",text:a.message})}finally{C(!1)}},ad=async()=>{F(!0),H(null);try{let a=await fetch("/api/cli-tools/codex-settings",{method:"DELETE"}),b=await a.json();a.ok?(H({type:"success",text:"Settings reset successfully!"}),N(""),P(""),ab()):H({type:"error",text:b.error||"Failed to reset settings"})}catch(a){H({type:"error",text:a.message})}finally{F(!1)}};return(0,d.jsxs)(f.Zp,{padding:"xs",className:"overflow-hidden",children:[(0,d.jsxs)("div",{className:"flex items-start justify-between gap-3 hover:cursor-pointer sm:items-center",onClick:c,children:[(0,d.jsxs)("div",{className:"flex min-w-0 items-center gap-3",children:[(0,d.jsx)("div",{className:"size-8 flex items-center justify-center shrink-0",children:(0,d.jsx)(g.default,{src:"/providers/codex.png",alt:a.name,width:32,height:32,className:"size-8 object-contain rounded-lg",sizes:"32px",onError:a=>{a.target.style.display="none"},loading:"lazy",decoding:"async"})}),(0,d.jsxs)("div",{className:"min-w-0",children:[(0,d.jsxs)("div",{className:"flex min-w-0 flex-wrap items-center gap-2",children:[(0,d.jsx)("h3",{className:"font-medium text-sm",children:a.name}),"configured"===_&&(0,d.jsx)("span",{className:"px-1.5 py-0.5 text-[10px] font-medium bg-green-500/10 text-green-600 dark:text-green-400 rounded-full",children:"Connected"}),"not_configured"===_&&(0,d.jsx)("span",{className:"px-1.5 py-0.5 text-[10px] font-medium bg-yellow-500/10 text-yellow-600 dark:text-yellow-400 rounded-full",children:"Not configured"}),"other"===_&&(0,d.jsx)("span",{className:"px-1.5 py-0.5 text-[10px] font-medium bg-blue-500/10 text-blue-600 dark:text-blue-400 rounded-full",children:"Other"})]}),(0,d.jsx)("p",{className:"text-xs text-text-muted truncate",children:a.description})]})]}),(0,d.jsx)("span",{className:`material-symbols-outlined text-text-muted text-[20px] transition-transform ${b?"rotate-180":""}`,children:"expand_more"})]}),b&&(0,d.jsxs)("div",{className:"mt-4 pt-4 border-t border-border flex flex-col gap-4",children:[z&&(0,d.jsxs)("div",{className:"flex items-center gap-2 text-text-muted",children:[(0,d.jsx)("span",{className:"material-symbols-outlined animate-spin",children:"progress_activity"}),(0,d.jsx)("span",{children:"Checking Codex CLI..."})]}),!z&&v&&!v.installed&&(0,d.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,d.jsxs)("div",{className:"flex flex-col gap-3 p-4 bg-yellow-500/10 border border-yellow-500/30 rounded-lg",children:[(0,d.jsxs)("div",{className:"flex items-start gap-3",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-yellow-500",children:"warning"}),(0,d.jsxs)("div",{className:"flex-1",children:[(0,d.jsx)("p",{className:"font-medium text-yellow-600 dark:text-yellow-400",children:"Codex CLI not detected locally"}),(0,d.jsx)("p",{className:"text-sm text-text-muted",children:"Manual configuration is still available if 9router is deployed on a remote server."})]})]}),(0,d.jsxs)("div",{className:"flex items-center gap-2 pl-9",children:[(0,d.jsxs)(f.$n,{variant:"secondary",size:"sm",onClick:()=>X(!0),className:"!bg-yellow-500/20 !border-yellow-500/40 !text-yellow-700 dark:!text-yellow-300 hover:!bg-yellow-500/30",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[18px] mr-1",children:"content_copy"}),"Manual Config"]}),(0,d.jsxs)(f.$n,{variant:"outline",size:"sm",onClick:()=>J(!I),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[18px] mr-1",children:I?"expand_less":"help"}),I?"Hide":"How to Install"]})]})]}),I&&(0,d.jsxs)("div",{className:"p-4 bg-surface border border-border rounded-lg",children:[(0,d.jsx)("h4",{className:"font-medium mb-3",children:"Installation Guide"}),(0,d.jsxs)("div",{className:"space-y-3 text-sm",children:[(0,d.jsxs)("div",{children:[(0,d.jsx)("p",{className:"text-text-muted mb-1",children:"macOS / Linux / Windows:"}),(0,d.jsx)("code",{className:"block px-3 py-2 bg-black/5 dark:bg-white/5 rounded font-mono text-xs",children:"npm install -g @openai/codex"})]}),(0,d.jsxs)("p",{className:"text-text-muted",children:["After installation, run ",(0,d.jsx)("code",{className:"px-1 bg-black/5 dark:bg-white/5 rounded",children:"codex"})," to verify."]}),(0,d.jsx)("div",{className:"pt-2 border-t border-border",children:(0,d.jsxs)("p",{className:"text-text-muted text-xs",children:["Codex reads custom providers from ",(0,d.jsx)("code",{className:"px-1 bg-black/5 dark:bg-white/5 rounded",children:"~/.codex/config.toml"}),'. Click "Apply" to auto-configure.']})})]})]})]}),!z&&v?.installed&&(0,d.jsxs)(d.Fragment,{children:[(0,d.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"Select Endpoint"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsx)(t,{value:Y||Y||`${h}/v1`,onChange:Z,requiresExternalUrl:a.requiresExternalUrl,tunnelEnabled:m,tunnelPublicUrl:n,tailscaleEnabled:o,tailscaleUrl:p,currentUrl:$})]}),v?.config&&($?(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"Current"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsx)("span",{className:"min-w-0 truncate rounded bg-surface/40 px-2 py-2 text-xs text-text-muted sm:py-1.5",children:$})]}):null),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"API Key"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsx)(w,{value:K,onChange:L,apiKeys:i,cloudEnabled:k})]}),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"Model"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsxs)("div",{className:"relative w-full min-w-0",children:[(0,d.jsx)("input",{type:"text",value:M,onChange:a=>N(a.target.value),placeholder:"provider/model-id",className:"w-full min-w-0 pl-2 pr-7 py-2 bg-surface rounded border border-border text-xs focus:outline-none focus:ring-1 focus:ring-primary/50 sm:py-1.5"}),M&&(0,d.jsx)("button",{onClick:()=>N(""),className:"absolute right-1 top-1/2 -translate-y-1/2 p-0.5 text-text-muted hover:text-red-500 rounded transition-colors",title:"Clear",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"close"})})]}),(0,d.jsx)("button",{onClick:()=>R(!0),disabled:!j?.length,className:`w-full sm:w-auto rounded border px-2 py-2 text-xs transition-colors sm:py-1.5 whitespace-nowrap sm:shrink-0 ${j?.length?"bg-surface border-border text-text-main hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Select Model"})]}),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"Subagent Model"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsxs)("div",{className:"relative w-full min-w-0",children:[(0,d.jsx)("input",{type:"text",value:O,onChange:a=>P(a.target.value),placeholder:M||"provider/model-id (defaults to main model)",className:"w-full min-w-0 pl-2 pr-7 py-2 bg-surface rounded border border-border text-xs focus:outline-none focus:ring-1 focus:ring-primary/50 sm:py-1.5"}),O&&(0,d.jsx)("button",{onClick:()=>P(""),className:"absolute right-1 top-1/2 -translate-y-1/2 p-0.5 text-text-muted hover:text-red-500 rounded transition-colors",title:"Clear (will use main model)",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"close"})})]}),(0,d.jsx)("button",{onClick:()=>T(!0),disabled:!j?.length,className:`w-full sm:w-auto rounded border px-2 py-2 text-xs transition-colors sm:py-1.5 whitespace-nowrap sm:shrink-0 ${j?.length?"bg-surface border-border text-text-main hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Select Model"})]})]}),G&&(0,d.jsxs)("div",{className:`flex items-center gap-2 px-2 py-1.5 rounded text-xs ${"success"===G.type?"bg-green-500/10 text-green-600":"bg-red-500/10 text-red-600"}`,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"success"===G.type?"check_circle":"error"}),(0,d.jsx)("span",{children:G.text})]}),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-2 sm:flex sm:items-center",children:[(0,d.jsxs)(f.$n,{variant:"primary",size:"sm",onClick:ac,disabled:!K&&k&&i.length>0||!M,loading:B,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"save"}),"Apply"]}),(0,d.jsxs)(f.$n,{variant:"outline",size:"sm",onClick:ad,disabled:E,loading:E,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"restore"}),"Reset"]}),(0,d.jsxs)(f.$n,{variant:"ghost",size:"sm",onClick:()=>X(!0),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"content_copy"}),"Manual Config"]})]})]})]}),Q&&(0,d.jsx)(f.rq,{isOpen:Q,onClose:()=>R(!1),onSelect:a=>{N(a.value),O||P(a.value),R(!1)},selectedModel:M,activeProviders:j,modelAliases:U,title:"Select Model for Codex"}),S&&(0,d.jsx)(f.rq,{isOpen:S,onClose:()=>T(!1),onSelect:a=>{P(a.value),T(!1)},selectedModel:O,activeProviders:j,modelAliases:U,title:"Select Subagent Model for Codex"}),(0,d.jsx)(f.uR,{isOpen:W,onClose:()=>X(!1),title:"Codex CLI - Manual Configuration",configs:(s=K&&K.trim()?K:k?"<API_KEY_FROM_DASHBOARD>":"sk_9router",u=O||M,[{filename:"~/.codex/config.toml",content:`# 9Router Configuration for Codex CLI
1
+ "use strict";exports.id=2778,exports.ids=[2778],exports.modules={8019:(a,b,c)=>{c.d(b,{Tk:()=>C,aG:()=>P,Ah:()=>D,Q6:()=>O,lF:()=>S,a7:()=>L,ZM:()=>F,WE:()=>_,E_:()=>Z,RF:()=>I,mW:()=>T,c9:()=>Q,gY:()=>ag,tA:()=>ab,kn:()=>ad,yZ:()=>G,qO:()=>M});var d=c(48249),e=c(67484),f=c(50412),g=c(81220),h=c(37837);function i({storageKey:a,changeEvent:b,itemField:c,normalize:d=a=>a,defaultName:e=a=>a}){let f=()=>[],g=a=>{};return{read:f,subscribe:a=>()=>{},upsert:(a,b)=>{let h=d(a);if(!h)return null;let i=f(),j=i.find(a=>d(a[c])===h);if(j&&!b)return j.name;let k=(b||e(h)).trim();return k?(g([...i.filter(a=>a.name!==k&&d(a[c])!==h),{name:k,[c]:h}].sort((a,b)=>a.name.localeCompare(b.name))),k):null},remove:a=>g(f().filter(b=>b.name!==a))}}let j=a=>(a||"").replace(/\/+$/,""),k=i({storageKey:"9router.cliToolEndpointPresets",changeEvent:"9router:endpoint-presets-changed",itemField:"baseUrl",normalize:j,defaultName:a=>{try{return new URL(a).host}catch{return a}}}),l=i({storageKey:"9router.cliToolApiKeyPresets",changeEvent:"9router:api-key-presets-changed",itemField:"key"});k.read,k.subscribe;let m=k.upsert,n=k.remove;l.read,l.subscribe;let o=l.upsert,p=l.remove;function q(a,{tunnelPublicUrl:b,tailscaleUrl:c,cloudUrl:d}={}){let e=j(a);return!e||[`http://127.0.0.1:${h.h0.appPort}`,b,c,d].filter(Boolean).flatMap(a=>[j(a),`${j(a)}/v1`]).includes(e)?null:m(e)}let r="__custom__",s="__save__";function t({value:a,onChange:b,requiresExternalUrl:c=!1,tunnelEnabled:f=!1,tunnelPublicUrl:g="",tailscaleEnabled:i=!1,tailscaleUrl:j="",cloudEnabled:k=!1,cloudUrl:l="",withV1:o=!0,currentUrl:p=""}){let[q,u]=(0,e.useState)([]),[v,w]=(0,e.useState)(!1),[x,y]=(0,e.useState)(""),[z,A]=(0,e.useState)("");(0,e.useRef)(!1);let B=(0,e.useRef)(""),C=(0,e.useMemo)(()=>(({requiresExternalUrl:a,tunnelEnabled:b,tunnelPublicUrl:c,tailscaleEnabled:d,tailscaleUrl:e,cloudEnabled:f,cloudUrl:g,savedPresets:i,withV1:j})=>{let k=[],l=a=>{let b;return j?(b=(a||"").replace(/\/+$/,""))?/\/v1$/.test(b)?b:`${b}/v1`:"":(a||"").replace(/\/+$/,"")};if(!a){let a=l(`http://127.0.0.1:${h.h0.appPort}`);k.push({value:"local",label:a,url:a})}if(b&&c){let a=l(c);k.push({value:"tunnel",label:a,url:a})}if(d&&e){let a=l(e);k.push({value:"tailscale",label:a,url:a})}if(f&&g){let a=l(g);k.push({value:"cloud",label:a,url:a})}return i.forEach(a=>{k.push({value:`saved:${a.name}`,label:a.baseUrl,url:a.baseUrl,saved:!0})}),k.push({value:r,label:"Custom URL...",url:""}),k})({requiresExternalUrl:c,tunnelEnabled:f,tunnelPublicUrl:g,tailscaleEnabled:i,tailscaleUrl:j,cloudEnabled:k,cloudUrl:l,savedPresets:q,withV1:o}),[c,f,g,i,j,k,l,q,o]),D=x.startsWith("saved:"),E=x===r,F=E&&(z||"").trim().length>0;return(0,d.jsxs)("div",{className:"flex flex-col gap-1.5",children:[(0,d.jsxs)("div",{className:"flex items-center gap-2",children:[(0,d.jsxs)("select",{value:x,onChange:c=>{let d=c.target.value;if(d===s){let b=(a||"").trim();if(!b)return;let c=b;try{c=new URL(b).host}catch{}let d=window.prompt("Save endpoint as:",c),e=d?.trim()?m(b,d.trim()):null;e&&y(`saved:${e}`);return}if(y(d),d===r){A(""),b("");return}let e=C.find(a=>a.value===d);e&&b(e.url)},className:"flex-1 min-w-0 px-2 py-2 bg-surface rounded text-xs border border-border focus:outline-none focus:ring-1 focus:ring-primary/50 sm:py-1.5",children:[C.map(a=>(0,d.jsx)("option",{value:a.value,children:a.label},a.value)),F&&(0,d.jsx)("option",{value:s,children:"+ Save current as..."})]}),D&&(0,d.jsx)("button",{type:"button",onClick:()=>{if(!x.startsWith("saved:"))return;n(x.slice(6)),A("");let a=C.find(a=>a.value!==r&&a.value!==x);a?(y(a.value),b(a.url)):(y(r),b(""))},className:"p-1 text-text-muted hover:text-red-500 rounded transition-colors shrink-0",title:"Delete saved endpoint",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"delete"})})]}),E&&(0,d.jsx)("input",{type:"text",value:z,onChange:a=>{let c=a.target.value;B.current=c,A(c),b(c)},placeholder:o?"https://example.com/v1":"https://example.com",className:"w-full min-w-0 px-2 py-2 bg-surface rounded border border-border text-xs focus:outline-none focus:ring-1 focus:ring-primary/50 sm:py-1.5"})]})}let u="__custom__",v="__save_key__";function w({value:a,onChange:b,apiKeys:c=[],cloudEnabled:f=!1,className:g=""}){let[h,i]=(0,e.useState)([]),[j,k]=(0,e.useState)(!1),[l,m]=(0,e.useState)(""),n=(0,e.useMemo)(()=>[...c.map(a=>({value:a.key,label:a.key})),...h.map(a=>({value:`saved:${a.name}`,label:a.key,url:a.key,saved:!0})),{value:u,label:"Custom...",url:""}],[c,h]),q=a?n.find(b=>b.value===a||b.url===a):null,r=q?q.value:j||a?u:n[0]?.value??u,s=j?l:a||"",t="string"==typeof r&&r.startsWith("saved:"),x=r===u,y=x&&(a||"").trim().length>0&&!c.some(b=>b.key===a);return 0!==c.length||0!==h.length||j||a?(0,d.jsxs)("div",{className:`flex flex-col gap-1.5 ${g}`,children:[(0,d.jsxs)("div",{className:"flex items-center gap-2",children:[(0,d.jsxs)("select",{value:r,onChange:c=>{let d=c.target.value;if(d===v)return void o((a||"").trim());if(d===u){k(!0),m(""),b("");return}k(!1),m("");let e=n.find(a=>a.value===d);e&&b(e.url??e.value)},className:"flex-1 min-w-0 px-2 py-2 bg-surface rounded text-xs border border-border focus:outline-none focus:ring-1 focus:ring-primary/50 sm:py-1.5",children:[n.map(a=>(0,d.jsx)("option",{value:a.value,children:a.label},a.value)),y&&(0,d.jsx)("option",{value:v,children:"+ Save current as..."})]}),t&&(0,d.jsx)("button",{type:"button",onClick:()=>{if(!t)return;p(r.slice(6)),k(!1),m("");let a=n.find(a=>a.value!==u&&a.value!==r);b(a?a.url??a.value:"")},className:"p-1 text-text-muted hover:text-red-500 rounded transition-colors shrink-0",title:"Delete saved key",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"delete"})})]}),x&&(0,d.jsx)("input",{type:"text",value:s,onChange:a=>{let c=a.target.value;k(!0),m(c),b(c)},placeholder:"sk-...",className:"w-full min-w-0 px-2 py-2 bg-surface rounded border border-border text-xs focus:outline-none focus:ring-1 focus:ring-primary/50 sm:py-1.5"})]}):(0,d.jsx)("span",{className:`min-w-0 rounded bg-surface/40 px-2 py-2 text-xs text-text-muted sm:py-1.5 ${g}`,children:f?"No API keys - Create one in Keys page":"sk_9router (default)"})}let x=a=>(a||"").replace(/\/+$/,"");function y(a,b={}){if(!a)return!1;let c=x(a),{tunnelPublicUrl:d,tailscaleUrl:e,cloudUrl:f}=b;return!!(/localhost|127\.0\.0\.1|0\.0\.0\.0/.test(c)||d&&c.startsWith(x(d))||e&&c.startsWith(x(e))||f&&c.startsWith(x(f)))}let z=/\[1m\](?=-review$|$)/i,A=process.env.NEXT_PUBLIC_CLOUD_URL,B=[{label:"Default",value:""},{label:"200K",value:"198000"},{label:"300K",value:"298000"},{label:"500K",value:"498000"},{label:"700K",value:"698000"}];function C({tool:a,isExpanded:b,onToggle:c,activeProviders:h,modelMappings:i,onModelMappingChange:j,baseUrl:k,hasActiveProviders:l,apiKeys:m,cloudEnabled:n,initialStatus:o,tunnelEnabled:p,tunnelPublicUrl:r,tailscaleEnabled:s,tailscaleUrl:u}){let v,x,D,[E,F]=(0,e.useState)(o||null),[G,H]=(0,e.useState)(!1),[I,J]=(0,e.useState)(!1),[K,L]=(0,e.useState)(!1),[M,N]=(0,e.useState)(null),[O,P]=(0,e.useState)(!1),[Q,R]=(0,e.useState)(!1),[S,T]=(0,e.useState)(null),[U,V]=(0,e.useState)(""),[W,X]=(0,e.useState)({}),[Y,Z]=(0,e.useState)(!1),[$,_]=(0,e.useState)(""),[aa,ab]=(0,e.useState)(!1),[ac,ad]=(0,e.useState)(!1),[ae,af]=(0,e.useState)(""),[ag,ah]=(0,e.useState)(!1);(0,e.useRef)(!1);let ai=E?.settings?.env?.ANTHROPIC_BASE_URL||"",aj=(()=>{if(!E?.installed)return null;let a=E.settings?.env?.ANTHROPIC_BASE_URL;return a?y(a,{tunnelPublicUrl:r,tailscaleUrl:u,cloudUrl:n?A:null})?"configured":"other":"not_configured"})(),ak=async a=>{let b=a.target.checked;ab(b),await fetch("/api/settings",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({ccFilterNaming:b})}).catch(()=>{})},al=()=>{let a=$||k;return a.endsWith("/v1")?a:`${a}/v1`},am=async()=>{J(!0),N(null);try{let b={ANTHROPIC_BASE_URL:al()},c=U?.trim()||(m?.length>0?m[0].key:null)||(n?null:"sk_9router");c&&(b.ANTHROPIC_AUTH_TOKEN=c),a.defaultModels.forEach(a=>{let c=i[a.alias];c&&a.envKey&&(b[a.envKey]=c)}),ae&&(b.CLAUDE_CODE_AUTO_COMPACT_WINDOW=ae);let d=await fetch("/api/cli-tools/claude-settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({env:b,exaMcpEnabled:ac,autoCompactWindow:ae})}),e=await d.json();d.ok?(q(al(),{tunnelPublicUrl:r,tailscaleUrl:u}),N({type:"success",text:"Settings applied successfully!"}),F(a=>({...a,hasBackup:!0,settings:{...a?.settings,env:b},exaMcpEnabled:ac}))):N({type:"error",text:e.error||"Failed to apply settings"})}catch(a){N({type:"error",text:a.message})}finally{J(!1)}},an=async()=>{L(!0),N(null);try{let b=await fetch("/api/cli-tools/claude-settings",{method:"DELETE"}),c=await b.json();b.ok?(N({type:"success",text:"Settings reset successfully!"}),a.defaultModels.forEach(a=>j(a.alias,a.defaultValue||"")),V(""),ad(!1),af(""),ah(!1)):N({type:"error",text:c.error||"Failed to reset settings"})}catch(a){N({type:"error",text:a.message})}finally{L(!1)}};return(0,d.jsxs)(f.Zp,{padding:"xs",className:"overflow-hidden",children:[(0,d.jsxs)("div",{className:"flex items-start justify-between gap-3 hover:cursor-pointer sm:items-center",onClick:c,children:[(0,d.jsxs)("div",{className:"flex min-w-0 items-center gap-3",children:[(0,d.jsx)("div",{className:"size-8 flex items-center justify-center shrink-0",children:(0,d.jsx)(g.default,{src:"/providers/claude.png",alt:a.name,width:32,height:32,className:"size-8 object-contain rounded-lg",sizes:"32px",onError:a=>{a.target.style.display="none"},loading:"lazy",decoding:"async"})}),(0,d.jsxs)("div",{className:"min-w-0",children:[(0,d.jsxs)("div",{className:"flex min-w-0 flex-wrap items-center gap-2",children:[(0,d.jsx)("h3",{className:"font-medium text-sm",children:a.name}),"configured"===aj&&(0,d.jsx)("span",{className:"px-1.5 py-0.5 text-[10px] font-medium bg-green-500/10 text-green-600 dark:text-green-400 rounded-full",children:"Connected"}),"not_configured"===aj&&(0,d.jsx)("span",{className:"px-1.5 py-0.5 text-[10px] font-medium bg-yellow-500/10 text-yellow-600 dark:text-yellow-400 rounded-full",children:"Not configured"}),"other"===aj&&(0,d.jsx)("span",{className:"px-1.5 py-0.5 text-[10px] font-medium bg-blue-500/10 text-blue-600 dark:text-blue-400 rounded-full",children:"Other"})]}),(0,d.jsx)("p",{className:"text-xs text-text-muted truncate",children:a.description})]})]}),(0,d.jsx)("span",{className:`material-symbols-outlined text-text-muted text-[20px] transition-transform ${b?"rotate-180":""}`,children:"expand_more"})]}),b&&(0,d.jsxs)("div",{className:"mt-4 pt-4 border-t border-border flex flex-col gap-4",children:[G&&(0,d.jsxs)("div",{className:"flex items-center gap-2 text-text-muted",children:[(0,d.jsx)("span",{className:"material-symbols-outlined animate-spin",children:"progress_activity"}),(0,d.jsx)("span",{children:"Checking Claude CLI..."})]}),!G&&E&&!E.installed&&(0,d.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,d.jsxs)("div",{className:"flex flex-col gap-3 p-4 bg-yellow-500/10 border border-yellow-500/30 rounded-lg",children:[(0,d.jsxs)("div",{className:"flex items-start gap-3",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-yellow-500",children:"warning"}),(0,d.jsxs)("div",{className:"flex-1",children:[(0,d.jsx)("p",{className:"font-medium text-yellow-600 dark:text-yellow-400",children:"Claude CLI not detected locally"}),(0,d.jsx)("p",{className:"text-sm text-text-muted",children:"Manual configuration is still available if 9router is deployed on a remote server."})]})]}),(0,d.jsxs)("div",{className:"flex items-center gap-2 pl-9",children:[(0,d.jsxs)(f.$n,{variant:"secondary",size:"sm",onClick:()=>Z(!0),className:"!bg-yellow-500/20 !border-yellow-500/40 !text-yellow-700 dark:!text-yellow-300 hover:!bg-yellow-500/30",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[18px] mr-1",children:"content_copy"}),"Manual Config"]}),(0,d.jsxs)(f.$n,{variant:"outline",size:"sm",onClick:()=>P(!O),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[18px] mr-1",children:O?"expand_less":"help"}),O?"Hide":"How to Install"]})]})]}),O&&(0,d.jsxs)("div",{className:"p-4 bg-surface border border-border rounded-lg",children:[(0,d.jsx)("h4",{className:"font-medium mb-3",children:"Installation Guide"}),(0,d.jsxs)("div",{className:"space-y-3 text-sm",children:[(0,d.jsxs)("div",{children:[(0,d.jsx)("p",{className:"text-text-muted mb-1",children:"macOS / Linux / Windows:"}),(0,d.jsx)("code",{className:"block px-3 py-2 bg-black/5 dark:bg-white/5 rounded font-mono text-xs",children:"npm install -g @anthropic-ai/claude-code"})]}),(0,d.jsxs)("p",{className:"text-text-muted",children:["After installation, run ",(0,d.jsx)("code",{className:"px-1 bg-black/5 dark:bg-white/5 rounded",children:"claude"})," to verify."]})]})]})]}),!G&&E?.installed&&(0,d.jsxs)(d.Fragment,{children:[(0,d.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"Select Endpoint"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsx)(t,{value:$||((v=$||k).endsWith("/v1")?v:`${v}/v1`),onChange:_,requiresExternalUrl:a.requiresExternalUrl,tunnelEnabled:p,tunnelPublicUrl:r,tailscaleEnabled:s,tailscaleUrl:u,currentUrl:ai})]}),E?.settings?.env?.ANTHROPIC_BASE_URL&&(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"Current"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsx)("span",{className:"min-w-0 truncate rounded bg-surface/40 px-2 py-2 text-xs text-text-muted sm:py-1.5",children:E.settings.env.ANTHROPIC_BASE_URL})]}),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"API Key"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsx)(w,{value:U,onChange:V,apiKeys:m,cloudEnabled:n})]}),a.defaultModels.map(a=>(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:a.name}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsxs)("div",{className:"relative w-full min-w-0",children:[(0,d.jsx)("input",{type:"text",value:i[a.alias]||"",onChange:b=>j(a.alias,b.target.value),placeholder:"provider/model-id",className:"w-full min-w-0 pl-2 pr-7 py-2 bg-surface rounded border border-border text-xs focus:outline-none focus:ring-1 focus:ring-primary/50 sm:py-1.5"}),i[a.alias]&&(0,d.jsx)("button",{onClick:()=>j(a.alias,""),className:"absolute right-1 top-1/2 -translate-y-1/2 p-0.5 text-text-muted hover:text-red-500 rounded transition-colors",title:"Clear",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"close"})})]}),(0,d.jsx)("button",{onClick:()=>{T(a.alias),R(!0)},disabled:!l,className:`w-full sm:w-auto rounded border px-2 py-2 text-xs transition-colors sm:py-1.5 whitespace-nowrap sm:shrink-0 ${l?"bg-surface border-border text-text-main hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Select Model"})]},a.alias)),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"Auto-compact"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsx)("select",{value:ae,onChange:a=>af(a.target.value),className:"w-full min-w-0 px-2 py-2 bg-surface rounded border border-border text-xs focus:outline-none focus:ring-1 focus:ring-primary/50 sm:py-1.5",children:B.map(a=>(0,d.jsx)("option",{value:a.value,children:a.label},a.label))})]}),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"1M context"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsxs)("label",{className:"flex items-center gap-1.5 cursor-pointer select-none",children:[(0,d.jsx)("input",{type:"checkbox",checked:ag,onChange:b=>{var c;ah(c=b.target.checked),a.defaultModels.forEach(a=>{let b=i[a.alias];b&&j(a.alias,((a,b)=>{let{model:c}=function(a){if("string"!=typeof a)return{model:a,contextMarker:null};let b=a.trim(),c=b.match(z);return c?{model:b.replace(z,"").trim(),contextMarker:c[0].slice(1,-1).toLowerCase()}:{model:a,contextMarker:null}}(a);return b?`${c}[1m]`:c})(b,c))})},className:"w-3.5 h-3.5 accent-primary cursor-pointer"}),(0,d.jsx)("span",{className:"text-xs text-text-muted",children:"Append [1m] to the model name"}),(0,d.jsx)(f.m_,{text:"Claude Code otherwise assumes a 200K window, which clamps the auto-compact window above. Applied to every mapped model — only enable it for models that really accept 1M.",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-text-muted text-[14px] cursor-help",children:"info"})})]})]}),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"Filter naming"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsxs)("label",{className:"flex items-center gap-1.5 cursor-pointer select-none",children:[(0,d.jsx)("input",{type:"checkbox",checked:aa,onChange:ak,className:"w-3.5 h-3.5 accent-primary cursor-pointer"}),(0,d.jsx)("span",{className:"text-xs text-text-muted",children:"Filter naming requests"}),(0,d.jsx)(f.m_,{text:"Intercepts Claude Code's topic-naming requests and returns a fake response locally, saving API tokens.",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-text-muted text-[14px] cursor-help",children:"info"})})]})]}),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"Web Search"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsxs)("label",{className:"flex items-center gap-1.5 cursor-pointer select-none",children:[(0,d.jsx)("input",{type:"checkbox",checked:ac,onChange:a=>ad(a.target.checked),className:"w-3.5 h-3.5 accent-primary cursor-pointer"}),(0,d.jsx)("span",{className:"text-xs text-text-muted",children:"Exa MCP"}),(0,d.jsx)(f.m_,{text:"Injects Exa MCP into ~/.claude.json so non-Claude models gain web search. Restart Claude Code after Apply.",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-text-muted text-[14px] cursor-help",children:"info"})})]})]})]}),M&&(0,d.jsxs)("div",{className:`flex items-center gap-2 px-2 py-1.5 rounded text-xs ${"success"===M.type?"bg-green-500/10 text-green-600":"bg-red-500/10 text-red-600"}`,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"success"===M.type?"check_circle":"error"}),(0,d.jsx)("span",{children:M.text})]}),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-2 sm:flex sm:items-center",children:[(0,d.jsxs)(f.$n,{variant:"primary",size:"sm",onClick:am,disabled:!l,loading:I,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"save"}),"Apply"]}),(0,d.jsxs)(f.$n,{variant:"outline",size:"sm",onClick:an,disabled:!E?.has9Router,loading:K,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"restore"}),"Reset"]}),(0,d.jsxs)(f.$n,{variant:"ghost",size:"sm",onClick:()=>Z(!0),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"content_copy"}),"Manual Config"]})]})]})]}),Q&&(0,d.jsx)(f.rq,{isOpen:Q,onClose:()=>R(!1),onSelect:a=>{S&&j(S,a.value)},selectedModel:S?i[S]:null,activeProviders:h,modelAliases:W,title:`Select model for ${S}`}),(0,d.jsx)(f.uR,{isOpen:Y,onClose:()=>Z(!1),title:"Claude CLI - Manual Configuration",configs:(x=U&&U.trim()?U:n?"<API_KEY_FROM_DASHBOARD>":"sk_9router",D={ANTHROPIC_BASE_URL:al(),ANTHROPIC_AUTH_TOKEN:x},a.defaultModels.forEach(a=>{let b=i[a.alias];b&&a.envKey&&(D[a.envKey]=b)}),ae&&(D.CLAUDE_CODE_AUTO_COMPACT_WINDOW=ae),[{filename:"~/.claude/settings.json",content:JSON.stringify({hasCompletedOnboarding:!0,env:D},null,2)}])})]})}function D({tool:a,isExpanded:b,onToggle:c,baseUrl:h,apiKeys:i,activeProviders:j,cloudEnabled:k,initialStatus:l,tunnelEnabled:m,tunnelPublicUrl:n,tailscaleEnabled:o,tailscaleUrl:p}){let r,s,u,[v,x]=(0,e.useState)(l||null),[z,A]=(0,e.useState)(!1),[B,C]=(0,e.useState)(!1),[E,F]=(0,e.useState)(!1),[G,H]=(0,e.useState)(null),[I,J]=(0,e.useState)(!1),[K,L]=(0,e.useState)(""),[M,N]=(0,e.useState)(""),[O,P]=(0,e.useState)(""),[Q,R]=(0,e.useState)(!1),[S,T]=(0,e.useState)(!1),[U,V]=(0,e.useState)({}),[W,X]=(0,e.useState)(!1),[Y,Z]=(0,e.useState)(""),$=(r=v?.config?.match(/base_url\s*=\s*"([^"]+)"/))?r[1]:"",_=v?.installed?v.config?y($,{tunnelPublicUrl:n,tailscaleUrl:p})?"configured":"other":"not_configured":null,aa=()=>{let a=Y||`${h}/v1`;return a.endsWith("/v1")?a:`${a}/v1`},ab=async()=>{A(!0);try{let a=await fetch("/api/cli-tools/codex-settings"),b=await a.json();x(b)}catch(a){x({installed:!1,error:a.message})}finally{A(!1)}},ac=async()=>{C(!0),H(null);try{let a=K&&K.trim()||k?K:"sk_9router",b=await fetch("/api/cli-tools/codex-settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({baseUrl:aa(),apiKey:a,model:M,subagentModel:O||M})}),c=await b.json();b.ok?(q(aa(),{tunnelPublicUrl:n,tailscaleUrl:p}),H({type:"success",text:"Settings applied successfully!"}),ab()):H({type:"error",text:c.error||"Failed to apply settings"})}catch(a){H({type:"error",text:a.message})}finally{C(!1)}},ad=async()=>{F(!0),H(null);try{let a=await fetch("/api/cli-tools/codex-settings",{method:"DELETE"}),b=await a.json();a.ok?(H({type:"success",text:"Settings reset successfully!"}),N(""),P(""),ab()):H({type:"error",text:b.error||"Failed to reset settings"})}catch(a){H({type:"error",text:a.message})}finally{F(!1)}};return(0,d.jsxs)(f.Zp,{padding:"xs",className:"overflow-hidden",children:[(0,d.jsxs)("div",{className:"flex items-start justify-between gap-3 hover:cursor-pointer sm:items-center",onClick:c,children:[(0,d.jsxs)("div",{className:"flex min-w-0 items-center gap-3",children:[(0,d.jsx)("div",{className:"size-8 flex items-center justify-center shrink-0",children:(0,d.jsx)(g.default,{src:"/providers/codex.png",alt:a.name,width:32,height:32,className:"size-8 object-contain rounded-lg",sizes:"32px",onError:a=>{a.target.style.display="none"},loading:"lazy",decoding:"async"})}),(0,d.jsxs)("div",{className:"min-w-0",children:[(0,d.jsxs)("div",{className:"flex min-w-0 flex-wrap items-center gap-2",children:[(0,d.jsx)("h3",{className:"font-medium text-sm",children:a.name}),"configured"===_&&(0,d.jsx)("span",{className:"px-1.5 py-0.5 text-[10px] font-medium bg-green-500/10 text-green-600 dark:text-green-400 rounded-full",children:"Connected"}),"not_configured"===_&&(0,d.jsx)("span",{className:"px-1.5 py-0.5 text-[10px] font-medium bg-yellow-500/10 text-yellow-600 dark:text-yellow-400 rounded-full",children:"Not configured"}),"other"===_&&(0,d.jsx)("span",{className:"px-1.5 py-0.5 text-[10px] font-medium bg-blue-500/10 text-blue-600 dark:text-blue-400 rounded-full",children:"Other"})]}),(0,d.jsx)("p",{className:"text-xs text-text-muted truncate",children:a.description})]})]}),(0,d.jsx)("span",{className:`material-symbols-outlined text-text-muted text-[20px] transition-transform ${b?"rotate-180":""}`,children:"expand_more"})]}),b&&(0,d.jsxs)("div",{className:"mt-4 pt-4 border-t border-border flex flex-col gap-4",children:[z&&(0,d.jsxs)("div",{className:"flex items-center gap-2 text-text-muted",children:[(0,d.jsx)("span",{className:"material-symbols-outlined animate-spin",children:"progress_activity"}),(0,d.jsx)("span",{children:"Checking Codex CLI..."})]}),!z&&v&&!v.installed&&(0,d.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,d.jsxs)("div",{className:"flex flex-col gap-3 p-4 bg-yellow-500/10 border border-yellow-500/30 rounded-lg",children:[(0,d.jsxs)("div",{className:"flex items-start gap-3",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-yellow-500",children:"warning"}),(0,d.jsxs)("div",{className:"flex-1",children:[(0,d.jsx)("p",{className:"font-medium text-yellow-600 dark:text-yellow-400",children:"Codex CLI not detected locally"}),(0,d.jsx)("p",{className:"text-sm text-text-muted",children:"Manual configuration is still available if 9router is deployed on a remote server."})]})]}),(0,d.jsxs)("div",{className:"flex items-center gap-2 pl-9",children:[(0,d.jsxs)(f.$n,{variant:"secondary",size:"sm",onClick:()=>X(!0),className:"!bg-yellow-500/20 !border-yellow-500/40 !text-yellow-700 dark:!text-yellow-300 hover:!bg-yellow-500/30",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[18px] mr-1",children:"content_copy"}),"Manual Config"]}),(0,d.jsxs)(f.$n,{variant:"outline",size:"sm",onClick:()=>J(!I),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[18px] mr-1",children:I?"expand_less":"help"}),I?"Hide":"How to Install"]})]})]}),I&&(0,d.jsxs)("div",{className:"p-4 bg-surface border border-border rounded-lg",children:[(0,d.jsx)("h4",{className:"font-medium mb-3",children:"Installation Guide"}),(0,d.jsxs)("div",{className:"space-y-3 text-sm",children:[(0,d.jsxs)("div",{children:[(0,d.jsx)("p",{className:"text-text-muted mb-1",children:"macOS / Linux / Windows:"}),(0,d.jsx)("code",{className:"block px-3 py-2 bg-black/5 dark:bg-white/5 rounded font-mono text-xs",children:"npm install -g @openai/codex"})]}),(0,d.jsxs)("p",{className:"text-text-muted",children:["After installation, run ",(0,d.jsx)("code",{className:"px-1 bg-black/5 dark:bg-white/5 rounded",children:"codex"})," to verify."]}),(0,d.jsx)("div",{className:"pt-2 border-t border-border",children:(0,d.jsxs)("p",{className:"text-text-muted text-xs",children:["Codex reads custom providers from ",(0,d.jsx)("code",{className:"px-1 bg-black/5 dark:bg-white/5 rounded",children:"~/.codex/config.toml"}),'. Click "Apply" to auto-configure.']})})]})]})]}),!z&&v?.installed&&(0,d.jsxs)(d.Fragment,{children:[(0,d.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"Select Endpoint"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsx)(t,{value:Y||Y||`${h}/v1`,onChange:Z,requiresExternalUrl:a.requiresExternalUrl,tunnelEnabled:m,tunnelPublicUrl:n,tailscaleEnabled:o,tailscaleUrl:p,currentUrl:$})]}),v?.config&&($?(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"Current"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsx)("span",{className:"min-w-0 truncate rounded bg-surface/40 px-2 py-2 text-xs text-text-muted sm:py-1.5",children:$})]}):null),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"API Key"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsx)(w,{value:K,onChange:L,apiKeys:i,cloudEnabled:k})]}),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"Model"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsxs)("div",{className:"relative w-full min-w-0",children:[(0,d.jsx)("input",{type:"text",value:M,onChange:a=>N(a.target.value),placeholder:"provider/model-id",className:"w-full min-w-0 pl-2 pr-7 py-2 bg-surface rounded border border-border text-xs focus:outline-none focus:ring-1 focus:ring-primary/50 sm:py-1.5"}),M&&(0,d.jsx)("button",{onClick:()=>N(""),className:"absolute right-1 top-1/2 -translate-y-1/2 p-0.5 text-text-muted hover:text-red-500 rounded transition-colors",title:"Clear",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"close"})})]}),(0,d.jsx)("button",{onClick:()=>R(!0),disabled:!j?.length,className:`w-full sm:w-auto rounded border px-2 py-2 text-xs transition-colors sm:py-1.5 whitespace-nowrap sm:shrink-0 ${j?.length?"bg-surface border-border text-text-main hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Select Model"})]}),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr_auto] sm:items-center sm:gap-2",children:[(0,d.jsx)("span",{className:"text-xs font-semibold text-text-main sm:text-right sm:text-sm",children:"Subagent Model"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsxs)("div",{className:"relative w-full min-w-0",children:[(0,d.jsx)("input",{type:"text",value:O,onChange:a=>P(a.target.value),placeholder:M||"provider/model-id (defaults to main model)",className:"w-full min-w-0 pl-2 pr-7 py-2 bg-surface rounded border border-border text-xs focus:outline-none focus:ring-1 focus:ring-primary/50 sm:py-1.5"}),O&&(0,d.jsx)("button",{onClick:()=>P(""),className:"absolute right-1 top-1/2 -translate-y-1/2 p-0.5 text-text-muted hover:text-red-500 rounded transition-colors",title:"Clear (will use main model)",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"close"})})]}),(0,d.jsx)("button",{onClick:()=>T(!0),disabled:!j?.length,className:`w-full sm:w-auto rounded border px-2 py-2 text-xs transition-colors sm:py-1.5 whitespace-nowrap sm:shrink-0 ${j?.length?"bg-surface border-border text-text-main hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Select Model"})]})]}),G&&(0,d.jsxs)("div",{className:`flex items-center gap-2 px-2 py-1.5 rounded text-xs ${"success"===G.type?"bg-green-500/10 text-green-600":"bg-red-500/10 text-red-600"}`,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"success"===G.type?"check_circle":"error"}),(0,d.jsx)("span",{children:G.text})]}),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-2 sm:flex sm:items-center",children:[(0,d.jsxs)(f.$n,{variant:"primary",size:"sm",onClick:ac,disabled:!K&&k&&i.length>0||!M,loading:B,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"save"}),"Apply"]}),(0,d.jsxs)(f.$n,{variant:"outline",size:"sm",onClick:ad,disabled:E,loading:E,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"restore"}),"Reset"]}),(0,d.jsxs)(f.$n,{variant:"ghost",size:"sm",onClick:()=>X(!0),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"content_copy"}),"Manual Config"]})]})]})]}),Q&&(0,d.jsx)(f.rq,{isOpen:Q,onClose:()=>R(!1),onSelect:a=>{N(a.value),O||P(a.value),R(!1)},selectedModel:M,activeProviders:j,modelAliases:U,title:"Select Model for Codex"}),S&&(0,d.jsx)(f.rq,{isOpen:S,onClose:()=>T(!1),onSelect:a=>{P(a.value),T(!1)},selectedModel:O,activeProviders:j,modelAliases:U,title:"Select Subagent Model for Codex"}),(0,d.jsx)(f.uR,{isOpen:W,onClose:()=>X(!1),title:"Codex CLI - Manual Configuration",configs:(s=K&&K.trim()?K:k?"<API_KEY_FROM_DASHBOARD>":"sk_9router",u=O||M,[{filename:"~/.codex/config.toml",content:`# 9Router Configuration for Codex CLI
2
2
  model = "${M}"
3
3
  model_provider = "9router"
4
4
 
@@ -1 +1 @@
1
- "use strict";exports.id=3943,exports.ids=[3943],exports.modules={8521:(a,b,c)=>{c.d(b,{oD:()=>C,Og:()=>E,jT:()=>D,Sc:()=>F,Wm:()=>s,jR:()=>x,I9:()=>q,Ql:()=>u,$B:()=>K,pb:()=>H,qZ:()=>L});var d=c(35024),e=c(75924),f=c(39609);let g=new Map;async function h(a,b,c,d){if(!b)return c();let e=`${a}:${b}`,f=g.get(e);if(f){if(f.promise)return d?.info?.("TOKEN_REFRESH",`Reusing in-flight refresh for ${a}`),f.promise;if(f.expiresAt>Date.now())return d?.info?.("TOKEN_REFRESH",`Reusing recent refresh result for ${a}`),f.result;g.delete(e)}let h=(async()=>{try{let a=await c();return g.set(e,{result:a,expiresAt:Date.now()+1e4}),a}catch(a){throw g.delete(e),a}})();return g.set(e,{promise:h}),h}var i=c(18080);let j=null;async function k(a,b,d=null){return a?h("xai",a,async()=>{try{j||(j=new(await Promise.all([c.e(5615),c.e(4730)]).then(c.bind(c,84730))).XaiService);let b=await j.refreshAccessToken(a,d);return{accessToken:b.access_token,refreshToken:b.refresh_token||a,expiresIn:b.expires_in,idToken:b.id_token}}catch(c){b?.warn?.("TOKEN_REFRESH",`xai refresh failed: ${c?.message||c}`);let a=String(c?.message||"");if(a.includes("invalid_grant")||a.includes("invalid_request"))return{error:"invalid_grant"};return null}},b):null}let l={claude:{bodyFormat:"json",includeClientSecret:!1,url:()=>e.NA.anthropic.token,dedupKey:"claude"},iflow:{url:()=>e.NA.iflow.token,dedupKey:"iflow",extraHeaders:(a,b)=>({Authorization:`Basic ${btoa(`${b.clientId}:${b.clientSecret}`)}`})},github:{url:()=>e.NA.github.token,dedupKey:"github",includeClientSecret:a=>!!a?.clientSecret},kimi:{dedupKey:"kimi",extraHeaders:a=>(0,e.buildKimiHeaders)(a?.providerSpecificData?.deviceId)}};async function m(a,b,c,e,g=null){let i=d.xq[a],j=l[a]||{},k=function(a,b,c){if(c?.url)try{return c.url()}catch{}return b?.refreshUrl||d.sr[a]?.tokenUrl||null}(a,i,j);return i&&k?b?h(j.dedupKey||a,b,async()=>{try{let d,h,l,{format:m,body:n}=(d=j?.bodyFormat==="json"?"json":"form",h=j?.includeClientSecret===void 0||("function"==typeof j.includeClientSecret?j.includeClientSecret(i):j.includeClientSecret),l={grant_type:"refresh_token",refresh_token:b,client_id:i.clientId},(h&&i.clientSecret&&(l.client_secret=i.clientSecret),"json"===d)?{format:"json",body:JSON.stringify(l)}:{format:"form",body:new URLSearchParams(l)}),o={"Content-Type":"json"===m?"application/json":"application/x-www-form-urlencoded",Accept:"application/json",...j.extraHeaders&&j.extraHeaders(c,i)||{}},p=await (0,f.proxyAwareFetch)(k,{method:"POST",headers:o,body:n},g);if(!p.ok){let b=await p.text(),c=r(b,p.status);if(e?.error?.("TOKEN_REFRESH",`Failed to refresh token for ${a}`,{status:p.status,error:b,permanent:c.permanent}),c.permanent)return{error:"unrecoverable_refresh_error",code:c.code||"invalid_grant",description:c.description,status:p.status};return null}let q=await p.json();return e?.info?.("TOKEN_REFRESH",`Successfully refreshed token for ${a}`,{hasNewAccessToken:!!q.access_token,hasNewRefreshToken:!!q.refresh_token,expiresIn:q.expires_in}),{accessToken:q.access_token,refreshToken:q.refresh_token||b,expiresIn:q.expires_in,...j.parse&&j.parse(q)||{}}}catch(b){return e?.error?.("TOKEN_REFRESH",`Error refreshing token for ${a}`,{error:b.message}),null}},e):(e?.warn?.("TOKEN_REFRESH",`No refresh token available for provider: ${a}`),null):(e?.warn?.("TOKEN_REFRESH",`No refresh URL configured for provider: ${a}`),null)}async function n(a,b,c){return m("kimi",a,b,c)}async function o(a,b){return a?h("cline",a,async()=>{try{let c=await fetch(d.xq.cline?.refreshUrl,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({refreshToken:a,grantType:"refresh_token",clientType:"extension"})});if(!c.ok){let a=await c.text();return b?.error?.("TOKEN_REFRESH","Failed to refresh Cline token",{status:c.status,error:a}),null}let e=await c.json(),f=e?.data||e;if(!f?.accessToken)return null;let g=f.expiresAt?Math.max(1,Math.floor((new Date(f.expiresAt).getTime()-Date.now())/1e3)):f.expiresIn||f.expires_in||3600;return{accessToken:f.accessToken,refreshToken:f.refreshToken||a,expiresIn:g}}catch(a){return b?.error?.("TOKEN_REFRESH",`Error refreshing Cline token: ${a.message}`),null}},b):null}async function p(a,b,c=null){return m("claude",a,{},b,c)}async function q(a,b,c,d){return a?h(`google:${b}`,a,async()=>{try{let f=await fetch(e.NA.google.token,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded",Accept:"application/json"},body:new URLSearchParams({grant_type:"refresh_token",refresh_token:a,client_id:b,client_secret:c})});if(!f.ok){let a=await f.text(),b=r(a,f.status);if(d?.error?.("TOKEN_REFRESH","Failed to refresh Google token",{status:f.status,error:a,permanent:b.permanent}),b.permanent)return{error:"unrecoverable_refresh_error",code:b.code||"invalid_grant",description:b.description,status:f.status};return null}let g=await f.json();return d?.info?.("TOKEN_REFRESH","Successfully refreshed Google token",{hasNewAccessToken:!!g.access_token,expiresIn:g.expires_in}),{accessToken:g.access_token,refreshToken:g.refresh_token||a,expiresIn:g.expires_in}}catch(a){return d?.error?.("TOKEN_REFRESH",`Network error refreshing Google token: ${a.message}`),null}},d):null}function r(a="",b=0){let c=null;try{c=a?JSON.parse(a):null}catch{c=null}let d=c?.error?.code||c?.error||c?.error_code||"",e=c?.error_description||c?.message||a||"",f=`${d} ${e}`.toLowerCase();return{status:b,code:d,description:e,permanent:["refresh_token_expired","refresh_token_reused","refresh_token_invalidated","invalid_grant"].some(a=>f.includes(a))}}async function s(a,b,c=null){return a?h("codex",a,async()=>{try{let g=await (0,f.proxyAwareFetch)(e.NA.openai.token,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({client_id:d.xq.codex.clientId,grant_type:"refresh_token",refresh_token:a})},c);if(!g.ok){let a=await g.text(),c=r(a,g.status);if(c.permanent)return b?.error?.("TOKEN_REFRESH","Codex refresh token already used or invalid. Re-auth required.",{status:g.status,code:c.code}),{error:"unrecoverable_refresh_error",code:c.code};return b?.error?.("TOKEN_REFRESH","Failed to refresh Codex token",{status:g.status,error:a,code:c.code,permanent:c.permanent}),null}let h=await g.json();return b?.info?.("TOKEN_REFRESH","Successfully refreshed Codex token",{hasNewAccessToken:!!h.access_token,hasNewRefreshToken:!!h.refresh_token,hasIdToken:!!h.id_token,expiresIn:h.expires_in}),{accessToken:h.access_token,refreshToken:h.refresh_token||a,idToken:h.id_token,expiresIn:h.expires_in}}catch(a){return b?.error?.("TOKEN_REFRESH",`Network error refreshing Codex token: ${a.message}`),null}},b):null}async function t(a,b,d){if(a?.profileArn)return{};let e=d?.trim?.()||null;if(!e){let{fetchKiroProfileArn:a}=await Promise.all([c.e(7774),c.e(5433),c.e(8920),c.e(24),c.e(2329),c.e(3225),c.e(6922),c.e(5215),c.e(6022),c.e(8499),c.e(8526),c.e(6249),c.e(5330),c.e(8895),c.e(4049),c.e(3535)]).then(c.bind(c,74177));e=await a(b)}return e?{providerSpecificData:{profileArn:e}}:{}}async function u(a,b,c,e=null){return a?h("kiro",a,async()=>{let g=b?.authMethod,h=b?.clientId,j=b?.clientSecret,k=b?.region;if("external_idp"===g){let d;try{d=(0,i.uo)(a,b)}catch(a){return c?.warn?.("TOKEN_REFRESH",`Invalid Kiro external_idp refresh config: ${a.message}`),null}let g=await (0,f.proxyAwareFetch)(d.tokenEndpoint,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded",Accept:"application/json"},body:d.body},e);if(!g.ok){let a=await g.text();return c?.error?.("TOKEN_REFRESH","Failed to refresh Kiro external_idp token",{status:g.status,error:a}),null}let h=await g.json();return c?.info?.("TOKEN_REFRESH","Successfully refreshed Kiro external_idp token",{hasNewAccessToken:!!h.access_token,hasNewRefreshToken:!!h.refresh_token,expiresIn:h.expires_in}),{accessToken:h.access_token,refreshToken:h.refresh_token||a,expiresIn:h.expires_in,providerSpecificData:d.providerSpecificData}}if(h&&j){let d="idc"===g&&k?`https://oidc.${k}.amazonaws.com/token`:"https://oidc.us-east-1.amazonaws.com/token",i=await (0,f.proxyAwareFetch)(d,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({clientId:h,clientSecret:j,refreshToken:a,grantType:"refresh_token"})},e);if(!i.ok){let a=await i.text();return c?.error?.("TOKEN_REFRESH","Failed to refresh Kiro AWS token",{status:i.status,error:a}),null}let l=await i.json();return c?.info?.("TOKEN_REFRESH","Successfully refreshed Kiro AWS token",{hasNewAccessToken:!!l.accessToken,expiresIn:l.expiresIn}),{accessToken:l.accessToken,refreshToken:l.refreshToken||a,expiresIn:l.expiresIn,...await t(b,l.accessToken,l.profileArn)}}let l=await (0,f.proxyAwareFetch)(d.xq.kiro.tokenUrl,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json","User-Agent":"kiro-cli/1.0.0"},body:JSON.stringify({refreshToken:a})},e);if(!l.ok){let a=await l.text();return c?.error?.("TOKEN_REFRESH","Failed to refresh Kiro social token",{status:l.status,error:a}),null}let m=await l.json();return c?.info?.("TOKEN_REFRESH","Successfully refreshed Kiro social token",{hasNewAccessToken:!!m.accessToken,expiresIn:m.expiresIn}),{accessToken:m.accessToken,refreshToken:m.refreshToken||a,expiresIn:m.expiresIn,...await t(b,m.accessToken,m.profileArn)}},c):null}async function v(a,b){return m("iflow",a,{},b)}async function w(a,b){return m("github",a,{},b)}async function x(a,b){return a?h("copilot",a,async()=>{try{let c=await fetch(d.sr.github?.copilotTokenUrl,{headers:{Authorization:`token ${a}`,"User-Agent":e.x0.USER_AGENT,"Editor-Version":`vscode/${e.x0.VSCODE_VERSION}`,"Editor-Plugin-Version":`copilot-chat/${e.x0.COPILOT_CHAT_VERSION}`,Accept:"application/json","x-github-api-version":e.x0.API_VERSION}});if(!c.ok){let a=await c.text();return b?.error?.("TOKEN_REFRESH","Failed to refresh Copilot token",{status:c.status,error:a}),null}let f=await c.json();return b?.info?.("TOKEN_REFRESH","Successfully refreshed Copilot token",{hasToken:!!f.token,expiresAt:f.expires_at}),{token:f.token,expiresAt:f.expires_at}}catch(a){return b?.error?.("TOKEN_REFRESH","Error refreshing Copilot token",{error:a.message}),null}},b):null}async function y(a,b){return a?h("codebuddy-cn",a,async()=>{let c=d.sr["codebuddy-cn"]||{},e=await fetch(c.refreshUrl,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json","User-Agent":c.userAgent,"X-Requested-With":"XMLHttpRequest","X-Domain":"copilot.tencent.com","X-Refresh-Token":a,"X-Auth-Refresh-Source":"plugin","X-Product":"SaaS"},body:"{}"});if(!e.ok){let a=await e.text();return b?.error?.("TOKEN_REFRESH","Failed to refresh CodeBuddy token",{status:e.status,error:a}),null}let f=await e.json();return 0===f.code&&f.data?.accessToken?(b?.info?.("TOKEN_REFRESH","Successfully refreshed CodeBuddy token",{hasNewAccessToken:!!f.data.accessToken,hasNewRefreshToken:!!f.data.refreshToken,expiresIn:f.data.expiresIn}),{accessToken:f.data.accessToken,refreshToken:f.data.refreshToken||a,expiresIn:f.data.expiresIn}):(b?.error?.("TOKEN_REFRESH","CodeBuddy token refresh returned no token",{code:f.code,msg:f.msg}),null)},b):null}async function z(a,b){return a?h("codebuddy-intl",a,async()=>{let c=d.sr["codebuddy-intl"]||{},e=await fetch(c.refreshUrl,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json","User-Agent":c.userAgent,"X-Requested-With":"XMLHttpRequest","X-Domain":"www.codebuddy.ai","X-Refresh-Token":a,"X-Auth-Refresh-Source":"plugin","X-Product":"SaaS"},body:"{}"});if(!e.ok){let a=await e.text();return b?.error?.("TOKEN_REFRESH","Failed to refresh CodeBuddy intl token",{status:e.status,error:a}),null}let f=await e.json();return 0===f.code&&f.data?.accessToken?(b?.info?.("TOKEN_REFRESH","Successfully refreshed CodeBuddy intl token",{hasNewAccessToken:!!f.data.accessToken,hasNewRefreshToken:!!f.data.refreshToken,expiresIn:f.data.expiresIn}),{accessToken:f.data.accessToken,refreshToken:f.data.refreshToken||a,expiresIn:f.data.expiresIn}):(b?.error?.("TOKEN_REFRESH","CodeBuddy intl token refresh returned no token",{code:f.code,msg:f.msg}),null)},b):null}async function A(a,b,c){if(!a)return null;let e=d.sr.trae||{},f=e.exchangeTokenUrl||e.tokenUrl;return f?h("trae",a,async()=>{try{let b,d=await fetch(f,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json","User-Agent":"Trae/1.0.0 antigravity-cockpit-tools"},body:JSON.stringify({ClientID:e.clientId||"ono9krqynydwx5",RefreshToken:a,ClientSecret:e.clientSecret||"-",UserID:""})});if(!d.ok){let a=await d.text();return c?.error?.("TOKEN_REFRESH","Failed to refresh Trae token",{status:d.status,error:a}),null}let g=await d.json(),h=g?.Result||g?.result||g,i=h?.AccessToken||h?.accessToken;if(!i)return c?.error?.("TOKEN_REFRESH","Trae refresh returned no AccessToken",{payload:g}),null;let j=h?.RefreshToken||h?.refreshToken||a,k=h?.ExpiresAt||h?.expiresAt;if("number"==typeof k)b=Math.max(1,k-Math.floor(Date.now()/1e3));else if("string"==typeof k){let a=new Date(k).getTime()-Date.now();b=a>0?Math.floor(a/1e3):void 0}return c?.info?.("TOKEN_REFRESH","Successfully refreshed Trae token",{hasNewAccessToken:!!i,hasNewRefreshToken:j!==a,expiresIn:b}),{accessToken:i,refreshToken:j,expiresIn:b}}catch(a){return c?.error?.("TOKEN_REFRESH",`Error refreshing Trae token: ${a.message}`),null}},c):(c?.warn?.("TOKEN_REFRESH","No Trae exchangeTokenUrl configured"),null)}async function B(a,b){return b?.info?.("TOKEN_REFRESH","windsurf: apiKey is long-lived (no refresh_token flow) — skipping"),null}let C=3e5;function D(a){return a&&"object"==typeof a&&("unrecoverable_refresh_error"===a.error||"refresh_token_reused"===a.error||"refresh_token_expired"===a.error||"refresh_token_invalidated"===a.error||"invalid_request"===a.error||"invalid_grant"===a.error||"invalid_grant"===a.code||"refresh_token_expired"===a.code||"refresh_token_reused"===a.code||"refresh_token_invalidated"===a.code)}function E(a){return e.Wu[a]?e.Wu[a]:"kimi-coding"===a&&e.Wu.kimi?e.Wu.kimi:C}function F(a){if("string"!=typeof a)return null;try{let b=JSON.parse(a);if("service_account"===b.type&&b.client_email&&b.private_key&&b.project_id)return b;return null}catch{return null}}let G=new Map;async function H(a,b,d=null){let g=a.client_email,h=G.get(g);if(h&&h.expiresAt-Date.now()>3e5)return{accessToken:h.token,expiresAt:h.expiresAt};try{let{SignJWT:h,importPKCS8:i}=await Promise.all([c.e(8292),c.e(1455)]).then(c.bind(c,71455));b?.debug?.("TOKEN_REFRESH",`Vertex minting token for ${a.client_email}`);let j=await i(a.private_key.replace(/\\n/g,"\n"),"RS256"),k=Math.floor(Date.now()/1e3),l=await new h({scope:"https://www.googleapis.com/auth/cloud-platform"}).setProtectedHeader({alg:"RS256"}).setIssuer(a.client_email).setAudience(e.NA.google.token).setIssuedAt(k).setExpirationTime(k+3600).sign(j),m=await (0,f.proxyAwareFetch)(e.NA.google.token,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:new URLSearchParams({grant_type:"urn:ietf:params:oauth:grant-type:jwt-bearer",assertion:l})},d);if(!m.ok){let a=await m.text();return b?.error?.("TOKEN_REFRESH",`Vertex token mint failed: ${a}`),null}let{access_token:n,expires_in:o}=await m.json(),p=Date.now()+(o??3600)*1e3;return G.set(g,{token:n,expiresAt:p}),b?.info?.("TOKEN_REFRESH",`Vertex token minted for ${a.client_email}`),{accessToken:n,expiresAt:p}}catch(a){return b?.error?.("TOKEN_REFRESH",`Vertex token error: ${a.message}`),null}}function I(a,b,c=null){let d=F(a.apiKey);return d?H(d,b,c):null}let J={"gemini-cli":(a,b)=>q(a.refreshToken,d.xq["gemini-cli"].clientId,d.xq["gemini-cli"].clientSecret,b),antigravity:(a,b)=>q(a.refreshToken,d.xq.antigravity.clientId,d.xq.antigravity.clientSecret,b),claude:(a,b,c)=>p(a.refreshToken,b,c),codex:(a,b,c)=>s(a.refreshToken,b,c),iflow:(a,b)=>v(a.refreshToken,b),github:(a,b)=>w(a.refreshToken,b),kiro:(a,b)=>u(a.refreshToken,a.providerSpecificData,b),xai:(a,b,c)=>k(a.refreshToken,b,c),"grok-cli":(a,b,c)=>k(a.refreshToken,b,c),gcli:(a,b,c)=>k(a.refreshToken,b,c),"codebuddy-cn":(a,b)=>y(a.refreshToken,b),"codebuddy-intl":(a,b)=>z(a.refreshToken,b),trae:(a,b)=>A(a.refreshToken,a,b),cline:(a,b)=>o(a.refreshToken,b),clinepass:(a,b)=>o(a.refreshToken,b),zed:()=>null,windsurf:(a,b)=>B(a,b),devin:()=>null,kimi:(a,b)=>n(a.refreshToken,a,b),"kimi-coding":(a,b)=>n(a.refreshToken,a,b),vertex:(a,b,c)=>I(a,b,c),"vertex-partner":(a,b,c)=>I(a,b,c)};async function K(a,b,c,d=null){if(!b?.refreshToken&&!(("vertex"===a||"vertex-partner"===a)&&b?.apiKey))return null;let e=d??(0,f.deriveConnectionProxyOptions)(b),g=J[a];return g?g(b,c,e):m(a,b.refreshToken,b,c,e)}async function L(a,b=3,c=null){for(let d=0;d<b;d++){if(d>0){let a=1e3*d;c?.debug?.("TOKEN_REFRESH",`Retry ${d}/${b} after ${a}ms`),await new Promise(b=>setTimeout(b,a))}try{let b=await a();if(b)return b}catch(a){c?.warn?.("TOKEN_REFRESH",`Attempt ${d+1}/${b} failed: ${a.message}`)}}return c?.error?.("TOKEN_REFRESH",`All ${b} retry attempts failed`),null}},18080:(a,b,c)=>{c.d(b,{Xj:()=>i,uo:()=>j});let d=new Set(["login.microsoftonline.com","login.microsoft.com","login.windows.net"]);function e(a){return"string"==typeof a?a.trim():""}function f(a){let b,c=e(a);if(!c)throw Error("token_endpoint is required");try{b=new URL(c)}catch{throw Error("token_endpoint must be a valid URL")}if("https:"!==b.protocol)throw Error("token_endpoint must use https");let f=b.hostname.toLowerCase();if(!d.has(f))throw Error("token_endpoint must be a Microsoft login endpoint");return b.toString()}function g(a){return Array.isArray(a)?a.map(e).filter(Boolean).join(" "):e(a)}function h(a){try{if(!a||"string"!=typeof a)return null;let b=a.split(".");if(3!==b.length)return null;let c=b[1].replace(/-/g,"+").replace(/_/g,"/"),d=(4-c.length%4)%4;return JSON.parse(Buffer.from(`${c}${"=".repeat(d)}`,"base64").toString("utf8"))}catch{return null}}function i(a){let b=a;if("string"==typeof b)try{b=JSON.parse(b)}catch{throw Error("CLIProxyAPI auth JSON is invalid")}if(!b||"object"!=typeof b)throw Error("CLIProxyAPI auth JSON is required");let c=e(b.auth_method||b.authMethod);if(c&&"external_idp"!==c)throw Error("Only external_idp Kiro auth is supported by this importer");let d=e(b.access_token||b.accessToken),i=e(b.refresh_token||b.refreshToken),j=e(b.client_id||b.clientId),k=f(b.token_endpoint||b.tokenEndpoint),l=e(b.profile_arn||b.profileArn),m=e(b.region)||"us-east-1",n=g(b.scopes||b.scope);if(!d)throw Error("access_token is required");if(!i)throw Error("refresh_token is required");if(!j)throw Error("client_id is required");if(!n)throw Error("scopes is required");if(!l)throw Error("profile_arn is required");let o=h(d),p=b.email||o?.email||o?.preferred_username||o?.upn||o?.sub||null;return{accessToken:d,refreshToken:i,expiresAt:function(a){let b=a.expired||a.expires_at||a.expiresAt;if(b){let a=new Date(b).getTime();if(Number.isFinite(a))return new Date(a).toISOString()}let c=Number(a.expires_in||a.expiresIn||0);if(Number.isFinite(c)&&c>0)return new Date(Date.now()+1e3*c).toISOString();let d=h(a.access_token||a.accessToken);return d?.exp?new Date(1e3*d.exp).toISOString():new Date(Date.now()+36e5).toISOString()}(b),email:p,providerSpecificData:{profileArn:l,region:m,authMethod:"external_idp",provider:"CLIProxyAPI",clientId:j,tokenEndpoint:k,scope:n}}}function j(a,b={}){let c=e(b.clientId||b.client_id),d=f(b.tokenEndpoint||b.token_endpoint),h=g(b.scope||b.scopes);if(!a)throw Error("refresh token is required");if(!c)throw Error("clientId is required for external_idp refresh");if(!h)throw Error("scope is required for external_idp refresh");return{tokenEndpoint:d,body:new URLSearchParams({grant_type:"refresh_token",client_id:c,refresh_token:a,scope:h}),providerSpecificData:{...b,authMethod:"external_idp",clientId:c,tokenEndpoint:d,scope:h}}}},93943:(a,b,c)=>{c.d(b,{Dz:()=>j,Vq:()=>m,fp:()=>k});var d=c(8521),e=c(26070),f=c(39609);let g=e.sr.codex?.maxRefreshAgeMs,h=new Map;function i(a){if(null==a||""===a)return null;if("number"==typeof a)return a<1e12?1e3*a:a;let b=new Date(a).getTime();return Number.isFinite(b)?b:null}function j(a){return i(a?.expiresAt??a?.tokenExpiresAt)}function k(a,b,c=Date.now()){if(!b)return!1;let f=j(b);if(null!==f&&f-c<(0,d.Og)(a))return!0;let h=e.sr[a]?.maxRefreshAgeMs;return!!(h&&b.refreshToken&&function(a,b=Date.now(),c=g){let d=i(a?.lastRefreshAt??a?.lastRefresh??a?.providerSpecificData?.lastRefreshAt);return!d||b-d>=c}(b,c,h))}async function l(a,b,c){let d,e=(d=b?.connectionId||b?.id||b?.email||b?.name||b?.refreshToken?.slice?.(-16)||"default",`${a}:${d}`),f=h.get(e);if(f)return f;let g=Promise.resolve().then(c).finally(()=>{h.delete(e)});return h.set(e,g),g}async function m(a,b,c,g=null){if(!b)return null;let h=g??(0,f.deriveConnectionProxyOptions)(b);return l(a,b,async()=>{let f=await (0,d.$B)(a,b,c,h);return function(a,b,c,f=Date.now()){var g,h;if(!c)return null;if((0,d.jT)(c))return c;let i={},j=new Date(f).toISOString();c.accessToken&&(i.accessToken=c.accessToken),c.apiKey&&(i.apiKey=c.apiKey),c.token&&(i.token=c.token);let k=c.refreshToken??b?.refreshToken;k&&(i.refreshToken=k);let l=c.idToken??b?.idToken;return l&&(i.idToken=l),c.expiresIn?(i.expiresIn=c.expiresIn,i.expiresAt=function(a,b=Date.now()){return a?new Date(b+1e3*a).toISOString():null}(c.expiresIn,f)):c.expiresAt&&(i.expiresAt=c.expiresAt),c.projectId&&(i.projectId=c.projectId),c.providerSpecificData&&(g=b?.providerSpecificData,i.providerSpecificData=(h=c.providerSpecificData)&&"object"==typeof h?{...g||{},...h}:g),c.copilotToken&&(i.copilotToken=c.copilotToken),c.copilotTokenExpiresAt&&(i.copilotTokenExpiresAt=c.copilotTokenExpiresAt),(e.sr[a]?.trackRefreshAt||i.accessToken||i.apiKey||i.token||i.refreshToken||i.copilotToken)&&(i.lastRefreshAt=c.lastRefreshAt||j),i}(a,b,f)})}}};
1
+ "use strict";exports.id=3943,exports.ids=[3943],exports.modules={8521:(a,b,c)=>{c.d(b,{oD:()=>C,Og:()=>E,jT:()=>D,Sc:()=>F,Wm:()=>s,jR:()=>x,I9:()=>q,Ql:()=>u,$B:()=>K,pb:()=>H,qZ:()=>L});var d=c(35024),e=c(75924),f=c(39609);let g=new Map;async function h(a,b,c,d){if(!b)return c();let e=`${a}:${b}`,f=g.get(e);if(f){if(f.promise)return d?.info?.("TOKEN_REFRESH",`Reusing in-flight refresh for ${a}`),f.promise;if(f.expiresAt>Date.now())return d?.info?.("TOKEN_REFRESH",`Reusing recent refresh result for ${a}`),f.result;g.delete(e)}let h=(async()=>{try{let a=await c();return g.set(e,{result:a,expiresAt:Date.now()+1e4}),a}catch(a){throw g.delete(e),a}})();return g.set(e,{promise:h}),h}var i=c(18080);let j=null;async function k(a,b,d=null){return a?h("xai",a,async()=>{try{j||(j=new(await Promise.all([c.e(5615),c.e(4730)]).then(c.bind(c,84730))).XaiService);let b=await j.refreshAccessToken(a,d);return{accessToken:b.access_token,refreshToken:b.refresh_token||a,expiresIn:b.expires_in,idToken:b.id_token}}catch(c){b?.warn?.("TOKEN_REFRESH",`xai refresh failed: ${c?.message||c}`);let a=String(c?.message||"");if(a.includes("invalid_grant")||a.includes("invalid_request"))return{error:"invalid_grant"};return null}},b):null}let l={claude:{bodyFormat:"json",includeClientSecret:!1,url:()=>e.NA.anthropic.token,dedupKey:"claude"},iflow:{url:()=>e.NA.iflow.token,dedupKey:"iflow",extraHeaders:(a,b)=>({Authorization:`Basic ${btoa(`${b.clientId}:${b.clientSecret}`)}`})},github:{url:()=>e.NA.github.token,dedupKey:"github",includeClientSecret:a=>!!a?.clientSecret},kimi:{dedupKey:"kimi",extraHeaders:a=>(0,e.buildKimiHeaders)(a?.providerSpecificData?.deviceId)}};async function m(a,b,c,e,g=null){let i=d.xq[a],j=l[a]||{},k=function(a,b,c){if(c?.url)try{return c.url()}catch{}return b?.refreshUrl||d.sr[a]?.tokenUrl||null}(a,i,j);return i&&k?b?h(j.dedupKey||a,b,async()=>{try{let d,h,l,{format:m,body:n}=(d=j?.bodyFormat==="json"?"json":"form",h=j?.includeClientSecret===void 0||("function"==typeof j.includeClientSecret?j.includeClientSecret(i):j.includeClientSecret),l={grant_type:"refresh_token",refresh_token:b,client_id:i.clientId},(h&&i.clientSecret&&(l.client_secret=i.clientSecret),"json"===d)?{format:"json",body:JSON.stringify(l)}:{format:"form",body:new URLSearchParams(l)}),o={"Content-Type":"json"===m?"application/json":"application/x-www-form-urlencoded",Accept:"application/json",...j.extraHeaders&&j.extraHeaders(c,i)||{}},p=await (0,f.proxyAwareFetch)(k,{method:"POST",headers:o,body:n},g);if(!p.ok){let b=await p.text(),c=r(b,p.status);if(e?.error?.("TOKEN_REFRESH",`Failed to refresh token for ${a}`,{status:p.status,error:b,permanent:c.permanent}),c.permanent)return{error:"unrecoverable_refresh_error",code:c.code||"invalid_grant",description:c.description,status:p.status};return null}let q=await p.json();return e?.info?.("TOKEN_REFRESH",`Successfully refreshed token for ${a}`,{hasNewAccessToken:!!q.access_token,hasNewRefreshToken:!!q.refresh_token,expiresIn:q.expires_in}),{accessToken:q.access_token,refreshToken:q.refresh_token||b,expiresIn:q.expires_in,...j.parse&&j.parse(q)||{}}}catch(b){return e?.error?.("TOKEN_REFRESH",`Error refreshing token for ${a}`,{error:b.message}),null}},e):(e?.warn?.("TOKEN_REFRESH",`No refresh token available for provider: ${a}`),null):(e?.warn?.("TOKEN_REFRESH",`No refresh URL configured for provider: ${a}`),null)}async function n(a,b,c){return m("kimi",a,b,c)}async function o(a,b){return a?h("cline",a,async()=>{try{let c=await fetch(d.xq.cline?.refreshUrl,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({refreshToken:a,grantType:"refresh_token",clientType:"extension"})});if(!c.ok){let a=await c.text();return b?.error?.("TOKEN_REFRESH","Failed to refresh Cline token",{status:c.status,error:a}),null}let e=await c.json(),f=e?.data||e;if(!f?.accessToken)return null;let g=f.expiresAt?Math.max(1,Math.floor((new Date(f.expiresAt).getTime()-Date.now())/1e3)):f.expiresIn||f.expires_in||3600;return{accessToken:f.accessToken,refreshToken:f.refreshToken||a,expiresIn:g}}catch(a){return b?.error?.("TOKEN_REFRESH",`Error refreshing Cline token: ${a.message}`),null}},b):null}async function p(a,b,c=null){return m("claude",a,{},b,c)}async function q(a,b,c,d){return a?h(`google:${b}`,a,async()=>{try{let f=await fetch(e.NA.google.token,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded",Accept:"application/json"},body:new URLSearchParams({grant_type:"refresh_token",refresh_token:a,client_id:b,client_secret:c})});if(!f.ok){let a=await f.text(),b=r(a,f.status);if(d?.error?.("TOKEN_REFRESH","Failed to refresh Google token",{status:f.status,error:a,permanent:b.permanent}),b.permanent)return{error:"unrecoverable_refresh_error",code:b.code||"invalid_grant",description:b.description,status:f.status};return null}let g=await f.json();return d?.info?.("TOKEN_REFRESH","Successfully refreshed Google token",{hasNewAccessToken:!!g.access_token,expiresIn:g.expires_in}),{accessToken:g.access_token,refreshToken:g.refresh_token||a,expiresIn:g.expires_in}}catch(a){return d?.error?.("TOKEN_REFRESH",`Network error refreshing Google token: ${a.message}`),null}},d):null}function r(a="",b=0){let c=null;try{c=a?JSON.parse(a):null}catch{c=null}let d=c?.error?.code||c?.error||c?.error_code||"",e=c?.error_description||c?.message||a||"",f=`${d} ${e}`.toLowerCase();return{status:b,code:d,description:e,permanent:["refresh_token_expired","refresh_token_reused","refresh_token_invalidated","invalid_grant"].some(a=>f.includes(a))}}async function s(a,b,c=null){return a?h("codex",a,async()=>{try{let g=await (0,f.proxyAwareFetch)(e.NA.openai.token,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({client_id:d.xq.codex.clientId,grant_type:"refresh_token",refresh_token:a})},c);if(!g.ok){let a=await g.text(),c=r(a,g.status);if(c.permanent)return b?.error?.("TOKEN_REFRESH","Codex refresh token already used or invalid. Re-auth required.",{status:g.status,code:c.code}),{error:"unrecoverable_refresh_error",code:c.code};return b?.error?.("TOKEN_REFRESH","Failed to refresh Codex token",{status:g.status,error:a,code:c.code,permanent:c.permanent}),null}let h=await g.json();return b?.info?.("TOKEN_REFRESH","Successfully refreshed Codex token",{hasNewAccessToken:!!h.access_token,hasNewRefreshToken:!!h.refresh_token,hasIdToken:!!h.id_token,expiresIn:h.expires_in}),{accessToken:h.access_token,refreshToken:h.refresh_token||a,idToken:h.id_token,expiresIn:h.expires_in}}catch(a){return b?.error?.("TOKEN_REFRESH",`Network error refreshing Codex token: ${a.message}`),null}},b):null}async function t(a,b,d){if(a?.profileArn)return{};let e=d?.trim?.()||null;if(!e){let{fetchKiroProfileArn:a}=await Promise.all([c.e(7774),c.e(5433),c.e(8920),c.e(24),c.e(2329),c.e(3225),c.e(6922),c.e(5215),c.e(8587),c.e(6022),c.e(8499),c.e(6249),c.e(5330),c.e(8895),c.e(4049),c.e(3535)]).then(c.bind(c,74177));e=await a(b)}return e?{providerSpecificData:{profileArn:e}}:{}}async function u(a,b,c,e=null){return a?h("kiro",a,async()=>{let g=b?.authMethod,h=b?.clientId,j=b?.clientSecret,k=b?.region;if("external_idp"===g){let d;try{d=(0,i.uo)(a,b)}catch(a){return c?.warn?.("TOKEN_REFRESH",`Invalid Kiro external_idp refresh config: ${a.message}`),null}let g=await (0,f.proxyAwareFetch)(d.tokenEndpoint,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded",Accept:"application/json"},body:d.body},e);if(!g.ok){let a=await g.text();return c?.error?.("TOKEN_REFRESH","Failed to refresh Kiro external_idp token",{status:g.status,error:a}),null}let h=await g.json();return c?.info?.("TOKEN_REFRESH","Successfully refreshed Kiro external_idp token",{hasNewAccessToken:!!h.access_token,hasNewRefreshToken:!!h.refresh_token,expiresIn:h.expires_in}),{accessToken:h.access_token,refreshToken:h.refresh_token||a,expiresIn:h.expires_in,providerSpecificData:d.providerSpecificData}}if(h&&j){let d="idc"===g&&k?`https://oidc.${k}.amazonaws.com/token`:"https://oidc.us-east-1.amazonaws.com/token",i=await (0,f.proxyAwareFetch)(d,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({clientId:h,clientSecret:j,refreshToken:a,grantType:"refresh_token"})},e);if(!i.ok){let a=await i.text();return c?.error?.("TOKEN_REFRESH","Failed to refresh Kiro AWS token",{status:i.status,error:a}),null}let l=await i.json();return c?.info?.("TOKEN_REFRESH","Successfully refreshed Kiro AWS token",{hasNewAccessToken:!!l.accessToken,expiresIn:l.expiresIn}),{accessToken:l.accessToken,refreshToken:l.refreshToken||a,expiresIn:l.expiresIn,...await t(b,l.accessToken,l.profileArn)}}let l=await (0,f.proxyAwareFetch)(d.xq.kiro.tokenUrl,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json","User-Agent":"kiro-cli/1.0.0"},body:JSON.stringify({refreshToken:a})},e);if(!l.ok){let a=await l.text();return c?.error?.("TOKEN_REFRESH","Failed to refresh Kiro social token",{status:l.status,error:a}),null}let m=await l.json();return c?.info?.("TOKEN_REFRESH","Successfully refreshed Kiro social token",{hasNewAccessToken:!!m.accessToken,expiresIn:m.expiresIn}),{accessToken:m.accessToken,refreshToken:m.refreshToken||a,expiresIn:m.expiresIn,...await t(b,m.accessToken,m.profileArn)}},c):null}async function v(a,b){return m("iflow",a,{},b)}async function w(a,b){return m("github",a,{},b)}async function x(a,b){return a?h("copilot",a,async()=>{try{let c=await fetch(d.sr.github?.copilotTokenUrl,{headers:{Authorization:`token ${a}`,"User-Agent":e.x0.USER_AGENT,"Editor-Version":`vscode/${e.x0.VSCODE_VERSION}`,"Editor-Plugin-Version":`copilot-chat/${e.x0.COPILOT_CHAT_VERSION}`,Accept:"application/json","x-github-api-version":e.x0.API_VERSION}});if(!c.ok){let a=await c.text();return b?.error?.("TOKEN_REFRESH","Failed to refresh Copilot token",{status:c.status,error:a}),null}let f=await c.json();return b?.info?.("TOKEN_REFRESH","Successfully refreshed Copilot token",{hasToken:!!f.token,expiresAt:f.expires_at}),{token:f.token,expiresAt:f.expires_at}}catch(a){return b?.error?.("TOKEN_REFRESH","Error refreshing Copilot token",{error:a.message}),null}},b):null}async function y(a,b){return a?h("codebuddy-cn",a,async()=>{let c=d.sr["codebuddy-cn"]||{},e=await fetch(c.refreshUrl,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json","User-Agent":c.userAgent,"X-Requested-With":"XMLHttpRequest","X-Domain":"copilot.tencent.com","X-Refresh-Token":a,"X-Auth-Refresh-Source":"plugin","X-Product":"SaaS"},body:"{}"});if(!e.ok){let a=await e.text();return b?.error?.("TOKEN_REFRESH","Failed to refresh CodeBuddy token",{status:e.status,error:a}),null}let f=await e.json();return 0===f.code&&f.data?.accessToken?(b?.info?.("TOKEN_REFRESH","Successfully refreshed CodeBuddy token",{hasNewAccessToken:!!f.data.accessToken,hasNewRefreshToken:!!f.data.refreshToken,expiresIn:f.data.expiresIn}),{accessToken:f.data.accessToken,refreshToken:f.data.refreshToken||a,expiresIn:f.data.expiresIn}):(b?.error?.("TOKEN_REFRESH","CodeBuddy token refresh returned no token",{code:f.code,msg:f.msg}),null)},b):null}async function z(a,b){return a?h("codebuddy-intl",a,async()=>{let c=d.sr["codebuddy-intl"]||{},e=await fetch(c.refreshUrl,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json","User-Agent":c.userAgent,"X-Requested-With":"XMLHttpRequest","X-Domain":"www.codebuddy.ai","X-Refresh-Token":a,"X-Auth-Refresh-Source":"plugin","X-Product":"SaaS"},body:"{}"});if(!e.ok){let a=await e.text();return b?.error?.("TOKEN_REFRESH","Failed to refresh CodeBuddy intl token",{status:e.status,error:a}),null}let f=await e.json();return 0===f.code&&f.data?.accessToken?(b?.info?.("TOKEN_REFRESH","Successfully refreshed CodeBuddy intl token",{hasNewAccessToken:!!f.data.accessToken,hasNewRefreshToken:!!f.data.refreshToken,expiresIn:f.data.expiresIn}),{accessToken:f.data.accessToken,refreshToken:f.data.refreshToken||a,expiresIn:f.data.expiresIn}):(b?.error?.("TOKEN_REFRESH","CodeBuddy intl token refresh returned no token",{code:f.code,msg:f.msg}),null)},b):null}async function A(a,b,c){if(!a)return null;let e=d.sr.trae||{},f=e.exchangeTokenUrl||e.tokenUrl;return f?h("trae",a,async()=>{try{let b,d=await fetch(f,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json","User-Agent":"Trae/1.0.0 antigravity-cockpit-tools"},body:JSON.stringify({ClientID:e.clientId||"ono9krqynydwx5",RefreshToken:a,ClientSecret:e.clientSecret||"-",UserID:""})});if(!d.ok){let a=await d.text();return c?.error?.("TOKEN_REFRESH","Failed to refresh Trae token",{status:d.status,error:a}),null}let g=await d.json(),h=g?.Result||g?.result||g,i=h?.AccessToken||h?.accessToken;if(!i)return c?.error?.("TOKEN_REFRESH","Trae refresh returned no AccessToken",{payload:g}),null;let j=h?.RefreshToken||h?.refreshToken||a,k=h?.ExpiresAt||h?.expiresAt;if("number"==typeof k)b=Math.max(1,k-Math.floor(Date.now()/1e3));else if("string"==typeof k){let a=new Date(k).getTime()-Date.now();b=a>0?Math.floor(a/1e3):void 0}return c?.info?.("TOKEN_REFRESH","Successfully refreshed Trae token",{hasNewAccessToken:!!i,hasNewRefreshToken:j!==a,expiresIn:b}),{accessToken:i,refreshToken:j,expiresIn:b}}catch(a){return c?.error?.("TOKEN_REFRESH",`Error refreshing Trae token: ${a.message}`),null}},c):(c?.warn?.("TOKEN_REFRESH","No Trae exchangeTokenUrl configured"),null)}async function B(a,b){return b?.info?.("TOKEN_REFRESH","windsurf: apiKey is long-lived (no refresh_token flow) — skipping"),null}let C=3e5;function D(a){return a&&"object"==typeof a&&("unrecoverable_refresh_error"===a.error||"refresh_token_reused"===a.error||"refresh_token_expired"===a.error||"refresh_token_invalidated"===a.error||"invalid_request"===a.error||"invalid_grant"===a.error||"invalid_grant"===a.code||"refresh_token_expired"===a.code||"refresh_token_reused"===a.code||"refresh_token_invalidated"===a.code)}function E(a){return e.Wu[a]?e.Wu[a]:"kimi-coding"===a&&e.Wu.kimi?e.Wu.kimi:C}function F(a){if("string"!=typeof a)return null;try{let b=JSON.parse(a);if("service_account"===b.type&&b.client_email&&b.private_key&&b.project_id)return b;return null}catch{return null}}let G=new Map;async function H(a,b,d=null){let g=a.client_email,h=G.get(g);if(h&&h.expiresAt-Date.now()>3e5)return{accessToken:h.token,expiresAt:h.expiresAt};try{let{SignJWT:h,importPKCS8:i}=await Promise.all([c.e(8292),c.e(1455)]).then(c.bind(c,71455));b?.debug?.("TOKEN_REFRESH",`Vertex minting token for ${a.client_email}`);let j=await i(a.private_key.replace(/\\n/g,"\n"),"RS256"),k=Math.floor(Date.now()/1e3),l=await new h({scope:"https://www.googleapis.com/auth/cloud-platform"}).setProtectedHeader({alg:"RS256"}).setIssuer(a.client_email).setAudience(e.NA.google.token).setIssuedAt(k).setExpirationTime(k+3600).sign(j),m=await (0,f.proxyAwareFetch)(e.NA.google.token,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:new URLSearchParams({grant_type:"urn:ietf:params:oauth:grant-type:jwt-bearer",assertion:l})},d);if(!m.ok){let a=await m.text();return b?.error?.("TOKEN_REFRESH",`Vertex token mint failed: ${a}`),null}let{access_token:n,expires_in:o}=await m.json(),p=Date.now()+(o??3600)*1e3;return G.set(g,{token:n,expiresAt:p}),b?.info?.("TOKEN_REFRESH",`Vertex token minted for ${a.client_email}`),{accessToken:n,expiresAt:p}}catch(a){return b?.error?.("TOKEN_REFRESH",`Vertex token error: ${a.message}`),null}}function I(a,b,c=null){let d=F(a.apiKey);return d?H(d,b,c):null}let J={"gemini-cli":(a,b)=>q(a.refreshToken,d.xq["gemini-cli"].clientId,d.xq["gemini-cli"].clientSecret,b),antigravity:(a,b)=>q(a.refreshToken,d.xq.antigravity.clientId,d.xq.antigravity.clientSecret,b),claude:(a,b,c)=>p(a.refreshToken,b,c),codex:(a,b,c)=>s(a.refreshToken,b,c),iflow:(a,b)=>v(a.refreshToken,b),github:(a,b)=>w(a.refreshToken,b),kiro:(a,b)=>u(a.refreshToken,a.providerSpecificData,b),xai:(a,b,c)=>k(a.refreshToken,b,c),"grok-cli":(a,b,c)=>k(a.refreshToken,b,c),gcli:(a,b,c)=>k(a.refreshToken,b,c),"codebuddy-cn":(a,b)=>y(a.refreshToken,b),"codebuddy-intl":(a,b)=>z(a.refreshToken,b),trae:(a,b)=>A(a.refreshToken,a,b),cline:(a,b)=>o(a.refreshToken,b),clinepass:(a,b)=>o(a.refreshToken,b),zed:()=>null,windsurf:(a,b)=>B(a,b),devin:()=>null,kimi:(a,b)=>n(a.refreshToken,a,b),"kimi-coding":(a,b)=>n(a.refreshToken,a,b),vertex:(a,b,c)=>I(a,b,c),"vertex-partner":(a,b,c)=>I(a,b,c)};async function K(a,b,c,d=null){if(!b?.refreshToken&&!(("vertex"===a||"vertex-partner"===a)&&b?.apiKey))return null;let e=d??(0,f.deriveConnectionProxyOptions)(b),g=J[a];return g?g(b,c,e):m(a,b.refreshToken,b,c,e)}async function L(a,b=3,c=null){for(let d=0;d<b;d++){if(d>0){let a=1e3*d;c?.debug?.("TOKEN_REFRESH",`Retry ${d}/${b} after ${a}ms`),await new Promise(b=>setTimeout(b,a))}try{let b=await a();if(b)return b}catch(a){c?.warn?.("TOKEN_REFRESH",`Attempt ${d+1}/${b} failed: ${a.message}`)}}return c?.error?.("TOKEN_REFRESH",`All ${b} retry attempts failed`),null}},18080:(a,b,c)=>{c.d(b,{Xj:()=>i,uo:()=>j});let d=new Set(["login.microsoftonline.com","login.microsoft.com","login.windows.net"]);function e(a){return"string"==typeof a?a.trim():""}function f(a){let b,c=e(a);if(!c)throw Error("token_endpoint is required");try{b=new URL(c)}catch{throw Error("token_endpoint must be a valid URL")}if("https:"!==b.protocol)throw Error("token_endpoint must use https");let f=b.hostname.toLowerCase();if(!d.has(f))throw Error("token_endpoint must be a Microsoft login endpoint");return b.toString()}function g(a){return Array.isArray(a)?a.map(e).filter(Boolean).join(" "):e(a)}function h(a){try{if(!a||"string"!=typeof a)return null;let b=a.split(".");if(3!==b.length)return null;let c=b[1].replace(/-/g,"+").replace(/_/g,"/"),d=(4-c.length%4)%4;return JSON.parse(Buffer.from(`${c}${"=".repeat(d)}`,"base64").toString("utf8"))}catch{return null}}function i(a){let b=a;if("string"==typeof b)try{b=JSON.parse(b)}catch{throw Error("CLIProxyAPI auth JSON is invalid")}if(!b||"object"!=typeof b)throw Error("CLIProxyAPI auth JSON is required");let c=e(b.auth_method||b.authMethod);if(c&&"external_idp"!==c)throw Error("Only external_idp Kiro auth is supported by this importer");let d=e(b.access_token||b.accessToken),i=e(b.refresh_token||b.refreshToken),j=e(b.client_id||b.clientId),k=f(b.token_endpoint||b.tokenEndpoint),l=e(b.profile_arn||b.profileArn),m=e(b.region)||"us-east-1",n=g(b.scopes||b.scope);if(!d)throw Error("access_token is required");if(!i)throw Error("refresh_token is required");if(!j)throw Error("client_id is required");if(!n)throw Error("scopes is required");if(!l)throw Error("profile_arn is required");let o=h(d),p=b.email||o?.email||o?.preferred_username||o?.upn||o?.sub||null;return{accessToken:d,refreshToken:i,expiresAt:function(a){let b=a.expired||a.expires_at||a.expiresAt;if(b){let a=new Date(b).getTime();if(Number.isFinite(a))return new Date(a).toISOString()}let c=Number(a.expires_in||a.expiresIn||0);if(Number.isFinite(c)&&c>0)return new Date(Date.now()+1e3*c).toISOString();let d=h(a.access_token||a.accessToken);return d?.exp?new Date(1e3*d.exp).toISOString():new Date(Date.now()+36e5).toISOString()}(b),email:p,providerSpecificData:{profileArn:l,region:m,authMethod:"external_idp",provider:"CLIProxyAPI",clientId:j,tokenEndpoint:k,scope:n}}}function j(a,b={}){let c=e(b.clientId||b.client_id),d=f(b.tokenEndpoint||b.token_endpoint),h=g(b.scope||b.scopes);if(!a)throw Error("refresh token is required");if(!c)throw Error("clientId is required for external_idp refresh");if(!h)throw Error("scope is required for external_idp refresh");return{tokenEndpoint:d,body:new URLSearchParams({grant_type:"refresh_token",client_id:c,refresh_token:a,scope:h}),providerSpecificData:{...b,authMethod:"external_idp",clientId:c,tokenEndpoint:d,scope:h}}}},93943:(a,b,c)=>{c.d(b,{Dz:()=>j,Vq:()=>m,fp:()=>k});var d=c(8521),e=c(26070),f=c(39609);let g=e.sr.codex?.maxRefreshAgeMs,h=new Map;function i(a){if(null==a||""===a)return null;if("number"==typeof a)return a<1e12?1e3*a:a;let b=new Date(a).getTime();return Number.isFinite(b)?b:null}function j(a){return i(a?.expiresAt??a?.tokenExpiresAt)}function k(a,b,c=Date.now()){if(!b)return!1;let f=j(b);if(null!==f&&f-c<(0,d.Og)(a))return!0;let h=e.sr[a]?.maxRefreshAgeMs;return!!(h&&b.refreshToken&&function(a,b=Date.now(),c=g){let d=i(a?.lastRefreshAt??a?.lastRefresh??a?.providerSpecificData?.lastRefreshAt);return!d||b-d>=c}(b,c,h))}async function l(a,b,c){let d,e=(d=b?.connectionId||b?.id||b?.email||b?.name||b?.refreshToken?.slice?.(-16)||"default",`${a}:${d}`),f=h.get(e);if(f)return f;let g=Promise.resolve().then(c).finally(()=>{h.delete(e)});return h.set(e,g),g}async function m(a,b,c,g=null){if(!b)return null;let h=g??(0,f.deriveConnectionProxyOptions)(b);return l(a,b,async()=>{let f=await (0,d.$B)(a,b,c,h);return function(a,b,c,f=Date.now()){var g,h;if(!c)return null;if((0,d.jT)(c))return c;let i={},j=new Date(f).toISOString();c.accessToken&&(i.accessToken=c.accessToken),c.apiKey&&(i.apiKey=c.apiKey),c.token&&(i.token=c.token);let k=c.refreshToken??b?.refreshToken;k&&(i.refreshToken=k);let l=c.idToken??b?.idToken;return l&&(i.idToken=l),c.expiresIn?(i.expiresIn=c.expiresIn,i.expiresAt=function(a,b=Date.now()){return a?new Date(b+1e3*a).toISOString():null}(c.expiresIn,f)):c.expiresAt&&(i.expiresAt=c.expiresAt),c.projectId&&(i.projectId=c.projectId),c.providerSpecificData&&(g=b?.providerSpecificData,i.providerSpecificData=(h=c.providerSpecificData)&&"object"==typeof h?{...g||{},...h}:g),c.copilotToken&&(i.copilotToken=c.copilotToken),c.copilotTokenExpiresAt&&(i.copilotTokenExpiresAt=c.copilotTokenExpiresAt),(e.sr[a]?.trackRefreshAt||i.accessToken||i.apiKey||i.token||i.refreshToken||i.copilotToken)&&(i.lastRefreshAt=c.lastRefreshAt||j),i}(a,b,f)})}}};
@@ -1 +1 @@
1
- "use strict";exports.id=4037,exports.ids=[3662,4037],exports.modules={3256:(a,b,c)=>{c.r(b),c.d(b,{BACKGROUND_REFRESH_LEAD_MS:()=>g,runBackgroundTokenRefreshTick:()=>p,selectConnectionsNeedingRefresh:()=>m,startBackgroundTokenRefresh:()=>q,stopBackgroundTokenRefresh:()=>r});var d=c(7803),e=c(8521),f=c(93943);let g=18e5,h=new Set(["antigravity","gemini-cli"]),i=!1,j=null,k=null,l=!1;function m(a,b=Date.now()){if(!Array.isArray(a)||0===a.length)return[];let c=[];for(let d of a){if(!d||"oauth"!==String(d.authType||"").toLowerCase().replace(/_/g,"")||!d.refreshToken)continue;let a=(0,f.Dz)(d);if(null===a)continue;let h=(0,e.Og)(d.provider);a-b<Math.max(Number.isFinite(h)?h:0,g)&&c.push(d)}return c}async function n(){let{getProviderConnections:a}=await Promise.resolve().then(c.bind(c,5781));return a({isActive:!0})}async function o(a){let{checkAndRefreshToken:b}=await c.e(7828).then(c.bind(c,67828));return b(a.provider,a,{force:!0})}async function p(a={}){if(!l){l=!0;try{let b=a.loadConnections||n,c=a.refreshConnection||o,e=a.sleep||(a=>new Promise(b=>setTimeout(b,a))),f=await b(),g=m(f,Date.now());if(0===g.length)return;let i=Number(process.env.BG_REFRESH_GOOGLE_DELAY_MS)||12e3,j=Number(process.env.BG_REFRESH_DELAY_MS)||1500;for(let a=0;a<g.length;a++){let b=g[a];try{await c(b),d.info("BG_TOKEN_REFRESH","Connection refresh finished",{id:b.id,email:b.email||b.name||b.id,provider:b.provider})}catch(a){d.warn("BG_TOKEN_REFRESH","Connection refresh failed (swallowed)",{id:b?.id,email:b?.email||b?.name||b?.id,provider:b?.provider,error:a?.message??String(a)})}if(a<g.length-1){let a=h.has(b.provider),c=a?i:j,d=a?Math.floor(4e3*Math.random()):200;await e(c+d)}}}catch(a){d.warn("BG_TOKEN_REFRESH","Tick failed (swallowed)",{error:a?.message??String(a)})}finally{l=!1}}}function q({intervalMs:a}={}){let b;if(i||function(a){if(null==a||""===a)return!1;let b=String(a).trim().toLowerCase();return"1"===b||"true"===b||"yes"===b||"on"===b}(process.env.DISABLE_BACKGROUND_TOKEN_REFRESH)||"phase-production-build"===(b=process.env.NEXT_PHASE||"")||"phase-export"===b||"phase-static"===b)return!1;i=!0;let c=Number.isFinite(a)&&a>0?a:3e5,e=()=>{p().catch(a=>{d.warn("BG_TOKEN_REFRESH","Unhandled tick rejection (swallowed)",{error:a?.message??String(a)})})};return(k=setTimeout(e,1e4)).unref&&k.unref(),(j=setInterval(e,c)).unref&&j.unref(),!0}function r(){k&&(clearTimeout(k),k=null),j&&(clearInterval(j),j=null),i&&(i=!1)}},3662:(a,b,c)=>{c.d(b,{EQ:()=>f,LY:()=>d,O:()=>e,fe:()=>q,fh:()=>h,wf:()=>g});let d={400:{type:"invalid_request_error",code:"bad_request"},401:{type:"authentication_error",code:"invalid_api_key"},402:{type:"billing_error",code:"payment_required"},403:{type:"permission_error",code:"insufficient_quota"},404:{type:"invalid_request_error",code:"model_not_found"},406:{type:"invalid_request_error",code:"model_not_supported"},429:{type:"rate_limit_error",code:"rate_limit_exceeded"},500:{type:"server_error",code:"internal_server_error"},502:{type:"server_error",code:"bad_gateway"},503:{type:"server_error",code:"service_unavailable"},504:{type:"server_error",code:"gateway_timeout"}},e={400:"Bad request",401:"Invalid API key provided",402:"Payment required",403:"You exceeded your current quota",404:"Model not found",406:"Model not supported",429:"Rate limit exceeded",500:"Internal server error",502:"Bad gateway - upstream provider error",503:"Service temporarily unavailable",504:"Gateway timeout"},f={base:2e3,max:3e5,maxLevel:15},g=3e4,h=18e5,i="auth_invalid",j="quota",k="overload",l="malformed_request",m="usage_failure",n="provider_restriction",o="transient",p=[{text:"unable to fetch usage",category:m,shouldFallback:!1,cooldownMs:0},{text:"usage details require",category:m,shouldFallback:!1,cooldownMs:0},{text:"usage api requires",category:m,shouldFallback:!1,cooldownMs:0},{text:"failed to fetch usage",category:m,shouldFallback:!1,cooldownMs:0},{text:"no credentials",category:i,shouldFallback:!0,cooldownMs:12e4},{text:"invalid_api_key",category:i,shouldFallback:!0,cooldownMs:12e4},{text:"invalid api key",category:i,shouldFallback:!0,cooldownMs:12e4},{text:"invalid x-api-key",category:i,shouldFallback:!0,cooldownMs:12e4},{text:"authentication_error",category:i,shouldFallback:!0,cooldownMs:12e4},{text:"invalid_token",category:i,shouldFallback:!0,cooldownMs:12e4},{text:"token expired",category:i,shouldFallback:!0,cooldownMs:12e4},{text:"token has been revoked",category:i,shouldFallback:!0,cooldownMs:12e4},{text:"account suspended",category:i,shouldFallback:!0,cooldownMs:12e4},{text:"request not allowed",category:n,shouldFallback:!0,cooldownMs:5e3},{text:"permission_denied",category:n,shouldFallback:!0,cooldownMs:12e4},{text:"permission_error",category:n,shouldFallback:!0,cooldownMs:12e4},{text:"organization_restricted",category:n,shouldFallback:!0,cooldownMs:12e4},{text:"geoblocked",category:n,shouldFallback:!0,cooldownMs:12e4},{text:"country not supported",category:n,shouldFallback:!0,cooldownMs:12e4},{text:"region not supported",category:n,shouldFallback:!0,cooldownMs:12e4},{text:"provider_restricted",category:n,shouldFallback:!0,cooldownMs:12e4},{text:"improperly formed request",category:l,shouldFallback:!1,cooldownMs:0},{text:"invalid_request_error",category:l,shouldFallback:!1,cooldownMs:0},{text:"bad_request",category:l,shouldFallback:!1,cooldownMs:0},{text:"context length exceeded",category:l,shouldFallback:!1,cooldownMs:0},{text:"prompt too long",category:l,shouldFallback:!1,cooldownMs:0},{text:"max_tokens too large",category:l,shouldFallback:!1,cooldownMs:0},{text:"quota exceeded",category:j,shouldFallback:!0,backoff:!0},{text:"insufficient_quota",category:j,shouldFallback:!0,backoff:!0},{text:"credit balance",category:j,shouldFallback:!0,backoff:!0},{text:"usage limit reached",category:j,shouldFallback:!0,backoff:!0},{text:"usage limit exceeded",category:j,shouldFallback:!0,backoff:!0},{text:"billing_error",category:j,shouldFallback:!0,backoff:!0},{text:"rate limit",category:k,shouldFallback:!0,backoff:!0},{text:"too many requests",category:k,shouldFallback:!0,backoff:!0},{text:"capacity",category:k,shouldFallback:!0,backoff:!0},{text:"overloaded",category:k,shouldFallback:!0,backoff:!0},{text:"overloaded_error",category:k,shouldFallback:!0,backoff:!0},{text:"resource exhausted",category:k,shouldFallback:!0,backoff:!0},{status:400,category:l,shouldFallback:!1,cooldownMs:0},{status:401,category:i,shouldFallback:!0,cooldownMs:12e4},{status:402,category:j,shouldFallback:!0,cooldownMs:12e4},{status:403,category:n,shouldFallback:!0,cooldownMs:12e4},{status:404,category:n,shouldFallback:!0,cooldownMs:12e4},{status:406,category:l,shouldFallback:!1,cooldownMs:0},{status:422,category:l,shouldFallback:!1,cooldownMs:0},{status:429,category:k,shouldFallback:!0,backoff:!0},{status:529,category:k,shouldFallback:!0,backoff:!0},{status:500,category:o,shouldFallback:!0,cooldownMs:3e4},{status:502,category:o,shouldFallback:!0,cooldownMs:3e4},{status:503,category:o,shouldFallback:!0,cooldownMs:3e4},{status:504,category:o,shouldFallback:!0,cooldownMs:3e4}];function q(a,b){let c=b?("string"==typeof b?b:JSON.stringify(b)).toLowerCase():"";for(let b of p)if(b.text&&c&&c.includes(b.text)||b.status&&b.status===a)return{category:b.category||o,shouldFallback:void 0===b.shouldFallback||b.shouldFallback,cooldownMs:b.cooldownMs,backoff:!!b.backoff,rule:b};return{category:o,shouldFallback:!0,cooldownMs:g,backoff:!1}}},7803:(a,b,c)=>{c.r(b),c.d(b,{debug:()=>o,error:()=>r,errorLine:()=>l,fmtThink:()=>m,info:()=>p,line:()=>k,maskKey:()=>v,nextTag:()=>i,request:()=>s,response:()=>t,stream:()=>u,tagForSession:()=>j,warn:()=>q});let d={DEBUG:0,INFO:1,WARN:2,ERROR:3},e=d[process.env.LOG_LEVEL?.toUpperCase?.()]??d.INFO;function f(){return new Date().toLocaleTimeString("en-US",{hour12:!1})}let g=["\uD83D\uDFE2","\uD83D\uDD35","\uD83D\uDFE3","\uD83D\uDFE1","\uD83D\uDFE0","\uD83D\uDD34","⚪","\uD83D\uDFE4"],h=0;function i(){let a=g[h%g.length];return h++,a}function j(a){if(!a)return i();let b=0;for(let c=0;c<a.length;c++)b=31*b+a.charCodeAt(c)|0;return g[Math.abs(b)%g.length]}function k(a,b,c){e>d.INFO||console.log(`[${f()}] ${a} ${b} ${c}`)}function l(a,b,c){console.log(`[${f()}] ${a} ${b} ${c}`)}function m(a){return a&&a.mode?"none"===a.mode?"off":"auto"===a.mode?"auto":"budget"===a.mode?a.budget>=1e3?`${Math.round(a.budget/1e3)}k`:`${a.budget}`:"level"===a.mode?a.level:null:null}function n(a){if(!a)return"";if("string"==typeof a)return a;try{return JSON.stringify(a)}catch{return String(a)}}function o(a,b,c){if(e<=d.DEBUG){let d=c?` ${n(c)}`:"";console.log(`[${f()}] 🔍 [${a}] ${b}${d}`)}}function p(a,b,c){if(e<=d.INFO){let d=c?` ${n(c)}`:"";console.log(`[${f()}] ℹ️ [${a}] ${b}${d}`)}}function q(a,b,c){if(e<=d.WARN){let d=c?` ${n(c)}`:"";console.warn(`[${f()}] ⚠️ [${a}] ${b}${d}`)}}function r(a,b,c){if(e<=d.ERROR){let d=c?` ${n(c)}`:"";console.log(`[${f()}] ❌ [${a}] ${b}${d}`)}}function s(a,b,c){let d=c?` ${n(c)}`:"";console.log(`\x1b[36m[${f()}] 📥 ${a} ${b}${d}\x1b[0m`)}function t(a,b,c){let d=c?` ${n(c)}`:"";console.log(`[${f()}] ${a<400?"\uD83D\uDCE4":"\uD83D\uDCA5"} ${a} (${b}ms)${d}`)}function u(a,b){let c=b?` ${n(b)}`:"";console.log(`[${f()}] 🌊 [STREAM] ${a}${c}`)}function v(a){return!a||a.length<8?"***":`${a.slice(0,4)}...${a.slice(-4)}`}},35024:(a,b,c)=>{c.d(b,{Ak:()=>e,Yg:()=>h,sr:()=>d.sr,xq:()=>d.xq});var d=c(26070);function e(a){return(a?.providerSpecificData?.baseUrl?.trim()||"http://localhost:11434").replace(/\/$/,"")}let f=d.xq["xiaomi-tokenplan"]?.regions||{},g=d.xq["xiaomi-tokenplan"]?.defaultRegion;function h(a){return f[a?.providerSpecificData?.region]||f[g]}},39006:a=>{a.exports={rE:"0.5.86"}}};
1
+ "use strict";exports.id=4037,exports.ids=[3662,4037],exports.modules={3256:(a,b,c)=>{c.r(b),c.d(b,{BACKGROUND_REFRESH_LEAD_MS:()=>g,runBackgroundTokenRefreshTick:()=>p,selectConnectionsNeedingRefresh:()=>m,startBackgroundTokenRefresh:()=>q,stopBackgroundTokenRefresh:()=>r});var d=c(7803),e=c(8521),f=c(93943);let g=18e5,h=new Set(["antigravity","gemini-cli"]),i=!1,j=null,k=null,l=!1;function m(a,b=Date.now()){if(!Array.isArray(a)||0===a.length)return[];let c=[];for(let d of a){if(!d||"oauth"!==String(d.authType||"").toLowerCase().replace(/_/g,"")||!d.refreshToken)continue;let a=(0,f.Dz)(d);if(null===a)continue;let h=(0,e.Og)(d.provider);a-b<Math.max(Number.isFinite(h)?h:0,g)&&c.push(d)}return c}async function n(){let{getProviderConnections:a}=await Promise.resolve().then(c.bind(c,5781));return a({isActive:!0})}async function o(a){let{checkAndRefreshToken:b}=await c.e(7828).then(c.bind(c,67828));return b(a.provider,a,{force:!0})}async function p(a={}){if(!l){l=!0;try{let b=a.loadConnections||n,c=a.refreshConnection||o,e=a.sleep||(a=>new Promise(b=>setTimeout(b,a))),f=await b(),g=m(f,Date.now());if(0===g.length)return;let i=Number(process.env.BG_REFRESH_GOOGLE_DELAY_MS)||12e3,j=Number(process.env.BG_REFRESH_DELAY_MS)||1500;for(let a=0;a<g.length;a++){let b=g[a];try{await c(b),d.info("BG_TOKEN_REFRESH","Connection refresh finished",{id:b.id,email:b.email||b.name||b.id,provider:b.provider})}catch(a){d.warn("BG_TOKEN_REFRESH","Connection refresh failed (swallowed)",{id:b?.id,email:b?.email||b?.name||b?.id,provider:b?.provider,error:a?.message??String(a)})}if(a<g.length-1){let a=h.has(b.provider),c=a?i:j,d=a?Math.floor(4e3*Math.random()):200;await e(c+d)}}}catch(a){d.warn("BG_TOKEN_REFRESH","Tick failed (swallowed)",{error:a?.message??String(a)})}finally{l=!1}}}function q({intervalMs:a}={}){let b;if(i||function(a){if(null==a||""===a)return!1;let b=String(a).trim().toLowerCase();return"1"===b||"true"===b||"yes"===b||"on"===b}(process.env.DISABLE_BACKGROUND_TOKEN_REFRESH)||"phase-production-build"===(b=process.env.NEXT_PHASE||"")||"phase-export"===b||"phase-static"===b)return!1;i=!0;let c=Number.isFinite(a)&&a>0?a:3e5,e=()=>{p().catch(a=>{d.warn("BG_TOKEN_REFRESH","Unhandled tick rejection (swallowed)",{error:a?.message??String(a)})})};return(k=setTimeout(e,1e4)).unref&&k.unref(),(j=setInterval(e,c)).unref&&j.unref(),!0}function r(){k&&(clearTimeout(k),k=null),j&&(clearInterval(j),j=null),i&&(i=!1)}},3662:(a,b,c)=>{c.d(b,{EQ:()=>f,LY:()=>d,O:()=>e,fe:()=>q,fh:()=>h,wf:()=>g});let d={400:{type:"invalid_request_error",code:"bad_request"},401:{type:"authentication_error",code:"invalid_api_key"},402:{type:"billing_error",code:"payment_required"},403:{type:"permission_error",code:"insufficient_quota"},404:{type:"invalid_request_error",code:"model_not_found"},406:{type:"invalid_request_error",code:"model_not_supported"},429:{type:"rate_limit_error",code:"rate_limit_exceeded"},500:{type:"server_error",code:"internal_server_error"},502:{type:"server_error",code:"bad_gateway"},503:{type:"server_error",code:"service_unavailable"},504:{type:"server_error",code:"gateway_timeout"}},e={400:"Bad request",401:"Invalid API key provided",402:"Payment required",403:"You exceeded your current quota",404:"Model not found",406:"Model not supported",429:"Rate limit exceeded",500:"Internal server error",502:"Bad gateway - upstream provider error",503:"Service temporarily unavailable",504:"Gateway timeout"},f={base:2e3,max:3e5,maxLevel:15},g=3e4,h=18e5,i="auth_invalid",j="quota",k="overload",l="malformed_request",m="usage_failure",n="provider_restriction",o="transient",p=[{text:"unable to fetch usage",category:m,shouldFallback:!1,cooldownMs:0},{text:"usage details require",category:m,shouldFallback:!1,cooldownMs:0},{text:"usage api requires",category:m,shouldFallback:!1,cooldownMs:0},{text:"failed to fetch usage",category:m,shouldFallback:!1,cooldownMs:0},{text:"no credentials",category:i,shouldFallback:!0,cooldownMs:12e4},{text:"invalid_api_key",category:i,shouldFallback:!0,cooldownMs:12e4},{text:"invalid api key",category:i,shouldFallback:!0,cooldownMs:12e4},{text:"invalid x-api-key",category:i,shouldFallback:!0,cooldownMs:12e4},{text:"authentication_error",category:i,shouldFallback:!0,cooldownMs:12e4},{text:"invalid_token",category:i,shouldFallback:!0,cooldownMs:12e4},{text:"token expired",category:i,shouldFallback:!0,cooldownMs:12e4},{text:"token has been revoked",category:i,shouldFallback:!0,cooldownMs:12e4},{text:"account suspended",category:i,shouldFallback:!0,cooldownMs:12e4},{text:"request not allowed",category:n,shouldFallback:!0,cooldownMs:5e3},{text:"permission_denied",category:n,shouldFallback:!0,cooldownMs:12e4},{text:"permission_error",category:n,shouldFallback:!0,cooldownMs:12e4},{text:"organization_restricted",category:n,shouldFallback:!0,cooldownMs:12e4},{text:"geoblocked",category:n,shouldFallback:!0,cooldownMs:12e4},{text:"country not supported",category:n,shouldFallback:!0,cooldownMs:12e4},{text:"region not supported",category:n,shouldFallback:!0,cooldownMs:12e4},{text:"provider_restricted",category:n,shouldFallback:!0,cooldownMs:12e4},{text:"improperly formed request",category:l,shouldFallback:!1,cooldownMs:0},{text:"invalid_request_error",category:l,shouldFallback:!1,cooldownMs:0},{text:"bad_request",category:l,shouldFallback:!1,cooldownMs:0},{text:"context length exceeded",category:l,shouldFallback:!1,cooldownMs:0},{text:"prompt too long",category:l,shouldFallback:!1,cooldownMs:0},{text:"max_tokens too large",category:l,shouldFallback:!1,cooldownMs:0},{text:"quota exceeded",category:j,shouldFallback:!0,backoff:!0},{text:"insufficient_quota",category:j,shouldFallback:!0,backoff:!0},{text:"credit balance",category:j,shouldFallback:!0,backoff:!0},{text:"usage limit reached",category:j,shouldFallback:!0,backoff:!0},{text:"usage limit exceeded",category:j,shouldFallback:!0,backoff:!0},{text:"billing_error",category:j,shouldFallback:!0,backoff:!0},{text:"rate limit",category:k,shouldFallback:!0,backoff:!0},{text:"too many requests",category:k,shouldFallback:!0,backoff:!0},{text:"capacity",category:k,shouldFallback:!0,backoff:!0},{text:"overloaded",category:k,shouldFallback:!0,backoff:!0},{text:"overloaded_error",category:k,shouldFallback:!0,backoff:!0},{text:"resource exhausted",category:k,shouldFallback:!0,backoff:!0},{status:400,category:l,shouldFallback:!1,cooldownMs:0},{status:401,category:i,shouldFallback:!0,cooldownMs:12e4},{status:402,category:j,shouldFallback:!0,cooldownMs:12e4},{status:403,category:n,shouldFallback:!0,cooldownMs:12e4},{status:404,category:n,shouldFallback:!0,cooldownMs:12e4},{status:406,category:l,shouldFallback:!1,cooldownMs:0},{status:422,category:l,shouldFallback:!1,cooldownMs:0},{status:429,category:k,shouldFallback:!0,backoff:!0},{status:529,category:k,shouldFallback:!0,backoff:!0},{status:500,category:o,shouldFallback:!0,cooldownMs:3e4},{status:502,category:o,shouldFallback:!0,cooldownMs:3e4},{status:503,category:o,shouldFallback:!0,cooldownMs:3e4},{status:504,category:o,shouldFallback:!0,cooldownMs:3e4}];function q(a,b){let c=b?("string"==typeof b?b:JSON.stringify(b)).toLowerCase():"";for(let b of p)if(b.text&&c&&c.includes(b.text)||b.status&&b.status===a)return{category:b.category||o,shouldFallback:void 0===b.shouldFallback||b.shouldFallback,cooldownMs:b.cooldownMs,backoff:!!b.backoff,rule:b};return{category:o,shouldFallback:!0,cooldownMs:g,backoff:!1}}},7803:(a,b,c)=>{c.r(b),c.d(b,{debug:()=>o,error:()=>r,errorLine:()=>l,fmtThink:()=>m,info:()=>p,line:()=>k,maskKey:()=>v,nextTag:()=>i,request:()=>s,response:()=>t,stream:()=>u,tagForSession:()=>j,warn:()=>q});let d={DEBUG:0,INFO:1,WARN:2,ERROR:3},e=d[process.env.LOG_LEVEL?.toUpperCase?.()]??d.INFO;function f(){return new Date().toLocaleTimeString("en-US",{hour12:!1})}let g=["\uD83D\uDFE2","\uD83D\uDD35","\uD83D\uDFE3","\uD83D\uDFE1","\uD83D\uDFE0","\uD83D\uDD34","⚪","\uD83D\uDFE4"],h=0;function i(){let a=g[h%g.length];return h++,a}function j(a){if(!a)return i();let b=0;for(let c=0;c<a.length;c++)b=31*b+a.charCodeAt(c)|0;return g[Math.abs(b)%g.length]}function k(a,b,c){e>d.INFO||console.log(`[${f()}] ${a} ${b} ${c}`)}function l(a,b,c){console.log(`[${f()}] ${a} ${b} ${c}`)}function m(a){return a&&a.mode?"none"===a.mode?"off":"auto"===a.mode?"auto":"budget"===a.mode?a.budget>=1e3?`${Math.round(a.budget/1e3)}k`:`${a.budget}`:"level"===a.mode?a.level:null:null}function n(a){if(!a)return"";if("string"==typeof a)return a;try{return JSON.stringify(a)}catch{return String(a)}}function o(a,b,c){if(e<=d.DEBUG){let d=c?` ${n(c)}`:"";console.log(`[${f()}] 🔍 [${a}] ${b}${d}`)}}function p(a,b,c){if(e<=d.INFO){let d=c?` ${n(c)}`:"";console.log(`[${f()}] ℹ️ [${a}] ${b}${d}`)}}function q(a,b,c){if(e<=d.WARN){let d=c?` ${n(c)}`:"";console.warn(`[${f()}] ⚠️ [${a}] ${b}${d}`)}}function r(a,b,c){if(e<=d.ERROR){let d=c?` ${n(c)}`:"";console.log(`[${f()}] ❌ [${a}] ${b}${d}`)}}function s(a,b,c){let d=c?` ${n(c)}`:"";console.log(`\x1b[36m[${f()}] 📥 ${a} ${b}${d}\x1b[0m`)}function t(a,b,c){let d=c?` ${n(c)}`:"";console.log(`[${f()}] ${a<400?"\uD83D\uDCE4":"\uD83D\uDCA5"} ${a} (${b}ms)${d}`)}function u(a,b){let c=b?` ${n(b)}`:"";console.log(`[${f()}] 🌊 [STREAM] ${a}${c}`)}function v(a){return!a||a.length<8?"***":`${a.slice(0,4)}...${a.slice(-4)}`}},35024:(a,b,c)=>{c.d(b,{Ak:()=>e,Yg:()=>h,sr:()=>d.sr,xq:()=>d.xq});var d=c(26070);function e(a){return(a?.providerSpecificData?.baseUrl?.trim()||"http://localhost:11434").replace(/\/$/,"")}let f=d.xq["xiaomi-tokenplan"]?.regions||{},g=d.xq["xiaomi-tokenplan"]?.defaultRegion;function h(a){return f[a?.providerSpecificData?.region]||f[g]}},39006:a=>{a.exports={rE:"0.5.87"}}};