switchboard-router 0.9.65 → 0.9.67

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 (340) hide show
  1. package/app/{.next-cli-build/static/chunks/1321-fed8b28775abdff1.js → .next/static/chunks/1321-648c1dd2b30b0477.js} +1 -1
  2. package/app/.next-cli-build/BUILD_ID +1 -1
  3. package/app/.next-cli-build/app-path-routes-manifest.json +11 -11
  4. package/app/.next-cli-build/build-manifest.json +2 -2
  5. package/app/.next-cli-build/prerender-manifest.json +3 -3
  6. package/app/.next-cli-build/server/app/(dashboard)/dashboard/agent-library/page.js.nft.json +1 -1
  7. package/app/.next-cli-build/server/app/(dashboard)/dashboard/agent-library/page_client-reference-manifest.js +1 -1
  8. package/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page.js.nft.json +1 -1
  9. package/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page_client-reference-manifest.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.nft.json +1 -1
  13. package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page_client-reference-manifest.js +1 -1
  14. package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page.js.nft.json +1 -1
  15. package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page_client-reference-manifest.js +1 -1
  16. package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/routing/page.js.nft.json +1 -1
  17. package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/routing/page_client-reference-manifest.js +1 -1
  18. package/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page.js.nft.json +1 -1
  19. package/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page_client-reference-manifest.js +1 -1
  20. package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page.js.nft.json +1 -1
  21. package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page_client-reference-manifest.js +1 -1
  22. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page.js.nft.json +1 -1
  23. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page_client-reference-manifest.js +1 -1
  24. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page.js.nft.json +1 -1
  25. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page_client-reference-manifest.js +1 -1
  26. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page.js.nft.json +1 -1
  27. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page_client-reference-manifest.js +1 -1
  28. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/page.js.nft.json +1 -1
  29. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/page_client-reference-manifest.js +1 -1
  30. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page.js.nft.json +1 -1
  31. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page_client-reference-manifest.js +1 -1
  32. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page.js.nft.json +1 -1
  33. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page_client-reference-manifest.js +1 -1
  34. package/app/.next-cli-build/server/app/(dashboard)/dashboard/page.js.nft.json +1 -1
  35. package/app/.next-cli-build/server/app/(dashboard)/dashboard/page_client-reference-manifest.js +1 -1
  36. package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page.js.nft.json +1 -1
  37. package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page_client-reference-manifest.js +1 -1
  38. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page.js.nft.json +1 -1
  39. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page_client-reference-manifest.js +1 -1
  40. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page.js +1 -1
  41. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page.js.nft.json +1 -1
  42. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page_client-reference-manifest.js +1 -1
  43. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page.js.nft.json +1 -1
  44. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page_client-reference-manifest.js +1 -1
  45. package/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page.js.nft.json +1 -1
  46. package/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page_client-reference-manifest.js +1 -1
  47. package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page.js.nft.json +1 -1
  48. package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page_client-reference-manifest.js +1 -1
  49. package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/[id]/page.js.nft.json +1 -1
  50. package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/[id]/page_client-reference-manifest.js +1 -1
  51. package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page.js.nft.json +1 -1
  52. package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page_client-reference-manifest.js +1 -1
  53. package/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page.js.nft.json +1 -1
  54. package/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page_client-reference-manifest.js +1 -1
  55. package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page.js.nft.json +1 -1
  56. package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page_client-reference-manifest.js +1 -1
  57. package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page.js.nft.json +1 -1
  58. package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page_client-reference-manifest.js +1 -1
  59. package/app/.next-cli-build/server/app/_global-error/page.js.nft.json +1 -1
  60. package/app/.next-cli-build/server/app/_global-error/page_client-reference-manifest.js +1 -1
  61. package/app/.next-cli-build/server/app/_global-error.html +1 -1
  62. package/app/.next-cli-build/server/app/_global-error.rsc +1 -1
  63. package/app/.next-cli-build/server/app/_global-error.segments/_full.segment.rsc +1 -1
  64. package/app/.next-cli-build/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
  65. package/app/.next-cli-build/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  66. package/app/.next-cli-build/server/app/_not-found/page.js.nft.json +1 -1
  67. package/app/.next-cli-build/server/app/_not-found/page_client-reference-manifest.js +1 -1
  68. package/app/.next-cli-build/server/app/_not-found.html +1 -1
  69. package/app/.next-cli-build/server/app/_not-found.rsc +3 -3
  70. package/app/.next-cli-build/server/app/_not-found.segments/_full.segment.rsc +3 -3
  71. package/app/.next-cli-build/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +3 -3
  72. package/app/.next-cli-build/server/app/_not-found.segments/_tree.segment.rsc +1 -1
  73. package/app/.next-cli-build/server/app/api/agent-library/catalog/route.js.nft.json +1 -1
  74. package/app/.next-cli-build/server/app/api/agent-library/doctor/route.js.nft.json +1 -1
  75. package/app/.next-cli-build/server/app/api/agent-library/export/route.js.nft.json +1 -1
  76. package/app/.next-cli-build/server/app/api/agent-library/mcp/route.js.nft.json +1 -1
  77. package/app/.next-cli-build/server/app/api/agent-library/route.js.nft.json +1 -1
  78. package/app/.next-cli-build/server/app/api/agent-library/skills/route.js.nft.json +1 -1
  79. package/app/.next-cli-build/server/app/api/agent-library/sync/route.js.nft.json +1 -1
  80. package/app/.next-cli-build/server/app/api/agent-library/updates/route.js.nft.json +1 -1
  81. package/app/.next-cli-build/server/app/api/auth/login/route.js.nft.json +1 -1
  82. package/app/.next-cli-build/server/app/api/auth/logout/route.js.nft.json +1 -1
  83. package/app/.next-cli-build/server/app/api/auth/status/route.js.nft.json +1 -1
  84. package/app/.next-cli-build/server/app/api/cli-tools/aider-settings/route.js +2 -2
  85. package/app/.next-cli-build/server/app/api/cli-tools/aider-settings/route.js.nft.json +1 -1
  86. package/app/.next-cli-build/server/app/api/cli-tools/all-statuses/route.js +6 -6
  87. package/app/.next-cli-build/server/app/api/cli-tools/all-statuses/route.js.nft.json +1 -1
  88. package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/alias/route.js +1 -1
  89. package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/alias/route.js.nft.json +1 -1
  90. package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/route.js.nft.json +1 -1
  91. package/app/.next-cli-build/server/app/api/cli-tools/claude-full-catalog/route.js.nft.json +1 -1
  92. package/app/.next-cli-build/server/app/api/cli-tools/claude-picker-labels/route.js.nft.json +1 -1
  93. package/app/.next-cli-build/server/app/api/cli-tools/claude-settings/route.js.nft.json +1 -1
  94. package/app/.next-cli-build/server/app/api/cli-tools/cline-settings/route.js +1 -1
  95. package/app/.next-cli-build/server/app/api/cli-tools/cline-settings/route.js.nft.json +1 -1
  96. package/app/.next-cli-build/server/app/api/cli-tools/codex-settings/route.js +1 -1
  97. package/app/.next-cli-build/server/app/api/cli-tools/codex-settings/route.js.nft.json +1 -1
  98. package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-registry/route.js +2 -2
  99. package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-registry/route.js.nft.json +1 -1
  100. package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-tools/route.js +2 -2
  101. package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-tools/route.js.nft.json +1 -1
  102. package/app/.next-cli-build/server/app/api/cli-tools/cowork-settings/route.js +1 -1
  103. package/app/.next-cli-build/server/app/api/cli-tools/cowork-settings/route.js.nft.json +1 -1
  104. package/app/.next-cli-build/server/app/api/cli-tools/deepseek-tui-settings/route.js +1 -1
  105. package/app/.next-cli-build/server/app/api/cli-tools/deepseek-tui-settings/route.js.nft.json +1 -1
  106. package/app/.next-cli-build/server/app/api/cli-tools/droid-settings/route.js +2 -2
  107. package/app/.next-cli-build/server/app/api/cli-tools/droid-settings/route.js.nft.json +1 -1
  108. package/app/.next-cli-build/server/app/api/cli-tools/fx-settings/manual-configs/route.js.nft.json +1 -1
  109. package/app/.next-cli-build/server/app/api/cli-tools/fx-settings/route.js +1 -1
  110. package/app/.next-cli-build/server/app/api/cli-tools/fx-settings/route.js.nft.json +1 -1
  111. package/app/.next-cli-build/server/app/api/cli-tools/gemini-cli-settings/route.js +3 -3
  112. package/app/.next-cli-build/server/app/api/cli-tools/gemini-cli-settings/route.js.nft.json +1 -1
  113. package/app/.next-cli-build/server/app/api/cli-tools/grok-settings/route.js +2 -2
  114. package/app/.next-cli-build/server/app/api/cli-tools/grok-settings/route.js.nft.json +1 -1
  115. package/app/.next-cli-build/server/app/api/cli-tools/hermes-settings/route.js +3 -3
  116. package/app/.next-cli-build/server/app/api/cli-tools/hermes-settings/route.js.nft.json +1 -1
  117. package/app/.next-cli-build/server/app/api/cli-tools/jcode-settings/route.js +2 -2
  118. package/app/.next-cli-build/server/app/api/cli-tools/jcode-settings/route.js.nft.json +1 -1
  119. package/app/.next-cli-build/server/app/api/cli-tools/kilo-settings/route.js +2 -2
  120. package/app/.next-cli-build/server/app/api/cli-tools/kilo-settings/route.js.nft.json +1 -1
  121. package/app/.next-cli-build/server/app/api/cli-tools/openclaw-settings/route.js +2 -2
  122. package/app/.next-cli-build/server/app/api/cli-tools/openclaw-settings/route.js.nft.json +1 -1
  123. package/app/.next-cli-build/server/app/api/cli-tools/opencode-settings/route.js +1 -1
  124. package/app/.next-cli-build/server/app/api/cli-tools/opencode-settings/route.js.nft.json +1 -1
  125. package/app/.next-cli-build/server/app/api/cli-tools/pi-settings/manual-configs/route.js.nft.json +1 -1
  126. package/app/.next-cli-build/server/app/api/cli-tools/pi-settings/route.js +1 -1
  127. package/app/.next-cli-build/server/app/api/cli-tools/pi-settings/route.js.nft.json +1 -1
  128. package/app/.next-cli-build/server/app/api/cli-tools/picker-labels/route.js.nft.json +1 -1
  129. package/app/.next-cli-build/server/app/api/combos/[id]/route.js.nft.json +1 -1
  130. package/app/.next-cli-build/server/app/api/combos/route.js.nft.json +1 -1
  131. package/app/.next-cli-build/server/app/api/headroom/extras/route.js.nft.json +1 -1
  132. package/app/.next-cli-build/server/app/api/headroom/proxy/[...path]/route.js.nft.json +1 -1
  133. package/app/.next-cli-build/server/app/api/headroom/restart/route.js.nft.json +1 -1
  134. package/app/.next-cli-build/server/app/api/headroom/start/route.js.nft.json +1 -1
  135. package/app/.next-cli-build/server/app/api/headroom/status/route.js.nft.json +1 -1
  136. package/app/.next-cli-build/server/app/api/headroom/stop/route.js.nft.json +1 -1
  137. package/app/.next-cli-build/server/app/api/health/live/route.js.nft.json +1 -1
  138. package/app/.next-cli-build/server/app/api/health/route.js.nft.json +1 -1
  139. package/app/.next-cli-build/server/app/api/keys/[id]/route.js.nft.json +1 -1
  140. package/app/.next-cli-build/server/app/api/keys/route.js.nft.json +1 -1
  141. package/app/.next-cli-build/server/app/api/locale/route.js.nft.json +1 -1
  142. package/app/.next-cli-build/server/app/api/mcp/[plugin]/message/route.js.nft.json +1 -1
  143. package/app/.next-cli-build/server/app/api/mcp/[plugin]/sse/route.js.nft.json +1 -1
  144. package/app/.next-cli-build/server/app/api/media-providers/tts/deepgram/voices/route.js.nft.json +1 -1
  145. package/app/.next-cli-build/server/app/api/media-providers/tts/elevenlabs/voices/route.js.nft.json +1 -1
  146. package/app/.next-cli-build/server/app/api/media-providers/tts/inworld/voices/route.js.nft.json +1 -1
  147. package/app/.next-cli-build/server/app/api/media-providers/tts/minimax/voices/route.js.nft.json +1 -1
  148. package/app/.next-cli-build/server/app/api/media-providers/tts/voices/route.js.nft.json +1 -1
  149. package/app/.next-cli-build/server/app/api/mgmt/v1/combos/[id]/route.js.nft.json +1 -1
  150. package/app/.next-cli-build/server/app/api/mgmt/v1/combos/[id]/strategy/route.js.nft.json +1 -1
  151. package/app/.next-cli-build/server/app/api/mgmt/v1/combos/route.js.nft.json +1 -1
  152. package/app/.next-cli-build/server/app/api/mgmt/v1/health/route.js.nft.json +1 -1
  153. package/app/.next-cli-build/server/app/api/mgmt/v1/metrics/route.js.nft.json +1 -1
  154. package/app/.next-cli-build/server/app/api/mgmt/v1/providers/route.js.nft.json +1 -1
  155. package/app/.next-cli-build/server/app/api/mgmt/v1/routing/route.js.nft.json +1 -1
  156. package/app/.next-cli-build/server/app/api/mgmt/v1/usage/route.js.nft.json +1 -1
  157. package/app/.next-cli-build/server/app/api/mgmt/v1/version/route.js.nft.json +1 -1
  158. package/app/.next-cli-build/server/app/api/models/alias/route.js.nft.json +1 -1
  159. package/app/.next-cli-build/server/app/api/models/availability/route.js.nft.json +1 -1
  160. package/app/.next-cli-build/server/app/api/models/custom/route.js.nft.json +1 -1
  161. package/app/.next-cli-build/server/app/api/models/disabled/route.js.nft.json +1 -1
  162. package/app/.next-cli-build/server/app/api/models/routable/route.js +1 -1
  163. package/app/.next-cli-build/server/app/api/models/routable/route.js.nft.json +1 -1
  164. package/app/.next-cli-build/server/app/api/models/route.js.nft.json +1 -1
  165. package/app/.next-cli-build/server/app/api/models/test/route.js.nft.json +1 -1
  166. package/app/.next-cli-build/server/app/api/oauth/[provider]/[action]/route.js.nft.json +1 -1
  167. package/app/.next-cli-build/server/app/api/oauth/codex/bulk-import/route.js.nft.json +1 -1
  168. package/app/.next-cli-build/server/app/api/oauth/codex/import-token/route.js.nft.json +1 -1
  169. package/app/.next-cli-build/server/app/api/oauth/cursor/auto-import/route.js.nft.json +1 -1
  170. package/app/.next-cli-build/server/app/api/oauth/cursor/import/route.js.nft.json +1 -1
  171. package/app/.next-cli-build/server/app/api/oauth/gitlab/pat/route.js.nft.json +1 -1
  172. package/app/.next-cli-build/server/app/api/oauth/iflow/cookie/route.js.nft.json +1 -1
  173. package/app/.next-cli-build/server/app/api/oauth/kiro/api-key/route.js.nft.json +1 -1
  174. package/app/.next-cli-build/server/app/api/oauth/kiro/auto-import/route.js.nft.json +1 -1
  175. package/app/.next-cli-build/server/app/api/oauth/kiro/import/route.js.nft.json +1 -1
  176. package/app/.next-cli-build/server/app/api/oauth/kiro/import-cli-proxy/route.js.nft.json +1 -1
  177. package/app/.next-cli-build/server/app/api/oauth/kiro/social-authorize/route.js.nft.json +1 -1
  178. package/app/.next-cli-build/server/app/api/oauth/kiro/social-exchange/route.js.nft.json +1 -1
  179. package/app/.next-cli-build/server/app/api/pricing/defaults/route.js.nft.json +1 -1
  180. package/app/.next-cli-build/server/app/api/pricing/route.js.nft.json +1 -1
  181. package/app/.next-cli-build/server/app/api/provider-nodes/[id]/route.js.nft.json +1 -1
  182. package/app/.next-cli-build/server/app/api/provider-nodes/route.js.nft.json +1 -1
  183. package/app/.next-cli-build/server/app/api/provider-nodes/validate/route.js.nft.json +1 -1
  184. package/app/.next-cli-build/server/app/api/providers/[id]/model-probes/batch/route.js.nft.json +1 -1
  185. package/app/.next-cli-build/server/app/api/providers/[id]/model-probes/cache/route.js.nft.json +1 -1
  186. package/app/.next-cli-build/server/app/api/providers/[id]/model-probes/prepare/route.js.nft.json +1 -1
  187. package/app/.next-cli-build/server/app/api/providers/[id]/model-probes/remove-unavailable/route.js.nft.json +1 -1
  188. package/app/.next-cli-build/server/app/api/providers/[id]/model-probes/route.js.nft.json +1 -1
  189. package/app/.next-cli-build/server/app/api/providers/[id]/model-probes/verify/cancel/route.js.nft.json +1 -1
  190. package/app/.next-cli-build/server/app/api/providers/[id]/model-probes/verify/start/route.js.nft.json +1 -1
  191. package/app/.next-cli-build/server/app/api/providers/[id]/model-probes/verify/status/route.js.nft.json +1 -1
  192. package/app/.next-cli-build/server/app/api/providers/[id]/models/route.js +1 -1
  193. package/app/.next-cli-build/server/app/api/providers/[id]/models/route.js.nft.json +1 -1
  194. package/app/.next-cli-build/server/app/api/providers/[id]/route.js.nft.json +1 -1
  195. package/app/.next-cli-build/server/app/api/providers/[id]/test/route.js.nft.json +1 -1
  196. package/app/.next-cli-build/server/app/api/providers/[id]/test-models/route.js.nft.json +1 -1
  197. package/app/.next-cli-build/server/app/api/providers/client/route.js.nft.json +1 -1
  198. package/app/.next-cli-build/server/app/api/providers/kilo/free-models/route.js.nft.json +1 -1
  199. package/app/.next-cli-build/server/app/api/providers/route.js.nft.json +1 -1
  200. package/app/.next-cli-build/server/app/api/providers/suggested-models/route.js.nft.json +1 -1
  201. package/app/.next-cli-build/server/app/api/providers/test-batch/route.js.nft.json +1 -1
  202. package/app/.next-cli-build/server/app/api/providers/validate/route.js.nft.json +1 -1
  203. package/app/.next-cli-build/server/app/api/pxpipe/health/route.js.nft.json +1 -1
  204. package/app/.next-cli-build/server/app/api/pxpipe/install/route.js.nft.json +1 -1
  205. package/app/.next-cli-build/server/app/api/pxpipe/logs/route.js.nft.json +1 -1
  206. package/app/.next-cli-build/server/app/api/pxpipe/restart/route.js.nft.json +1 -1
  207. package/app/.next-cli-build/server/app/api/pxpipe/start/route.js.nft.json +1 -1
  208. package/app/.next-cli-build/server/app/api/pxpipe/stats/route.js.nft.json +1 -1
  209. package/app/.next-cli-build/server/app/api/pxpipe/status/route.js.nft.json +1 -1
  210. package/app/.next-cli-build/server/app/api/pxpipe/stop/route.js.nft.json +1 -1
  211. package/app/.next-cli-build/server/app/api/routing/feedback/route.js.nft.json +1 -1
  212. package/app/.next-cli-build/server/app/api/routing/insights/route.js.nft.json +1 -1
  213. package/app/.next-cli-build/server/app/api/routing/learn/route.js.nft.json +1 -1
  214. package/app/.next-cli-build/server/app/api/routing/stats/route.js.nft.json +1 -1
  215. package/app/.next-cli-build/server/app/api/routing/versions/promote/route.js.nft.json +1 -1
  216. package/app/.next-cli-build/server/app/api/routing/versions/rollback/route.js.nft.json +1 -1
  217. package/app/.next-cli-build/server/app/api/settings/database/route.js.nft.json +1 -1
  218. package/app/.next-cli-build/server/app/api/settings/proxy-test/route.js.nft.json +1 -1
  219. package/app/.next-cli-build/server/app/api/settings/route.js.nft.json +1 -1
  220. package/app/.next-cli-build/server/app/api/shutdown/route.js.nft.json +1 -1
  221. package/app/.next-cli-build/server/app/api/skills/[id]/route.js.nft.json +1 -1
  222. package/app/.next-cli-build/server/app/api/tags/route.js.nft.json +1 -1
  223. package/app/.next-cli-build/server/app/api/token-saver/vault-stats/route.js.nft.json +1 -1
  224. package/app/.next-cli-build/server/app/api/translator/console-logs/route.js.nft.json +1 -1
  225. package/app/.next-cli-build/server/app/api/translator/console-logs/stream/route.js.nft.json +1 -1
  226. package/app/.next-cli-build/server/app/api/translator/load/route.js.nft.json +1 -1
  227. package/app/.next-cli-build/server/app/api/translator/save/route.js.nft.json +1 -1
  228. package/app/.next-cli-build/server/app/api/translator/send/route.js.nft.json +1 -1
  229. package/app/.next-cli-build/server/app/api/translator/translate/route.js.nft.json +1 -1
  230. package/app/.next-cli-build/server/app/api/usage/[connectionId]/codex-reset-credits/route.js.nft.json +1 -1
  231. package/app/.next-cli-build/server/app/api/usage/[connectionId]/route.js.nft.json +1 -1
  232. package/app/.next-cli-build/server/app/api/usage/chart/route.js.nft.json +1 -1
  233. package/app/.next-cli-build/server/app/api/usage/history/route.js.nft.json +1 -1
  234. package/app/.next-cli-build/server/app/api/usage/logs/route.js.nft.json +1 -1
  235. package/app/.next-cli-build/server/app/api/usage/providers/route.js.nft.json +1 -1
  236. package/app/.next-cli-build/server/app/api/usage/request-details/[id]/route.js.nft.json +1 -1
  237. package/app/.next-cli-build/server/app/api/usage/request-details/route.js.nft.json +1 -1
  238. package/app/.next-cli-build/server/app/api/usage/request-logs/route.js.nft.json +1 -1
  239. package/app/.next-cli-build/server/app/api/usage/stats/route.js.nft.json +1 -1
  240. package/app/.next-cli-build/server/app/api/usage/stream/route.js.nft.json +1 -1
  241. package/app/.next-cli-build/server/app/api/v1/api/chat/route.js.nft.json +1 -1
  242. package/app/.next-cli-build/server/app/api/v1/audio/speech/route.js.nft.json +1 -1
  243. package/app/.next-cli-build/server/app/api/v1/audio/transcriptions/route.js.nft.json +1 -1
  244. package/app/.next-cli-build/server/app/api/v1/audio/voices/route.js.nft.json +1 -1
  245. package/app/.next-cli-build/server/app/api/v1/chat/completions/route.js.nft.json +1 -1
  246. package/app/.next-cli-build/server/app/api/v1/embeddings/route.js.nft.json +1 -1
  247. package/app/.next-cli-build/server/app/api/v1/images/generations/route.js.nft.json +1 -1
  248. package/app/.next-cli-build/server/app/api/v1/messages/count_tokens/route.js.nft.json +1 -1
  249. package/app/.next-cli-build/server/app/api/v1/messages/route.js.nft.json +1 -1
  250. package/app/.next-cli-build/server/app/api/v1/models/[kind]/route.js +1 -1
  251. package/app/.next-cli-build/server/app/api/v1/models/[kind]/route.js.nft.json +1 -1
  252. package/app/.next-cli-build/server/app/api/v1/models/info/route.js +1 -1
  253. package/app/.next-cli-build/server/app/api/v1/models/info/route.js.nft.json +1 -1
  254. package/app/.next-cli-build/server/app/api/v1/models/route.js +1 -1
  255. package/app/.next-cli-build/server/app/api/v1/models/route.js.nft.json +1 -1
  256. package/app/.next-cli-build/server/app/api/v1/responses/compact/route.js.nft.json +1 -1
  257. package/app/.next-cli-build/server/app/api/v1/responses/route.js.nft.json +1 -1
  258. package/app/.next-cli-build/server/app/api/v1/route.js +1 -1
  259. package/app/.next-cli-build/server/app/api/v1/route.js.nft.json +1 -1
  260. package/app/.next-cli-build/server/app/api/v1/search/route.js.nft.json +1 -1
  261. package/app/.next-cli-build/server/app/api/v1/videos/[id]/route.js.nft.json +1 -1
  262. package/app/.next-cli-build/server/app/api/v1/videos/edits/route.js.nft.json +1 -1
  263. package/app/.next-cli-build/server/app/api/v1/videos/extensions/route.js.nft.json +1 -1
  264. package/app/.next-cli-build/server/app/api/v1/videos/generations/route.js.nft.json +1 -1
  265. package/app/.next-cli-build/server/app/api/v1/web/fetch/route.js.nft.json +1 -1
  266. package/app/.next-cli-build/server/app/api/v1beta/models/[...path]/route.js.nft.json +1 -1
  267. package/app/.next-cli-build/server/app/api/v1beta/models/route.js +1 -1
  268. package/app/.next-cli-build/server/app/api/v1beta/models/route.js.nft.json +1 -1
  269. package/app/.next-cli-build/server/app/api/version/route.js +1 -1
  270. package/app/.next-cli-build/server/app/api/version/route.js.nft.json +1 -1
  271. package/app/.next-cli-build/server/app/api/version/shutdown/route.js.nft.json +1 -1
  272. package/app/.next-cli-build/server/app/api/version/update/route.js.nft.json +1 -1
  273. package/app/.next-cli-build/server/app/callback/page.js.nft.json +1 -1
  274. package/app/.next-cli-build/server/app/callback/page_client-reference-manifest.js +1 -1
  275. package/app/.next-cli-build/server/app/callback.html +1 -1
  276. package/app/.next-cli-build/server/app/callback.rsc +3 -3
  277. package/app/.next-cli-build/server/app/callback.segments/_full.segment.rsc +3 -3
  278. package/app/.next-cli-build/server/app/callback.segments/_tree.segment.rsc +1 -1
  279. package/app/.next-cli-build/server/app/callback.segments/callback/__PAGE__.segment.rsc +3 -3
  280. package/app/.next-cli-build/server/app/dashboard/settings/pricing/page.js.nft.json +1 -1
  281. package/app/.next-cli-build/server/app/dashboard/settings/pricing/page_client-reference-manifest.js +1 -1
  282. package/app/.next-cli-build/server/app/dashboard/settings/pricing.html +1 -1
  283. package/app/.next-cli-build/server/app/dashboard/settings/pricing.rsc +3 -3
  284. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_full.segment.rsc +3 -3
  285. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_tree.segment.rsc +1 -1
  286. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/dashboard/settings/pricing/__PAGE__.segment.rsc +3 -3
  287. package/app/.next-cli-build/server/app/favicon.ico/route.js.nft.json +1 -1
  288. package/app/.next-cli-build/server/app/index.html +1 -1
  289. package/app/.next-cli-build/server/app/index.rsc +3 -3
  290. package/app/.next-cli-build/server/app/index.segments/__PAGE__.segment.rsc +3 -3
  291. package/app/.next-cli-build/server/app/index.segments/_full.segment.rsc +3 -3
  292. package/app/.next-cli-build/server/app/index.segments/_tree.segment.rsc +1 -1
  293. package/app/.next-cli-build/server/app/landing/page.js.nft.json +1 -1
  294. package/app/.next-cli-build/server/app/landing/page_client-reference-manifest.js +1 -1
  295. package/app/.next-cli-build/server/app/landing.html +1 -1
  296. package/app/.next-cli-build/server/app/landing.rsc +3 -3
  297. package/app/.next-cli-build/server/app/landing.segments/_full.segment.rsc +3 -3
  298. package/app/.next-cli-build/server/app/landing.segments/_tree.segment.rsc +1 -1
  299. package/app/.next-cli-build/server/app/landing.segments/landing/__PAGE__.segment.rsc +3 -3
  300. package/app/.next-cli-build/server/app/login/page.js.nft.json +1 -1
  301. package/app/.next-cli-build/server/app/login/page_client-reference-manifest.js +1 -1
  302. package/app/.next-cli-build/server/app/login.html +1 -1
  303. package/app/.next-cli-build/server/app/login.rsc +4 -4
  304. package/app/.next-cli-build/server/app/login.segments/_full.segment.rsc +4 -4
  305. package/app/.next-cli-build/server/app/login.segments/_tree.segment.rsc +1 -1
  306. package/app/.next-cli-build/server/app/login.segments/login/__PAGE__.segment.rsc +4 -4
  307. package/app/.next-cli-build/server/app/manifest.webmanifest/route.js.nft.json +1 -1
  308. package/app/.next-cli-build/server/app/page.js.nft.json +1 -1
  309. package/app/.next-cli-build/server/app/page_client-reference-manifest.js +1 -1
  310. package/app/.next-cli-build/server/app-paths-manifest.json +11 -11
  311. package/app/.next-cli-build/server/chunks/1350.js +1 -1
  312. package/app/.next-cli-build/server/chunks/2847.js +1 -1
  313. package/app/.next-cli-build/server/chunks/5873.js +1 -0
  314. package/app/.next-cli-build/server/chunks/6328.js +1 -1
  315. package/app/.next-cli-build/server/chunks/8255.js +1 -0
  316. package/app/.next-cli-build/server/chunks/8400.js +2 -2
  317. package/app/.next-cli-build/server/chunks/869.js +1 -1
  318. package/app/.next-cli-build/server/chunks/8789.js +1 -1
  319. package/app/.next-cli-build/server/chunks/8998.js +4 -4
  320. package/app/.next-cli-build/server/middleware-build-manifest.js +1 -1
  321. package/app/.next-cli-build/server/middleware.js +3 -3
  322. package/app/.next-cli-build/server/pages/404.html +1 -1
  323. package/app/.next-cli-build/server/pages/500.html +1 -1
  324. package/app/.next-cli-build/server/server-reference-manifest.js +1 -1
  325. package/app/.next-cli-build/server/server-reference-manifest.json +1 -1
  326. package/app/{.next/static/chunks/1321-fed8b28775abdff1.js → .next-cli-build/static/chunks/1321-648c1dd2b30b0477.js} +1 -1
  327. package/app/open-sse/identity/tls/bin/darwin/arm64/switchboard-claude-tls +0 -0
  328. package/app/open-sse/identity/tls/bin/darwin/x64/switchboard-claude-tls +0 -0
  329. package/app/open-sse/identity/tls/bin/linux/arm64/switchboard-claude-tls +0 -0
  330. package/app/open-sse/identity/tls/bin/linux/x64/switchboard-claude-tls +0 -0
  331. package/app/open-sse/identity/tls/bin/win32/arm64/switchboard-claude-tls.exe +0 -0
  332. package/app/open-sse/identity/tls/bin/win32/x64/switchboard-claude-tls.exe +0 -0
  333. package/app/package.json +1 -1
  334. package/package.json +1 -1
  335. package/app/.next-cli-build/server/chunks/3446.js +0 -1
  336. package/app/.next-cli-build/server/chunks/5139.js +0 -1
  337. /package/app/.next/static/{d_kgkyLFc009hkiluta7E → rnVU8G8NE7SuV3Xfm2epX}/_buildManifest.js +0 -0
  338. /package/app/.next/static/{d_kgkyLFc009hkiluta7E → rnVU8G8NE7SuV3Xfm2epX}/_ssgManifest.js +0 -0
  339. /package/app/.next-cli-build/static/{d_kgkyLFc009hkiluta7E → rnVU8G8NE7SuV3Xfm2epX}/_buildManifest.js +0 -0
  340. /package/app/.next-cli-build/static/{d_kgkyLFc009hkiluta7E → rnVU8G8NE7SuV3Xfm2epX}/_ssgManifest.js +0 -0
@@ -1 +1 @@
1
- "use strict";exports.id=8789,exports.ids=[8789],exports.modules={12407:(a,b,c)=>{c.d(b,{$s:()=>r,E5:()=>i,GU:()=>m,Hr:()=>o,Kx:()=>l,M8:()=>q,f8:()=>p,oC:()=>g,ox:()=>j,p3:()=>n,qd:()=>f,sZ:()=>k,uw:()=>h});let d=async()=>{},e={getSettings:async()=>({}),loadProviderQuotaState:null,saveProviderQuotaState:null,trackPendingRequest:()=>{},appendRequestLog:d,saveRequestDetail:d,saveRequestUsage:d,getRoutingEvents:async()=>[],getClusterWorkerStats:async()=>({}),getPromotedLearningVersion:async()=>null,createLearningVersion:d,countRoutingEvents:async()=>0,listCombosWithRoutingEvents:async()=>[],getLastScheduledLearnAt:async()=>null,getClusterLatencyP50:async()=>null,getComboModels:async()=>null,putVaultEntry:async()=>!1,searchVault:async()=>[],getVaultEntry:async()=>null,cleanupExpiredVault:async()=>0,buildExternalIdpRefreshParams:null,createXaiService:null,fetchKiroProfileArn:null};function f(a={}){return e={...e,...a}}function g(){return e}function h(...a){return e.trackPendingRequest?.(...a)}function i(...a){return e.appendRequestLog?.(...a)??Promise.resolve()}function j(...a){return e.saveRequestDetail?.(...a)??Promise.resolve()}function k(...a){return e.saveRequestUsage?.(...a)??Promise.resolve()}async function l(...a){return e.getRoutingEvents(...a)}async function m(...a){return e.getClusterWorkerStats(...a)}async function n(...a){return e.getPromotedLearningVersion(...a)}async function o(...a){return e.createLearningVersion(...a)}async function p(...a){return e.countRoutingEvents(...a)}async function q(...a){return!!e.putVaultEntry&&e.putVaultEntry(...a)}async function r(...a){return e.searchVault?e.searchVault(...a):[]}},18129:(a,b,c)=>{c.d(b,{Hf:()=>o,Jj:()=>q,MF:()=>v,Vq:()=>w,fp:()=>t,hJ:()=>u});var d=c(16698),e=c(77598),f=c(60290),g=c(41029),h=c(45350);let i=h.sr.codex?.maxRefreshAgeMs,j=new Map,k=new Map,l=new d.AsyncLocalStorage,m=new WeakMap,n=new WeakMap;function o(a){return m.get(a)||a?.providerSpecificData||{}}function p(a){return{accessToken:a?.accessToken,refreshToken:a?.refreshToken,idToken:a?.idToken,copilotToken:a?.copilotToken??a?.providerSpecificData?.copilotToken}}function q(a,b){let c=n.get(b);if(c&&(c.source.connectionId||c.source.id)===a)return c;let d=p(b),e=Object.keys(d).filter(a=>d[a]);if(0===e.length)return null;for(let b of[...k.values()].reverse()){if((b.source.connectionId||b.source.id)!==a)continue;let c={...p(b.source),...Object.fromEntries(Object.entries(p(b.result)).filter(([,a])=>a))};if(e.every(a=>c[a]===d[a]))return b}return null}function r(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 s(a){return r(a?.expiresAt??a?.tokenExpiresAt)}function t(a,b,c=Date.now()){if(!b)return!1;let d=s(b);if(null!==d&&d-c<(0,g.Og)(a))return!0;let e=h.sr[a]?.maxRefreshAgeMs;return!!(e&&b.refreshToken&&function(a,b=Date.now(),c=i){let d=r(a?.lastRefreshAt??a?.lastRefresh??a?.providerSpecificData?.lastRefreshAt);return!d||b-d>=c}(b,c,e))}function u(a,b,c,d=Date.now()){var e,f;if(!c)return null;if((0,g.jT)(c))return c;let i={},j=new Date(d).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,d)):c.expiresAt&&(i.expiresAt=c.expiresAt),c.projectId&&(i.projectId=c.projectId),c.providerSpecificData&&(e=b?.providerSpecificData,i.providerSpecificData=(f=c.providerSpecificData)&&"object"==typeof f?{...e||{},...f}:e),c.copilotToken&&(i.copilotToken=c.copilotToken),c.copilotTokenExpiresAt&&(i.copilotTokenExpiresAt=c.copilotTokenExpiresAt),(h.sr[a]?.trackRefreshAt||i.accessToken||i.apiKey||i.token||i.refreshToken||i.copilotToken)&&(i.lastRefreshAt=c.lastRefreshAt||j),m.set(i,c.providerSpecificData||{}),i}async function v(a,b,c){let d,g,h,i=(d=[b?.accessToken,b?.refreshToken,b?.idToken,b?.copilotToken??b?.providerSpecificData?.copilotToken],g=(0,e.createHash)("sha256").update(JSON.stringify(d)).digest("hex"),`${h=b?.connectionId||b?.id||b?.email||b?.name||b?.refreshToken?.slice?.(-16)||"default",`${a}:${h}`}:${g}`);if(l.getStore()===i)return c();let q=j.get(i);if(q)return q;let r=k.get(i);if(r?.reusable){let a;return a=r.result,Number.isFinite(r.expiresAt)&&(a={...a,expiresAt:new Date(r.expiresAt).toISOString(),expiresIn:Math.max(0,Math.ceil((r.expiresAt-Date.now())/1e3))},m.set(a,r.providerSpecificUpdates),n.set(a,r)),a}let t={...b?._connection||{},...b,provider:a,authType:b?.authType||b?._connection?.authType||"oauth"},u=Promise.resolve().then(()=>l.run(i,c)).then(a=>{if(a&&!a.error&&Object.values(p(a)).some(Boolean)){let b={result:a,source:t,reusable:!!a&&!a.error&&(["accessToken","refreshToken","idToken"].some(b=>a[b]&&a[b]!==t?.[b])||a.copilotToken&&a.copilotToken!==(t?.copilotToken??t?.providerSpecificData?.copilotToken)),providerSpecificUpdates:Object.fromEntries(Object.entries(o(a)).filter(([a,b])=>JSON.stringify(b)!==JSON.stringify(t.providerSpecificData?.[a]))),expiresAt:s(a)??(Number.isFinite(Number(a.expiresIn))&&Number(a.expiresIn)>0?Date.now()+1e3*Number(a.expiresIn):null)};for(m.set(a,b.providerSpecificUpdates),n.set(a,b),k.delete(i),k.set(i,b);k.size>f.v1.credentialRefreshResultsMaxSize;)k.delete(k.keys().next().value)}return a}).finally(()=>{j.delete(i)});return j.set(i,u),u}async function w(a,b,c,d=null){return b?v(a,b,async()=>{let e=await (0,g.$B)(a,b,c,d);return u(a,b,e)}):null}},28730:(a,b,c)=>{c.d(b,{$V:()=>v,Cn:()=>l,Co:()=>u,Ic:()=>s,J5:()=>q,NA:()=>x,QH:()=>o,VK:()=>y,Wu:()=>w,fC:()=>m,go:()=>i,nZ:()=>r,qk:()=>n,sX:()=>j,uR:()=>p,zv:()=>t});var d=c(21820),e=c(4630),f=c(35570);function g(){try{return(0,f.zi)("gemini-cli")||null}catch{return null}}let h=e.xq["gemini-cli"]?.cliVersion||g()?.version||"0.56.0",i=e.xq["gemini-cli"]?.apiClient||g()?.apiClient||"google-genai-sdk/1.41.0 gl-node/v22.19.0";function j(a="unknown"){let b,c=g()?.version||h;return`GeminiCLI/${c}/${a||"unknown"} (${(0,d.platform)()}; ${"ia32"===(b=(0,d.arch)())?"x86":b}; terminal)`}function k(){let a=(0,d.platform)(),b=(0,d.arch)();return"darwin"===a?"arm64"===b?2:1:"linux"===a?"arm64"===b?4:3:5*("win32"===a)}let l={ideType:9,platform:k(),pluginType:2},m=Object.freeze(["authorization","x-api-key","x-goog-api-key","x-switchboard-key","cookie","token","set-cookie","session-id","session_id","x-session-id","x-amp-thread-id","x-client-request-id"]),n=Object.freeze(["authorization","x-switchboard-key","x-api-key","x-goog-api-key","session-id","session_id","x-session-id","x-amp-thread-id","x-client-request-id"]),o="_ide",p="_ide",q=new Set(["browser_subagent","command_status","find_by_name","generate_image","grep_search","list_dir","list_resources","multi_replace_file_content","notify_user","read_resource","read_terminal","read_url_content","replace_file_content","run_command","search_web","send_command_input","task_boundary","view_content_chunk","view_file","write_to_file"]),r={loadCodeAssist:"https://cloudcode-pa.googleapis.com/v1internal:loadCodeAssist",onboardUser:"https://cloudcode-pa.googleapis.com/v1internal:onboardUser"},s={"Content-Type":"application/json","User-Agent":"google-api-nodejs-client/9.15.1","X-Goog-Api-Client":"google-cloud-sdk vscode_cloudshelleditor/0.1","Client-Metadata":JSON.stringify({ideType:9,platform:k(),pluginType:2})},t={ideType:9,platform:k(),pluginType:2},u="You are Claude Code, Anthropic's official CLI for Claude.",v="You are Antigravity, a powerful agentic AI coding assistant designed by the Google Deepmind team working on Advanced Agentic Coding.You are pair programming with a USER to solve their coding task. The task may require creating a new codebase, modifying or debugging an existing codebase, or simply answering a question.**Absolute paths only****Proactiveness**",w=Object.fromEntries(Object.entries(e.sr).filter(([,a])=>a.refreshLeadMs).map(([a,b])=>[a,b.refreshLeadMs])),x={google:{token:"https://oauth2.googleapis.com/token",auth:"https://accounts.google.com/o/oauth2/auth"},openai:{token:e.sr.codex?.tokenUrl,auth:e.sr.codex?.authorizeUrl},anthropic:{token:e.sr.claude?.tokenUrl,auth:"https://api.anthropic.com/v1/oauth/authorize"},qwen:{token:e.sr.qwen?.tokenUrl,auth:e.sr.qwen?.deviceCodeUrl},iflow:{token:e.sr.iflow?.tokenUrl,auth:e.sr.iflow?.authorizeUrl},github:{token:e.sr.github?.tokenUrl,auth:e.sr.github?.authorizeUrl,deviceCode:e.sr.github?.deviceCodeUrl}};function y(a){let b="string"==typeof a&&a.trim()?a.trim():`kimi-${Date.now()}`;return{"X-Msh-Platform":"switchboard","X-Msh-Version":"2.1.2","X-Msh-Device-Model":"u">typeof process?`${process.platform} ${process.arch}`:"unknown","X-Msh-Device-Id":b}}},41029:(a,b,c)=>{c.d(b,{oD:()=>C,Og:()=>E,jT:()=>D,Sc:()=>F,jR:()=>A,I9:()=>s,AH:()=>y,Ql:()=>x,$B:()=>L,pb:()=>H,qZ:()=>M});var d=c(4630),e=c(28730),f=c(46052);let g=new Map;function h(){for(;g.size>256;){let a=g.keys().next().value;if(void 0===a)break;let b=g.get(a);g.delete(a),b?.cleanupTimer&&clearTimeout(b.cleanupTimer)}}function i(a,b){g.get(a)===b&&(g.delete(a),b.cleanupTimer&&clearTimeout(b.cleanupTimer))}async function j(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;i(e,f)}let j={promise:null},k=(async()=>{try{let a=await c();if(a&&(a.accessToken||a.copilotToken||a.refreshToken)){let b;(b={result:a,expiresAt:Date.now()+1e4,cleanupTimer:null}).cleanupTimer=setTimeout(()=>{g.get(e)===b&&(g.delete(e),b.cleanupTimer=null)},1e4),b.cleanupTimer.unref?.(),g.set(e,b),h()}else i(e,j);return a}catch(a){throw i(e,j),a}})();return j.promise=k,g.set(e,j),h(),k}var k=c(12407),l=c(57034);function m(a,b,c,d){let e=u(c,d);return e.permanent?(a?.error?.("TOKEN_REFRESH",`${b} refresh token revoked or expired. Re-auth required.`,{status:d,code:e.code}),{error:"unrecoverable_refresh_error",code:e.code}):null}function n(a="",b=0){let c="";try{let b=a?JSON.parse(a):null;c=b?.error||b?.error_code||b?.code||""}catch{}return{status:b,errorCode:c||void 0,bodyLen:a?.length||0}}let o=null;async function p(a,b){return a?j("xai",a,async()=>{try{if(!o){let a=(0,k.oC)().createXaiService;if(!a)return b?.warn?.("TOKEN_REFRESH","xAI service not wired (setOpenSseDeps)"),null;o=await a()}let c=await o.refreshAccessToken(a);return{accessToken:c.access_token,refreshToken:c.refresh_token||a,expiresIn:c.expires_in,idToken:c.id_token}}catch(d){let a=String(d?.message||""),c=a.includes("invalid_grant")?"invalid_grant":a.includes("invalid_request")?"invalid_request":null;if(b?.warn?.("TOKEN_REFRESH","xai refresh failed",c?{errorCode:c}:void 0),c)return{error:c};return null}},b):null}async function q(a,b,c,e,g=null){let h=d.xq[a],i=h?.refreshUrl||d.sr[a]?.refreshUrl||d.sr[a]?.tokenUrl;return h&&i?b?j(a,b,async()=>{try{let c=new URLSearchParams({grant_type:"refresh_token",refresh_token:b,client_id:h.clientId});h.clientSecret&&c.set("client_secret",h.clientSecret);let d=await (0,f.Fm)(i,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded",Accept:"application/json"},body:c,identity:h.identity,provider:a,format:h.format},g);if(!d.ok){let b=await d.text(),c=m(e,a,b,d.status);if(c)return c;return e?.error?.("TOKEN_REFRESH",`Failed to refresh token for ${a}`,{status:d.status,error:n(b,d.status)}),null}let j=await d.json();return e?.info?.("TOKEN_REFRESH",`Successfully refreshed token for ${a}`,{hasNewAccessToken:!!j.access_token,hasNewRefreshToken:!!j.refresh_token,expiresIn:j.expires_in}),{accessToken:j.access_token,refreshToken:j.refresh_token||b,expiresIn:j.expires_in}}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 r(a,b){return a?j("claude",a,async()=>{try{let c=await (0,f.Fm)(e.NA.anthropic.token,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({grant_type:"refresh_token",refresh_token:a,client_id:d.xq.claude.clientId}),identity:d.xq.claude?.identity,provider:"claude",format:d.xq.claude?.format});if(!c.ok){let a=await c.text(),d=m(b,"Claude",a,c.status);if(d)return d;return b?.error?.("TOKEN_REFRESH","Failed to refresh Claude OAuth token",{status:c.status,error:n(a,c.status)}),null}let g=await c.json();return b?.info?.("TOKEN_REFRESH","Successfully refreshed Claude OAuth 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 b?.error?.("TOKEN_REFRESH",`Network error refreshing Claude token: ${a.message}`),null}},b):null}async function s(a,b,c,g,h=null,i=null){if(!a)return null;let k=h||(b===d.xq.antigravity?.clientId?"antigravity":"gemini-cli"),l=d.xq[k];return j(`google:${b}`,a,async()=>{try{let d=await (0,f.Fm)(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}),identity:l?.identity,provider:k,format:l?.format},i);if(!d.ok){let a=await d.text(),b=m(g,"Google",a,d.status);if(b)return b;return g?.error?.("TOKEN_REFRESH","Failed to refresh Google token",{status:d.status,error:n(a,d.status)}),null}let h=await d.json();return g?.info?.("TOKEN_REFRESH","Successfully refreshed Google token",{hasNewAccessToken:!!h.access_token,expiresIn:h.expires_in}),{accessToken:h.access_token,refreshToken:h.refresh_token||a,expiresIn:h.expires_in}}catch(a){return g?.error?.("TOKEN_REFRESH",`Network error refreshing Google token: ${a.message}`),null}},g)}async function t(a,b){return a?j("qwen",a,async()=>{let c=e.NA.qwen.token;try{let e=await (0,f.Fm)(c,{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:d.xq.qwen.clientId}),identity:d.xq.qwen?.identity,provider:"qwen",format:d.xq.qwen?.format});if(200===e.status){let c=await e.json();return b?.info?.("TOKEN_REFRESH","Successfully refreshed Qwen token",{hasNewAccessToken:!!c.access_token,hasNewRefreshToken:!!c.refresh_token,expiresIn:c.expires_in}),{accessToken:c.access_token,refreshToken:c.refresh_token||a,expiresIn:c.expires_in,providerSpecificData:c.resource_url?{resourceUrl:c.resource_url}:void 0}}{let a=await e.text().catch(()=>""),c=m(b,"Qwen",a,e.status);if(c)return c;b?.warn?.("TOKEN_REFRESH","Error with Qwen endpoint",{status:e.status,error:n(a,e.status)})}}catch(a){b?.warn?.("TOKEN_REFRESH","Network error trying Qwen endpoint",{error:a.message})}return b?.error?.("TOKEN_REFRESH","Failed to refresh Qwen token"),null},b):null}function u(a="",b=0){let c=null;try{c=a?JSON.parse(a):null}catch{c=null}let d=c?.error,e=("string"==typeof d?d:d?.code||d?.type)||c?.error_code||"",f=c?.error_description||c?.message||d?.message||a||"",g=`${e} ${f}`.toLowerCase(),h=b<500&&["refresh_token_expired","refresh_token_reused","refresh_token_invalidated","invalid_grant","bad_refresh_token"].some(a=>g.includes(a));return{status:b,code:e,description:f,permanent:h}}async function v(a,b){return a?j("codex",a,async()=>{try{let c=await (0,f.Fm)(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}),identity:d.xq.codex?.identity,provider:"codex",format:d.xq.codex?.format});if(!c.ok){let a=await c.text(),d=u(a,c.status);if(d.permanent)return b?.error?.("TOKEN_REFRESH","Codex refresh token already used or invalid. Re-auth required.",{status:c.status,code:d.code}),{error:"unrecoverable_refresh_error",code:d.code};return b?.error?.("TOKEN_REFRESH","Failed to refresh Codex token",{status:c.status,error:n(a,c.status),code:d.code,permanent:d.permanent}),null}let g=await c.json();return b?.info?.("TOKEN_REFRESH","Successfully refreshed Codex token",{hasNewAccessToken:!!g.access_token,hasNewRefreshToken:!!g.refresh_token,hasIdToken:!!g.id_token,expiresIn:g.expires_in}),{accessToken:g.access_token,refreshToken:g.refresh_token||a,idToken:g.id_token,expiresIn:g.expires_in}}catch(a){return b?.error?.("TOKEN_REFRESH",`Network error refreshing Codex token: ${a.message}`),null}},b):null}async function w(a,b,c){if(a?.profileArn)return{};let d=c?.trim?.()||null;if(!d){let c=(0,k.oC)().fetchKiroProfileArn;c&&(d=await c(b,a?.region))}return d?{providerSpecificData:{profileArn:d}}:{}}async function x(a,b,c,e=null){return a?j("kiro",a,async()=>{let g=b?.authMethod,h=b?.clientId,i=b?.clientSecret,j=b?.region;if("external_idp"===g){let g;try{let c=(0,k.oC)().buildExternalIdpRefreshParams;if(!c)throw Error("buildExternalIdpRefreshParams not wired");g=await c(a,b)}catch(a){return c?.warn?.("TOKEN_REFRESH",`Invalid Kiro external_idp refresh config: ${a.message}`),null}let h=await (0,f.Fm)(g.tokenEndpoint,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded",Accept:"application/json"},body:g.body,identity:d.xq.kiro?.identity,provider:"kiro",format:d.xq.kiro?.format},e);if(!h.ok){let a=await h.text();return c?.error?.("TOKEN_REFRESH","Failed to refresh Kiro external_idp token",{status:h.status,error:n(a,h.status)}),null}let i=await h.json();return c?.info?.("TOKEN_REFRESH","Successfully refreshed Kiro external_idp token",{hasNewAccessToken:!!i.access_token,hasNewRefreshToken:!!i.refresh_token,expiresIn:i.expires_in}),{accessToken:i.access_token,refreshToken:i.refresh_token||a,expiresIn:i.expires_in,providerSpecificData:g.providerSpecificData}}if(h&&i){let k="idc"===g&&(0,l.i7)(j)?`https://oidc.${j}.amazonaws.com/token`:"https://oidc.us-east-1.amazonaws.com/token",m=await (0,f.Fm)(k,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({clientId:h,clientSecret:i,refreshToken:a,grantType:"refresh_token"}),identity:d.xq.kiro?.identity,provider:"kiro",format:d.xq.kiro?.format},e);if(!m.ok){let a=await m.text();return c?.error?.("TOKEN_REFRESH","Failed to refresh Kiro AWS token",{status:m.status,error:n(a,m.status)}),null}let o=await m.json();return c?.info?.("TOKEN_REFRESH","Successfully refreshed Kiro AWS token",{hasNewAccessToken:!!o.accessToken,expiresIn:o.expiresIn}),{accessToken:o.accessToken,refreshToken:o.refreshToken||a,expiresIn:o.expiresIn,...await w(b,o.accessToken,o.profileArn)}}let m=await (0,f.Fm)(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}),identity:d.xq.kiro?.identity,provider:"kiro",format:d.xq.kiro?.format},e);if(!m.ok){let a=await m.text();return c?.error?.("TOKEN_REFRESH","Failed to refresh Kiro social token",{status:m.status,error:n(a,m.status)}),null}let o=await m.json();return c?.info?.("TOKEN_REFRESH","Successfully refreshed Kiro social token",{hasNewAccessToken:!!o.accessToken,expiresIn:o.expiresIn}),{accessToken:o.accessToken,refreshToken:o.refreshToken||a,expiresIn:o.expiresIn,...await w(b,o.accessToken,o.profileArn)}},c):null}async function y(a,b){return a?j("iflow",a,async()=>{let c=btoa(`${d.xq.iflow.clientId}:${d.xq.iflow.clientSecret}`),g=await (0,f.Fm)(e.NA.iflow.token,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded",Accept:"application/json",Authorization:`Basic ${c}`},body:new URLSearchParams({grant_type:"refresh_token",refresh_token:a,client_id:d.xq.iflow.clientId,client_secret:d.xq.iflow.clientSecret}),identity:d.xq.iflow?.identity,provider:"iflow",format:d.xq.iflow?.format});if(!g.ok){let a=await g.text(),c=m(b,"iFlow",a,g.status);return c||(b?.error?.("TOKEN_REFRESH","Failed to refresh iFlow token",{status:g.status,error:n(a,g.status)}),null)}let h=await g.json();return b?.info?.("TOKEN_REFRESH","Successfully refreshed iFlow 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}},b):null}async function z(a,b){return a?j("github",a,async()=>{let c={grant_type:"refresh_token",refresh_token:a,client_id:d.xq.github.clientId};d.xq.github.clientSecret&&(c.client_secret=d.xq.github.clientSecret);let g=await (0,f.Fm)(e.NA.github.token,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded",Accept:"application/json"},body:new URLSearchParams(c),identity:d.xq.github?.identity,provider:"github",format:d.xq.github?.format});if(!g.ok){let a=await g.text(),c=m(b,"GitHub",a,g.status);return c||(b?.error?.("TOKEN_REFRESH","Failed to refresh GitHub token",{status:g.status,error:n(a,g.status)}),null)}let h=await g.json();if(h.error||!h.access_token){let a=JSON.stringify(h),c=m(b,"GitHub",a,g.status);return c||(b?.error?.("TOKEN_REFRESH","Failed to refresh GitHub token",{status:g.status,error:n(a,g.status)}),null)}return b?.info?.("TOKEN_REFRESH","Successfully refreshed GitHub 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}},b):null}async function A(a,b){return a?j("copilot",a,async()=>{try{let c=await (0,f.Fm)(d.sr.github?.copilotTokenUrl,{headers:{Authorization:`token ${a}`,Accept:"application/json"},identity:d.xq.github?.identity,provider:"github",format:d.xq.github?.format});if(!c.ok){let a=await c.text();return b?.error?.("TOKEN_REFRESH","Failed to refresh Copilot token",{status:c.status,error:n(a,c.status)}),null}let e=await c.json();return b?.info?.("TOKEN_REFRESH","Successfully refreshed Copilot token",{hasToken:!!e.token,expiresAt:e.expires_at}),{token:e.token,expiresAt:e.expires_at}}catch(a){return b?.error?.("TOKEN_REFRESH","Error refreshing Copilot token",{error:a.message}),null}},b):null}async function B(a,b){return a?j("codebuddy-cn",a,async()=>{let c=d.sr["codebuddy-cn"]||{},e=await (0,f.Fm)(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},body:JSON.stringify({refreshToken:a}),identity:d.xq["codebuddy-cn"]?.identity,provider:"codebuddy-cn",format:d.xq["codebuddy-cn"]?.format});if(!e.ok){let a=await e.text();return b?.error?.("TOKEN_REFRESH","Failed to refresh CodeBuddy token",{status:e.status,error:n(a,e.status)}),null}let g=await e.json();return 0===g.code&&g.data?.accessToken?(b?.info?.("TOKEN_REFRESH","Successfully refreshed CodeBuddy token",{hasNewAccessToken:!!g.data.accessToken,hasNewRefreshToken:!!g.data.refreshToken,expiresIn:g.data.expiresIn}),{accessToken:g.data.accessToken,refreshToken:g.data.refreshToken||a,expiresIn:g.data.expiresIn}):(b?.error?.("TOKEN_REFRESH","CodeBuddy token refresh returned no token",{code:g.code,msg:g.msg}),null)},b):null}let C=3e5;function D(a){return a&&"object"==typeof a&&("unrecoverable_refresh_error"===a.error||"refresh_token_reused"===a.error||"invalid_request"===a.error||"invalid_grant"===a.error)}function E(a){return e.Wu[a]||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,g="vertex",h=null){let i=a.client_email,j=G.get(i);if(j&&j.expiresAt-Date.now()>3e5)return{accessToken:j.token,expiresAt:j.expiresAt};try{let{SignJWT:j,importPKCS8:k}=await c.e(9078).then(c.bind(c,9078));b?.debug?.("TOKEN_REFRESH",`Vertex minting token for ${a.client_email}`);let l=await k(a.private_key.replace(/\\n/g,"\n"),"RS256"),m=Math.floor(Date.now()/1e3),n=await new j({scope:"https://www.googleapis.com/auth/cloud-platform"}).setProtectedHeader({alg:"RS256"}).setIssuer(a.client_email).setAudience(e.NA.google.token).setIssuedAt(m).setExpirationTime(m+3600).sign(l),o=d.xq[g]||d.xq.vertex,p=await (0,f.Fm)(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:n}),identity:o.identity,provider:g,format:o.format},h);if(!p.ok){let a=await p.text();return b?.error?.("TOKEN_REFRESH",`Vertex token mint failed: ${a}`),null}let{access_token:q,expires_in:r}=await p.json(),s=Date.now()+(r??3600)*1e3;return G.set(i,{token:q,expiresAt:s}),b?.info?.("TOKEN_REFRESH",`Vertex token minted for ${a.client_email}`),{accessToken:q,expiresAt:s}}catch(a){return b?.error?.("TOKEN_REFRESH",`Vertex token error: ${a.message}`),null}}function I(a,b,c="vertex"){let d=F(a.apiKey);if(d)return H(d,b,c);try{let d="string"==typeof a.apiKey?JSON.parse(a.apiKey):null;if(d?.type==="authorized_user"&&d.refresh_token&&d.client_id&&d.client_secret)return s(d.refresh_token,d.client_id,d.client_secret,b,c)}catch{}return null}let J={"gemini-cli":(a,b)=>s(a.refreshToken,d.xq["gemini-cli"].clientId,d.xq["gemini-cli"].clientSecret,b),antigravity:(a,b)=>s(a.refreshToken,d.xq.antigravity.clientId,d.xq.antigravity.clientSecret,b),claude:(a,b)=>r(a.refreshToken,b),codex:(a,b)=>v(a.refreshToken,b),qwen:(a,b)=>t(a.refreshToken,b),iflow:(a,b)=>y(a.refreshToken,b),github:(a,b)=>z(a.refreshToken,b),kiro:(a,b)=>x(a.refreshToken,a.providerSpecificData,b),xai:(a,b)=>p(a.refreshToken,b),"grok-cli":(a,b,c)=>q("grok-cli",a.refreshToken,a,b,c),"codebuddy-cn":(a,b)=>B(a.refreshToken,b),muse:(a,b)=>K(a.providerSpecificData?.dcaToken||a.refreshToken,b),vertex:(a,b)=>I(a,b,"vertex"),"vertex-partner":(a,b)=>I(a,b,"vertex-partner")};async function K(a,b){if(!a)return null;try{let c=process.env.META_MINT_URL||"https://api.meta.ai/muse-code/key",d=await (0,f.Fm)(c,{method:"POST",headers:{Authorization:`Bearer ${a}`,"User-Agent":"muse-code/1.0.2","Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({dca_token:a}),identity:"muse-code",provider:"muse"});if(!d.ok)return b?.warn?.("TOKEN_REFRESH",`Failed to re-mint Meta Muse API key: ${d.status}`),null;let e=await d.json();return{accessToken:e.api_key,apiKey:e.api_key,providerSpecificData:{apiKey:e.api_key,baseUrl:e.base_url||"https://api.meta.ai/v1"}}}catch(a){return b?.warn?.("TOKEN_REFRESH",`Error re-minting Meta Muse API key: ${a?.message}`),null}}async function L(a,b,c,d=null){let e="vertex"===a||"vertex-partner"===a;if(!b.refreshToken&&!(e&&b?.apiKey))return null;let f=J[a];return f?f(b,c,d):q(a,b.refreshToken,b,c,d)}async function M(a,b=3,c=null,d=null){for(let e=0;e<b;e++){if(d?.throwIfAborted(),e>0){let a=1e3*e;c?.debug?.("TOKEN_REFRESH",`Retry ${e}/${b} after ${a}ms`),await new Promise(b=>{let c=()=>{clearTimeout(e),d?.removeEventListener("abort",c),b()},e=setTimeout(c,a);d?.addEventListener("abort",c,{once:!0}),d?.aborted&&c()}),d?.throwIfAborted()}try{let b=await a();if(D(b)||b)return b}catch(a){d?.throwIfAborted(),c?.warn?.("TOKEN_REFRESH",`Attempt ${e+1}/${b} failed: ${a.message}`)}}return c?.error?.("TOKEN_REFRESH",`All ${b} retry attempts failed`),null}},47293:(a,b,c)=>{c.d(b,{A:()=>f});let d=new Uint8Array(16);var e=c(50122);let f=function(a,b,c){return b||a||!crypto.randomUUID?function(a,b,c){let f=(a=a||{}).random??a.rng?.()??crypto.getRandomValues(d);if(f.length<16)throw Error("Random bytes length must be >= 16");if(f[6]=15&f[6]|64,f[8]=63&f[8]|128,b){if((c=c||0)<0||c+16>b.length)throw RangeError(`UUID byte range ${c}:${c+15} is out of buffer bounds`);for(let a=0;a<16;++a)b[c+a]=f[a];return b}return(0,e.k)(f)}(a,b,c):crypto.randomUUID()}},50122:(a,b,c)=>{c.d(b,{k:()=>e});let d=[];for(let a=0;a<256;++a)d.push((a+256).toString(16).slice(1));function e(a,b=0){return(d[a[b+0]]+d[a[b+1]]+d[a[b+2]]+d[a[b+3]]+"-"+d[a[b+4]]+d[a[b+5]]+"-"+d[a[b+6]]+d[a[b+7]]+"-"+d[a[b+8]]+d[a[b+9]]+"-"+d[a[b+10]]+d[a[b+11]]+d[a[b+12]]+d[a[b+13]]+d[a[b+14]]+d[a[b+15]]).toLowerCase()}},57034:(a,b,c)=>{c.d(b,{i7:()=>e,l6:()=>f});let d=/^[a-z]{2}(?:-[a-z0-9]+)+-\d{1,2}$/;function e(a){return"string"==typeof a&&d.test(a)}function f(a,b="us-east-1"){return e(a)?a:b}}};
1
+ "use strict";exports.id=8789,exports.ids=[8789],exports.modules={12407:(a,b,c)=>{c.d(b,{$s:()=>r,E5:()=>i,GU:()=>m,Hr:()=>o,Kx:()=>l,M8:()=>q,f8:()=>p,oC:()=>g,ox:()=>j,p3:()=>n,qd:()=>f,sZ:()=>k,uw:()=>h});let d=async()=>{},e={getSettings:async()=>({}),loadProviderQuotaState:null,saveProviderQuotaState:null,trackPendingRequest:()=>{},appendRequestLog:d,saveRequestDetail:d,saveRequestUsage:d,getRoutingEvents:async()=>[],getClusterWorkerStats:async()=>({}),getPromotedLearningVersion:async()=>null,createLearningVersion:d,countRoutingEvents:async()=>0,listCombosWithRoutingEvents:async()=>[],getLastScheduledLearnAt:async()=>null,getClusterLatencyP50:async()=>null,getComboModels:async()=>null,putVaultEntry:async()=>!1,searchVault:async()=>[],getVaultEntry:async()=>null,cleanupExpiredVault:async()=>0,buildExternalIdpRefreshParams:null,createXaiService:null,fetchKiroProfileArn:null};function f(a={}){return e={...e,...a}}function g(){return e}function h(...a){return e.trackPendingRequest?.(...a)}function i(...a){return e.appendRequestLog?.(...a)??Promise.resolve()}function j(...a){return e.saveRequestDetail?.(...a)??Promise.resolve()}function k(...a){return e.saveRequestUsage?.(...a)??Promise.resolve()}async function l(...a){return e.getRoutingEvents(...a)}async function m(...a){return e.getClusterWorkerStats(...a)}async function n(...a){return e.getPromotedLearningVersion(...a)}async function o(...a){return e.createLearningVersion(...a)}async function p(...a){return e.countRoutingEvents(...a)}async function q(...a){return!!e.putVaultEntry&&e.putVaultEntry(...a)}async function r(...a){return e.searchVault?e.searchVault(...a):[]}},18129:(a,b,c)=>{c.d(b,{Hf:()=>o,Jj:()=>q,MF:()=>v,Vq:()=>w,fp:()=>t,hJ:()=>u});var d=c(16698),e=c(77598),f=c(60290),g=c(41029),h=c(45350);let i=h.sr.codex?.maxRefreshAgeMs,{refreshLocks:j,successfulRefreshes:k,refreshContext:l,providerSpecificRefreshUpdates:m,receiptSources:n}=globalThis.__switchboardOAuthRefreshState??={refreshLocks:new Map,successfulRefreshes:new Map,refreshContext:new d.AsyncLocalStorage,providerSpecificRefreshUpdates:new WeakMap,receiptSources:new WeakMap};function o(a){return m.get(a)||a?.providerSpecificData||{}}function p(a){return{accessToken:a?.accessToken,refreshToken:a?.refreshToken,idToken:a?.idToken,copilotToken:a?.copilotToken??a?.providerSpecificData?.copilotToken}}function q(a,b){let c=n.get(b);if(c&&(c.source.connectionId||c.source.id)===a)return c;let d=p(b),e=Object.keys(d).filter(a=>d[a]);if(0===e.length)return null;for(let b of[...k.values()].reverse()){if((b.source.connectionId||b.source.id)!==a)continue;let c={...p(b.source),...Object.fromEntries(Object.entries(p(b.result)).filter(([,a])=>a))};if(e.every(a=>c[a]===d[a]))return b}return null}function r(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 s(a){return r(a?.expiresAt??a?.tokenExpiresAt)}function t(a,b,c=Date.now()){if(!b)return!1;let d=s(b);if(null!==d&&d-c<(0,g.Og)(a))return!0;let e=h.sr[a]?.maxRefreshAgeMs;return!!(e&&b.refreshToken&&function(a,b=Date.now(),c=i){let d=r(a?.lastRefreshAt??a?.lastRefresh??a?.providerSpecificData?.lastRefreshAt);return!d||b-d>=c}(b,c,e))}function u(a,b,c,d=Date.now()){var e,f;if(!c)return null;if((0,g.jT)(c))return c;let i={},j=new Date(d).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,d)):c.expiresAt&&(i.expiresAt=c.expiresAt),c.projectId&&(i.projectId=c.projectId),c.providerSpecificData&&(e=b?.providerSpecificData,i.providerSpecificData=(f=c.providerSpecificData)&&"object"==typeof f?{...e||{},...f}:e),c.copilotToken&&(i.copilotToken=c.copilotToken),c.copilotTokenExpiresAt&&(i.copilotTokenExpiresAt=c.copilotTokenExpiresAt),(h.sr[a]?.trackRefreshAt||i.accessToken||i.apiKey||i.token||i.refreshToken||i.copilotToken)&&(i.lastRefreshAt=c.lastRefreshAt||j),m.set(i,c.providerSpecificData||{}),i}async function v(a,b,c){let d,g,h,i=(d=[b?.accessToken,b?.refreshToken,b?.idToken,b?.copilotToken??b?.providerSpecificData?.copilotToken],g=(0,e.createHash)("sha256").update(JSON.stringify(d)).digest("hex"),`${h=b?.connectionId||b?.id||b?.email||b?.name||b?.refreshToken?.slice?.(-16)||"default",`${a}:${h}`}:${g}`);if(l.getStore()===i)return c();let q=j.get(i);if(q)return q;let r=k.get(i);if(r?.reusable){let a;return a=r.result,Number.isFinite(r.expiresAt)&&(a={...a,expiresAt:new Date(r.expiresAt).toISOString(),expiresIn:Math.max(0,Math.ceil((r.expiresAt-Date.now())/1e3))},m.set(a,r.providerSpecificUpdates),n.set(a,r)),a}let t={...b?._connection||{},...b,provider:a,authType:b?.authType||b?._connection?.authType||"oauth"},u=Promise.resolve().then(()=>l.run(i,c)).then(a=>{if(a&&!a.error&&Object.values(p(a)).some(Boolean)){let b={result:a,source:t,reusable:!!a&&!a.error&&(["accessToken","refreshToken","idToken"].some(b=>a[b]&&a[b]!==t?.[b])||a.copilotToken&&a.copilotToken!==(t?.copilotToken??t?.providerSpecificData?.copilotToken)),providerSpecificUpdates:Object.fromEntries(Object.entries(o(a)).filter(([a,b])=>JSON.stringify(b)!==JSON.stringify(t.providerSpecificData?.[a]))),expiresAt:s(a)??(Number.isFinite(Number(a.expiresIn))&&Number(a.expiresIn)>0?Date.now()+1e3*Number(a.expiresIn):null)};for(m.set(a,b.providerSpecificUpdates),n.set(a,b),k.delete(i),k.set(i,b);k.size>f.v1.credentialRefreshResultsMaxSize;)k.delete(k.keys().next().value)}return a}).finally(()=>{j.delete(i)});return j.set(i,u),u}async function w(a,b,c,d=null){return b?v(a,b,async()=>{let e=await (0,g.$B)(a,b,c,d);return u(a,b,e)}):null}},28730:(a,b,c)=>{c.d(b,{$V:()=>v,Cn:()=>l,Co:()=>u,Ic:()=>s,J5:()=>q,NA:()=>x,QH:()=>o,VK:()=>y,Wu:()=>w,fC:()=>m,go:()=>i,nZ:()=>r,qk:()=>n,sX:()=>j,uR:()=>p,zv:()=>t});var d=c(21820),e=c(4630),f=c(35570);function g(){try{return(0,f.zi)("gemini-cli")||null}catch{return null}}let h=e.xq["gemini-cli"]?.cliVersion||g()?.version||"0.56.0",i=e.xq["gemini-cli"]?.apiClient||g()?.apiClient||"google-genai-sdk/1.41.0 gl-node/v22.19.0";function j(a="unknown"){let b,c=g()?.version||h;return`GeminiCLI/${c}/${a||"unknown"} (${(0,d.platform)()}; ${"ia32"===(b=(0,d.arch)())?"x86":b}; terminal)`}function k(){let a=(0,d.platform)(),b=(0,d.arch)();return"darwin"===a?"arm64"===b?2:1:"linux"===a?"arm64"===b?4:3:5*("win32"===a)}let l={ideType:9,platform:k(),pluginType:2},m=Object.freeze(["authorization","x-api-key","x-goog-api-key","x-switchboard-key","cookie","token","set-cookie","session-id","session_id","x-session-id","x-amp-thread-id","x-client-request-id"]),n=Object.freeze(["authorization","x-switchboard-key","x-api-key","x-goog-api-key","session-id","session_id","x-session-id","x-amp-thread-id","x-client-request-id"]),o="_ide",p="_ide",q=new Set(["browser_subagent","command_status","find_by_name","generate_image","grep_search","list_dir","list_resources","multi_replace_file_content","notify_user","read_resource","read_terminal","read_url_content","replace_file_content","run_command","search_web","send_command_input","task_boundary","view_content_chunk","view_file","write_to_file"]),r={loadCodeAssist:"https://cloudcode-pa.googleapis.com/v1internal:loadCodeAssist",onboardUser:"https://cloudcode-pa.googleapis.com/v1internal:onboardUser"},s={"Content-Type":"application/json","User-Agent":"google-api-nodejs-client/9.15.1","X-Goog-Api-Client":"google-cloud-sdk vscode_cloudshelleditor/0.1","Client-Metadata":JSON.stringify({ideType:9,platform:k(),pluginType:2})},t={ideType:9,platform:k(),pluginType:2},u="You are Claude Code, Anthropic's official CLI for Claude.",v="You are Antigravity, a powerful agentic AI coding assistant designed by the Google Deepmind team working on Advanced Agentic Coding.You are pair programming with a USER to solve their coding task. The task may require creating a new codebase, modifying or debugging an existing codebase, or simply answering a question.**Absolute paths only****Proactiveness**",w=Object.fromEntries(Object.entries(e.sr).filter(([,a])=>a.refreshLeadMs).map(([a,b])=>[a,b.refreshLeadMs])),x={google:{token:"https://oauth2.googleapis.com/token",auth:"https://accounts.google.com/o/oauth2/auth"},openai:{token:e.sr.codex?.tokenUrl,auth:e.sr.codex?.authorizeUrl},anthropic:{token:e.sr.claude?.tokenUrl,auth:"https://api.anthropic.com/v1/oauth/authorize"},qwen:{token:e.sr.qwen?.tokenUrl,auth:e.sr.qwen?.deviceCodeUrl},iflow:{token:e.sr.iflow?.tokenUrl,auth:e.sr.iflow?.authorizeUrl},github:{token:e.sr.github?.tokenUrl,auth:e.sr.github?.authorizeUrl,deviceCode:e.sr.github?.deviceCodeUrl}};function y(a){let b="string"==typeof a&&a.trim()?a.trim():`kimi-${Date.now()}`;return{"X-Msh-Platform":"switchboard","X-Msh-Version":"2.1.2","X-Msh-Device-Model":"u">typeof process?`${process.platform} ${process.arch}`:"unknown","X-Msh-Device-Id":b}}},41029:(a,b,c)=>{c.d(b,{oD:()=>C,Og:()=>E,jT:()=>D,Sc:()=>F,jR:()=>A,I9:()=>s,AH:()=>y,Ql:()=>x,$B:()=>L,pb:()=>H,qZ:()=>M});var d=c(4630),e=c(28730),f=c(46052);let g=globalThis.__switchboardRefreshDedupCache??=new Map;function h(){for(;g.size>256;){let a=g.keys().next().value;if(void 0===a)break;let b=g.get(a);g.delete(a),b?.cleanupTimer&&clearTimeout(b.cleanupTimer)}}function i(a,b){g.get(a)===b&&(g.delete(a),b.cleanupTimer&&clearTimeout(b.cleanupTimer))}async function j(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;i(e,f)}let j={promise:null},k=(async()=>{try{let a=await c();if(a&&(a.accessToken||a.copilotToken||a.refreshToken)){let b;(b={result:a,expiresAt:Date.now()+1e4,cleanupTimer:null}).cleanupTimer=setTimeout(()=>{g.get(e)===b&&(g.delete(e),b.cleanupTimer=null)},1e4),b.cleanupTimer.unref?.(),g.set(e,b),h()}else i(e,j);return a}catch(a){throw i(e,j),a}})();return j.promise=k,g.set(e,j),h(),k}var k=c(12407),l=c(57034);function m(a,b,c,d){let e=u(c,d);return e.permanent?(a?.error?.("TOKEN_REFRESH",`${b} refresh token revoked or expired. Re-auth required.`,{status:d,code:e.code}),{error:"unrecoverable_refresh_error",code:e.code}):null}function n(a="",b=0){let c="";try{let b=a?JSON.parse(a):null;c=b?.error||b?.error_code||b?.code||""}catch{}return{status:b,errorCode:c||void 0,bodyLen:a?.length||0}}let o=null;async function p(a,b){return a?j("xai",a,async()=>{try{if(!o){let a=(0,k.oC)().createXaiService;if(!a)return b?.warn?.("TOKEN_REFRESH","xAI service not wired (setOpenSseDeps)"),null;o=await a()}let c=await o.refreshAccessToken(a);return{accessToken:c.access_token,refreshToken:c.refresh_token||a,expiresIn:c.expires_in,idToken:c.id_token}}catch(d){let a=String(d?.message||""),c=a.includes("invalid_grant")?"invalid_grant":a.includes("invalid_request")?"invalid_request":null;if(b?.warn?.("TOKEN_REFRESH","xai refresh failed",c?{errorCode:c}:void 0),c)return{error:c};return null}},b):null}async function q(a,b,c,e,g=null){let h=d.xq[a],i=h?.refreshUrl||d.sr[a]?.refreshUrl||d.sr[a]?.tokenUrl;return h&&i?b?j(a,b,async()=>{try{let c=new URLSearchParams({grant_type:"refresh_token",refresh_token:b,client_id:h.clientId});h.clientSecret&&c.set("client_secret",h.clientSecret);let d=await (0,f.Fm)(i,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded",Accept:"application/json"},body:c,identity:h.identity,provider:a,format:h.format},g);if(!d.ok){let b=await d.text(),c=m(e,a,b,d.status);if(c)return c;return e?.error?.("TOKEN_REFRESH",`Failed to refresh token for ${a}`,{status:d.status,error:n(b,d.status)}),null}let j=await d.json();return e?.info?.("TOKEN_REFRESH",`Successfully refreshed token for ${a}`,{hasNewAccessToken:!!j.access_token,hasNewRefreshToken:!!j.refresh_token,expiresIn:j.expires_in}),{accessToken:j.access_token,refreshToken:j.refresh_token||b,expiresIn:j.expires_in}}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 r(a,b,c=null){return a?j("claude",a,async()=>{try{let g=await (0,f.Fm)(e.NA.anthropic.token,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({grant_type:"refresh_token",refresh_token:a,client_id:d.xq.claude.clientId}),identity:d.xq.claude?.identity,provider:"claude",format:d.xq.claude?.format},c);if(!g.ok){let a=await g.text(),c=m(b,"Claude",a,g.status);if(c)return c;return b?.error?.("TOKEN_REFRESH","Failed to refresh Claude OAuth token",{status:g.status,error:n(a,g.status)}),null}let h=await g.json();return b?.info?.("TOKEN_REFRESH","Successfully refreshed Claude OAuth token",{hasNewAccessToken:!!h.access_token,expiresIn:h.expires_in}),{accessToken:h.access_token,refreshToken:h.refresh_token||a,expiresIn:h.expires_in}}catch(a){return b?.error?.("TOKEN_REFRESH",`Network error refreshing Claude token: ${a.message}`),null}},b):null}async function s(a,b,c,g,h=null,i=null){if(!a)return null;let k=h||(b===d.xq.antigravity?.clientId?"antigravity":"gemini-cli"),l=d.xq[k];return j(`google:${b}`,a,async()=>{try{let d=await (0,f.Fm)(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}),identity:l?.identity,provider:k,format:l?.format},i);if(!d.ok){let a=await d.text(),b=m(g,"Google",a,d.status);if(b)return b;return g?.error?.("TOKEN_REFRESH","Failed to refresh Google token",{status:d.status,error:n(a,d.status)}),null}let h=await d.json();return g?.info?.("TOKEN_REFRESH","Successfully refreshed Google token",{hasNewAccessToken:!!h.access_token,expiresIn:h.expires_in}),{accessToken:h.access_token,refreshToken:h.refresh_token||a,expiresIn:h.expires_in}}catch(a){return g?.error?.("TOKEN_REFRESH",`Network error refreshing Google token: ${a.message}`),null}},g)}async function t(a,b){return a?j("qwen",a,async()=>{let c=e.NA.qwen.token;try{let e=await (0,f.Fm)(c,{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:d.xq.qwen.clientId}),identity:d.xq.qwen?.identity,provider:"qwen",format:d.xq.qwen?.format});if(200===e.status){let c=await e.json();return b?.info?.("TOKEN_REFRESH","Successfully refreshed Qwen token",{hasNewAccessToken:!!c.access_token,hasNewRefreshToken:!!c.refresh_token,expiresIn:c.expires_in}),{accessToken:c.access_token,refreshToken:c.refresh_token||a,expiresIn:c.expires_in,providerSpecificData:c.resource_url?{resourceUrl:c.resource_url}:void 0}}{let a=await e.text().catch(()=>""),c=m(b,"Qwen",a,e.status);if(c)return c;b?.warn?.("TOKEN_REFRESH","Error with Qwen endpoint",{status:e.status,error:n(a,e.status)})}}catch(a){b?.warn?.("TOKEN_REFRESH","Network error trying Qwen endpoint",{error:a.message})}return b?.error?.("TOKEN_REFRESH","Failed to refresh Qwen token"),null},b):null}function u(a="",b=0){let c=null;try{c=a?JSON.parse(a):null}catch{c=null}let d=c?.error,e=("string"==typeof d?d:d?.code||d?.type)||c?.error_code||"",f=c?.error_description||c?.message||d?.message||a||"",g=`${e} ${f}`.toLowerCase(),h=b<500&&["refresh_token_expired","refresh_token_reused","refresh_token_invalidated","invalid_grant","bad_refresh_token"].some(a=>g.includes(a));return{status:b,code:e,description:f,permanent:h}}async function v(a,b){return a?j("codex",a,async()=>{try{let c=await (0,f.Fm)(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}),identity:d.xq.codex?.identity,provider:"codex",format:d.xq.codex?.format});if(!c.ok){let a=await c.text(),d=u(a,c.status);if(d.permanent)return b?.error?.("TOKEN_REFRESH","Codex refresh token already used or invalid. Re-auth required.",{status:c.status,code:d.code}),{error:"unrecoverable_refresh_error",code:d.code};return b?.error?.("TOKEN_REFRESH","Failed to refresh Codex token",{status:c.status,error:n(a,c.status),code:d.code,permanent:d.permanent}),null}let g=await c.json();return b?.info?.("TOKEN_REFRESH","Successfully refreshed Codex token",{hasNewAccessToken:!!g.access_token,hasNewRefreshToken:!!g.refresh_token,hasIdToken:!!g.id_token,expiresIn:g.expires_in}),{accessToken:g.access_token,refreshToken:g.refresh_token||a,idToken:g.id_token,expiresIn:g.expires_in}}catch(a){return b?.error?.("TOKEN_REFRESH",`Network error refreshing Codex token: ${a.message}`),null}},b):null}async function w(a,b,c){if(a?.profileArn)return{};let d=c?.trim?.()||null;if(!d){let c=(0,k.oC)().fetchKiroProfileArn;c&&(d=await c(b,a?.region))}return d?{providerSpecificData:{profileArn:d}}:{}}async function x(a,b,c,e=null){return a?j("kiro",a,async()=>{let g=b?.authMethod,h=b?.clientId,i=b?.clientSecret,j=b?.region;if("external_idp"===g){let g;try{let c=(0,k.oC)().buildExternalIdpRefreshParams;if(!c)throw Error("buildExternalIdpRefreshParams not wired");g=await c(a,b)}catch(a){return c?.warn?.("TOKEN_REFRESH",`Invalid Kiro external_idp refresh config: ${a.message}`),null}let h=await (0,f.Fm)(g.tokenEndpoint,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded",Accept:"application/json"},body:g.body,identity:d.xq.kiro?.identity,provider:"kiro",format:d.xq.kiro?.format},e);if(!h.ok){let a=await h.text();return c?.error?.("TOKEN_REFRESH","Failed to refresh Kiro external_idp token",{status:h.status,error:n(a,h.status)}),null}let i=await h.json();return c?.info?.("TOKEN_REFRESH","Successfully refreshed Kiro external_idp token",{hasNewAccessToken:!!i.access_token,hasNewRefreshToken:!!i.refresh_token,expiresIn:i.expires_in}),{accessToken:i.access_token,refreshToken:i.refresh_token||a,expiresIn:i.expires_in,providerSpecificData:g.providerSpecificData}}if(h&&i){let k="idc"===g&&(0,l.i7)(j)?`https://oidc.${j}.amazonaws.com/token`:"https://oidc.us-east-1.amazonaws.com/token",m=await (0,f.Fm)(k,{method:"POST",headers:{"Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({clientId:h,clientSecret:i,refreshToken:a,grantType:"refresh_token"}),identity:d.xq.kiro?.identity,provider:"kiro",format:d.xq.kiro?.format},e);if(!m.ok){let a=await m.text();return c?.error?.("TOKEN_REFRESH","Failed to refresh Kiro AWS token",{status:m.status,error:n(a,m.status)}),null}let o=await m.json();return c?.info?.("TOKEN_REFRESH","Successfully refreshed Kiro AWS token",{hasNewAccessToken:!!o.accessToken,expiresIn:o.expiresIn}),{accessToken:o.accessToken,refreshToken:o.refreshToken||a,expiresIn:o.expiresIn,...await w(b,o.accessToken,o.profileArn)}}let m=await (0,f.Fm)(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}),identity:d.xq.kiro?.identity,provider:"kiro",format:d.xq.kiro?.format},e);if(!m.ok){let a=await m.text();return c?.error?.("TOKEN_REFRESH","Failed to refresh Kiro social token",{status:m.status,error:n(a,m.status)}),null}let o=await m.json();return c?.info?.("TOKEN_REFRESH","Successfully refreshed Kiro social token",{hasNewAccessToken:!!o.accessToken,expiresIn:o.expiresIn}),{accessToken:o.accessToken,refreshToken:o.refreshToken||a,expiresIn:o.expiresIn,...await w(b,o.accessToken,o.profileArn)}},c):null}async function y(a,b){return a?j("iflow",a,async()=>{let c=btoa(`${d.xq.iflow.clientId}:${d.xq.iflow.clientSecret}`),g=await (0,f.Fm)(e.NA.iflow.token,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded",Accept:"application/json",Authorization:`Basic ${c}`},body:new URLSearchParams({grant_type:"refresh_token",refresh_token:a,client_id:d.xq.iflow.clientId,client_secret:d.xq.iflow.clientSecret}),identity:d.xq.iflow?.identity,provider:"iflow",format:d.xq.iflow?.format});if(!g.ok){let a=await g.text(),c=m(b,"iFlow",a,g.status);return c||(b?.error?.("TOKEN_REFRESH","Failed to refresh iFlow token",{status:g.status,error:n(a,g.status)}),null)}let h=await g.json();return b?.info?.("TOKEN_REFRESH","Successfully refreshed iFlow 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}},b):null}async function z(a,b){return a?j("github",a,async()=>{let c={grant_type:"refresh_token",refresh_token:a,client_id:d.xq.github.clientId};d.xq.github.clientSecret&&(c.client_secret=d.xq.github.clientSecret);let g=await (0,f.Fm)(e.NA.github.token,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded",Accept:"application/json"},body:new URLSearchParams(c),identity:d.xq.github?.identity,provider:"github",format:d.xq.github?.format});if(!g.ok){let a=await g.text(),c=m(b,"GitHub",a,g.status);return c||(b?.error?.("TOKEN_REFRESH","Failed to refresh GitHub token",{status:g.status,error:n(a,g.status)}),null)}let h=await g.json();if(h.error||!h.access_token){let a=JSON.stringify(h),c=m(b,"GitHub",a,g.status);return c||(b?.error?.("TOKEN_REFRESH","Failed to refresh GitHub token",{status:g.status,error:n(a,g.status)}),null)}return b?.info?.("TOKEN_REFRESH","Successfully refreshed GitHub 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}},b):null}async function A(a,b){return a?j("copilot",a,async()=>{try{let c=await (0,f.Fm)(d.sr.github?.copilotTokenUrl,{headers:{Authorization:`token ${a}`,Accept:"application/json"},identity:d.xq.github?.identity,provider:"github",format:d.xq.github?.format});if(!c.ok){let a=await c.text();return b?.error?.("TOKEN_REFRESH","Failed to refresh Copilot token",{status:c.status,error:n(a,c.status)}),null}let e=await c.json();return b?.info?.("TOKEN_REFRESH","Successfully refreshed Copilot token",{hasToken:!!e.token,expiresAt:e.expires_at}),{token:e.token,expiresAt:e.expires_at}}catch(a){return b?.error?.("TOKEN_REFRESH","Error refreshing Copilot token",{error:a.message}),null}},b):null}async function B(a,b){return a?j("codebuddy-cn",a,async()=>{let c=d.sr["codebuddy-cn"]||{},e=await (0,f.Fm)(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},body:JSON.stringify({refreshToken:a}),identity:d.xq["codebuddy-cn"]?.identity,provider:"codebuddy-cn",format:d.xq["codebuddy-cn"]?.format});if(!e.ok){let a=await e.text();return b?.error?.("TOKEN_REFRESH","Failed to refresh CodeBuddy token",{status:e.status,error:n(a,e.status)}),null}let g=await e.json();return 0===g.code&&g.data?.accessToken?(b?.info?.("TOKEN_REFRESH","Successfully refreshed CodeBuddy token",{hasNewAccessToken:!!g.data.accessToken,hasNewRefreshToken:!!g.data.refreshToken,expiresIn:g.data.expiresIn}),{accessToken:g.data.accessToken,refreshToken:g.data.refreshToken||a,expiresIn:g.data.expiresIn}):(b?.error?.("TOKEN_REFRESH","CodeBuddy token refresh returned no token",{code:g.code,msg:g.msg}),null)},b):null}let C=3e5;function D(a){return a&&"object"==typeof a&&("unrecoverable_refresh_error"===a.error||"refresh_token_reused"===a.error||"invalid_request"===a.error||"invalid_grant"===a.error)}function E(a){return e.Wu[a]||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,g="vertex",h=null){let i=a.client_email,j=G.get(i);if(j&&j.expiresAt-Date.now()>3e5)return{accessToken:j.token,expiresAt:j.expiresAt};try{let{SignJWT:j,importPKCS8:k}=await c.e(9078).then(c.bind(c,9078));b?.debug?.("TOKEN_REFRESH",`Vertex minting token for ${a.client_email}`);let l=await k(a.private_key.replace(/\\n/g,"\n"),"RS256"),m=Math.floor(Date.now()/1e3),n=await new j({scope:"https://www.googleapis.com/auth/cloud-platform"}).setProtectedHeader({alg:"RS256"}).setIssuer(a.client_email).setAudience(e.NA.google.token).setIssuedAt(m).setExpirationTime(m+3600).sign(l),o=d.xq[g]||d.xq.vertex,p=await (0,f.Fm)(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:n}),identity:o.identity,provider:g,format:o.format},h);if(!p.ok){let a=await p.text();return b?.error?.("TOKEN_REFRESH",`Vertex token mint failed: ${a}`),null}let{access_token:q,expires_in:r}=await p.json(),s=Date.now()+(r??3600)*1e3;return G.set(i,{token:q,expiresAt:s}),b?.info?.("TOKEN_REFRESH",`Vertex token minted for ${a.client_email}`),{accessToken:q,expiresAt:s}}catch(a){return b?.error?.("TOKEN_REFRESH",`Vertex token error: ${a.message}`),null}}function I(a,b,c="vertex"){let d=F(a.apiKey);if(d)return H(d,b,c);try{let d="string"==typeof a.apiKey?JSON.parse(a.apiKey):null;if(d?.type==="authorized_user"&&d.refresh_token&&d.client_id&&d.client_secret)return s(d.refresh_token,d.client_id,d.client_secret,b,c)}catch{}return null}let J={"gemini-cli":(a,b)=>s(a.refreshToken,d.xq["gemini-cli"].clientId,d.xq["gemini-cli"].clientSecret,b),antigravity:(a,b)=>s(a.refreshToken,d.xq.antigravity.clientId,d.xq.antigravity.clientSecret,b),claude:(a,b,c)=>r(a.refreshToken,b,c),codex:(a,b)=>v(a.refreshToken,b),qwen:(a,b)=>t(a.refreshToken,b),iflow:(a,b)=>y(a.refreshToken,b),github:(a,b)=>z(a.refreshToken,b),kiro:(a,b)=>x(a.refreshToken,a.providerSpecificData,b),xai:(a,b)=>p(a.refreshToken,b),"grok-cli":(a,b,c)=>q("grok-cli",a.refreshToken,a,b,c),"codebuddy-cn":(a,b)=>B(a.refreshToken,b),muse:(a,b)=>K(a.providerSpecificData?.dcaToken||a.refreshToken,b),vertex:(a,b)=>I(a,b,"vertex"),"vertex-partner":(a,b)=>I(a,b,"vertex-partner")};async function K(a,b){if(!a)return null;try{let c=process.env.META_MINT_URL||"https://api.meta.ai/muse-code/key",d=await (0,f.Fm)(c,{method:"POST",headers:{Authorization:`Bearer ${a}`,"User-Agent":"muse-code/1.0.2","Content-Type":"application/json",Accept:"application/json"},body:JSON.stringify({dca_token:a}),identity:"muse-code",provider:"muse"});if(!d.ok)return b?.warn?.("TOKEN_REFRESH",`Failed to re-mint Meta Muse API key: ${d.status}`),null;let e=await d.json();return{accessToken:e.api_key,apiKey:e.api_key,providerSpecificData:{apiKey:e.api_key,baseUrl:e.base_url||"https://api.meta.ai/v1"}}}catch(a){return b?.warn?.("TOKEN_REFRESH",`Error re-minting Meta Muse API key: ${a?.message}`),null}}async function L(a,b,c,d=null){let e="vertex"===a||"vertex-partner"===a;if(!b.refreshToken&&!(e&&b?.apiKey))return null;let f=J[a];return f?f(b,c,d):q(a,b.refreshToken,b,c,d)}async function M(a,b=3,c=null,d=null){for(let e=0;e<b;e++){if(d?.throwIfAborted(),e>0){let a=1e3*e;c?.debug?.("TOKEN_REFRESH",`Retry ${e}/${b} after ${a}ms`),await new Promise(b=>{let c=()=>{clearTimeout(e),d?.removeEventListener("abort",c),b()},e=setTimeout(c,a);d?.addEventListener("abort",c,{once:!0}),d?.aborted&&c()}),d?.throwIfAborted()}try{let b=await a();if(D(b)||b)return b}catch(a){d?.throwIfAborted(),c?.warn?.("TOKEN_REFRESH",`Attempt ${e+1}/${b} failed: ${a.message}`)}}return c?.error?.("TOKEN_REFRESH",`All ${b} retry attempts failed`),null}},47293:(a,b,c)=>{c.d(b,{A:()=>f});let d=new Uint8Array(16);var e=c(50122);let f=function(a,b,c){return b||a||!crypto.randomUUID?function(a,b,c){let f=(a=a||{}).random??a.rng?.()??crypto.getRandomValues(d);if(f.length<16)throw Error("Random bytes length must be >= 16");if(f[6]=15&f[6]|64,f[8]=63&f[8]|128,b){if((c=c||0)<0||c+16>b.length)throw RangeError(`UUID byte range ${c}:${c+15} is out of buffer bounds`);for(let a=0;a<16;++a)b[c+a]=f[a];return b}return(0,e.k)(f)}(a,b,c):crypto.randomUUID()}},50122:(a,b,c)=>{c.d(b,{k:()=>e});let d=[];for(let a=0;a<256;++a)d.push((a+256).toString(16).slice(1));function e(a,b=0){return(d[a[b+0]]+d[a[b+1]]+d[a[b+2]]+d[a[b+3]]+"-"+d[a[b+4]]+d[a[b+5]]+"-"+d[a[b+6]]+d[a[b+7]]+"-"+d[a[b+8]]+d[a[b+9]]+"-"+d[a[b+10]]+d[a[b+11]]+d[a[b+12]]+d[a[b+13]]+d[a[b+14]]+d[a[b+15]]).toLowerCase()}},57034:(a,b,c)=>{c.d(b,{i7:()=>e,l6:()=>f});let d=/^[a-z]{2}(?:-[a-z0-9]+)+-\d{1,2}$/;function e(a){return"string"==typeof a&&d.test(a)}function f(a,b="us-east-1"){return e(a)?a:b}}};