@hilbras/omnihilbras 2.7.0 → 2.9.0

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 (642) hide show
  1. package/app/.next-cli-build/BUILD_ID +1 -1
  2. package/app/.next-cli-build/app-path-routes-manifest.json +23 -23
  3. package/app/.next-cli-build/build-manifest.json +3 -3
  4. package/app/.next-cli-build/react-loadable-manifest.json +1 -1
  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/endpoint/page.js +1 -1
  21. package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page.js.nft.json +1 -1
  22. package/app/.next-cli-build/server/app/(dashboard)/dashboard/endpoint/page_client-reference-manifest.js +1 -1
  23. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page.js +1 -1
  24. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page.js.nft.json +1 -1
  25. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/[id]/page_client-reference-manifest.js +1 -1
  26. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page.js +1 -1
  27. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page.js.nft.json +1 -1
  28. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/[kind]/page_client-reference-manifest.js +1 -1
  29. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page.js +1 -1
  30. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page.js.nft.json +1 -1
  31. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/combo/[id]/page_client-reference-manifest.js +1 -1
  32. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page.js +1 -1
  33. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page.js.nft.json +1 -1
  34. package/app/.next-cli-build/server/app/(dashboard)/dashboard/media-providers/web/page_client-reference-manifest.js +1 -1
  35. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page.js +1 -1
  36. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page.js.nft.json +1 -1
  37. package/app/.next-cli-build/server/app/(dashboard)/dashboard/mitm/page_client-reference-manifest.js +1 -1
  38. package/app/.next-cli-build/server/app/(dashboard)/dashboard/page.js +1 -1
  39. package/app/.next-cli-build/server/app/(dashboard)/dashboard/page.js.nft.json +1 -1
  40. package/app/.next-cli-build/server/app/(dashboard)/dashboard/page_client-reference-manifest.js +1 -1
  41. package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page.js +1 -1
  42. package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page.js.nft.json +1 -1
  43. package/app/.next-cli-build/server/app/(dashboard)/dashboard/profile/page_client-reference-manifest.js +1 -1
  44. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page.js +1 -1
  45. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page.js.nft.json +1 -1
  46. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/[id]/page_client-reference-manifest.js +1 -1
  47. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page.js +1 -1
  48. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page.js.nft.json +1 -1
  49. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/new/page_client-reference-manifest.js +1 -1
  50. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page.js +1 -1
  51. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page.js.nft.json +1 -1
  52. package/app/.next-cli-build/server/app/(dashboard)/dashboard/providers/page_client-reference-manifest.js +1 -1
  53. package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page.js +1 -1
  54. package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page.js.nft.json +1 -1
  55. package/app/.next-cli-build/server/app/(dashboard)/dashboard/proxy-pools/page_client-reference-manifest.js +1 -1
  56. package/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page.js +1 -1
  57. package/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page.js.nft.json +1 -1
  58. package/app/.next-cli-build/server/app/(dashboard)/dashboard/pxpipe/page_client-reference-manifest.js +1 -1
  59. package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page.js +1 -1
  60. package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page.js.nft.json +1 -1
  61. package/app/.next-cli-build/server/app/(dashboard)/dashboard/quota/page_client-reference-manifest.js +1 -1
  62. package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page.js +1 -1
  63. package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page.js.nft.json +1 -1
  64. package/app/.next-cli-build/server/app/(dashboard)/dashboard/skills/page_client-reference-manifest.js +1 -1
  65. package/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page.js +1 -1
  66. package/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page.js.nft.json +1 -1
  67. package/app/.next-cli-build/server/app/(dashboard)/dashboard/token-saver/page_client-reference-manifest.js +1 -1
  68. package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page.js +1 -1
  69. package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page.js.nft.json +1 -1
  70. package/app/.next-cli-build/server/app/(dashboard)/dashboard/translator/page_client-reference-manifest.js +1 -1
  71. package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page.js +1 -1
  72. package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page.js.nft.json +1 -1
  73. package/app/.next-cli-build/server/app/(dashboard)/dashboard/usage/page_client-reference-manifest.js +1 -1
  74. package/app/.next-cli-build/server/app/_global-error/page.js.nft.json +1 -1
  75. package/app/.next-cli-build/server/app/_global-error/page_client-reference-manifest.js +1 -1
  76. package/app/.next-cli-build/server/app/_global-error.html +1 -1
  77. package/app/.next-cli-build/server/app/_global-error.rsc +1 -1
  78. package/app/.next-cli-build/server/app/_global-error.segments/_full.segment.rsc +1 -1
  79. package/app/.next-cli-build/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
  80. package/app/.next-cli-build/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  81. package/app/.next-cli-build/server/app/_not-found/page.js +1 -1
  82. package/app/.next-cli-build/server/app/_not-found/page.js.nft.json +1 -1
  83. package/app/.next-cli-build/server/app/_not-found/page_client-reference-manifest.js +1 -1
  84. package/app/.next-cli-build/server/app/_not-found.html +1 -1
  85. package/app/.next-cli-build/server/app/_not-found.rsc +5 -5
  86. package/app/.next-cli-build/server/app/_not-found.segments/_full.segment.rsc +5 -5
  87. package/app/.next-cli-build/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +5 -5
  88. package/app/.next-cli-build/server/app/_not-found.segments/_tree.segment.rsc +2 -2
  89. package/app/.next-cli-build/server/app/api/auth/login/route.js +1 -1
  90. package/app/.next-cli-build/server/app/api/auth/login/route.js.nft.json +1 -1
  91. package/app/.next-cli-build/server/app/api/auth/logout/route.js +1 -1
  92. package/app/.next-cli-build/server/app/api/auth/logout/route.js.nft.json +1 -1
  93. package/app/.next-cli-build/server/app/api/auth/oidc/callback/route.js +1 -1
  94. package/app/.next-cli-build/server/app/api/auth/oidc/callback/route.js.nft.json +1 -1
  95. package/app/.next-cli-build/server/app/api/auth/oidc/start/route.js +1 -1
  96. package/app/.next-cli-build/server/app/api/auth/oidc/start/route.js.nft.json +1 -1
  97. package/app/.next-cli-build/server/app/api/auth/oidc/test/route.js +1 -1
  98. package/app/.next-cli-build/server/app/api/auth/oidc/test/route.js.nft.json +1 -1
  99. package/app/.next-cli-build/server/app/api/auth/reset-password/route.js +1 -1
  100. package/app/.next-cli-build/server/app/api/auth/reset-password/route.js.nft.json +1 -1
  101. package/app/.next-cli-build/server/app/api/auth/saml/acs/route.js +1 -1
  102. package/app/.next-cli-build/server/app/api/auth/saml/acs/route.js.nft.json +1 -1
  103. package/app/.next-cli-build/server/app/api/auth/saml/metadata/route.js +1 -1
  104. package/app/.next-cli-build/server/app/api/auth/saml/metadata/route.js.nft.json +1 -1
  105. package/app/.next-cli-build/server/app/api/auth/saml/start/route.js +1 -1
  106. package/app/.next-cli-build/server/app/api/auth/saml/start/route.js.nft.json +1 -1
  107. package/app/.next-cli-build/server/app/api/auth/saml/test/route.js +1 -1
  108. package/app/.next-cli-build/server/app/api/auth/saml/test/route.js.nft.json +1 -1
  109. package/app/.next-cli-build/server/app/api/auth/status/route.js +1 -1
  110. package/app/.next-cli-build/server/app/api/auth/status/route.js.nft.json +1 -1
  111. package/app/.next-cli-build/server/app/api/cli-tools/all-statuses/route.js +5 -5
  112. package/app/.next-cli-build/server/app/api/cli-tools/all-statuses/route.js.nft.json +1 -1
  113. package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/alias/route.js.nft.json +1 -1
  114. package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/route.js +1 -1
  115. package/app/.next-cli-build/server/app/api/cli-tools/antigravity-mitm/route.js.nft.json +1 -1
  116. package/app/.next-cli-build/server/app/api/cli-tools/claude-settings/route.js +2 -2
  117. package/app/.next-cli-build/server/app/api/cli-tools/claude-settings/route.js.nft.json +1 -1
  118. package/app/.next-cli-build/server/app/api/cli-tools/cline-settings/route.js +2 -2
  119. package/app/.next-cli-build/server/app/api/cli-tools/cline-settings/route.js.nft.json +1 -1
  120. package/app/.next-cli-build/server/app/api/cli-tools/codewhale-settings/route.js +1 -1
  121. package/app/.next-cli-build/server/app/api/cli-tools/codewhale-settings/route.js.nft.json +1 -1
  122. package/app/.next-cli-build/server/app/api/cli-tools/codex-profiles/route.js.nft.json +1 -1
  123. package/app/.next-cli-build/server/app/api/cli-tools/codex-settings/route.js +1 -1
  124. package/app/.next-cli-build/server/app/api/cli-tools/codex-settings/route.js.nft.json +1 -1
  125. package/app/.next-cli-build/server/app/api/cli-tools/copilot-settings/route.js +1 -1
  126. package/app/.next-cli-build/server/app/api/cli-tools/copilot-settings/route.js.nft.json +1 -1
  127. package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-registry/route.js.nft.json +1 -1
  128. package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-tools/route.js +2 -2
  129. package/app/.next-cli-build/server/app/api/cli-tools/cowork-mcp-tools/route.js.nft.json +1 -1
  130. package/app/.next-cli-build/server/app/api/cli-tools/cowork-settings/route.js +1 -1
  131. package/app/.next-cli-build/server/app/api/cli-tools/cowork-settings/route.js.nft.json +1 -1
  132. package/app/.next-cli-build/server/app/api/cli-tools/crush-settings/route.js +1 -1
  133. package/app/.next-cli-build/server/app/api/cli-tools/crush-settings/route.js.nft.json +1 -1
  134. package/app/.next-cli-build/server/app/api/cli-tools/deepseek-tui-settings/route.js +1 -1
  135. package/app/.next-cli-build/server/app/api/cli-tools/deepseek-tui-settings/route.js.nft.json +1 -1
  136. package/app/.next-cli-build/server/app/api/cli-tools/devin-settings/route.js.nft.json +1 -1
  137. package/app/.next-cli-build/server/app/api/cli-tools/droid-settings/route.js +2 -2
  138. package/app/.next-cli-build/server/app/api/cli-tools/droid-settings/route.js.nft.json +1 -1
  139. package/app/.next-cli-build/server/app/api/cli-tools/forge-settings/route.js +1 -1
  140. package/app/.next-cli-build/server/app/api/cli-tools/forge-settings/route.js.nft.json +1 -1
  141. package/app/.next-cli-build/server/app/api/cli-tools/grok-build-settings/route.js +1 -1
  142. package/app/.next-cli-build/server/app/api/cli-tools/grok-build-settings/route.js.nft.json +1 -1
  143. package/app/.next-cli-build/server/app/api/cli-tools/hermes-profiles/route.js.nft.json +1 -1
  144. package/app/.next-cli-build/server/app/api/cli-tools/hermes-settings/route.js +2 -2
  145. package/app/.next-cli-build/server/app/api/cli-tools/hermes-settings/route.js.nft.json +1 -1
  146. package/app/.next-cli-build/server/app/api/cli-tools/jcode-settings/route.js +3 -3
  147. package/app/.next-cli-build/server/app/api/cli-tools/jcode-settings/route.js.nft.json +1 -1
  148. package/app/.next-cli-build/server/app/api/cli-tools/kilo-settings/route.js +2 -2
  149. package/app/.next-cli-build/server/app/api/cli-tools/kilo-settings/route.js.nft.json +1 -1
  150. package/app/.next-cli-build/server/app/api/cli-tools/omp-settings/route.js +1 -1
  151. package/app/.next-cli-build/server/app/api/cli-tools/omp-settings/route.js.nft.json +1 -1
  152. package/app/.next-cli-build/server/app/api/cli-tools/openclaw-settings/route.js +2 -2
  153. package/app/.next-cli-build/server/app/api/cli-tools/openclaw-settings/route.js.nft.json +1 -1
  154. package/app/.next-cli-build/server/app/api/cli-tools/opencode-settings/route.js +1 -1
  155. package/app/.next-cli-build/server/app/api/cli-tools/opencode-settings/route.js.nft.json +1 -1
  156. package/app/.next-cli-build/server/app/api/cli-tools/pi-settings/route.js +1 -1
  157. package/app/.next-cli-build/server/app/api/cli-tools/pi-settings/route.js.nft.json +1 -1
  158. package/app/.next-cli-build/server/app/api/cli-tools/smelt-settings/route.js +1 -1
  159. package/app/.next-cli-build/server/app/api/cli-tools/smelt-settings/route.js.nft.json +1 -1
  160. package/app/.next-cli-build/server/app/api/combos/[id]/route.js +1 -1
  161. package/app/.next-cli-build/server/app/api/combos/[id]/route.js.nft.json +1 -1
  162. package/app/.next-cli-build/server/app/api/combos/presets/route.js +1 -1
  163. package/app/.next-cli-build/server/app/api/combos/presets/route.js.nft.json +1 -1
  164. package/app/.next-cli-build/server/app/api/combos/route.js +1 -1
  165. package/app/.next-cli-build/server/app/api/combos/route.js.nft.json +1 -1
  166. package/app/.next-cli-build/server/app/api/headroom/extras/route.js +1 -1
  167. package/app/.next-cli-build/server/app/api/headroom/extras/route.js.nft.json +1 -1
  168. package/app/.next-cli-build/server/app/api/headroom/proxy/[...path]/route.js +1 -1
  169. package/app/.next-cli-build/server/app/api/headroom/proxy/[...path]/route.js.nft.json +1 -1
  170. package/app/.next-cli-build/server/app/api/headroom/restart/route.js +1 -1
  171. package/app/.next-cli-build/server/app/api/headroom/restart/route.js.nft.json +1 -1
  172. package/app/.next-cli-build/server/app/api/headroom/start/route.js +1 -1
  173. package/app/.next-cli-build/server/app/api/headroom/start/route.js.nft.json +1 -1
  174. package/app/.next-cli-build/server/app/api/headroom/status/route.js +1 -1
  175. package/app/.next-cli-build/server/app/api/headroom/status/route.js.nft.json +1 -1
  176. package/app/.next-cli-build/server/app/api/headroom/stop/route.js +1 -1
  177. package/app/.next-cli-build/server/app/api/headroom/stop/route.js.nft.json +1 -1
  178. package/app/.next-cli-build/server/app/api/health/route.js.nft.json +1 -1
  179. package/app/.next-cli-build/server/app/api/init/route.js.nft.json +1 -1
  180. package/app/.next-cli-build/server/app/api/keys/[id]/route.js +1 -1
  181. package/app/.next-cli-build/server/app/api/keys/[id]/route.js.nft.json +1 -1
  182. package/app/.next-cli-build/server/app/api/keys/route.js +1 -1
  183. package/app/.next-cli-build/server/app/api/keys/route.js.nft.json +1 -1
  184. package/app/.next-cli-build/server/app/api/locale/route.js.nft.json +1 -1
  185. package/app/.next-cli-build/server/app/api/mcp/[plugin]/message/route.js.nft.json +1 -1
  186. package/app/.next-cli-build/server/app/api/mcp/[plugin]/sse/route.js.nft.json +1 -1
  187. package/app/.next-cli-build/server/app/api/media-providers/tts/deepgram/voices/route.js +1 -1
  188. package/app/.next-cli-build/server/app/api/media-providers/tts/deepgram/voices/route.js.nft.json +1 -1
  189. package/app/.next-cli-build/server/app/api/media-providers/tts/elevenlabs/voices/route.js +1 -1
  190. package/app/.next-cli-build/server/app/api/media-providers/tts/elevenlabs/voices/route.js.nft.json +1 -1
  191. package/app/.next-cli-build/server/app/api/media-providers/tts/inworld/voices/route.js +1 -1
  192. package/app/.next-cli-build/server/app/api/media-providers/tts/inworld/voices/route.js.nft.json +1 -1
  193. package/app/.next-cli-build/server/app/api/media-providers/tts/minimax/voices/route.js +1 -1
  194. package/app/.next-cli-build/server/app/api/media-providers/tts/minimax/voices/route.js.nft.json +1 -1
  195. package/app/.next-cli-build/server/app/api/media-providers/tts/voices/route.js +1 -1
  196. package/app/.next-cli-build/server/app/api/media-providers/tts/voices/route.js.nft.json +1 -1
  197. package/app/.next-cli-build/server/app/api/models/alias/route.js +1 -1
  198. package/app/.next-cli-build/server/app/api/models/alias/route.js.nft.json +1 -1
  199. package/app/.next-cli-build/server/app/api/models/availability/route.js +1 -1
  200. package/app/.next-cli-build/server/app/api/models/availability/route.js.nft.json +1 -1
  201. package/app/.next-cli-build/server/app/api/models/catalog-sync/route.js +1 -1
  202. package/app/.next-cli-build/server/app/api/models/catalog-sync/route.js.nft.json +1 -1
  203. package/app/.next-cli-build/server/app/api/models/chat/route.js +1 -1
  204. package/app/.next-cli-build/server/app/api/models/chat/route.js.nft.json +1 -1
  205. package/app/.next-cli-build/server/app/api/models/custom/route.js +1 -1
  206. package/app/.next-cli-build/server/app/api/models/custom/route.js.nft.json +1 -1
  207. package/app/.next-cli-build/server/app/api/models/disabled/route.js.nft.json +1 -1
  208. package/app/.next-cli-build/server/app/api/models/route.js +1 -1
  209. package/app/.next-cli-build/server/app/api/models/route.js.nft.json +1 -1
  210. package/app/.next-cli-build/server/app/api/models/test/route.js +1 -1
  211. package/app/.next-cli-build/server/app/api/models/test/route.js.nft.json +1 -1
  212. package/app/.next-cli-build/server/app/api/models/test-batch/route.js +2 -2
  213. package/app/.next-cli-build/server/app/api/models/test-batch/route.js.nft.json +1 -1
  214. package/app/.next-cli-build/server/app/api/oauth/[provider]/[action]/route.js +1 -1
  215. package/app/.next-cli-build/server/app/api/oauth/[provider]/[action]/route.js.nft.json +1 -1
  216. package/app/.next-cli-build/server/app/api/oauth/codex/bulk-import/route.js +1 -1
  217. package/app/.next-cli-build/server/app/api/oauth/codex/bulk-import/route.js.nft.json +1 -1
  218. package/app/.next-cli-build/server/app/api/oauth/codex/import-token/route.js +1 -1
  219. package/app/.next-cli-build/server/app/api/oauth/codex/import-token/route.js.nft.json +1 -1
  220. package/app/.next-cli-build/server/app/api/oauth/cursor/auto-import/route.js.nft.json +1 -1
  221. package/app/.next-cli-build/server/app/api/oauth/cursor/import/route.js +1 -1
  222. package/app/.next-cli-build/server/app/api/oauth/cursor/import/route.js.nft.json +1 -1
  223. package/app/.next-cli-build/server/app/api/oauth/gitlab/pat/route.js +1 -1
  224. package/app/.next-cli-build/server/app/api/oauth/gitlab/pat/route.js.nft.json +1 -1
  225. package/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/route.js +1 -1
  226. package/app/.next-cli-build/server/app/api/oauth/grok-cli/bulk-import/route.js.nft.json +1 -1
  227. package/app/.next-cli-build/server/app/api/oauth/iflow/cookie/route.js +1 -1
  228. package/app/.next-cli-build/server/app/api/oauth/iflow/cookie/route.js.nft.json +1 -1
  229. package/app/.next-cli-build/server/app/api/oauth/kiro/api-key/route.js +1 -1
  230. package/app/.next-cli-build/server/app/api/oauth/kiro/api-key/route.js.nft.json +1 -1
  231. package/app/.next-cli-build/server/app/api/oauth/kiro/auto-import/route.js.nft.json +1 -1
  232. package/app/.next-cli-build/server/app/api/oauth/kiro/import/route.js +1 -1
  233. package/app/.next-cli-build/server/app/api/oauth/kiro/import/route.js.nft.json +1 -1
  234. package/app/.next-cli-build/server/app/api/oauth/kiro/import-cli-proxy/route.js +1 -1
  235. package/app/.next-cli-build/server/app/api/oauth/kiro/import-cli-proxy/route.js.nft.json +1 -1
  236. package/app/.next-cli-build/server/app/api/oauth/kiro/social-authorize/route.js +1 -1
  237. package/app/.next-cli-build/server/app/api/oauth/kiro/social-authorize/route.js.nft.json +1 -1
  238. package/app/.next-cli-build/server/app/api/oauth/kiro/social-exchange/route.js +1 -1
  239. package/app/.next-cli-build/server/app/api/oauth/kiro/social-exchange/route.js.nft.json +1 -1
  240. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/api-key/route.js +1 -1
  241. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/api-key/route.js.nft.json +1 -1
  242. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/auto-import/route.js +1 -1
  243. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/auto-import/route.js.nft.json +1 -1
  244. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/login/start/route.js.nft.json +1 -1
  245. package/app/.next-cli-build/server/app/api/oauth/xiaomi-mimo/login/status/route.js.nft.json +1 -1
  246. package/app/.next-cli-build/server/app/api/oauth/zed/auto-import/route.js.nft.json +1 -1
  247. package/app/.next-cli-build/server/app/api/oauth/zed/import/route.js +1 -1
  248. package/app/.next-cli-build/server/app/api/oauth/zed/import/route.js.nft.json +1 -1
  249. package/app/.next-cli-build/server/app/api/pricing/route.js +1 -1
  250. package/app/.next-cli-build/server/app/api/pricing/route.js.nft.json +1 -1
  251. package/app/.next-cli-build/server/app/api/provider-nodes/[id]/route.js +1 -1
  252. package/app/.next-cli-build/server/app/api/provider-nodes/[id]/route.js.nft.json +1 -1
  253. package/app/.next-cli-build/server/app/api/provider-nodes/route.js +1 -1
  254. package/app/.next-cli-build/server/app/api/provider-nodes/route.js.nft.json +1 -1
  255. package/app/.next-cli-build/server/app/api/provider-nodes/validate/route.js +1 -1
  256. package/app/.next-cli-build/server/app/api/provider-nodes/validate/route.js.nft.json +1 -1
  257. package/app/.next-cli-build/server/app/api/providers/[id]/models/route.js +1 -1
  258. package/app/.next-cli-build/server/app/api/providers/[id]/models/route.js.nft.json +1 -1
  259. package/app/.next-cli-build/server/app/api/providers/[id]/overrides/route.js +1 -1
  260. package/app/.next-cli-build/server/app/api/providers/[id]/overrides/route.js.nft.json +1 -1
  261. package/app/.next-cli-build/server/app/api/providers/[id]/route.js +1 -1
  262. package/app/.next-cli-build/server/app/api/providers/[id]/route.js.nft.json +1 -1
  263. package/app/.next-cli-build/server/app/api/providers/[id]/test/route.js +1 -1
  264. package/app/.next-cli-build/server/app/api/providers/[id]/test/route.js.nft.json +1 -1
  265. package/app/.next-cli-build/server/app/api/providers/[id]/test-models/route.js +1 -1
  266. package/app/.next-cli-build/server/app/api/providers/[id]/test-models/route.js.nft.json +1 -1
  267. package/app/.next-cli-build/server/app/api/providers/client/route.js +1 -1
  268. package/app/.next-cli-build/server/app/api/providers/client/route.js.nft.json +1 -1
  269. package/app/.next-cli-build/server/app/api/providers/kilo/free-models/route.js.nft.json +1 -1
  270. package/app/.next-cli-build/server/app/api/providers/route.js +1 -1
  271. package/app/.next-cli-build/server/app/api/providers/route.js.nft.json +1 -1
  272. package/app/.next-cli-build/server/app/api/providers/suggested-models/route.js +1 -1
  273. package/app/.next-cli-build/server/app/api/providers/suggested-models/route.js.nft.json +1 -1
  274. package/app/.next-cli-build/server/app/api/providers/test-batch/route.js +1 -1
  275. package/app/.next-cli-build/server/app/api/providers/test-batch/route.js.nft.json +1 -1
  276. package/app/.next-cli-build/server/app/api/providers/validate/route.js +1 -1
  277. package/app/.next-cli-build/server/app/api/providers/validate/route.js.nft.json +1 -1
  278. package/app/.next-cli-build/server/app/api/providers/web-session/[id]/route.js +1 -1
  279. package/app/.next-cli-build/server/app/api/providers/web-session/[id]/route.js.nft.json +1 -1
  280. package/app/.next-cli-build/server/app/api/proxy-pools/[id]/route.js +1 -1
  281. package/app/.next-cli-build/server/app/api/proxy-pools/[id]/route.js.nft.json +1 -1
  282. package/app/.next-cli-build/server/app/api/proxy-pools/[id]/test/route.js +1 -1
  283. package/app/.next-cli-build/server/app/api/proxy-pools/[id]/test/route.js.nft.json +1 -1
  284. package/app/.next-cli-build/server/app/api/proxy-pools/cloudflare-deploy/route.js +1 -1
  285. package/app/.next-cli-build/server/app/api/proxy-pools/cloudflare-deploy/route.js.nft.json +1 -1
  286. package/app/.next-cli-build/server/app/api/proxy-pools/deno-deploy/route.js +1 -1
  287. package/app/.next-cli-build/server/app/api/proxy-pools/deno-deploy/route.js.nft.json +1 -1
  288. package/app/.next-cli-build/server/app/api/proxy-pools/netlify-deploy/route.js +1 -1
  289. package/app/.next-cli-build/server/app/api/proxy-pools/netlify-deploy/route.js.nft.json +1 -1
  290. package/app/.next-cli-build/server/app/api/proxy-pools/route.js +1 -1
  291. package/app/.next-cli-build/server/app/api/proxy-pools/route.js.nft.json +1 -1
  292. package/app/.next-cli-build/server/app/api/proxy-pools/vercel-deploy/route.js +1 -1
  293. package/app/.next-cli-build/server/app/api/proxy-pools/vercel-deploy/route.js.nft.json +1 -1
  294. package/app/.next-cli-build/server/app/api/pxpipe/health/route.js +1 -1
  295. package/app/.next-cli-build/server/app/api/pxpipe/health/route.js.nft.json +1 -1
  296. package/app/.next-cli-build/server/app/api/pxpipe/install/route.js +1 -1
  297. package/app/.next-cli-build/server/app/api/pxpipe/install/route.js.nft.json +1 -1
  298. package/app/.next-cli-build/server/app/api/pxpipe/logs/route.js +1 -1
  299. package/app/.next-cli-build/server/app/api/pxpipe/logs/route.js.nft.json +1 -1
  300. package/app/.next-cli-build/server/app/api/pxpipe/restart/route.js +1 -1
  301. package/app/.next-cli-build/server/app/api/pxpipe/restart/route.js.nft.json +1 -1
  302. package/app/.next-cli-build/server/app/api/pxpipe/start/route.js +1 -1
  303. package/app/.next-cli-build/server/app/api/pxpipe/start/route.js.nft.json +1 -1
  304. package/app/.next-cli-build/server/app/api/pxpipe/stats/route.js +1 -1
  305. package/app/.next-cli-build/server/app/api/pxpipe/stats/route.js.nft.json +1 -1
  306. package/app/.next-cli-build/server/app/api/pxpipe/status/route.js +1 -1
  307. package/app/.next-cli-build/server/app/api/pxpipe/status/route.js.nft.json +1 -1
  308. package/app/.next-cli-build/server/app/api/pxpipe/stop/route.js +1 -1
  309. package/app/.next-cli-build/server/app/api/pxpipe/stop/route.js.nft.json +1 -1
  310. package/app/.next-cli-build/server/app/api/settings/database/route.js +1 -1
  311. package/app/.next-cli-build/server/app/api/settings/database/route.js.nft.json +1 -1
  312. package/app/.next-cli-build/server/app/api/settings/proxy-test/route.js.nft.json +1 -1
  313. package/app/.next-cli-build/server/app/api/settings/require-login/route.js +1 -1
  314. package/app/.next-cli-build/server/app/api/settings/require-login/route.js.nft.json +1 -1
  315. package/app/.next-cli-build/server/app/api/settings/route.js +1 -1
  316. package/app/.next-cli-build/server/app/api/settings/route.js.nft.json +1 -1
  317. package/app/.next-cli-build/server/app/api/shutdown/route.js.nft.json +1 -1
  318. package/app/.next-cli-build/server/app/api/tags/route.js.nft.json +1 -1
  319. package/app/.next-cli-build/server/app/api/translator/console-logs/route.js +1 -1
  320. package/app/.next-cli-build/server/app/api/translator/console-logs/route.js.nft.json +1 -1
  321. package/app/.next-cli-build/server/app/api/translator/console-logs/stream/route.js +1 -1
  322. package/app/.next-cli-build/server/app/api/translator/console-logs/stream/route.js.nft.json +1 -1
  323. package/app/.next-cli-build/server/app/api/translator/load/route.js.nft.json +1 -1
  324. package/app/.next-cli-build/server/app/api/translator/save/route.js.nft.json +1 -1
  325. package/app/.next-cli-build/server/app/api/translator/send/route.js +1 -1
  326. package/app/.next-cli-build/server/app/api/translator/send/route.js.nft.json +1 -1
  327. package/app/.next-cli-build/server/app/api/translator/translate/route.js +1 -1
  328. package/app/.next-cli-build/server/app/api/translator/translate/route.js.nft.json +1 -1
  329. package/app/.next-cli-build/server/app/api/tunnel/disable/route.js.nft.json +1 -1
  330. package/app/.next-cli-build/server/app/api/tunnel/enable/route.js.nft.json +1 -1
  331. package/app/.next-cli-build/server/app/api/tunnel/status/route.js.nft.json +1 -1
  332. package/app/.next-cli-build/server/app/api/tunnel/tailscale-check/route.js.nft.json +1 -1
  333. package/app/.next-cli-build/server/app/api/tunnel/tailscale-disable/route.js.nft.json +1 -1
  334. package/app/.next-cli-build/server/app/api/tunnel/tailscale-enable/route.js.nft.json +1 -1
  335. package/app/.next-cli-build/server/app/api/tunnel/tailscale-install/route.js.nft.json +1 -1
  336. package/app/.next-cli-build/server/app/api/usage/[connectionId]/claude-reset/route.js +1 -1
  337. package/app/.next-cli-build/server/app/api/usage/[connectionId]/claude-reset/route.js.nft.json +1 -1
  338. package/app/.next-cli-build/server/app/api/usage/[connectionId]/codex-reset-credits/route.js +1 -1
  339. package/app/.next-cli-build/server/app/api/usage/[connectionId]/codex-reset-credits/route.js.nft.json +1 -1
  340. package/app/.next-cli-build/server/app/api/usage/[connectionId]/route.js +1 -1
  341. package/app/.next-cli-build/server/app/api/usage/[connectionId]/route.js.nft.json +1 -1
  342. package/app/.next-cli-build/server/app/api/usage/chart/route.js +1 -1
  343. package/app/.next-cli-build/server/app/api/usage/chart/route.js.nft.json +1 -1
  344. package/app/.next-cli-build/server/app/api/usage/history/route.js +1 -1
  345. package/app/.next-cli-build/server/app/api/usage/history/route.js.nft.json +1 -1
  346. package/app/.next-cli-build/server/app/api/usage/logs/route.js +1 -1
  347. package/app/.next-cli-build/server/app/api/usage/logs/route.js.nft.json +1 -1
  348. package/app/.next-cli-build/server/app/api/usage/providers/route.js +1 -1
  349. package/app/.next-cli-build/server/app/api/usage/providers/route.js.nft.json +1 -1
  350. package/app/.next-cli-build/server/app/api/usage/request-details/route.js +1 -1
  351. package/app/.next-cli-build/server/app/api/usage/request-details/route.js.nft.json +1 -1
  352. package/app/.next-cli-build/server/app/api/usage/request-logs/route.js +1 -1
  353. package/app/.next-cli-build/server/app/api/usage/request-logs/route.js.nft.json +1 -1
  354. package/app/.next-cli-build/server/app/api/usage/stats/route.js +1 -1
  355. package/app/.next-cli-build/server/app/api/usage/stats/route.js.nft.json +1 -1
  356. package/app/.next-cli-build/server/app/api/usage/stream/route.js +1 -1
  357. package/app/.next-cli-build/server/app/api/usage/stream/route.js.nft.json +1 -1
  358. package/app/.next-cli-build/server/app/api/v1/api/chat/route.js +1 -1
  359. package/app/.next-cli-build/server/app/api/v1/api/chat/route.js.nft.json +1 -1
  360. package/app/.next-cli-build/server/app/api/v1/audio/speech/route.js +1 -1
  361. package/app/.next-cli-build/server/app/api/v1/audio/speech/route.js.nft.json +1 -1
  362. package/app/.next-cli-build/server/app/api/v1/audio/transcriptions/route.js +1 -1
  363. package/app/.next-cli-build/server/app/api/v1/audio/transcriptions/route.js.nft.json +1 -1
  364. package/app/.next-cli-build/server/app/api/v1/audio/voices/route.js +1 -1
  365. package/app/.next-cli-build/server/app/api/v1/audio/voices/route.js.nft.json +1 -1
  366. package/app/.next-cli-build/server/app/api/v1/chat/completions/route.js +1 -1
  367. package/app/.next-cli-build/server/app/api/v1/chat/completions/route.js.nft.json +1 -1
  368. package/app/.next-cli-build/server/app/api/v1/embeddings/route.js +1 -1
  369. package/app/.next-cli-build/server/app/api/v1/embeddings/route.js.nft.json +1 -1
  370. package/app/.next-cli-build/server/app/api/v1/images/generations/route.js +3 -2
  371. package/app/.next-cli-build/server/app/api/v1/images/generations/route.js.nft.json +1 -1
  372. package/app/.next-cli-build/server/app/api/v1/messages/count_tokens/route.js.nft.json +1 -1
  373. package/app/.next-cli-build/server/app/api/v1/messages/route.js +1 -1
  374. package/app/.next-cli-build/server/app/api/v1/messages/route.js.nft.json +1 -1
  375. package/app/.next-cli-build/server/app/api/v1/models/[...model]/route.js +1 -1
  376. package/app/.next-cli-build/server/app/api/v1/models/[...model]/route.js.nft.json +1 -1
  377. package/app/.next-cli-build/server/app/api/v1/models/info/route.js +1 -1
  378. package/app/.next-cli-build/server/app/api/v1/models/info/route.js.nft.json +1 -1
  379. package/app/.next-cli-build/server/app/api/v1/models/route.js +1 -1
  380. package/app/.next-cli-build/server/app/api/v1/models/route.js.nft.json +1 -1
  381. package/app/.next-cli-build/server/app/api/v1/responses/compact/route.js +1 -1
  382. package/app/.next-cli-build/server/app/api/v1/responses/compact/route.js.nft.json +1 -1
  383. package/app/.next-cli-build/server/app/api/v1/responses/route.js +1 -1
  384. package/app/.next-cli-build/server/app/api/v1/responses/route.js.nft.json +1 -1
  385. package/app/.next-cli-build/server/app/api/v1/route.js +1 -1
  386. package/app/.next-cli-build/server/app/api/v1/route.js.nft.json +1 -1
  387. package/app/.next-cli-build/server/app/api/v1/search/route.js +1 -1
  388. package/app/.next-cli-build/server/app/api/v1/search/route.js.nft.json +1 -1
  389. package/app/.next-cli-build/server/app/api/v1/systemone/route.js +1 -1
  390. package/app/.next-cli-build/server/app/api/v1/systemone/route.js.nft.json +1 -1
  391. package/app/.next-cli-build/server/app/api/v1/videos/[id]/route.js +1 -1
  392. package/app/.next-cli-build/server/app/api/v1/videos/[id]/route.js.nft.json +1 -1
  393. package/app/.next-cli-build/server/app/api/v1/videos/edits/route.js +1 -1
  394. package/app/.next-cli-build/server/app/api/v1/videos/edits/route.js.nft.json +1 -1
  395. package/app/.next-cli-build/server/app/api/v1/videos/extensions/route.js +1 -1
  396. package/app/.next-cli-build/server/app/api/v1/videos/extensions/route.js.nft.json +1 -1
  397. package/app/.next-cli-build/server/app/api/v1/videos/generations/route.js +1 -1
  398. package/app/.next-cli-build/server/app/api/v1/videos/generations/route.js.nft.json +1 -1
  399. package/app/.next-cli-build/server/app/api/v1/web/fetch/route.js +1 -1
  400. package/app/.next-cli-build/server/app/api/v1/web/fetch/route.js.nft.json +1 -1
  401. package/app/.next-cli-build/server/app/api/v1beta/models/[...path]/route.js +1 -2
  402. package/app/.next-cli-build/server/app/api/v1beta/models/[...path]/route.js.nft.json +1 -1
  403. package/app/.next-cli-build/server/app/api/v1beta/models/route.js +1 -1
  404. package/app/.next-cli-build/server/app/api/v1beta/models/route.js.nft.json +1 -1
  405. package/app/.next-cli-build/server/app/api/version/route.js +1 -1
  406. package/app/.next-cli-build/server/app/api/version/route.js.nft.json +1 -1
  407. package/app/.next-cli-build/server/app/api/version/shutdown/route.js +1 -1
  408. package/app/.next-cli-build/server/app/api/version/shutdown/route.js.nft.json +1 -1
  409. package/app/.next-cli-build/server/app/api/version/update/route.js +1 -1
  410. package/app/.next-cli-build/server/app/api/version/update/route.js.nft.json +1 -1
  411. package/app/.next-cli-build/server/app/callback/page.js +1 -1
  412. package/app/.next-cli-build/server/app/callback/page.js.nft.json +1 -1
  413. package/app/.next-cli-build/server/app/callback/page_client-reference-manifest.js +1 -1
  414. package/app/.next-cli-build/server/app/callback.html +1 -1
  415. package/app/.next-cli-build/server/app/callback.rsc +5 -5
  416. package/app/.next-cli-build/server/app/callback.segments/_full.segment.rsc +5 -5
  417. package/app/.next-cli-build/server/app/callback.segments/_tree.segment.rsc +2 -2
  418. package/app/.next-cli-build/server/app/callback.segments/callback/__PAGE__.segment.rsc +5 -5
  419. package/app/.next-cli-build/server/app/dashboard/basic-chat.html +1 -1
  420. package/app/.next-cli-build/server/app/dashboard/basic-chat.rsc +5 -5
  421. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/!KGRhc2hib2FyZCk/dashboard/basic-chat/__PAGE__.segment.rsc +5 -5
  422. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_full.segment.rsc +5 -5
  423. package/app/.next-cli-build/server/app/dashboard/basic-chat.segments/_tree.segment.rsc +2 -2
  424. package/app/.next-cli-build/server/app/dashboard/cli-tools.html +1 -1
  425. package/app/.next-cli-build/server/app/dashboard/cli-tools.rsc +5 -5
  426. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/!KGRhc2hib2FyZCk/dashboard/cli-tools/__PAGE__.segment.rsc +5 -5
  427. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_full.segment.rsc +5 -5
  428. package/app/.next-cli-build/server/app/dashboard/cli-tools.segments/_tree.segment.rsc +2 -2
  429. package/app/.next-cli-build/server/app/dashboard/combos.html +1 -1
  430. package/app/.next-cli-build/server/app/dashboard/combos.rsc +5 -5
  431. package/app/.next-cli-build/server/app/dashboard/combos.segments/!KGRhc2hib2FyZCk/dashboard/combos/__PAGE__.segment.rsc +5 -5
  432. package/app/.next-cli-build/server/app/dashboard/combos.segments/_full.segment.rsc +5 -5
  433. package/app/.next-cli-build/server/app/dashboard/combos.segments/_tree.segment.rsc +2 -2
  434. package/app/.next-cli-build/server/app/dashboard/endpoint.html +1 -1
  435. package/app/.next-cli-build/server/app/dashboard/endpoint.rsc +7 -7
  436. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/!KGRhc2hib2FyZCk/dashboard/endpoint/__PAGE__.segment.rsc +7 -7
  437. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_full.segment.rsc +7 -7
  438. package/app/.next-cli-build/server/app/dashboard/endpoint.segments/_tree.segment.rsc +2 -2
  439. package/app/.next-cli-build/server/app/dashboard/media-providers/web.html +1 -1
  440. package/app/.next-cli-build/server/app/dashboard/media-providers/web.rsc +5 -5
  441. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/!KGRhc2hib2FyZCk/dashboard/media-providers/web/__PAGE__.segment.rsc +5 -5
  442. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_full.segment.rsc +5 -5
  443. package/app/.next-cli-build/server/app/dashboard/media-providers/web.segments/_tree.segment.rsc +2 -2
  444. package/app/.next-cli-build/server/app/dashboard/mitm.html +1 -1
  445. package/app/.next-cli-build/server/app/dashboard/mitm.rsc +5 -5
  446. package/app/.next-cli-build/server/app/dashboard/mitm.segments/!KGRhc2hib2FyZCk/dashboard/mitm/__PAGE__.segment.rsc +5 -5
  447. package/app/.next-cli-build/server/app/dashboard/mitm.segments/_full.segment.rsc +5 -5
  448. package/app/.next-cli-build/server/app/dashboard/mitm.segments/_tree.segment.rsc +2 -2
  449. package/app/.next-cli-build/server/app/dashboard/profile.html +1 -1
  450. package/app/.next-cli-build/server/app/dashboard/profile.rsc +5 -5
  451. package/app/.next-cli-build/server/app/dashboard/profile.segments/!KGRhc2hib2FyZCk/dashboard/profile/__PAGE__.segment.rsc +5 -5
  452. package/app/.next-cli-build/server/app/dashboard/profile.segments/_full.segment.rsc +5 -5
  453. package/app/.next-cli-build/server/app/dashboard/profile.segments/_tree.segment.rsc +2 -2
  454. package/app/.next-cli-build/server/app/dashboard/providers/new.html +1 -1
  455. package/app/.next-cli-build/server/app/dashboard/providers/new.rsc +5 -5
  456. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/!KGRhc2hib2FyZCk/dashboard/providers/new/__PAGE__.segment.rsc +5 -5
  457. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_full.segment.rsc +5 -5
  458. package/app/.next-cli-build/server/app/dashboard/providers/new.segments/_tree.segment.rsc +2 -2
  459. package/app/.next-cli-build/server/app/dashboard/providers.html +1 -1
  460. package/app/.next-cli-build/server/app/dashboard/providers.rsc +5 -5
  461. package/app/.next-cli-build/server/app/dashboard/providers.segments/!KGRhc2hib2FyZCk/dashboard/providers/__PAGE__.segment.rsc +5 -5
  462. package/app/.next-cli-build/server/app/dashboard/providers.segments/_full.segment.rsc +5 -5
  463. package/app/.next-cli-build/server/app/dashboard/providers.segments/_tree.segment.rsc +2 -2
  464. package/app/.next-cli-build/server/app/dashboard/proxy-pools.html +1 -1
  465. package/app/.next-cli-build/server/app/dashboard/proxy-pools.rsc +5 -5
  466. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/!KGRhc2hib2FyZCk/dashboard/proxy-pools/__PAGE__.segment.rsc +5 -5
  467. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_full.segment.rsc +5 -5
  468. package/app/.next-cli-build/server/app/dashboard/proxy-pools.segments/_tree.segment.rsc +2 -2
  469. package/app/.next-cli-build/server/app/dashboard/pxpipe.html +1 -1
  470. package/app/.next-cli-build/server/app/dashboard/pxpipe.rsc +5 -5
  471. package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/!KGRhc2hib2FyZCk/dashboard/pxpipe/__PAGE__.segment.rsc +5 -5
  472. package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/_full.segment.rsc +5 -5
  473. package/app/.next-cli-build/server/app/dashboard/pxpipe.segments/_tree.segment.rsc +2 -2
  474. package/app/.next-cli-build/server/app/dashboard/quota.html +1 -1
  475. package/app/.next-cli-build/server/app/dashboard/quota.rsc +5 -5
  476. package/app/.next-cli-build/server/app/dashboard/quota.segments/!KGRhc2hib2FyZCk/dashboard/quota/__PAGE__.segment.rsc +5 -5
  477. package/app/.next-cli-build/server/app/dashboard/quota.segments/_full.segment.rsc +5 -5
  478. package/app/.next-cli-build/server/app/dashboard/quota.segments/_tree.segment.rsc +2 -2
  479. package/app/.next-cli-build/server/app/dashboard/settings/pricing/page.js +1 -1
  480. package/app/.next-cli-build/server/app/dashboard/settings/pricing/page.js.nft.json +1 -1
  481. package/app/.next-cli-build/server/app/dashboard/settings/pricing/page_client-reference-manifest.js +1 -1
  482. package/app/.next-cli-build/server/app/dashboard/settings/pricing.html +1 -1
  483. package/app/.next-cli-build/server/app/dashboard/settings/pricing.rsc +5 -5
  484. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_full.segment.rsc +5 -5
  485. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/_tree.segment.rsc +2 -2
  486. package/app/.next-cli-build/server/app/dashboard/settings/pricing.segments/dashboard/settings/pricing/__PAGE__.segment.rsc +5 -5
  487. package/app/.next-cli-build/server/app/dashboard/skills.html +1 -1
  488. package/app/.next-cli-build/server/app/dashboard/skills.rsc +5 -5
  489. package/app/.next-cli-build/server/app/dashboard/skills.segments/!KGRhc2hib2FyZCk/dashboard/skills/__PAGE__.segment.rsc +5 -5
  490. package/app/.next-cli-build/server/app/dashboard/skills.segments/_full.segment.rsc +5 -5
  491. package/app/.next-cli-build/server/app/dashboard/skills.segments/_tree.segment.rsc +2 -2
  492. package/app/.next-cli-build/server/app/dashboard/token-saver.html +1 -1
  493. package/app/.next-cli-build/server/app/dashboard/token-saver.rsc +5 -5
  494. package/app/.next-cli-build/server/app/dashboard/token-saver.segments/!KGRhc2hib2FyZCk/dashboard/token-saver/__PAGE__.segment.rsc +5 -5
  495. package/app/.next-cli-build/server/app/dashboard/token-saver.segments/_full.segment.rsc +5 -5
  496. package/app/.next-cli-build/server/app/dashboard/token-saver.segments/_tree.segment.rsc +2 -2
  497. package/app/.next-cli-build/server/app/dashboard/translator.html +1 -1
  498. package/app/.next-cli-build/server/app/dashboard/translator.rsc +5 -5
  499. package/app/.next-cli-build/server/app/dashboard/translator.segments/!KGRhc2hib2FyZCk/dashboard/translator/__PAGE__.segment.rsc +5 -5
  500. package/app/.next-cli-build/server/app/dashboard/translator.segments/_full.segment.rsc +5 -5
  501. package/app/.next-cli-build/server/app/dashboard/translator.segments/_tree.segment.rsc +2 -2
  502. package/app/.next-cli-build/server/app/dashboard/usage.html +1 -1
  503. package/app/.next-cli-build/server/app/dashboard/usage.rsc +5 -5
  504. package/app/.next-cli-build/server/app/dashboard/usage.segments/!KGRhc2hib2FyZCk/dashboard/usage/__PAGE__.segment.rsc +5 -5
  505. package/app/.next-cli-build/server/app/dashboard/usage.segments/_full.segment.rsc +5 -5
  506. package/app/.next-cli-build/server/app/dashboard/usage.segments/_tree.segment.rsc +2 -2
  507. package/app/.next-cli-build/server/app/dashboard.html +1 -1
  508. package/app/.next-cli-build/server/app/dashboard.rsc +7 -7
  509. package/app/.next-cli-build/server/app/dashboard.segments/!KGRhc2hib2FyZCk/dashboard/__PAGE__.segment.rsc +7 -7
  510. package/app/.next-cli-build/server/app/dashboard.segments/_full.segment.rsc +7 -7
  511. package/app/.next-cli-build/server/app/dashboard.segments/_tree.segment.rsc +2 -2
  512. package/app/.next-cli-build/server/app/favicon.ico/route.js.nft.json +1 -1
  513. package/app/.next-cli-build/server/app/index.html +1 -1
  514. package/app/.next-cli-build/server/app/index.rsc +5 -5
  515. package/app/.next-cli-build/server/app/index.segments/__PAGE__.segment.rsc +5 -5
  516. package/app/.next-cli-build/server/app/index.segments/_full.segment.rsc +5 -5
  517. package/app/.next-cli-build/server/app/index.segments/_tree.segment.rsc +2 -2
  518. package/app/.next-cli-build/server/app/landing/page.js +1 -1
  519. package/app/.next-cli-build/server/app/landing/page.js.nft.json +1 -1
  520. package/app/.next-cli-build/server/app/landing/page_client-reference-manifest.js +1 -1
  521. package/app/.next-cli-build/server/app/landing.html +1 -1
  522. package/app/.next-cli-build/server/app/landing.rsc +5 -5
  523. package/app/.next-cli-build/server/app/landing.segments/_full.segment.rsc +5 -5
  524. package/app/.next-cli-build/server/app/landing.segments/_tree.segment.rsc +2 -2
  525. package/app/.next-cli-build/server/app/landing.segments/landing/__PAGE__.segment.rsc +5 -5
  526. package/app/.next-cli-build/server/app/login/page.js +1 -1
  527. package/app/.next-cli-build/server/app/login/page.js.nft.json +1 -1
  528. package/app/.next-cli-build/server/app/login/page_client-reference-manifest.js +1 -1
  529. package/app/.next-cli-build/server/app/login.html +1 -1
  530. package/app/.next-cli-build/server/app/login.rsc +5 -5
  531. package/app/.next-cli-build/server/app/login.segments/_full.segment.rsc +5 -5
  532. package/app/.next-cli-build/server/app/login.segments/_tree.segment.rsc +2 -2
  533. package/app/.next-cli-build/server/app/login.segments/login/__PAGE__.segment.rsc +5 -5
  534. package/app/.next-cli-build/server/app/manifest.webmanifest/route.js.nft.json +1 -1
  535. package/app/.next-cli-build/server/app/page.js +1 -1
  536. package/app/.next-cli-build/server/app/page.js.nft.json +1 -1
  537. package/app/.next-cli-build/server/app/page_client-reference-manifest.js +1 -1
  538. package/app/.next-cli-build/server/app-paths-manifest.json +23 -23
  539. package/app/.next-cli-build/server/chunks/1004.js +1 -0
  540. package/app/.next-cli-build/server/chunks/1159.js +1 -1
  541. package/app/.next-cli-build/server/chunks/1204.js +19 -0
  542. package/app/.next-cli-build/server/chunks/1260.js +1 -1
  543. package/app/.next-cli-build/server/chunks/1640.js +1 -0
  544. package/app/.next-cli-build/server/chunks/1757.js +1 -1
  545. package/app/.next-cli-build/server/chunks/199.js +1 -0
  546. package/app/.next-cli-build/server/chunks/2132.js +1 -1
  547. package/app/.next-cli-build/server/chunks/24.js +1 -1
  548. package/app/.next-cli-build/server/chunks/241.js +1 -1
  549. package/app/.next-cli-build/server/chunks/2617.js +1 -0
  550. package/app/.next-cli-build/server/chunks/2881.js +1 -0
  551. package/app/.next-cli-build/server/chunks/3099.js +1 -0
  552. package/app/.next-cli-build/server/chunks/3104.js +19 -0
  553. package/app/.next-cli-build/server/chunks/3118.js +1 -1
  554. package/app/.next-cli-build/server/chunks/32.js +1 -0
  555. package/app/.next-cli-build/server/chunks/3276.js +3 -3
  556. package/app/.next-cli-build/server/chunks/{2750.js → 3278.js} +2 -2
  557. package/app/.next-cli-build/server/chunks/3593.js +2 -2
  558. package/app/.next-cli-build/server/chunks/3726.js +1 -1
  559. package/app/.next-cli-build/server/chunks/3817.js +1 -1
  560. package/app/.next-cli-build/server/chunks/3943.js +1 -1
  561. package/app/.next-cli-build/server/chunks/3946.js +1 -0
  562. package/app/.next-cli-build/server/chunks/412.js +1 -1
  563. package/app/.next-cli-build/server/chunks/4123.js +1 -1
  564. package/app/.next-cli-build/server/chunks/4199.js +1 -1
  565. package/app/.next-cli-build/server/chunks/{6155.js → 4217.js} +1 -1
  566. package/app/.next-cli-build/server/chunks/436.js +1 -1
  567. package/app/.next-cli-build/server/chunks/4739.js +2 -2
  568. package/app/.next-cli-build/server/chunks/4780.js +2 -2
  569. package/app/.next-cli-build/server/chunks/4785.js +6 -6
  570. package/app/.next-cli-build/server/chunks/507.js +2 -2
  571. package/app/.next-cli-build/server/chunks/5258.js +2 -2
  572. package/app/.next-cli-build/server/chunks/5537.js +1 -0
  573. package/app/.next-cli-build/server/chunks/5615.js +1 -1
  574. package/app/.next-cli-build/server/chunks/5908.js +1 -0
  575. package/app/.next-cli-build/server/chunks/5961.js +4 -0
  576. package/app/.next-cli-build/server/chunks/6763.js +1 -1
  577. package/app/.next-cli-build/server/chunks/6777.js +1 -1
  578. package/app/.next-cli-build/server/chunks/6844.js +1 -1
  579. package/app/.next-cli-build/server/chunks/698.js +2 -2
  580. package/app/.next-cli-build/server/chunks/7068.js +1 -1
  581. package/app/.next-cli-build/server/chunks/7073.js +1 -0
  582. package/app/.next-cli-build/server/chunks/7525.js +1 -1
  583. package/app/.next-cli-build/server/chunks/7557.js +1 -1
  584. package/app/.next-cli-build/server/chunks/7716.js +1 -1
  585. package/app/.next-cli-build/server/chunks/7955.js +1 -0
  586. package/app/.next-cli-build/server/chunks/7965.js +2 -2
  587. package/app/.next-cli-build/server/chunks/7971.js +1 -1
  588. package/app/.next-cli-build/server/chunks/8287.js +1 -0
  589. package/app/.next-cli-build/server/chunks/8310.js +1 -0
  590. package/app/.next-cli-build/server/chunks/8402.js +1 -1
  591. package/app/.next-cli-build/server/chunks/8520.js +2 -2
  592. package/app/.next-cli-build/server/chunks/{3799.js → 8525.js} +1 -1
  593. package/app/.next-cli-build/server/chunks/8895.js +8 -8
  594. package/app/.next-cli-build/server/chunks/8910.js +2 -2
  595. package/app/.next-cli-build/server/chunks/8913.js +1 -1
  596. package/app/.next-cli-build/server/chunks/8920.js +1 -1
  597. package/app/.next-cli-build/server/chunks/915.js +3 -3
  598. package/app/.next-cli-build/server/chunks/9609.js +1 -1
  599. package/app/.next-cli-build/server/instrumentation.js.nft.json +1 -1
  600. package/app/.next-cli-build/server/middleware-build-manifest.js +1 -1
  601. package/app/.next-cli-build/server/middleware-react-loadable-manifest.js +1 -1
  602. package/app/.next-cli-build/server/middleware.js +24 -16
  603. package/app/.next-cli-build/server/middleware.js.nft.json +1 -1
  604. package/app/.next-cli-build/server/pages/404.html +1 -1
  605. package/app/.next-cli-build/server/pages/500.html +1 -1
  606. package/app/.next-cli-build/static/chunks/5497-b25ea0870709c4a3.js +7 -0
  607. package/app/.next-cli-build/static/chunks/{705-f07c546a169bc3d2.js → 705-b19ee360eb96fbf0.js} +1 -1
  608. package/app/.next-cli-build/static/chunks/7958-2d1c84171a8399d8.js +5 -0
  609. package/app/.next-cli-build/static/chunks/{85-83d08704177e2de9.js → 85-23bf3a4cff99dadd.js} +1 -1
  610. package/app/.next-cli-build/static/chunks/webpack-e231561434c0967e.js +1 -0
  611. package/app/.next-cli-build/static/css/5a593dc4b7a052d4.css +1 -0
  612. package/app/cli/.build-home/.omnihilbras/db/data.sqlite +0 -0
  613. package/app/package.json +1 -1
  614. package/app/src/lib/db/migrate.js +38 -3
  615. package/app/src/mitm/server.js +31 -31
  616. package/app/src/shared/services/usageRetention.js +72 -0
  617. package/app/src/shared/utils/apiKey.js +15 -7
  618. package/package.json +1 -1
  619. package/src/cli/menus/apiKeys.js +19 -60
  620. package/app/.next-cli-build/server/chunks/238.js +0 -1
  621. package/app/.next-cli-build/server/chunks/3558.js +0 -1
  622. package/app/.next-cli-build/server/chunks/3662.js +0 -1
  623. package/app/.next-cli-build/server/chunks/3770.js +0 -1
  624. package/app/.next-cli-build/server/chunks/4049.js +0 -1
  625. package/app/.next-cli-build/server/chunks/4055.js +0 -9
  626. package/app/.next-cli-build/server/chunks/4663.js +0 -1
  627. package/app/.next-cli-build/server/chunks/5182.js +0 -1
  628. package/app/.next-cli-build/server/chunks/5217.js +0 -9
  629. package/app/.next-cli-build/server/chunks/5245.js +0 -1
  630. package/app/.next-cli-build/server/chunks/5287.js +0 -1
  631. package/app/.next-cli-build/server/chunks/5919.js +0 -1
  632. package/app/.next-cli-build/server/chunks/595.js +0 -1
  633. package/app/.next-cli-build/server/chunks/7811.js +0 -1
  634. package/app/.next-cli-build/server/chunks/827.js +0 -1
  635. package/app/.next-cli-build/server/chunks/8416.js +0 -1
  636. package/app/.next-cli-build/server/chunks/9489.js +0 -3
  637. package/app/.next-cli-build/static/chunks/5497-3c3d55a9b2b370b0.js +0 -7
  638. package/app/.next-cli-build/static/chunks/7958-b44b343c4ee9f7e0.js +0 -5
  639. package/app/.next-cli-build/static/chunks/webpack-65f2475d325cf79e.js +0 -1
  640. package/app/.next-cli-build/static/css/a1ec8457dda7a088.css +0 -1
  641. /package/app/.next-cli-build/static/{rtpcR0260Q2ARX74R3KSA → Bc_4pI0TTRTxAuRjbtM9m}/_buildManifest.js +0 -0
  642. /package/app/.next-cli-build/static/{rtpcR0260Q2ARX74R3KSA → Bc_4pI0TTRTxAuRjbtM9m}/_ssgManifest.js +0 -0
@@ -0,0 +1,4 @@
1
+ "use strict";exports.id=5961,exports.ids=[5961,8910],exports.modules={3894:(a,b,c)=>{c.d(b,{F_:()=>g,Nc:()=>h,Qh:()=>t,Su:()=>q,ag:()=>o,kI:()=>p,rl:()=>u,sy:()=>s});var d=c(79646),e=c(33873),f=c.n(e);let g=["code","ml"],h={code:["tree-sitter","tree-sitter-language-pack"],ml:["torch","huggingface-hub"]},i="win32"===process.platform,j=i?"where":"which",k=i?[`${process.env.LOCALAPPDATA||""}\\Programs\\Python\\Python313\\Scripts`,`${process.env.LOCALAPPDATA||""}\\Programs\\Python\\Python312\\Scripts`,`${process.env.LOCALAPPDATA||""}\\Programs\\Python\\Python311\\Scripts`,`${process.env.LOCALAPPDATA||""}\\Programs\\Python\\Python310\\Scripts`,`${process.env.APPDATA||""}\\Python\\Python313\\Scripts`]:["/usr/local/bin","/opt/homebrew/bin","/Library/Frameworks/Python.framework/Versions/3.13/bin","/Library/Frameworks/Python.framework/Versions/3.12/bin","/Library/Frameworks/Python.framework/Versions/3.11/bin","/Library/Frameworks/Python.framework/Versions/3.10/bin",`${process.env.HOME||""}/.local/bin`,"/usr/bin","/bin"],l=[...k,process.env.PATH||""].filter(Boolean).join(f().delimiter),m=["python3.13","python3.12","python3.11","python3.10","python3","python"],n=new Set(["localhost","127.0.0.1","::1","[::1]","0.0.0.0"]),o=process.env.HEADROOM_URL||"http://localhost:8787";function p(){try{let a=(0,d.execSync)(`${j} headroom`,{stdio:["ignore","pipe","ignore"],windowsHide:!0,env:{...process.env,PATH:l}}).toString().trim();return a?a.split(/\r?\n/)[0].trim():null}catch{return null}}function q(){let a=null;for(let b of function(){let a=[],b=p();if(b){let c=f().dirname(b);for(let b of i?["python.exe","python3.exe"]:["python3","python3.13","python"])a.push(f().join(c,b))}for(let b of k)if(b)for(let c of m)a.push(f().join(b,i?`${c}.exe`:c));return a.push(...m),a}())try{let c=(0,d.execSync)(`${b} --version`,{stdio:["ignore","pipe","ignore"],windowsHide:!0,env:{...process.env,PATH:l}}).toString().trim().match(/(\d+)\.(\d+)/);if(!c)continue;let[e,f]=[parseInt(c[1],10),parseInt(c[2],10)];if(!(e>3||3===e&&f>=10))continue;a||(a=b);try{return(0,d.execFileSync)(b,["-m","pip","show","headroom-ai"],{stdio:["ignore","pipe","ignore"],windowsHide:!0,timeout:8e3,env:{...process.env,PATH:l}}),b}catch{}}catch{}return a}async function r(a){if(!a)return!1;let b=String(a).replace(/\/$/,"");try{return(await fetch(`${b}/health`,{signal:AbortSignal.timeout(1500)})).ok}catch{return!1}}function s(a){try{let b=new URL(a);return n.has(b.hostname)}catch{return!1}}async function t(a){let b=p(),c=q(),d=!!b,e=await r(a),f=s(a),g=d?u(c):{installed:!1,version:null,extras:{code:!1,ml:!1}};return{installed:d,path:b,running:e,python:c,localUrl:f,canStart:d&&f,version:g.version,extras:g.extras}}function u(a){let b=a||q();if(!b)return{installed:!1,version:null,extras:{code:!1,ml:!1}};try{let a=(0,d.execFileSync)(b,["-m","pip","list","--format=json","--disable-pip-version-check"],{stdio:["ignore","pipe","ignore"],windowsHide:!0,timeout:8e3,env:{...process.env,PATH:l}}).toString(),c=JSON.parse(a),e=new Set(c.map(a=>String(a.name||"").toLowerCase()));if(!e.has("headroom-ai"))return{installed:!1,version:null,extras:{code:!1,ml:!1}};let f=c.find(a=>a.name?.toLowerCase()==="headroom-ai")?.version||null,i={};for(let a of g)i[a]=h[a].some(a=>e.has(a));return{installed:!0,version:f,extras:i}}catch{return{installed:!1,version:null,extras:{code:!1,ml:!1}}}}},17603:(a,b,c)=>{c.d(b,{R8:()=>l,ar:()=>n,vB:()=>j});var d=c(24);let e=["vision","pdf","audioInput","videoInput"],f=new Set(e),g="oc/mimo-v2.6-flash-free",h=a=>"oc/mimo-v2.5-free"===a?g:a;function i(a,b){var c;let d=Array.isArray(c=b?.capacityAdapter?.[a])?{enabled:!0,roundRobin:!1,models:c.map(a=>h(a?.model||a)).filter(Boolean)}:c&&"object"==typeof c?{enabled:!1!==c.enabled,roundRobin:!!c.roundRobin,models:Array.isArray(c.models)?c.models.map(h).filter(Boolean):[]}:{enabled:!1,roundRobin:!1,models:[]};return d.enabled&&0===d.models.length?{...d,models:[g]}:d}function j(a,b){for(let c of[...a||[]].filter(a=>f.has(a))){let{enabled:a,models:d}=i(c,b);if(a&&0!==d.length)return function(a,b){let{enabled:c,roundRobin:d}=i(a,b);return c&&d?"round-robin":"fallback"}(c,b)}return"fallback"}function k(a,b){let c=a.indexOf("/"),e=c>0?a.slice(0,c):"",f=c>0?a.slice(c+1):a,g=(0,d.getCapabilitiesForModel)(e,f);return b.every(a=>!0===g[a])}function l(a,b,c){let d=[...b||[]].filter(a=>f.has(a));if(0===d.length||!Array.isArray(a)||0===a.length||a.some(a=>k(a,d)))return a;let g=(function(a){let b=new Set,c=[];for(let d of e){let{enabled:e,models:f}=i(d,a);if(e)for(let a of f)b.has(a)||(b.add(a),c.push(a))}return c})(c).filter(b=>!a.includes(b)&&k(b,d));return 0===g.length?a:[...g,...a]}function m(a){return"string"==typeof a?a.length:Array.isArray(a)?a.reduce((a,b)=>a+("string"==typeof b?.text?b.text.length:50),0):0}function n(a,b){let c=new Set(b);return 0===c.size?a:(b,e,...f)=>{if(c.has(e)){let a=e.indexOf("/"),c=a>0?e.slice(0,a):"",f=a>0?e.slice(a+1):e,{contextWindow:g}=(0,d.getCapabilitiesForModel)(c,f);b=function(a,b){let c=Array.isArray(a.messages)?"messages":Array.isArray(a.input)?"input":Array.isArray(a.contents)?"contents":null;if(!c)return a;let d=a[c];if(!d||0===d.length)return a;let e=a=>"system"===a||"developer"===a,f=d.filter(a=>e(a?.role)),g=d.filter(a=>!e(a?.role));if(0===g.length)return a;let h=a=>"assistant"===a||"model"===a,i=g.length-1;for(;i>=0&&!h(g[i]?.role);)i--;let j=g.slice(i+1),k=g.slice(0,i+1);if(0===k.length)return a;let l=a=>a.content??a.parts,n=.8*(b||2e5)*4,o=k.slice(0,6),p=f.concat(o,j).reduce((a,b)=>a+m(l(b)),0);for(;p>n&&o.length>0;)p-=m(l(o.pop()));return o.length===k.length?a:{...a,[c]:[...f,...o,...j]}}(b,g)}return a(b,e,...f)}}},18910:(a,b,c)=>{c.d(b,{Pr:()=>r,UP:()=>p,Vu:()=>q,t8:()=>o,vt:()=>t});var d=c(12557),e=c(93297),f=c(43659),g=c(24),h=c(26922);let i=new Set(["vision","pdf","audioInput","videoInput"]),j="[Called tools: ",k="[Tool result: ";function l(a){return a.filter(a=>a).map(a=>{if("tool"===a.role||"function"===a.role)return{role:"assistant",content:`${k}${(0,h.kU)(a.content)||String(a.content??"")}]`};if("assistant"===a.role&&Array.isArray(a.tool_calls)){let{tool_calls:b,...c}=a,d=b.map(a=>a?.function?.name||a?.name||"tool").join(", "),e=(0,h.kU)(c.content)||("string"==typeof c.content?c.content:"");return{...c,content:`${e}${e?"\n":""}${j}${d}]`}}if(Array.isArray(a.content)){let b=a.content.some(a=>"tool_use"===a.type),c=a.content.some(a=>"tool_result"===a.type);if(b||c){let b=[],c=[],d=[];for(let e of a.content)"text"===e.type&&e.text&&b.push(e.text),"tool_use"===e.type&&c.push(e.name||"tool"),"tool_result"===e.type&&d.push((0,h.kU)(e.content)||String(e.content??""));let{...e}=a,f=b.join("\n");return c.length>0&&(f=`${f}${f?"\n":""}${j}${c.join(", ")}]`),d.length>0&&(f=`${f}${f?"\n":""}${k}${d.join("\n")}]`),{...e,content:f}}}return a})}let m=new Map;function n(a){if(!Array.isArray(a)||0===a.length)return[];let b=a=>"assistant"===a||"model"===a,c=a.length-1;for(;c>=0&&!b(a[c]?.role);)c--;return a.slice(c+1)}function o(a){let b=new Set;if(!a||"object"!=typeof a)return b;let c=a=>{"string"==typeof a&&(a.startsWith("image/")?b.add("vision"):"application/pdf"===a?b.add("pdf"):a.startsWith("audio/")?b.add("audioInput"):a.startsWith("video/")&&b.add("videoInput"))},d=a=>{if(!a||"object"!=typeof a)return;let d=a.type;if(("image_url"===d||"image"===d||"input_image"===d)&&b.add("vision"),("input_audio"===d||"audio_url"===d||"audio"===d)&&b.add("audioInput"),("input_video"===d||"video_url"===d||"video"===d)&&b.add("videoInput"),"file"===d||"document"===d||"input_file"===d){let d=null;a.input_audio?.format?d=`audio/${a.input_audio.format}`:a.file?.file_data?d=String(a.file.file_data).match(/^data:([^;,]+)/)?.[1]:a.source?.media_type?d=a.source.media_type:a.source?.data&&(d=String(a.source.data).match(/^data:([^;,]+)/)?.[1]),d?c(d):b.add("pdf")}c(a.inlineData?.mimeType||a.fileData?.mimeType)},e=a=>{if(Array.isArray(a))for(let b of a)d(b)},f=a=>{if(!a||"object"!=typeof a)return;Array.isArray(a.images)&&a.images.length>0&&b.add("vision");let d=a.experimental_attachments||a.attachments;if(Array.isArray(d))for(let a of d){if(!a)continue;let d=a.contentType||a.mediaType||"string"==typeof a.url&&a.url.match(/^data:([^;,]+)/)?.[1];d?c(d):(a.url||a.data)&&b.add("vision")}(a.image_url||a.image)&&b.add("vision"),(a.audio_url||a.audio)&&b.add("audioInput"),e(a.content),"string"==typeof a.content&&(a.content.includes("data:image/")?b.add("vision"):a.content.includes("data:audio/")?b.add("audioInput"):a.content.includes("data:application/pdf")&&b.add("pdf"))};for(let b of n(a.messages))f(b);for(let b of n(a.input))e(b.content);for(let b of n(a.contents||a.request?.contents))e(b.parts);return b}function p(a){a?m.delete(a):m.clear()}function q(a,b){if(a.includes("/"))return null;let c=(Array.isArray(b)?b:b?.combos||[]).find(b=>b.name===a);return c&&c.models&&c.models.length>0?c.models:null}async function r({body:a,models:b,handleSingleModel:c,log:h,comboName:j,comboStrategy:k,comboStickyLimit:l=1,autoSwitch:n=!0,fanOutBudget:p=null}){let q=function(a,b,c,d=1){let e;if(!a||a.length<=1||"round-robin"!==c)return a;let f=b||"__default__",g=Number.isFinite(e=Number.parseInt(d,10))&&e>0?e:1,h=m.get(f),i="number"==typeof h?{index:h,consecutiveUseCount:0}:h||{index:0,consecutiveUseCount:0},j=i.index%a.length,k=function(a,b){let c=[...a];for(let a=0;a<b;a++){let a=c.shift();c.push(a)}return c}(a,j),l=i.consecutiveUseCount+1;return l>=g?m.set(f,{index:(j+1)%a.length,consecutiveUseCount:0}):m.set(f,{index:j,consecutiveUseCount:l}),k}(b,j,k,l);if(n){let b=o(a);if(b.size>0){let a=function(a,b){if(!b||0===b.size||!Array.isArray(a)||a.length<=1)return a;let c=[...b].filter(a=>i.has(a)),d=[...b].filter(a=>!i.has(a));return a.map((a,b)=>{let e,f,h,i;return{m:a,i:b,t:(f=(e="string"==typeof a?a.indexOf("/"):-1)>0?a.slice(0,e):"",h=e>0?a.slice(e+1):a,i=(0,g.getCapabilitiesForModel)(f,h),c.every(a=>!0===i[a])?+!d.every(a=>!0===i[a]):2)}}).sort((a,b)=>a.t-b.t||a.i-b.i).map(a=>a.m)}(q,b);a[0]!==q[0]&&h.info("COMBO",`auto-switch for [${[...b].join(",")}] → ${a[0]}`),q=a}}let s=null,t=null,u=null;for(let b=0;b<q.length;b++){let f=q[b];h.info("COMBO",`Trying model ${b+1}/${q.length}: ${f}`);try{let g=await c(a,f);if(p?.exhausted)return h.warn("COMBO",`fan-out budget exhausted at ${f}`),(0,e.Kz)(p);if(g.ok){if(b!==q.length-1&&(g.headers?.get?.("content-type")||"").includes("application/json"))try{let a=await g.clone().json();if(function(a){if(!a||"object"!=typeof a)return!1;if(Array.isArray(a.choices)){if(0===a.choices.length)return!0;let b=a.choices[0];if(!b)return!0;let c=b.message||b.delta,d=c?.content,e="string"==typeof d?d.trim().length>0:Array.isArray(d)&&d.length>0,f=Array.isArray(c?.tool_calls)&&c.tool_calls.length>0||!!c?.function_call,g="string"==typeof c?.reasoning_content&&c.reasoning_content.trim().length>0,h=b.finish_reason;if(!e&&!f&&!g&&("stop"!==h&&"length"!==h&&"tool_calls"!==h&&"function_call"!==h||"in_progress"===h||"incomplete"===h))return!0}if(Array.isArray(a.content)){let b=a.content.some(a=>"text"===a.type&&a.text?.trim().length>0||"tool_use"===a.type),c=a.stop_reason;if(!b&&(!c||"in_progress"===c||"incomplete"===c))return!0}return!1}(a)){h.warn("COMBO",`Model ${f} returned HTTP 200 with zero usable content, falling back to next model`),s="Zero usable content",u=200;continue}}catch{}return h.info("COMBO",`Model ${f} succeeded`),g}let i=g.statusText||"",j=null;try{let a=await g.clone().json();i=a?.error?.message||a?.error||a?.message||i,j=a?.retryAfter||null}catch{}if(j&&(!t||new Date(j)<new Date(t))&&(t=j),"string"!=typeof i)try{i=JSON.stringify(i)}catch{i=String(i)}let{shouldFallback:k,cooldownMs:l}=(0,d.hk)(g.status,i);if(!k)return h.warn("COMBO",`Model ${f} failed (no fallback)`,{status:g.status}),g;l&&l>0&&l<=5e3&&(503===g.status||502===g.status||504===g.status)&&(h.info("COMBO",`Model ${f} transient ${g.status}, waiting ${l}ms before next`),await new Promise(a=>setTimeout(a,l))),s=i||String(g.status),u||(u=g.status),h.warn("COMBO",`Model ${f} failed, trying next`,{status:g.status})}catch(a){s=a.message||String(a),u||(u=500),h.warn("COMBO",`Model ${f} threw error, trying next`,{error:s})}}let v=s&&s.toLowerCase().includes("no credentials")?503:u||503,w=s||"All combo models unavailable";if(t){let a=(0,d.Qo)(t);return h.warn("COMBO",`All models failed | ${w} (${a})`),(0,f.wO)(v,w,t,a)}return h.warn("COMBO",`All models failed | ${w}`),new Response(JSON.stringify({error:{message:w}}),{status:v,headers:{"Content-Type":"application/json"}})}let s={minPanel:2,stragglerGraceMs:8e3,panelHardTimeoutMs:9e4};async function t({body:a,models:b,handleSingleModel:c,log:d,comboName:f,judgeModel:g,tuning:i,fanOutBudget:j=null}){var k;let m,n,o=Array.isArray(b)?b.filter(Boolean):[];if(0===o.length)return new Response(JSON.stringify({error:{message:"Fusion combo has no models"}}),{status:400,headers:{"Content-Type":"application/json"}});if(1===o.length)return c(a,o[0]);if(j&&(0,e.qB)(j)<o.length+1)return d.warn("FUSION",`fan-out budget too small for a panel of ${o.length}`),(0,e.Kz)(j);let p={...s,...i||{}},q=Math.min(Math.max(2,p.minPanel),o.length),r=g&&g.trim()?g.trim():o[0];d.info("FUSION",`Combo "${f}" | panel=${o.length} [${o.join(", ")}] | judge=${r} | quorum=${q}`);let{tools:u,tool_choice:v,stream_options:w,...x}=a,y={...x,stream:!1};Array.isArray(y.messages)?y.messages=l(y.messages):Array.isArray(y.input)&&(y.input=l(y.input));let z=Date.now(),A=o.map(a=>{var b,d;return b=c(y,a,!0),d=p.panelHardTimeoutMs,new Promise(a=>{let c=setTimeout(()=>a({__timeout:!0}),d);Promise.resolve(b).then(b=>{clearTimeout(c),a(b)}).catch(b=>{clearTimeout(c),a({__error:b})})})}),B=await function(a,{minPanel:b,stragglerGraceMs:c,panelHardTimeoutMs:d}){return new Promise(e=>{let f=Array(a.length),g=0,h=0,i=!1,j=null,k=()=>{i||(i=!0,clearTimeout(l),j&&clearTimeout(j),e(f))},l=setTimeout(k,d);a.forEach((d,e)=>{Promise.resolve(d).then(a=>{f[e]=a}).catch(a=>{f[e]={__error:a}}).finally(()=>{if(g++,f[e]&&f[e].ok&&h++,g===a.length)return k();h>=b&&!j&&(j=setTimeout(k,c))})})})}(A,{...p,minPanel:q});d.info("FUSION",`fan-out collected in ${Date.now()-z}ms`);let C=[];for(let a=0;a<B.length;a++){let b=B[a],c=o[a];if(!b){d.warn("FUSION",`Panel ${c} dropped (straggler/timeout)`);continue}if(b.__timeout){d.warn("FUSION",`Panel ${c} timed out`);continue}if(b.__error){d.warn("FUSION",`Panel ${c} threw`,{error:b.__error?.message||String(b.__error)});continue}if(!b.ok){d.warn("FUSION",`Panel ${c} failed`,{status:b.status});continue}try{let a=await b.clone().json(),e=function(a){if(!a||"object"!=typeof a)return"";let b=a.choices?.[0];if(b){let a=b.message??b.delta??{},c=(0,h.kU)(a.content);if(c.trim())return c;if("string"==typeof b.text&&b.text.trim())return b.text}let c=(0,h.kU)(a.content);if(c.trim())return c;let d=a.candidates?.[0]?.content?.parts;if(Array.isArray(d)){let a=d.map(a=>a?.text||"").join("");if(a.trim())return a}if(Array.isArray(a.output)){let b=a.output.flatMap(a=>Array.isArray(a.content)?a.content.map(a=>a?.text||""):[]).join("");if(b.trim())return b}return""}(a);e?(C.push({model:c,text:e}),d.info("FUSION",`Panel ${c} ok (${e.length} chars)`)):d.warn("FUSION",`Panel ${c} returned empty content`)}catch(a){d.warn("FUSION",`Panel ${c} unparseable`,{error:a.message||String(a)})}}if(0===C.length)return d.warn("FUSION","All panel models failed"),new Response(JSON.stringify({error:{message:"All fusion panel models failed"}}),{status:503,headers:{"Content-Type":"application/json"}});if(1===C.length)return d.info("FUSION",`Only ${C[0].model} succeeded — answering directly (no fusion)`),c(a,C[0].model);let D=(m=C.map((a,b)=>`[Source ${b+1}]
2
+ ${a.text}`).join("\n\n"),k=[`You are the JUDGE in a model-fusion panel. ${C.length} expert models independently answered the user's most recent request. Their responses are below, anonymized by source.`,"\nDo NOT mention that multiple models were used, and do NOT refer to the sources. Produce ONE authoritative final answer addressed directly to the user.\n\nFirst, internally analyze the panel along these dimensions: consensus (points most sources agree on — treat as higher-confidence), contradictions (where they disagree — resolve with your own judgment), partial coverage, unique insights only one source surfaced, and blind spots every source missed. Then write the best possible final answer grounded in that analysis — more complete and correct than any single response, with no filler.\n\n=== PANEL RESPONSES ===",m,"=== END PANEL RESPONSES ===\n\nNow write the final answer to the user's original request."].join("\n"),n={...a},Array.isArray(a.messages)?n.messages=[...a.messages,{role:"user",content:k}]:Array.isArray(a.input)?n.input=[...a.input,{role:"user",content:k}]:Array.isArray(a.contents)?n.contents=[...a.contents,{role:"user",parts:[{text:k}]}]:n.messages=[{role:"user",content:k}],n);return d.info("FUSION",`Judging ${C.length} answers with ${r}`),c(D,r)}},46634:(a,b,c)=>{c.d(b,{Mo:()=>h,RG:()=>l,V:()=>i,Y8:()=>k,xl:()=>m});var d=c(1932),e=c(87155);let f=null,g=null;function h(){return f?{loaded:!0,version:f.version,loadedAt:f.loadedAt}:{loaded:!1}}async function i(){return f||g||(g=j().finally(()=>{g=null}))}async function j(){let a=(0,e.S1)();if(!a.installed){let a=Error("PXPIPE is not installed");throw a.code="NOT_INSTALLED",a}let b=`${(0,d.pathToFileURL)((0,e.CG)()).href}?v=${encodeURIComponent(a.version||"0")}`,c=await import(b);if("function"!=typeof c.transformAnthropicMessages)throw Error("installed pxpipe package does not export transformAnthropicMessages");return f={module:c,version:a.version,loadedAt:Date.now()}}function k(){let a=!!f;return f=null,a}async function l({autoLoad:a=!0}={}){try{if(!f&&!a)return null;let{module:b}=await i();return b.transformAnthropicMessages}catch{return null}}async function m(){let a=Date.now(),{module:b}=await i(),c=new TextEncoder().encode(JSON.stringify({model:"claude-fable-5",max_tokens:16,messages:[{role:"user",content:"ping"}]})),d=await b.transformAnthropicMessages({body:c,model:"claude-fable-5"});if(!d||"boolean"!=typeof d.applied||!(d.body instanceof Uint8Array))throw Error("transform returned an unexpected shape");return{ok:!0,reason:d.reason,durationMs:Date.now()-a}}},46945:(a,b,c)=>{c.d(b,{V:()=>e});let d=/\[1m\]$/i;function e(a){if("string"!=typeof a)return{model:a,contextMarker:null};let b=a.trim(),c=b.match(d);return c?{model:b.slice(0,-c[0].length),contextMarker:c[0].slice(1,-1).toLowerCase()}:{model:a,contextMarker:null}}},74388:(a,b,c)=>{c.d(b,{Az:()=>l,SP:()=>o,T0:()=>k});var d=c(29021),e=c.n(d),f=c(33873),g=c.n(f),h=c(87155);let i=g().join(h.XF,"events.jsonl"),j=g().join(h.XF,"events.jsonl.1");function k(a){try{e().existsSync(h.XF)||e().mkdirSync(h.XF,{recursive:!0});try{e().statSync(i).size>5242880&&e().renameSync(i,j)}catch{}e().appendFile(i,JSON.stringify({ts:Date.now(),...a})+"\n",()=>{})}catch{}}function l({sinceMs:a=null,limit:b=null}={}){let c=[];for(let b of[j,i])try{if(!e().existsSync(b))continue;for(let d of e().readFileSync(b,"utf8").split("\n"))if(d)try{let b=JSON.parse(d);if(a&&b.ts<a)continue;c.push(b)}catch{}}catch{}return c.sort((a,b)=>a.ts-b.ts),b?c.slice(-b):c}function m(){return{requests:0,compressed:0,bypassed:0,errors:0,tokensBeforeEst:0,tokensAfterEst:0,tokensSavedEst:0,savedPct:0,imagesGenerated:0,compressionTimeMs:0,avgCompressionMs:0}}function n(a,b){a.requests++,b.applied?(a.compressed++,a.tokensBeforeEst+=b.tokensBeforeEst||0,a.tokensAfterEst+=b.tokensAfterEst||0,a.tokensSavedEst+=b.tokensSavedEst||0,a.imagesGenerated+=b.imageCount||0,a.compressionTimeMs+=b.durationMs||0):"transform_error"===b.reason||"timeout"===b.reason?a.errors++:a.bypassed++}function o({timelineDays:a=30,recentLimit:b=100}={}){let c=l(),d=Date.now(),e=new Date(new Date(d).setHours(0,0,0,0)).getTime(),f={all:m(),today:m(),yesterday:m(),last7d:m(),last30d:m()},g=new Map;for(let b=a-1;b>=0;b--){let a=new Date(e-864e5*b);g.set(a.toISOString().slice(0,10),{date:a.toISOString().slice(0,10),tokensSavedEst:0,compressed:0,requests:0})}for(let a of c){n(f.all,a),a.ts>=e?n(f.today,a):a.ts>=e-864e5&&n(f.yesterday,a),a.ts>=d-6048e5&&n(f.last7d,a),a.ts>=d-2592e6&&n(f.last30d,a);let b=new Date(a.ts).toISOString().slice(0,10),c=g.get(b);c&&(c.requests++,a.applied&&(c.compressed++,c.tokensSavedEst+=a.tokensSavedEst||0))}for(let a of Object.values(f))a.savedPct=a.tokensBeforeEst>0?+(a.tokensSavedEst/a.tokensBeforeEst*100).toFixed(2):0,a.avgCompressionMs=a.compressed>0?Math.round(a.compressionTimeMs/a.compressed):0;return{windows:f,timeline:[...g.values()],recent:c.slice(-b).reverse()}}},79489:(a,b,c)=>{c.a(a,async(a,d)=>{try{c.d(b,{P:()=>C});var e=c(48895),f=c(80238),g=c(45974),h=c(89718),i=c(38775),j=c(92500),k=c(3894),l=c(46634),m=c(74388),n=c(43659),o=c(48136),p=c(18910),q=c(17603),r=c(27349),s=c(41004),t=c(14170),u=c(7803),v=c(67828),w=c(38160),x=c(46945),y=c(27811),z=c(53439),A=c(93297),B=a([e,j]);async function C(a,b=null){return await (0,z.Gb)(a,c=>D(a,b,c))}async function D(a,b=null,c={}){let d,e=c.fanOutBudget||null;try{d=await a.json()}catch{return u.warn("CHAT","Invalid JSON body"),(0,n.yj)(s.gx.BAD_REQUEST,"Invalid JSON body")}b||(b={endpoint:new URL(a.url).pathname,body:d,headers:Object.fromEntries(a.headers.entries())});let{model:g,contextMarker:j}=(0,x.V)(d.model);j&&(d.model=g);let k=a.headers.get("Authorization"),l=(0,f.Tr)(a);if(k&&l){let a=u.maskKey(l);u.debug("AUTH",`API Key: ${a}`)}else u.debug("AUTH","No API key provided (local mode)");let m=await (0,h.mt)();if(m.requireApiKey){if(!l)return u.warn("AUTH","Missing API key (requireApiKey=true)"),(0,n.yj)(s.gx.UNAUTHORIZED,"Missing API key");if(!await (0,f.kI)(l))return u.warn("AUTH","Invalid API key (requireApiKey=true)"),(0,n.yj)(s.gx.UNAUTHORIZED,"Invalid API key")}if(!g)return u.warn("CHAT","Missing model"),(0,n.yj)(s.gx.BAD_REQUEST,"Missing model");let o=await (0,y.TM)(a),t=await (0,y.cI)(o,g);if(t)return t;let v=a?.headers?.get("user-agent")||"",w=(0,r.c)(d,g,v,!!m.ccFilterNaming);if(w)return w.response||w;let z=(0,p.t8)(d),A=await (0,i.d_)(g);if(A){let c=m.comboStrategies||{},f=c[g]?.fallbackStrategy||m.comboStrategy||"fallback",h=await (0,y.Ge)(o,(0,q.R8)(A,z,m),A),i=h.filter(a=>!A.includes(a));if("fusion"===f)return u.info("CHAT",`Combo "${g}" with ${A.length} models (strategy: fusion)`),(0,p.vt)({body:d,models:A,handleSingleModel:(c,d,f)=>{let g=b;if(f&&b){let{tools:a,tool_choice:c,...d}=b.body||{};g={...b,body:d}}return E(c,d,g,a,l,null,e)},log:u,comboName:g,judgeModel:c[g]?.judgeModel,tuning:c[g]?.fusionTuning,fanOutBudget:e});let j=m.comboStickyRoundRobinLimit;return u.info("CHAT",`Combo "${g}" with ${h.length} models (strategy: ${f}, sticky: ${j})`),(0,p.Pr)({body:d,models:h,handleSingleModel:(0,q.ar)((c,d)=>E(c,d,b,a,l,null,e),i),log:u,comboName:g,comboStrategy:f,comboStickyLimit:j,fanOutBudget:e})}let B=await (0,y.Ge)(o,(0,q.R8)([g],z,m),[g]);if(B.length>1){let c=B.filter(a=>a!==g);return u.info("CHAT",`Capacity adapter for [${[...z].join(",")}] on "${g}" → trying ${B.join(", ")}`),(0,p.Pr)({body:d,models:B,handleSingleModel:(0,q.ar)((c,d)=>E(c,d,b,a,l,null,e),c),log:u,comboName:g,comboStrategy:(0,q.vB)(z,m),fanOutBudget:e})}return E(d,g,b,a,l,j?`${g.slice(g.indexOf("/")+1)}[${j}]`:null,e)}async function E(a,b,c=null,d=null,e=null,r=null,x=null){let z=await (0,i.mA)(b);if(!z.provider){let f=await (0,i.d_)(b);if(f){let g=await (0,h.mt)(),i=g.comboStrategies||{},j=i[b]?.fallbackStrategy||g.comboStrategy||"fallback",k=(0,p.t8)(a),l=await (0,y.TM)(d),m=await (0,y.Ge)(l,(0,q.R8)(f,k,g),f),n=m.filter(a=>!f.includes(a));if("fusion"===j)return u.info("CHAT",`Combo "${b}" with ${f.length} models (strategy: fusion)`),(0,p.vt)({body:a,models:f,handleSingleModel:(a,b,f)=>{let g=c;if(f&&c){let{tools:a,tool_choice:b,...d}=c.body||{};g={...c,body:d}}return E(a,b,g,d,e,null,x)},log:u,comboName:b,judgeModel:i[b]?.judgeModel,tuning:i[b]?.fusionTuning,fanOutBudget:x});let o=g.comboStickyRoundRobinLimit;return u.info("CHAT",`Combo "${b}" with ${m.length} models (strategy: ${j}, sticky: ${o})`),(0,p.Pr)({body:a,models:m,handleSingleModel:(0,q.ar)((a,b)=>E(a,b,c,d,e,null,x),n),log:u,comboName:b,comboStrategy:j,comboStickyLimit:o,fanOutBudget:x})}return u.warn("CHAT","Invalid model format",{model:b}),(0,n.yj)(s.gx.BAD_REQUEST,"Invalid model format")}let{provider:B,model:C}=z,D=d?.headers?.get("user-agent")||"",F=new Set,G=null,H=null,I=null;for(;;){let b=await (0,f.c1)(B,F,C,{requestedModel:r||C});if(!b||b.allRateLimited){if(b?.allRateLimited){let a=G||b.lastError||"Unavailable",c=s.gx.SERVICE_UNAVAILABLE;return u.warn("CHAT",`[${B}/${C}] ${a} (${b.retryAfterHuman})`),(0,n.wO)(c,`[${B}/${C}] ${a}`,b.retryAfter,b.retryAfterHuman,I)}if(0===F.size)return u.warn("AUTH",`No active credentials for provider: ${B}`),(0,n.yj)(s.gx.NOT_FOUND,`No active credentials for provider: ${B}`);return u.warn("CHAT","No more accounts available",{provider:B}),(0,n.yj)(H||s.gx.SERVICE_UNAVAILABLE,G||"All accounts unavailable",I)}let i=await (0,v.checkAndRefreshToken)(B,b);if(("antigravity"===B||"gemini-cli"===B)&&!i.projectId){let a=await (0,w.eG)(b.connectionId,i.accessToken,B);a&&(i.projectId=a,(0,v.vN)(b.connectionId,{projectId:a}).catch(()=>{}))}let p=await (0,h.mt)(),q=(p.providerThinking||{})[B]||null;if(!(0,A.G3)(x,`${B}/${C}`))return u.warn("CHAT",`fan-out budget exhausted at ${B}/${C}`),(0,A.Kz)(x);let y=await (0,j.wk)({body:{...a,model:`${B}/${C}`},clientSignal:d?.signal,modelInfo:{provider:B,model:C},credentials:i,log:u,clientRawRequest:c,connectionId:b.connectionId,userAgent:D,apiKey:e,ccFilterNaming:!!p.ccFilterNaming,rtkEnabled:!!p.rtkEnabled,headroomEnabled:!!p.headroomEnabled,headroomUrl:p.headroomUrl||k.ag,headroomCompressUserMessages:!!p.headroomCompressUserMessages,headroomTimeoutMs:p.headroomTimeoutMs,cavemanEnabled:!!p.cavemanEnabled,cavemanLevel:p.cavemanLevel||"full",ponytailEnabled:!!p.ponytailEnabled,ponytailLevel:p.ponytailLevel||"full",pxpipeEnabled:!!p.pxpipeEnabled,pxpipeMinChars:p.pxpipeMinChars,pxpipeTimeoutMs:p.pxpipeTimeoutMs,pxpipeTransform:p.pxpipeEnabled?await (0,l.RG)():null,onPxpipeEvent:m.T0,providerThinking:q,providerOverrides:(p.providerOverrides||{})[B]||null,sourceFormatOverride:d?.url?(0,t.t)(new URL(d.url).pathname,a):null,onCredentialsRefreshed:async a=>{await (0,v.vN)(b.connectionId,{...a,existingProviderSpecificData:b.providerSpecificData,testStatus:"active"})},onRequestSuccess:async()=>{await (0,f.Pt)(b.connectionId,b,C),(0,g.vO)(b.connectionId,C)}});if(y.success)return y.response;let z=null,E=y.resetsAtMs;if("antigravity"===B&&(409===y.status||429===y.status)&&(z=await (0,g.XJ)(b.connectionId,y.status,C,i.accessToken,b.providerSpecificData))&&(E=z),"antigravity"===B&&z||(await (0,f.vk)(b.connectionId,y.status,y.error,B,C,E)).shouldFallback){u.warn("FALLBACK",`⇄ ACC:${b.connectionName} UNAVAILABLE (${y.status}) → NEXT ACCOUNT`),F.add(b.connectionId),G=y.error,H=y.status,I=(0,o.d)(y.response?.headers);continue}return y.response}}[e,j]=B.then?(await B)():B,d()}catch(a){d(a)}})},85081:(a,b,c)=>{c.d(b,{Ay:()=>j});var d=c(77598);let e=function(a){return Array.isArray(a)?a=Buffer.from(a):"string"==typeof a&&(a=Buffer.from(a,"utf8")),(0,d.createHash)("sha1").update(a).digest()},f=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-8][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/i,g=function(a){let b;if(!("string"==typeof a&&f.test(a)))throw TypeError("Invalid UUID");return Uint8Array.of((b=parseInt(a.slice(0,8),16))>>>24,b>>>16&255,b>>>8&255,255&b,(b=parseInt(a.slice(9,13),16))>>>8,255&b,(b=parseInt(a.slice(14,18),16))>>>8,255&b,(b=parseInt(a.slice(19,23),16))>>>8,255&b,(b=parseInt(a.slice(24,36),16))/0x10000000000&255,b/0x100000000&255,b>>>24&255,b>>>16&255,b>>>8&255,255&b)};var h=c(50122);function i(a,b,c,d){var f=b,i=d;let j="string"==typeof a?function(a){let b=new Uint8Array((a=unescape(encodeURIComponent(a))).length);for(let c=0;c<a.length;++c)b[c]=a.charCodeAt(c);return b}(a):a,k="string"==typeof f?g(f):f;if("string"==typeof f&&(f=g(f)),f?.length!==16)throw TypeError("Namespace must be array-like (16 iterable integer values, 0-255)");let l=new Uint8Array(16+j.length);if(l.set(k),l.set(j,k.length),(l=e(l))[6]=15&l[6]|80,l[8]=63&l[8]|128,c){if((i=i||0)<0||i+16>c.length)throw RangeError(`UUID byte range ${i}:${i+15} is out of buffer bounds`);for(let a=0;a<16;++a)c[i+a]=l[a];return c}return(0,h.k)(l)}i.DNS="6ba7b810-9dad-11d1-80b4-00c04fd430c8",i.URL="6ba7b811-9dad-11d1-80b4-00c04fd430c8";let j=i},87155:(a,b,c)=>{c.d(b,{CG:()=>q,ED:()=>u,S1:()=>s,XF:()=>j,_g:()=>t,no:()=>r,sW:()=>w});var d=c(29021),e=c.n(d),f=c(33873),g=c.n(f),h=c(79646),i=c(49120);let j=g().join(i.n,"pxpipe"),k="pxpipe-proxy",l=g().join(j,"install.log"),m="win32"===process.platform,n=[...m?[`${process.env.ProgramFiles||""}\\nodejs`,`${process.env.APPDATA||""}\\npm`]:["/usr/local/bin","/opt/homebrew/bin",`${process.env.HOME||""}/.local/bin`,"/usr/bin","/bin"],process.env.PATH||""].filter(Boolean).join(g().delimiter),o=null;function p(){return g().join(j,"node_modules",k)}function q(){return g().join(p(),"dist","core","library.js")}function r(){try{let a=(0,h.execSync)(`${m?"where":"which"} npm`,{stdio:["ignore","pipe","ignore"],windowsHide:!0,env:{...process.env,PATH:n}}).toString().trim();return a?a.split(/\r?\n/)[0].trim():null}catch{return null}}function s(){try{let a=g().join(p(),"package.json");if(!e().existsSync(a)||!e().existsSync(q()))return{installed:!1,version:null,path:null};let b=JSON.parse(e().readFileSync(a,"utf8"));return{installed:!0,version:b.version||null,path:p()}}catch{return{installed:!1,version:null,path:null}}}function t(){return null!==o}function u(){return o||(o=v().finally(()=>{o=null}))}async function v(){let a=r();if(!a){let a=Error("npm not found on PATH — Node.js/npm is required to install PXPIPE");throw a.code="NPM_NOT_FOUND",a}e().existsSync(j)||e().mkdirSync(j,{recursive:!0});let b=g().join(j,"package.json");e().existsSync(b)||e().writeFileSync(b,JSON.stringify({name:"omnihilbras-pxpipe-host",private:!0},null,2));let c=e().openSync(l,"a");e().writeSync(c,`
3
+ [${new Date().toISOString()}] npm install ${k}@latest
4
+ `),await new Promise((b,d)=>{let e=(0,h.spawn)(a,["install",`${k}@latest`,"--no-audit","--no-fund","--omit=dev"],{cwd:j,stdio:["ignore",c,c],windowsHide:!0,env:{...process.env,PATH:n}}),f=setTimeout(()=>{e.kill("SIGKILL"),d(Error("npm install timed out after 5 minutes — see install.log"))},3e5);e.once("error",a=>{clearTimeout(f),d(a)}),e.once("exit",a=>{clearTimeout(f),0===a?b():d(Error(`npm install exited with code ${a} — see install.log`))})}).finally(()=>e().closeSync(c));let d=s();if(!d.installed)throw Error("install finished but package is missing — see install.log");return d}function w(a=200){try{if(!e().existsSync(l))return"";return e().readFileSync(l,"utf8").split(/\r?\n/).filter(Boolean).slice(-a).join("\n")}catch{return""}}}};
@@ -1 +1 @@
1
- "use strict";exports.id=6763,exports.ids=[6763],exports.modules={26763:(a,b,c)=>{c.d(b,{PROVIDER_PRICING:()=>g,calculateCostFromTokens:()=>k,getPricingForModel:()=>j});let d=["cline-free/"],e={input:0,output:0,cached:0,reasoning:0,cache_creation:0},f={"claude-opus-4-6":{input:5,output:25,cached:.5,reasoning:25,cache_creation:6.25},"claude-opus-4-5-20251101":{input:5,output:25,cached:.5,reasoning:25,cache_creation:6.25},"claude-sonnet-4-6":{input:3,output:15,cached:.3,reasoning:15,cache_creation:3.75},"claude-sonnet-4-5-20250929":{input:3,output:15,cached:.3,reasoning:15,cache_creation:3.75},"claude-haiku-4-5-20251001":{input:1,output:5,cached:.1,reasoning:5,cache_creation:1.25},"claude-sonnet-4-20250514":{input:3,output:15,cached:1.5,reasoning:15,cache_creation:3},"claude-opus-4-20250514":{input:15,output:25,cached:7.5,reasoning:112.5,cache_creation:15},"claude-3-5-sonnet-20241022":{input:3,output:15,cached:1.5,reasoning:15,cache_creation:3},"claude-haiku-4.5":{input:.5,output:2.5,cached:.05,reasoning:3.75,cache_creation:.5},"claude-opus-4.1":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"claude-opus-4.5":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"claude-opus-4.6":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"claude-sonnet-4":{input:3,output:15,cached:.3,reasoning:22.5,cache_creation:3},"claude-sonnet-4.5":{input:3,output:15,cached:.3,reasoning:22.5,cache_creation:3},"claude-sonnet-4.6":{input:3,output:15,cached:.3,reasoning:22.5,cache_creation:3},"claude-opus-4-5-thinking":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"claude-opus-4-6-thinking":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"claude-opus-5-5-thinking":{input:4,output:20,cached:.2,reasoning:20,cache_creation:5},"claude-opus-5-5":{input:4,output:20,cached:.2,reasoning:20,cache_creation:5},"claude-opus-5-5-high":{input:4,output:20,cached:.2,reasoning:20,cache_creation:5},"claude-opus-5-5-medium":{input:4,output:20,cached:.2,reasoning:20,cache_creation:5},"claude-opus-5-5-low":{input:4,output:20,cached:.2,reasoning:20,cache_creation:5},"claude-fable-5":{input:10,output:50,cached:1,reasoning:50,cache_creation:12.5},"claude-sonnet-5-5":{input:2,output:10,cached:.2,reasoning:10,cache_creation:2.5},"claude-sonnet-5-5-thinking":{input:2,output:10,cached:.2,reasoning:10,cache_creation:2.5},"claude-sonnet-5-5-high":{input:2,output:10,cached:.2,reasoning:10,cache_creation:2.5},"claude-sonnet-5-5-medium":{input:2,output:10,cached:.2,reasoning:10,cache_creation:2.5},"claude-sonnet-5-5-low":{input:2,output:10,cached:.2,reasoning:10,cache_creation:2.5},"claude-sonnet-5":{input:2,output:10,cached:.2,reasoning:10,cache_creation:2.5},"gpt-3.5-turbo":{input:.5,output:1.5,cached:.25,reasoning:2.25,cache_creation:.5},"gpt-4":{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5},"gpt-4-turbo":{input:10,output:30,cached:5,reasoning:45,cache_creation:10},"gpt-4o":{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5},"gpt-4o-mini":{input:.15,output:.6,cached:.075,reasoning:.9,cache_creation:.15},"gpt-4.1":{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5},"gpt-5":{input:1.25,output:10,cached:.625,reasoning:10,cache_creation:1.25},"gpt-5-mini":{input:.25,output:2,cached:.125,reasoning:2,cache_creation:.25},"gpt-5-codex":{input:1.25,output:10,cached:.625,reasoning:10,cache_creation:1.25},"gpt-5.1":{input:1.25,output:10,cached:.625,reasoning:10,cache_creation:1.25},"gpt-5.1-codex":{input:1.25,output:10,cached:.625,reasoning:10,cache_creation:1.25},"gpt-5.1-codex-mini":{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5},"gpt-5.1-codex-mini-high":{input:2,output:8,cached:1,reasoning:12,cache_creation:2},"gpt-5.1-codex-max":{input:8,output:32,cached:4,reasoning:48,cache_creation:8},"gpt-5.2":{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75},"gpt-5.2-codex":{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75},"gpt-5.3-codex":{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75},"gpt-5.3-codex-spark":{input:3,output:12,cached:.3,reasoning:12,cache_creation:3},"gpt-5.6":{input:2.5,output:15,cached:.25,reasoning:15,cache_creation:2.5},"gpt-5.6-luna":{input:1,output:6,cached:.1,reasoning:6,cache_creation:1},"gpt-5.6-terra":{input:2.5,output:15,cached:.25,reasoning:15,cache_creation:2.5},"gpt-5.6-sol":{input:5,output:30,cached:.5,reasoning:30,cache_creation:5},"gpt-6-astra":{input:10,output:50,cached:1,reasoning:50,cache_creation:12.5},"gpt-6.1-sol":{input:2,output:10,cached:.1,reasoning:10,cache_creation:2.5},"gpt-6-sol":{input:2,output:10,cached:.2,reasoning:10,cache_creation:2.5},"gpt-6-luna":{input:.1,output:.5,cached:.01,reasoning:.5,cache_creation:.125},o1:{input:15,output:60,cached:7.5,reasoning:90,cache_creation:15},"o1-mini":{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3},"gemini-3.8-flash":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.8-flash-high":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.8-flash-medium":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.8-flash-low":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.7-flash":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.7-flash-high":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.7-flash-medium":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.7-flash-low":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.6-flash":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.6-flash-high":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.6-flash-medium":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.6-flash-low":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.5-flash-lite":{input:.3,output:2.5,cached:.03,reasoning:3.75,cache_creation:.375},"gemini-3.5-flash-high":{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5},"gemini-3-flash-preview":{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5},"gemini-3-pro-preview":{input:2,output:12,cached:.25,reasoning:18,cache_creation:2},"gemini-3.1-pro-low":{input:2,output:12,cached:.25,reasoning:18,cache_creation:2},"gemini-3.1-pro-high":{input:4,output:18,cached:.5,reasoning:27,cache_creation:4},"gemini-pro-agent":{input:4,output:18,cached:.5,reasoning:27,cache_creation:4},"gemini-3-flash-agent":{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5},"gemini-3.5-flash-low":{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5},"gemini-3.5-flash-extra-low":{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5},"gemini-3-flash":{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5},"gemini-2.5-pro":{input:2,output:12,cached:.25,reasoning:18,cache_creation:2},"gemini-2.5-flash":{input:.3,output:2.5,cached:.03,reasoning:3.75,cache_creation:.3},"gemini-2.5-flash-lite":{input:.15,output:1.25,cached:.015,reasoning:1.875,cache_creation:.15},"qwen3-coder-plus":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"qwen3-coder-flash":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"kimi-k3":{input:3,output:15,cached:.3,reasoning:15,cache_creation:3},k3:{input:3,output:15,cached:.3,reasoning:15,cache_creation:3},"kimi-k2.7-code":{input:.95,output:4,cached:.19,reasoning:4,cache_creation:.95},"kimi-k2.7-code-highspeed":{input:1.9,output:8,cached:.38,reasoning:8,cache_creation:1.9},"kimi-for-coding":{input:.95,output:4,cached:.19,reasoning:4,cache_creation:.95},"kimi-for-coding-highspeed":{input:1.9,output:8,cached:.38,reasoning:8,cache_creation:1.9},"kimi-k2":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"kimi-k2-thinking":{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5},"kimi-k2.5":{input:1.2,output:4.8,cached:.6,reasoning:7.2,cache_creation:1.2},"kimi-k2.5-thinking":{input:1.8,output:7.2,cached:.9,reasoning:10.8,cache_creation:1.8},"kimi-k2.6":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"kimi-latest":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"deepseek-chat":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-reasoner":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-r1":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-v3.2-chat":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-v3.2-reasoner":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-v4-flash":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-v4.1-flash":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-flash":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-v4-pro":{input:.435,output:.87,cached:.003625,reasoning:.87,cache_creation:.435},"glm-4.6":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"glm-4.6v":{input:.75,output:3,cached:.375,reasoning:4.5,cache_creation:.75},"glm-4.7":{input:.75,output:3,cached:.375,reasoning:4.5,cache_creation:.75},"glm-5":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"MiniMax-M3":{input:.3,output:1.2,cached:.06,reasoning:1.8,cache_creation:.3},"MiniMax-M2.1":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"MiniMax-M2.5":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"MiniMax-M2.7":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"minimax-m2.1":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"minimax-m2.5":{input:.6,output:2.4,cached:.3,reasoning:3.6,cache_creation:.6},"grok-code-fast-1":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"muse-spark-1.3":{input:1.25,output:4.25,cached:.15,reasoning:4.25,cache_creation:0},"muse-spark-1.2":{input:1.25,output:4.25,cached:.15,reasoning:4.25,cache_creation:0},"muse-spark-1.1":{input:1.25,output:4.25,cached:.15,reasoning:4.25,cache_creation:0},"muse-spark-1.3-contributor":{input:.1,output:.2,cached:.002,reasoning:.2,cache_creation:0},"muse-spark-1.2-contributor":{input:.1,output:.2,cached:.002,reasoning:.2,cache_creation:0},auto:{input:2,output:8,cached:1,reasoning:12,cache_creation:2},"oswe-vscode-prime":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"gpt-oss-120b-medium":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"vision-model":{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5},"coder-model":{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5}},g={gh:{"gpt-5.3-codex":{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75}},tokenrouter:{"MiniMax-M3":{input:.3,output:1.2,cached:.06,reasoning:1.2},"anthropic/claude-fable-5":{input:10,output:50,cached:1,cache_creation:12.5,reasoning:50},"anthropic/claude-haiku-4.5":{input:1,output:5,cached:.1,cache_creation:1.25,reasoning:5},"anthropic/claude-opus-4.5":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-4.6":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-4.7":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-4.7-fast":{input:30,output:150,cached:3,reasoning:150},"anthropic/claude-opus-4.8":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-4.8-fast":{input:10,output:50,cached:1,cache_creation:12.5,reasoning:50},"anthropic/claude-opus-5":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-5-fast":{input:10,output:50,cached:1,cache_creation:12.5,reasoning:50},"anthropic/claude-sonnet-4":{input:3,output:15,cached:.3,cache_creation:3.75,reasoning:15},"anthropic/claude-sonnet-4.5":{input:3,output:15,cached:.3,cache_creation:3.75,reasoning:15},"anthropic/claude-sonnet-4.6":{input:3,output:15,cached:.3,cache_creation:3.75,reasoning:15},"anthropic/claude-sonnet-5":{input:2,output:10,cached:.2,reasoning:10},"claude-opus-4-8-m-aws":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"deepseek/deepseek-v3.2":{input:.26,output:.38,cached:.13,reasoning:.38},"deepseek/deepseek-v4-flash":{input:.14,output:.28,cached:.0028,reasoning:.28},"deepseek/deepseek-v4-flash-0731":{input:.14,output:.28,cached:.0028,reasoning:.28},"deepseek/deepseek-v4-pro":{input:.435,output:.87,cached:.003625,reasoning:.87},"ex/gpt-5.4":{input:2.5,output:15,cached:.25,reasoning:15},"google/gemini-2.5-flash-image":{input:.3,output:2.5,reasoning:2.5},"google/gemini-3-flash-preview":{input:.5,output:3,cached:.05,cache_creation:.08333,reasoning:3},"google/gemini-3-pro-image-preview":{input:2,output:12,reasoning:12},"google/gemini-3.1-flash-image-preview":{input:.5,output:3,reasoning:3},"google/gemini-3.1-flash-lite-image":{input:.25,output:1.5,reasoning:1.5},"google/gemini-3.1-pro-preview":{input:2,output:12,cached:.2,cache_creation:.375,reasoning:12},"google/gemini-3.5-flash":{input:1.5,output:9,cached:.15,cache_creation:.08333,reasoning:9},"google/gemini-3.5-flash-lite":{input:.3,output:2.5,cached:.03,cache_creation:.08333,reasoning:2.5},"google/gemini-3.6-flash":{input:1.5,output:7.5,cached:.15,cache_creation:.08333,reasoning:7.5},"google/gemini-embedding-2":{input:1,output:6,cached:.1,reasoning:6},"google/gemma-4-26b-a4b-it":{input:.06,output:.33,reasoning:.33},"kling-3.0-turbo":{input:2.1,output:2.1,reasoning:2.1},"microsoft/mai-image-2.5":{input:5,output:47,reasoning:47},"minimax/minimax-m2-her":{input:.3,output:1.2,cached:.03,reasoning:1.2},"minimax/minimax-m2.1":{input:.3,output:1.2,cached:.03,reasoning:1.2},"minimax/minimax-m2.1-highspeed":{input:.6,output:2.4,cached:.06,reasoning:2.4},"minimax/minimax-m2.5":{input:.3,output:1.2,cached:.03,reasoning:1.2},"minimax/minimax-m2.7":{input:.3,output:1.2,cached:.06,reasoning:1.2},"minimax/minimax-m2.7-highspeed":{input:.6,output:2.4,cached:.06,reasoning:2.4},"miromind/mirothinker-1-7-deepresearch":{input:4,output:25,reasoning:25},"miromind/mirothinker-1-7-deepresearch-mini":{input:1.25,output:10,reasoning:10},"mistralai/devstral-2512":{input:.4,output:2,cached:.04,reasoning:2},"mistralai/mistral-medium-3-5":{input:1.5,output:7.5,reasoning:7.5},"mistralai/mistral-small-2603":{input:.15,output:.6,cached:.015,reasoning:.6},"mistralai/voxtral-small-24b-2507":{input:.1,output:.3,cached:.01,reasoning:.3},"moonshotai/kimi-k2.5":{input:.6,output:3,cached:.1,reasoning:3},"moonshotai/kimi-k2.6":{input:.95,output:4,cached:.16,reasoning:4},"moonshotai/kimi-k2.7-code":{input:.9286,output:3.8571,cached:.1857,reasoning:3.8571},"moonshotai/kimi-k3":{input:3,output:15,cached:.3,reasoning:15},"nvidia/nemotron-3-super-120b-a12b":{input:.3,output:.9,cached:.1,reasoning:.9},"openai/gpt-4o-mini":{input:.15,output:.6,cached:.075,reasoning:.6},"openai/gpt-5":{input:1.25,output:10,cached:.125,reasoning:10},"openai/gpt-5-image":{input:10,output:40,cached:2.5,reasoning:40},"openai/gpt-5-image-mini":{input:2.5,output:8,cached:.25,reasoning:8},"openai/gpt-5-mini":{input:.25,output:2,cached:.025,reasoning:2},"openai/gpt-5.2":{input:1.75,output:14,cached:.175,reasoning:14},"openai/gpt-5.3-codex":{input:1.75,output:14,cached:.175,reasoning:14},"openai/gpt-5.4":{input:2.5,output:15,cached:.25,reasoning:15},"openai/gpt-5.4-image-2":{input:8,output:30,cached:2,reasoning:30},"openai/gpt-5.4-mini":{input:.75,output:4.5,cached:.075,reasoning:4.5},"openai/gpt-5.4-nano":{input:.2,output:1.25,cached:.02,reasoning:1.25},"openai/gpt-5.4-pro":{input:30,output:180,reasoning:180},"openai/gpt-5.5":{input:5,output:30,cached:.5,reasoning:30},"openai/gpt-5.5-pro":{input:30,output:180,reasoning:180},"openai/gpt-5.6-luna":{input:.2,output:1.2,cached:.02,cache_creation:.25,reasoning:1.2},"openai/gpt-5.6-sol":{input:5,output:30,cached:.5,cache_creation:6.25,reasoning:30},"openai/gpt-5.6-terra":{input:2,output:12,cached:.2,cache_creation:2.5,reasoning:12},"openai/gpt-audio":{input:2.5,output:10,reasoning:10},"openai/gpt-audio-mini":{input:.6,output:2.4,reasoning:2.4},"openai/gpt-oss-120b":{input:.039,output:.18,reasoning:.18},"qwen/qwen3-coder-next":{input:.12,output:.75,cached:.06,reasoning:.75},"qwen/qwen3.5-122b-a10b":{input:.26,output:2.08,reasoning:2.08},"qwen/qwen3.5-35b-a3b":{input:.1625,output:1.3,reasoning:1.3},"qwen/qwen3.5-397b-a17b":{input:.39,output:2.34,reasoning:2.34},"qwen/qwen3.5-9b":{input:.1,output:.15,reasoning:.15},"qwen/qwen3.5-flash":{input:.1048,output:.4194,reasoning:.4194},"qwen/qwen3.5-plus-02-15":{input:.26,output:1.56,reasoning:1.56},"qwen/qwen3.6-plus":{input:.54,output:3.21,reasoning:3.21},"qwen/qwen3.7-max":{input:1.25,output:3.75,cached:.25,reasoning:3.75},"qwen/qwen3.7-plus":{input:.4,output:1.6,cached:.08,reasoning:1.6},"qwen/qwen3.8-max":{input:2,output:6,cached:.25,cache_creation:2.5,reasoning:6},"qwen3.5-omni-plus":{input:1,output:5.7143,reasoning:5.7143},"qwen3.6-flash":{input:.171,output:1.029,cached:.017,cache_creation:.214,reasoning:1.029},"sakana/fugu-ultra":{input:5,output:30,cached:.5,reasoning:30},"seed-2-0-code-preview-260328":{input:1,output:6,cached:.2,cache_creation:.008333,reasoning:6},"seed-2-0-lite-260428":{input:.5,output:4,cached:.1,cache_creation:.008333,reasoning:4},"seed-2-0-mini-260428":{input:.2,output:.8,cached:.04,cache_creation:.00833,reasoning:.8},"seed-2-0-pro-260328":{input:1,output:6,cached:.2,cache_creation:.008333,reasoning:6},"stepfun/step-3.5-flash":{input:.1,output:.3,cached:.02,reasoning:.3},"stepfun/step-3.7-flash":{input:.2,output:1.15,cached:.04,reasoning:1.15},"tencent/hy3-preview":{input:.066,output:.26,cached:.029,reasoning:.26},"x-ai/grok-4.1-fast":{input:.2,output:.5,cached:.05,reasoning:.5},"x-ai/grok-4.20-beta":{input:2,output:6,cached:.2,reasoning:6},"x-ai/grok-4.3":{input:1.25,output:2.5,cached:.2,reasoning:2.5},"x-ai/grok-4.5":{input:2,output:6,cached:.5,reasoning:6},"x-ai/grok-build-0.1":{input:1,output:2,cached:.2,reasoning:2},"xiaomi/mimo-v2-flash":{input:.1,output:.3,cached:.01,reasoning:.3},"xiaomi/mimo-v2-omni":{input:.4,output:2,cached:.08,reasoning:2},"xiaomi/mimo-v2-pro":{input:1,output:3,cached:.2,reasoning:3},"xiaomi/mimo-v2.5":{input:.4,output:2,cached:.08,reasoning:2},"xiaomi/mimo-v2.5-pro":{input:1,output:3,cached:.2,reasoning:3},"z-ai/glm-4.5-air":{input:.13,output:.85,cached:.025,reasoning:.85},"z-ai/glm-4.6":{input:.6,output:2.2,cached:.11,reasoning:2.2},"z-ai/glm-4.6v":{input:.3,output:.9,reasoning:.9},"z-ai/glm-4.7":{input:.6,output:2.2,cached:.11,reasoning:2.2},"z-ai/glm-5":{input:1,output:3.2,cached:.2,reasoning:3.2},"z-ai/glm-5-turbo":{input:1.2,output:4,cached:.24,reasoning:4},"z-ai/glm-5.1":{input:1.05,output:3.5,cached:.525,reasoning:3.5},"z-ai/glm-5.2":{input:1.4,output:4.4,cached:.26,reasoning:4.4},"z-ai/glm-5.3-free":{input:0,output:0,cached:0,reasoning:0}}},h=[{pattern:"*-codex-xhigh",pricing:{input:10,output:40,cached:5,reasoning:60,cache_creation:10}},{pattern:"*-codex-high",pricing:{input:8,output:32,cached:4,reasoning:48,cache_creation:8}},{pattern:"*-codex-max",pricing:{input:8,output:32,cached:4,reasoning:48,cache_creation:8}},{pattern:"*-codex-mini-*",pricing:{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5}},{pattern:"*-codex-mini",pricing:{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5}},{pattern:"*-codex-low",pricing:{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75}},{pattern:"*-codex-none",pricing:{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75}},{pattern:"*-codex-spark",pricing:{input:3,output:12,cached:.3,reasoning:12,cache_creation:3}},{pattern:"codex-*",pricing:{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75}},{pattern:"*-codex",pricing:{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75}},{pattern:"claude-opus-*",pricing:{input:5,output:25,cached:.5,reasoning:25,cache_creation:6.25}},{pattern:"claude-sonnet-*",pricing:{input:3,output:15,cached:.3,reasoning:15,cache_creation:3.75}},{pattern:"claude-haiku-*",pricing:{input:1,output:5,cached:.1,reasoning:5,cache_creation:1.25}},{pattern:"claude-*",pricing:{input:3,output:15,cached:.3,reasoning:15,cache_creation:3.75}},{pattern:"gemini-*-flash-lite",pricing:{input:.15,output:1.25,cached:.015,reasoning:1.875,cache_creation:.15}},{pattern:"gemini-*-flash",pricing:{input:.3,output:2.5,cached:.03,reasoning:3.75,cache_creation:.3}},{pattern:"gemini-*-pro",pricing:{input:2,output:12,cached:.25,reasoning:18,cache_creation:2}},{pattern:"gemini-3-*",pricing:{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5}},{pattern:"gemini-2.5-*",pricing:{input:.3,output:2.5,cached:.03,reasoning:3.75,cache_creation:.3}},{pattern:"gemini-*",pricing:{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5}},{pattern:"gpt-5.6-*",pricing:{input:2.5,output:15,cached:.25,reasoning:15,cache_creation:2.5}},{pattern:"gpt-5.3-*",pricing:{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75}},{pattern:"gpt-5.2-*",pricing:{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75}},{pattern:"gpt-5.1-*",pricing:{input:1.25,output:10,cached:.625,reasoning:10,cache_creation:1.25}},{pattern:"gpt-5-*",pricing:{input:1.25,output:10,cached:.625,reasoning:10,cache_creation:1.25}},{pattern:"gpt-5*",pricing:{input:1.25,output:10,cached:.625,reasoning:10,cache_creation:1.25}},{pattern:"gpt-4o-*",pricing:{input:.15,output:.6,cached:.075,reasoning:.9,cache_creation:.15}},{pattern:"gpt-4o",pricing:{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5}},{pattern:"gpt-4*",pricing:{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5}},{pattern:"o1-*",pricing:{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3}},{pattern:"o1",pricing:{input:15,output:60,cached:7.5,reasoning:90,cache_creation:15}},{pattern:"o3-*",pricing:{input:10,output:40,cached:5,reasoning:60,cache_creation:10}},{pattern:"o4-*",pricing:{input:2,output:8,cached:1,reasoning:12,cache_creation:2}},{pattern:"qwen3-coder-*",pricing:{input:1,output:4,cached:.5,reasoning:6,cache_creation:1}},{pattern:"qwen*-coder-*",pricing:{input:1,output:4,cached:.5,reasoning:6,cache_creation:1}},{pattern:"qwen*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"kimi-*-thinking",pricing:{input:1.8,output:7.2,cached:.9,reasoning:10.8,cache_creation:1.8}},{pattern:"kimi-k3*",pricing:{input:3,output:15,cached:.3,reasoning:15,cache_creation:3}},{pattern:"kimi-k2*",pricing:{input:1.2,output:4.8,cached:.6,reasoning:7.2,cache_creation:1.2}},{pattern:"kimi-*",pricing:{input:1,output:4,cached:.5,reasoning:6,cache_creation:1}},{pattern:"deepseek-*reasoner*",pricing:{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14}},{pattern:"deepseek-r*",pricing:{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14}},{pattern:"deepseek-v*",pricing:{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14}},{pattern:"deepseek-*",pricing:{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14}},{pattern:"glm-5*",pricing:{input:1,output:4,cached:.5,reasoning:6,cache_creation:1}},{pattern:"glm-4*",pricing:{input:.75,output:3,cached:.375,reasoning:4.5,cache_creation:.75}},{pattern:"glm-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"MiniMax-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"minimax-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"grok-code-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"grok-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}}];function i(a,b){return RegExp("^"+a.split("*").map(a=>a.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")).join(".*")+"$","i").test(b)}function j(a,b){if(!b)return null;if(a&&g[a]?.[b])return g[a][b];if(function(a){if(!a)return!1;let b=String(a).toLowerCase();return d.some(a=>b.startsWith(a))}(b))return e;let c=b.includes("/")?b.split("/").pop():b;if(f[c])return f[c];if(f[b])return f[b];for(let{pattern:a,pricing:d}of h)if(i(a,c)||i(a,b))return d;return null}function k(a,b){if(!a||!b)return 0;let c=0,d=a.prompt_tokens||a.input_tokens||0,e=a.cached_tokens||a.cache_read_input_tokens||0,f=a.cache_creation_input_tokens||0;c+=Math.max(0,d-e-f)*(b.input/1e6),e>0&&(c+=e*((b.cached||b.input)/1e6)),c+=(a.completion_tokens||a.output_tokens||0)*(b.output/1e6);let g=a.reasoning_tokens||0;return g>0&&(c+=g*((b.reasoning||b.output)/1e6)),f>0&&(c+=f*((b.cache_creation||b.input)/1e6)),c}}};
1
+ "use strict";exports.id=6763,exports.ids=[6763],exports.modules={26763:(a,b,c)=>{c.d(b,{PROVIDER_PRICING:()=>g,calculateCostFromTokens:()=>l,getPricingForModel:()=>k});let d=["cline-free/"],e={input:0,output:0,cached:0,reasoning:0,cache_creation:0},f={"claude-opus-4-6":{input:5,output:25,cached:.5,reasoning:25,cache_creation:6.25},"claude-opus-4-5-20251101":{input:5,output:25,cached:.5,reasoning:25,cache_creation:6.25},"claude-sonnet-4-6":{input:3,output:15,cached:.3,reasoning:15,cache_creation:3.75},"claude-sonnet-4-5-20250929":{input:3,output:15,cached:.3,reasoning:15,cache_creation:3.75},"claude-haiku-4-5-20251001":{input:1,output:5,cached:.1,reasoning:5,cache_creation:1.25},"claude-sonnet-4-20250514":{input:3,output:15,cached:1.5,reasoning:15,cache_creation:3},"claude-opus-4-20250514":{input:15,output:25,cached:7.5,reasoning:112.5,cache_creation:15},"claude-3-5-sonnet-20241022":{input:3,output:15,cached:1.5,reasoning:15,cache_creation:3},"claude-haiku-4.5":{input:.5,output:2.5,cached:.05,reasoning:3.75,cache_creation:.5},"claude-opus-4.1":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"claude-opus-4.5":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"claude-opus-4.6":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"claude-sonnet-4":{input:3,output:15,cached:.3,reasoning:22.5,cache_creation:3},"claude-sonnet-4.5":{input:3,output:15,cached:.3,reasoning:22.5,cache_creation:3},"claude-sonnet-4.6":{input:3,output:15,cached:.3,reasoning:22.5,cache_creation:3},"claude-opus-4-5-thinking":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"claude-opus-4-6-thinking":{input:5,output:25,cached:.5,reasoning:37.5,cache_creation:5},"claude-opus-5-5-thinking":{input:4,output:20,cached:.2,reasoning:20,cache_creation:5},"claude-opus-5-5":{input:4,output:20,cached:.2,reasoning:20,cache_creation:5},"claude-opus-5-5-high":{input:4,output:20,cached:.2,reasoning:20,cache_creation:5},"claude-opus-5-5-medium":{input:4,output:20,cached:.2,reasoning:20,cache_creation:5},"claude-opus-5-5-low":{input:4,output:20,cached:.2,reasoning:20,cache_creation:5},"claude-fable-5":{input:10,output:50,cached:1,reasoning:50,cache_creation:12.5},"claude-sonnet-5-5":{input:2,output:10,cached:.2,reasoning:10,cache_creation:2.5},"claude-sonnet-5-5-thinking":{input:2,output:10,cached:.2,reasoning:10,cache_creation:2.5},"claude-sonnet-5-5-high":{input:2,output:10,cached:.2,reasoning:10,cache_creation:2.5},"claude-sonnet-5-5-medium":{input:2,output:10,cached:.2,reasoning:10,cache_creation:2.5},"claude-sonnet-5-5-low":{input:2,output:10,cached:.2,reasoning:10,cache_creation:2.5},"claude-sonnet-5":{input:2,output:10,cached:.2,reasoning:10,cache_creation:2.5},"gpt-3.5-turbo":{input:.5,output:1.5,cached:.25,reasoning:2.25,cache_creation:.5},"gpt-4":{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5},"gpt-4-turbo":{input:10,output:30,cached:5,reasoning:45,cache_creation:10},"gpt-4o":{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5},"gpt-4o-mini":{input:.15,output:.6,cached:.075,reasoning:.9,cache_creation:.15},"gpt-4.1":{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5},"gpt-5":{input:1.25,output:10,cached:.625,reasoning:10,cache_creation:1.25},"gpt-5-mini":{input:.25,output:2,cached:.125,reasoning:2,cache_creation:.25},"gpt-5-codex":{input:1.25,output:10,cached:.625,reasoning:10,cache_creation:1.25},"gpt-5.1":{input:1.25,output:10,cached:.625,reasoning:10,cache_creation:1.25},"gpt-5.1-codex":{input:1.25,output:10,cached:.625,reasoning:10,cache_creation:1.25},"gpt-5.1-codex-mini":{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5},"gpt-5.1-codex-mini-high":{input:2,output:8,cached:1,reasoning:12,cache_creation:2},"gpt-5.1-codex-max":{input:8,output:32,cached:4,reasoning:48,cache_creation:8},"gpt-5.2":{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75},"gpt-5.2-codex":{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75},"gpt-5.3-codex":{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75},"gpt-5.3-codex-spark":{input:3,output:12,cached:.3,reasoning:12,cache_creation:3},"gpt-5.6":{input:2.5,output:15,cached:.25,reasoning:15,cache_creation:2.5},"gpt-5.6-luna":{input:1,output:6,cached:.1,reasoning:6,cache_creation:1},"gpt-5.6-terra":{input:2.5,output:15,cached:.25,reasoning:15,cache_creation:2.5},"gpt-5.6-sol":{input:5,output:30,cached:.5,reasoning:30,cache_creation:5},"gpt-6-astra":{input:10,output:50,cached:1,reasoning:50,cache_creation:12.5},"gpt-6.1-sol":{input:2,output:10,cached:.1,reasoning:10,cache_creation:2.5},"gpt-6-sol":{input:2,output:10,cached:.2,reasoning:10,cache_creation:2.5},"gpt-6-luna":{input:.1,output:.5,cached:.01,reasoning:.5,cache_creation:.125},o1:{input:15,output:60,cached:7.5,reasoning:90,cache_creation:15},"o1-mini":{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3},"gemini-3.8-flash":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.8-flash-high":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.8-flash-medium":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.8-flash-low":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.7-flash":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.7-flash-high":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.7-flash-medium":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.7-flash-low":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.6-flash":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.6-flash-high":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.6-flash-medium":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.6-flash-low":{input:1.5,output:7.5,cached:.15,reasoning:11.25,cache_creation:1.875},"gemini-3.5-flash-lite":{input:.3,output:2.5,cached:.03,reasoning:3.75,cache_creation:.375},"gemini-3.5-flash-high":{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5},"gemini-3-flash-preview":{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5},"gemini-3-pro-preview":{input:2,output:12,cached:.25,reasoning:18,cache_creation:2},"gemini-3.1-pro-low":{input:2,output:12,cached:.25,reasoning:18,cache_creation:2},"gemini-3.1-pro-high":{input:4,output:18,cached:.5,reasoning:27,cache_creation:4},"gemini-pro-agent":{input:4,output:18,cached:.5,reasoning:27,cache_creation:4},"gemini-3-flash-agent":{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5},"gemini-3.5-flash-low":{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5},"gemini-3.5-flash-extra-low":{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5},"gemini-3-flash":{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5},"gemini-2.5-pro":{input:2,output:12,cached:.25,reasoning:18,cache_creation:2},"gemini-2.5-flash":{input:.3,output:2.5,cached:.03,reasoning:3.75,cache_creation:.3},"gemini-2.5-flash-lite":{input:.15,output:1.25,cached:.015,reasoning:1.875,cache_creation:.15},"qwen3-coder-plus":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"qwen3-coder-flash":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"kimi-k3":{input:3,output:15,cached:.3,reasoning:15,cache_creation:3},k3:{input:3,output:15,cached:.3,reasoning:15,cache_creation:3},"kimi-k2.7-code":{input:.95,output:4,cached:.19,reasoning:4,cache_creation:.95},"kimi-k2.7-code-highspeed":{input:1.9,output:8,cached:.38,reasoning:8,cache_creation:1.9},"kimi-for-coding":{input:.95,output:4,cached:.19,reasoning:4,cache_creation:.95},"kimi-for-coding-highspeed":{input:1.9,output:8,cached:.38,reasoning:8,cache_creation:1.9},"kimi-k2":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"kimi-k2-thinking":{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5},"kimi-k2.5":{input:1.2,output:4.8,cached:.6,reasoning:7.2,cache_creation:1.2},"kimi-k2.5-thinking":{input:1.8,output:7.2,cached:.9,reasoning:10.8,cache_creation:1.8},"kimi-k2.6":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"kimi-latest":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"deepseek-chat":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-reasoner":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-r1":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-v3.2-chat":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-v3.2-reasoner":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-v4-flash":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-v4.1-flash":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-flash":{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14},"deepseek-v4-pro":{input:.435,output:.87,cached:.003625,reasoning:.87,cache_creation:.435},"glm-4.6":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"glm-4.6v":{input:.75,output:3,cached:.375,reasoning:4.5,cache_creation:.75},"glm-4.7":{input:.75,output:3,cached:.375,reasoning:4.5,cache_creation:.75},"glm-5":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"MiniMax-M3":{input:.3,output:1.2,cached:.06,reasoning:1.8,cache_creation:.3},"MiniMax-M2.1":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"MiniMax-M2.5":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"MiniMax-M2.7":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"minimax-m2.1":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"minimax-m2.5":{input:.6,output:2.4,cached:.3,reasoning:3.6,cache_creation:.6},"grok-code-fast-1":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"muse-spark-1.3":{input:1.25,output:4.25,cached:.15,reasoning:4.25,cache_creation:0},"muse-spark-1.2":{input:1.25,output:4.25,cached:.15,reasoning:4.25,cache_creation:0},"muse-spark-1.1":{input:1.25,output:4.25,cached:.15,reasoning:4.25,cache_creation:0},"muse-spark-1.3-contributor":{input:.1,output:.2,cached:.002,reasoning:.2,cache_creation:0},"muse-spark-1.2-contributor":{input:.1,output:.2,cached:.002,reasoning:.2,cache_creation:0},auto:{input:2,output:8,cached:1,reasoning:12,cache_creation:2},"oswe-vscode-prime":{input:1,output:4,cached:.5,reasoning:6,cache_creation:1},"gpt-oss-120b-medium":{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5},"vision-model":{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5},"coder-model":{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5}},g={gh:{"gpt-5.3-codex":{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75}},tokenrouter:{"MiniMax-M3":{input:.3,output:1.2,cached:.06,reasoning:1.2},"anthropic/claude-fable-5":{input:10,output:50,cached:1,cache_creation:12.5,reasoning:50},"anthropic/claude-haiku-4.5":{input:1,output:5,cached:.1,cache_creation:1.25,reasoning:5},"anthropic/claude-opus-4.5":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-4.6":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-4.7":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-4.7-fast":{input:30,output:150,cached:3,reasoning:150},"anthropic/claude-opus-4.8":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-4.8-fast":{input:10,output:50,cached:1,cache_creation:12.5,reasoning:50},"anthropic/claude-opus-5":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-5-fast":{input:10,output:50,cached:1,cache_creation:12.5,reasoning:50},"anthropic/claude-sonnet-4":{input:3,output:15,cached:.3,cache_creation:3.75,reasoning:15},"anthropic/claude-sonnet-4.5":{input:3,output:15,cached:.3,cache_creation:3.75,reasoning:15},"anthropic/claude-sonnet-4.6":{input:3,output:15,cached:.3,cache_creation:3.75,reasoning:15},"anthropic/claude-sonnet-5":{input:2,output:10,cached:.2,reasoning:10},"claude-opus-4-8-m-aws":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"deepseek/deepseek-v3.2":{input:.26,output:.38,cached:.13,reasoning:.38},"deepseek/deepseek-v4-flash":{input:.14,output:.28,cached:.0028,reasoning:.28},"deepseek/deepseek-v4-flash-0731":{input:.14,output:.28,cached:.0028,reasoning:.28},"deepseek/deepseek-v4-pro":{input:.435,output:.87,cached:.003625,reasoning:.87},"ex/gpt-5.4":{input:2.5,output:15,cached:.25,reasoning:15},"google/gemini-2.5-flash-image":{input:.3,output:2.5,reasoning:2.5},"google/gemini-3-flash-preview":{input:.5,output:3,cached:.05,cache_creation:.08333,reasoning:3},"google/gemini-3-pro-image-preview":{input:2,output:12,reasoning:12},"google/gemini-3.1-flash-image-preview":{input:.5,output:3,reasoning:3},"google/gemini-3.1-flash-lite-image":{input:.25,output:1.5,reasoning:1.5},"google/gemini-3.1-pro-preview":{input:2,output:12,cached:.2,cache_creation:.375,reasoning:12},"google/gemini-3.5-flash":{input:1.5,output:9,cached:.15,cache_creation:.08333,reasoning:9},"google/gemini-3.5-flash-lite":{input:.3,output:2.5,cached:.03,cache_creation:.08333,reasoning:2.5},"google/gemini-3.6-flash":{input:1.5,output:7.5,cached:.15,cache_creation:.08333,reasoning:7.5},"google/gemini-embedding-2":{input:1,output:6,cached:.1,reasoning:6},"google/gemma-4-26b-a4b-it":{input:.06,output:.33,reasoning:.33},"kling-3.0-turbo":{input:2.1,output:2.1,reasoning:2.1},"microsoft/mai-image-2.5":{input:5,output:47,reasoning:47},"minimax/minimax-m2-her":{input:.3,output:1.2,cached:.03,reasoning:1.2},"minimax/minimax-m2.1":{input:.3,output:1.2,cached:.03,reasoning:1.2},"minimax/minimax-m2.1-highspeed":{input:.6,output:2.4,cached:.06,reasoning:2.4},"minimax/minimax-m2.5":{input:.3,output:1.2,cached:.03,reasoning:1.2},"minimax/minimax-m2.7":{input:.3,output:1.2,cached:.06,reasoning:1.2},"minimax/minimax-m2.7-highspeed":{input:.6,output:2.4,cached:.06,reasoning:2.4},"miromind/mirothinker-1-7-deepresearch":{input:4,output:25,reasoning:25},"miromind/mirothinker-1-7-deepresearch-mini":{input:1.25,output:10,reasoning:10},"mistralai/devstral-2512":{input:.4,output:2,cached:.04,reasoning:2},"mistralai/mistral-medium-3-5":{input:1.5,output:7.5,reasoning:7.5},"mistralai/mistral-small-2603":{input:.15,output:.6,cached:.015,reasoning:.6},"mistralai/voxtral-small-24b-2507":{input:.1,output:.3,cached:.01,reasoning:.3},"moonshotai/kimi-k2.5":{input:.6,output:3,cached:.1,reasoning:3},"moonshotai/kimi-k2.6":{input:.95,output:4,cached:.16,reasoning:4},"moonshotai/kimi-k2.7-code":{input:.9286,output:3.8571,cached:.1857,reasoning:3.8571},"moonshotai/kimi-k3":{input:3,output:15,cached:.3,reasoning:15},"nvidia/nemotron-3-super-120b-a12b":{input:.3,output:.9,cached:.1,reasoning:.9},"openai/gpt-4o-mini":{input:.15,output:.6,cached:.075,reasoning:.6},"openai/gpt-5":{input:1.25,output:10,cached:.125,reasoning:10},"openai/gpt-5-image":{input:10,output:40,cached:2.5,reasoning:40},"openai/gpt-5-image-mini":{input:2.5,output:8,cached:.25,reasoning:8},"openai/gpt-5-mini":{input:.25,output:2,cached:.025,reasoning:2},"openai/gpt-5.2":{input:1.75,output:14,cached:.175,reasoning:14},"openai/gpt-5.3-codex":{input:1.75,output:14,cached:.175,reasoning:14},"openai/gpt-5.4":{input:2.5,output:15,cached:.25,reasoning:15},"openai/gpt-5.4-image-2":{input:8,output:30,cached:2,reasoning:30},"openai/gpt-5.4-mini":{input:.75,output:4.5,cached:.075,reasoning:4.5},"openai/gpt-5.4-nano":{input:.2,output:1.25,cached:.02,reasoning:1.25},"openai/gpt-5.4-pro":{input:30,output:180,reasoning:180},"openai/gpt-5.5":{input:5,output:30,cached:.5,reasoning:30},"openai/gpt-5.5-pro":{input:30,output:180,reasoning:180},"openai/gpt-5.6-luna":{input:.2,output:1.2,cached:.02,cache_creation:.25,reasoning:1.2},"openai/gpt-5.6-sol":{input:5,output:30,cached:.5,cache_creation:6.25,reasoning:30},"openai/gpt-5.6-terra":{input:2,output:12,cached:.2,cache_creation:2.5,reasoning:12},"openai/gpt-audio":{input:2.5,output:10,reasoning:10},"openai/gpt-audio-mini":{input:.6,output:2.4,reasoning:2.4},"openai/gpt-oss-120b":{input:.039,output:.18,reasoning:.18},"qwen/qwen3-coder-next":{input:.12,output:.75,cached:.06,reasoning:.75},"qwen/qwen3.5-122b-a10b":{input:.26,output:2.08,reasoning:2.08},"qwen/qwen3.5-35b-a3b":{input:.1625,output:1.3,reasoning:1.3},"qwen/qwen3.5-397b-a17b":{input:.39,output:2.34,reasoning:2.34},"qwen/qwen3.5-9b":{input:.1,output:.15,reasoning:.15},"qwen/qwen3.5-flash":{input:.1048,output:.4194,reasoning:.4194},"qwen/qwen3.5-plus-02-15":{input:.26,output:1.56,reasoning:1.56},"qwen/qwen3.6-plus":{input:.54,output:3.21,reasoning:3.21},"qwen/qwen3.7-max":{input:1.25,output:3.75,cached:.25,reasoning:3.75},"qwen/qwen3.7-plus":{input:.4,output:1.6,cached:.08,reasoning:1.6},"qwen/qwen3.8-max":{input:2,output:6,cached:.25,cache_creation:2.5,reasoning:6},"qwen3.5-omni-plus":{input:1,output:5.7143,reasoning:5.7143},"qwen3.6-flash":{input:.171,output:1.029,cached:.017,cache_creation:.214,reasoning:1.029},"sakana/fugu-ultra":{input:5,output:30,cached:.5,reasoning:30},"seed-2-0-code-preview-260328":{input:1,output:6,cached:.2,cache_creation:.008333,reasoning:6},"seed-2-0-lite-260428":{input:.5,output:4,cached:.1,cache_creation:.008333,reasoning:4},"seed-2-0-mini-260428":{input:.2,output:.8,cached:.04,cache_creation:.00833,reasoning:.8},"seed-2-0-pro-260328":{input:1,output:6,cached:.2,cache_creation:.008333,reasoning:6},"stepfun/step-3.5-flash":{input:.1,output:.3,cached:.02,reasoning:.3},"stepfun/step-3.7-flash":{input:.2,output:1.15,cached:.04,reasoning:1.15},"tencent/hy3-preview":{input:.066,output:.26,cached:.029,reasoning:.26},"x-ai/grok-4.1-fast":{input:.2,output:.5,cached:.05,reasoning:.5},"x-ai/grok-4.20-beta":{input:2,output:6,cached:.2,reasoning:6},"x-ai/grok-4.3":{input:1.25,output:2.5,cached:.2,reasoning:2.5},"x-ai/grok-4.5":{input:2,output:6,cached:.5,reasoning:6},"x-ai/grok-build-0.1":{input:1,output:2,cached:.2,reasoning:2},"xiaomi/mimo-v2-flash":{input:.1,output:.3,cached:.01,reasoning:.3},"xiaomi/mimo-v2-omni":{input:.4,output:2,cached:.08,reasoning:2},"xiaomi/mimo-v2-pro":{input:1,output:3,cached:.2,reasoning:3},"xiaomi/mimo-v2.5":{input:.4,output:2,cached:.08,reasoning:2},"xiaomi/mimo-v2.5-pro":{input:1,output:3,cached:.2,reasoning:3},"z-ai/glm-4.5-air":{input:.13,output:.85,cached:.025,reasoning:.85},"z-ai/glm-4.6":{input:.6,output:2.2,cached:.11,reasoning:2.2},"z-ai/glm-4.6v":{input:.3,output:.9,reasoning:.9},"z-ai/glm-4.7":{input:.6,output:2.2,cached:.11,reasoning:2.2},"z-ai/glm-5":{input:1,output:3.2,cached:.2,reasoning:3.2},"z-ai/glm-5-turbo":{input:1.2,output:4,cached:.24,reasoning:4},"z-ai/glm-5.1":{input:1.05,output:3.5,cached:.525,reasoning:3.5},"z-ai/glm-5.2":{input:1.4,output:4.4,cached:.26,reasoning:4.4},"z-ai/glm-5.3-free":{input:0,output:0,cached:0,reasoning:0}}},h=[{pattern:"*-codex-xhigh",pricing:{input:10,output:40,cached:5,reasoning:60,cache_creation:10}},{pattern:"*-codex-high",pricing:{input:8,output:32,cached:4,reasoning:48,cache_creation:8}},{pattern:"*-codex-max",pricing:{input:8,output:32,cached:4,reasoning:48,cache_creation:8}},{pattern:"*-codex-mini-*",pricing:{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5}},{pattern:"*-codex-mini",pricing:{input:1.5,output:6,cached:.75,reasoning:9,cache_creation:1.5}},{pattern:"*-codex-low",pricing:{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75}},{pattern:"*-codex-none",pricing:{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75}},{pattern:"*-codex-spark",pricing:{input:3,output:12,cached:.3,reasoning:12,cache_creation:3}},{pattern:"codex-*",pricing:{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75}},{pattern:"*-codex",pricing:{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75}},{pattern:"claude-opus-*",pricing:{input:5,output:25,cached:.5,reasoning:25,cache_creation:6.25}},{pattern:"claude-sonnet-*",pricing:{input:3,output:15,cached:.3,reasoning:15,cache_creation:3.75}},{pattern:"claude-haiku-*",pricing:{input:1,output:5,cached:.1,reasoning:5,cache_creation:1.25}},{pattern:"claude-*",pricing:{input:3,output:15,cached:.3,reasoning:15,cache_creation:3.75}},{pattern:"gemini-*-flash-lite",pricing:{input:.15,output:1.25,cached:.015,reasoning:1.875,cache_creation:.15}},{pattern:"gemini-*-flash",pricing:{input:.3,output:2.5,cached:.03,reasoning:3.75,cache_creation:.3}},{pattern:"gemini-*-pro",pricing:{input:2,output:12,cached:.25,reasoning:18,cache_creation:2}},{pattern:"gemini-3-*",pricing:{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5}},{pattern:"gemini-2.5-*",pricing:{input:.3,output:2.5,cached:.03,reasoning:3.75,cache_creation:.3}},{pattern:"gemini-*",pricing:{input:.5,output:3,cached:.03,reasoning:4.5,cache_creation:.5}},{pattern:"gpt-5.6-*",pricing:{input:2.5,output:15,cached:.25,reasoning:15,cache_creation:2.5}},{pattern:"gpt-5.3-*",pricing:{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75}},{pattern:"gpt-5.2-*",pricing:{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75}},{pattern:"gpt-5.1-*",pricing:{input:1.25,output:10,cached:.625,reasoning:10,cache_creation:1.25}},{pattern:"gpt-5-*",pricing:{input:1.25,output:10,cached:.625,reasoning:10,cache_creation:1.25}},{pattern:"gpt-5*",pricing:{input:1.25,output:10,cached:.625,reasoning:10,cache_creation:1.25}},{pattern:"gpt-4o-*",pricing:{input:.15,output:.6,cached:.075,reasoning:.9,cache_creation:.15}},{pattern:"gpt-4o",pricing:{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5}},{pattern:"gpt-4*",pricing:{input:2.5,output:10,cached:1.25,reasoning:15,cache_creation:2.5}},{pattern:"o1-*",pricing:{input:3,output:12,cached:1.5,reasoning:18,cache_creation:3}},{pattern:"o1",pricing:{input:15,output:60,cached:7.5,reasoning:90,cache_creation:15}},{pattern:"o3-*",pricing:{input:10,output:40,cached:5,reasoning:60,cache_creation:10}},{pattern:"o4-*",pricing:{input:2,output:8,cached:1,reasoning:12,cache_creation:2}},{pattern:"qwen3-coder-*",pricing:{input:1,output:4,cached:.5,reasoning:6,cache_creation:1}},{pattern:"qwen*-coder-*",pricing:{input:1,output:4,cached:.5,reasoning:6,cache_creation:1}},{pattern:"qwen*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"kimi-*-thinking",pricing:{input:1.8,output:7.2,cached:.9,reasoning:10.8,cache_creation:1.8}},{pattern:"kimi-k3*",pricing:{input:3,output:15,cached:.3,reasoning:15,cache_creation:3}},{pattern:"kimi-k2*",pricing:{input:1.2,output:4.8,cached:.6,reasoning:7.2,cache_creation:1.2}},{pattern:"kimi-*",pricing:{input:1,output:4,cached:.5,reasoning:6,cache_creation:1}},{pattern:"deepseek-*reasoner*",pricing:{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14}},{pattern:"deepseek-r*",pricing:{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14}},{pattern:"deepseek-v*",pricing:{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14}},{pattern:"deepseek-*",pricing:{input:.14,output:.28,cached:.0028,reasoning:.28,cache_creation:.14}},{pattern:"glm-5*",pricing:{input:1,output:4,cached:.5,reasoning:6,cache_creation:1}},{pattern:"glm-4*",pricing:{input:.75,output:3,cached:.375,reasoning:4.5,cache_creation:.75}},{pattern:"glm-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"MiniMax-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"minimax-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"grok-code-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}},{pattern:"grok-*",pricing:{input:.5,output:2,cached:.25,reasoning:3,cache_creation:.5}}],i=new Map;function j(a,b){let c;return(!(c=i.get(a))&&(c=RegExp("^"+a.split("*").map(a=>a.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")).join(".*")+"$","i"),i.set(a,c)),c).test(b)}function k(a,b){if(!b)return null;if(a&&g[a]?.[b])return g[a][b];if(function(a){if(!a)return!1;let b=String(a).toLowerCase();return d.some(a=>b.startsWith(a))}(b))return e;let c=b.includes("/")?b.split("/").pop():b;if(f[c])return f[c];if(f[b])return f[b];for(let{pattern:a,pricing:d}of h)if(j(a,c)||j(a,b))return d;return null}function l(a,b){if(!a||!b)return 0;let c=0,d=a.prompt_tokens||a.input_tokens||0,e=a.cached_tokens||a.cache_read_input_tokens||0,f=a.cache_creation_input_tokens||0;c+=Math.max(0,d-e-f)*(b.input/1e6),e>0&&(c+=e*((b.cached||b.input)/1e6)),c+=(a.completion_tokens||a.output_tokens||0)*(b.output/1e6);let g=a.reasoning_tokens||0;return g>0&&(c+=g*((b.reasoning||b.output)/1e6)),f>0&&(c+=f*((b.cache_creation||b.input)/1e6)),c}}};
@@ -1 +1 @@
1
- "use strict";exports.id=6777,exports.ids=[6777],exports.modules={17660:(a,b,c)=>{c.d(b,{default:()=>f});var d=c(48249),e=c(71404);function f({children:a,title:b,subtitle:c,icon:g,action:h,padding:i="md",hover:j=!1,elev:k=!1,className:l,...m}){return(0,d.jsxs)("div",{className:(0,e.cn)("bg-surface border border-border-subtle",k?"rounded-[14px] shadow-[var(--shadow-elev)]":"rounded-[14px] shadow-[var(--shadow-soft)]",j&&"hover:shadow-[var(--shadow-warm)] hover:border-brand-500/30 transition-all cursor-pointer",{none:"",xs:"p-3",sm:"p-4",md:"p-6",lg:"p-8"}[i],l),...m,children:[(b||h)&&(0,d.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,d.jsxs)("div",{className:"flex items-center gap-3",children:[g&&(0,d.jsx)("div",{className:"p-2 rounded-[10px] bg-bg text-text-muted",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-[20px]",children:g})}),(0,d.jsxs)("div",{children:[b&&(0,d.jsx)("h3",{className:"text-text-main font-semibold",children:b}),c&&(0,d.jsx)("p",{className:"text-sm text-text-muted",children:c})]})]}),h]}),a]})}f.Section=function({children:a,className:b,...c}){return(0,d.jsx)("div",{className:(0,e.cn)("p-4 rounded-[10px]","bg-bg border border-border-subtle",b),...c,children:a})},f.Row=function({children:a,className:b,...c}){return(0,d.jsx)("div",{className:(0,e.cn)("p-3 -mx-3 px-3 transition-colors","border-b border-border-subtle last:border-b-0","hover:bg-surface-2/50",b),...c,children:a})},f.ListItem=function({children:a,actions:b,className:c,...f}){return(0,d.jsxs)("div",{className:(0,e.cn)("group flex items-center justify-between p-3 -mx-3 px-3","border-b border-border-subtle last:border-b-0","hover:bg-surface-2/50 transition-colors",c),...f,children:[(0,d.jsx)("div",{className:"flex-1 min-w-0",children:a}),b&&(0,d.jsx)("div",{className:"flex items-center gap-1 opacity-0 group-hover:opacity-100 transition-opacity",children:b})]})}},18982:(a,b,c)=>{c.d(b,{ad:()=>f,gH:()=>e});let d={gh:{"gpt-5.3-codex":{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75}},tokenrouter:{"MiniMax-M3":{input:.3,output:1.2,cached:.06,reasoning:1.2},"anthropic/claude-fable-5":{input:10,output:50,cached:1,cache_creation:12.5,reasoning:50},"anthropic/claude-haiku-4.5":{input:1,output:5,cached:.1,cache_creation:1.25,reasoning:5},"anthropic/claude-opus-4.5":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-4.6":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-4.7":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-4.7-fast":{input:30,output:150,cached:3,reasoning:150},"anthropic/claude-opus-4.8":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-4.8-fast":{input:10,output:50,cached:1,cache_creation:12.5,reasoning:50},"anthropic/claude-opus-5":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-5-fast":{input:10,output:50,cached:1,cache_creation:12.5,reasoning:50},"anthropic/claude-sonnet-4":{input:3,output:15,cached:.3,cache_creation:3.75,reasoning:15},"anthropic/claude-sonnet-4.5":{input:3,output:15,cached:.3,cache_creation:3.75,reasoning:15},"anthropic/claude-sonnet-4.6":{input:3,output:15,cached:.3,cache_creation:3.75,reasoning:15},"anthropic/claude-sonnet-5":{input:2,output:10,cached:.2,reasoning:10},"claude-opus-4-8-m-aws":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"deepseek/deepseek-v3.2":{input:.26,output:.38,cached:.13,reasoning:.38},"deepseek/deepseek-v4-flash":{input:.14,output:.28,cached:.0028,reasoning:.28},"deepseek/deepseek-v4-flash-0731":{input:.14,output:.28,cached:.0028,reasoning:.28},"deepseek/deepseek-v4-pro":{input:.435,output:.87,cached:.003625,reasoning:.87},"ex/gpt-5.4":{input:2.5,output:15,cached:.25,reasoning:15},"google/gemini-2.5-flash-image":{input:.3,output:2.5,reasoning:2.5},"google/gemini-3-flash-preview":{input:.5,output:3,cached:.05,cache_creation:.08333,reasoning:3},"google/gemini-3-pro-image-preview":{input:2,output:12,reasoning:12},"google/gemini-3.1-flash-image-preview":{input:.5,output:3,reasoning:3},"google/gemini-3.1-flash-lite-image":{input:.25,output:1.5,reasoning:1.5},"google/gemini-3.1-pro-preview":{input:2,output:12,cached:.2,cache_creation:.375,reasoning:12},"google/gemini-3.5-flash":{input:1.5,output:9,cached:.15,cache_creation:.08333,reasoning:9},"google/gemini-3.5-flash-lite":{input:.3,output:2.5,cached:.03,cache_creation:.08333,reasoning:2.5},"google/gemini-3.6-flash":{input:1.5,output:7.5,cached:.15,cache_creation:.08333,reasoning:7.5},"google/gemini-embedding-2":{input:1,output:6,cached:.1,reasoning:6},"google/gemma-4-26b-a4b-it":{input:.06,output:.33,reasoning:.33},"kling-3.0-turbo":{input:2.1,output:2.1,reasoning:2.1},"microsoft/mai-image-2.5":{input:5,output:47,reasoning:47},"minimax/minimax-m2-her":{input:.3,output:1.2,cached:.03,reasoning:1.2},"minimax/minimax-m2.1":{input:.3,output:1.2,cached:.03,reasoning:1.2},"minimax/minimax-m2.1-highspeed":{input:.6,output:2.4,cached:.06,reasoning:2.4},"minimax/minimax-m2.5":{input:.3,output:1.2,cached:.03,reasoning:1.2},"minimax/minimax-m2.7":{input:.3,output:1.2,cached:.06,reasoning:1.2},"minimax/minimax-m2.7-highspeed":{input:.6,output:2.4,cached:.06,reasoning:2.4},"miromind/mirothinker-1-7-deepresearch":{input:4,output:25,reasoning:25},"miromind/mirothinker-1-7-deepresearch-mini":{input:1.25,output:10,reasoning:10},"mistralai/devstral-2512":{input:.4,output:2,cached:.04,reasoning:2},"mistralai/mistral-medium-3-5":{input:1.5,output:7.5,reasoning:7.5},"mistralai/mistral-small-2603":{input:.15,output:.6,cached:.015,reasoning:.6},"mistralai/voxtral-small-24b-2507":{input:.1,output:.3,cached:.01,reasoning:.3},"moonshotai/kimi-k2.5":{input:.6,output:3,cached:.1,reasoning:3},"moonshotai/kimi-k2.6":{input:.95,output:4,cached:.16,reasoning:4},"moonshotai/kimi-k2.7-code":{input:.9286,output:3.8571,cached:.1857,reasoning:3.8571},"moonshotai/kimi-k3":{input:3,output:15,cached:.3,reasoning:15},"nvidia/nemotron-3-super-120b-a12b":{input:.3,output:.9,cached:.1,reasoning:.9},"openai/gpt-4o-mini":{input:.15,output:.6,cached:.075,reasoning:.6},"openai/gpt-5":{input:1.25,output:10,cached:.125,reasoning:10},"openai/gpt-5-image":{input:10,output:40,cached:2.5,reasoning:40},"openai/gpt-5-image-mini":{input:2.5,output:8,cached:.25,reasoning:8},"openai/gpt-5-mini":{input:.25,output:2,cached:.025,reasoning:2},"openai/gpt-5.2":{input:1.75,output:14,cached:.175,reasoning:14},"openai/gpt-5.3-codex":{input:1.75,output:14,cached:.175,reasoning:14},"openai/gpt-5.4":{input:2.5,output:15,cached:.25,reasoning:15},"openai/gpt-5.4-image-2":{input:8,output:30,cached:2,reasoning:30},"openai/gpt-5.4-mini":{input:.75,output:4.5,cached:.075,reasoning:4.5},"openai/gpt-5.4-nano":{input:.2,output:1.25,cached:.02,reasoning:1.25},"openai/gpt-5.4-pro":{input:30,output:180,reasoning:180},"openai/gpt-5.5":{input:5,output:30,cached:.5,reasoning:30},"openai/gpt-5.5-pro":{input:30,output:180,reasoning:180},"openai/gpt-5.6-luna":{input:.2,output:1.2,cached:.02,cache_creation:.25,reasoning:1.2},"openai/gpt-5.6-sol":{input:5,output:30,cached:.5,cache_creation:6.25,reasoning:30},"openai/gpt-5.6-terra":{input:2,output:12,cached:.2,cache_creation:2.5,reasoning:12},"openai/gpt-audio":{input:2.5,output:10,reasoning:10},"openai/gpt-audio-mini":{input:.6,output:2.4,reasoning:2.4},"openai/gpt-oss-120b":{input:.039,output:.18,reasoning:.18},"qwen/qwen3-coder-next":{input:.12,output:.75,cached:.06,reasoning:.75},"qwen/qwen3.5-122b-a10b":{input:.26,output:2.08,reasoning:2.08},"qwen/qwen3.5-35b-a3b":{input:.1625,output:1.3,reasoning:1.3},"qwen/qwen3.5-397b-a17b":{input:.39,output:2.34,reasoning:2.34},"qwen/qwen3.5-9b":{input:.1,output:.15,reasoning:.15},"qwen/qwen3.5-flash":{input:.1048,output:.4194,reasoning:.4194},"qwen/qwen3.5-plus-02-15":{input:.26,output:1.56,reasoning:1.56},"qwen/qwen3.6-plus":{input:.54,output:3.21,reasoning:3.21},"qwen/qwen3.7-max":{input:1.25,output:3.75,cached:.25,reasoning:3.75},"qwen/qwen3.7-plus":{input:.4,output:1.6,cached:.08,reasoning:1.6},"qwen/qwen3.8-max":{input:2,output:6,cached:.25,cache_creation:2.5,reasoning:6},"qwen3.5-omni-plus":{input:1,output:5.7143,reasoning:5.7143},"qwen3.6-flash":{input:.171,output:1.029,cached:.017,cache_creation:.214,reasoning:1.029},"sakana/fugu-ultra":{input:5,output:30,cached:.5,reasoning:30},"seed-2-0-code-preview-260328":{input:1,output:6,cached:.2,cache_creation:.008333,reasoning:6},"seed-2-0-lite-260428":{input:.5,output:4,cached:.1,cache_creation:.008333,reasoning:4},"seed-2-0-mini-260428":{input:.2,output:.8,cached:.04,cache_creation:.00833,reasoning:.8},"seed-2-0-pro-260328":{input:1,output:6,cached:.2,cache_creation:.008333,reasoning:6},"stepfun/step-3.5-flash":{input:.1,output:.3,cached:.02,reasoning:.3},"stepfun/step-3.7-flash":{input:.2,output:1.15,cached:.04,reasoning:1.15},"tencent/hy3-preview":{input:.066,output:.26,cached:.029,reasoning:.26},"x-ai/grok-4.1-fast":{input:.2,output:.5,cached:.05,reasoning:.5},"x-ai/grok-4.20-beta":{input:2,output:6,cached:.2,reasoning:6},"x-ai/grok-4.3":{input:1.25,output:2.5,cached:.2,reasoning:2.5},"x-ai/grok-4.5":{input:2,output:6,cached:.5,reasoning:6},"x-ai/grok-build-0.1":{input:1,output:2,cached:.2,reasoning:2},"xiaomi/mimo-v2-flash":{input:.1,output:.3,cached:.01,reasoning:.3},"xiaomi/mimo-v2-omni":{input:.4,output:2,cached:.08,reasoning:2},"xiaomi/mimo-v2-pro":{input:1,output:3,cached:.2,reasoning:3},"xiaomi/mimo-v2.5":{input:.4,output:2,cached:.08,reasoning:2},"xiaomi/mimo-v2.5-pro":{input:1,output:3,cached:.2,reasoning:3},"z-ai/glm-4.5-air":{input:.13,output:.85,cached:.025,reasoning:.85},"z-ai/glm-4.6":{input:.6,output:2.2,cached:.11,reasoning:2.2},"z-ai/glm-4.6v":{input:.3,output:.9,reasoning:.9},"z-ai/glm-4.7":{input:.6,output:2.2,cached:.11,reasoning:2.2},"z-ai/glm-5":{input:1,output:3.2,cached:.2,reasoning:3.2},"z-ai/glm-5-turbo":{input:1.2,output:4,cached:.24,reasoning:4},"z-ai/glm-5.1":{input:1.05,output:3.5,cached:.525,reasoning:3.5},"z-ai/glm-5.2":{input:1.4,output:4.4,cached:.26,reasoning:4.4},"z-ai/glm-5.3-free":{input:0,output:0,cached:0,reasoning:0}}};function e(a,b){return RegExp("^"+a.split("*").map(a=>a.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")).join(".*")+"$","i").test(b)}function f(){return d}},71404:(a,b,c)=>{c.d(b,{cn:()=>d});function d(...a){return a.filter(Boolean).join(" ").replace(/\s+/g," ").trim()}}};
1
+ "use strict";exports.id=6777,exports.ids=[6777],exports.modules={17660:(a,b,c)=>{c.d(b,{default:()=>f});var d=c(48249),e=c(71404);function f({children:a,title:b,subtitle:c,icon:g,action:h,padding:i="md",hover:j=!1,elev:k=!1,className:l,...m}){return(0,d.jsxs)("div",{className:(0,e.cn)("bg-surface border border-border-subtle",k?"rounded-[14px] shadow-[var(--shadow-elev)]":"rounded-[14px] shadow-[var(--shadow-soft)]",j&&"hover:shadow-[var(--shadow-warm)] hover:border-brand-500/30 transition-all cursor-pointer",{none:"",xs:"p-3",sm:"p-4",md:"p-6",lg:"p-8"}[i],l),...m,children:[(b||h)&&(0,d.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,d.jsxs)("div",{className:"flex items-center gap-3",children:[g&&(0,d.jsx)("div",{className:"p-2 rounded-[10px] bg-bg text-text-muted",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-[20px]",children:g})}),(0,d.jsxs)("div",{children:[b&&(0,d.jsx)("h3",{className:"text-text-main font-semibold",children:b}),c&&(0,d.jsx)("p",{className:"text-sm text-text-muted",children:c})]})]}),h]}),a]})}f.Section=function({children:a,className:b,...c}){return(0,d.jsx)("div",{className:(0,e.cn)("p-4 rounded-[10px]","bg-bg border border-border-subtle",b),...c,children:a})},f.Row=function({children:a,className:b,...c}){return(0,d.jsx)("div",{className:(0,e.cn)("p-3 -mx-3 px-3 transition-colors","border-b border-border-subtle last:border-b-0","hover:bg-surface-2/50",b),...c,children:a})},f.ListItem=function({children:a,actions:b,className:c,...f}){return(0,d.jsxs)("div",{className:(0,e.cn)("group flex items-center justify-between p-3 -mx-3 px-3","border-b border-border-subtle last:border-b-0","hover:bg-surface-2/50 transition-colors",c),...f,children:[(0,d.jsx)("div",{className:"flex-1 min-w-0",children:a}),b&&(0,d.jsx)("div",{className:"flex items-center gap-1 opacity-0 group-hover:opacity-100 transition-opacity",children:b})]})}},18982:(a,b,c)=>{c.d(b,{ad:()=>g,gH:()=>f});let d={gh:{"gpt-5.3-codex":{input:1.75,output:14,cached:.175,reasoning:14,cache_creation:1.75}},tokenrouter:{"MiniMax-M3":{input:.3,output:1.2,cached:.06,reasoning:1.2},"anthropic/claude-fable-5":{input:10,output:50,cached:1,cache_creation:12.5,reasoning:50},"anthropic/claude-haiku-4.5":{input:1,output:5,cached:.1,cache_creation:1.25,reasoning:5},"anthropic/claude-opus-4.5":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-4.6":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-4.7":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-4.7-fast":{input:30,output:150,cached:3,reasoning:150},"anthropic/claude-opus-4.8":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-4.8-fast":{input:10,output:50,cached:1,cache_creation:12.5,reasoning:50},"anthropic/claude-opus-5":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"anthropic/claude-opus-5-fast":{input:10,output:50,cached:1,cache_creation:12.5,reasoning:50},"anthropic/claude-sonnet-4":{input:3,output:15,cached:.3,cache_creation:3.75,reasoning:15},"anthropic/claude-sonnet-4.5":{input:3,output:15,cached:.3,cache_creation:3.75,reasoning:15},"anthropic/claude-sonnet-4.6":{input:3,output:15,cached:.3,cache_creation:3.75,reasoning:15},"anthropic/claude-sonnet-5":{input:2,output:10,cached:.2,reasoning:10},"claude-opus-4-8-m-aws":{input:5,output:25,cached:.5,cache_creation:6.25,reasoning:25},"deepseek/deepseek-v3.2":{input:.26,output:.38,cached:.13,reasoning:.38},"deepseek/deepseek-v4-flash":{input:.14,output:.28,cached:.0028,reasoning:.28},"deepseek/deepseek-v4-flash-0731":{input:.14,output:.28,cached:.0028,reasoning:.28},"deepseek/deepseek-v4-pro":{input:.435,output:.87,cached:.003625,reasoning:.87},"ex/gpt-5.4":{input:2.5,output:15,cached:.25,reasoning:15},"google/gemini-2.5-flash-image":{input:.3,output:2.5,reasoning:2.5},"google/gemini-3-flash-preview":{input:.5,output:3,cached:.05,cache_creation:.08333,reasoning:3},"google/gemini-3-pro-image-preview":{input:2,output:12,reasoning:12},"google/gemini-3.1-flash-image-preview":{input:.5,output:3,reasoning:3},"google/gemini-3.1-flash-lite-image":{input:.25,output:1.5,reasoning:1.5},"google/gemini-3.1-pro-preview":{input:2,output:12,cached:.2,cache_creation:.375,reasoning:12},"google/gemini-3.5-flash":{input:1.5,output:9,cached:.15,cache_creation:.08333,reasoning:9},"google/gemini-3.5-flash-lite":{input:.3,output:2.5,cached:.03,cache_creation:.08333,reasoning:2.5},"google/gemini-3.6-flash":{input:1.5,output:7.5,cached:.15,cache_creation:.08333,reasoning:7.5},"google/gemini-embedding-2":{input:1,output:6,cached:.1,reasoning:6},"google/gemma-4-26b-a4b-it":{input:.06,output:.33,reasoning:.33},"kling-3.0-turbo":{input:2.1,output:2.1,reasoning:2.1},"microsoft/mai-image-2.5":{input:5,output:47,reasoning:47},"minimax/minimax-m2-her":{input:.3,output:1.2,cached:.03,reasoning:1.2},"minimax/minimax-m2.1":{input:.3,output:1.2,cached:.03,reasoning:1.2},"minimax/minimax-m2.1-highspeed":{input:.6,output:2.4,cached:.06,reasoning:2.4},"minimax/minimax-m2.5":{input:.3,output:1.2,cached:.03,reasoning:1.2},"minimax/minimax-m2.7":{input:.3,output:1.2,cached:.06,reasoning:1.2},"minimax/minimax-m2.7-highspeed":{input:.6,output:2.4,cached:.06,reasoning:2.4},"miromind/mirothinker-1-7-deepresearch":{input:4,output:25,reasoning:25},"miromind/mirothinker-1-7-deepresearch-mini":{input:1.25,output:10,reasoning:10},"mistralai/devstral-2512":{input:.4,output:2,cached:.04,reasoning:2},"mistralai/mistral-medium-3-5":{input:1.5,output:7.5,reasoning:7.5},"mistralai/mistral-small-2603":{input:.15,output:.6,cached:.015,reasoning:.6},"mistralai/voxtral-small-24b-2507":{input:.1,output:.3,cached:.01,reasoning:.3},"moonshotai/kimi-k2.5":{input:.6,output:3,cached:.1,reasoning:3},"moonshotai/kimi-k2.6":{input:.95,output:4,cached:.16,reasoning:4},"moonshotai/kimi-k2.7-code":{input:.9286,output:3.8571,cached:.1857,reasoning:3.8571},"moonshotai/kimi-k3":{input:3,output:15,cached:.3,reasoning:15},"nvidia/nemotron-3-super-120b-a12b":{input:.3,output:.9,cached:.1,reasoning:.9},"openai/gpt-4o-mini":{input:.15,output:.6,cached:.075,reasoning:.6},"openai/gpt-5":{input:1.25,output:10,cached:.125,reasoning:10},"openai/gpt-5-image":{input:10,output:40,cached:2.5,reasoning:40},"openai/gpt-5-image-mini":{input:2.5,output:8,cached:.25,reasoning:8},"openai/gpt-5-mini":{input:.25,output:2,cached:.025,reasoning:2},"openai/gpt-5.2":{input:1.75,output:14,cached:.175,reasoning:14},"openai/gpt-5.3-codex":{input:1.75,output:14,cached:.175,reasoning:14},"openai/gpt-5.4":{input:2.5,output:15,cached:.25,reasoning:15},"openai/gpt-5.4-image-2":{input:8,output:30,cached:2,reasoning:30},"openai/gpt-5.4-mini":{input:.75,output:4.5,cached:.075,reasoning:4.5},"openai/gpt-5.4-nano":{input:.2,output:1.25,cached:.02,reasoning:1.25},"openai/gpt-5.4-pro":{input:30,output:180,reasoning:180},"openai/gpt-5.5":{input:5,output:30,cached:.5,reasoning:30},"openai/gpt-5.5-pro":{input:30,output:180,reasoning:180},"openai/gpt-5.6-luna":{input:.2,output:1.2,cached:.02,cache_creation:.25,reasoning:1.2},"openai/gpt-5.6-sol":{input:5,output:30,cached:.5,cache_creation:6.25,reasoning:30},"openai/gpt-5.6-terra":{input:2,output:12,cached:.2,cache_creation:2.5,reasoning:12},"openai/gpt-audio":{input:2.5,output:10,reasoning:10},"openai/gpt-audio-mini":{input:.6,output:2.4,reasoning:2.4},"openai/gpt-oss-120b":{input:.039,output:.18,reasoning:.18},"qwen/qwen3-coder-next":{input:.12,output:.75,cached:.06,reasoning:.75},"qwen/qwen3.5-122b-a10b":{input:.26,output:2.08,reasoning:2.08},"qwen/qwen3.5-35b-a3b":{input:.1625,output:1.3,reasoning:1.3},"qwen/qwen3.5-397b-a17b":{input:.39,output:2.34,reasoning:2.34},"qwen/qwen3.5-9b":{input:.1,output:.15,reasoning:.15},"qwen/qwen3.5-flash":{input:.1048,output:.4194,reasoning:.4194},"qwen/qwen3.5-plus-02-15":{input:.26,output:1.56,reasoning:1.56},"qwen/qwen3.6-plus":{input:.54,output:3.21,reasoning:3.21},"qwen/qwen3.7-max":{input:1.25,output:3.75,cached:.25,reasoning:3.75},"qwen/qwen3.7-plus":{input:.4,output:1.6,cached:.08,reasoning:1.6},"qwen/qwen3.8-max":{input:2,output:6,cached:.25,cache_creation:2.5,reasoning:6},"qwen3.5-omni-plus":{input:1,output:5.7143,reasoning:5.7143},"qwen3.6-flash":{input:.171,output:1.029,cached:.017,cache_creation:.214,reasoning:1.029},"sakana/fugu-ultra":{input:5,output:30,cached:.5,reasoning:30},"seed-2-0-code-preview-260328":{input:1,output:6,cached:.2,cache_creation:.008333,reasoning:6},"seed-2-0-lite-260428":{input:.5,output:4,cached:.1,cache_creation:.008333,reasoning:4},"seed-2-0-mini-260428":{input:.2,output:.8,cached:.04,cache_creation:.00833,reasoning:.8},"seed-2-0-pro-260328":{input:1,output:6,cached:.2,cache_creation:.008333,reasoning:6},"stepfun/step-3.5-flash":{input:.1,output:.3,cached:.02,reasoning:.3},"stepfun/step-3.7-flash":{input:.2,output:1.15,cached:.04,reasoning:1.15},"tencent/hy3-preview":{input:.066,output:.26,cached:.029,reasoning:.26},"x-ai/grok-4.1-fast":{input:.2,output:.5,cached:.05,reasoning:.5},"x-ai/grok-4.20-beta":{input:2,output:6,cached:.2,reasoning:6},"x-ai/grok-4.3":{input:1.25,output:2.5,cached:.2,reasoning:2.5},"x-ai/grok-4.5":{input:2,output:6,cached:.5,reasoning:6},"x-ai/grok-build-0.1":{input:1,output:2,cached:.2,reasoning:2},"xiaomi/mimo-v2-flash":{input:.1,output:.3,cached:.01,reasoning:.3},"xiaomi/mimo-v2-omni":{input:.4,output:2,cached:.08,reasoning:2},"xiaomi/mimo-v2-pro":{input:1,output:3,cached:.2,reasoning:3},"xiaomi/mimo-v2.5":{input:.4,output:2,cached:.08,reasoning:2},"xiaomi/mimo-v2.5-pro":{input:1,output:3,cached:.2,reasoning:3},"z-ai/glm-4.5-air":{input:.13,output:.85,cached:.025,reasoning:.85},"z-ai/glm-4.6":{input:.6,output:2.2,cached:.11,reasoning:2.2},"z-ai/glm-4.6v":{input:.3,output:.9,reasoning:.9},"z-ai/glm-4.7":{input:.6,output:2.2,cached:.11,reasoning:2.2},"z-ai/glm-5":{input:1,output:3.2,cached:.2,reasoning:3.2},"z-ai/glm-5-turbo":{input:1.2,output:4,cached:.24,reasoning:4},"z-ai/glm-5.1":{input:1.05,output:3.5,cached:.525,reasoning:3.5},"z-ai/glm-5.2":{input:1.4,output:4.4,cached:.26,reasoning:4.4},"z-ai/glm-5.3-free":{input:0,output:0,cached:0,reasoning:0}}},e=new Map;function f(a,b){let c;return(!(c=e.get(a))&&(c=RegExp("^"+a.split("*").map(a=>a.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")).join(".*")+"$","i"),e.set(a,c)),c).test(b)}function g(){return d}},71404:(a,b,c)=>{c.d(b,{cn:()=>d});function d(...a){return a.filter(Boolean).join(" ").replace(/\s+/g," ").trim()}}};
@@ -1 +1 @@
1
- "use strict";exports.id=6844,exports.ids=[6844],exports.modules={86844:(a,b,c)=>{c.d(b,{generateApiKeyWithMachine:()=>g});var d=c(55511),e=c.n(d);let f=process.env.API_KEY_SECRET||"endpoint-proxy-api-key-secret";function g(a){let b=function(){let a="abcdefghijklmnopqrstuvwxyz0123456789",b="";for(let c=0;c<6;c++)b+=a.charAt(Math.floor(Math.random()*a.length));return b}(),c=e().createHmac("sha256",f).update(a+b).digest("hex").slice(0,8);return{key:`sk-${a}-${b}-${c}`,keyId:b}}}};
1
+ "use strict";exports.id=6844,exports.ids=[6844],exports.modules={86844:(a,b,c)=>{c.d(b,{generateApiKeyWithMachine:()=>g});var d=c(55511),e=c.n(d);let f=process.env.API_KEY_SECRET||"endpoint-proxy-api-key-secret";function g(a){let b=e().randomBytes(18).toString("base64url").replace(/-/g,"_"),c=e().createHmac("sha256",f).update(a+b).digest("hex").slice(0,8);return{key:`sk-${a}-${b}-${c}`,keyId:b}}}};
@@ -1,4 +1,4 @@
1
- "use strict";exports.id=698,exports.ids=[698],exports.modules={76040:(a,b,c)=>{c.d(b,{CG:()=>f,f$:()=>d,oG:()=>e,zE:()=>g});let d=2,e=`
1
+ "use strict";exports.id=698,exports.ids=[698],exports.modules={76040:(a,b,c)=>{c.d(b,{CG:()=>f,f$:()=>d,oG:()=>e,zE:()=>g});let d=3,e=`
2
2
  PRAGMA journal_mode = WAL;
3
3
  PRAGMA synchronous = NORMAL;
4
4
  PRAGMA temp_store = MEMORY;
@@ -6,4 +6,4 @@ PRAGMA mmap_size = 30000000;
6
6
  PRAGMA cache_size = -64000;
7
7
  PRAGMA foreign_keys = ON;
8
8
  PRAGMA busy_timeout = 5000;
9
- `,f={_meta:{columns:{key:"TEXT PRIMARY KEY",value:"TEXT NOT NULL"}},settings:{columns:{id:"INTEGER PRIMARY KEY CHECK (id = 1)",data:"TEXT NOT NULL"}},providerConnections:{columns:{id:"TEXT PRIMARY KEY",provider:"TEXT NOT NULL",authType:"TEXT NOT NULL",name:"TEXT",email:"TEXT",priority:"INTEGER",isActive:"INTEGER DEFAULT 1",data:"TEXT NOT NULL",createdAt:"TEXT NOT NULL",updatedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_pc_provider ON providerConnections(provider)","CREATE INDEX IF NOT EXISTS idx_pc_provider_active ON providerConnections(provider, isActive)","CREATE INDEX IF NOT EXISTS idx_pc_priority ON providerConnections(provider, priority)"]},providerNodes:{columns:{id:"TEXT PRIMARY KEY",type:"TEXT",name:"TEXT",data:"TEXT NOT NULL",createdAt:"TEXT NOT NULL",updatedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_pn_type ON providerNodes(type)"]},proxyPools:{columns:{id:"TEXT PRIMARY KEY",isActive:"INTEGER DEFAULT 1",testStatus:"TEXT",data:"TEXT NOT NULL",createdAt:"TEXT NOT NULL",updatedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_pp_active ON proxyPools(isActive)","CREATE INDEX IF NOT EXISTS idx_pp_status ON proxyPools(testStatus)"]},apiKeys:{columns:{id:"TEXT PRIMARY KEY",key:"TEXT UNIQUE NOT NULL",name:"TEXT",machineId:"TEXT",isActive:"INTEGER DEFAULT 1",createdAt:"TEXT NOT NULL",accessRestricted:"INTEGER DEFAULT 0",accessAllow:"TEXT"},indexes:["CREATE INDEX IF NOT EXISTS idx_ak_key ON apiKeys(key)"]},combos:{columns:{id:"TEXT PRIMARY KEY",name:"TEXT UNIQUE NOT NULL",kind:"TEXT",models:"TEXT NOT NULL",createdAt:"TEXT NOT NULL",updatedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_combo_name ON combos(name)"]},kv:{columns:{scope:"TEXT NOT NULL",key:"TEXT NOT NULL",value:"TEXT NOT NULL"},primaryKey:"PRIMARY KEY (scope, key)",indexes:["CREATE INDEX IF NOT EXISTS idx_kv_scope ON kv(scope)"]},usageHistory:{columns:{id:"INTEGER PRIMARY KEY AUTOINCREMENT",timestamp:"TEXT NOT NULL",provider:"TEXT",model:"TEXT",connectionId:"TEXT",apiKey:"TEXT",endpoint:"TEXT",promptTokens:"INTEGER DEFAULT 0",completionTokens:"INTEGER DEFAULT 0",cost:"REAL DEFAULT 0",status:"TEXT",tokens:"TEXT",meta:"TEXT"},indexes:["CREATE INDEX IF NOT EXISTS idx_uh_ts ON usageHistory(timestamp DESC)","CREATE INDEX IF NOT EXISTS idx_uh_provider ON usageHistory(provider)","CREATE INDEX IF NOT EXISTS idx_uh_model ON usageHistory(model)","CREATE INDEX IF NOT EXISTS idx_uh_conn ON usageHistory(connectionId)"]},usageDaily:{columns:{dateKey:"TEXT PRIMARY KEY",data:"TEXT NOT NULL"}},requestDetails:{columns:{id:"TEXT PRIMARY KEY",timestamp:"TEXT NOT NULL",provider:"TEXT",model:"TEXT",connectionId:"TEXT",status:"TEXT",data:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_rd_ts ON requestDetails(timestamp DESC)","CREATE INDEX IF NOT EXISTS idx_rd_provider ON requestDetails(provider)","CREATE INDEX IF NOT EXISTS idx_rd_model ON requestDetails(model)","CREATE INDEX IF NOT EXISTS idx_rd_conn ON requestDetails(connectionId)"]}};function g(a,b){let c=Object.entries(b.columns).map(([a,b])=>`${a} ${b}`);return b.primaryKey&&c.push(b.primaryKey),`CREATE TABLE IF NOT EXISTS ${a} (${c.join(", ")})`}},90698:(a,b,c)=>{c.d(b,{createBunSqliteAdapter:()=>e});var d=c(76040);async function e(a){let{Database:b}=await Promise.resolve().then(c.t.bind(c,81787,23)),e=new b(a,{create:!0});e.exec(d.oG);let f=new Map;function g(a){let b=f.get(a);return b||(b=e.prepare(a),f.set(a,b)),b}let h=setInterval(()=>{try{e.exec("PRAGMA wal_checkpoint(TRUNCATE)")}catch{}},6e4);function i(){try{e.exec("PRAGMA wal_checkpoint(TRUNCATE)")}catch{}try{f.clear()}catch{}try{e.close()}catch{}}"function"==typeof h.unref&&h.unref();let j=()=>i();return process.once("beforeExit",j),process.once("SIGINT",()=>{j(),process.exit(0)}),process.once("SIGTERM",()=>{j(),process.exit(0)}),{driver:"bun:sqlite",run(a,b=[]){let c=g(a).run(...b);return{changes:Number(c.changes??0),lastInsertRowid:Number(c.lastInsertRowid??0)}},get:(a,b=[])=>g(a).get(...b),all:(a,b=[])=>g(a).all(...b),exec:a=>e.exec(a),transaction:a=>e.transaction(a)(),checkpoint(){try{e.exec("PRAGMA wal_checkpoint(TRUNCATE)")}catch{}},close(){clearInterval(h),i()},raw:e}}}};
9
+ `,f={_meta:{columns:{key:"TEXT PRIMARY KEY",value:"TEXT NOT NULL"}},settings:{columns:{id:"INTEGER PRIMARY KEY CHECK (id = 1)",data:"TEXT NOT NULL"}},providerConnections:{columns:{id:"TEXT PRIMARY KEY",provider:"TEXT NOT NULL",authType:"TEXT NOT NULL",name:"TEXT",email:"TEXT",priority:"INTEGER",isActive:"INTEGER DEFAULT 1",data:"TEXT NOT NULL",createdAt:"TEXT NOT NULL",updatedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_pc_provider ON providerConnections(provider)","CREATE INDEX IF NOT EXISTS idx_pc_provider_active ON providerConnections(provider, isActive)","CREATE INDEX IF NOT EXISTS idx_pc_priority ON providerConnections(provider, priority)"]},providerNodes:{columns:{id:"TEXT PRIMARY KEY",type:"TEXT",name:"TEXT",data:"TEXT NOT NULL",createdAt:"TEXT NOT NULL",updatedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_pn_type ON providerNodes(type)"]},proxyPools:{columns:{id:"TEXT PRIMARY KEY",isActive:"INTEGER DEFAULT 1",testStatus:"TEXT",data:"TEXT NOT NULL",createdAt:"TEXT NOT NULL",updatedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_pp_active ON proxyPools(isActive)","CREATE INDEX IF NOT EXISTS idx_pp_status ON proxyPools(testStatus)"]},apiKeys:{columns:{id:"TEXT PRIMARY KEY",key:"TEXT NOT NULL",keyHash:"TEXT",name:"TEXT",machineId:"TEXT",isActive:"INTEGER DEFAULT 1",createdAt:"TEXT NOT NULL",accessRestricted:"INTEGER DEFAULT 0",accessAllow:"TEXT"},indexes:["CREATE INDEX IF NOT EXISTS idx_ak_key ON apiKeys(key)","CREATE UNIQUE INDEX IF NOT EXISTS idx_ak_key_hash ON apiKeys(keyHash)"]},combos:{columns:{id:"TEXT PRIMARY KEY",name:"TEXT UNIQUE NOT NULL",kind:"TEXT",models:"TEXT NOT NULL",createdAt:"TEXT NOT NULL",updatedAt:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_combo_name ON combos(name)"]},kv:{columns:{scope:"TEXT NOT NULL",key:"TEXT NOT NULL",value:"TEXT NOT NULL"},primaryKey:"PRIMARY KEY (scope, key)",indexes:["CREATE INDEX IF NOT EXISTS idx_kv_scope ON kv(scope)"]},usageHistory:{columns:{id:"INTEGER PRIMARY KEY AUTOINCREMENT",timestamp:"TEXT NOT NULL",provider:"TEXT",model:"TEXT",connectionId:"TEXT",apiKey:"TEXT",endpoint:"TEXT",promptTokens:"INTEGER DEFAULT 0",completionTokens:"INTEGER DEFAULT 0",cost:"REAL DEFAULT 0",status:"TEXT",tokens:"TEXT",meta:"TEXT"},indexes:["CREATE INDEX IF NOT EXISTS idx_uh_ts ON usageHistory(timestamp DESC)","CREATE INDEX IF NOT EXISTS idx_uh_provider ON usageHistory(provider)","CREATE INDEX IF NOT EXISTS idx_uh_model ON usageHistory(model)","CREATE INDEX IF NOT EXISTS idx_uh_conn ON usageHistory(connectionId)"]},usageDaily:{columns:{dateKey:"TEXT PRIMARY KEY",data:"TEXT NOT NULL"}},requestDetails:{columns:{id:"TEXT PRIMARY KEY",timestamp:"TEXT NOT NULL",provider:"TEXT",model:"TEXT",connectionId:"TEXT",status:"TEXT",data:"TEXT NOT NULL"},indexes:["CREATE INDEX IF NOT EXISTS idx_rd_ts ON requestDetails(timestamp DESC)","CREATE INDEX IF NOT EXISTS idx_rd_provider ON requestDetails(provider)","CREATE INDEX IF NOT EXISTS idx_rd_model ON requestDetails(model)","CREATE INDEX IF NOT EXISTS idx_rd_conn ON requestDetails(connectionId)"]}};function g(a,b){let c=Object.entries(b.columns).map(([a,b])=>`${a} ${b}`);return b.primaryKey&&c.push(b.primaryKey),`CREATE TABLE IF NOT EXISTS ${a} (${c.join(", ")})`}},90698:(a,b,c)=>{c.d(b,{createBunSqliteAdapter:()=>e});var d=c(76040);async function e(a){let{Database:b}=await Promise.resolve().then(c.t.bind(c,81787,23)),e=new b(a,{create:!0});e.exec(d.oG);let f=new Map;function g(a){let b=f.get(a);return b||(b=e.prepare(a),f.set(a,b)),b}let h=setInterval(()=>{try{e.exec("PRAGMA wal_checkpoint(TRUNCATE)")}catch{}},6e4);function i(){try{e.exec("PRAGMA wal_checkpoint(TRUNCATE)")}catch{}try{f.clear()}catch{}try{e.close()}catch{}}"function"==typeof h.unref&&h.unref();let j=()=>i();return process.once("beforeExit",j),process.once("SIGINT",()=>{j(),process.exit(0)}),process.once("SIGTERM",()=>{j(),process.exit(0)}),{driver:"bun:sqlite",run(a,b=[]){let c=g(a).run(...b);return{changes:Number(c.changes??0),lastInsertRowid:Number(c.lastInsertRowid??0)}},get:(a,b=[])=>g(a).get(...b),all:(a,b=[])=>g(a).all(...b),exec:a=>e.exec(a),transaction:a=>e.transaction(a)(),checkpoint(){try{e.exec("PRAGMA wal_checkpoint(TRUNCATE)")}catch{}},close(){clearInterval(h),i()},raw:e}}}};
@@ -1 +1 @@
1
- "use strict";exports.id=7068,exports.ids=[3662,4051,6432,7068,9289,9609],exports.modules={3662:(a,b,c)=>{c.d(b,{EQ:()=>f,LY:()=>d,O:()=>e,fh:()=>h,t2:()=>i,wf:()=>g});let d={400:{type:"invalid_request_error",code:"bad_request"},401:{type:"authentication_error",code:"invalid_api_key"},402:{type:"billing_error",code:"payment_required"},403:{type:"permission_error",code:"insufficient_quota"},404:{type:"invalid_request_error",code:"model_not_found"},406:{type:"invalid_request_error",code:"model_not_supported"},429:{type:"rate_limit_error",code:"rate_limit_exceeded"},500:{type:"server_error",code:"internal_server_error"},502:{type:"server_error",code:"bad_gateway"},503:{type:"server_error",code:"service_unavailable"},504:{type:"server_error",code:"gateway_timeout"}},e={400:"Bad request",401:"Invalid API key provided",402:"Payment required",403:"You exceeded your current quota",404:"Model not found",406:"Model not supported",429:"Rate limit exceeded",500:"Internal server error",502:"Bad gateway - upstream provider error",503:"Service temporarily unavailable",504:"Gateway timeout"},f={base:2e3,max:3e5,maxLevel:15},g=3e4,h=18e5,i=[{provider:"codex",text:"model is not supported when using codex with a chatgpt account",cooldownMs:18e5},{text:"no credentials",cooldownMs:12e4},{text:"request not allowed",cooldownMs:5e3},{text:"improperly formed request",cooldownMs:12e4},{text:"rate limit",backoff:!0},{text:"too many requests",backoff:!0},{text:"quota exceeded",backoff:!0},{text:"capacity",backoff:!0},{text:"overloaded",backoff:!0},{status:401,cooldownMs:12e4},{status:402,cooldownMs:12e4},{status:403,cooldownMs:12e4},{status:404,cooldownMs:12e4},{status:429,backoff:!0}]},39609:(a,b,c)=>{c.r(b),c.d(b,{default:()=>u,proxyAwareFetch:()=>s});var d=c(27910),e=c(41004);let f=globalThis.fetch,g=new Map,h=new Map,i=new Set(["SELF_SIGNED_CERT_IN_CHAIN","DEPTH_ZERO_SELF_SIGNED_CERT","UNABLE_TO_VERIFY_LEAF_SIGNATURE","UNABLE_TO_GET_ISSUER_CERT","UNABLE_TO_GET_ISSUER_CERT_LOCALLY","CERT_HAS_EXPIRED","ERR_TLS_CERT_ALTNAME_INVALID"]),j=["cloudcode-pa.googleapis.com","daily-cloudcode-pa.googleapis.com","api.individual.githubcopilot.com","q.us-east-1.amazonaws.com","codewhisperer.us-east-1.amazonaws.com","api2.cursor.sh"],k=["8.8.8.8","8.8.4.4"];function l(a){return null==a?"":String(a).trim()}async function m(a){let b=h.get(a);if(b&&Date.now()<b.expiry)return b.ip;try{let b=await Promise.resolve().then(c.t.bind(c,14985,23)),{promisify:d}=await Promise.resolve().then(c.t.bind(c,28354,23)),f=new b.Resolver;f.setServers(k);let g=d(f.resolve4.bind(f)),i=await g(a);return h.set(a,{ip:i[0],expiry:Date.now()+e.v1.dnsCacheTtlMs}),i[0]}catch(b){return console.warn(`[ProxyFetch] DNS resolve failed for ${a}:`,b.message),null}}function n(a,b){let c,d=l(b);if(!d)return!1;try{c=new URL(a).hostname.toLowerCase()}catch{return!1}return d.split(",").map(a=>a.trim().toLowerCase()).filter(Boolean).some(a=>"*"===a||(a.startsWith(".")?c.endsWith(a)||c===a.slice(1):c===a||c.endsWith(`.${a}`)))}function o(a){let b=l(a);if(!b)return null;try{return new URL(b),b}catch{return`http://${b}`}}async function p(a,b=!1){let d=o(a);if(!d&&!b)return null;let f=`${d||"direct"}::${b?"insecure":"secure"}`;if(!g.has(f)){g.size>=e.v1.proxyDispatchersMaxSize&&g.delete(g.keys().next().value);let{Agent:a,ProxyAgent:h}=await c.e(7774).then(c.t.bind(c,47774,19)),i=b?{rejectUnauthorized:!1}:void 0,j=d?new h({uri:d,...b?{requestTls:i}:{}}):new a({connect:i});g.set(f,j)}return g.get(f)}async function q(a,b,c){try{let d=c?await p(c):void 0;return await f(a,d?{...b,dispatcher:d}:b)}catch(e){let d;if("true"!==process.env.STRICT_SSL&&"1"!==process.env.STRICT_SSL&&(d=e?.cause?.code||e?.code,i.has(d))){if(b.body&&"function"==typeof b.body.getReader&&b.body.locked)throw e;console.warn(`[ProxyFetch] TLS cert verification failed (${e.cause?.code||e.code}), retrying with insecure TLS: ${a}`);let d=await p(c,!0);return await f(a,{...b,dispatcher:d})}throw e}}async function r(a,b,e){let f=await Promise.resolve().then(c.t.bind(c,55591,23)),g=await Promise.resolve().then(c.t.bind(c,91645,23)),h=f.default??f,i=g.default??g;return new Promise((c,f)=>{let g=new i.Socket;if(g.connect(443,b,()=>{let b={socket:g,servername:a.hostname,path:a.pathname+a.search,method:e.method||"POST",headers:{...e.headers,Host:a.hostname}},i=h.request(b,a=>{let b={ok:a.statusCode>=200&&a.statusCode<300,status:a.statusCode,statusText:a.statusMessage,headers:new Map(Object.entries(a.headers)),body:d.Readable.toWeb(a),text:async()=>{let b=[];for await(let c of a)b.push(c);return Buffer.concat(b).toString()},json:async()=>JSON.parse(await b.text())};c(b)});i.on("error",f),e.body&&i.write("string"==typeof e.body?e.body:JSON.stringify(e.body)),i.end()}),g.on("error",f),e.signal){let a=!1,b=()=>{a||(a=!0,g.destroy(),f(new DOMException("The operation was aborted","AbortError")))};e.signal.aborted?b():(e.signal.addEventListener("abort",b,{once:!0}),g.once("close",()=>e.signal.removeEventListener("abort",b)))}})}async function s(a,b={},c=null){let d="string"==typeof a?a:a.toString(),e=l(c?.vercelRelayUrl);if(e){let a=new URL(d),c={...b.headers instanceof Headers?Object.fromEntries(b.headers.entries()):{...b.headers||{}},"x-relay-target":`${a.protocol}//${a.host}`,"x-relay-path":`${a.pathname}${a.search}`};return f(e,{...b,headers:c})}let g=function(a,b){if(b?.enabled!==!0&&b?.connectionProxyEnabled!==!0)return null;let c=l(b?.url??b?.connectionProxyUrl);if(!c)return null;let d=l(b?.noProxy??b?.connectionNoProxy);return d&&n(a,d)?null:o(c)}(d,c),h=g?null:o(function(a){let b;if(n(a,process.env.NO_PROXY||process.env.no_proxy))return null;try{b=new URL(a).protocol}catch{return null}return"https:"===b?process.env.HTTPS_PROXY||process.env.https_proxy||process.env.ALL_PROXY||process.env.all_proxy:process.env.HTTP_PROXY||process.env.http_proxy||process.env.ALL_PROXY||process.env.all_proxy}(d)),i=g||h;if(function(a){try{let b=new URL(a).hostname;return j.some(a=>b.includes(a))}catch{return!1}}(d)){if(i)try{return await q(a,b,i)}catch(a){if(c?.strictProxy===!0)throw Error(`[ProxyFetch] Proxy required but failed (strictProxy=true): ${a.message}`);console.warn(`[ProxyFetch] Proxy failed, falling back to direct bypass: ${a.message}`)}try{let a=new URL(d),c=await m(a.hostname);if(c)return await r(a,c,b)}catch(a){console.warn(`[ProxyFetch] MITM bypass failed: ${a.message}`)}}if(i)try{return await q(a,b,i)}catch(d){if(c?.strictProxy===!0)throw Error(`[ProxyFetch] Proxy required but failed (strictProxy=true): ${d.message}`);return console.warn(`[ProxyFetch] Proxy failed, falling back to direct: ${d.message}`),q(a,b,null)}let k=c?.proxyPoolId||c?.enabled===!0||c?.connectionProxyEnabled===!0||!!l(c?.url??c?.connectionProxyUrl);if(c?.strictProxy===!0&&k)throw Error("[ProxyFetch] Proxy required but none resolved (strictProxy=true)");return q(a,b,null)}async function t(a,b={}){return s(a,b,null)}globalThis.fetch!==t&&(globalThis.fetch=t);let u=t},41004:(a,b,c)=>{c.d(b,{C8:()=>q,DR:()=>p,IK:()=>k,Ps:()=>g,SA:()=>n,Uc:()=>l,Z1:()=>i,ZL:()=>r,cI:()=>o,eo:()=>m,gx:()=>d,jk:()=>s,pH:()=>j,v1:()=>e,xM:()=>h}),c(3662);let d={BAD_REQUEST:400,UNAUTHORIZED:401,PAYMENT_REQUIRED:402,FORBIDDEN:403,NOT_FOUND:404,NOT_ACCEPTABLE:406,REQUEST_TIMEOUT:408,RATE_LIMITED:429,SERVER_ERROR:500,BAD_GATEWAY:502,SERVICE_UNAVAILABLE:503,GATEWAY_TIMEOUT:504},e={sessionTtlMs:72e5,sessionCleanupIntervalMs:18e5,dnsCacheTtlMs:3e5,proxyDispatchersMaxSize:20};function f(a,b){let c=process.env[a];if(null==c||""===c)return b;let d=parseInt(c,10);return Number.isFinite(d)&&d>0?d:b}let g=process.env.SEARXNG_URL?.trim()||"http://localhost:8888/search",h=f("STREAM_STALL_TIMEOUT_MS",36e4),i=f("STREAM_FIRST_CHUNK_TIMEOUT_MS",2e5),j=f("FETCH_CONNECT_TIMEOUT_MS",6e4),k=f("GEMINI_NATIVE_TTS_FETCH_TIMEOUT_MS",45e3),l=64e3,m=32e3,n="x-omnihilbras-token-saver",o={429:{attempts:0,delayMs:0},502:{attempts:3,delayMs:3e3},503:{attempts:3,delayMs:2e3},504:{attempts:2,delayMs:3e3}};function p(a){return null==a?{attempts:0,delayMs:2e3}:"number"==typeof a?{attempts:a,delayMs:2e3}:{attempts:a.attempts||0,delayMs:null!=a.delayMs?a.delayMs:2e3}}let q=["Please write a 5-10 word title for the following conversation:"],r={candidates:[{flavor:"openai-billing",path:"/dashboard/billing/subscription"},{flavor:"openai-billing",path:"/dashboard/billing/usage"},{flavor:"new-api",path:"/api/user/self"}],usageWindowDays:30,unsupportedTtlMs:f("AGGREGATOR_UNSUPPORTED_TTL_MS",6e5),newApiQuotaPerUnit:5e5,fetchTimeoutMs:1e4},s={supabaseUrl:process.env.AGGREGATOR_WALLET_SUPABASE_URL||"https://isbnzmwjmtiuipesgmmg.supabase.co",anonKey:process.env.AGGREGATOR_WALLET_ANON_KEY||"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6ImlzYm56bXdqbXRpdWlwZXNnbW1nIiwicm9sZSI6ImFub24iLCJpYXQiOjE3NzY3NjU1MzYsImV4cCI6MjA5MjM0MTUzNn0.CodUcchio6jNW_k68vaAb--LshBQXK51tZ6VTxNSz_A",authBaseUrl:process.env.AGGREGATOR_WALLET_AUTH_BASE_URL||"https://auth.tokenharbor.ai/auth/v1",walletTable:"wallets",walletColumns:["balance_paid","balance_trial","balance_bonus","balance_bonus_locked"],lockedColumn:"balance_bonus_locked"}},54051:(a,b,c)=>{c.r(b),c.d(b,{BROWSER_LOCALE:()=>h,BROWSER_TIMEZONE:()=>i,CHROME_USER_AGENT:()=>g,MISSING_BROWSER_MESSAGE:()=>q,browserFingerprintHeaders:()=>l,cookieHeaderFrom:()=>k,isMissingBrowser:()=>m,loadPlaywright:()=>o,parseCookieHeader:()=>j,profileDir:()=>p,readBodyRefusal:()=>r});var d=c(77598),e=c(48161),f=c(76760);let g="Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/151.0.7922.34 Safari/537.36",h="en-US",i="America/New_York";function j(a){let b=String(a||"").trim();if(!b)throw Error("Paste the Cookie header from your browser.");if(/^(GET|POST|PUT|HEAD|OPTIONS|DELETE|PATCH)\s+\//i.test(b))throw Error("That is a request line, not a cookie. Copy the value of the Cookie header only.");let c={};for(let a of b.split(";")){let b=a.indexOf("=");if(b<=0)continue;let d=a.slice(0,b).trim(),e=a.slice(b+1).trim();d&&e&&(c[d]=e)}if(0===Object.keys(c).length)throw Error("That does not look like a cookie header — it has no name=value pairs in it.");return c}function k(a){return Object.entries(a||{}).map(([a,b])=>`${a}=${b}`).join("; ")}function l({origin:a,referer:b,accept:c="application/json",extra:d={}}={}){let e={accept:c,"accept-language":"en-US,en;q=0.9","user-agent":g,"sec-ch-ua":'"Chromium";v="151", "Not(A:Brand";v="8"',"sec-ch-ua-mobile":"?0","sec-ch-ua-platform":'"Linux"',"sec-fetch-dest":"empty","sec-fetch-mode":"cors","sec-fetch-site":"same-origin",...d};return a&&(e.origin=a),b&&(e.referer=b),e}function m(a){let b=String(a||"").toLowerCase();return b.includes("executable doesn't exist")||b.includes("executablenotfound")||b.includes("playwright install")||b.includes("chromium")&&b.includes("download")}let n=null;async function o(){return n??=(async()=>{try{return await Promise.resolve().then(c.bind(c,26915))}catch{return}})()}function p(a,b){let c=process.env.XDG_CONFIG_HOME||(0,f.join)((0,e.homedir)(),".config"),g=(0,d.createHash)("sha256").update(String(b||"default")).digest("hex").slice(0,32);return(0,f.join)(c,"omnihilbras",a,g)}let q="This provider needs a browser. Install Chromium with `npx playwright install chromium`, then try again — everything else about the connection is fine.";function r(a){if(!a||"object"!=typeof a)return;if(!1!==a.success){let b=Array.isArray(a.ret)?a.ret:null;return b&&b.length>0?`refused: ${b.join(", ")}`:void 0}let b=a.data?.code??a.code,c=a.data?.details??a.details;return["string"==typeof b?b:void 0,"string"==typeof c?c:void 0].filter(Boolean).join(" — ")||"refused"}},67068:(a,b,c)=>{c.r(b),c.d(b,{checkWebSession:()=>u,connectWebSession:()=>v,parseTokenHarborCookie:()=>m,refusalFor:()=>r,sessionExpiresAt:()=>q,sessionValueProblem:()=>p});var d=c(39609),e=c(67528),f=c(54051);let g=e.A.transport||{},h=e.A.models||[],i="sb-auth-auth-token",j="base64-",k="Paste the Cookie header or the sb-auth-auth-token value from tokenharbor.ai.",l=`The "${i}" cookie is empty, which is what the browser stores when you are signed out. Sign in at tokenharbor.ai and copy it again.`;function m(a){var b;let c=String(a||"").trim();if(!c)throw Error(k);let d=(b=c).startsWith(j)?b:b===i?"":null;if(null!==d){if(!d)throw Error(l);let a=p(d);if(a)throw Error(a);return`${i}=${d}`}if(RegExp(`(?:^|;\\s*)${i}=\\s*(?:;|$)`).test(c))throw Error(l);let e=(0,f.parseCookieHeader)((function(a){if(!/[\r\n]/.test(a))return a;let b=a.split(/\r?\n/).map(a=>a.trim()).filter(Boolean);return b.find(a=>/^cookie\s*:/i.test(a))||b[0]||a})(c).replace(/^\s*cookie\s*:\s*/i,"")),g=Object.keys(e),h=g.filter(a=>a===i||a.startsWith(`${i}.`)).sort((a,b)=>n(a)-n(b));if(0===h.length)throw Error(`That Cookie header carries no "${i}" cookie. Sign in at tokenharbor.ai and copy it again.`);let m=h.map(a=>e[a]??"").join("");if(!m)throw Error(l);let o=p(m);if(o)throw Error(o);let q={};for(let a of g)a===i||a.startsWith(`${i}.`)||(q[a]=e[a]);let r=(0,f.cookieHeaderFrom)(q),s=`${i}=${m}`;return r?`${r}; ${s}`:s}function n(a){if(a===i)return 0;let b=Number(a.slice(i.length+1));return Number.isFinite(b)?b+1:Number.MAX_SAFE_INTEGER}function o(a){try{let b=a.replace(/-/g,"+").replace(/_/g,"/"),c=b+"=".repeat((4-b.length%4)%4),d=atob(c),e=Uint8Array.from(d,a=>a.charCodeAt(0));return new TextDecoder().decode(e)}catch{return}}function p(a){let b;if(!a.startsWith(j))return 3===a.split(".").length?void 0:`That session value is not in the shape tokenharbor.ai stores it in — it should start with "${j}". Copy the whole value of the cookie, or the whole Cookie header.`;let c=o(a.slice(j.length));if(void 0===c)return"That session cookie is not valid base64, which almost always means the paste was cut short. Select the entire cookie value — it is long, and a partially copied one is refused here rather than sent and reported as a dead session.";try{b=JSON.parse(c)}catch{return"That session cookie was cut short: it decodes to something that is not complete JSON. Copy the whole cookie value (or the whole Cookie header) and paste it again — the session itself is probably fine."}if(!b||"object"!=typeof b||"string"!=typeof b.access_token)return`That cookie decodes, but it carries no access token, so this adapter does not recognise it as a Token Harbor session. Confirm you copied the cookie named "${i}".`}function q(a){let b=function(a){let b=String(a||"").trim();if(b.startsWith(j))return b;let c=b.match(RegExp(`(?:^|;\\s*)${i}=([^;]+)`));return c?.[1]?.trim()??void 0}(a);if(void 0===b)return;let c=o(b.slice(j.length));if(void 0!==c)try{let a=JSON.parse(c);return"number"==typeof a.expires_at?a.expires_at:void 0}catch{return}}function r(a,b,c){if(401===a||403===a){let d=c?q(c):void 0,e=void 0!==d&&1e3*d<=Date.now()?`The pasted session expired at ${new Date(1e3*d).toISOString()}. Sign in at tokenharbor.ai and copy a fresh cookie.`:"Sign in at tokenharbor.ai again and paste a fresh cookie. A 403 can also be Cloudflare refusing the request rather than the session being dead.";return`Token Harbor refused this session while ${b} (${a}). ${e}`}return 429===a?`Token Harbor is rate limiting this session (${a}) while ${b}.`:402===a?`Token Harbor refused ${b}: the account has no balance for this model (402). The ":free" models do not bill.`:`Token Harbor answered ${a} while ${b}.`}async function s(a){let b,c=g.profileUrl;if(!c)return{ok:!1,detail:"Token Harbor Web is not configured in this build."};try{let e;b=await (0,d.proxyAwareFetch)(c,{method:"GET",headers:(e=g.origin,{...(0,f.browserFingerprintHeaders)({origin:e,referer:e?`${e}/chat`:void 0,accept:"application/json"}),Cookie:a})})}catch(a){return{ok:!1,detail:`Token Harbor could not be reached: ${a?.message||String(a)}`}}let e=await b.json().catch(()=>void 0),h=(0,f.readBodyRefusal)(e)||(e?.ok===!1?"the service answered ok:false":void 0);return b.ok?h?{ok:!1,detail:`Token Harbor did not accept the session (${h}). Sign in at tokenharbor.ai again and paste a fresh cookie.`}:{ok:!0,detail:"Token Harbor accepted the session cookie.",email:"string"==typeof e?.email?e.email:void 0}:{ok:!1,detail:r(b.status,"checking the session",a)}}function t(){return h.map(a=>a.id).filter(Boolean)}async function u(a){let b;try{b=m(a)}catch(a){return{ok:!1,detail:a?.message||k}}let c=await s(b);return c.ok?{ok:!0,detail:c.detail,models:t()}:{ok:!1,detail:c.detail}}async function v(a){let b;try{b=m(a)}catch(b){let a=b?.message||k;return{ok:!1,error:a,detail:a}}let c=await s(b);return c.ok?{ok:!0,credential:b,models:t(),name:"Token Harbor Web",email:c.email}:{ok:!1,error:c.detail,detail:c.detail}}},67528:(a,b,c)=>{c.d(b,{A:()=>d});let d={id:"tokenharbor-web",priority:220,alias:"tokenharbor-web",aliases:["thw"],uiAlias:"thw",display:{name:"Token Harbor Web",icon:"anchor",color:"#3859ff",textIcon:"TH",website:"https://tokenharbor.ai/chat",notice:{text:'Reached with a signed-in browser session, not an API key. Token Harbor\'s terms prohibit proxying their gateway, and their metered API (tokenharbor.ai/v1) is the supported route — the ":free" models do not bill. Use at your own risk.',apiKeyUrl:"https://tokenharbor.ai/dashboard"}},category:"webCookieSession",authType:"cookie",authHint:"Paste the Cookie header (or the sb-auth-auth-token value) from tokenharbor.ai",transport:{baseUrl:"https://tokenharbor.ai/api/direct-chat/stream",format:"tokenharbor-web",authType:"cookie",origin:"https://tokenharbor.ai",profileUrl:"https://tokenharbor.ai/api/me/profile",sessionsUrl:"https://tokenharbor.ai/api/direct-chat/sessions",streamUrl:"https://tokenharbor.ai/api/direct-chat/stream"},models:[{id:"th-rudder:free",name:"TH-Rudder (Free)"},{id:"claude-fable-5.1",name:"Claude Fable 5.1"},{id:"claude-opus-5.5",name:"Claude Opus 5.5"},{id:"claude-sonnet-5.5",name:"Claude Sonnet 5.5"},{id:"deepseek-v4.1-flash",name:"DeepSeek V4.1 Flash"},{id:"deepseek-v4.1-flash:free",name:"DeepSeek V4.1 Flash (Free)"},{id:"gemini-3.8-flash",name:"Gemini 3.8 Flash"},{id:"glm-5.3",name:"GLM-5.3"},{id:"glm-5.3-flash",name:"GLM 5.3 Flash"},{id:"gpt-6-astra",name:"GPT-6 Astra"},{id:"gpt-6-luna",name:"GPT-6 Luna"},{id:"gpt-6.1-sol",name:"GPT-6.1 Sol"},{id:"grok-4.7",name:"Grok 4.7"},{id:"kimi-k3",name:"Kimi K3"},{id:"mimo-v2.6-flash",name:"MiMo V2.6 Flash"},{id:"mimo-v2.6-flash:free",name:"MiMo V2.6 Flash (Free)"},{id:"mimo-v2.6-pro",name:"MiMo V2.6 Pro"},{id:"mistral-large-2512",name:"Mistral Large 2512"},{id:"muse-spark-1-3",name:"Muse Spark 1.3"},{id:"qwen3.8-27b",name:"Qwen3.8 27B"},{id:"qwen3.8-flash",name:"Qwen3.8 Flash"},{id:"qwen3.8-max",name:"Qwen3.8 Max"}]}}};
1
+ "use strict";exports.id=7068,exports.ids=[1004,4051,6432,7068,9289,9609],exports.modules={3662:(a,b,c)=>{c.d(b,{EQ:()=>f,LY:()=>d,O:()=>e,fh:()=>h,t2:()=>i,wf:()=>g});let d={400:{type:"invalid_request_error",code:"bad_request"},401:{type:"authentication_error",code:"invalid_api_key"},402:{type:"billing_error",code:"payment_required"},403:{type:"permission_error",code:"insufficient_quota"},404:{type:"invalid_request_error",code:"model_not_found"},406:{type:"invalid_request_error",code:"model_not_supported"},429:{type:"rate_limit_error",code:"rate_limit_exceeded"},500:{type:"server_error",code:"internal_server_error"},502:{type:"server_error",code:"bad_gateway"},503:{type:"server_error",code:"service_unavailable"},504:{type:"server_error",code:"gateway_timeout"}},e={400:"Bad request",401:"Invalid API key provided",402:"Payment required",403:"You exceeded your current quota",404:"Model not found",406:"Model not supported",429:"Rate limit exceeded",500:"Internal server error",502:"Bad gateway - upstream provider error",503:"Service temporarily unavailable",504:"Gateway timeout"},f={base:2e3,max:3e5,maxLevel:15},g=3e4,h=18e5,i=[{provider:"codex",text:"model is not supported when using codex with a chatgpt account",cooldownMs:18e5},{text:"no credentials",cooldownMs:12e4},{text:"request not allowed",cooldownMs:5e3},{text:"improperly formed request",cooldownMs:12e4},{text:"rate limit",backoff:!0},{text:"too many requests",backoff:!0},{text:"quota exceeded",backoff:!0},{text:"capacity",backoff:!0},{text:"overloaded",backoff:!0},{status:401,cooldownMs:12e4},{status:402,cooldownMs:12e4},{status:403,cooldownMs:12e4},{status:404,cooldownMs:12e4},{status:429,backoff:!0}]},39609:(a,b,c)=>{c.r(b),c.d(b,{default:()=>u,proxyAwareFetch:()=>s});var d=c(27910),e=c(41004);let f=globalThis.fetch,g=new Map,h=new Map,i=new Set(["SELF_SIGNED_CERT_IN_CHAIN","DEPTH_ZERO_SELF_SIGNED_CERT","UNABLE_TO_VERIFY_LEAF_SIGNATURE","UNABLE_TO_GET_ISSUER_CERT","UNABLE_TO_GET_ISSUER_CERT_LOCALLY","CERT_HAS_EXPIRED","ERR_TLS_CERT_ALTNAME_INVALID"]),j=["cloudcode-pa.googleapis.com","daily-cloudcode-pa.googleapis.com","api.individual.githubcopilot.com","q.us-east-1.amazonaws.com","codewhisperer.us-east-1.amazonaws.com","api2.cursor.sh"],k=["8.8.8.8","8.8.4.4"];function l(a){return null==a?"":String(a).trim()}async function m(a){let b=h.get(a);if(b&&Date.now()<b.expiry)return b.ip;try{let b=await Promise.resolve().then(c.t.bind(c,14985,23)),{promisify:d}=await Promise.resolve().then(c.t.bind(c,28354,23)),f=new b.Resolver;f.setServers(k);let g=d(f.resolve4.bind(f)),i=await g(a);return h.set(a,{ip:i[0],expiry:Date.now()+e.v1.dnsCacheTtlMs}),i[0]}catch(b){return console.warn(`[ProxyFetch] DNS resolve failed for ${a}:`,b.message),null}}function n(a,b){let c,d=l(b);if(!d)return!1;try{c=new URL(a).hostname.toLowerCase()}catch{return!1}return d.split(",").map(a=>a.trim().toLowerCase()).filter(Boolean).some(a=>"*"===a||(a.startsWith(".")?c.endsWith(a)||c===a.slice(1):c===a||c.endsWith(`.${a}`)))}function o(a){let b=l(a);if(!b)return null;try{return new URL(b),b}catch{return`http://${b}`}}async function p(a,b=!1){let d=o(a);if(!d&&!b)return null;let f=`${d||"direct"}::${b?"insecure":"secure"}`;if(!g.has(f)){g.size>=e.v1.proxyDispatchersMaxSize&&g.delete(g.keys().next().value);let{Agent:a,ProxyAgent:h}=await c.e(7774).then(c.t.bind(c,47774,19)),i=b?{rejectUnauthorized:!1}:void 0,j=d?new h({uri:d,...b?{requestTls:i}:{}}):new a({connect:i});g.set(f,j)}return g.get(f)}async function q(a,b,c){try{let d=c?await p(c):void 0;return await f(a,d?{...b,dispatcher:d}:b)}catch(e){let d;if("true"!==process.env.STRICT_SSL&&"1"!==process.env.STRICT_SSL&&(d=e?.cause?.code||e?.code,i.has(d))){if(b.body&&"function"==typeof b.body.getReader&&b.body.locked)throw e;console.warn(`[ProxyFetch] TLS cert verification failed (${e.cause?.code||e.code}), retrying with insecure TLS: ${a}`);let d=await p(c,!0);return await f(a,{...b,dispatcher:d})}throw e}}async function r(a,b,e){let f=await Promise.resolve().then(c.t.bind(c,55591,23)),g=await Promise.resolve().then(c.t.bind(c,91645,23)),h=f.default??f,i=g.default??g;return new Promise((c,f)=>{let g=new i.Socket;if(g.connect(443,b,()=>{let b={socket:g,servername:a.hostname,path:a.pathname+a.search,method:e.method||"POST",headers:{...e.headers,Host:a.hostname}},i=h.request(b,a=>{let b={ok:a.statusCode>=200&&a.statusCode<300,status:a.statusCode,statusText:a.statusMessage,headers:new Map(Object.entries(a.headers)),body:d.Readable.toWeb(a),text:async()=>{let b=[];for await(let c of a)b.push(c);return Buffer.concat(b).toString()},json:async()=>JSON.parse(await b.text())};c(b)});i.on("error",f),e.body&&i.write("string"==typeof e.body?e.body:JSON.stringify(e.body)),i.end()}),g.on("error",f),e.signal){let a=!1,b=()=>{a||(a=!0,g.destroy(),f(new DOMException("The operation was aborted","AbortError")))};e.signal.aborted?b():(e.signal.addEventListener("abort",b,{once:!0}),g.once("close",()=>e.signal.removeEventListener("abort",b)))}})}async function s(a,b={},c=null){let d="string"==typeof a?a:a.toString(),e=l(c?.vercelRelayUrl);if(e){let a=new URL(d),c={...b.headers instanceof Headers?Object.fromEntries(b.headers.entries()):{...b.headers||{}},"x-relay-target":`${a.protocol}//${a.host}`,"x-relay-path":`${a.pathname}${a.search}`};return f(e,{...b,headers:c})}let g=function(a,b){if(b?.enabled!==!0&&b?.connectionProxyEnabled!==!0)return null;let c=l(b?.url??b?.connectionProxyUrl);if(!c)return null;let d=l(b?.noProxy??b?.connectionNoProxy);return d&&n(a,d)?null:o(c)}(d,c),h=g?null:o(function(a){let b;if(n(a,process.env.NO_PROXY||process.env.no_proxy))return null;try{b=new URL(a).protocol}catch{return null}return"https:"===b?process.env.HTTPS_PROXY||process.env.https_proxy||process.env.ALL_PROXY||process.env.all_proxy:process.env.HTTP_PROXY||process.env.http_proxy||process.env.ALL_PROXY||process.env.all_proxy}(d)),i=g||h;if(function(a){try{let b=new URL(a).hostname;return j.some(a=>b.includes(a))}catch{return!1}}(d)){if(i)try{return await q(a,b,i)}catch(a){if(c?.strictProxy===!0)throw Error(`[ProxyFetch] Proxy required but failed (strictProxy=true): ${a.message}`);console.warn(`[ProxyFetch] Proxy failed, falling back to direct bypass: ${a.message}`)}try{let a=new URL(d),c=await m(a.hostname);if(c)return await r(a,c,b)}catch(a){console.warn(`[ProxyFetch] MITM bypass failed: ${a.message}`)}}if(i)try{return await q(a,b,i)}catch(d){if(c?.strictProxy===!0)throw Error(`[ProxyFetch] Proxy required but failed (strictProxy=true): ${d.message}`);return console.warn(`[ProxyFetch] Proxy failed, falling back to direct: ${d.message}`),q(a,b,null)}let k=c?.proxyPoolId||c?.enabled===!0||c?.connectionProxyEnabled===!0||!!l(c?.url??c?.connectionProxyUrl);if(c?.strictProxy===!0&&k)throw Error("[ProxyFetch] Proxy required but none resolved (strictProxy=true)");return q(a,b,null)}async function t(a,b={}){return s(a,b,null)}globalThis.fetch!==t&&(globalThis.fetch=t);let u=t},41004:(a,b,c)=>{c.d(b,{C8:()=>s,DR:()=>r,Ey:()=>k,IK:()=>m,Kv:()=>j,Ps:()=>g,SA:()=>p,Uc:()=>n,Z1:()=>i,ZL:()=>t,cI:()=>q,eo:()=>o,gx:()=>d,jk:()=>u,pH:()=>l,v1:()=>e,xM:()=>h}),c(3662);let d={BAD_REQUEST:400,UNAUTHORIZED:401,PAYMENT_REQUIRED:402,FORBIDDEN:403,NOT_FOUND:404,NOT_ACCEPTABLE:406,REQUEST_TIMEOUT:408,RATE_LIMITED:429,SERVER_ERROR:500,BAD_GATEWAY:502,SERVICE_UNAVAILABLE:503,GATEWAY_TIMEOUT:504},e={sessionTtlMs:72e5,sessionCleanupIntervalMs:18e5,dnsCacheTtlMs:3e5,proxyDispatchersMaxSize:20};function f(a,b){let c=process.env[a];if(null==c||""===c)return b;let d=parseInt(c,10);return Number.isFinite(d)&&d>0?d:b}let g=process.env.SEARXNG_URL?.trim()||"http://localhost:8888/search",h=f("STREAM_STALL_TIMEOUT_MS",36e4),i=f("STREAM_FIRST_CHUNK_TIMEOUT_MS",2e5),j=f("UPSTREAM_MAX_BODY_BYTES",0x2000000),k=f("UPSTREAM_TOTAL_TIMEOUT_MS",18e5),l=f("FETCH_CONNECT_TIMEOUT_MS",6e4),m=f("GEMINI_NATIVE_TTS_FETCH_TIMEOUT_MS",45e3),n=64e3,o=32e3,p="x-omnihilbras-token-saver",q={429:{attempts:0,delayMs:0},502:{attempts:3,delayMs:3e3},503:{attempts:3,delayMs:2e3},504:{attempts:2,delayMs:3e3}};function r(a){return null==a?{attempts:0,delayMs:2e3}:"number"==typeof a?{attempts:a,delayMs:2e3}:{attempts:a.attempts||0,delayMs:null!=a.delayMs?a.delayMs:2e3}}let s=["Please write a 5-10 word title for the following conversation:"],t={candidates:[{flavor:"openai-billing",path:"/dashboard/billing/subscription"},{flavor:"openai-billing",path:"/dashboard/billing/usage"},{flavor:"new-api",path:"/api/user/self"}],usageWindowDays:30,unsupportedTtlMs:f("AGGREGATOR_UNSUPPORTED_TTL_MS",6e5),newApiQuotaPerUnit:5e5,fetchTimeoutMs:1e4},u={supabaseUrl:process.env.AGGREGATOR_WALLET_SUPABASE_URL||"https://isbnzmwjmtiuipesgmmg.supabase.co",anonKey:process.env.AGGREGATOR_WALLET_ANON_KEY||"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6ImlzYm56bXdqbXRpdWlwZXNnbW1nIiwicm9sZSI6ImFub24iLCJpYXQiOjE3NzY3NjU1MzYsImV4cCI6MjA5MjM0MTUzNn0.CodUcchio6jNW_k68vaAb--LshBQXK51tZ6VTxNSz_A",authBaseUrl:process.env.AGGREGATOR_WALLET_AUTH_BASE_URL||"https://auth.tokenharbor.ai/auth/v1",walletTable:"wallets",walletColumns:["balance_paid","balance_trial","balance_bonus","balance_bonus_locked"],lockedColumn:"balance_bonus_locked"}},54051:(a,b,c)=>{c.r(b),c.d(b,{BROWSER_LOCALE:()=>h,BROWSER_TIMEZONE:()=>i,CHROME_USER_AGENT:()=>g,MISSING_BROWSER_MESSAGE:()=>q,browserFingerprintHeaders:()=>l,cookieHeaderFrom:()=>k,isMissingBrowser:()=>m,loadPlaywright:()=>o,parseCookieHeader:()=>j,profileDir:()=>p,readBodyRefusal:()=>r});var d=c(77598),e=c(48161),f=c(76760);let g="Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/151.0.7922.34 Safari/537.36",h="en-US",i="America/New_York";function j(a){let b=String(a||"").trim();if(!b)throw Error("Paste the Cookie header from your browser.");if(/^(GET|POST|PUT|HEAD|OPTIONS|DELETE|PATCH)\s+\//i.test(b))throw Error("That is a request line, not a cookie. Copy the value of the Cookie header only.");let c={};for(let a of b.split(";")){let b=a.indexOf("=");if(b<=0)continue;let d=a.slice(0,b).trim(),e=a.slice(b+1).trim();d&&e&&(c[d]=e)}if(0===Object.keys(c).length)throw Error("That does not look like a cookie header — it has no name=value pairs in it.");return c}function k(a){return Object.entries(a||{}).map(([a,b])=>`${a}=${b}`).join("; ")}function l({origin:a,referer:b,accept:c="application/json",extra:d={}}={}){let e={accept:c,"accept-language":"en-US,en;q=0.9","user-agent":g,"sec-ch-ua":'"Chromium";v="151", "Not(A:Brand";v="8"',"sec-ch-ua-mobile":"?0","sec-ch-ua-platform":'"Linux"',"sec-fetch-dest":"empty","sec-fetch-mode":"cors","sec-fetch-site":"same-origin",...d};return a&&(e.origin=a),b&&(e.referer=b),e}function m(a){let b=String(a||"").toLowerCase();return b.includes("executable doesn't exist")||b.includes("executablenotfound")||b.includes("playwright install")||b.includes("chromium")&&b.includes("download")}let n=null;async function o(){return n??=(async()=>{try{return await Promise.resolve().then(c.bind(c,26915))}catch{return}})()}function p(a,b){let c=process.env.XDG_CONFIG_HOME||(0,f.join)((0,e.homedir)(),".config"),g=(0,d.createHash)("sha256").update(String(b||"default")).digest("hex").slice(0,32);return(0,f.join)(c,"omnihilbras",a,g)}let q="This provider needs a browser. Install Chromium with `npx playwright install chromium`, then try again — everything else about the connection is fine.";function r(a){if(!a||"object"!=typeof a)return;if(!1!==a.success){let b=Array.isArray(a.ret)?a.ret:null;return b&&b.length>0?`refused: ${b.join(", ")}`:void 0}let b=a.data?.code??a.code,c=a.data?.details??a.details;return["string"==typeof b?b:void 0,"string"==typeof c?c:void 0].filter(Boolean).join(" — ")||"refused"}},67068:(a,b,c)=>{c.r(b),c.d(b,{checkWebSession:()=>u,connectWebSession:()=>v,parseTokenHarborCookie:()=>m,refusalFor:()=>r,sessionExpiresAt:()=>q,sessionValueProblem:()=>p});var d=c(39609),e=c(67528),f=c(54051);let g=e.A.transport||{},h=e.A.models||[],i="sb-auth-auth-token",j="base64-",k="Paste the Cookie header or the sb-auth-auth-token value from tokenharbor.ai.",l=`The "${i}" cookie is empty, which is what the browser stores when you are signed out. Sign in at tokenharbor.ai and copy it again.`;function m(a){var b;let c=String(a||"").trim();if(!c)throw Error(k);let d=(b=c).startsWith(j)?b:b===i?"":null;if(null!==d){if(!d)throw Error(l);let a=p(d);if(a)throw Error(a);return`${i}=${d}`}if(RegExp(`(?:^|;\\s*)${i}=\\s*(?:;|$)`).test(c))throw Error(l);let e=(0,f.parseCookieHeader)((function(a){if(!/[\r\n]/.test(a))return a;let b=a.split(/\r?\n/).map(a=>a.trim()).filter(Boolean);return b.find(a=>/^cookie\s*:/i.test(a))||b[0]||a})(c).replace(/^\s*cookie\s*:\s*/i,"")),g=Object.keys(e),h=g.filter(a=>a===i||a.startsWith(`${i}.`)).sort((a,b)=>n(a)-n(b));if(0===h.length)throw Error(`That Cookie header carries no "${i}" cookie. Sign in at tokenharbor.ai and copy it again.`);let m=h.map(a=>e[a]??"").join("");if(!m)throw Error(l);let o=p(m);if(o)throw Error(o);let q={};for(let a of g)a===i||a.startsWith(`${i}.`)||(q[a]=e[a]);let r=(0,f.cookieHeaderFrom)(q),s=`${i}=${m}`;return r?`${r}; ${s}`:s}function n(a){if(a===i)return 0;let b=Number(a.slice(i.length+1));return Number.isFinite(b)?b+1:Number.MAX_SAFE_INTEGER}function o(a){try{let b=a.replace(/-/g,"+").replace(/_/g,"/"),c=b+"=".repeat((4-b.length%4)%4),d=atob(c),e=Uint8Array.from(d,a=>a.charCodeAt(0));return new TextDecoder().decode(e)}catch{return}}function p(a){let b;if(!a.startsWith(j))return 3===a.split(".").length?void 0:`That session value is not in the shape tokenharbor.ai stores it in — it should start with "${j}". Copy the whole value of the cookie, or the whole Cookie header.`;let c=o(a.slice(j.length));if(void 0===c)return"That session cookie is not valid base64, which almost always means the paste was cut short. Select the entire cookie value — it is long, and a partially copied one is refused here rather than sent and reported as a dead session.";try{b=JSON.parse(c)}catch{return"That session cookie was cut short: it decodes to something that is not complete JSON. Copy the whole cookie value (or the whole Cookie header) and paste it again — the session itself is probably fine."}if(!b||"object"!=typeof b||"string"!=typeof b.access_token)return`That cookie decodes, but it carries no access token, so this adapter does not recognise it as a Token Harbor session. Confirm you copied the cookie named "${i}".`}function q(a){let b=function(a){let b=String(a||"").trim();if(b.startsWith(j))return b;let c=b.match(RegExp(`(?:^|;\\s*)${i}=([^;]+)`));return c?.[1]?.trim()??void 0}(a);if(void 0===b)return;let c=o(b.slice(j.length));if(void 0!==c)try{let a=JSON.parse(c);return"number"==typeof a.expires_at?a.expires_at:void 0}catch{return}}function r(a,b,c){if(401===a||403===a){let d=c?q(c):void 0,e=void 0!==d&&1e3*d<=Date.now()?`The pasted session expired at ${new Date(1e3*d).toISOString()}. Sign in at tokenharbor.ai and copy a fresh cookie.`:"Sign in at tokenharbor.ai again and paste a fresh cookie. A 403 can also be Cloudflare refusing the request rather than the session being dead.";return`Token Harbor refused this session while ${b} (${a}). ${e}`}return 429===a?`Token Harbor is rate limiting this session (${a}) while ${b}.`:402===a?`Token Harbor refused ${b}: the account has no balance for this model (402). The ":free" models do not bill.`:`Token Harbor answered ${a} while ${b}.`}async function s(a){let b,c=g.profileUrl;if(!c)return{ok:!1,detail:"Token Harbor Web is not configured in this build."};try{let e;b=await (0,d.proxyAwareFetch)(c,{method:"GET",headers:(e=g.origin,{...(0,f.browserFingerprintHeaders)({origin:e,referer:e?`${e}/chat`:void 0,accept:"application/json"}),Cookie:a})})}catch(a){return{ok:!1,detail:`Token Harbor could not be reached: ${a?.message||String(a)}`}}let e=await b.json().catch(()=>void 0),h=(0,f.readBodyRefusal)(e)||(e?.ok===!1?"the service answered ok:false":void 0);return b.ok?h?{ok:!1,detail:`Token Harbor did not accept the session (${h}). Sign in at tokenharbor.ai again and paste a fresh cookie.`}:{ok:!0,detail:"Token Harbor accepted the session cookie.",email:"string"==typeof e?.email?e.email:void 0}:{ok:!1,detail:r(b.status,"checking the session",a)}}function t(){return h.map(a=>a.id).filter(Boolean)}async function u(a){let b;try{b=m(a)}catch(a){return{ok:!1,detail:a?.message||k}}let c=await s(b);return c.ok?{ok:!0,detail:c.detail,models:t()}:{ok:!1,detail:c.detail}}async function v(a){let b;try{b=m(a)}catch(b){let a=b?.message||k;return{ok:!1,error:a,detail:a}}let c=await s(b);return c.ok?{ok:!0,credential:b,models:t(),name:"Token Harbor Web",email:c.email}:{ok:!1,error:c.detail,detail:c.detail}}},67528:(a,b,c)=>{c.d(b,{A:()=>d});let d={id:"tokenharbor-web",priority:220,alias:"tokenharbor-web",aliases:["thw"],uiAlias:"thw",display:{name:"Token Harbor Web",icon:"anchor",color:"#3859ff",textIcon:"TH",website:"https://tokenharbor.ai/chat",notice:{text:'Reached with a signed-in browser session, not an API key. Token Harbor\'s terms prohibit proxying their gateway, and their metered API (tokenharbor.ai/v1) is the supported route — the ":free" models do not bill. Use at your own risk.',apiKeyUrl:"https://tokenharbor.ai/dashboard"}},category:"webCookieSession",authType:"cookie",authHint:"Paste the Cookie header (or the sb-auth-auth-token value) from tokenharbor.ai",transport:{baseUrl:"https://tokenharbor.ai/api/direct-chat/stream",format:"tokenharbor-web",authType:"cookie",origin:"https://tokenharbor.ai",profileUrl:"https://tokenharbor.ai/api/me/profile",sessionsUrl:"https://tokenharbor.ai/api/direct-chat/sessions",streamUrl:"https://tokenharbor.ai/api/direct-chat/stream"},models:[{id:"th-rudder:free",name:"TH-Rudder (Free)"},{id:"claude-fable-5.1",name:"Claude Fable 5.1"},{id:"claude-opus-5.5",name:"Claude Opus 5.5"},{id:"claude-sonnet-5.5",name:"Claude Sonnet 5.5"},{id:"deepseek-v4.1-flash",name:"DeepSeek V4.1 Flash"},{id:"deepseek-v4.1-flash:free",name:"DeepSeek V4.1 Flash (Free)"},{id:"gemini-3.8-flash",name:"Gemini 3.8 Flash"},{id:"glm-5.3",name:"GLM-5.3"},{id:"glm-5.3-flash",name:"GLM 5.3 Flash"},{id:"gpt-6-astra",name:"GPT-6 Astra"},{id:"gpt-6-luna",name:"GPT-6 Luna"},{id:"gpt-6.1-sol",name:"GPT-6.1 Sol"},{id:"grok-4.7",name:"Grok 4.7"},{id:"kimi-k3",name:"Kimi K3"},{id:"mimo-v2.6-flash",name:"MiMo V2.6 Flash"},{id:"mimo-v2.6-flash:free",name:"MiMo V2.6 Flash (Free)"},{id:"mimo-v2.6-pro",name:"MiMo V2.6 Pro"},{id:"mistral-large-2512",name:"Mistral Large 2512"},{id:"muse-spark-1-3",name:"Muse Spark 1.3"},{id:"qwen3.8-27b",name:"Qwen3.8 27B"},{id:"qwen3.8-flash",name:"Qwen3.8 Flash"},{id:"qwen3.8-max",name:"Qwen3.8 Max"}]}}};
@@ -0,0 +1 @@
1
+ "use strict";exports.id=7073,exports.ids=[1004,7073],exports.modules={3662:(a,b,c)=>{c.d(b,{EQ:()=>f,LY:()=>d,O:()=>e,fh:()=>h,t2:()=>i,wf:()=>g});let d={400:{type:"invalid_request_error",code:"bad_request"},401:{type:"authentication_error",code:"invalid_api_key"},402:{type:"billing_error",code:"payment_required"},403:{type:"permission_error",code:"insufficient_quota"},404:{type:"invalid_request_error",code:"model_not_found"},406:{type:"invalid_request_error",code:"model_not_supported"},429:{type:"rate_limit_error",code:"rate_limit_exceeded"},500:{type:"server_error",code:"internal_server_error"},502:{type:"server_error",code:"bad_gateway"},503:{type:"server_error",code:"service_unavailable"},504:{type:"server_error",code:"gateway_timeout"}},e={400:"Bad request",401:"Invalid API key provided",402:"Payment required",403:"You exceeded your current quota",404:"Model not found",406:"Model not supported",429:"Rate limit exceeded",500:"Internal server error",502:"Bad gateway - upstream provider error",503:"Service temporarily unavailable",504:"Gateway timeout"},f={base:2e3,max:3e5,maxLevel:15},g=3e4,h=18e5,i=[{provider:"codex",text:"model is not supported when using codex with a chatgpt account",cooldownMs:18e5},{text:"no credentials",cooldownMs:12e4},{text:"request not allowed",cooldownMs:5e3},{text:"improperly formed request",cooldownMs:12e4},{text:"rate limit",backoff:!0},{text:"too many requests",backoff:!0},{text:"quota exceeded",backoff:!0},{text:"capacity",backoff:!0},{text:"overloaded",backoff:!0},{status:401,cooldownMs:12e4},{status:402,cooldownMs:12e4},{status:403,cooldownMs:12e4},{status:404,cooldownMs:12e4},{status:429,backoff:!0}]},38775:(a,b,c)=>{c.d(b,{d_:()=>l,mA:()=>j});var d=c(89718),e=c(40669),f=c(3260),g=c(83817);let h={xmtp:"xiaomi-tokenplan","xiaomi-tokenplan":"xiaomi-tokenplan"},i=new Set(Object.keys(h));for(let a of g.default)for(let b of(i.add(a.id),a.alias&&i.add(a.alias),a.aliases||[]))i.add(b);async function j(a){let b=`model:${a}`,c=(0,f.OS)(b);return c?{...c}:{...await (0,f.ng)(b,await k(a))}}async function k(a){let b,c=(b=(0,e.Xh)(a),b?.providerAlias&&h[b.providerAlias]?{...b,provider:h[b.providerAlias]}:b);if(!c.isAlias){if(!i.has(c.providerAlias)){let a=await (0,d.zw)(c.providerAlias);if(a)return{provider:a.id,model:c.model}}return{provider:c.provider,model:c.model}}return await (0,d.Dj)(c.model)?{provider:null,model:c.model}:(0,e.js)(a,d.OM)}async function l(a){if(a.includes("/"))return null;let b=`combo:${a}`,c=(0,f.OS)(b);if(void 0!==c)return c?[...c]:c;let e=await (0,d.Dj)(a),g=e&&e.models&&e.models.length>0?e.models:null;return(0,f.ng)(b,g),g?[...g]:null}},41004:(a,b,c)=>{c.d(b,{C8:()=>s,DR:()=>r,Ey:()=>k,IK:()=>m,Kv:()=>j,Ps:()=>g,SA:()=>p,Uc:()=>n,Z1:()=>i,ZL:()=>t,cI:()=>q,eo:()=>o,gx:()=>d,jk:()=>u,pH:()=>l,v1:()=>e,xM:()=>h}),c(3662);let d={BAD_REQUEST:400,UNAUTHORIZED:401,PAYMENT_REQUIRED:402,FORBIDDEN:403,NOT_FOUND:404,NOT_ACCEPTABLE:406,REQUEST_TIMEOUT:408,RATE_LIMITED:429,SERVER_ERROR:500,BAD_GATEWAY:502,SERVICE_UNAVAILABLE:503,GATEWAY_TIMEOUT:504},e={sessionTtlMs:72e5,sessionCleanupIntervalMs:18e5,dnsCacheTtlMs:3e5,proxyDispatchersMaxSize:20};function f(a,b){let c=process.env[a];if(null==c||""===c)return b;let d=parseInt(c,10);return Number.isFinite(d)&&d>0?d:b}let g=process.env.SEARXNG_URL?.trim()||"http://localhost:8888/search",h=f("STREAM_STALL_TIMEOUT_MS",36e4),i=f("STREAM_FIRST_CHUNK_TIMEOUT_MS",2e5),j=f("UPSTREAM_MAX_BODY_BYTES",0x2000000),k=f("UPSTREAM_TOTAL_TIMEOUT_MS",18e5),l=f("FETCH_CONNECT_TIMEOUT_MS",6e4),m=f("GEMINI_NATIVE_TTS_FETCH_TIMEOUT_MS",45e3),n=64e3,o=32e3,p="x-omnihilbras-token-saver",q={429:{attempts:0,delayMs:0},502:{attempts:3,delayMs:3e3},503:{attempts:3,delayMs:2e3},504:{attempts:2,delayMs:3e3}};function r(a){return null==a?{attempts:0,delayMs:2e3}:"number"==typeof a?{attempts:a,delayMs:2e3}:{attempts:a.attempts||0,delayMs:null!=a.delayMs?a.delayMs:2e3}}let s=["Please write a 5-10 word title for the following conversation:"],t={candidates:[{flavor:"openai-billing",path:"/dashboard/billing/subscription"},{flavor:"openai-billing",path:"/dashboard/billing/usage"},{flavor:"new-api",path:"/api/user/self"}],usageWindowDays:30,unsupportedTtlMs:f("AGGREGATOR_UNSUPPORTED_TTL_MS",6e5),newApiQuotaPerUnit:5e5,fetchTimeoutMs:1e4},u={supabaseUrl:process.env.AGGREGATOR_WALLET_SUPABASE_URL||"https://isbnzmwjmtiuipesgmmg.supabase.co",anonKey:process.env.AGGREGATOR_WALLET_ANON_KEY||"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6ImlzYm56bXdqbXRpdWlwZXNnbW1nIiwicm9sZSI6ImFub24iLCJpYXQiOjE3NzY3NjU1MzYsImV4cCI6MjA5MjM0MTUzNn0.CodUcchio6jNW_k68vaAb--LshBQXK51tZ6VTxNSz_A",authBaseUrl:process.env.AGGREGATOR_WALLET_AUTH_BASE_URL||"https://auth.tokenharbor.ai/auth/v1",walletTable:"wallets",walletColumns:["balance_paid","balance_trial","balance_bonus","balance_bonus_locked"],lockedColumn:"balance_bonus_locked"}},43659:(a,b,c)=>{c.d(b,{A1:()=>i,lR:()=>k,wO:()=>j,xJ:()=>f,yj:()=>g,zL:()=>h});var d=c(54742),e=c(3662);function f(a,b){let c=e.LY[a]||(a>=500?{type:"server_error",code:"internal_server_error"}:{type:"invalid_request_error",code:""});return{error:{message:b||e.O[a]||"An error occurred",type:c.type,code:c.code}}}function g(a,b,c=null){return new Response(JSON.stringify(f(a,b)),{status:a,headers:{"Content-Type":"application/json","Access-Control-Allow-Origin":"*",...c}})}async function h(a,b=null){let c="";try{c=await (0,d.B)(a,262144)}catch{c=""}if(b&&"function"==typeof b.parseError)try{let d=b.parseError(a,c);if(d&&"object"==typeof d){let b=d.message||e.O[a.status]||`Upstream error: ${a.status}`;return{statusCode:d.status||a.status,message:b,resetsAtMs:d.resetsAtMs}}}catch{}let f="";try{let a=JSON.parse(c);f=a.error?.message||a.message||a.error||c}catch{f=c}let g=("string"==typeof f?f:JSON.stringify(f))||e.O[a.status]||`Upstream error: ${a.status}`;return{statusCode:a.status,message:g}}function i(a,b,c,d=null){return{success:!1,status:a,error:b,resetsAtMs:c,response:g(a,b,d)}}function j(a,b,c,d,e=null){let f=Math.max(Math.ceil((new Date(c).getTime()-Date.now())/1e3),1);return new Response(JSON.stringify({error:{message:`${b} (${d})`}}),{status:a,headers:{...e,"Content-Type":"application/json","retry-after":String(f)}})}function k(a,b,c,d){let e=d||a.code||"FETCH_FAILED",f=a.message||"Unknown error",g=a.cause?.code,h=a.cause?.message,i=g||h?` (cause: ${[g,h].filter(Boolean).join(": ")})`:"";return`[${e}]: ${f}${i}`}},54742:(a,b,c)=>{c.d(b,{B:()=>e,_:()=>f});var d=c(41004);async function e(a,b=d.Kv){let c=a?.body?.getReader?.();if(!c){let c=await a.text();if(c.length>b)throw Error(`upstream response exceeded ${b} bytes`);return c}let f=[],g=0;try{for(;;){let{done:a,value:d}=await c.read();if(a)break;if(d){if((g+=d.byteLength??d.length??0)>b)throw Error(`upstream response exceeded ${b} bytes`);f.push(d)}}}finally{await c.cancel("bounded upstream body").catch(()=>{})}let h=new TextDecoder;if(1===f.length)return h.decode(f[0]);let i="";for(let a of f)i+=h.decode(a,{stream:!0});return i+h.decode()}async function f(a,b=d.Kv){let c=await e(a,b);try{return JSON.parse(c)}catch(a){throw Error(`upstream response is not valid JSON: ${a.message}`)}}},89718:(a,b,c)=>{c.d(b,{CG:()=>d.CG,Dj:()=>d.Dj,Fh:()=>d.Fh,Iq:()=>d.Iq,K1:()=>d.K1,KJ:()=>d.KJ,L:()=>d.L,L9:()=>d.L9,Lh:()=>d.Lh,OM:()=>d.OM,PX:()=>d.PX,Pc:()=>d.Pc,Q_:()=>d.Q_,Qu:()=>d.Qu,S8:()=>d.S8,Uv:()=>d.Uv,VT:()=>d.VT,XW:()=>d.XW,Xx:()=>d.Xx,Yd:()=>d.Yd,ZO:()=>d.ZO,bI:()=>d.bI,c:()=>d.c,ek:()=>d.ek,fK:()=>d.fK,fv:()=>d.fv,getProviderConnectionById:()=>d.Mc,getProviderConnections:()=>d.P,ho:()=>d.ho,hr:()=>d.hr,i0:()=>d.i0,iE:()=>d.iE,jd:()=>d.jd,mt:()=>d.mt,o5:()=>d.o5,oG:()=>d.oG,op:()=>d.op,r4:()=>d.r4,uL:()=>d.uL,ui:()=>d.ui,updateProviderConnection:()=>d.rj,uv:()=>d.uv,yF:()=>d.yF,yg:()=>d.yg,zP:()=>d.zP,zw:()=>d.zw});var d=c(47765)}};
@@ -1 +1 @@
1
- "use strict";exports.id=7525,exports.ids=[7525,7557],exports.modules={67557:(a,b,c)=>{c.r(b),c.d(b,{default:()=>u,proxyAwareFetch:()=>s});var d=c(27910);function e(a,b){let c=process.env[a];if(null==c||""===c)return b;let d=parseInt(c,10);return Number.isFinite(d)&&d>0?d:b}process.env.SEARXNG_URL?.trim(),e("STREAM_STALL_TIMEOUT_MS",36e4),e("STREAM_FIRST_CHUNK_TIMEOUT_MS",2e5),e("FETCH_CONNECT_TIMEOUT_MS",6e4),e("GEMINI_NATIVE_TTS_FETCH_TIMEOUT_MS",45e3),e("AGGREGATOR_UNSUPPORTED_TTL_MS",6e5),process.env.AGGREGATOR_WALLET_SUPABASE_URL,process.env.AGGREGATOR_WALLET_ANON_KEY,process.env.AGGREGATOR_WALLET_AUTH_BASE_URL;let f=globalThis.fetch,g=new Map,h=new Map,i=new Set(["SELF_SIGNED_CERT_IN_CHAIN","DEPTH_ZERO_SELF_SIGNED_CERT","UNABLE_TO_VERIFY_LEAF_SIGNATURE","UNABLE_TO_GET_ISSUER_CERT","UNABLE_TO_GET_ISSUER_CERT_LOCALLY","CERT_HAS_EXPIRED","ERR_TLS_CERT_ALTNAME_INVALID"]),j=["cloudcode-pa.googleapis.com","daily-cloudcode-pa.googleapis.com","api.individual.githubcopilot.com","q.us-east-1.amazonaws.com","codewhisperer.us-east-1.amazonaws.com","api2.cursor.sh"],k=["8.8.8.8","8.8.4.4"];function l(a){return null==a?"":String(a).trim()}async function m(a){let b=h.get(a);if(b&&Date.now()<b.expiry)return b.ip;try{let b=await Promise.resolve().then(c.t.bind(c,14985,23)),{promisify:d}=await Promise.resolve().then(c.t.bind(c,28354,23)),e=new b.Resolver;e.setServers(k);let f=d(e.resolve4.bind(e)),g=await f(a);return h.set(a,{ip:g[0],expiry:Date.now()+3e5}),g[0]}catch(b){return console.warn(`[ProxyFetch] DNS resolve failed for ${a}:`,b.message),null}}function n(a,b){let c,d=l(b);if(!d)return!1;try{c=new URL(a).hostname.toLowerCase()}catch{return!1}return d.split(",").map(a=>a.trim().toLowerCase()).filter(Boolean).some(a=>"*"===a||(a.startsWith(".")?c.endsWith(a)||c===a.slice(1):c===a||c.endsWith(`.${a}`)))}function o(a){let b=l(a);if(!b)return null;try{return new URL(b),b}catch{return`http://${b}`}}async function p(a,b=!1){let d=o(a);if(!d&&!b)return null;let e=`${d||"direct"}::${b?"insecure":"secure"}`;if(!g.has(e)){g.size>=20&&g.delete(g.keys().next().value);let{Agent:a,ProxyAgent:f}=await c.e(7995).then(c.t.bind(c,17995,19)),h=b?{rejectUnauthorized:!1}:void 0,i=d?new f({uri:d,...b?{requestTls:h}:{}}):new a({connect:h});g.set(e,i)}return g.get(e)}async function q(a,b,c){try{let d=c?await p(c):void 0;return await f(a,d?{...b,dispatcher:d}:b)}catch(e){let d;if("true"!==process.env.STRICT_SSL&&"1"!==process.env.STRICT_SSL&&(d=e?.cause?.code||e?.code,i.has(d))){if(b.body&&"function"==typeof b.body.getReader&&b.body.locked)throw e;console.warn(`[ProxyFetch] TLS cert verification failed (${e.cause?.code||e.code}), retrying with insecure TLS: ${a}`);let d=await p(c,!0);return await f(a,{...b,dispatcher:d})}throw e}}async function r(a,b,e){let f=await Promise.resolve().then(c.t.bind(c,55591,23)),g=await Promise.resolve().then(c.t.bind(c,91645,23)),h=f.default??f,i=g.default??g;return new Promise((c,f)=>{let g=new i.Socket;if(g.connect(443,b,()=>{let b={socket:g,servername:a.hostname,path:a.pathname+a.search,method:e.method||"POST",headers:{...e.headers,Host:a.hostname}},i=h.request(b,a=>{let b={ok:a.statusCode>=200&&a.statusCode<300,status:a.statusCode,statusText:a.statusMessage,headers:new Map(Object.entries(a.headers)),body:d.Readable.toWeb(a),text:async()=>{let b=[];for await(let c of a)b.push(c);return Buffer.concat(b).toString()},json:async()=>JSON.parse(await b.text())};c(b)});i.on("error",f),e.body&&i.write("string"==typeof e.body?e.body:JSON.stringify(e.body)),i.end()}),g.on("error",f),e.signal){let a=!1,b=()=>{a||(a=!0,g.destroy(),f(new DOMException("The operation was aborted","AbortError")))};e.signal.aborted?b():(e.signal.addEventListener("abort",b,{once:!0}),g.once("close",()=>e.signal.removeEventListener("abort",b)))}})}async function s(a,b={},c=null){let d="string"==typeof a?a:a.toString(),e=l(c?.vercelRelayUrl);if(e){let a=new URL(d),c={...b.headers instanceof Headers?Object.fromEntries(b.headers.entries()):{...b.headers||{}},"x-relay-target":`${a.protocol}//${a.host}`,"x-relay-path":`${a.pathname}${a.search}`};return f(e,{...b,headers:c})}let g=function(a,b){if(b?.enabled!==!0&&b?.connectionProxyEnabled!==!0)return null;let c=l(b?.url??b?.connectionProxyUrl);if(!c)return null;let d=l(b?.noProxy??b?.connectionNoProxy);return d&&n(a,d)?null:o(c)}(d,c),h=g?null:o(function(a){let b;if(n(a,process.env.NO_PROXY||process.env.no_proxy))return null;try{b=new URL(a).protocol}catch{return null}return"https:"===b?process.env.HTTPS_PROXY||process.env.https_proxy||process.env.ALL_PROXY||process.env.all_proxy:process.env.HTTP_PROXY||process.env.http_proxy||process.env.ALL_PROXY||process.env.all_proxy}(d)),i=g||h;if(function(a){try{let b=new URL(a).hostname;return j.some(a=>b.includes(a))}catch{return!1}}(d)){if(i)try{return await q(a,b,i)}catch(a){if(c?.strictProxy===!0)throw Error(`[ProxyFetch] Proxy required but failed (strictProxy=true): ${a.message}`);console.warn(`[ProxyFetch] Proxy failed, falling back to direct bypass: ${a.message}`)}try{let a=new URL(d),c=await m(a.hostname);if(c)return await r(a,c,b)}catch(a){console.warn(`[ProxyFetch] MITM bypass failed: ${a.message}`)}}if(i)try{return await q(a,b,i)}catch(d){if(c?.strictProxy===!0)throw Error(`[ProxyFetch] Proxy required but failed (strictProxy=true): ${d.message}`);return console.warn(`[ProxyFetch] Proxy failed, falling back to direct: ${d.message}`),q(a,b,null)}let k=c?.proxyPoolId||c?.enabled===!0||c?.connectionProxyEnabled===!0||!!l(c?.url??c?.connectionProxyUrl);if(c?.strictProxy===!0&&k)throw Error("[ProxyFetch] Proxy required but none resolved (strictProxy=true)");return q(a,b,null)}async function t(a,b={}){return s(a,b,null)}globalThis.fetch!==t&&(globalThis.fetch=t);let u=t},97525:(a,b,c)=>{c.r(b),c.d(b,{MIMO_API_BASE:()=>D,MIMO_API_UA:()=>E,getMimoAccountCookie:()=>F,getMimoAccountUsage:()=>G,invalidateMimoAccountCookieCache:()=>C,readDesktopPassToken:()=>v,resolveMimoServerBase:()=>y});var d=c(73024),e=c.n(d),f=c(48161),g=c.n(f),h=c(76760),i=c.n(h),j=c(77598),k=c.n(j),l=c(67557);let m={cn:"https://mimo-server-cn.xiaomimimo.com",sgp:"https://mimo-server-sgp.xiaomimimo.com",ams:"https://mimo-server-ams.xiaomimimo.com",ru:"https://mimo-server-ru.xiaomimimo.com",in:"https://mimo-server-in.xiaomimimo.com"},n=m.sgp,o={cn:"mimopc",sgp:"mimosgp",ams:"mimoams",ru:"mimoru",in:"mimoin"},p="account.xiaomi.com",q="miNative PC/Normal Windows_NT/10.0.19045 SDKV/1.0.0 DEVT/PC DEVS/Windows APP/miaccount_desktop APPV/0.1.0",r="MiClaw/1.0",s=new Map,t=new Map;async function u(){let a,b=(a=g().homedir(),"win32"===process.platform?i().join(a,"AppData","Roaming","Xiaomi MiMo","Partitions","xiaomi-account","Network","Cookies"):"darwin"===process.platform?i().join(a,"Library","Application Support","Xiaomi MiMo","Partitions","xiaomi-account","Network","Cookies"):i().join(a,".config","Xiaomi MiMo","Partitions","xiaomi-account","Network","Cookies"));if(!e().existsSync(b))return null;let d=i().join(g().tmpdir(),`9r-mimo-cookies-${process.pid}-${k().randomBytes(4).toString("hex")}.db`);try{e().copyFileSync(b,d)}catch{return null}try{let{DatabaseSync:a}=await Promise.resolve().then(c.t.bind(c,79868,23)),b=new a(d,{readOnly:!0}),e=b.prepare("SELECT name, value FROM cookies WHERE host_key = ?").all("."+p);b.close();let f=Object.fromEntries(e.map(a=>[a.name,a.value]));return f.passToken?f:null}catch{return null}finally{try{e().unlinkSync(d)}catch{}}}async function v(){try{let a=await u();if(!a?.passToken)return null;return{passToken:a.passToken,userId:a.userId||null,cUserId:a.cUserId||null}}catch{return null}}function w(a,b){for(let c of b.headers.getSetCookie?.()||[]){let b=/^([^=]+)=([^;]*)/.exec(c.trim());b&&b[2]&&(a[b[1]]=b[2])}}function x(a){return Object.entries(a).filter(([,a])=>a).map(([a,b])=>`${a}=${b}`).join("; ")}function y(a=null){return m[String(a?.region||"").toLowerCase()]||n}async function z(a,b,c=n,d="sgp"){let e=String(d||"").toLowerCase(),f=o[String(e||"").toLowerCase()]||o.sgp,g=await A(a,"cn"===e?null:b,c,f);return g&&console.log(`[mimoAccount] desktop 2-phase OK (sid=${f})`),g}async function A(a,b,c,d){var e,f;let g,h=a=>console.log(`[mimoAccount] desktopPhase fail: ${a}`),i={...a},j={};i.userId&&(j.userId=i.userId),i.passToken&&(j.passToken=i.passToken),i.cUserId&&(j.cUserId=i.cUserId);let m=`https://${p}/pass/serviceLogin?_locale=zh_CN&_snsNone=true&sid=${encodeURIComponent(d)}&_json=true`,n=await (0,l.proxyAwareFetch)(m,{headers:{Cookie:x(j),"User-Agent":r,Accept:"application/json"}},b),o=await n.text(),q=o.replace(/^&&&START&&&/,""),s=q.match(/"nonce"\s*:\s*(\d+)/)?.[1],t=null;try{t=JSON.parse(q)}catch{}if(s&&t&&(t.nonce=s),!t||"number"!=typeof t.code||0!==t.code||!t.location||!t.nonce||!t.ssecurity)return h(`phase1 sid=${d} http=${n.status} code=${t?.code??"?"} hasLoc=${!!t?.location} secondValidation=${t?.bSecondValidation??"?"} notificationUrl=${t?.notificationUrl?"present":"no"} body=${JSON.stringify(o.slice(0,200))}`),null;w(i,n);let u=t.location.includes("?")?"&":"?",v=`${t.location}${u}clientSign=${(e=s||t.nonce,g=`nonce=${e}`+((f=t.ssecurity)&&f.trim()?`&${f}`:""),encodeURIComponent(k().createHash("sha1").update(g).digest("base64")))}`;for(let a=0;a<8;a++){let a=await (0,l.proxyAwareFetch)(v,{redirect:"manual",headers:{"User-Agent":r}},b);w(i,a);let c=a.headers.get("location");if(a.status>=300&&a.status<400&&c){v=new URL(c,v).toString();continue}break}let y=`${d}_serviceToken`;if(!i.serviceToken&&i[y]&&(i.serviceToken=i[y]),!i.serviceToken)return h(`phase2 no serviceToken sid=${d} jar=[${Object.keys(i).join(",")}]`),null;let z={};for(let[a,b]of Object.entries(i))b&&("serviceToken"===a||"userId"===a||/_(ph|slh)$/.test(a))&&(z[a]=b);return x(z)}async function B(a,b){let c=y(a),d=a?.mimoPassToken?{passToken:a.mimoPassToken,userId:a.mimoUserId,cUserId:a.mimoCUserId}:await u();if(!d)return{cookie:null,reason:"no-pass-token"};let e=k().createHash("sha256").update(`${c}|${d.passToken}`).digest("hex"),f=s.get(e);if(f&&Date.now()-f.at<18e5)return{cookie:f.cookie};let g=t.get(e);if(g){let a=await g;return a?{cookie:a}:{cookie:null,reason:"sso-failed"}}let h=(async()=>{try{return await z(d,b,c,a?.region)}catch(a){return console.log(`[mimoAccount] acquire threw: ${a?.message||a} | ${String(a?.stack||"").split("\n").slice(1,4).join(" <- ")}`),null}finally{t.delete(e)}})();t.set(e,h);let i=await h;return i?(s.set(e,{cookie:i,at:Date.now()}),{cookie:i}):{cookie:null,reason:"sso-failed"}}function C(){s.clear()}let D=n,E=q;async function F(a=null,b=null){try{let{cookie:c}=await B(a,b);return c}catch(a){return console.log(`[mimoAccount] getMimoAccountCookie threw: ${a?.message||a} | ${String(a?.stack||"").split("\n").slice(1,4).join(" <- ")}`),null}}async function G(a=null,b=null){let{cookie:c,reason:d}=await B(a,b);if(!c)return{error:"no-pass-token"===d?"no-session":"session-failed"};try{let d=await (0,l.proxyAwareFetch)(`${y(a)}/api/user/usage`,{headers:{"User-Agent":q,Cookie:c,Accept:"application/json"},signal:AbortSignal.timeout(1e4)},b);if(!d.ok)return{error:`http-${d.status}`};let e=await d.json().catch(()=>null);if(!e||0!==e.code||!e.data)return{error:"bad-response"};return{percent:e.data.percent,resetDate:e.data.resetDate,resetAt:e.data.resetAt}}catch(a){return{error:a.message}}}}};
1
+ "use strict";exports.id=7525,exports.ids=[7525,7557],exports.modules={67557:(a,b,c)=>{c.r(b),c.d(b,{default:()=>u,proxyAwareFetch:()=>s});var d=c(27910);function e(a,b){let c=process.env[a];if(null==c||""===c)return b;let d=parseInt(c,10);return Number.isFinite(d)&&d>0?d:b}process.env.SEARXNG_URL?.trim(),e("STREAM_STALL_TIMEOUT_MS",36e4),e("STREAM_FIRST_CHUNK_TIMEOUT_MS",2e5),e("UPSTREAM_MAX_BODY_BYTES",0x2000000),e("UPSTREAM_TOTAL_TIMEOUT_MS",18e5),e("FETCH_CONNECT_TIMEOUT_MS",6e4),e("GEMINI_NATIVE_TTS_FETCH_TIMEOUT_MS",45e3),e("AGGREGATOR_UNSUPPORTED_TTL_MS",6e5),process.env.AGGREGATOR_WALLET_SUPABASE_URL,process.env.AGGREGATOR_WALLET_ANON_KEY,process.env.AGGREGATOR_WALLET_AUTH_BASE_URL;let f=globalThis.fetch,g=new Map,h=new Map,i=new Set(["SELF_SIGNED_CERT_IN_CHAIN","DEPTH_ZERO_SELF_SIGNED_CERT","UNABLE_TO_VERIFY_LEAF_SIGNATURE","UNABLE_TO_GET_ISSUER_CERT","UNABLE_TO_GET_ISSUER_CERT_LOCALLY","CERT_HAS_EXPIRED","ERR_TLS_CERT_ALTNAME_INVALID"]),j=["cloudcode-pa.googleapis.com","daily-cloudcode-pa.googleapis.com","api.individual.githubcopilot.com","q.us-east-1.amazonaws.com","codewhisperer.us-east-1.amazonaws.com","api2.cursor.sh"],k=["8.8.8.8","8.8.4.4"];function l(a){return null==a?"":String(a).trim()}async function m(a){let b=h.get(a);if(b&&Date.now()<b.expiry)return b.ip;try{let b=await Promise.resolve().then(c.t.bind(c,14985,23)),{promisify:d}=await Promise.resolve().then(c.t.bind(c,28354,23)),e=new b.Resolver;e.setServers(k);let f=d(e.resolve4.bind(e)),g=await f(a);return h.set(a,{ip:g[0],expiry:Date.now()+3e5}),g[0]}catch(b){return console.warn(`[ProxyFetch] DNS resolve failed for ${a}:`,b.message),null}}function n(a,b){let c,d=l(b);if(!d)return!1;try{c=new URL(a).hostname.toLowerCase()}catch{return!1}return d.split(",").map(a=>a.trim().toLowerCase()).filter(Boolean).some(a=>"*"===a||(a.startsWith(".")?c.endsWith(a)||c===a.slice(1):c===a||c.endsWith(`.${a}`)))}function o(a){let b=l(a);if(!b)return null;try{return new URL(b),b}catch{return`http://${b}`}}async function p(a,b=!1){let d=o(a);if(!d&&!b)return null;let e=`${d||"direct"}::${b?"insecure":"secure"}`;if(!g.has(e)){g.size>=20&&g.delete(g.keys().next().value);let{Agent:a,ProxyAgent:f}=await c.e(7995).then(c.t.bind(c,17995,19)),h=b?{rejectUnauthorized:!1}:void 0,i=d?new f({uri:d,...b?{requestTls:h}:{}}):new a({connect:h});g.set(e,i)}return g.get(e)}async function q(a,b,c){try{let d=c?await p(c):void 0;return await f(a,d?{...b,dispatcher:d}:b)}catch(e){let d;if("true"!==process.env.STRICT_SSL&&"1"!==process.env.STRICT_SSL&&(d=e?.cause?.code||e?.code,i.has(d))){if(b.body&&"function"==typeof b.body.getReader&&b.body.locked)throw e;console.warn(`[ProxyFetch] TLS cert verification failed (${e.cause?.code||e.code}), retrying with insecure TLS: ${a}`);let d=await p(c,!0);return await f(a,{...b,dispatcher:d})}throw e}}async function r(a,b,e){let f=await Promise.resolve().then(c.t.bind(c,55591,23)),g=await Promise.resolve().then(c.t.bind(c,91645,23)),h=f.default??f,i=g.default??g;return new Promise((c,f)=>{let g=new i.Socket;if(g.connect(443,b,()=>{let b={socket:g,servername:a.hostname,path:a.pathname+a.search,method:e.method||"POST",headers:{...e.headers,Host:a.hostname}},i=h.request(b,a=>{let b={ok:a.statusCode>=200&&a.statusCode<300,status:a.statusCode,statusText:a.statusMessage,headers:new Map(Object.entries(a.headers)),body:d.Readable.toWeb(a),text:async()=>{let b=[];for await(let c of a)b.push(c);return Buffer.concat(b).toString()},json:async()=>JSON.parse(await b.text())};c(b)});i.on("error",f),e.body&&i.write("string"==typeof e.body?e.body:JSON.stringify(e.body)),i.end()}),g.on("error",f),e.signal){let a=!1,b=()=>{a||(a=!0,g.destroy(),f(new DOMException("The operation was aborted","AbortError")))};e.signal.aborted?b():(e.signal.addEventListener("abort",b,{once:!0}),g.once("close",()=>e.signal.removeEventListener("abort",b)))}})}async function s(a,b={},c=null){let d="string"==typeof a?a:a.toString(),e=l(c?.vercelRelayUrl);if(e){let a=new URL(d),c={...b.headers instanceof Headers?Object.fromEntries(b.headers.entries()):{...b.headers||{}},"x-relay-target":`${a.protocol}//${a.host}`,"x-relay-path":`${a.pathname}${a.search}`};return f(e,{...b,headers:c})}let g=function(a,b){if(b?.enabled!==!0&&b?.connectionProxyEnabled!==!0)return null;let c=l(b?.url??b?.connectionProxyUrl);if(!c)return null;let d=l(b?.noProxy??b?.connectionNoProxy);return d&&n(a,d)?null:o(c)}(d,c),h=g?null:o(function(a){let b;if(n(a,process.env.NO_PROXY||process.env.no_proxy))return null;try{b=new URL(a).protocol}catch{return null}return"https:"===b?process.env.HTTPS_PROXY||process.env.https_proxy||process.env.ALL_PROXY||process.env.all_proxy:process.env.HTTP_PROXY||process.env.http_proxy||process.env.ALL_PROXY||process.env.all_proxy}(d)),i=g||h;if(function(a){try{let b=new URL(a).hostname;return j.some(a=>b.includes(a))}catch{return!1}}(d)){if(i)try{return await q(a,b,i)}catch(a){if(c?.strictProxy===!0)throw Error(`[ProxyFetch] Proxy required but failed (strictProxy=true): ${a.message}`);console.warn(`[ProxyFetch] Proxy failed, falling back to direct bypass: ${a.message}`)}try{let a=new URL(d),c=await m(a.hostname);if(c)return await r(a,c,b)}catch(a){console.warn(`[ProxyFetch] MITM bypass failed: ${a.message}`)}}if(i)try{return await q(a,b,i)}catch(d){if(c?.strictProxy===!0)throw Error(`[ProxyFetch] Proxy required but failed (strictProxy=true): ${d.message}`);return console.warn(`[ProxyFetch] Proxy failed, falling back to direct: ${d.message}`),q(a,b,null)}let k=c?.proxyPoolId||c?.enabled===!0||c?.connectionProxyEnabled===!0||!!l(c?.url??c?.connectionProxyUrl);if(c?.strictProxy===!0&&k)throw Error("[ProxyFetch] Proxy required but none resolved (strictProxy=true)");return q(a,b,null)}async function t(a,b={}){return s(a,b,null)}globalThis.fetch!==t&&(globalThis.fetch=t);let u=t},97525:(a,b,c)=>{c.r(b),c.d(b,{MIMO_API_BASE:()=>D,MIMO_API_UA:()=>E,getMimoAccountCookie:()=>F,getMimoAccountUsage:()=>G,invalidateMimoAccountCookieCache:()=>C,readDesktopPassToken:()=>v,resolveMimoServerBase:()=>y});var d=c(73024),e=c.n(d),f=c(48161),g=c.n(f),h=c(76760),i=c.n(h),j=c(77598),k=c.n(j),l=c(67557);let m={cn:"https://mimo-server-cn.xiaomimimo.com",sgp:"https://mimo-server-sgp.xiaomimimo.com",ams:"https://mimo-server-ams.xiaomimimo.com",ru:"https://mimo-server-ru.xiaomimimo.com",in:"https://mimo-server-in.xiaomimimo.com"},n=m.sgp,o={cn:"mimopc",sgp:"mimosgp",ams:"mimoams",ru:"mimoru",in:"mimoin"},p="account.xiaomi.com",q="miNative PC/Normal Windows_NT/10.0.19045 SDKV/1.0.0 DEVT/PC DEVS/Windows APP/miaccount_desktop APPV/0.1.0",r="MiClaw/1.0",s=new Map,t=new Map;async function u(){let a,b=(a=g().homedir(),"win32"===process.platform?i().join(a,"AppData","Roaming","Xiaomi MiMo","Partitions","xiaomi-account","Network","Cookies"):"darwin"===process.platform?i().join(a,"Library","Application Support","Xiaomi MiMo","Partitions","xiaomi-account","Network","Cookies"):i().join(a,".config","Xiaomi MiMo","Partitions","xiaomi-account","Network","Cookies"));if(!e().existsSync(b))return null;let d=i().join(g().tmpdir(),`9r-mimo-cookies-${process.pid}-${k().randomBytes(4).toString("hex")}.db`);try{e().copyFileSync(b,d)}catch{return null}try{let{DatabaseSync:a}=await Promise.resolve().then(c.t.bind(c,79868,23)),b=new a(d,{readOnly:!0}),e=b.prepare("SELECT name, value FROM cookies WHERE host_key = ?").all("."+p);b.close();let f=Object.fromEntries(e.map(a=>[a.name,a.value]));return f.passToken?f:null}catch{return null}finally{try{e().unlinkSync(d)}catch{}}}async function v(){try{let a=await u();if(!a?.passToken)return null;return{passToken:a.passToken,userId:a.userId||null,cUserId:a.cUserId||null}}catch{return null}}function w(a,b){for(let c of b.headers.getSetCookie?.()||[]){let b=/^([^=]+)=([^;]*)/.exec(c.trim());b&&b[2]&&(a[b[1]]=b[2])}}function x(a){return Object.entries(a).filter(([,a])=>a).map(([a,b])=>`${a}=${b}`).join("; ")}function y(a=null){return m[String(a?.region||"").toLowerCase()]||n}async function z(a,b,c=n,d="sgp"){let e=String(d||"").toLowerCase(),f=o[String(e||"").toLowerCase()]||o.sgp,g=await A(a,"cn"===e?null:b,c,f);return g&&console.log(`[mimoAccount] desktop 2-phase OK (sid=${f})`),g}async function A(a,b,c,d){var e,f;let g,h=a=>console.log(`[mimoAccount] desktopPhase fail: ${a}`),i={...a},j={};i.userId&&(j.userId=i.userId),i.passToken&&(j.passToken=i.passToken),i.cUserId&&(j.cUserId=i.cUserId);let m=`https://${p}/pass/serviceLogin?_locale=zh_CN&_snsNone=true&sid=${encodeURIComponent(d)}&_json=true`,n=await (0,l.proxyAwareFetch)(m,{headers:{Cookie:x(j),"User-Agent":r,Accept:"application/json"}},b),o=await n.text(),q=o.replace(/^&&&START&&&/,""),s=q.match(/"nonce"\s*:\s*(\d+)/)?.[1],t=null;try{t=JSON.parse(q)}catch{}if(s&&t&&(t.nonce=s),!t||"number"!=typeof t.code||0!==t.code||!t.location||!t.nonce||!t.ssecurity)return h(`phase1 sid=${d} http=${n.status} code=${t?.code??"?"} hasLoc=${!!t?.location} secondValidation=${t?.bSecondValidation??"?"} notificationUrl=${t?.notificationUrl?"present":"no"} body=${JSON.stringify(o.slice(0,200))}`),null;w(i,n);let u=t.location.includes("?")?"&":"?",v=`${t.location}${u}clientSign=${(e=s||t.nonce,g=`nonce=${e}`+((f=t.ssecurity)&&f.trim()?`&${f}`:""),encodeURIComponent(k().createHash("sha1").update(g).digest("base64")))}`;for(let a=0;a<8;a++){let a=await (0,l.proxyAwareFetch)(v,{redirect:"manual",headers:{"User-Agent":r}},b);w(i,a);let c=a.headers.get("location");if(a.status>=300&&a.status<400&&c){v=new URL(c,v).toString();continue}break}let y=`${d}_serviceToken`;if(!i.serviceToken&&i[y]&&(i.serviceToken=i[y]),!i.serviceToken)return h(`phase2 no serviceToken sid=${d} jar=[${Object.keys(i).join(",")}]`),null;let z={};for(let[a,b]of Object.entries(i))b&&("serviceToken"===a||"userId"===a||/_(ph|slh)$/.test(a))&&(z[a]=b);return x(z)}async function B(a,b){let c=y(a),d=a?.mimoPassToken?{passToken:a.mimoPassToken,userId:a.mimoUserId,cUserId:a.mimoCUserId}:await u();if(!d)return{cookie:null,reason:"no-pass-token"};let e=k().createHash("sha256").update(`${c}|${d.passToken}`).digest("hex"),f=s.get(e);if(f&&Date.now()-f.at<18e5)return{cookie:f.cookie};let g=t.get(e);if(g){let a=await g;return a?{cookie:a}:{cookie:null,reason:"sso-failed"}}let h=(async()=>{try{return await z(d,b,c,a?.region)}catch(a){return console.log(`[mimoAccount] acquire threw: ${a?.message||a} | ${String(a?.stack||"").split("\n").slice(1,4).join(" <- ")}`),null}finally{t.delete(e)}})();t.set(e,h);let i=await h;return i?(s.set(e,{cookie:i,at:Date.now()}),{cookie:i}):{cookie:null,reason:"sso-failed"}}function C(){s.clear()}let D=n,E=q;async function F(a=null,b=null){try{let{cookie:c}=await B(a,b);return c}catch(a){return console.log(`[mimoAccount] getMimoAccountCookie threw: ${a?.message||a} | ${String(a?.stack||"").split("\n").slice(1,4).join(" <- ")}`),null}}async function G(a=null,b=null){let{cookie:c,reason:d}=await B(a,b);if(!c)return{error:"no-pass-token"===d?"no-session":"session-failed"};try{let d=await (0,l.proxyAwareFetch)(`${y(a)}/api/user/usage`,{headers:{"User-Agent":q,Cookie:c,Accept:"application/json"},signal:AbortSignal.timeout(1e4)},b);if(!d.ok)return{error:`http-${d.status}`};let e=await d.json().catch(()=>null);if(!e||0!==e.code||!e.data)return{error:"bad-response"};return{percent:e.data.percent,resetDate:e.data.resetDate,resetAt:e.data.resetAt}}catch(a){return{error:a.message}}}}};
@@ -1 +1 @@
1
- "use strict";exports.id=7557,exports.ids=[7557],exports.modules={67557:(a,b,c)=>{c.r(b),c.d(b,{default:()=>u,proxyAwareFetch:()=>s});var d=c(27910);function e(a,b){let c=process.env[a];if(null==c||""===c)return b;let d=parseInt(c,10);return Number.isFinite(d)&&d>0?d:b}process.env.SEARXNG_URL?.trim(),e("STREAM_STALL_TIMEOUT_MS",36e4),e("STREAM_FIRST_CHUNK_TIMEOUT_MS",2e5),e("FETCH_CONNECT_TIMEOUT_MS",6e4),e("GEMINI_NATIVE_TTS_FETCH_TIMEOUT_MS",45e3),e("AGGREGATOR_UNSUPPORTED_TTL_MS",6e5),process.env.AGGREGATOR_WALLET_SUPABASE_URL,process.env.AGGREGATOR_WALLET_ANON_KEY,process.env.AGGREGATOR_WALLET_AUTH_BASE_URL;let f=globalThis.fetch,g=new Map,h=new Map,i=new Set(["SELF_SIGNED_CERT_IN_CHAIN","DEPTH_ZERO_SELF_SIGNED_CERT","UNABLE_TO_VERIFY_LEAF_SIGNATURE","UNABLE_TO_GET_ISSUER_CERT","UNABLE_TO_GET_ISSUER_CERT_LOCALLY","CERT_HAS_EXPIRED","ERR_TLS_CERT_ALTNAME_INVALID"]),j=["cloudcode-pa.googleapis.com","daily-cloudcode-pa.googleapis.com","api.individual.githubcopilot.com","q.us-east-1.amazonaws.com","codewhisperer.us-east-1.amazonaws.com","api2.cursor.sh"],k=["8.8.8.8","8.8.4.4"];function l(a){return null==a?"":String(a).trim()}async function m(a){let b=h.get(a);if(b&&Date.now()<b.expiry)return b.ip;try{let b=await Promise.resolve().then(c.t.bind(c,14985,23)),{promisify:d}=await Promise.resolve().then(c.t.bind(c,28354,23)),e=new b.Resolver;e.setServers(k);let f=d(e.resolve4.bind(e)),g=await f(a);return h.set(a,{ip:g[0],expiry:Date.now()+3e5}),g[0]}catch(b){return console.warn(`[ProxyFetch] DNS resolve failed for ${a}:`,b.message),null}}function n(a,b){let c,d=l(b);if(!d)return!1;try{c=new URL(a).hostname.toLowerCase()}catch{return!1}return d.split(",").map(a=>a.trim().toLowerCase()).filter(Boolean).some(a=>"*"===a||(a.startsWith(".")?c.endsWith(a)||c===a.slice(1):c===a||c.endsWith(`.${a}`)))}function o(a){let b=l(a);if(!b)return null;try{return new URL(b),b}catch{return`http://${b}`}}async function p(a,b=!1){let d=o(a);if(!d&&!b)return null;let e=`${d||"direct"}::${b?"insecure":"secure"}`;if(!g.has(e)){g.size>=20&&g.delete(g.keys().next().value);let{Agent:a,ProxyAgent:f}=await c.e(7995).then(c.t.bind(c,17995,19)),h=b?{rejectUnauthorized:!1}:void 0,i=d?new f({uri:d,...b?{requestTls:h}:{}}):new a({connect:h});g.set(e,i)}return g.get(e)}async function q(a,b,c){try{let d=c?await p(c):void 0;return await f(a,d?{...b,dispatcher:d}:b)}catch(e){let d;if("true"!==process.env.STRICT_SSL&&"1"!==process.env.STRICT_SSL&&(d=e?.cause?.code||e?.code,i.has(d))){if(b.body&&"function"==typeof b.body.getReader&&b.body.locked)throw e;console.warn(`[ProxyFetch] TLS cert verification failed (${e.cause?.code||e.code}), retrying with insecure TLS: ${a}`);let d=await p(c,!0);return await f(a,{...b,dispatcher:d})}throw e}}async function r(a,b,e){let f=await Promise.resolve().then(c.t.bind(c,55591,23)),g=await Promise.resolve().then(c.t.bind(c,91645,23)),h=f.default??f,i=g.default??g;return new Promise((c,f)=>{let g=new i.Socket;if(g.connect(443,b,()=>{let b={socket:g,servername:a.hostname,path:a.pathname+a.search,method:e.method||"POST",headers:{...e.headers,Host:a.hostname}},i=h.request(b,a=>{let b={ok:a.statusCode>=200&&a.statusCode<300,status:a.statusCode,statusText:a.statusMessage,headers:new Map(Object.entries(a.headers)),body:d.Readable.toWeb(a),text:async()=>{let b=[];for await(let c of a)b.push(c);return Buffer.concat(b).toString()},json:async()=>JSON.parse(await b.text())};c(b)});i.on("error",f),e.body&&i.write("string"==typeof e.body?e.body:JSON.stringify(e.body)),i.end()}),g.on("error",f),e.signal){let a=!1,b=()=>{a||(a=!0,g.destroy(),f(new DOMException("The operation was aborted","AbortError")))};e.signal.aborted?b():(e.signal.addEventListener("abort",b,{once:!0}),g.once("close",()=>e.signal.removeEventListener("abort",b)))}})}async function s(a,b={},c=null){let d="string"==typeof a?a:a.toString(),e=l(c?.vercelRelayUrl);if(e){let a=new URL(d),c={...b.headers instanceof Headers?Object.fromEntries(b.headers.entries()):{...b.headers||{}},"x-relay-target":`${a.protocol}//${a.host}`,"x-relay-path":`${a.pathname}${a.search}`};return f(e,{...b,headers:c})}let g=function(a,b){if(b?.enabled!==!0&&b?.connectionProxyEnabled!==!0)return null;let c=l(b?.url??b?.connectionProxyUrl);if(!c)return null;let d=l(b?.noProxy??b?.connectionNoProxy);return d&&n(a,d)?null:o(c)}(d,c),h=g?null:o(function(a){let b;if(n(a,process.env.NO_PROXY||process.env.no_proxy))return null;try{b=new URL(a).protocol}catch{return null}return"https:"===b?process.env.HTTPS_PROXY||process.env.https_proxy||process.env.ALL_PROXY||process.env.all_proxy:process.env.HTTP_PROXY||process.env.http_proxy||process.env.ALL_PROXY||process.env.all_proxy}(d)),i=g||h;if(function(a){try{let b=new URL(a).hostname;return j.some(a=>b.includes(a))}catch{return!1}}(d)){if(i)try{return await q(a,b,i)}catch(a){if(c?.strictProxy===!0)throw Error(`[ProxyFetch] Proxy required but failed (strictProxy=true): ${a.message}`);console.warn(`[ProxyFetch] Proxy failed, falling back to direct bypass: ${a.message}`)}try{let a=new URL(d),c=await m(a.hostname);if(c)return await r(a,c,b)}catch(a){console.warn(`[ProxyFetch] MITM bypass failed: ${a.message}`)}}if(i)try{return await q(a,b,i)}catch(d){if(c?.strictProxy===!0)throw Error(`[ProxyFetch] Proxy required but failed (strictProxy=true): ${d.message}`);return console.warn(`[ProxyFetch] Proxy failed, falling back to direct: ${d.message}`),q(a,b,null)}let k=c?.proxyPoolId||c?.enabled===!0||c?.connectionProxyEnabled===!0||!!l(c?.url??c?.connectionProxyUrl);if(c?.strictProxy===!0&&k)throw Error("[ProxyFetch] Proxy required but none resolved (strictProxy=true)");return q(a,b,null)}async function t(a,b={}){return s(a,b,null)}globalThis.fetch!==t&&(globalThis.fetch=t);let u=t}};
1
+ "use strict";exports.id=7557,exports.ids=[7557],exports.modules={67557:(a,b,c)=>{c.r(b),c.d(b,{default:()=>u,proxyAwareFetch:()=>s});var d=c(27910);function e(a,b){let c=process.env[a];if(null==c||""===c)return b;let d=parseInt(c,10);return Number.isFinite(d)&&d>0?d:b}process.env.SEARXNG_URL?.trim(),e("STREAM_STALL_TIMEOUT_MS",36e4),e("STREAM_FIRST_CHUNK_TIMEOUT_MS",2e5),e("UPSTREAM_MAX_BODY_BYTES",0x2000000),e("UPSTREAM_TOTAL_TIMEOUT_MS",18e5),e("FETCH_CONNECT_TIMEOUT_MS",6e4),e("GEMINI_NATIVE_TTS_FETCH_TIMEOUT_MS",45e3),e("AGGREGATOR_UNSUPPORTED_TTL_MS",6e5),process.env.AGGREGATOR_WALLET_SUPABASE_URL,process.env.AGGREGATOR_WALLET_ANON_KEY,process.env.AGGREGATOR_WALLET_AUTH_BASE_URL;let f=globalThis.fetch,g=new Map,h=new Map,i=new Set(["SELF_SIGNED_CERT_IN_CHAIN","DEPTH_ZERO_SELF_SIGNED_CERT","UNABLE_TO_VERIFY_LEAF_SIGNATURE","UNABLE_TO_GET_ISSUER_CERT","UNABLE_TO_GET_ISSUER_CERT_LOCALLY","CERT_HAS_EXPIRED","ERR_TLS_CERT_ALTNAME_INVALID"]),j=["cloudcode-pa.googleapis.com","daily-cloudcode-pa.googleapis.com","api.individual.githubcopilot.com","q.us-east-1.amazonaws.com","codewhisperer.us-east-1.amazonaws.com","api2.cursor.sh"],k=["8.8.8.8","8.8.4.4"];function l(a){return null==a?"":String(a).trim()}async function m(a){let b=h.get(a);if(b&&Date.now()<b.expiry)return b.ip;try{let b=await Promise.resolve().then(c.t.bind(c,14985,23)),{promisify:d}=await Promise.resolve().then(c.t.bind(c,28354,23)),e=new b.Resolver;e.setServers(k);let f=d(e.resolve4.bind(e)),g=await f(a);return h.set(a,{ip:g[0],expiry:Date.now()+3e5}),g[0]}catch(b){return console.warn(`[ProxyFetch] DNS resolve failed for ${a}:`,b.message),null}}function n(a,b){let c,d=l(b);if(!d)return!1;try{c=new URL(a).hostname.toLowerCase()}catch{return!1}return d.split(",").map(a=>a.trim().toLowerCase()).filter(Boolean).some(a=>"*"===a||(a.startsWith(".")?c.endsWith(a)||c===a.slice(1):c===a||c.endsWith(`.${a}`)))}function o(a){let b=l(a);if(!b)return null;try{return new URL(b),b}catch{return`http://${b}`}}async function p(a,b=!1){let d=o(a);if(!d&&!b)return null;let e=`${d||"direct"}::${b?"insecure":"secure"}`;if(!g.has(e)){g.size>=20&&g.delete(g.keys().next().value);let{Agent:a,ProxyAgent:f}=await c.e(7995).then(c.t.bind(c,17995,19)),h=b?{rejectUnauthorized:!1}:void 0,i=d?new f({uri:d,...b?{requestTls:h}:{}}):new a({connect:h});g.set(e,i)}return g.get(e)}async function q(a,b,c){try{let d=c?await p(c):void 0;return await f(a,d?{...b,dispatcher:d}:b)}catch(e){let d;if("true"!==process.env.STRICT_SSL&&"1"!==process.env.STRICT_SSL&&(d=e?.cause?.code||e?.code,i.has(d))){if(b.body&&"function"==typeof b.body.getReader&&b.body.locked)throw e;console.warn(`[ProxyFetch] TLS cert verification failed (${e.cause?.code||e.code}), retrying with insecure TLS: ${a}`);let d=await p(c,!0);return await f(a,{...b,dispatcher:d})}throw e}}async function r(a,b,e){let f=await Promise.resolve().then(c.t.bind(c,55591,23)),g=await Promise.resolve().then(c.t.bind(c,91645,23)),h=f.default??f,i=g.default??g;return new Promise((c,f)=>{let g=new i.Socket;if(g.connect(443,b,()=>{let b={socket:g,servername:a.hostname,path:a.pathname+a.search,method:e.method||"POST",headers:{...e.headers,Host:a.hostname}},i=h.request(b,a=>{let b={ok:a.statusCode>=200&&a.statusCode<300,status:a.statusCode,statusText:a.statusMessage,headers:new Map(Object.entries(a.headers)),body:d.Readable.toWeb(a),text:async()=>{let b=[];for await(let c of a)b.push(c);return Buffer.concat(b).toString()},json:async()=>JSON.parse(await b.text())};c(b)});i.on("error",f),e.body&&i.write("string"==typeof e.body?e.body:JSON.stringify(e.body)),i.end()}),g.on("error",f),e.signal){let a=!1,b=()=>{a||(a=!0,g.destroy(),f(new DOMException("The operation was aborted","AbortError")))};e.signal.aborted?b():(e.signal.addEventListener("abort",b,{once:!0}),g.once("close",()=>e.signal.removeEventListener("abort",b)))}})}async function s(a,b={},c=null){let d="string"==typeof a?a:a.toString(),e=l(c?.vercelRelayUrl);if(e){let a=new URL(d),c={...b.headers instanceof Headers?Object.fromEntries(b.headers.entries()):{...b.headers||{}},"x-relay-target":`${a.protocol}//${a.host}`,"x-relay-path":`${a.pathname}${a.search}`};return f(e,{...b,headers:c})}let g=function(a,b){if(b?.enabled!==!0&&b?.connectionProxyEnabled!==!0)return null;let c=l(b?.url??b?.connectionProxyUrl);if(!c)return null;let d=l(b?.noProxy??b?.connectionNoProxy);return d&&n(a,d)?null:o(c)}(d,c),h=g?null:o(function(a){let b;if(n(a,process.env.NO_PROXY||process.env.no_proxy))return null;try{b=new URL(a).protocol}catch{return null}return"https:"===b?process.env.HTTPS_PROXY||process.env.https_proxy||process.env.ALL_PROXY||process.env.all_proxy:process.env.HTTP_PROXY||process.env.http_proxy||process.env.ALL_PROXY||process.env.all_proxy}(d)),i=g||h;if(function(a){try{let b=new URL(a).hostname;return j.some(a=>b.includes(a))}catch{return!1}}(d)){if(i)try{return await q(a,b,i)}catch(a){if(c?.strictProxy===!0)throw Error(`[ProxyFetch] Proxy required but failed (strictProxy=true): ${a.message}`);console.warn(`[ProxyFetch] Proxy failed, falling back to direct bypass: ${a.message}`)}try{let a=new URL(d),c=await m(a.hostname);if(c)return await r(a,c,b)}catch(a){console.warn(`[ProxyFetch] MITM bypass failed: ${a.message}`)}}if(i)try{return await q(a,b,i)}catch(d){if(c?.strictProxy===!0)throw Error(`[ProxyFetch] Proxy required but failed (strictProxy=true): ${d.message}`);return console.warn(`[ProxyFetch] Proxy failed, falling back to direct: ${d.message}`),q(a,b,null)}let k=c?.proxyPoolId||c?.enabled===!0||c?.connectionProxyEnabled===!0||!!l(c?.url??c?.connectionProxyUrl);if(c?.strictProxy===!0&&k)throw Error("[ProxyFetch] Proxy required but none resolved (strictProxy=true)");return q(a,b,null)}async function t(a,b={}){return s(a,b,null)}globalThis.fetch!==t&&(globalThis.fetch=t);let u=t}};
@@ -1 +1 @@
1
- "use strict";exports.id=7716,exports.ids=[3726,7716],exports.modules={53726:(a,b,c)=>{c.d(b,{l9:()=>o,Ah:()=>p,$i:()=>q,installCatalogSource:()=>z,Pg:()=>y});var d=c(73024),e=c.n(d),f=c(76760),g=c.n(f),h=c(33873),i=c.n(h),j=c(21820),k=c.n(j);let l="omnihilbras";function m(){return"win32"===process.platform?i().join(process.env.APPDATA||i().join(k().homedir(),"AppData","Roaming"),l):i().join(k().homedir(),`.${l}`)}let n=function(){let a=process.env.DATA_DIR;if(!a)return m();if("win32"===process.platform&&/^\//.test(a))return console.warn(`[DATA_DIR] '${a}' is a Unix path on Windows → fallback to default`),m();try{return e().mkdirSync(a,{recursive:!0}),a}catch(b){if(b?.code==="EACCES"||b?.code==="EPERM")return console.warn(`[DATA_DIR] '${a}' not writable → fallback ~/.${l}`),m();throw b}}(),o=g().join(n,"model-catalog.json"),p=g().join(n,"model-catalog-raw.json"),q=2,r={models:{},providers:{}},s=r,t=-1;function u(a){return a?(a.includes("/")?a.split("/").pop():a).toLowerCase().split(":")[0]:""}function v(){let a;try{a=e().statSync(o).mtimeMs}catch{return t=-1,s=r}if(a===t)return s;t=a;try{let a=JSON.parse(e().readFileSync(o,"utf8"));s={models:a?.models||{},providers:a?.providers||{}}}catch{s=r}return s}function w(a,b){return a&&v().models[`${a}:${u(b)}`]||null}function x(a,b){let c=a&&v().providers[a];return c&&(c[b]||c[u(b)])||null}function y(){t=-1}async function z(){let{setCatalogSource:a}=await c.e(8402).then(c.bind(c,38402));a({getModalities:w,getLimits:x})}},57716:(a,b,c)=>{c.d(b,{startModelCatalogSync:()=>q});var d=c(73024),e=c.n(d),f=c(76760),g=c.n(f),h=c(53726);let i={image:"vision",pdf:"pdf",audio:"audioInput",video:"videoInput"},j={github:"github-copilot",glm:"zai","glm-cn":"zhipuai",claude:"anthropic",gemini:"google",kimi:"moonshotai","kimi-cn":"moonshotai-cn",qwen:"alibaba","qwen-cn":"alibaba-cn",zhipu:"zhipuai",hunyuan:"tencent",doubao:"volcengine","cloudflare-ai":"cloudflare-workers-ai"},k={running:!1,lastSync:null,lastError:null,lastResult:null,etag:null,fileVersion:null},l=null;function m(a){return(a.includes("/")?a.split("/").pop():a).toLowerCase().split(":")[0]}function n(a,b){e().mkdirSync(g().dirname(a),{recursive:!0}),e().writeFileSync(`${a}.tmp`,b,"utf8"),e().renameSync(`${a}.tmp`,a)}async function o(){let[{default:a},{getCapabilitiesForModel:b,setCatalogSource:d}]=await Promise.all([c.e(8913).then(c.bind(c,8913)),c.e(8402).then(c.bind(c,38402))]);d(null);let e=[];for(let c of a)for(let a of c.models||[])e.push({provider:c.id,model:a.id,contextLength:a.contextLength,current:b(c.id,a.id)});return e}async function p(){if(k.running)return null;k.running=!0;try{let a,b={accept:"application/json"};k.etag&&k.fileVersion===h.$i&&(b["if-none-match"]=k.etag);let c=await fetch("https://models.dev/api.json",{headers:b,signal:AbortSignal.timeout(6e4)});if(304===c.status)a={status:"unchanged"};else if(c.ok){let b=await c.json(),d=c.headers.get("etag")||null,e=await o(),{models:f,providers:g}=function(a,b){let c=new Map;for(let{provider:a}of b){let b=j[a]||a,d=c.get(b);d||c.set(b,d=[]),d.includes(a)||d.push(a)}let d={},e={};for(let[b,f]of Object.entries(a)){let a=c.get(b)||[b],g={},h=new Set;for(let[c,d]of Object.entries(f?.models||{})){let f=m(c);if(g[f]=d,h.has(f))continue;h.add(f);let j={};for(let a of d?.modalities?.input||[]){let b=i[a];b&&(j[b]=!0)}if(Object.keys(j).length){for(let b of a)e[`${b}:${f}`]=j;a.includes(b)||(e[`${b}:${f}`]=j)}}d[b]=g}let f={};for(let{provider:c,model:e,contextLength:g,current:h}of b){let b=j[c],i=a[c]?c:b&&a[b]?b:null,k=i&&d[i]?.[m(e)];if(!k)continue;let l={},{context:n,output:o}=k.limit||{};n>0&&!g&&Math.abs(n-h.contextWindow)/h.contextWindow>.1&&(l.contextWindow=n),o>0&&Math.abs(o-h.maxOutput)/h.maxOutput>.1&&(l.maxOutput=o),Object.keys(l).length&&((f[c]||(f[c]={}))[e]=l)}return{models:e,providers:f}}(b,e),l=JSON.stringify({v:h.$i,etag:d,syncedAt:Date.now(),models:f,providers:g});n(h.l9,l),n(h.Ah,JSON.stringify(function(a){let b={};for(let[c,d]of Object.entries(a)){let a={};for(let[b,c]of Object.entries(d?.models||{}))a[b]={i:(c?.modalities?.input||[]).filter(a=>"text"!==a),c:c?.limit?.context,o:c?.limit?.output,r:c?.reasoning||void 0};b[c]=a}return b}(b))),k.etag=d,k.fileVersion=h.$i,(0,h.Pg)(),a={status:"updated",etag:d,bytes:Buffer.byteLength(l),models:Object.keys(f).length,providers:Object.keys(g).length},console.log(`[modelCatalog] ${a.models} models, ${a.providers} providers, ${(a.bytes/1024).toFixed(1)}KB`)}else throw Error(`HTTP ${c.status}`);return k.lastSync=Date.now(),k.lastError=null,k.lastResult=a,a}catch(a){return k.lastError=a?.message||String(a),console.log(`[modelCatalog] sync failed: ${k.lastError}`),null}finally{await (0,h.installCatalogSource)().catch(()=>{}),k.running=!1}}function q(){if(l||"off"===String(process.env.MODEL_CATALOG_SYNC||"").toLowerCase())return;try{let a=JSON.parse(e().readFileSync(h.l9,"utf8"));k.etag=a.etag||null,k.fileVersion=a.v||1,k.lastSync=e().statSync(h.l9).mtimeMs}catch{k.etag=null,k.fileVersion=null}let a=b=>{l=setTimeout(async()=>{a(await p()?864e5:18e5)},b),l.unref?.()};a(6e4)}}};
1
+ "use strict";exports.id=7716,exports.ids=[3726,7716],exports.modules={53726:(a,b,c)=>{c.d(b,{l9:()=>o,Ah:()=>p,$i:()=>q,installCatalogSource:()=>z,Pg:()=>y});var d=c(73024),e=c.n(d),f=c(76760),g=c.n(f),h=c(33873),i=c.n(h),j=c(21820),k=c.n(j);let l="omnihilbras";function m(){return"win32"===process.platform?i().join(process.env.APPDATA||i().join(k().homedir(),"AppData","Roaming"),l):i().join(k().homedir(),`.${l}`)}let n=function(){let a=process.env.DATA_DIR;if(!a)return m();if("win32"===process.platform&&/^\//.test(a))return console.warn(`[DATA_DIR] '${a}' is a Unix path on Windows → fallback to default`),m();try{e().mkdirSync(a,{recursive:!0,mode:448});try{e().chmodSync(a,448)}catch{}return a}catch(b){if(b?.code==="EACCES"||b?.code==="EPERM")return console.warn(`[DATA_DIR] '${a}' not writable → fallback ~/.${l}`),m();throw b}}(),o=g().join(n,"model-catalog.json"),p=g().join(n,"model-catalog-raw.json"),q=2,r={models:{},providers:{}},s=r,t=-1;function u(a){return a?(a.includes("/")?a.split("/").pop():a).toLowerCase().split(":")[0]:""}function v(){let a;try{a=e().statSync(o).mtimeMs}catch{return t=-1,s=r}if(a===t)return s;t=a;try{let a=JSON.parse(e().readFileSync(o,"utf8"));s={models:a?.models||{},providers:a?.providers||{}}}catch{s=r}return s}function w(a,b){return a&&v().models[`${a}:${u(b)}`]||null}function x(a,b){let c=a&&v().providers[a];return c&&(c[b]||c[u(b)])||null}function y(){t=-1}async function z(){let{setCatalogSource:a}=await c.e(8402).then(c.bind(c,38402));a({getModalities:w,getLimits:x})}},57716:(a,b,c)=>{c.d(b,{startModelCatalogSync:()=>q});var d=c(73024),e=c.n(d),f=c(76760),g=c.n(f),h=c(53726);let i={image:"vision",pdf:"pdf",audio:"audioInput",video:"videoInput"},j={github:"github-copilot",glm:"zai","glm-cn":"zhipuai",claude:"anthropic",gemini:"google",kimi:"moonshotai","kimi-cn":"moonshotai-cn",qwen:"alibaba","qwen-cn":"alibaba-cn",zhipu:"zhipuai",hunyuan:"tencent",doubao:"volcengine","cloudflare-ai":"cloudflare-workers-ai"},k={running:!1,lastSync:null,lastError:null,lastResult:null,etag:null,fileVersion:null},l=null;function m(a){return(a.includes("/")?a.split("/").pop():a).toLowerCase().split(":")[0]}function n(a,b){e().mkdirSync(g().dirname(a),{recursive:!0}),e().writeFileSync(`${a}.tmp`,b,"utf8"),e().renameSync(`${a}.tmp`,a)}async function o(){let[{default:a},{getCapabilitiesForModel:b,setCatalogSource:d}]=await Promise.all([c.e(8913).then(c.bind(c,8913)),c.e(8402).then(c.bind(c,38402))]);d(null);let e=[];for(let c of a)for(let a of c.models||[])e.push({provider:c.id,model:a.id,contextLength:a.contextLength,current:b(c.id,a.id)});return e}async function p(){if(k.running)return null;k.running=!0;try{let a,b={accept:"application/json"};k.etag&&k.fileVersion===h.$i&&(b["if-none-match"]=k.etag);let c=await fetch("https://models.dev/api.json",{headers:b,signal:AbortSignal.timeout(6e4)});if(304===c.status)a={status:"unchanged"};else if(c.ok){let b=await c.json(),d=c.headers.get("etag")||null,e=await o(),{models:f,providers:g}=function(a,b){let c=new Map;for(let{provider:a}of b){let b=j[a]||a,d=c.get(b);d||c.set(b,d=[]),d.includes(a)||d.push(a)}let d={},e={};for(let[b,f]of Object.entries(a)){let a=c.get(b)||[b],g={},h=new Set;for(let[c,d]of Object.entries(f?.models||{})){let f=m(c);if(g[f]=d,h.has(f))continue;h.add(f);let j={};for(let a of d?.modalities?.input||[]){let b=i[a];b&&(j[b]=!0)}if(Object.keys(j).length){for(let b of a)e[`${b}:${f}`]=j;a.includes(b)||(e[`${b}:${f}`]=j)}}d[b]=g}let f={};for(let{provider:c,model:e,contextLength:g,current:h}of b){let b=j[c],i=a[c]?c:b&&a[b]?b:null,k=i&&d[i]?.[m(e)];if(!k)continue;let l={},{context:n,output:o}=k.limit||{};n>0&&!g&&Math.abs(n-h.contextWindow)/h.contextWindow>.1&&(l.contextWindow=n),o>0&&Math.abs(o-h.maxOutput)/h.maxOutput>.1&&(l.maxOutput=o),Object.keys(l).length&&((f[c]||(f[c]={}))[e]=l)}return{models:e,providers:f}}(b,e),l=JSON.stringify({v:h.$i,etag:d,syncedAt:Date.now(),models:f,providers:g});n(h.l9,l),n(h.Ah,JSON.stringify(function(a){let b={};for(let[c,d]of Object.entries(a)){let a={};for(let[b,c]of Object.entries(d?.models||{}))a[b]={i:(c?.modalities?.input||[]).filter(a=>"text"!==a),c:c?.limit?.context,o:c?.limit?.output,r:c?.reasoning||void 0};b[c]=a}return b}(b))),k.etag=d,k.fileVersion=h.$i,(0,h.Pg)(),a={status:"updated",etag:d,bytes:Buffer.byteLength(l),models:Object.keys(f).length,providers:Object.keys(g).length},console.log(`[modelCatalog] ${a.models} models, ${a.providers} providers, ${(a.bytes/1024).toFixed(1)}KB`)}else throw Error(`HTTP ${c.status}`);return k.lastSync=Date.now(),k.lastError=null,k.lastResult=a,a}catch(a){return k.lastError=a?.message||String(a),console.log(`[modelCatalog] sync failed: ${k.lastError}`),null}finally{await (0,h.installCatalogSource)().catch(()=>{}),k.running=!1}}function q(){if(l||"off"===String(process.env.MODEL_CATALOG_SYNC||"").toLowerCase())return;try{let a=JSON.parse(e().readFileSync(h.l9,"utf8"));k.etag=a.etag||null,k.fileVersion=a.v||1,k.lastSync=e().statSync(h.l9).mtimeMs}catch{k.etag=null,k.fileVersion=null}let a=b=>{l=setTimeout(async()=>{a(await p()?864e5:18e5)},b),l.unref?.()};a(6e4)}}};
@@ -0,0 +1 @@
1
+ "use strict";exports.id=7955,exports.ids=[7955],exports.modules={37955:(a,b,c)=>{c.r(b),c.d(b,{runUsageRetentionOnce:()=>h,startUsageRetentionScheduler:()=>i,stopUsageRetentionScheduler:()=>j});var d=c(89718),e=c(47370);let f=null;function g(a,b){let c=Number(a);return Number.isFinite(c)&&c>0?Math.floor(c):b}async function h(){try{let a=await (0,d.mt)(),b=a?.usageRetention||{};if(!1===b.enabled)return null;let c=await (0,e.q3)(g(b.historyDays,90),g(b.dailyDays,400));return c&&(c.history>0||c.daily>0)&&console.log(`[UsageRetention] pruned ${c.history} history rows, ${c.daily} daily rows`),c}catch(a){return console.log("[UsageRetention] prune failed:",a?.message||a),null}}async function i(){if(f)return f;let a=36e5;try{let b=await (0,d.mt)();if(a=g(b?.usageRetention?.intervalMs,36e5),b?.usageRetention?.enabled===!1)return null}catch{}return f=setInterval(()=>{h().catch(()=>{})},a),f.unref?.(),h().catch(()=>{}),f}function j(){f&&(clearInterval(f),f=null)}},47370:(a,b,c)=>{c.d(b,{BY:()=>d.BY,Dv:()=>d.Dv,E5:()=>d.E5,SL:()=>d.SL,Zx:()=>d.Zx,_V:()=>d._V,cx:()=>d.cx,j$:()=>d.j$,ox:()=>d.ox,q3:()=>d.q3,rg:()=>d.rg,sZ:()=>d.sZ,uw:()=>d.uw});var d=c(47765)}};