@rabbi696/ezrouter 0.6.15 → 0.6.16

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 (863) hide show
  1. package/README.md +72 -1
  2. package/app/.next-cli-build/BUILD_ID +1 -1
  3. package/app/.next-cli-build/app-path-routes-manifest.json +27 -27
  4. package/app/.next-cli-build/build-manifest.json +2 -2
  5. package/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page.js +1 -1
  6. package/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page.js.nft.json +1 -1
  7. package/app/.next-cli-build/server/app/(dashboard)/dashboard/basic-chat/page_client-reference-manifest.js +1 -1
  8. package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page.js +1 -1
  9. package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page.js.nft.json +1 -1
  10. package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/[toolId]/page_client-reference-manifest.js +1 -1
  11. package/app/.next-cli-build/server/app/(dashboard)/dashboard/cli-tools/page.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 +1 -1
  15. package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page.js.nft.json +1 -1
  16. package/app/.next-cli-build/server/app/(dashboard)/dashboard/combos/page_client-reference-manifest.js +1 -1
  17. package/app/.next-cli-build/server/app/(dashboard)/dashboard/console-log/page.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/convoy/page.js +1 -1
  21. package/app/.next-cli-build/server/app/(dashboard)/dashboard/convoy/page.js.nft.json +1 -1
  22. package/app/.next-cli-build/server/app/(dashboard)/dashboard/convoy/page_client-reference-manifest.js +1 -1
  23. package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page.js +1 -1
  24. package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page.js.nft.json +1 -1
  25. package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page_client-reference-manifest.js +1 -1
  26. package/app/.next-cli-build/server/app/(dashboard)/dashboard/error-log/page.js +1 -1
  27. package/app/.next-cli-build/server/app/(dashboard)/dashboard/error-log/page.js.nft.json +1 -1
  28. package/app/.next-cli-build/server/app/(dashboard)/dashboard/error-log/page_client-reference-manifest.js +1 -1
  29. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mcp-gateway/keys/page.js +1 -1
  30. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mcp-gateway/keys/page.js.nft.json +1 -1
  31. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mcp-gateway/keys/page_client-reference-manifest.js +1 -1
  32. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mcp-gateway/page.js +1 -1
  33. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mcp-gateway/page.js.nft.json +1 -1
  34. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mcp-gateway/page_client-reference-manifest.js +1 -1
  35. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mcp-gateway/servers/page.js +1 -1
  36. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mcp-gateway/servers/page.js.nft.json +1 -1
  37. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mcp-gateway/servers/page_client-reference-manifest.js +1 -1
  38. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page.js +10 -6
  39. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page.js.nft.json +1 -1
  40. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page_client-reference-manifest.js +1 -1
  41. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page.js +1 -1
  42. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page.js.nft.json +1 -1
  43. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page_client-reference-manifest.js +1 -1
  44. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page.js +1 -1
  45. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page.js.nft.json +1 -1
  46. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page_client-reference-manifest.js +1 -1
  47. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page.js +1 -1
  48. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page.js.nft.json +1 -1
  49. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page_client-reference-manifest.js +1 -1
  50. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page.js +1 -1
  51. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page.js.nft.json +1 -1
  52. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page_client-reference-manifest.js +1 -1
  53. package/app/.next-cli-build/server/app/(dashboard)/dashboard/page.js +1 -1
  54. package/app/.next-cli-build/server/app/(dashboard)/dashboard/page.js.nft.json +1 -1
  55. package/app/.next-cli-build/server/app/(dashboard)/dashboard/page_client-reference-manifest.js +1 -1
  56. package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page.js +1 -1
  57. package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page.js.nft.json +1 -1
  58. package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page_client-reference-manifest.js +1 -1
  59. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page.js +3 -3
  60. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page.js.nft.json +1 -1
  61. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page_client-reference-manifest.js +1 -1
  62. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page.js +1 -1
  63. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page.js.nft.json +1 -1
  64. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page_client-reference-manifest.js +1 -1
  65. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page.js +1 -1
  66. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page.js.nft.json +1 -1
  67. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page_client-reference-manifest.js +1 -1
  68. package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page.js +1 -1
  69. package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page.js.nft.json +1 -1
  70. package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page_client-reference-manifest.js +1 -1
  71. package/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page.js +1 -1
  72. package/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page.js.nft.json +1 -1
  73. package/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page_client-reference-manifest.js +1 -1
  74. package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page.js +1 -1
  75. package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page.js.nft.json +1 -1
  76. package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page_client-reference-manifest.js +1 -1
  77. package/app/.next-cli-build/server/app/(dashboard)/dashboard/routing-health/page.js +1 -1
  78. package/app/.next-cli-build/server/app/(dashboard)/dashboard/routing-health/page.js.nft.json +1 -1
  79. package/app/.next-cli-build/server/app/(dashboard)/dashboard/routing-health/page_client-reference-manifest.js +1 -1
  80. package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page.js +1 -1
  81. package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page.js.nft.json +1 -1
  82. package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page_client-reference-manifest.js +1 -1
  83. package/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page.js +1 -1
  84. package/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page.js.nft.json +1 -1
  85. package/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page_client-reference-manifest.js +1 -1
  86. package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page.js +1 -1
  87. package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page.js.nft.json +1 -1
  88. package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page_client-reference-manifest.js +1 -1
  89. package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page.js +1 -1
  90. package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page.js.nft.json +1 -1
  91. package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page_client-reference-manifest.js +1 -1
  92. package/app/.next-cli-build/server/app/_global-error/page.js.nft.json +1 -1
  93. package/app/.next-cli-build/server/app/_global-error/page_client-reference-manifest.js +1 -1
  94. package/app/.next-cli-build/server/app/_global-error.html +1 -1
  95. package/app/.next-cli-build/server/app/_global-error.rsc +1 -1
  96. package/app/.next-cli-build/server/app/_global-error.segments/_full.segment.rsc +1 -1
  97. package/app/.next-cli-build/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
  98. package/app/.next-cli-build/server/app/_global-error.segments/_global-error.segment.rsc +1 -1
  99. package/app/.next-cli-build/server/app/_global-error.segments/_head.segment.rsc +1 -1
  100. package/app/.next-cli-build/server/app/_global-error.segments/_index.segment.rsc +1 -1
  101. package/app/.next-cli-build/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  102. package/app/.next-cli-build/server/app/_not-found/page.js +1 -1
  103. package/app/.next-cli-build/server/app/_not-found/page.js.nft.json +1 -1
  104. package/app/.next-cli-build/server/app/_not-found/page_client-reference-manifest.js +1 -1
  105. package/app/.next-cli-build/server/app/_not-found.html +1 -1
  106. package/app/.next-cli-build/server/app/_not-found.rsc +3 -3
  107. package/app/.next-cli-build/server/app/_not-found.segments/_full.segment.rsc +3 -3
  108. package/app/.next-cli-build/server/app/_not-found.segments/_head.segment.rsc +1 -1
  109. package/app/.next-cli-build/server/app/_not-found.segments/_index.segment.rsc +3 -3
  110. package/app/.next-cli-build/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
  111. package/app/.next-cli-build/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
  112. package/app/.next-cli-build/server/app/_not-found.segments/_tree.segment.rsc +1 -1
  113. package/app/.next-cli-build/server/app/api/auth/login/route.js +1 -1
  114. package/app/.next-cli-build/server/app/api/auth/login/route.js.nft.json +1 -1
  115. package/app/.next-cli-build/server/app/api/auth/logout/route.js +1 -1
  116. package/app/.next-cli-build/server/app/api/auth/logout/route.js.nft.json +1 -1
  117. package/app/.next-cli-build/server/app/api/auth/oidc/callback/route.js +1 -1
  118. package/app/.next-cli-build/server/app/api/auth/oidc/callback/route.js.nft.json +1 -1
  119. package/app/.next-cli-build/server/app/api/auth/oidc/start/route.js +1 -1
  120. package/app/.next-cli-build/server/app/api/auth/oidc/start/route.js.nft.json +1 -1
  121. package/app/.next-cli-build/server/app/api/auth/oidc/test/route.js +1 -1
  122. package/app/.next-cli-build/server/app/api/auth/oidc/test/route.js.nft.json +1 -1
  123. package/app/.next-cli-build/server/app/api/auth/reset-password/route.js +1 -1
  124. package/app/.next-cli-build/server/app/api/auth/reset-password/route.js.nft.json +1 -1
  125. package/app/.next-cli-build/server/app/api/auth/saml/acs/route.js +1 -1
  126. package/app/.next-cli-build/server/app/api/auth/saml/acs/route.js.nft.json +1 -1
  127. package/app/.next-cli-build/server/app/api/auth/saml/metadata/route.js +1 -1
  128. package/app/.next-cli-build/server/app/api/auth/saml/metadata/route.js.nft.json +1 -1
  129. package/app/.next-cli-build/server/app/api/auth/saml/start/route.js +1 -1
  130. package/app/.next-cli-build/server/app/api/auth/saml/start/route.js.nft.json +1 -1
  131. package/app/.next-cli-build/server/app/api/auth/saml/test/route.js +1 -1
  132. package/app/.next-cli-build/server/app/api/auth/saml/test/route.js.nft.json +1 -1
  133. package/app/.next-cli-build/server/app/api/auth/status/route.js +1 -1
  134. package/app/.next-cli-build/server/app/api/auth/status/route.js.nft.json +1 -1
  135. package/app/.next-cli-build/server/app/api/changelog/route.js.nft.json +1 -1
  136. package/app/.next-cli-build/server/app/api/cli/providers/codex/route.js +1 -1
  137. package/app/.next-cli-build/server/app/api/cli/providers/codex/route.js.nft.json +1 -1
  138. package/app/.next-cli-build/server/app/api/cli-tools/all-statuses/route.js +1 -1
  139. package/app/.next-cli-build/server/app/api/cli-tools/all-statuses/route.js.nft.json +1 -1
  140. package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/alias/route.js +1 -1
  141. package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/alias/route.js.nft.json +1 -1
  142. package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/route.js +1 -1
  143. package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/route.js.nft.json +1 -1
  144. package/app/.next-cli-build/server/app/api/cli-tools/claude-settings/route.js.nft.json +1 -1
  145. package/app/.next-cli-build/server/app/api/cli-tools/cline-settings/route.js.nft.json +1 -1
  146. package/app/.next-cli-build/server/app/api/cli-tools/codewhale-settings/route.js +1 -1
  147. package/app/.next-cli-build/server/app/api/cli-tools/codewhale-settings/route.js.nft.json +1 -1
  148. package/app/.next-cli-build/server/app/api/cli-tools/codex-native/models/route.js +1 -1
  149. package/app/.next-cli-build/server/app/api/cli-tools/codex-native/models/route.js.nft.json +1 -1
  150. package/app/.next-cli-build/server/app/api/cli-tools/codex-native/readiness/route.js +1 -1
  151. package/app/.next-cli-build/server/app/api/cli-tools/codex-native/readiness/route.js.nft.json +1 -1
  152. package/app/.next-cli-build/server/app/api/cli-tools/codex-profiles/route.js.nft.json +1 -1
  153. package/app/.next-cli-build/server/app/api/cli-tools/codex-settings/route.js.nft.json +1 -1
  154. package/app/.next-cli-build/server/app/api/cli-tools/copilot-settings/route.js +1 -1
  155. package/app/.next-cli-build/server/app/api/cli-tools/copilot-settings/route.js.nft.json +1 -1
  156. package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-registry/route.js.nft.json +1 -1
  157. package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-tools/route.js +1 -1
  158. package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-tools/route.js.nft.json +1 -1
  159. package/app/.next-cli-build/server/app/api/cli-tools/cowork-settings/route.js +1 -1
  160. package/app/.next-cli-build/server/app/api/cli-tools/cowork-settings/route.js.nft.json +1 -1
  161. package/app/.next-cli-build/server/app/api/cli-tools/crush-settings/route.js +1 -1
  162. package/app/.next-cli-build/server/app/api/cli-tools/crush-settings/route.js.nft.json +1 -1
  163. package/app/.next-cli-build/server/app/api/cli-tools/deepseek-tui-settings/route.js +1 -1
  164. package/app/.next-cli-build/server/app/api/cli-tools/deepseek-tui-settings/route.js.nft.json +1 -1
  165. package/app/.next-cli-build/server/app/api/cli-tools/devin-settings/route.js.nft.json +1 -1
  166. package/app/.next-cli-build/server/app/api/cli-tools/droid-settings/route.js.nft.json +1 -1
  167. package/app/.next-cli-build/server/app/api/cli-tools/forge-settings/route.js +1 -1
  168. package/app/.next-cli-build/server/app/api/cli-tools/forge-settings/route.js.nft.json +1 -1
  169. package/app/.next-cli-build/server/app/api/cli-tools/grok-build-settings/route.js +1 -1
  170. package/app/.next-cli-build/server/app/api/cli-tools/grok-build-settings/route.js.nft.json +1 -1
  171. package/app/.next-cli-build/server/app/api/cli-tools/hermes-settings/route.js.nft.json +1 -1
  172. package/app/.next-cli-build/server/app/api/cli-tools/jcode-settings/route.js.nft.json +1 -1
  173. package/app/.next-cli-build/server/app/api/cli-tools/kilo-settings/route.js.nft.json +1 -1
  174. package/app/.next-cli-build/server/app/api/cli-tools/omp-settings/route.js +1 -1
  175. package/app/.next-cli-build/server/app/api/cli-tools/omp-settings/route.js.nft.json +1 -1
  176. package/app/.next-cli-build/server/app/api/cli-tools/openclaw-settings/route.js.nft.json +1 -1
  177. package/app/.next-cli-build/server/app/api/cli-tools/opencode-settings/route.js +1 -1
  178. package/app/.next-cli-build/server/app/api/cli-tools/opencode-settings/route.js.nft.json +1 -1
  179. package/app/.next-cli-build/server/app/api/cli-tools/pi-settings/route.js +1 -1
  180. package/app/.next-cli-build/server/app/api/cli-tools/pi-settings/route.js.nft.json +1 -1
  181. package/app/.next-cli-build/server/app/api/cli-tools/smelt-settings/route.js +1 -1
  182. package/app/.next-cli-build/server/app/api/cli-tools/smelt-settings/route.js.nft.json +1 -1
  183. package/app/.next-cli-build/server/app/api/combos/[id]/route.js +1 -1
  184. package/app/.next-cli-build/server/app/api/combos/[id]/route.js.nft.json +1 -1
  185. package/app/.next-cli-build/server/app/api/combos/[id]/test/route.js +1 -1
  186. package/app/.next-cli-build/server/app/api/combos/[id]/test/route.js.nft.json +1 -1
  187. package/app/.next-cli-build/server/app/api/combos/export/route.js +1 -1
  188. package/app/.next-cli-build/server/app/api/combos/export/route.js.nft.json +1 -1
  189. package/app/.next-cli-build/server/app/api/combos/import/route.js +1 -1
  190. package/app/.next-cli-build/server/app/api/combos/import/route.js.nft.json +1 -1
  191. package/app/.next-cli-build/server/app/api/combos/presets/route.js +1 -1
  192. package/app/.next-cli-build/server/app/api/combos/presets/route.js.nft.json +1 -1
  193. package/app/.next-cli-build/server/app/api/combos/route.js +1 -1
  194. package/app/.next-cli-build/server/app/api/combos/route.js.nft.json +1 -1
  195. package/app/.next-cli-build/server/app/api/combos/test/route.js +1 -1
  196. package/app/.next-cli-build/server/app/api/combos/test/route.js.nft.json +1 -1
  197. package/app/.next-cli-build/server/app/api/convoy/rules/route.js.nft.json +1 -1
  198. package/app/.next-cli-build/server/app/api/headroom/extras/route.js +1 -1
  199. package/app/.next-cli-build/server/app/api/headroom/extras/route.js.nft.json +1 -1
  200. package/app/.next-cli-build/server/app/api/headroom/proxy/[...path]/route.js +1 -1
  201. package/app/.next-cli-build/server/app/api/headroom/proxy/[...path]/route.js.nft.json +1 -1
  202. package/app/.next-cli-build/server/app/api/headroom/restart/route.js +1 -1
  203. package/app/.next-cli-build/server/app/api/headroom/restart/route.js.nft.json +1 -1
  204. package/app/.next-cli-build/server/app/api/headroom/start/route.js +1 -1
  205. package/app/.next-cli-build/server/app/api/headroom/start/route.js.nft.json +1 -1
  206. package/app/.next-cli-build/server/app/api/headroom/status/route.js +1 -1
  207. package/app/.next-cli-build/server/app/api/headroom/status/route.js.nft.json +1 -1
  208. package/app/.next-cli-build/server/app/api/headroom/stop/route.js +1 -1
  209. package/app/.next-cli-build/server/app/api/headroom/stop/route.js.nft.json +1 -1
  210. package/app/.next-cli-build/server/app/api/health/route.js.nft.json +1 -1
  211. package/app/.next-cli-build/server/app/api/init/route.js.nft.json +1 -1
  212. package/app/.next-cli-build/server/app/api/internal/codex-native/lease/[action]/route.js +1 -1
  213. package/app/.next-cli-build/server/app/api/internal/codex-native/lease/[action]/route.js.nft.json +1 -1
  214. package/app/.next-cli-build/server/app/api/keys/[id]/route.js +1 -1
  215. package/app/.next-cli-build/server/app/api/keys/[id]/route.js.nft.json +1 -1
  216. package/app/.next-cli-build/server/app/api/keys/route.js +1 -1
  217. package/app/.next-cli-build/server/app/api/keys/route.js.nft.json +1 -1
  218. package/app/.next-cli-build/server/app/api/locale/route.js.nft.json +1 -1
  219. package/app/.next-cli-build/server/app/api/mcp/[plugin]/message/route.js +1 -1
  220. package/app/.next-cli-build/server/app/api/mcp/[plugin]/message/route.js.nft.json +1 -1
  221. package/app/.next-cli-build/server/app/api/mcp/[plugin]/sse/route.js +1 -1
  222. package/app/.next-cli-build/server/app/api/mcp/[plugin]/sse/route.js.nft.json +1 -1
  223. package/app/.next-cli-build/server/app/api/mcp-gateway/instances/[id]/route.js +1 -1
  224. package/app/.next-cli-build/server/app/api/mcp-gateway/instances/[id]/route.js.nft.json +1 -1
  225. package/app/.next-cli-build/server/app/api/mcp-gateway/instances/[id]/test/route.js +1 -1
  226. package/app/.next-cli-build/server/app/api/mcp-gateway/instances/[id]/test/route.js.nft.json +1 -1
  227. package/app/.next-cli-build/server/app/api/mcp-gateway/instances/route.js +1 -1
  228. package/app/.next-cli-build/server/app/api/mcp-gateway/instances/route.js.nft.json +1 -1
  229. package/app/.next-cli-build/server/app/api/mcp-gateway/keys/[id]/route.js +1 -1
  230. package/app/.next-cli-build/server/app/api/mcp-gateway/keys/[id]/route.js.nft.json +1 -1
  231. package/app/.next-cli-build/server/app/api/mcp-gateway/keys/route.js +1 -1
  232. package/app/.next-cli-build/server/app/api/mcp-gateway/keys/route.js.nft.json +1 -1
  233. package/app/.next-cli-build/server/app/api/mcp-gateway/message/route.js +1 -1
  234. package/app/.next-cli-build/server/app/api/mcp-gateway/message/route.js.nft.json +1 -1
  235. package/app/.next-cli-build/server/app/api/mcp-gateway/oauth/[id]/[action]/route.js +2 -2
  236. package/app/.next-cli-build/server/app/api/mcp-gateway/oauth/[id]/[action]/route.js.nft.json +1 -1
  237. package/app/.next-cli-build/server/app/api/mcp-gateway/route.js +1 -1
  238. package/app/.next-cli-build/server/app/api/mcp-gateway/route.js.nft.json +1 -1
  239. package/app/.next-cli-build/server/app/api/mcp-gateway/sse/route.js.nft.json +1 -1
  240. package/app/.next-cli-build/server/app/api/media-providers/tts/deepgram/voices/route.js +1 -1
  241. package/app/.next-cli-build/server/app/api/media-providers/tts/deepgram/voices/route.js.nft.json +1 -1
  242. package/app/.next-cli-build/server/app/api/media-providers/tts/elevenlabs/voices/route.js +1 -1
  243. package/app/.next-cli-build/server/app/api/media-providers/tts/elevenlabs/voices/route.js.nft.json +1 -1
  244. package/app/.next-cli-build/server/app/api/media-providers/tts/inworld/voices/route.js +1 -1
  245. package/app/.next-cli-build/server/app/api/media-providers/tts/inworld/voices/route.js.nft.json +1 -1
  246. package/app/.next-cli-build/server/app/api/media-providers/tts/minimax/voices/route.js +1 -1
  247. package/app/.next-cli-build/server/app/api/media-providers/tts/minimax/voices/route.js.nft.json +1 -1
  248. package/app/.next-cli-build/server/app/api/media-providers/tts/voices/route.js.nft.json +1 -1
  249. package/app/.next-cli-build/server/app/api/models/alias/route.js +1 -1
  250. package/app/.next-cli-build/server/app/api/models/alias/route.js.nft.json +1 -1
  251. package/app/.next-cli-build/server/app/api/models/availability/route.js +1 -1
  252. package/app/.next-cli-build/server/app/api/models/availability/route.js.nft.json +1 -1
  253. package/app/.next-cli-build/server/app/api/models/catalog-sync/route.js.nft.json +1 -1
  254. package/app/.next-cli-build/server/app/api/models/custom/route.js +1 -1
  255. package/app/.next-cli-build/server/app/api/models/custom/route.js.nft.json +1 -1
  256. package/app/.next-cli-build/server/app/api/models/disabled/route.js +1 -1
  257. package/app/.next-cli-build/server/app/api/models/disabled/route.js.nft.json +1 -1
  258. package/app/.next-cli-build/server/app/api/models/enabled/route.js +1 -1
  259. package/app/.next-cli-build/server/app/api/models/enabled/route.js.nft.json +1 -1
  260. package/app/.next-cli-build/server/app/api/models/route.js +1 -1
  261. package/app/.next-cli-build/server/app/api/models/route.js.nft.json +1 -1
  262. package/app/.next-cli-build/server/app/api/models/test/route.js +1 -1
  263. package/app/.next-cli-build/server/app/api/models/test/route.js.nft.json +1 -1
  264. package/app/.next-cli-build/server/app/api/oauth/[provider]/[action]/route.js +1 -1
  265. package/app/.next-cli-build/server/app/api/oauth/[provider]/[action]/route.js.nft.json +1 -1
  266. package/app/.next-cli-build/server/app/api/oauth/callback/route.js.nft.json +1 -1
  267. package/app/.next-cli-build/server/app/api/oauth/codex/bulk-import/route.js +1 -1
  268. package/app/.next-cli-build/server/app/api/oauth/codex/bulk-import/route.js.nft.json +1 -1
  269. package/app/.next-cli-build/server/app/api/oauth/codex/import-token/route.js +1 -1
  270. package/app/.next-cli-build/server/app/api/oauth/codex/import-token/route.js.nft.json +1 -1
  271. package/app/.next-cli-build/server/app/api/oauth/cursor/auto-import/route.js +1 -1
  272. package/app/.next-cli-build/server/app/api/oauth/cursor/auto-import/route.js.nft.json +1 -1
  273. package/app/.next-cli-build/server/app/api/oauth/cursor/import/route.js +1 -1
  274. package/app/.next-cli-build/server/app/api/oauth/cursor/import/route.js.nft.json +1 -1
  275. package/app/.next-cli-build/server/app/api/oauth/gitlab/pat/route.js +1 -1
  276. package/app/.next-cli-build/server/app/api/oauth/gitlab/pat/route.js.nft.json +1 -1
  277. package/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/route.js +1 -1
  278. package/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/route.js.nft.json +1 -1
  279. package/app/.next-cli-build/server/app/api/oauth/iflow/cookie/route.js +1 -1
  280. package/app/.next-cli-build/server/app/api/oauth/iflow/cookie/route.js.nft.json +1 -1
  281. package/app/.next-cli-build/server/app/api/oauth/kiro/api-key/route.js +1 -1
  282. package/app/.next-cli-build/server/app/api/oauth/kiro/api-key/route.js.nft.json +1 -1
  283. package/app/.next-cli-build/server/app/api/oauth/kiro/auto-import/route.js +1 -1
  284. package/app/.next-cli-build/server/app/api/oauth/kiro/auto-import/route.js.nft.json +1 -1
  285. package/app/.next-cli-build/server/app/api/oauth/kiro/import/route.js +1 -1
  286. package/app/.next-cli-build/server/app/api/oauth/kiro/import/route.js.nft.json +1 -1
  287. package/app/.next-cli-build/server/app/api/oauth/kiro/import-cli-proxy/route.js +1 -1
  288. package/app/.next-cli-build/server/app/api/oauth/kiro/import-cli-proxy/route.js.nft.json +1 -1
  289. package/app/.next-cli-build/server/app/api/oauth/kiro/social-authorize/route.js.nft.json +1 -1
  290. package/app/.next-cli-build/server/app/api/oauth/kiro/social-exchange/route.js +1 -1
  291. package/app/.next-cli-build/server/app/api/oauth/kiro/social-exchange/route.js.nft.json +1 -1
  292. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/api-key/route.js +1 -1
  293. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/api-key/route.js.nft.json +1 -1
  294. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/auto-import/route.js.nft.json +1 -1
  295. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/login/start/route.js.nft.json +1 -1
  296. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/login/status/route.js.nft.json +1 -1
  297. package/app/.next-cli-build/server/app/api/oauth/zed/auto-import/route.js.nft.json +1 -1
  298. package/app/.next-cli-build/server/app/api/oauth/zed/import/route.js +1 -1
  299. package/app/.next-cli-build/server/app/api/oauth/zed/import/route.js.nft.json +1 -1
  300. package/app/.next-cli-build/server/app/api/pricing/route.js +1 -1
  301. package/app/.next-cli-build/server/app/api/pricing/route.js.nft.json +1 -1
  302. package/app/.next-cli-build/server/app/api/provider-nodes/[id]/route.js +1 -1
  303. package/app/.next-cli-build/server/app/api/provider-nodes/[id]/route.js.nft.json +1 -1
  304. package/app/.next-cli-build/server/app/api/provider-nodes/route.js +1 -1
  305. package/app/.next-cli-build/server/app/api/provider-nodes/route.js.nft.json +1 -1
  306. package/app/.next-cli-build/server/app/api/provider-nodes/validate/route.js +1 -1
  307. package/app/.next-cli-build/server/app/api/provider-nodes/validate/route.js.nft.json +1 -1
  308. package/app/.next-cli-build/server/app/api/providers/[id]/models/route.js +1 -1
  309. package/app/.next-cli-build/server/app/api/providers/[id]/models/route.js.nft.json +1 -1
  310. package/app/.next-cli-build/server/app/api/providers/[id]/overrides/route.js +1 -1
  311. package/app/.next-cli-build/server/app/api/providers/[id]/overrides/route.js.nft.json +1 -1
  312. package/app/.next-cli-build/server/app/api/providers/[id]/refresh-profile/route.js +1 -1
  313. package/app/.next-cli-build/server/app/api/providers/[id]/refresh-profile/route.js.nft.json +1 -1
  314. package/app/.next-cli-build/server/app/api/providers/[id]/route.js +1 -1
  315. package/app/.next-cli-build/server/app/api/providers/[id]/route.js.nft.json +1 -1
  316. package/app/.next-cli-build/server/app/api/providers/[id]/test/route.js +1 -1
  317. package/app/.next-cli-build/server/app/api/providers/[id]/test/route.js.nft.json +1 -1
  318. package/app/.next-cli-build/server/app/api/providers/[id]/test-models/route.js +1 -1
  319. package/app/.next-cli-build/server/app/api/providers/[id]/test-models/route.js.nft.json +1 -1
  320. package/app/.next-cli-build/server/app/api/providers/client/route.js +1 -1
  321. package/app/.next-cli-build/server/app/api/providers/client/route.js.nft.json +1 -1
  322. package/app/.next-cli-build/server/app/api/providers/kilo/free-models/route.js.nft.json +1 -1
  323. package/app/.next-cli-build/server/app/api/providers/route.js +1 -1
  324. package/app/.next-cli-build/server/app/api/providers/route.js.nft.json +1 -1
  325. package/app/.next-cli-build/server/app/api/providers/suggested-models/route.js.nft.json +1 -1
  326. package/app/.next-cli-build/server/app/api/providers/test-batch/route.js +1 -1
  327. package/app/.next-cli-build/server/app/api/providers/test-batch/route.js.nft.json +1 -1
  328. package/app/.next-cli-build/server/app/api/providers/validate/route.js +1 -1
  329. package/app/.next-cli-build/server/app/api/providers/validate/route.js.nft.json +1 -1
  330. package/app/.next-cli-build/server/app/api/proxy-pools/[id]/route.js +1 -1
  331. package/app/.next-cli-build/server/app/api/proxy-pools/[id]/route.js.nft.json +1 -1
  332. package/app/.next-cli-build/server/app/api/proxy-pools/[id]/test/route.js +1 -1
  333. package/app/.next-cli-build/server/app/api/proxy-pools/[id]/test/route.js.nft.json +1 -1
  334. package/app/.next-cli-build/server/app/api/proxy-pools/cloudflare-deploy/route.js +1 -1
  335. package/app/.next-cli-build/server/app/api/proxy-pools/cloudflare-deploy/route.js.nft.json +1 -1
  336. package/app/.next-cli-build/server/app/api/proxy-pools/deno-deploy/route.js +1 -1
  337. package/app/.next-cli-build/server/app/api/proxy-pools/deno-deploy/route.js.nft.json +1 -1
  338. package/app/.next-cli-build/server/app/api/proxy-pools/route.js +1 -1
  339. package/app/.next-cli-build/server/app/api/proxy-pools/route.js.nft.json +1 -1
  340. package/app/.next-cli-build/server/app/api/proxy-pools/vercel-deploy/route.js +1 -1
  341. package/app/.next-cli-build/server/app/api/proxy-pools/vercel-deploy/route.js.nft.json +1 -1
  342. package/app/.next-cli-build/server/app/api/pxpipe/health/route.js.nft.json +1 -1
  343. package/app/.next-cli-build/server/app/api/pxpipe/install/route.js.nft.json +1 -1
  344. package/app/.next-cli-build/server/app/api/pxpipe/logs/route.js.nft.json +1 -1
  345. package/app/.next-cli-build/server/app/api/pxpipe/restart/route.js.nft.json +1 -1
  346. package/app/.next-cli-build/server/app/api/pxpipe/start/route.js +1 -1
  347. package/app/.next-cli-build/server/app/api/pxpipe/start/route.js.nft.json +1 -1
  348. package/app/.next-cli-build/server/app/api/pxpipe/stats/route.js.nft.json +1 -1
  349. package/app/.next-cli-build/server/app/api/pxpipe/status/route.js +1 -1
  350. package/app/.next-cli-build/server/app/api/pxpipe/status/route.js.nft.json +1 -1
  351. package/app/.next-cli-build/server/app/api/pxpipe/stop/route.js.nft.json +1 -1
  352. package/app/.next-cli-build/server/app/api/routing-health/route.js +1 -1
  353. package/app/.next-cli-build/server/app/api/routing-health/route.js.nft.json +1 -1
  354. package/app/.next-cli-build/server/app/api/settings/database/route.js +1 -1
  355. package/app/.next-cli-build/server/app/api/settings/database/route.js.nft.json +1 -1
  356. package/app/.next-cli-build/server/app/api/settings/proxy-test/route.js.nft.json +1 -1
  357. package/app/.next-cli-build/server/app/api/settings/require-login/route.js +1 -1
  358. package/app/.next-cli-build/server/app/api/settings/require-login/route.js.nft.json +1 -1
  359. package/app/.next-cli-build/server/app/api/settings/route.js +1 -1
  360. package/app/.next-cli-build/server/app/api/settings/route.js.nft.json +1 -1
  361. package/app/.next-cli-build/server/app/api/shutdown/route.js.nft.json +1 -1
  362. package/app/.next-cli-build/server/app/api/tags/route.js.nft.json +1 -1
  363. package/app/.next-cli-build/server/app/api/token-saver/stats/route.js +1 -1
  364. package/app/.next-cli-build/server/app/api/token-saver/stats/route.js.nft.json +1 -1
  365. package/app/.next-cli-build/server/app/api/token-saver/stream/route.js +2 -2
  366. package/app/.next-cli-build/server/app/api/token-saver/stream/route.js.nft.json +1 -1
  367. package/app/.next-cli-build/server/app/api/tool-disclosure/stats/route.js.nft.json +1 -1
  368. package/app/.next-cli-build/server/app/api/translator/console-logs/route.js +1 -1
  369. package/app/.next-cli-build/server/app/api/translator/console-logs/route.js.nft.json +1 -1
  370. package/app/.next-cli-build/server/app/api/translator/console-logs/stream/route.js +1 -1
  371. package/app/.next-cli-build/server/app/api/translator/console-logs/stream/route.js.nft.json +1 -1
  372. package/app/.next-cli-build/server/app/api/translator/load/route.js.nft.json +1 -1
  373. package/app/.next-cli-build/server/app/api/translator/save/route.js.nft.json +1 -1
  374. package/app/.next-cli-build/server/app/api/translator/send/route.js +1 -1
  375. package/app/.next-cli-build/server/app/api/translator/send/route.js.nft.json +1 -1
  376. package/app/.next-cli-build/server/app/api/translator/translate/route.js +1 -1
  377. package/app/.next-cli-build/server/app/api/translator/translate/route.js.nft.json +1 -1
  378. package/app/.next-cli-build/server/app/api/tunnel/disable/route.js +1 -1
  379. package/app/.next-cli-build/server/app/api/tunnel/disable/route.js.nft.json +1 -1
  380. package/app/.next-cli-build/server/app/api/tunnel/enable/route.js +1 -1
  381. package/app/.next-cli-build/server/app/api/tunnel/enable/route.js.nft.json +1 -1
  382. package/app/.next-cli-build/server/app/api/tunnel/status/route.js +1 -1
  383. package/app/.next-cli-build/server/app/api/tunnel/status/route.js.nft.json +1 -1
  384. package/app/.next-cli-build/server/app/api/tunnel/tailscale-check/route.js +1 -1
  385. package/app/.next-cli-build/server/app/api/tunnel/tailscale-check/route.js.nft.json +1 -1
  386. package/app/.next-cli-build/server/app/api/tunnel/tailscale-disable/route.js +1 -1
  387. package/app/.next-cli-build/server/app/api/tunnel/tailscale-disable/route.js.nft.json +1 -1
  388. package/app/.next-cli-build/server/app/api/tunnel/tailscale-enable/route.js +1 -1
  389. package/app/.next-cli-build/server/app/api/tunnel/tailscale-enable/route.js.nft.json +1 -1
  390. package/app/.next-cli-build/server/app/api/tunnel/tailscale-install/route.js +1 -1
  391. package/app/.next-cli-build/server/app/api/tunnel/tailscale-install/route.js.nft.json +1 -1
  392. package/app/.next-cli-build/server/app/api/usage/[connectionId]/claude-reset/route.js +1 -1
  393. package/app/.next-cli-build/server/app/api/usage/[connectionId]/claude-reset/route.js.nft.json +1 -1
  394. package/app/.next-cli-build/server/app/api/usage/[connectionId]/codex-reset-credits/route.js +1 -1
  395. package/app/.next-cli-build/server/app/api/usage/[connectionId]/codex-reset-credits/route.js.nft.json +1 -1
  396. package/app/.next-cli-build/server/app/api/usage/[connectionId]/route.js +1 -1
  397. package/app/.next-cli-build/server/app/api/usage/[connectionId]/route.js.nft.json +1 -1
  398. package/app/.next-cli-build/server/app/api/usage/chart/route.js +1 -1
  399. package/app/.next-cli-build/server/app/api/usage/chart/route.js.nft.json +1 -1
  400. package/app/.next-cli-build/server/app/api/usage/error-logs/route.js.nft.json +1 -1
  401. package/app/.next-cli-build/server/app/api/usage/history/route.js +1 -1
  402. package/app/.next-cli-build/server/app/api/usage/history/route.js.nft.json +1 -1
  403. package/app/.next-cli-build/server/app/api/usage/logs/route.js +1 -1
  404. package/app/.next-cli-build/server/app/api/usage/logs/route.js.nft.json +1 -1
  405. package/app/.next-cli-build/server/app/api/usage/providers/route.js +1 -1
  406. package/app/.next-cli-build/server/app/api/usage/providers/route.js.nft.json +1 -1
  407. package/app/.next-cli-build/server/app/api/usage/request-details/route.js +1 -1
  408. package/app/.next-cli-build/server/app/api/usage/request-details/route.js.nft.json +1 -1
  409. package/app/.next-cli-build/server/app/api/usage/request-logs/route.js +1 -1
  410. package/app/.next-cli-build/server/app/api/usage/request-logs/route.js.nft.json +1 -1
  411. package/app/.next-cli-build/server/app/api/usage/stats/route.js +1 -1
  412. package/app/.next-cli-build/server/app/api/usage/stats/route.js.nft.json +1 -1
  413. package/app/.next-cli-build/server/app/api/usage/stream/route.js +1 -1
  414. package/app/.next-cli-build/server/app/api/usage/stream/route.js.nft.json +1 -1
  415. package/app/.next-cli-build/server/app/api/v1/alpha/search/route.js +1 -1
  416. package/app/.next-cli-build/server/app/api/v1/alpha/search/route.js.nft.json +1 -1
  417. package/app/.next-cli-build/server/app/api/v1/api/chat/route.js +1 -1
  418. package/app/.next-cli-build/server/app/api/v1/api/chat/route.js.nft.json +1 -1
  419. package/app/.next-cli-build/server/app/api/v1/audio/speech/route.js +1 -1
  420. package/app/.next-cli-build/server/app/api/v1/audio/speech/route.js.nft.json +1 -1
  421. package/app/.next-cli-build/server/app/api/v1/audio/transcriptions/route.js +1 -1
  422. package/app/.next-cli-build/server/app/api/v1/audio/transcriptions/route.js.nft.json +1 -1
  423. package/app/.next-cli-build/server/app/api/v1/audio/voices/route.js.nft.json +1 -1
  424. package/app/.next-cli-build/server/app/api/v1/chat/completions/route.js +1 -1
  425. package/app/.next-cli-build/server/app/api/v1/chat/completions/route.js.nft.json +1 -1
  426. package/app/.next-cli-build/server/app/api/v1/codex/alpha/search/route.js +1 -1
  427. package/app/.next-cli-build/server/app/api/v1/codex/alpha/search/route.js.nft.json +1 -1
  428. package/app/.next-cli-build/server/app/api/v1/codex/images/edits/route.js +1 -1
  429. package/app/.next-cli-build/server/app/api/v1/codex/images/edits/route.js.nft.json +1 -1
  430. package/app/.next-cli-build/server/app/api/v1/codex/images/generations/route.js +1 -1
  431. package/app/.next-cli-build/server/app/api/v1/codex/images/generations/route.js.nft.json +1 -1
  432. package/app/.next-cli-build/server/app/api/v1/codex/memories/trace_summarize/route.js +1 -1
  433. package/app/.next-cli-build/server/app/api/v1/codex/memories/trace_summarize/route.js.nft.json +1 -1
  434. package/app/.next-cli-build/server/app/api/v1/codex/models/route.js +1 -1
  435. package/app/.next-cli-build/server/app/api/v1/codex/models/route.js.nft.json +1 -1
  436. package/app/.next-cli-build/server/app/api/v1/codex/responses/compact/route.js +1 -1
  437. package/app/.next-cli-build/server/app/api/v1/codex/responses/compact/route.js.nft.json +1 -1
  438. package/app/.next-cli-build/server/app/api/v1/codex/responses/route.js +1 -1
  439. package/app/.next-cli-build/server/app/api/v1/codex/responses/route.js.nft.json +1 -1
  440. package/app/.next-cli-build/server/app/api/v1/embeddings/route.js +1 -1
  441. package/app/.next-cli-build/server/app/api/v1/embeddings/route.js.nft.json +1 -1
  442. package/app/.next-cli-build/server/app/api/v1/images/generations/route.js +3 -3
  443. package/app/.next-cli-build/server/app/api/v1/images/generations/route.js.nft.json +1 -1
  444. package/app/.next-cli-build/server/app/api/v1/messages/count_tokens/route.js.nft.json +1 -1
  445. package/app/.next-cli-build/server/app/api/v1/messages/route.js +1 -1
  446. package/app/.next-cli-build/server/app/api/v1/messages/route.js.nft.json +1 -1
  447. package/app/.next-cli-build/server/app/api/v1/models/[...model]/route.js +1 -1
  448. package/app/.next-cli-build/server/app/api/v1/models/[...model]/route.js.nft.json +1 -1
  449. package/app/.next-cli-build/server/app/api/v1/models/info/route.js +1 -1
  450. package/app/.next-cli-build/server/app/api/v1/models/info/route.js.nft.json +1 -1
  451. package/app/.next-cli-build/server/app/api/v1/models/route.js +1 -1
  452. package/app/.next-cli-build/server/app/api/v1/models/route.js.nft.json +1 -1
  453. package/app/.next-cli-build/server/app/api/v1/responses/compact/route.js +1 -1
  454. package/app/.next-cli-build/server/app/api/v1/responses/compact/route.js.nft.json +1 -1
  455. package/app/.next-cli-build/server/app/api/v1/responses/route.js +1 -1
  456. package/app/.next-cli-build/server/app/api/v1/responses/route.js.nft.json +1 -1
  457. package/app/.next-cli-build/server/app/api/v1/route.js +1 -1
  458. package/app/.next-cli-build/server/app/api/v1/route.js.nft.json +1 -1
  459. package/app/.next-cli-build/server/app/api/v1/search/route.js +1 -1
  460. package/app/.next-cli-build/server/app/api/v1/search/route.js.nft.json +1 -1
  461. package/app/.next-cli-build/server/app/api/v1/systemone/route.js +1 -1
  462. package/app/.next-cli-build/server/app/api/v1/systemone/route.js.nft.json +1 -1
  463. package/app/.next-cli-build/server/app/api/v1/videos/[id]/route.js +1 -1
  464. package/app/.next-cli-build/server/app/api/v1/videos/[id]/route.js.nft.json +1 -1
  465. package/app/.next-cli-build/server/app/api/v1/videos/edits/route.js +1 -1
  466. package/app/.next-cli-build/server/app/api/v1/videos/edits/route.js.nft.json +1 -1
  467. package/app/.next-cli-build/server/app/api/v1/videos/extensions/route.js +1 -1
  468. package/app/.next-cli-build/server/app/api/v1/videos/extensions/route.js.nft.json +1 -1
  469. package/app/.next-cli-build/server/app/api/v1/videos/generations/route.js +1 -1
  470. package/app/.next-cli-build/server/app/api/v1/videos/generations/route.js.nft.json +1 -1
  471. package/app/.next-cli-build/server/app/api/v1/web/fetch/route.js +1 -1
  472. package/app/.next-cli-build/server/app/api/v1/web/fetch/route.js.nft.json +1 -1
  473. package/app/.next-cli-build/server/app/api/v1beta/models/[...path]/route.js +1 -1
  474. package/app/.next-cli-build/server/app/api/v1beta/models/[...path]/route.js.nft.json +1 -1
  475. package/app/.next-cli-build/server/app/api/v1beta/models/route.js +1 -1
  476. package/app/.next-cli-build/server/app/api/v1beta/models/route.js.nft.json +1 -1
  477. package/app/.next-cli-build/server/app/api/version/route.js +1 -1
  478. package/app/.next-cli-build/server/app/api/version/route.js.nft.json +1 -1
  479. package/app/.next-cli-build/server/app/api/version/shutdown/route.js.nft.json +1 -1
  480. package/app/.next-cli-build/server/app/api/version/update/route.js.nft.json +1 -1
  481. package/app/.next-cli-build/server/app/callback/page.js +1 -1
  482. package/app/.next-cli-build/server/app/callback/page.js.nft.json +1 -1
  483. package/app/.next-cli-build/server/app/callback/page_client-reference-manifest.js +1 -1
  484. package/app/.next-cli-build/server/app/callback.html +1 -1
  485. package/app/.next-cli-build/server/app/callback.rsc +3 -3
  486. package/app/.next-cli-build/server/app/callback.segments/_full.segment.rsc +3 -3
  487. package/app/.next-cli-build/server/app/callback.segments/_head.segment.rsc +1 -1
  488. package/app/.next-cli-build/server/app/callback.segments/_index.segment.rsc +3 -3
  489. package/app/.next-cli-build/server/app/callback.segments/_tree.segment.rsc +1 -1
  490. package/app/.next-cli-build/server/app/callback.segments/callback/__PAGE__.segment.rsc +1 -1
  491. package/app/.next-cli-build/server/app/callback.segments/callback.segment.rsc +1 -1
  492. package/app/.next-cli-build/server/app/dashboard/basic-chat.html +1 -1
  493. package/app/.next-cli-build/server/app/dashboard/basic-chat.rsc +5 -5
  494. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk/dashboard/basic-chat/__PAGE__.segment.rsc +2 -2
  495. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk/dashboard/basic-chat.segment.rsc +1 -1
  496. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  497. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  498. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_full.segment.rsc +5 -5
  499. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_head.segment.rsc +1 -1
  500. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_index.segment.rsc +3 -3
  501. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_tree.segment.rsc +1 -1
  502. package/app/.next-cli-build/server/app/dashboard/cli-tools.html +1 -1
  503. package/app/.next-cli-build/server/app/dashboard/cli-tools.rsc +5 -5
  504. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk/dashboard/cli-tools/__PAGE__.segment.rsc +2 -2
  505. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk/dashboard/cli-tools.segment.rsc +1 -1
  506. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  507. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  508. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_full.segment.rsc +5 -5
  509. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_head.segment.rsc +1 -1
  510. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_index.segment.rsc +3 -3
  511. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_tree.segment.rsc +1 -1
  512. package/app/.next-cli-build/server/app/dashboard/combos.html +1 -1
  513. package/app/.next-cli-build/server/app/dashboard/combos.rsc +5 -5
  514. package/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk/dashboard/combos/__PAGE__.segment.rsc +2 -2
  515. package/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk/dashboard/combos.segment.rsc +1 -1
  516. package/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  517. package/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  518. package/app/.next-cli-build/server/app/dashboard/combos.segments/_full.segment.rsc +5 -5
  519. package/app/.next-cli-build/server/app/dashboard/combos.segments/_head.segment.rsc +1 -1
  520. package/app/.next-cli-build/server/app/dashboard/combos.segments/_index.segment.rsc +3 -3
  521. package/app/.next-cli-build/server/app/dashboard/combos.segments/_tree.segment.rsc +1 -1
  522. package/app/.next-cli-build/server/app/dashboard/convoy.html +1 -1
  523. package/app/.next-cli-build/server/app/dashboard/convoy.rsc +5 -5
  524. package/app/.next-cli-build/server/app/dashboard/convoy.segments/!KGRhc2hib2FyZCk/dashboard/convoy/__PAGE__.segment.rsc +2 -2
  525. package/app/.next-cli-build/server/app/dashboard/convoy.segments/!KGRhc2hib2FyZCk/dashboard/convoy.segment.rsc +1 -1
  526. package/app/.next-cli-build/server/app/dashboard/convoy.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  527. package/app/.next-cli-build/server/app/dashboard/convoy.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  528. package/app/.next-cli-build/server/app/dashboard/convoy.segments/_full.segment.rsc +5 -5
  529. package/app/.next-cli-build/server/app/dashboard/convoy.segments/_head.segment.rsc +1 -1
  530. package/app/.next-cli-build/server/app/dashboard/convoy.segments/_index.segment.rsc +3 -3
  531. package/app/.next-cli-build/server/app/dashboard/convoy.segments/_tree.segment.rsc +1 -1
  532. package/app/.next-cli-build/server/app/dashboard/endpoint.html +1 -1
  533. package/app/.next-cli-build/server/app/dashboard/endpoint.rsc +5 -5
  534. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk/dashboard/endpoint/__PAGE__.segment.rsc +2 -2
  535. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk/dashboard/endpoint.segment.rsc +1 -1
  536. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  537. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  538. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_full.segment.rsc +5 -5
  539. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_head.segment.rsc +1 -1
  540. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_index.segment.rsc +3 -3
  541. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_tree.segment.rsc +1 -1
  542. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/keys.html +1 -1
  543. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/keys.rsc +5 -5
  544. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/keys.segments/!KGRhc2hib2FyZCk/dashboard/mcp-gateway/keys/__PAGE__.segment.rsc +2 -2
  545. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/keys.segments/!KGRhc2hib2FyZCk/dashboard/mcp-gateway/keys.segment.rsc +1 -1
  546. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/keys.segments/!KGRhc2hib2FyZCk/dashboard/mcp-gateway.segment.rsc +1 -1
  547. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/keys.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  548. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/keys.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  549. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/keys.segments/_full.segment.rsc +5 -5
  550. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/keys.segments/_head.segment.rsc +1 -1
  551. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/keys.segments/_index.segment.rsc +3 -3
  552. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/keys.segments/_tree.segment.rsc +1 -1
  553. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/servers.html +1 -1
  554. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/servers.rsc +5 -5
  555. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/servers.segments/!KGRhc2hib2FyZCk/dashboard/mcp-gateway/servers/__PAGE__.segment.rsc +2 -2
  556. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/servers.segments/!KGRhc2hib2FyZCk/dashboard/mcp-gateway/servers.segment.rsc +1 -1
  557. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/servers.segments/!KGRhc2hib2FyZCk/dashboard/mcp-gateway.segment.rsc +1 -1
  558. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/servers.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  559. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/servers.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  560. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/servers.segments/_full.segment.rsc +5 -5
  561. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/servers.segments/_head.segment.rsc +1 -1
  562. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/servers.segments/_index.segment.rsc +3 -3
  563. package/app/.next-cli-build/server/app/dashboard/mcp-gateway/servers.segments/_tree.segment.rsc +1 -1
  564. package/app/.next-cli-build/server/app/dashboard/mcp-gateway.html +1 -1
  565. package/app/.next-cli-build/server/app/dashboard/mcp-gateway.rsc +5 -5
  566. package/app/.next-cli-build/server/app/dashboard/mcp-gateway.segments/!KGRhc2hib2FyZCk/dashboard/mcp-gateway/__PAGE__.segment.rsc +2 -2
  567. package/app/.next-cli-build/server/app/dashboard/mcp-gateway.segments/!KGRhc2hib2FyZCk/dashboard/mcp-gateway.segment.rsc +1 -1
  568. package/app/.next-cli-build/server/app/dashboard/mcp-gateway.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  569. package/app/.next-cli-build/server/app/dashboard/mcp-gateway.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  570. package/app/.next-cli-build/server/app/dashboard/mcp-gateway.segments/_full.segment.rsc +5 -5
  571. package/app/.next-cli-build/server/app/dashboard/mcp-gateway.segments/_head.segment.rsc +1 -1
  572. package/app/.next-cli-build/server/app/dashboard/mcp-gateway.segments/_index.segment.rsc +3 -3
  573. package/app/.next-cli-build/server/app/dashboard/mcp-gateway.segments/_tree.segment.rsc +1 -1
  574. package/app/.next-cli-build/server/app/dashboard/media-providers/web.html +1 -1
  575. package/app/.next-cli-build/server/app/dashboard/media-providers/web.rsc +5 -5
  576. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard/media-providers/web/__PAGE__.segment.rsc +2 -2
  577. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard/media-providers/web.segment.rsc +1 -1
  578. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard/media-providers.segment.rsc +1 -1
  579. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  580. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  581. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_full.segment.rsc +5 -5
  582. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_head.segment.rsc +1 -1
  583. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_index.segment.rsc +3 -3
  584. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_tree.segment.rsc +1 -1
  585. package/app/.next-cli-build/server/app/dashboard/mitm.html +1 -1
  586. package/app/.next-cli-build/server/app/dashboard/mitm.rsc +5 -5
  587. package/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk/dashboard/mitm/__PAGE__.segment.rsc +2 -2
  588. package/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk/dashboard/mitm.segment.rsc +1 -1
  589. package/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  590. package/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  591. package/app/.next-cli-build/server/app/dashboard/mitm.segments/_full.segment.rsc +5 -5
  592. package/app/.next-cli-build/server/app/dashboard/mitm.segments/_head.segment.rsc +1 -1
  593. package/app/.next-cli-build/server/app/dashboard/mitm.segments/_index.segment.rsc +3 -3
  594. package/app/.next-cli-build/server/app/dashboard/mitm.segments/_tree.segment.rsc +1 -1
  595. package/app/.next-cli-build/server/app/dashboard/profile.html +1 -1
  596. package/app/.next-cli-build/server/app/dashboard/profile.rsc +5 -5
  597. package/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk/dashboard/profile/__PAGE__.segment.rsc +2 -2
  598. package/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk/dashboard/profile.segment.rsc +1 -1
  599. package/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  600. package/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  601. package/app/.next-cli-build/server/app/dashboard/profile.segments/_full.segment.rsc +5 -5
  602. package/app/.next-cli-build/server/app/dashboard/profile.segments/_head.segment.rsc +1 -1
  603. package/app/.next-cli-build/server/app/dashboard/profile.segments/_index.segment.rsc +3 -3
  604. package/app/.next-cli-build/server/app/dashboard/profile.segments/_tree.segment.rsc +1 -1
  605. package/app/.next-cli-build/server/app/dashboard/providers/new.html +1 -1
  606. package/app/.next-cli-build/server/app/dashboard/providers/new.rsc +5 -5
  607. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard/providers/new/__PAGE__.segment.rsc +2 -2
  608. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard/providers/new.segment.rsc +1 -1
  609. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard/providers.segment.rsc +1 -1
  610. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  611. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  612. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_full.segment.rsc +5 -5
  613. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_head.segment.rsc +1 -1
  614. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_index.segment.rsc +3 -3
  615. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_tree.segment.rsc +1 -1
  616. package/app/.next-cli-build/server/app/dashboard/providers.html +1 -1
  617. package/app/.next-cli-build/server/app/dashboard/providers.rsc +5 -5
  618. package/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk/dashboard/providers/__PAGE__.segment.rsc +2 -2
  619. package/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk/dashboard/providers.segment.rsc +1 -1
  620. package/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  621. package/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  622. package/app/.next-cli-build/server/app/dashboard/providers.segments/_full.segment.rsc +5 -5
  623. package/app/.next-cli-build/server/app/dashboard/providers.segments/_head.segment.rsc +1 -1
  624. package/app/.next-cli-build/server/app/dashboard/providers.segments/_index.segment.rsc +3 -3
  625. package/app/.next-cli-build/server/app/dashboard/providers.segments/_tree.segment.rsc +1 -1
  626. package/app/.next-cli-build/server/app/dashboard/proxy-pools.html +1 -1
  627. package/app/.next-cli-build/server/app/dashboard/proxy-pools.rsc +5 -5
  628. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk/dashboard/proxy-pools/__PAGE__.segment.rsc +2 -2
  629. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk/dashboard/proxy-pools.segment.rsc +1 -1
  630. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  631. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  632. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_full.segment.rsc +5 -5
  633. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_head.segment.rsc +1 -1
  634. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_index.segment.rsc +3 -3
  635. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_tree.segment.rsc +1 -1
  636. package/app/.next-cli-build/server/app/dashboard/pxpipe.html +1 -1
  637. package/app/.next-cli-build/server/app/dashboard/pxpipe.rsc +5 -5
  638. package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/!KGRhc2hib2FyZCk/dashboard/pxpipe/__PAGE__.segment.rsc +2 -2
  639. package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/!KGRhc2hib2FyZCk/dashboard/pxpipe.segment.rsc +1 -1
  640. package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  641. package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  642. package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/_full.segment.rsc +5 -5
  643. package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/_head.segment.rsc +1 -1
  644. package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/_index.segment.rsc +3 -3
  645. package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/_tree.segment.rsc +1 -1
  646. package/app/.next-cli-build/server/app/dashboard/quota.html +1 -1
  647. package/app/.next-cli-build/server/app/dashboard/quota.rsc +6 -6
  648. package/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk/dashboard/quota/__PAGE__.segment.rsc +3 -3
  649. package/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk/dashboard/quota.segment.rsc +1 -1
  650. package/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  651. package/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  652. package/app/.next-cli-build/server/app/dashboard/quota.segments/_full.segment.rsc +6 -6
  653. package/app/.next-cli-build/server/app/dashboard/quota.segments/_head.segment.rsc +1 -1
  654. package/app/.next-cli-build/server/app/dashboard/quota.segments/_index.segment.rsc +3 -3
  655. package/app/.next-cli-build/server/app/dashboard/quota.segments/_tree.segment.rsc +1 -1
  656. package/app/.next-cli-build/server/app/dashboard/routing-health.html +1 -1
  657. package/app/.next-cli-build/server/app/dashboard/routing-health.rsc +5 -5
  658. package/app/.next-cli-build/server/app/dashboard/routing-health.segments/!KGRhc2hib2FyZCk/dashboard/routing-health/__PAGE__.segment.rsc +2 -2
  659. package/app/.next-cli-build/server/app/dashboard/routing-health.segments/!KGRhc2hib2FyZCk/dashboard/routing-health.segment.rsc +1 -1
  660. package/app/.next-cli-build/server/app/dashboard/routing-health.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  661. package/app/.next-cli-build/server/app/dashboard/routing-health.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  662. package/app/.next-cli-build/server/app/dashboard/routing-health.segments/_full.segment.rsc +5 -5
  663. package/app/.next-cli-build/server/app/dashboard/routing-health.segments/_head.segment.rsc +1 -1
  664. package/app/.next-cli-build/server/app/dashboard/routing-health.segments/_index.segment.rsc +3 -3
  665. package/app/.next-cli-build/server/app/dashboard/routing-health.segments/_tree.segment.rsc +1 -1
  666. package/app/.next-cli-build/server/app/dashboard/settings/pricing/page.js +1 -1
  667. package/app/.next-cli-build/server/app/dashboard/settings/pricing/page.js.nft.json +1 -1
  668. package/app/.next-cli-build/server/app/dashboard/settings/pricing/page_client-reference-manifest.js +1 -1
  669. package/app/.next-cli-build/server/app/dashboard/settings/pricing.html +1 -1
  670. package/app/.next-cli-build/server/app/dashboard/settings/pricing.rsc +3 -3
  671. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_full.segment.rsc +3 -3
  672. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_head.segment.rsc +1 -1
  673. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_index.segment.rsc +3 -3
  674. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_tree.segment.rsc +1 -1
  675. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/dashboard/settings/pricing/__PAGE__.segment.rsc +1 -1
  676. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/dashboard/settings/pricing.segment.rsc +1 -1
  677. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/dashboard/settings.segment.rsc +1 -1
  678. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/dashboard.segment.rsc +1 -1
  679. package/app/.next-cli-build/server/app/dashboard/skills.html +1 -1
  680. package/app/.next-cli-build/server/app/dashboard/skills.rsc +5 -5
  681. package/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk/dashboard/skills/__PAGE__.segment.rsc +2 -2
  682. package/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk/dashboard/skills.segment.rsc +1 -1
  683. package/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  684. package/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  685. package/app/.next-cli-build/server/app/dashboard/skills.segments/_full.segment.rsc +5 -5
  686. package/app/.next-cli-build/server/app/dashboard/skills.segments/_head.segment.rsc +1 -1
  687. package/app/.next-cli-build/server/app/dashboard/skills.segments/_index.segment.rsc +3 -3
  688. package/app/.next-cli-build/server/app/dashboard/skills.segments/_tree.segment.rsc +1 -1
  689. package/app/.next-cli-build/server/app/dashboard/token-saver.html +1 -1
  690. package/app/.next-cli-build/server/app/dashboard/token-saver.rsc +5 -5
  691. package/app/.next-cli-build/server/app/dashboard/token-saver.segments/!KGRhc2hib2FyZCk/dashboard/token-saver/__PAGE__.segment.rsc +2 -2
  692. package/app/.next-cli-build/server/app/dashboard/token-saver.segments/!KGRhc2hib2FyZCk/dashboard/token-saver.segment.rsc +1 -1
  693. package/app/.next-cli-build/server/app/dashboard/token-saver.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  694. package/app/.next-cli-build/server/app/dashboard/token-saver.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  695. package/app/.next-cli-build/server/app/dashboard/token-saver.segments/_full.segment.rsc +5 -5
  696. package/app/.next-cli-build/server/app/dashboard/token-saver.segments/_head.segment.rsc +1 -1
  697. package/app/.next-cli-build/server/app/dashboard/token-saver.segments/_index.segment.rsc +3 -3
  698. package/app/.next-cli-build/server/app/dashboard/token-saver.segments/_tree.segment.rsc +1 -1
  699. package/app/.next-cli-build/server/app/dashboard/translator.html +1 -1
  700. package/app/.next-cli-build/server/app/dashboard/translator.rsc +5 -5
  701. package/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk/dashboard/translator/__PAGE__.segment.rsc +2 -2
  702. package/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk/dashboard/translator.segment.rsc +1 -1
  703. package/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  704. package/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  705. package/app/.next-cli-build/server/app/dashboard/translator.segments/_full.segment.rsc +5 -5
  706. package/app/.next-cli-build/server/app/dashboard/translator.segments/_head.segment.rsc +1 -1
  707. package/app/.next-cli-build/server/app/dashboard/translator.segments/_index.segment.rsc +3 -3
  708. package/app/.next-cli-build/server/app/dashboard/translator.segments/_tree.segment.rsc +1 -1
  709. package/app/.next-cli-build/server/app/dashboard/usage.html +1 -1
  710. package/app/.next-cli-build/server/app/dashboard/usage.rsc +5 -5
  711. package/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk/dashboard/usage/__PAGE__.segment.rsc +2 -2
  712. package/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk/dashboard/usage.segment.rsc +1 -1
  713. package/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  714. package/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  715. package/app/.next-cli-build/server/app/dashboard/usage.segments/_full.segment.rsc +5 -5
  716. package/app/.next-cli-build/server/app/dashboard/usage.segments/_head.segment.rsc +1 -1
  717. package/app/.next-cli-build/server/app/dashboard/usage.segments/_index.segment.rsc +3 -3
  718. package/app/.next-cli-build/server/app/dashboard/usage.segments/_tree.segment.rsc +1 -1
  719. package/app/.next-cli-build/server/app/dashboard.html +1 -1
  720. package/app/.next-cli-build/server/app/dashboard.rsc +5 -5
  721. package/app/.next-cli-build/server/app/dashboard.segments/!KGRhc2hib2FyZCk/dashboard/__PAGE__.segment.rsc +2 -2
  722. package/app/.next-cli-build/server/app/dashboard.segments/!KGRhc2hib2FyZCk/dashboard.segment.rsc +1 -1
  723. package/app/.next-cli-build/server/app/dashboard.segments/!KGRhc2hib2FyZCk.segment.rsc +2 -2
  724. package/app/.next-cli-build/server/app/dashboard.segments/_full.segment.rsc +5 -5
  725. package/app/.next-cli-build/server/app/dashboard.segments/_head.segment.rsc +1 -1
  726. package/app/.next-cli-build/server/app/dashboard.segments/_index.segment.rsc +3 -3
  727. package/app/.next-cli-build/server/app/dashboard.segments/_tree.segment.rsc +1 -1
  728. package/app/.next-cli-build/server/app/favicon.ico/route.js.nft.json +1 -1
  729. package/app/.next-cli-build/server/app/index.html +1 -1
  730. package/app/.next-cli-build/server/app/index.rsc +3 -3
  731. package/app/.next-cli-build/server/app/index.segments/__PAGE__.segment.rsc +1 -1
  732. package/app/.next-cli-build/server/app/index.segments/_full.segment.rsc +3 -3
  733. package/app/.next-cli-build/server/app/index.segments/_head.segment.rsc +1 -1
  734. package/app/.next-cli-build/server/app/index.segments/_index.segment.rsc +3 -3
  735. package/app/.next-cli-build/server/app/index.segments/_tree.segment.rsc +1 -1
  736. package/app/.next-cli-build/server/app/landing/page.js +1 -1
  737. package/app/.next-cli-build/server/app/landing/page.js.nft.json +1 -1
  738. package/app/.next-cli-build/server/app/landing/page_client-reference-manifest.js +1 -1
  739. package/app/.next-cli-build/server/app/landing.html +1 -1
  740. package/app/.next-cli-build/server/app/landing.rsc +3 -3
  741. package/app/.next-cli-build/server/app/landing.segments/_full.segment.rsc +3 -3
  742. package/app/.next-cli-build/server/app/landing.segments/_head.segment.rsc +1 -1
  743. package/app/.next-cli-build/server/app/landing.segments/_index.segment.rsc +3 -3
  744. package/app/.next-cli-build/server/app/landing.segments/_tree.segment.rsc +1 -1
  745. package/app/.next-cli-build/server/app/landing.segments/landing/__PAGE__.segment.rsc +1 -1
  746. package/app/.next-cli-build/server/app/landing.segments/landing.segment.rsc +1 -1
  747. package/app/.next-cli-build/server/app/login/page.js +1 -1
  748. package/app/.next-cli-build/server/app/login/page.js.nft.json +1 -1
  749. package/app/.next-cli-build/server/app/login/page_client-reference-manifest.js +1 -1
  750. package/app/.next-cli-build/server/app/login.html +1 -1
  751. package/app/.next-cli-build/server/app/login.rsc +4 -4
  752. package/app/.next-cli-build/server/app/login.segments/_full.segment.rsc +4 -4
  753. package/app/.next-cli-build/server/app/login.segments/_head.segment.rsc +1 -1
  754. package/app/.next-cli-build/server/app/login.segments/_index.segment.rsc +3 -3
  755. package/app/.next-cli-build/server/app/login.segments/_tree.segment.rsc +1 -1
  756. package/app/.next-cli-build/server/app/login.segments/login/__PAGE__.segment.rsc +2 -2
  757. package/app/.next-cli-build/server/app/login.segments/login.segment.rsc +1 -1
  758. package/app/.next-cli-build/server/app/manifest.webmanifest/route.js.nft.json +1 -1
  759. package/app/.next-cli-build/server/app/page.js +1 -1
  760. package/app/.next-cli-build/server/app/page.js.nft.json +1 -1
  761. package/app/.next-cli-build/server/app/page_client-reference-manifest.js +1 -1
  762. package/app/.next-cli-build/server/app-paths-manifest.json +27 -27
  763. package/app/.next-cli-build/server/chunks/1253.js +1 -1
  764. package/app/.next-cli-build/server/chunks/1482.js +4 -2
  765. package/app/.next-cli-build/server/chunks/1531.js +1 -1
  766. package/app/.next-cli-build/server/chunks/1641.js +1 -0
  767. package/app/.next-cli-build/server/chunks/1733.js +1 -1
  768. package/app/.next-cli-build/server/chunks/1847.js +1 -1
  769. package/app/.next-cli-build/server/chunks/2269.js +1 -1
  770. package/app/.next-cli-build/server/chunks/2348.js +1 -1
  771. package/app/.next-cli-build/server/chunks/2898.js +1 -1
  772. package/app/.next-cli-build/server/chunks/3583.js +2 -2
  773. package/app/.next-cli-build/server/chunks/3593.js +2 -2
  774. package/app/.next-cli-build/server/chunks/369.js +22 -22
  775. package/app/.next-cli-build/server/chunks/3886.js +1 -1
  776. package/app/.next-cli-build/server/chunks/3912.js +1 -1
  777. package/app/.next-cli-build/server/chunks/3977.js +2 -2
  778. package/app/.next-cli-build/server/chunks/412.js +1 -1
  779. package/app/.next-cli-build/server/chunks/4378.js +3 -3
  780. package/app/.next-cli-build/server/chunks/4485.js +1 -1
  781. package/app/.next-cli-build/server/chunks/4574.js +1 -1
  782. package/app/.next-cli-build/server/chunks/4646.js +1 -1
  783. package/app/.next-cli-build/server/chunks/4704.js +2 -2
  784. package/app/.next-cli-build/server/chunks/4739.js +2 -2
  785. package/app/.next-cli-build/server/chunks/4768.js +1 -1
  786. package/app/.next-cli-build/server/chunks/4780.js +2 -2
  787. package/app/.next-cli-build/server/chunks/4803.js +2 -2
  788. package/app/.next-cli-build/server/chunks/4827.js +1 -1
  789. package/app/.next-cli-build/server/chunks/4878.js +1 -1
  790. package/app/.next-cli-build/server/chunks/5011.js +1 -1
  791. package/app/.next-cli-build/server/chunks/507.js +2 -2
  792. package/app/.next-cli-build/server/chunks/5130.js +1 -1
  793. package/app/.next-cli-build/server/chunks/{8421.js → 5251.js} +1 -1
  794. package/app/.next-cli-build/server/chunks/5258.js +2 -2
  795. package/app/.next-cli-build/server/chunks/5434.js +1 -1
  796. package/app/.next-cli-build/server/chunks/5460.js +40 -0
  797. package/app/.next-cli-build/server/chunks/5704.js +254 -0
  798. package/app/.next-cli-build/server/chunks/5872.js +1 -0
  799. package/app/.next-cli-build/server/chunks/5875.js +1 -1
  800. package/app/.next-cli-build/server/chunks/6252.js +2 -2
  801. package/app/.next-cli-build/server/chunks/6420.js +1 -1
  802. package/app/.next-cli-build/server/chunks/6670.js +2 -2
  803. package/app/.next-cli-build/server/chunks/6769.js +1 -0
  804. package/app/.next-cli-build/server/chunks/6799.js +2 -2
  805. package/app/.next-cli-build/server/chunks/698.js +2 -2
  806. package/app/.next-cli-build/server/chunks/7073.js +2 -2
  807. package/app/.next-cli-build/server/chunks/7218.js +1 -1
  808. package/app/.next-cli-build/server/chunks/7239.js +2 -2
  809. package/app/.next-cli-build/server/chunks/7362.js +1 -1
  810. package/app/.next-cli-build/server/chunks/7594.js +6 -6
  811. package/app/.next-cli-build/server/chunks/7663.js +1 -1
  812. package/app/.next-cli-build/server/chunks/7677.js +1 -1
  813. package/app/.next-cli-build/server/chunks/7775.js +1 -1
  814. package/app/.next-cli-build/server/chunks/7811.js +1 -0
  815. package/app/.next-cli-build/server/chunks/7965.js +2 -2
  816. package/app/.next-cli-build/server/chunks/8062.js +2 -2
  817. package/app/.next-cli-build/server/chunks/8129.js +1 -1
  818. package/app/.next-cli-build/server/chunks/8231.js +1 -1
  819. package/app/.next-cli-build/server/chunks/8243.js +5 -5
  820. package/app/.next-cli-build/server/chunks/8306.js +1 -1
  821. package/app/.next-cli-build/server/chunks/8469.js +2 -2
  822. package/app/.next-cli-build/server/chunks/8520.js +2 -2
  823. package/app/.next-cli-build/server/chunks/8644.js +1 -1
  824. package/app/.next-cli-build/server/chunks/8772.js +1 -1
  825. package/app/.next-cli-build/server/chunks/8976.js +1 -1
  826. package/app/.next-cli-build/server/chunks/9026.js +24 -24
  827. package/app/.next-cli-build/server/chunks/9062.js +1 -1
  828. package/app/.next-cli-build/server/chunks/9303.js +1 -1
  829. package/app/.next-cli-build/server/chunks/9485.js +1 -1
  830. package/app/.next-cli-build/server/chunks/9718.js +1 -1
  831. package/app/.next-cli-build/server/instrumentation.js +1 -1
  832. package/app/.next-cli-build/server/middleware-build-manifest.js +1 -1
  833. package/app/.next-cli-build/server/middleware.js +3 -3
  834. package/app/.next-cli-build/server/pages/404.html +1 -1
  835. package/app/.next-cli-build/server/pages/500.html +1 -1
  836. package/app/.next-cli-build/static/chunks/1321-73fdccd2b1bf151d.js +1 -0
  837. package/app/.next-cli-build/static/chunks/{5497-8766958582f95dc7.js → 5497-ff58e90f4053e184.js} +3 -3
  838. package/app/.next-cli-build/static/chunks/{6252-34f2d410651e1103.js → 6252-886aa8324e135e9c.js} +13 -13
  839. package/app/.next-cli-build/static/chunks/8105-9b41dc96e4b019cf.js +1 -0
  840. package/app/.next-cli-build/static/chunks/9227-4471c8f39a105c5f.js +5 -0
  841. package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/media-providers/[kind]/[id]/{page-89b4f70958736f2a.js → page-c35f746b4bd9fc90.js} +18 -14
  842. package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/providers/[id]/{page-fa195b4f7348e2d6.js → page-0868ecc0d2f1bd04.js} +2 -2
  843. package/app/.next-cli-build/static/chunks/app/(dashboard)/dashboard/quota/{page-a31d9ca05cc3d528.js → page-6cb070834a750fdd.js} +1 -1
  844. package/app/CHANGELOG.md +54 -32
  845. package/app/package.json +1 -1
  846. package/app/public/CHANGELOG.md +54 -32
  847. package/app/src/mitm/server.js +24 -24
  848. package/cli.js +71 -69
  849. package/package.json +1 -1
  850. package/src/cli/commands/connect.js +157 -15
  851. package/src/cli/commands/connectTools.js +222 -4
  852. package/src/cli/commands/show.js +101 -0
  853. package/src/cli/menus/providers.js +8 -0
  854. package/app/.next-cli-build/server/chunks/3252.js +0 -1
  855. package/app/.next-cli-build/server/chunks/3267.js +0 -40
  856. package/app/.next-cli-build/server/chunks/6707.js +0 -1
  857. package/app/.next-cli-build/server/chunks/8450.js +0 -254
  858. package/app/.next-cli-build/server/chunks/9143.js +0 -1
  859. package/app/.next-cli-build/static/chunks/1321-043afc56cba448b8.js +0 -1
  860. package/app/.next-cli-build/static/chunks/8105-9dfc2c5ffef6e778.js +0 -1
  861. package/app/.next-cli-build/static/chunks/9227-af65f6ac1fca28c9.js +0 -3
  862. /package/app/.next-cli-build/static/{zQapcWqcr7oLVi5jh7t01 → Y5Sk8uSUyB0vJ-ZgW1X1U}/_buildManifest.js +0 -0
  863. /package/app/.next-cli-build/static/{zQapcWqcr7oLVi5jh7t01 → Y5Sk8uSUyB0vJ-ZgW1X1U}/_ssgManifest.js +0 -0
@@ -99,7 +99,7 @@ default_model = "${J||"cc/claude-opus-4-7"}"
99
99
  requires_api_key = true
100
100
 
101
101
  [[providers.9router.models]]
102
- id = "${J||"cc/claude-opus-4-7"}"`},{filename:"~/.config/jcode/provider-9router.env",content:`JCODE_9ROUTER_API_KEY="${t}"`}])})]})}function ai({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]=(0,e.useState)(l||null),[t,v]=(0,e.useState)(!1),[w,y]=(0,e.useState)(!1),[z,A]=(0,e.useState)(!1),[B,C]=(0,e.useState)(null),[D,E]=(0,e.useState)(!1),[F,G]=(0,e.useState)(""),[H,I]=(0,e.useState)(""),[J,K]=(0,e.useState)(!1),[L,M]=(0,e.useState)({}),[N,O]=(0,e.useState)(!1),[P,Q]=(0,e.useState)(""),R=r?.installed?r.has9Router?"configured":"not_configured":null,S=()=>{let a=P||`${h}/v1`;return a.endsWith("/v1")?a:`${a}/v1`},T=async()=>{v(!0);try{let a=await fetch("/api/cli-tools/kilo-settings"),b=await a.json();s(b)}catch(a){s({installed:!1,error:a.message})}finally{v(!1)}},U=async()=>{y(!0),C(null);try{let a=F&&F.trim()||k?F:"sk_ezrouter",b=await fetch("/api/cli-tools/kilo-settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({baseUrl:S(),apiKey:a,model:H})}),c=await b.json();b.ok?(q(S(),{tunnelPublicUrl:n,tailscaleUrl:p}),C({type:"success",text:"Settings applied successfully!"}),T()):C({type:"error",text:c.error||"Failed to apply settings"})}catch(a){C({type:"error",text:a.message})}finally{y(!1)}},V=async()=>{A(!0),C(null);try{let a=await fetch("/api/cli-tools/kilo-settings",{method:"DELETE"}),b=await a.json();a.ok?(C({type:"success",text:"Settings reset successfully!"}),I(""),T()):C({type:"error",text:b.error||"Failed to reset settings"})}catch(a){C({type:"error",text:a.message})}finally{A(!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/kilocode.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"===R&&(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"===R&&(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"})]}),(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:[t&&(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 Kilo Code..."})]}),!t&&r&&!r.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:"Kilo Code 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:()=>O(!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:()=>E(!D),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[18px] mr-1",children:D?"expand_less":"help"}),D?"Hide":"How to Install"]})]})]}),D&&(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)("p",{className:"text-sm text-text-muted",children:["Install Kilo Code from ",(0,d.jsx)("a",{className:"text-primary underline",href:"https://kilocode.ai",target:"_blank",rel:"noreferrer",children:"kilocode.ai"})," or VS Code extension marketplace."]})]})]}),!t&&r?.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)(u,{value:P||P||`${h}/v1`,onChange:Q,requiresExternalUrl:a.requiresExternalUrl,tunnelEnabled:m,tunnelPublicUrl:n,tailscaleEnabled:o,tailscaleUrl:p})]}),(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)(x,{value:F,onChange:G,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:H,onChange:a=>I(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"}),H&&(0,d.jsx)("button",{onClick:()=>I(""),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:()=>K(!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"})]})]}),B&&(0,d.jsxs)("div",{className:`flex items-center gap-2 px-2 py-1.5 rounded text-xs ${"success"===B.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"===B.type?"check_circle":"error"}),(0,d.jsx)("span",{children:B.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:U,disabled:!F&&k&&i.length>0||!H,loading:w,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:V,disabled:z,loading:z,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:()=>O(!0),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"content_copy"}),"Manual Config"]})]})]})]}),J&&(0,d.jsx)(f.rq,{isOpen:J,onClose:()=>K(!1),onSelect:a=>{I(a.value),K(!1)},selectedModel:H,activeProviders:j,modelAliases:L,title:"Select Model for Kilo Code"}),(0,d.jsx)(f.uR,{isOpen:N,onClose:()=>O(!1),title:"Kilo Code - Manual Configuration",configs:[{filename:"~/.local/share/kilo/auth.json",content:JSON.stringify({"openai-compatible":{type:"api-key",apiKey:F&&F.trim()?F:k?"<API_KEY_FROM_DASHBOARD>":"sk_ezrouter",baseUrl:S(),model:H||"provider/model-id"}},null,2)}]})]})}var aj=c(2116),ak=c.n(aj);function al({tool:a}){return(0,d.jsx)(ak(),{href:"/dashboard/mitm",className:"block",children:(0,d.jsx)(f.Zp,{padding:"sm",className:"overflow-hidden hover:border-primary/50 transition-colors cursor-pointer",children:(0,d.jsxs)("div",{className:"flex items-center justify-between",children:[(0,d.jsxs)("div",{className:"flex 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:a.image,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 items-center gap-2",children:[(0,d.jsx)("h3",{className:"font-medium text-sm",children:a.name}),(0,d.jsx)("span",{className:"px-1.5 py-0.5 text-[10px] font-medium bg-purple-500/10 text-purple-600 dark:text-purple-400 rounded-full",children:"MITM"})]}),(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]",children:"chevron_right"})]})})})}let am="http://localhost:20126";function an({apiKeys:a,cloudEnabled:b,onStatusChange:c}){let[g,h]=(0,e.useState)(null),[i,j]=(0,e.useState)(!1),[k,l]=(0,e.useState)(!1),[m,n]=(0,e.useState)(""),[o,p]=(0,e.useState)(()=>a?.[0]?.key||""),[q,r]=(0,e.useState)(null),[s,t]=(0,e.useState)(null),[u,v]=(0,e.useState)(null),[w,x]=(0,e.useState)(am),[y,z]=(0,e.useState)(null),A=g?.isWin===!0,B=A||g?.hasCachedPassword||g?.needsSudoPassword===!1,C=g?.isAdmin!==!1;!C&&(A||g?.hasCachedPassword||g?.needsSudoPassword);let D=(0,e.useCallback)(async()=>{try{let a=await fetch("/api/cli-tools/antigravity-mitm");if(a.ok){let b=await a.json();h(b),b.mitmRouterBaseUrl&&x(b.mitmRouterBaseUrl),c?.(b)}}catch{h({running:!1,certExists:!1,dnsStatus:{}})}},[c]),E=a=>{v(null),g&&(B?F(a,""):(r(a),l(!0),t(null)))},F=async(c,d,e=!1)=>{j(!0),v(null);try{let f;if("trust-cert"===c)f=await fetch("/api/cli-tools/antigravity-mitm",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({action:"trust-cert",sudoPassword:d})});else if("start"===c){let c=o?.trim()||(a?.length>0?a[0].key:null)||(b?null:"sk_ezrouter");f=await fetch("/api/cli-tools/antigravity-mitm",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({apiKey:c,sudoPassword:d,mitmRouterBaseUrl:w.trim()||am,forceKillPort443:e})})}else f=await fetch("/api/cli-tools/antigravity-mitm",{method:"DELETE",headers:{"Content-Type":"application/json"},body:JSON.stringify({sudoPassword:d})});if(!f.ok){let a=await f.json().catch(()=>({}));if("PORT_443_BUSY"===a.code&&a.portOwner){l(!1),z({owner:a.portOwner,password:d});return}v(a.error||`Failed to ${c} MITM server`);return}l(!1),n(""),z(null),await D()}catch(a){v(a.message||"Network error")}finally{j(!1),r(null)}},G=()=>{m.trim()?F(q,m):t("Sudo password is required")},H=g?.running;return(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(f.Zp,{padding:"sm",className:"border-primary/20 bg-primary/5",children:(0,d.jsxs)("div",{className:"flex flex-col gap-3",children:[(0,d.jsxs)("div",{className:"flex flex-col gap-2 sm:flex-row sm:items-center sm:justify-between",children:[(0,d.jsxs)("div",{className:"flex min-w-0 flex-wrap items-center gap-2",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-primary text-[20px]",children:"security"}),(0,d.jsx)("span",{className:"font-semibold text-sm text-text-main",children:"MITM Server"}),H?(0,d.jsx)(f.Ex,{variant:"success",size:"sm",children:"Running"}):(0,d.jsx)(f.Ex,{variant:"default",size:"sm",children:"Stopped"})]}),(0,d.jsx)("div",{className:"flex flex-wrap items-center gap-1 text-xs text-text-muted","data-i18n-skip":"true",children:[{label:"Cert",ok:g?.certExists},{label:"Trusted",ok:g?.certTrusted},{label:"Server",ok:H}].map(({label:a,ok:b})=>(0,d.jsxs)("span",{className:`flex items-center gap-0.5 px-1.5 py-0.5 rounded ${b?"text-green-600":"text-text-muted"}`,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[12px]",children:b?"check_circle":"cancel"}),a]},a))})]}),(0,d.jsxs)("div",{className:"px-2 py-2 rounded-lg bg-surface/50 border border-border/50 flex flex-col gap-2",children:[(0,d.jsxs)("p",{className:"text-[11px] text-text-muted leading-relaxed",children:[(0,d.jsx)("span",{className:"font-medium text-text-main",children:"Purpose:"})," Use Antigravity IDE & GitHub Copilot → with ANY provider/model from EzRouter"]}),(0,d.jsxs)("p",{className:"text-[11px] text-text-muted leading-relaxed",children:[(0,d.jsx)("span",{className:"font-medium text-text-main",children:"How it works:"})," Antigravity/Copilot IDE request → DNS redirect to localhost:443 → MITM proxy intercepts → EzRouter → response to Antigravity/Copilot"]})]}),(0,d.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,d.jsxs)("div",{className:"grid gap-1 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:"EzRouter Base URL"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsx)("input",{type:"text",value:w,onChange:a=>x(a.target.value),placeholder:am,disabled:H,className:"flex-1 min-w-0 px-2 py-1.5 bg-surface rounded border border-border text-xs text-text-main focus:outline-none focus:ring-1 focus:ring-primary/50 disabled:opacity-50"})]}),!H&&(0,d.jsxs)("div",{className:"grid gap-1 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:"API Key"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsx)("input",{type:"text",list:"mitm-api-keys",value:o,onChange:a=>p(a.target.value),placeholder:b?"Enter or pick API key":"sk_ezrouter (default)",className:"flex-1 min-w-0 px-2 py-1.5 bg-surface rounded border border-border text-xs text-text-main focus:outline-none focus:ring-1 focus:ring-primary/50"}),a?.length>0&&(0,d.jsx)("datalist",{id:"mitm-api-keys",children:a.map(a=>(0,d.jsx)("option",{value:a.key,children:a.name||a.key},a.id))})]})]}),(0,d.jsxs)("div",{className:"flex flex-col gap-2 sm:flex-row sm:flex-wrap sm:items-center","data-i18n-skip":"true",children:[g?.certExists&&!g?.certTrusted&&(0,d.jsxs)("button",{onClick:()=>E("trust-cert"),disabled:i,className:"flex w-full items-center justify-center gap-1.5 rounded-lg border border-yellow-500/30 bg-yellow-500/10 px-4 py-2 text-xs font-medium text-yellow-600 transition-colors hover:bg-yellow-500/20 disabled:opacity-50 sm:w-auto sm:py-1.5",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[16px]",children:"verified_user"}),"Trust Cert"]}),H?(0,d.jsxs)("button",{onClick:()=>E("stop"),disabled:i,className:"flex w-full items-center justify-center gap-1.5 rounded-lg border border-red-500/30 bg-red-500/10 px-4 py-2 text-xs font-medium text-red-500 transition-colors hover:bg-red-500/20 disabled:opacity-50 sm:w-auto sm:py-1.5",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[16px]",children:"stop_circle"}),"Stop Server"]}):(0,d.jsxs)("button",{onClick:()=>E("start"),disabled:i||!g||A&&!C,title:A&&!C?"Administrator required":void 0,className:"flex w-full items-center justify-center gap-1.5 rounded-lg border border-primary/30 bg-primary/10 px-4 py-2 text-xs font-medium text-primary transition-colors hover:bg-primary/20 disabled:opacity-50 sm:w-auto sm:py-1.5",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[16px]",children:"play_circle"}),"Start Server"]}),H&&(0,d.jsx)("p",{className:"text-xs text-text-muted",children:"Enable DNS per tool below to activate interception"})]}),u&&(0,d.jsxs)("div",{className:"flex items-start gap-2 px-2 py-1.5 rounded text-xs bg-red-500/10 text-red-600 dark:text-red-400 border border-red-500/20",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mt-0.5 shrink-0",children:"error"}),(0,d.jsx)("span",{children:u})]}),A&&!C&&(0,d.jsxs)("div",{className:"flex items-center gap-2 px-2 py-1.5 rounded text-xs bg-red-500/10 text-red-600 border border-red-500/20",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"shield_lock"}),(0,d.jsx)("span",{children:"Administrator required — restart EzRouter as Administrator to use MITM"})]})]})}),k&&(0,d.jsx)("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/50 backdrop-blur-sm",children:(0,d.jsxs)("div",{className:"mx-4 flex w-full max-w-sm flex-col gap-4 rounded-xl border border-border bg-surface p-5 shadow-xl sm:p-6",children:[(0,d.jsx)("h3",{className:"font-semibold text-text-main",children:"Sudo Password Required"}),(0,d.jsxs)("div",{className:"flex items-start gap-3 p-3 bg-yellow-500/10 border border-yellow-500/30 rounded-lg",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-yellow-500 text-[20px]",children:"warning"}),(0,d.jsx)("p",{className:"text-xs text-text-muted",children:"Required for SSL certificate and server startup"})]}),(0,d.jsx)(f.pd,{type:"password",placeholder:"Enter sudo password",value:m,onChange:a=>n(a.target.value),onKeyDown:a=>{"Enter"!==a.key||i||G()}}),s&&(0,d.jsxs)("div",{className:"flex items-center gap-2 px-2 py-1.5 rounded text-xs bg-red-500/10 text-red-600",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"error"}),(0,d.jsx)("span",{children:s})]}),(0,d.jsxs)("div",{className:"flex items-center justify-end gap-2",children:[(0,d.jsx)(f.$n,{variant:"ghost",size:"sm",onClick:()=>{l(!1),n(""),t(null)},disabled:i,children:"Cancel"}),(0,d.jsx)(f.$n,{variant:"primary",size:"sm",onClick:G,loading:i,children:"Confirm"})]})]})}),y&&(0,d.jsx)("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/50 backdrop-blur-sm",children:(0,d.jsxs)("div",{className:"mx-4 flex w-full max-w-md flex-col gap-4 rounded-xl border border-border bg-surface p-5 shadow-xl sm:p-6",children:[(0,d.jsx)("h3",{className:"font-semibold text-text-main",children:"Port 443 Already In Use"}),(0,d.jsxs)("div",{className:"flex items-start gap-3 p-3 bg-yellow-500/10 border border-yellow-500/30 rounded-lg",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-yellow-500 text-[20px]",children:"warning"}),(0,d.jsxs)("div",{className:"flex flex-col gap-1 text-xs text-text-muted",children:[(0,d.jsx)("p",{children:"Port 443 is currently used by another process:"}),(0,d.jsxs)("p",{className:"font-mono text-text-main","data-i18n-skip":"true",children:[y.owner.name," (PID ",y.owner.pid,")"]}),(0,d.jsx)("p",{children:"Kill this process to start MITM Server?"})]})]}),(0,d.jsxs)("div",{className:"flex items-center justify-end gap-2",children:[(0,d.jsx)(f.$n,{variant:"ghost",size:"sm",onClick:()=>{z(null),j(!1)},disabled:i,children:"Cancel"}),(0,d.jsx)(f.$n,{variant:"primary",size:"sm",onClick:()=>{F("start",y?.password||"",!0)},loading:i,children:"Kill & Start"})]})]})})]})}var ao=c(36811);function ap({tool:a,isExpanded:b,onToggle:c,serverRunning:h,dnsActive:i,hasCachedPassword:j,needsSudoPassword:k,isWin:l,apiKeys:m,activeProviders:n,hasActiveProviders:o,modelAliases:p={},cloudEnabled:q,onDnsChange:r}){let[s,t]=(0,e.useState)(!1),[u,v]=(0,e.useState)(null),[w,x]=(0,e.useState)(!1),[y,z]=(0,e.useState)(""),[A,B]=(0,e.useState)(null),[C,D]=(0,e.useState)(null),[E,F]=(0,e.useState)({}),[G,H]=(0,e.useState)(!1),[I,J]=(0,e.useState)(null),K=ao.TOOL_HOSTS[a.id]??[],L=l||j||!1===k,M=(0,e.useCallback)(async b=>{try{await fetch("/api/cli-tools/antigravity-mitm/alias",{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({tool:a.id,mappings:b})})}catch{}},[a.id]),N=(a,b)=>{F(c=>({...c,[a]:b}))},O=()=>{if(!h)return;let a=i?"disable":"enable";L?P(a,""):(B(a),x(!0),D(null))},P=async(b,c)=>{t(!0),v(null);try{let d=await fetch("/api/cli-tools/antigravity-mitm",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({tool:a.id,action:b,sudoPassword:c})}),e=await d.json();if(!d.ok)throw Error(e.error||"Failed to toggle DNS");"enable"===b&&v(`Restart ${a.name} to apply changes`),x(!1),z(""),r?.(e)}catch{}finally{t(!1),B(null)}},Q=()=>{y.trim()?P(A,y):D("Sudo password is required")};return(0,d.jsxs)(d.Fragment,{children:[(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:a.image,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 flex-wrap items-center gap-2",children:[(0,d.jsx)("h3",{className:"font-medium text-sm",children:a.name}),h?i?(0,d.jsx)(f.Ex,{variant:"success",size:"sm",children:"Active"}):(0,d.jsx)(f.Ex,{variant:"warning",size:"sm",children:"DNS off"}):(0,d.jsx)(f.Ex,{variant:"default",size:"sm",children:"Server off"})]}),(0,d.jsxs)("p",{className:"text-xs text-text-muted sm:truncate",children:["Intercept ",a.name," requests via MITM proxy"]})]})]}),(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:[K.length>0&&(0,d.jsxs)("div",{className:"mt-2 rounded-md border border-border bg-surface/50 px-2 py-1.5",children:[(0,d.jsx)("p",{className:"text-[10px] font-medium tracking-wide text-text-main/80 mb-1",children:"Edit hosts file manually to add the following entries:"}),(0,d.jsx)("ul",{className:"list-none space-y-0.5 font-mono text-[10px] text-text-muted break-all",children:K.map(a=>(0,d.jsxs)("li",{children:["127.0.0.1 ",a]},a))})]}),(0,d.jsxs)("div",{className:"flex flex-col gap-0.5 text-[11px] text-text-muted px-1",children:[(0,d.jsxs)("p",{children:["Toggle DNS to redirect ",a.name," traffic through EzRouter via MITM."]}),!i&&(0,d.jsx)("p",{className:"text-amber-600 text-[10px] mt-1",children:"⚠️ Enable DNS to edit model mappings"})]}),a.defaultModels?.length>0&&(0,d.jsx)("div",{className:"flex flex-col gap-2",children:a.defaultModels.map(a=>(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[9rem_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",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:E[a.alias]||"",onChange:b=>N(a.alias,b.target.value),onBlur:b=>{var c,d;return c=a.alias,d=b.target.value,void M({...E,[c]:d})},placeholder:"provider/model-id",disabled:!i,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?"opacity-50 cursor-not-allowed":""}`}),E[a.alias]&&(0,d.jsx)("button",{onClick:()=>{N(a.alias,""),M({...E,[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:()=>{J(a.alias),H(!0)},disabled:!o||!i,className:`rounded border px-2 py-2 text-xs transition-colors sm:py-1.5 ${o&&i?"bg-surface border-border hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Select"})]},a.alias))}),a.defaultModels?.length===0&&(0,d.jsx)("p",{className:"text-xs text-text-muted px-1",children:"Model mappings will be available soon."}),(0,d.jsxs)("div",{className:"flex flex-col gap-2 sm:items-start",children:[i?(0,d.jsxs)("button",{onClick:O,disabled:!h||s,className:"flex w-full items-center justify-center gap-1.5 rounded-lg border border-red-500/30 bg-red-500/10 px-4 py-2 text-xs font-medium text-red-500 transition-colors hover:bg-red-500/20 disabled:cursor-not-allowed disabled:opacity-50 sm:w-auto sm:py-1.5",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[16px]",children:"stop_circle"}),"Stop DNS"]}):(0,d.jsxs)("button",{onClick:O,disabled:!h||s,className:"flex w-full items-center justify-center gap-1.5 rounded-lg border border-primary/30 bg-primary/10 px-4 py-2 text-xs font-medium text-primary transition-colors hover:bg-primary/20 disabled:cursor-not-allowed disabled:opacity-50 sm:w-auto sm:py-1.5",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[16px]",children:"play_circle"}),"Start DNS"]}),u&&(0,d.jsxs)("div",{className:"flex items-center gap-2 px-2 py-1.5 rounded text-xs text-amber-500",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"warning"}),(0,d.jsx)("span",{children:u})]})]})]})]}),w&&(0,d.jsx)("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/50 backdrop-blur-sm",children:(0,d.jsxs)("div",{className:"mx-4 flex w-full max-w-sm flex-col gap-4 rounded-xl border border-border bg-surface p-5 shadow-xl sm:p-6",children:[(0,d.jsx)("h3",{className:"font-semibold text-text-main",children:"Sudo Password Required"}),(0,d.jsxs)("div",{className:"flex items-start gap-3 p-3 bg-yellow-500/10 border border-yellow-500/30 rounded-lg",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-yellow-500 text-[20px]",children:"warning"}),(0,d.jsx)("p",{className:"text-xs text-text-muted",children:"Required to modify /etc/hosts and flush DNS cache"})]}),(0,d.jsx)(f.pd,{type:"password",placeholder:"Enter sudo password",value:y,onChange:a=>z(a.target.value),onKeyDown:a=>{"Enter"!==a.key||s||Q()}}),C&&(0,d.jsxs)("div",{className:"flex items-center gap-2 px-2 py-1.5 rounded text-xs bg-red-500/10 text-red-600",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"error"}),(0,d.jsx)("span",{children:C})]}),(0,d.jsxs)("div",{className:"flex items-center justify-end gap-2",children:[(0,d.jsx)(f.$n,{variant:"ghost",size:"sm",onClick:()=>{x(!1),z(""),D(null)},disabled:s,children:"Cancel"}),(0,d.jsx)(f.$n,{variant:"primary",size:"sm",onClick:Q,loading:s,children:"Confirm"})]})]})}),G&&(0,d.jsx)(f.rq,{isOpen:G,onClose:()=>H(!1),onSelect:a=>{if(!I||a.isPlaceholder)return;let b={...E,[I]:a.value};F(b),M(b)},selectedModel:I?E[I]:null,activeProviders:n,modelAliases:p,title:`Select model for ${I}`})]})}function aq({tool:a,isExpanded:b,onToggle:c,baseUrl:h,hasActiveProviders:i,apiKeys:j,activeProviders:k,cloudEnabled:l,initialStatus:m,tunnelEnabled:n,tunnelPublicUrl:o,tailscaleEnabled:p,tailscaleUrl:r}){let s,t,[v,w]=(0,e.useState)(m||null),[y,z]=(0,e.useState)(!1),[A,B]=(0,e.useState)(!1),[C,D]=(0,e.useState)(!1),[F,G]=(0,e.useState)(null),[H,I]=(0,e.useState)(""),[J,K]=(0,e.useState)(""),[L,M]=(0,e.useState)({}),[N,O]=(0,e.useState)(null),[P,Q]=(0,e.useState)(!1),[R,S]=(0,e.useState)({}),[T,U]=(0,e.useState)(!1),[V,W]=(0,e.useState)("");(0,e.useRef)(!1);let X=v?.settings?.models?.providers?.["9router"]?.baseUrl||"",Y=(()=>{if(!v?.installed)return null;let a=v.settings?.models?.providers?.["9router"];return a?E(a.baseUrl,{tunnelPublicUrl:o,tailscaleUrl:r})?"configured":"other":"not_configured"})(),Z=async()=>{z(!0);try{let a=await fetch("/api/cli-tools/openclaw-settings"),b=await a.json();w(b)}catch(a){w({installed:!1,error:a.message})}finally{z(!1)}},$=()=>{let a=V||"http://127.0.0.1:20126";return a.endsWith("/v1")?a:`${a}/v1`},_=async()=>{B(!0),G(null);try{let a=H?.trim()||(j?.length>0?j[0].key:null)||(l?null:"sk_ezrouter"),b=await fetch("/api/cli-tools/openclaw-settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({baseUrl:$(),apiKey:a,model:J,agentModels:L})}),c=await b.json();b.ok?(q($(),{tunnelPublicUrl:o,tailscaleUrl:r}),G({type:"success",text:"Settings applied successfully!"}),Z()):G({type:"error",text:c.error||"Failed to apply settings"})}catch(a){G({type:"error",text:a.message})}finally{B(!1)}},aa=async()=>{D(!0),G(null);try{let a=await fetch("/api/cli-tools/openclaw-settings",{method:"DELETE"}),b=await a.json();a.ok?(G({type:"success",text:"Settings reset successfully!"}),K(""),I(""),Z()):G({type:"error",text:b.error||"Failed to reset settings"})}catch(a){G({type:"error",text:a.message})}finally{D(!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/openclaw.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"===Y&&(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"===Y&&(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"===Y&&(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:[y&&(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 Open Claw CLI..."})]}),!y&&v&&!v.installed&&(0,d.jsx)("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:"Open Claw 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.jsx)("div",{className:"flex items-center gap-2 pl-9",children:(0,d.jsxs)(f.$n,{variant:"secondary",size:"sm",onClick:()=>U(!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"]})})]})}),!y&&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)(u,{value:V||((s=V||"http://127.0.0.1:20126").endsWith("/v1")?s:`${s}/v1`),onChange:W,requiresExternalUrl:a.requiresExternalUrl,tunnelEnabled:n,tunnelPublicUrl:o,tailscaleEnabled:p,tailscaleUrl:r,currentUrl:X})]}),v?.settings?.models?.providers?.["9router"]?.baseUrl&&(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:v.settings.models.providers["9router"].baseUrl})]}),(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)(x,{value:H,onChange:I,apiKeys:j,cloudEnabled:l})]}),(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:"Default 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:J,onChange:a=>K(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"}),J&&(0,d.jsx)("button",{onClick:()=>K(""),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:()=>{O(null),Q(!0)},disabled:!i,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 ${i?"bg-surface border-border text-text-main hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Select"})]}),(v.agents||[]).filter(a=>a.agentDir).map(a=>(0,d.jsxs)("div",{className:"flex items-center gap-2 pl-4",children:[(0,d.jsxs)("span",{className:"w-32 shrink-0 text-xs text-primary text-right truncate",title:a.name||a.id,children:["Agent ",a.name||a.id]}),(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:L[a.id]||"",onChange:b=>M(c=>({...c,[a.id]:b.target.value})),placeholder:`default (${J||"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"}),L[a.id]&&(0,d.jsx)("button",{onClick:()=>M(b=>({...b,[a.id]:""})),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:()=>{O(a.id),Q(!0)},disabled:!i,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 ${i?"bg-surface border-border text-text-main hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Select"})]},a.id))]}),F&&(0,d.jsxs)("div",{className:`flex items-center gap-2 px-2 py-1.5 rounded text-xs ${"success"===F.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"===F.type?"check_circle":"error"}),(0,d.jsx)("span",{children:F.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:_,disabled:!J,loading:A,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:aa,disabled:!v?.has9Router,loading:C,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:()=>U(!0),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"content_copy"}),"Manual Config"]})]})]})]}),P&&(0,d.jsx)(f.rq,{isOpen:P,onClose:()=>Q(!1),onSelect:a=>{N?(M(b=>({...b,[N]:a.value})),O(null)):K(a.value),Q(!1)},selectedModel:J,activeProviders:k,modelAliases:R,title:"Select Model for Open Claw"}),(0,d.jsx)(f.uR,{isOpen:T,onClose:()=>U(!1),title:"Open Claw - Manual Configuration",configs:(t=H&&H.trim()?H:l?"<API_KEY_FROM_DASHBOARD>":"sk_ezrouter",[{filename:"~/.openclaw/openclaw.json",content:JSON.stringify({agents:{defaults:{model:{primary:`9router/${J||"provider/model-id"}`}}},models:{providers:{"9router":{baseUrl:$(),apiKey:t,api:"openai-completions",models:[{id:J||"provider/model-id",name:(J||"provider/model-id").split("/").pop()}]}}}},null,2)}])})]})}function ar({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,t,v,w,[y,z]=(0,e.useState)(l||null),[A,B]=(0,e.useState)(!1),[D,F]=(0,e.useState)(!1),[G,H]=(0,e.useState)(!1),[I,J]=(0,e.useState)(null),[K,L]=(0,e.useState)(!1),[M,N]=(0,e.useState)(""),[O,P]=(0,e.useState)(""),[Q,R]=(0,e.useState)(""),[S,T]=(0,e.useState)(!1),[U,V]=(0,e.useState)(!1),[W,X]=(0,e.useState)({}),[Y,Z]=(0,e.useState)(!1),[$,_]=(0,e.useState)(""),[aa,ab]=(0,e.useState)([]),[ac,ad]=(0,e.useState)(""),ae=(0,e.useRef)([]),af=async a=>{try{let b=M&&M.trim()||k?M:"sk_ezrouter",c=a.includes(ac)?ac:a[0]||"";await fetch("/api/cli-tools/opencode-settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({baseUrl:ai(),apiKey:b,models:a,activeModel:c,subagentModel:Q})})}catch(a){console.log("Error saving models:",a)}},ag=y?.config?.provider?.["9router"]?.options?.baseURL||"",ah=y?.installed?y.config&&y.has9Router?E(y.config?.provider?.["9router"]?.options?.baseURL||"",{tunnelPublicUrl:n,tailscaleUrl:p})?"configured":"other":"not_configured":null,ai=()=>{let a=$||h;return a.endsWith("/v1")?a:`${a}/v1`},aj=async()=>{B(!0);try{let a=await fetch("/api/cli-tools/opencode-settings"),b=await a.json();z(b)}catch(a){z({installed:!1,error:a.message})}finally{B(!1)}},ak=async()=>{F(!0),J(null);try{let a=M&&M.trim()||k?M:"sk_ezrouter",b=await fetch("/api/cli-tools/opencode-settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({baseUrl:ai(),apiKey:a,models:aa,activeModel:""===ac?"":ac||aa[0],subagentModel:Q})}),c=await b.json();b.ok?(q(ai(),{tunnelPublicUrl:n,tailscaleUrl:p}),J({type:"success",text:"Settings applied successfully!"}),aj()):J({type:"error",text:c.error||"Failed to apply settings"})}catch(a){J({type:"error",text:a.message})}finally{F(!1)}},al=async()=>{H(!0),J(null);try{let a=await fetch("/api/cli-tools/opencode-settings",{method:"DELETE"}),b=await a.json();a.ok?(J({type:"success",text:"Settings reset successfully!"}),P(""),R(""),ab([]),ad(""),aj()):J({type:"error",text:b.error||"Failed to reset settings"})}catch(a){J({type:"error",text:a.message})}finally{H(!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/opencode.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"===ah&&(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"===ah&&(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"===ah&&(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:[A&&(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 OpenCode CLI..."})]}),!A&&y&&!y.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:"OpenCode 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.jsx)(C,{tool:"opencode",baseUrl:ai(),apiKey:M,model:ac||aa[0]||"",className:"!bg-yellow-500/20 !border-yellow-500/40 !text-yellow-700 dark:!text-yellow-300 hover:!bg-yellow-500/30"}),(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:()=>L(!K),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[18px] mr-1",children:K?"expand_less":"help"}),K?"Hide":"How to Install"]})]})]}),K&&(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:"}),(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 opencode-ai"})]}),(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:"opencode"})," to verify."]})]})]})]}),!A&&y?.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)(u,{value:$||$||`${h}/v1`,onChange:_,requiresExternalUrl:a.requiresExternalUrl,tunnelEnabled:m,tunnelPublicUrl:n,tailscaleEnabled:o,tailscaleUrl:p,currentUrl:ag})]}),y?.config?.provider?.["9router"]?.options?.baseURL&&(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:y.config.provider["9router"].options.baseURL})]}),(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)(x,{value:M,onChange:N,apiKeys:i,cloudEnabled:k})]}),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr] sm:items-start sm:gap-2",children:[(0,d.jsx)("span",{className:"w-32 shrink-0 text-sm font-semibold text-text-main text-right pt-1",children:"Models"}),(0,d.jsx)("span",{className:"material-symbols-outlined text-text-muted text-[14px] mt-1.5",children:"arrow_forward"}),(0,d.jsxs)("div",{className:"flex-1 flex flex-col gap-2",children:[(0,d.jsx)("div",{className:"flex flex-wrap gap-1.5 min-h-[28px] px-2 py-1.5 bg-surface rounded border border-border",children:0===aa.length?(0,d.jsx)("span",{className:"text-xs text-text-muted",children:"No models selected"}):aa.map(a=>(0,d.jsxs)("span",{onClick:async()=>{if(a===ac)try{(await fetch("/api/cli-tools/opencode-settings",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({clearActiveModel:!0})})).ok&&(ad(""),aj())}catch(a){console.log("Error clearing active model:",a)}else ad(a)},className:`inline-flex items-center gap-1 px-2 py-0.5 rounded text-xs cursor-pointer transition-colors ${a===ac?"bg-primary/10 text-primary border border-primary":"bg-black/5 dark:bg-white/5 text-text-muted border border-transparent hover:border-border"}`,title:a===ac?"Click to clear active model":"Click to set as active",children:[a===ac&&(0,d.jsx)("span",{className:"material-symbols-outlined text-[10px]",children:"star"}),a,(0,d.jsx)("button",{onClick:async b=>{b.stopPropagation();try{if((await fetch(`/api/cli-tools/opencode-settings?model=${encodeURIComponent(a)}`,{method:"DELETE"})).ok){let b=aa.filter(b=>b!==a);ab(b),ac===a&&ad(""),aj()}}catch(a){console.log("Error removing model:",a)}},className:"ml-0.5 hover:text-red-500",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-[12px]",children:"close"})})]},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)("button",{onClick:()=>T(!0),disabled:!j?.length,className:`px-2 py-1 rounded border text-xs transition-colors ${j?.length?"bg-surface border-border text-text-main hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Add Model"}),(0,d.jsx)("span",{className:"text-xs text-text-muted",children:aa.length>0&&ac?(0,d.jsxs)(d.Fragment,{children:["Active: ",(0,d.jsx)("span",{className:"text-primary",children:ac})]}):aa.length>0?(0,d.jsx)("span",{className:"text-yellow-500",children:"Click a model to set/clear active"}):"Select models to add"})]})]})]}),(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.jsx)("input",{type:"text",value:Q,onChange:a=>R(a.target.value),placeholder:O||"provider/model-id (defaults to main model)",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)("button",{onClick:()=>V(!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"}),Q&&(0,d.jsx)("button",{onClick:()=>R(""),className:"p-1 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"})})]})]}),I&&(0,d.jsxs)("div",{className:`flex items-center gap-2 px-2 py-1.5 rounded text-xs ${"success"===I.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"===I.type?"check_circle":"error"}),(0,d.jsx)("span",{children:I.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:ak,disabled:0===aa.length,loading:D,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:al,disabled:!y.has9Router,loading:G,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"]}),(0,d.jsx)(C,{tool:"opencode",baseUrl:ai(),apiKey:M,model:ac||aa[0]||"",variant:"ghost"})]})]})]}),S&&(0,d.jsx)(f.rq,{isOpen:S,onClose:()=>{T(!1),af(ae.current)},onSelect:a=>{!aa.includes(a.value)&&(ab([...aa,a.value]),ac||ad(a.value))},onDeselect:a=>{let b=aa.filter(b=>b!==a.value);ab(b),ac===a.value&&ad(b[0]||"")},selectedModel:null,activeProviders:j,modelAliases:W,addedModelValues:aa,closeOnSelect:!1,title:"Add Model for OpenCode"}),U&&(0,d.jsx)(f.rq,{isOpen:U,onClose:()=>V(!1),onSelect:a=>{R(a.value),V(!1)},selectedModel:Q,activeProviders:j,modelAliases:W,title:"Select Subagent Model for OpenCode"}),(0,d.jsx)(f.uR,{isOpen:Y,onClose:()=>Z(!1),title:"OpenCode - Manual Configuration",configs:(r=M&&M.trim()?M:k?"<API_KEY_FROM_DASHBOARD>":"sk_ezrouter",s=aa.length>0?aa:["provider/model-id"],t=ac||aa[0]||s[0],v=Q||t,w={},s.forEach(a=>{w[a]={name:a,modalities:{input:["text","image"],output:["text"]}}}),[{filename:"~/.config/opencode/opencode.json",content:JSON.stringify({provider:{"9router":{npm:"@ai-sdk/openai-compatible",options:{baseURL:ai(),apiKey:r},models:w}},model:`9router/${t}`,agent:{explorer:{description:"Fast explorer subagent for codebase exploration",mode:"subagent",model:`9router/${v}`}}},null,2)}])})]})}},36811:a=>{a.exports={TOOL_HOSTS:{antigravity:["daily-cloudcode-pa.googleapis.com","cloudcode-pa.googleapis.com"],copilot:["api.individual.githubcopilot.com"],kiro:["runtime.us-east-1.kiro.dev","q.us-east-1.amazonaws.com","codewhisperer.us-east-1.amazonaws.com"],cursor:["api2.cursor.sh"]}}},62911:(a,b,c)=>{c.d(b,{dM:()=>e,wn:()=>d});let d={antigravity:{id:"antigravity",name:"Antigravity",image:"/providers/antigravity.png",color:"#4285F4",description:"Google Antigravity IDE with MITM",configType:"mitm",mitmDomain:"daily-cloudcode-pa.googleapis.com",modelAliases:["gemini-3.8-flash-high","gemini-3.8-flash-medium","gemini-3.8-flash-low","gemini-3.7-flash-high","gemini-3.7-flash-medium","gemini-3.7-flash-low","gemini-3.7-flash","gemini-3.6-flash-high","gemini-3.6-flash-medium","gemini-3.6-flash-low","gemini-3-flash-agent","gemini-3.1-pro-low","gemini-pro-agent","claude-sonnet-4-6","claude-opus-4-6-thinking","gpt-oss-120b-medium","gemini-3-flash"],defaultModels:[{id:"gemini-3.8-flash-high",name:"Gemini 3.8 Flash (High)",alias:"gemini-3.8-flash-high"},{id:"gemini-3.8-flash-medium",name:"Gemini 3.8 Flash (Medium)",alias:"gemini-3.8-flash-medium"},{id:"gemini-3.8-flash-low",name:"Gemini 3.8 Flash (Low)",alias:"gemini-3.8-flash-low"},{id:"gemini-3.7-flash-high",name:"Gemini 3.7 Flash (High)",alias:"gemini-3.7-flash-high"},{id:"gemini-3.7-flash-medium",name:"Gemini 3.7 Flash (Medium)",alias:"gemini-3.7-flash-medium"},{id:"gemini-3.7-flash-low",name:"Gemini 3.7 Flash (Low)",alias:"gemini-3.7-flash-low"},{id:"gemini-3.7-flash",name:"Gemini 3.7 Flash",alias:"gemini-3.7-flash",mandatory:!0},{id:"gemini-3.6-flash-high",name:"Gemini 3.6 Flash (High)",alias:"gemini-3.6-flash-high"},{id:"gemini-3.6-flash-medium",name:"Gemini 3.6 Flash (Medium)",alias:"gemini-3.6-flash-medium"},{id:"gemini-3.6-flash-low",name:"Gemini 3.6 Flash (Low)",alias:"gemini-3.6-flash-low"},{id:"gemini-3-flash-agent",name:"Gemini 3.5 Flash (High)",alias:"gemini-3-flash-agent"},{id:"gemini-3.1-pro-low",name:"Gemini 3.1 Pro (Low)",alias:"gemini-3.1-pro-low"},{id:"gemini-pro-agent",name:"Gemini 3.1 Pro (High)",alias:"gemini-pro-agent"},{id:"claude-sonnet-4-6",name:"Claude Sonnet 4.6 (Thinking)",alias:"claude-sonnet-4-6"},{id:"claude-opus-4-6-thinking",name:"Claude Opus 4.6 (Thinking)",alias:"claude-opus-4-6-thinking"},{id:"gpt-oss-120b-medium",name:"GPT-OSS 120B (Medium)",alias:"gpt-oss-120b-medium"},{id:"gemini-3-flash",name:"Gemini 3 Flash (Command)",alias:"gemini-3-flash"}]},copilot:{id:"copilot",name:"GitHub Copilot",image:"/providers/copilot.png",color:"#1F6FEB",description:"GitHub Copilot IDE with MITM",configType:"mitm",mitmDomain:"api.individual.githubcopilot.com",modelAliases:["gpt-5-mini","gpt-5.4-nano","claude-haiku-4.5","gpt-4o","gpt-4.1"],defaultModels:[{id:"gpt-5-mini",name:"GPT-5 mini",alias:"gpt-5-mini"},{id:"gpt-5.4-nano",name:"GPT-5.4 nano",alias:"gpt-5.4-nano"},{id:"claude-haiku-4.5",name:"Claude Haiku 4.5",alias:"claude-haiku-4.5"},{id:"gpt-4o",name:"GPT-4o",alias:"gpt-4o"},{id:"gpt-4.1",name:"GPT-4.1",alias:"gpt-4.1"}]},kiro:{id:"kiro",name:"Kiro",image:"/providers/kiro.png",color:"#FF6B00",description:"Kiro IDE with MITM",configType:"mitm",mitmDomain:"runtime.us-east-1.kiro.dev",defaultModels:[{id:"auto",name:"Auto (Kiro Agent)",alias:"auto"},{id:"claude-sonnet-5",name:"Claude Sonnet 5",alias:"claude-sonnet-5"},{id:"claude-sonnet-4.5",name:"Claude Sonnet 4.5",alias:"claude-sonnet-4.5"},{id:"claude-sonnet-4",name:"Claude Sonnet 4",alias:"claude-sonnet-4"},{id:"claude-haiku-4.5",name:"Claude Haiku 4.5",alias:"claude-haiku-4.5"},{id:"deepseek-3.2",name:"DeepSeek 3.2",alias:"deepseek-3.2"},{id:"minimax-m2.1",name:"MiniMax M2.1",alias:"minimax-m2.1"},{id:"gpt-5.6-sol",name:"GPT 5.6 Sol",alias:"gpt-5.6-sol",contextLength:272e3,rateMultiplier:2.4},{id:"gpt-5.6-terra",name:"GPT 5.6 Terra",alias:"gpt-5.6-terra",contextLength:272e3,rateMultiplier:1.2},{id:"gpt-5.6-luna",name:"GPT 5.6 Luna",alias:"gpt-5.6-luna",contextLength:272e3,rateMultiplier:.6},{id:"simple-task",name:"Qwen3 Coder Next",alias:"simple-task"}]}},e={claude:{id:"claude",name:"Claude Code",image:"/providers/claude.png",color:"#D97757",description:"Anthropic Claude Code CLI",configType:"env",envVars:{baseUrl:"ANTHROPIC_BASE_URL",model:"ANTHROPIC_MODEL",opusModel:"ANTHROPIC_DEFAULT_OPUS_MODEL",sonnetModel:"ANTHROPIC_DEFAULT_SONNET_MODEL",fableModel:"ANTHROPIC_DEFAULT_FABLE_MODEL",haikuModel:"ANTHROPIC_DEFAULT_HAIKU_MODEL"},modelAliases:["default","sonnet","opus","fable","haiku","opusplan"],settingsFile:"~/.claude/settings.json",defaultModels:[{id:"fable",name:"Claude Fable",alias:"fable",envKey:"ANTHROPIC_DEFAULT_FABLE_MODEL",defaultValue:"cc/claude-fable-5"},{id:"opus",name:"Claude Opus",alias:"opus",envKey:"ANTHROPIC_DEFAULT_OPUS_MODEL",defaultValue:"cc/claude-opus-5"},{id:"sonnet",name:"Claude Sonnet",alias:"sonnet",envKey:"ANTHROPIC_DEFAULT_SONNET_MODEL",defaultValue:"cc/claude-sonnet-5"},{id:"haiku",name:"Claude Haiku",alias:"haiku",envKey:"ANTHROPIC_DEFAULT_HAIKU_MODEL",defaultValue:"cc/claude-haiku-4-5-20251001"}]},openclaw:{id:"openclaw",name:"Open Claw",image:"/providers/openclaw.png",color:"#FF6B35",description:"Open Claw AI Assistant",configType:"custom"},codex:{id:"codex",name:"OpenAI Codex CLI / App",image:"/providers/codex.png",color:"#10A37F",description:"OpenAI Codex CLI",configType:"custom"},opencode:{id:"opencode",name:"OpenCode",image:"/providers/opencode.png",color:"#E87040",description:"OpenCode AI Terminal Assistant",configType:"custom"},cowork:{id:"cowork",name:"Claude Cowork",image:"/providers/claude.png",color:"#D97757",description:"Claude Desktop Cowork (third-party inference)",configType:"custom"},hermes:{id:"hermes",name:"Hermes Agent",image:"/providers/hermes.png",color:"#8B5CF6",description:"Nous Research self-improving AI agent",configType:"custom",roles:[{id:"delegation",label:"Delegation (subagents)"},{id:"vision",label:"Vision"},{id:"web_extract",label:"Web Extract"},{id:"compression",label:"Compression"},{id:"title_generation",label:"Title Generation"},{id:"approval",label:"Approval"},{id:"skills_hub",label:"Skills Hub"},{id:"mcp",label:"MCP"},{id:"memory_query_rewrite",label:"Memory Query Rewrite"},{id:"background_review",label:"Background Review"},{id:"curator",label:"Curator"},{id:"monitor",label:"Monitor"}]},droid:{id:"droid",name:"Factory Droid",image:"/providers/droid.png",color:"#00D4FF",description:"Factory Droid AI Assistant",configType:"custom"},cursor:{id:"cursor",name:"Cursor",image:"/providers/cursor.png",color:"#000000",description:"Cursor AI Code Editor",configType:"guide",requiresExternalUrl:!0,notes:[{type:"warning",text:"Requires Cursor Pro account to use this feature."},{type:"cloudCheck",text:"Cursor routes requests through its own server, so local endpoint is not supported. Please enable Tunnel or Cloud Endpoint in Settings."}],guideSteps:[{step:1,title:"Open Settings",desc:"Go to Settings → Models"},{step:2,title:"Enable OpenAI API",desc:'Enable "OpenAI API key" option'},{step:3,title:"Base URL",value:"{{baseUrl}}",copyable:!0},{step:4,title:"API Key",type:"apiKeySelector"},{step:5,title:"Add Custom Model",desc:'Click "View All Model" → "Add Custom Model"'},{step:6,title:"Select Model",type:"modelSelector"}]},cline:{id:"cline",name:"Cline",image:"/providers/cline.png",color:"#5B9BD5",description:"Cline AI Coding Assistant",configType:"custom"},kilo:{id:"kilo",name:"Kilo Code",image:"/providers/kilocode.png",color:"#FF6B6B",description:"Kilo Code AI Assistant",configType:"custom"},roo:{id:"roo",name:"Roo",image:"/providers/roo.png",color:"#FF6B6B",description:"Roo AI Assistant",configType:"guide",guideSteps:[{step:1,title:"Open Settings",desc:"Go to Roo Settings panel"},{step:2,title:"Select Provider",desc:"Choose API Provider → Ollama"},{step:3,title:"Base URL",value:"{{baseUrl}}",copyable:!0},{step:4,title:"API Key",type:"apiKeySelector"},{step:5,title:"Select Model",type:"modelSelector"}]},continue:{id:"continue",name:"Continue",image:"/providers/continue.png",color:"#7C3AED",description:"Continue AI Assistant",configType:"guide",guideSteps:[{step:1,title:"Open Config",desc:"Open Continue configuration file"},{step:2,title:"API Key",type:"apiKeySelector"},{step:3,title:"Select Model",type:"modelSelector"},{step:4,title:"Add Model Config",desc:"Add the following configuration to your models array:"}],codeBlock:{language:"json",code:`{
102
+ id = "${J||"cc/claude-opus-4-7"}"`},{filename:"~/.config/jcode/provider-9router.env",content:`JCODE_9ROUTER_API_KEY="${t}"`}])})]})}function ai({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]=(0,e.useState)(l||null),[t,v]=(0,e.useState)(!1),[w,y]=(0,e.useState)(!1),[z,A]=(0,e.useState)(!1),[B,C]=(0,e.useState)(null),[D,E]=(0,e.useState)(!1),[F,G]=(0,e.useState)(""),[H,I]=(0,e.useState)(""),[J,K]=(0,e.useState)(!1),[L,M]=(0,e.useState)({}),[N,O]=(0,e.useState)(!1),[P,Q]=(0,e.useState)(""),R=r?.installed?r.has9Router?"configured":"not_configured":null,S=()=>{let a=P||`${h}/v1`;return a.endsWith("/v1")?a:`${a}/v1`},T=async()=>{v(!0);try{let a=await fetch("/api/cli-tools/kilo-settings"),b=await a.json();s(b)}catch(a){s({installed:!1,error:a.message})}finally{v(!1)}},U=async()=>{y(!0),C(null);try{let a=F&&F.trim()||k?F:"sk_ezrouter",b=await fetch("/api/cli-tools/kilo-settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({baseUrl:S(),apiKey:a,model:H})}),c=await b.json();b.ok?(q(S(),{tunnelPublicUrl:n,tailscaleUrl:p}),C({type:"success",text:"Settings applied successfully!"}),T()):C({type:"error",text:c.error||"Failed to apply settings"})}catch(a){C({type:"error",text:a.message})}finally{y(!1)}},V=async()=>{A(!0),C(null);try{let a=await fetch("/api/cli-tools/kilo-settings",{method:"DELETE"}),b=await a.json();a.ok?(C({type:"success",text:"Settings reset successfully!"}),I(""),T()):C({type:"error",text:b.error||"Failed to reset settings"})}catch(a){C({type:"error",text:a.message})}finally{A(!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/kilocode.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"===R&&(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"===R&&(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"})]}),(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:[t&&(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 Kilo Code..."})]}),!t&&r&&!r.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:"Kilo Code 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:()=>O(!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:()=>E(!D),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[18px] mr-1",children:D?"expand_less":"help"}),D?"Hide":"How to Install"]})]})]}),D&&(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)("p",{className:"text-sm text-text-muted",children:["Install Kilo Code from ",(0,d.jsx)("a",{className:"text-primary underline",href:"https://kilocode.ai",target:"_blank",rel:"noreferrer",children:"kilocode.ai"})," or VS Code extension marketplace."]})]})]}),!t&&r?.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)(u,{value:P||P||`${h}/v1`,onChange:Q,requiresExternalUrl:a.requiresExternalUrl,tunnelEnabled:m,tunnelPublicUrl:n,tailscaleEnabled:o,tailscaleUrl:p})]}),(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)(x,{value:F,onChange:G,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:H,onChange:a=>I(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"}),H&&(0,d.jsx)("button",{onClick:()=>I(""),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:()=>K(!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"})]})]}),B&&(0,d.jsxs)("div",{className:`flex items-center gap-2 px-2 py-1.5 rounded text-xs ${"success"===B.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"===B.type?"check_circle":"error"}),(0,d.jsx)("span",{children:B.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:U,disabled:!F&&k&&i.length>0||!H,loading:w,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:V,disabled:z,loading:z,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:()=>O(!0),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"content_copy"}),"Manual Config"]})]})]})]}),J&&(0,d.jsx)(f.rq,{isOpen:J,onClose:()=>K(!1),onSelect:a=>{I(a.value),K(!1)},selectedModel:H,activeProviders:j,modelAliases:L,title:"Select Model for Kilo Code"}),(0,d.jsx)(f.uR,{isOpen:N,onClose:()=>O(!1),title:"Kilo Code - Manual Configuration",configs:[{filename:"~/.local/share/kilo/auth.json",content:JSON.stringify({"openai-compatible":{type:"api-key",apiKey:F&&F.trim()?F:k?"<API_KEY_FROM_DASHBOARD>":"sk_ezrouter",baseUrl:S(),model:H||"provider/model-id"}},null,2)}]})]})}var aj=c(2116),ak=c.n(aj);function al({tool:a}){return(0,d.jsx)(ak(),{href:"/dashboard/mitm",className:"block",children:(0,d.jsx)(f.Zp,{padding:"sm",className:"overflow-hidden hover:border-primary/50 transition-colors cursor-pointer",children:(0,d.jsxs)("div",{className:"flex items-center justify-between",children:[(0,d.jsxs)("div",{className:"flex 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:a.image,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 items-center gap-2",children:[(0,d.jsx)("h3",{className:"font-medium text-sm",children:a.name}),(0,d.jsx)("span",{className:"px-1.5 py-0.5 text-[10px] font-medium bg-purple-500/10 text-purple-600 dark:text-purple-400 rounded-full",children:"MITM"})]}),(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]",children:"chevron_right"})]})})})}let am="http://localhost:20126";function an({apiKeys:a,cloudEnabled:b,onStatusChange:c}){let[g,h]=(0,e.useState)(null),[i,j]=(0,e.useState)(!1),[k,l]=(0,e.useState)(!1),[m,n]=(0,e.useState)(""),[o,p]=(0,e.useState)(()=>a?.[0]?.key||""),[q,r]=(0,e.useState)(null),[s,t]=(0,e.useState)(null),[u,v]=(0,e.useState)(null),[w,x]=(0,e.useState)(am),[y,z]=(0,e.useState)(null),A=g?.isWin===!0,B=A||g?.hasCachedPassword||g?.needsSudoPassword===!1,C=g?.isAdmin!==!1;!C&&(A||g?.hasCachedPassword||g?.needsSudoPassword);let D=(0,e.useCallback)(async()=>{try{let a=await fetch("/api/cli-tools/antigravity-mitm");if(a.ok){let b=await a.json();h(b),b.mitmRouterBaseUrl&&x(b.mitmRouterBaseUrl),c?.(b)}}catch{h({running:!1,certExists:!1,dnsStatus:{}})}},[c]),E=a=>{v(null),g&&(B?F(a,""):(r(a),l(!0),t(null)))},F=async(c,d,e=!1)=>{j(!0),v(null);try{let f;if("trust-cert"===c)f=await fetch("/api/cli-tools/antigravity-mitm",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({action:"trust-cert",sudoPassword:d})});else if("start"===c){let c=o?.trim()||(a?.length>0?a[0].key:null)||(b?null:"sk_ezrouter");f=await fetch("/api/cli-tools/antigravity-mitm",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({apiKey:c,sudoPassword:d,mitmRouterBaseUrl:w.trim()||am,forceKillPort443:e})})}else f=await fetch("/api/cli-tools/antigravity-mitm",{method:"DELETE",headers:{"Content-Type":"application/json"},body:JSON.stringify({sudoPassword:d})});if(!f.ok){let a=await f.json().catch(()=>({}));if("PORT_443_BUSY"===a.code&&a.portOwner){l(!1),z({owner:a.portOwner,password:d});return}v(a.error||`Failed to ${c} MITM server`);return}l(!1),n(""),z(null),await D()}catch(a){v(a.message||"Network error")}finally{j(!1),r(null)}},G=()=>{m.trim()?F(q,m):t("Sudo password is required")},H=g?.running;return(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(f.Zp,{padding:"sm",className:"border-primary/20 bg-primary/5",children:(0,d.jsxs)("div",{className:"flex flex-col gap-3",children:[(0,d.jsxs)("div",{className:"flex flex-col gap-2 sm:flex-row sm:items-center sm:justify-between",children:[(0,d.jsxs)("div",{className:"flex min-w-0 flex-wrap items-center gap-2",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-primary text-[20px]",children:"security"}),(0,d.jsx)("span",{className:"font-semibold text-sm text-text-main",children:"MITM Server"}),H?(0,d.jsx)(f.Ex,{variant:"success",size:"sm",children:"Running"}):(0,d.jsx)(f.Ex,{variant:"default",size:"sm",children:"Stopped"})]}),(0,d.jsx)("div",{className:"flex flex-wrap items-center gap-1 text-xs text-text-muted","data-i18n-skip":"true",children:[{label:"Cert",ok:g?.certExists},{label:"Trusted",ok:g?.certTrusted},{label:"Server",ok:H}].map(({label:a,ok:b})=>(0,d.jsxs)("span",{className:`flex items-center gap-0.5 px-1.5 py-0.5 rounded ${b?"text-green-600":"text-text-muted"}`,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[12px]",children:b?"check_circle":"cancel"}),a]},a))})]}),(0,d.jsxs)("div",{className:"px-2 py-2 rounded-lg bg-surface/50 border border-border/50 flex flex-col gap-2",children:[(0,d.jsxs)("p",{className:"text-[11px] text-text-muted leading-relaxed",children:[(0,d.jsx)("span",{className:"font-medium text-text-main",children:"Purpose:"})," Use Antigravity IDE & GitHub Copilot → with ANY provider/model from EzRouter"]}),(0,d.jsxs)("p",{className:"text-[11px] text-text-muted leading-relaxed",children:[(0,d.jsx)("span",{className:"font-medium text-text-main",children:"How it works:"})," Antigravity/Copilot IDE request → DNS redirect to localhost:443 → MITM proxy intercepts → EzRouter → response to Antigravity/Copilot"]})]}),(0,d.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,d.jsxs)("div",{className:"grid gap-1 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:"EzRouter Base URL"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsx)("input",{type:"text",value:w,onChange:a=>x(a.target.value),placeholder:am,disabled:H,className:"flex-1 min-w-0 px-2 py-1.5 bg-surface rounded border border-border text-xs text-text-main focus:outline-none focus:ring-1 focus:ring-primary/50 disabled:opacity-50"})]}),!H&&(0,d.jsxs)("div",{className:"grid gap-1 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:"API Key"}),(0,d.jsx)("span",{className:"material-symbols-outlined hidden text-text-muted text-[14px] sm:inline",children:"arrow_forward"}),(0,d.jsx)("input",{type:"text",list:"mitm-api-keys",value:o,onChange:a=>p(a.target.value),placeholder:b?"Enter or pick API key":"sk_ezrouter (default)",className:"flex-1 min-w-0 px-2 py-1.5 bg-surface rounded border border-border text-xs text-text-main focus:outline-none focus:ring-1 focus:ring-primary/50"}),a?.length>0&&(0,d.jsx)("datalist",{id:"mitm-api-keys",children:a.map(a=>(0,d.jsx)("option",{value:a.key,children:a.name||a.key},a.id))})]})]}),(0,d.jsxs)("div",{className:"flex flex-col gap-2 sm:flex-row sm:flex-wrap sm:items-center","data-i18n-skip":"true",children:[g?.certExists&&!g?.certTrusted&&(0,d.jsxs)("button",{onClick:()=>E("trust-cert"),disabled:i,className:"flex w-full items-center justify-center gap-1.5 rounded-lg border border-yellow-500/30 bg-yellow-500/10 px-4 py-2 text-xs font-medium text-yellow-600 transition-colors hover:bg-yellow-500/20 disabled:opacity-50 sm:w-auto sm:py-1.5",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[16px]",children:"verified_user"}),"Trust Cert"]}),H?(0,d.jsxs)("button",{onClick:()=>E("stop"),disabled:i,className:"flex w-full items-center justify-center gap-1.5 rounded-lg border border-red-500/30 bg-red-500/10 px-4 py-2 text-xs font-medium text-red-500 transition-colors hover:bg-red-500/20 disabled:opacity-50 sm:w-auto sm:py-1.5",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[16px]",children:"stop_circle"}),"Stop Server"]}):(0,d.jsxs)("button",{onClick:()=>E("start"),disabled:i||!g||A&&!C,title:A&&!C?"Administrator required":void 0,className:"flex w-full items-center justify-center gap-1.5 rounded-lg border border-primary/30 bg-primary/10 px-4 py-2 text-xs font-medium text-primary transition-colors hover:bg-primary/20 disabled:opacity-50 sm:w-auto sm:py-1.5",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[16px]",children:"play_circle"}),"Start Server"]}),H&&(0,d.jsx)("p",{className:"text-xs text-text-muted",children:"Enable DNS per tool below to activate interception"})]}),u&&(0,d.jsxs)("div",{className:"flex items-start gap-2 px-2 py-1.5 rounded text-xs bg-red-500/10 text-red-600 dark:text-red-400 border border-red-500/20",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mt-0.5 shrink-0",children:"error"}),(0,d.jsx)("span",{children:u})]}),A&&!C&&(0,d.jsxs)("div",{className:"flex items-center gap-2 px-2 py-1.5 rounded text-xs bg-red-500/10 text-red-600 border border-red-500/20",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"shield_lock"}),(0,d.jsx)("span",{children:"Administrator required — restart EzRouter as Administrator to use MITM"})]})]})}),k&&(0,d.jsx)("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/50 backdrop-blur-sm",children:(0,d.jsxs)("div",{className:"mx-4 flex w-full max-w-sm flex-col gap-4 rounded-xl border border-border bg-surface p-5 shadow-xl sm:p-6",children:[(0,d.jsx)("h3",{className:"font-semibold text-text-main",children:"Sudo Password Required"}),(0,d.jsxs)("div",{className:"flex items-start gap-3 p-3 bg-yellow-500/10 border border-yellow-500/30 rounded-lg",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-yellow-500 text-[20px]",children:"warning"}),(0,d.jsx)("p",{className:"text-xs text-text-muted",children:"Required for SSL certificate and server startup"})]}),(0,d.jsx)(f.pd,{type:"password",placeholder:"Enter sudo password",value:m,onChange:a=>n(a.target.value),onKeyDown:a=>{"Enter"!==a.key||i||G()}}),s&&(0,d.jsxs)("div",{className:"flex items-center gap-2 px-2 py-1.5 rounded text-xs bg-red-500/10 text-red-600",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"error"}),(0,d.jsx)("span",{children:s})]}),(0,d.jsxs)("div",{className:"flex items-center justify-end gap-2",children:[(0,d.jsx)(f.$n,{variant:"ghost",size:"sm",onClick:()=>{l(!1),n(""),t(null)},disabled:i,children:"Cancel"}),(0,d.jsx)(f.$n,{variant:"primary",size:"sm",onClick:G,loading:i,children:"Confirm"})]})]})}),y&&(0,d.jsx)("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/50 backdrop-blur-sm",children:(0,d.jsxs)("div",{className:"mx-4 flex w-full max-w-md flex-col gap-4 rounded-xl border border-border bg-surface p-5 shadow-xl sm:p-6",children:[(0,d.jsx)("h3",{className:"font-semibold text-text-main",children:"Port 443 Already In Use"}),(0,d.jsxs)("div",{className:"flex items-start gap-3 p-3 bg-yellow-500/10 border border-yellow-500/30 rounded-lg",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-yellow-500 text-[20px]",children:"warning"}),(0,d.jsxs)("div",{className:"flex flex-col gap-1 text-xs text-text-muted",children:[(0,d.jsx)("p",{children:"Port 443 is currently used by another process:"}),(0,d.jsxs)("p",{className:"font-mono text-text-main","data-i18n-skip":"true",children:[y.owner.name," (PID ",y.owner.pid,")"]}),(0,d.jsx)("p",{children:"Kill this process to start MITM Server?"})]})]}),(0,d.jsxs)("div",{className:"flex items-center justify-end gap-2",children:[(0,d.jsx)(f.$n,{variant:"ghost",size:"sm",onClick:()=>{z(null),j(!1)},disabled:i,children:"Cancel"}),(0,d.jsx)(f.$n,{variant:"primary",size:"sm",onClick:()=>{F("start",y?.password||"",!0)},loading:i,children:"Kill & Start"})]})]})})]})}var ao=c(36811);function ap({tool:a,isExpanded:b,onToggle:c,serverRunning:h,dnsActive:i,hasCachedPassword:j,needsSudoPassword:k,isWin:l,apiKeys:m,activeProviders:n,hasActiveProviders:o,modelAliases:p={},cloudEnabled:q,onDnsChange:r}){let[s,t]=(0,e.useState)(!1),[u,v]=(0,e.useState)(null),[w,x]=(0,e.useState)(!1),[y,z]=(0,e.useState)(""),[A,B]=(0,e.useState)(null),[C,D]=(0,e.useState)(null),[E,F]=(0,e.useState)({}),[G,H]=(0,e.useState)(!1),[I,J]=(0,e.useState)(null),K=ao.TOOL_HOSTS[a.id]??[],L=l||j||!1===k,M=(0,e.useCallback)(async b=>{try{await fetch("/api/cli-tools/antigravity-mitm/alias",{method:"PUT",headers:{"Content-Type":"application/json"},body:JSON.stringify({tool:a.id,mappings:b})})}catch{}},[a.id]),N=(a,b)=>{F(c=>({...c,[a]:b}))},O=()=>{if(!h)return;let a=i?"disable":"enable";L?P(a,""):(B(a),x(!0),D(null))},P=async(b,c)=>{t(!0),v(null);try{let d=await fetch("/api/cli-tools/antigravity-mitm",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({tool:a.id,action:b,sudoPassword:c})}),e=await d.json();if(!d.ok)throw Error(e.error||"Failed to toggle DNS");"enable"===b&&v(`Restart ${a.name} to apply changes`),x(!1),z(""),r?.(e)}catch{}finally{t(!1),B(null)}},Q=()=>{y.trim()?P(A,y):D("Sudo password is required")};return(0,d.jsxs)(d.Fragment,{children:[(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:a.image,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 flex-wrap items-center gap-2",children:[(0,d.jsx)("h3",{className:"font-medium text-sm",children:a.name}),h?i?(0,d.jsx)(f.Ex,{variant:"success",size:"sm",children:"Active"}):(0,d.jsx)(f.Ex,{variant:"warning",size:"sm",children:"DNS off"}):(0,d.jsx)(f.Ex,{variant:"default",size:"sm",children:"Server off"})]}),(0,d.jsxs)("p",{className:"text-xs text-text-muted sm:truncate",children:["Intercept ",a.name," requests via MITM proxy"]})]})]}),(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:[K.length>0&&(0,d.jsxs)("div",{className:"mt-2 rounded-md border border-border bg-surface/50 px-2 py-1.5",children:[(0,d.jsx)("p",{className:"text-[10px] font-medium tracking-wide text-text-main/80 mb-1",children:"Edit hosts file manually to add the following entries:"}),(0,d.jsx)("ul",{className:"list-none space-y-0.5 font-mono text-[10px] text-text-muted break-all",children:K.map(a=>(0,d.jsxs)("li",{children:["127.0.0.1 ",a]},a))})]}),(0,d.jsxs)("div",{className:"flex flex-col gap-0.5 text-[11px] text-text-muted px-1",children:[(0,d.jsxs)("p",{children:["Toggle DNS to redirect ",a.name," traffic through EzRouter via MITM."]}),!i&&(0,d.jsx)("p",{className:"text-amber-600 text-[10px] mt-1",children:"⚠️ Enable DNS to edit model mappings"})]}),a.defaultModels?.length>0&&(0,d.jsx)("div",{className:"flex flex-col gap-2",children:a.defaultModels.map(a=>(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[9rem_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",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:E[a.alias]||"",onChange:b=>N(a.alias,b.target.value),onBlur:b=>{var c,d;return c=a.alias,d=b.target.value,void M({...E,[c]:d})},placeholder:"provider/model-id",disabled:!i,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?"opacity-50 cursor-not-allowed":""}`}),E[a.alias]&&(0,d.jsx)("button",{onClick:()=>{N(a.alias,""),M({...E,[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:()=>{J(a.alias),H(!0)},disabled:!o||!i,className:`rounded border px-2 py-2 text-xs transition-colors sm:py-1.5 ${o&&i?"bg-surface border-border hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Select"})]},a.alias))}),a.defaultModels?.length===0&&(0,d.jsx)("p",{className:"text-xs text-text-muted px-1",children:"Model mappings will be available soon."}),(0,d.jsxs)("div",{className:"flex flex-col gap-2 sm:items-start",children:[i?(0,d.jsxs)("button",{onClick:O,disabled:!h||s,className:"flex w-full items-center justify-center gap-1.5 rounded-lg border border-red-500/30 bg-red-500/10 px-4 py-2 text-xs font-medium text-red-500 transition-colors hover:bg-red-500/20 disabled:cursor-not-allowed disabled:opacity-50 sm:w-auto sm:py-1.5",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[16px]",children:"stop_circle"}),"Stop DNS"]}):(0,d.jsxs)("button",{onClick:O,disabled:!h||s,className:"flex w-full items-center justify-center gap-1.5 rounded-lg border border-primary/30 bg-primary/10 px-4 py-2 text-xs font-medium text-primary transition-colors hover:bg-primary/20 disabled:cursor-not-allowed disabled:opacity-50 sm:w-auto sm:py-1.5",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[16px]",children:"play_circle"}),"Start DNS"]}),u&&(0,d.jsxs)("div",{className:"flex items-center gap-2 px-2 py-1.5 rounded text-xs text-amber-500",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"warning"}),(0,d.jsx)("span",{children:u})]})]})]})]}),w&&(0,d.jsx)("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/50 backdrop-blur-sm",children:(0,d.jsxs)("div",{className:"mx-4 flex w-full max-w-sm flex-col gap-4 rounded-xl border border-border bg-surface p-5 shadow-xl sm:p-6",children:[(0,d.jsx)("h3",{className:"font-semibold text-text-main",children:"Sudo Password Required"}),(0,d.jsxs)("div",{className:"flex items-start gap-3 p-3 bg-yellow-500/10 border border-yellow-500/30 rounded-lg",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-yellow-500 text-[20px]",children:"warning"}),(0,d.jsx)("p",{className:"text-xs text-text-muted",children:"Required to modify /etc/hosts and flush DNS cache"})]}),(0,d.jsx)(f.pd,{type:"password",placeholder:"Enter sudo password",value:y,onChange:a=>z(a.target.value),onKeyDown:a=>{"Enter"!==a.key||s||Q()}}),C&&(0,d.jsxs)("div",{className:"flex items-center gap-2 px-2 py-1.5 rounded text-xs bg-red-500/10 text-red-600",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"error"}),(0,d.jsx)("span",{children:C})]}),(0,d.jsxs)("div",{className:"flex items-center justify-end gap-2",children:[(0,d.jsx)(f.$n,{variant:"ghost",size:"sm",onClick:()=>{x(!1),z(""),D(null)},disabled:s,children:"Cancel"}),(0,d.jsx)(f.$n,{variant:"primary",size:"sm",onClick:Q,loading:s,children:"Confirm"})]})]})}),G&&(0,d.jsx)(f.rq,{isOpen:G,onClose:()=>H(!1),onSelect:a=>{if(!I||a.isPlaceholder)return;let b={...E,[I]:a.value};F(b),M(b)},selectedModel:I?E[I]:null,activeProviders:n,modelAliases:p,title:`Select model for ${I}`})]})}function aq({tool:a,isExpanded:b,onToggle:c,baseUrl:h,hasActiveProviders:i,apiKeys:j,activeProviders:k,cloudEnabled:l,initialStatus:m,tunnelEnabled:n,tunnelPublicUrl:o,tailscaleEnabled:p,tailscaleUrl:r}){let s,t,[v,w]=(0,e.useState)(m||null),[y,z]=(0,e.useState)(!1),[A,B]=(0,e.useState)(!1),[C,D]=(0,e.useState)(!1),[F,G]=(0,e.useState)(null),[H,I]=(0,e.useState)(""),[J,K]=(0,e.useState)(""),[L,M]=(0,e.useState)({}),[N,O]=(0,e.useState)(null),[P,Q]=(0,e.useState)(!1),[R,S]=(0,e.useState)({}),[T,U]=(0,e.useState)(!1),[V,W]=(0,e.useState)("");(0,e.useRef)(!1);let X=v?.settings?.models?.providers?.["9router"]?.baseUrl||"",Y=(()=>{if(!v?.installed)return null;let a=v.settings?.models?.providers?.["9router"];return a?E(a.baseUrl,{tunnelPublicUrl:o,tailscaleUrl:r})?"configured":"other":"not_configured"})(),Z=async()=>{z(!0);try{let a=await fetch("/api/cli-tools/openclaw-settings"),b=await a.json();w(b)}catch(a){w({installed:!1,error:a.message})}finally{z(!1)}},$=()=>{let a=V||"http://127.0.0.1:20126";return a.endsWith("/v1")?a:`${a}/v1`},_=async()=>{B(!0),G(null);try{let a=H?.trim()||(j?.length>0?j[0].key:null)||(l?null:"sk_ezrouter"),b=await fetch("/api/cli-tools/openclaw-settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({baseUrl:$(),apiKey:a,model:J,agentModels:L})}),c=await b.json();b.ok?(q($(),{tunnelPublicUrl:o,tailscaleUrl:r}),G({type:"success",text:"Settings applied successfully!"}),Z()):G({type:"error",text:c.error||"Failed to apply settings"})}catch(a){G({type:"error",text:a.message})}finally{B(!1)}},aa=async()=>{D(!0),G(null);try{let a=await fetch("/api/cli-tools/openclaw-settings",{method:"DELETE"}),b=await a.json();a.ok?(G({type:"success",text:"Settings reset successfully!"}),K(""),I(""),Z()):G({type:"error",text:b.error||"Failed to reset settings"})}catch(a){G({type:"error",text:a.message})}finally{D(!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/openclaw.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"===Y&&(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"===Y&&(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"===Y&&(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:[y&&(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 Open Claw CLI..."})]}),!y&&v&&!v.installed&&(0,d.jsx)("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:"Open Claw 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.jsx)("div",{className:"flex items-center gap-2 pl-9",children:(0,d.jsxs)(f.$n,{variant:"secondary",size:"sm",onClick:()=>U(!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"]})})]})}),!y&&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)(u,{value:V||((s=V||"http://127.0.0.1:20126").endsWith("/v1")?s:`${s}/v1`),onChange:W,requiresExternalUrl:a.requiresExternalUrl,tunnelEnabled:n,tunnelPublicUrl:o,tailscaleEnabled:p,tailscaleUrl:r,currentUrl:X})]}),v?.settings?.models?.providers?.["9router"]?.baseUrl&&(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:v.settings.models.providers["9router"].baseUrl})]}),(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)(x,{value:H,onChange:I,apiKeys:j,cloudEnabled:l})]}),(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:"Default 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:J,onChange:a=>K(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"}),J&&(0,d.jsx)("button",{onClick:()=>K(""),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:()=>{O(null),Q(!0)},disabled:!i,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 ${i?"bg-surface border-border text-text-main hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Select"})]}),(v.agents||[]).filter(a=>a.agentDir).map(a=>(0,d.jsxs)("div",{className:"flex items-center gap-2 pl-4",children:[(0,d.jsxs)("span",{className:"w-32 shrink-0 text-xs text-primary text-right truncate",title:a.name||a.id,children:["Agent ",a.name||a.id]}),(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:L[a.id]||"",onChange:b=>M(c=>({...c,[a.id]:b.target.value})),placeholder:`default (${J||"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"}),L[a.id]&&(0,d.jsx)("button",{onClick:()=>M(b=>({...b,[a.id]:""})),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:()=>{O(a.id),Q(!0)},disabled:!i,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 ${i?"bg-surface border-border text-text-main hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Select"})]},a.id))]}),F&&(0,d.jsxs)("div",{className:`flex items-center gap-2 px-2 py-1.5 rounded text-xs ${"success"===F.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"===F.type?"check_circle":"error"}),(0,d.jsx)("span",{children:F.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:_,disabled:!J,loading:A,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:aa,disabled:!v?.has9Router,loading:C,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:()=>U(!0),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"content_copy"}),"Manual Config"]})]})]})]}),P&&(0,d.jsx)(f.rq,{isOpen:P,onClose:()=>Q(!1),onSelect:a=>{N?(M(b=>({...b,[N]:a.value})),O(null)):K(a.value),Q(!1)},selectedModel:J,activeProviders:k,modelAliases:R,title:"Select Model for Open Claw"}),(0,d.jsx)(f.uR,{isOpen:T,onClose:()=>U(!1),title:"Open Claw - Manual Configuration",configs:(t=H&&H.trim()?H:l?"<API_KEY_FROM_DASHBOARD>":"sk_ezrouter",[{filename:"~/.openclaw/openclaw.json",content:JSON.stringify({agents:{defaults:{model:{primary:`9router/${J||"provider/model-id"}`}}},models:{providers:{"9router":{baseUrl:$(),apiKey:t,api:"openai-completions",models:[{id:J||"provider/model-id",name:(J||"provider/model-id").split("/").pop()}]}}}},null,2)}])})]})}function ar({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,t,v,w,[y,z]=(0,e.useState)(l||null),[A,B]=(0,e.useState)(!1),[D,F]=(0,e.useState)(!1),[G,H]=(0,e.useState)(!1),[I,J]=(0,e.useState)(null),[K,L]=(0,e.useState)(!1),[M,N]=(0,e.useState)(""),[O,P]=(0,e.useState)(""),[Q,R]=(0,e.useState)(""),[S,T]=(0,e.useState)(!1),[U,V]=(0,e.useState)(!1),[W,X]=(0,e.useState)({}),[Y,Z]=(0,e.useState)(!1),[$,_]=(0,e.useState)(""),[aa,ab]=(0,e.useState)([]),[ac,ad]=(0,e.useState)(""),ae=(0,e.useRef)([]),af=async a=>{try{let b=M&&M.trim()||k?M:"sk_ezrouter",c=a.includes(ac)?ac:a[0]||"";await fetch("/api/cli-tools/opencode-settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({baseUrl:ai(),apiKey:b,models:a,activeModel:c,subagentModel:Q})})}catch(a){console.log("Error saving models:",a)}},ag=y?.config?.provider?.["9router"]?.options?.baseURL||"",ah=y?.installed?y.config&&y.has9Router?E(y.config?.provider?.["9router"]?.options?.baseURL||"",{tunnelPublicUrl:n,tailscaleUrl:p})?"configured":"other":"not_configured":null,ai=()=>{let a=$||h;return a.endsWith("/v1")?a:`${a}/v1`},aj=async()=>{B(!0);try{let a=await fetch("/api/cli-tools/opencode-settings"),b=await a.json();z(b)}catch(a){z({installed:!1,error:a.message})}finally{B(!1)}},ak=async()=>{F(!0),J(null);try{let a=M&&M.trim()||k?M:"sk_ezrouter",b=await fetch("/api/cli-tools/opencode-settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({baseUrl:ai(),apiKey:a,models:aa,activeModel:""===ac?"":ac||aa[0],subagentModel:Q})}),c=await b.json();b.ok?(q(ai(),{tunnelPublicUrl:n,tailscaleUrl:p}),J({type:"success",text:"Settings applied successfully!"}),aj()):J({type:"error",text:c.error||"Failed to apply settings"})}catch(a){J({type:"error",text:a.message})}finally{F(!1)}},al=async()=>{H(!0),J(null);try{let a=await fetch("/api/cli-tools/opencode-settings",{method:"DELETE"}),b=await a.json();a.ok?(J({type:"success",text:"Settings reset successfully!"}),P(""),R(""),ab([]),ad(""),aj()):J({type:"error",text:b.error||"Failed to reset settings"})}catch(a){J({type:"error",text:a.message})}finally{H(!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/opencode.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"===ah&&(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"===ah&&(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"===ah&&(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:[A&&(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 OpenCode CLI..."})]}),!A&&y&&!y.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:"OpenCode 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.jsx)(C,{tool:"opencode",baseUrl:ai(),apiKey:M,model:ac||aa[0]||"",className:"!bg-yellow-500/20 !border-yellow-500/40 !text-yellow-700 dark:!text-yellow-300 hover:!bg-yellow-500/30"}),(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:()=>L(!K),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[18px] mr-1",children:K?"expand_less":"help"}),K?"Hide":"How to Install"]})]})]}),K&&(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:"}),(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 opencode-ai"})]}),(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:"opencode"})," to verify."]})]})]})]}),!A&&y?.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)(u,{value:$||$||`${h}/v1`,onChange:_,requiresExternalUrl:a.requiresExternalUrl,tunnelEnabled:m,tunnelPublicUrl:n,tailscaleEnabled:o,tailscaleUrl:p,currentUrl:ag})]}),y?.config?.provider?.["9router"]?.options?.baseURL&&(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:y.config.provider["9router"].options.baseURL})]}),(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)(x,{value:M,onChange:N,apiKeys:i,cloudEnabled:k})]}),(0,d.jsxs)("div",{className:"grid grid-cols-1 gap-1.5 sm:grid-cols-[8rem_auto_1fr] sm:items-start sm:gap-2",children:[(0,d.jsx)("span",{className:"w-32 shrink-0 text-sm font-semibold text-text-main text-right pt-1",children:"Models"}),(0,d.jsx)("span",{className:"material-symbols-outlined text-text-muted text-[14px] mt-1.5",children:"arrow_forward"}),(0,d.jsxs)("div",{className:"flex-1 flex flex-col gap-2",children:[(0,d.jsx)("div",{className:"flex flex-wrap gap-1.5 min-h-[28px] px-2 py-1.5 bg-surface rounded border border-border",children:0===aa.length?(0,d.jsx)("span",{className:"text-xs text-text-muted",children:"No models selected"}):aa.map(a=>(0,d.jsxs)("span",{onClick:async()=>{if(a===ac)try{(await fetch("/api/cli-tools/opencode-settings",{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({clearActiveModel:!0})})).ok&&(ad(""),aj())}catch(a){console.log("Error clearing active model:",a)}else ad(a)},className:`inline-flex items-center gap-1 px-2 py-0.5 rounded text-xs cursor-pointer transition-colors ${a===ac?"bg-primary/10 text-primary border border-primary":"bg-black/5 dark:bg-white/5 text-text-muted border border-transparent hover:border-border"}`,title:a===ac?"Click to clear active model":"Click to set as active",children:[a===ac&&(0,d.jsx)("span",{className:"material-symbols-outlined text-[10px]",children:"star"}),a,(0,d.jsx)("button",{onClick:async b=>{b.stopPropagation();try{if((await fetch(`/api/cli-tools/opencode-settings?model=${encodeURIComponent(a)}`,{method:"DELETE"})).ok){let b=aa.filter(b=>b!==a);ab(b),ac===a&&ad(""),aj()}}catch(a){console.log("Error removing model:",a)}},className:"ml-0.5 hover:text-red-500",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-[12px]",children:"close"})})]},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)("button",{onClick:()=>T(!0),disabled:!j?.length,className:`px-2 py-1 rounded border text-xs transition-colors ${j?.length?"bg-surface border-border text-text-main hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Add Model"}),(0,d.jsx)("span",{className:"text-xs text-text-muted",children:aa.length>0&&ac?(0,d.jsxs)(d.Fragment,{children:["Active: ",(0,d.jsx)("span",{className:"text-primary",children:ac})]}):aa.length>0?(0,d.jsx)("span",{className:"text-yellow-500",children:"Click a model to set/clear active"}):"Select models to add"})]})]})]}),(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.jsx)("input",{type:"text",value:Q,onChange:a=>R(a.target.value),placeholder:O||"provider/model-id (defaults to main model)",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)("button",{onClick:()=>V(!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"}),Q&&(0,d.jsx)("button",{onClick:()=>R(""),className:"p-1 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"})})]})]}),I&&(0,d.jsxs)("div",{className:`flex items-center gap-2 px-2 py-1.5 rounded text-xs ${"success"===I.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"===I.type?"check_circle":"error"}),(0,d.jsx)("span",{children:I.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:ak,disabled:0===aa.length,loading:D,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:al,disabled:!y.has9Router,loading:G,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"]}),(0,d.jsx)(C,{tool:"opencode",baseUrl:ai(),apiKey:M,model:ac||aa[0]||"",variant:"ghost"})]})]})]}),S&&(0,d.jsx)(f.rq,{isOpen:S,onClose:()=>{T(!1),af(ae.current)},onSelect:a=>{!aa.includes(a.value)&&(ab([...aa,a.value]),ac||ad(a.value))},onDeselect:a=>{let b=aa.filter(b=>b!==a.value);ab(b),ac===a.value&&ad(b[0]||"")},selectedModel:null,activeProviders:j,modelAliases:W,addedModelValues:aa,closeOnSelect:!1,title:"Add Model for OpenCode"}),U&&(0,d.jsx)(f.rq,{isOpen:U,onClose:()=>V(!1),onSelect:a=>{R(a.value),V(!1)},selectedModel:Q,activeProviders:j,modelAliases:W,title:"Select Subagent Model for OpenCode"}),(0,d.jsx)(f.uR,{isOpen:Y,onClose:()=>Z(!1),title:"OpenCode - Manual Configuration",configs:(r=M&&M.trim()?M:k?"<API_KEY_FROM_DASHBOARD>":"sk_ezrouter",s=aa.length>0?aa:["provider/model-id"],t=ac||aa[0]||s[0],v=Q||t,w={},s.forEach(a=>{w[a]={name:a,modalities:{input:["text","image"],output:["text"]}}}),[{filename:"~/.config/opencode/opencode.json",content:JSON.stringify({provider:{"9router":{npm:"@ai-sdk/openai-compatible",options:{baseURL:ai(),apiKey:r},models:w}},model:`9router/${t}`,agent:{explorer:{description:"Fast explorer subagent for codebase exploration",mode:"subagent",model:`9router/${v}`}}},null,2)}])})]})}},36811:a=>{a.exports={TOOL_HOSTS:{antigravity:["daily-cloudcode-pa.googleapis.com","cloudcode-pa.googleapis.com"],copilot:["api.individual.githubcopilot.com"],kiro:["runtime.us-east-1.kiro.dev","q.us-east-1.amazonaws.com","codewhisperer.us-east-1.amazonaws.com"],cursor:["api2.cursor.sh"]}}},62911:(a,b,c)=>{c.d(b,{dM:()=>e,wn:()=>d});let d={antigravity:{id:"antigravity",name:"Antigravity",image:"/providers/antigravity.png",color:"#4285F4",description:"Google Antigravity IDE with MITM",configType:"mitm",mitmDomain:"daily-cloudcode-pa.googleapis.com",modelAliases:["gemini-3.8-flash-high","gemini-3.8-flash-medium","gemini-3.8-flash-low","gemini-3.7-flash-high","gemini-3.7-flash-medium","gemini-3.7-flash-low","gemini-3.7-flash","gemini-3.6-flash-high","gemini-3.6-flash-medium","gemini-3.6-flash-low","gemini-3-flash-agent","gemini-3.1-pro-low","gemini-pro-agent","claude-sonnet-5-5","claude-sonnet-5-5-low","claude-sonnet-5-5-medium","claude-sonnet-5-5-high","claude-opus-5-5","claude-opus-5-5-low","claude-opus-5-5-medium","claude-opus-5-5-high","claude-sonnet-4-6","claude-opus-4-6-thinking","gpt-oss-120b-medium","gemini-3-flash"],defaultModels:[{id:"gemini-3.8-flash-high",name:"Gemini 3.8 Flash (High)",alias:"gemini-3.8-flash-high"},{id:"gemini-3.8-flash-medium",name:"Gemini 3.8 Flash (Medium)",alias:"gemini-3.8-flash-medium"},{id:"gemini-3.8-flash-low",name:"Gemini 3.8 Flash (Low)",alias:"gemini-3.8-flash-low"},{id:"gemini-3.7-flash-high",name:"Gemini 3.7 Flash (High)",alias:"gemini-3.7-flash-high"},{id:"gemini-3.7-flash-medium",name:"Gemini 3.7 Flash (Medium)",alias:"gemini-3.7-flash-medium"},{id:"gemini-3.7-flash-low",name:"Gemini 3.7 Flash (Low)",alias:"gemini-3.7-flash-low"},{id:"gemini-3.7-flash",name:"Gemini 3.7 Flash",alias:"gemini-3.7-flash",mandatory:!0},{id:"gemini-3.6-flash-high",name:"Gemini 3.6 Flash (High)",alias:"gemini-3.6-flash-high"},{id:"gemini-3.6-flash-medium",name:"Gemini 3.6 Flash (Medium)",alias:"gemini-3.6-flash-medium"},{id:"gemini-3.6-flash-low",name:"Gemini 3.6 Flash (Low)",alias:"gemini-3.6-flash-low"},{id:"gemini-3-flash-agent",name:"Gemini 3.5 Flash (High)",alias:"gemini-3-flash-agent"},{id:"gemini-3.1-pro-low",name:"Gemini 3.1 Pro (Low)",alias:"gemini-3.1-pro-low"},{id:"gemini-pro-agent",name:"Gemini 3.1 Pro (High)",alias:"gemini-pro-agent"},{id:"claude-sonnet-5-5",name:"Claude Sonnet 5.5 (Thinking)",alias:"claude-sonnet-5-5"},{id:"claude-sonnet-5-5-low",name:"Claude Sonnet 5.5 (Low)",alias:"claude-sonnet-5-5-low"},{id:"claude-sonnet-5-5-medium",name:"Claude Sonnet 5.5 (Medium)",alias:"claude-sonnet-5-5-medium"},{id:"claude-sonnet-5-5-high",name:"Claude Sonnet 5.5 (High)",alias:"claude-sonnet-5-5-high"},{id:"claude-opus-5-5",name:"Claude Opus 5.5 (Thinking)",alias:"claude-opus-5-5"},{id:"claude-opus-5-5-low",name:"Claude Opus 5.5 (Low)",alias:"claude-opus-5-5-low"},{id:"claude-opus-5-5-medium",name:"Claude Opus 5.5 (Medium)",alias:"claude-opus-5-5-medium"},{id:"claude-opus-5-5-high",name:"Claude Opus 5.5 (High)",alias:"claude-opus-5-5-high"},{id:"claude-sonnet-4-6",name:"Claude Sonnet 4.6 (Thinking)",alias:"claude-sonnet-4-6"},{id:"claude-opus-4-6-thinking",name:"Claude Opus 4.6 (Thinking)",alias:"claude-opus-4-6-thinking"},{id:"gpt-oss-120b-medium",name:"GPT-OSS 120B (Medium)",alias:"gpt-oss-120b-medium"},{id:"gemini-3-flash",name:"Gemini 3 Flash (Command)",alias:"gemini-3-flash"}]},copilot:{id:"copilot",name:"GitHub Copilot",image:"/providers/copilot.png",color:"#1F6FEB",description:"GitHub Copilot IDE with MITM",configType:"mitm",mitmDomain:"api.individual.githubcopilot.com",modelAliases:["gpt-5-mini","gpt-5.4-nano","claude-haiku-4.5","gpt-4o","gpt-4.1"],defaultModels:[{id:"gpt-5-mini",name:"GPT-5 mini",alias:"gpt-5-mini"},{id:"gpt-5.4-nano",name:"GPT-5.4 nano",alias:"gpt-5.4-nano"},{id:"claude-haiku-4.5",name:"Claude Haiku 4.5",alias:"claude-haiku-4.5"},{id:"gpt-4o",name:"GPT-4o",alias:"gpt-4o"},{id:"gpt-4.1",name:"GPT-4.1",alias:"gpt-4.1"}]},kiro:{id:"kiro",name:"Kiro",image:"/providers/kiro.png",color:"#FF6B00",description:"Kiro IDE with MITM",configType:"mitm",mitmDomain:"runtime.us-east-1.kiro.dev",defaultModels:[{id:"auto",name:"Auto (Kiro Agent)",alias:"auto"},{id:"claude-sonnet-5",name:"Claude Sonnet 5",alias:"claude-sonnet-5"},{id:"claude-sonnet-4.5",name:"Claude Sonnet 4.5",alias:"claude-sonnet-4.5"},{id:"claude-sonnet-4",name:"Claude Sonnet 4",alias:"claude-sonnet-4"},{id:"claude-haiku-4.5",name:"Claude Haiku 4.5",alias:"claude-haiku-4.5"},{id:"deepseek-3.2",name:"DeepSeek 3.2",alias:"deepseek-3.2"},{id:"minimax-m2.5",name:"MiniMax M2.5",alias:"minimax-m2.5"},{id:"minimax-m2.1",name:"MiniMax M2.1",alias:"minimax-m2.1"},{id:"gpt-5.6-sol",name:"GPT 5.6 Sol",alias:"gpt-5.6-sol",contextLength:272e3,rateMultiplier:2.4},{id:"gpt-5.6-terra",name:"GPT 5.6 Terra",alias:"gpt-5.6-terra",contextLength:272e3,rateMultiplier:1.2},{id:"gpt-5.6-luna",name:"GPT 5.6 Luna",alias:"gpt-5.6-luna",contextLength:272e3,rateMultiplier:.6},{id:"glm-5",name:"GLM 5",alias:"glm-5"},{id:"simple-task",name:"Qwen3 Coder Next",alias:"simple-task"}]}},e={claude:{id:"claude",name:"Claude Code",image:"/providers/claude.png",color:"#D97757",description:"Anthropic Claude Code CLI",configType:"env",envVars:{baseUrl:"ANTHROPIC_BASE_URL",model:"ANTHROPIC_MODEL",opusModel:"ANTHROPIC_DEFAULT_OPUS_MODEL",sonnetModel:"ANTHROPIC_DEFAULT_SONNET_MODEL",fableModel:"ANTHROPIC_DEFAULT_FABLE_MODEL",haikuModel:"ANTHROPIC_DEFAULT_HAIKU_MODEL"},modelAliases:["default","sonnet","opus","fable","haiku","opusplan"],settingsFile:"~/.claude/settings.json",defaultModels:[{id:"fable",name:"Claude Fable",alias:"fable",envKey:"ANTHROPIC_DEFAULT_FABLE_MODEL",defaultValue:"cc/claude-fable-5"},{id:"opus",name:"Claude Opus",alias:"opus",envKey:"ANTHROPIC_DEFAULT_OPUS_MODEL",defaultValue:"cc/claude-opus-5"},{id:"sonnet",name:"Claude Sonnet",alias:"sonnet",envKey:"ANTHROPIC_DEFAULT_SONNET_MODEL",defaultValue:"cc/claude-sonnet-5"},{id:"haiku",name:"Claude Haiku",alias:"haiku",envKey:"ANTHROPIC_DEFAULT_HAIKU_MODEL",defaultValue:"cc/claude-haiku-4-5-20251001"}]},openclaw:{id:"openclaw",name:"Open Claw",image:"/providers/openclaw.png",color:"#FF6B35",description:"Open Claw AI Assistant",configType:"custom"},codex:{id:"codex",name:"OpenAI Codex CLI / App",image:"/providers/codex.png",color:"#10A37F",description:"OpenAI Codex CLI",configType:"custom"},opencode:{id:"opencode",name:"OpenCode",image:"/providers/opencode.png",color:"#E87040",description:"OpenCode AI Terminal Assistant",configType:"custom"},cowork:{id:"cowork",name:"Claude Cowork",image:"/providers/claude.png",color:"#D97757",description:"Claude Desktop Cowork (third-party inference)",configType:"custom"},hermes:{id:"hermes",name:"Hermes Agent",image:"/providers/hermes.png",color:"#8B5CF6",description:"Nous Research self-improving AI agent",configType:"custom",roles:[{id:"delegation",label:"Delegation (subagents)"},{id:"vision",label:"Vision"},{id:"web_extract",label:"Web Extract"},{id:"compression",label:"Compression"},{id:"title_generation",label:"Title Generation"},{id:"approval",label:"Approval"},{id:"skills_hub",label:"Skills Hub"},{id:"mcp",label:"MCP"},{id:"memory_query_rewrite",label:"Memory Query Rewrite"},{id:"background_review",label:"Background Review"},{id:"curator",label:"Curator"},{id:"monitor",label:"Monitor"}]},droid:{id:"droid",name:"Factory Droid",image:"/providers/droid.png",color:"#00D4FF",description:"Factory Droid AI Assistant",configType:"custom"},cursor:{id:"cursor",name:"Cursor",image:"/providers/cursor.png",color:"#000000",description:"Cursor AI Code Editor",configType:"guide",requiresExternalUrl:!0,notes:[{type:"warning",text:"Requires Cursor Pro account to use this feature."},{type:"cloudCheck",text:"Cursor routes requests through its own server, so local endpoint is not supported. Please enable Tunnel or Cloud Endpoint in Settings."}],guideSteps:[{step:1,title:"Open Settings",desc:"Go to Settings → Models"},{step:2,title:"Enable OpenAI API",desc:'Enable "OpenAI API key" option'},{step:3,title:"Base URL",value:"{{baseUrl}}",copyable:!0},{step:4,title:"API Key",type:"apiKeySelector"},{step:5,title:"Add Custom Model",desc:'Click "View All Model" → "Add Custom Model"'},{step:6,title:"Select Model",type:"modelSelector"}]},cline:{id:"cline",name:"Cline",image:"/providers/cline.png",color:"#5B9BD5",description:"Cline AI Coding Assistant",configType:"custom"},kilo:{id:"kilo",name:"Kilo Code",image:"/providers/kilocode.png",color:"#FF6B6B",description:"Kilo Code AI Assistant",configType:"custom"},roo:{id:"roo",name:"Roo",image:"/providers/roo.png",color:"#FF6B6B",description:"Roo AI Assistant",configType:"guide",guideSteps:[{step:1,title:"Open Settings",desc:"Go to Roo Settings panel"},{step:2,title:"Select Provider",desc:"Choose API Provider → Ollama"},{step:3,title:"Base URL",value:"{{baseUrl}}",copyable:!0},{step:4,title:"API Key",type:"apiKeySelector"},{step:5,title:"Select Model",type:"modelSelector"}]},continue:{id:"continue",name:"Continue",image:"/providers/continue.png",color:"#7C3AED",description:"Continue AI Assistant",configType:"guide",guideSteps:[{step:1,title:"Open Config",desc:"Open Continue configuration file"},{step:2,title:"API Key",type:"apiKeySelector"},{step:3,title:"Select Model",type:"modelSelector"},{step:4,title:"Add Model Config",desc:"Add the following configuration to your models array:"}],codeBlock:{language:"json",code:`{
103
103
  "apiBase": "{{baseUrl}}",
104
104
  "title": "{{model}}",
105
105
  "model": "{{model}}",