ai-agent-router 0.1.21 → 0.2.1

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 (368) hide show
  1. package/.next/BUILD_ID +1 -1
  2. package/.next/app-path-routes-manifest.json +14 -0
  3. package/.next/build-manifest.json +2 -2
  4. package/.next/fallback-build-manifest.json +2 -2
  5. package/.next/routes-manifest.json +84 -0
  6. package/.next/server/app/_global-error/page.js +1 -1
  7. package/.next/server/app/_global-error/page.js.nft.json +1 -1
  8. package/.next/server/app/_global-error.html +2 -2
  9. package/.next/server/app/_global-error.rsc +1 -1
  10. package/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  11. package/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  12. package/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
  13. package/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
  14. package/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  15. package/.next/server/app/_not-found/page.js +1 -1
  16. package/.next/server/app/_not-found/page.js.nft.json +1 -1
  17. package/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  18. package/.next/server/app/_not-found.html +1 -1
  19. package/.next/server/app/_not-found.rsc +2 -2
  20. package/.next/server/app/_not-found.segments/_full.segment.rsc +2 -2
  21. package/.next/server/app/_not-found.segments/_head.segment.rsc +1 -1
  22. package/.next/server/app/_not-found.segments/_index.segment.rsc +2 -2
  23. package/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
  24. package/.next/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
  25. package/.next/server/app/_not-found.segments/_tree.segment.rsc +2 -2
  26. package/.next/server/app/api/config/route.js.nft.json +1 -1
  27. package/.next/server/app/api/gateway/[...path]/route.js.nft.json +1 -1
  28. package/.next/server/app/api/gateway/models/route.js.nft.json +1 -1
  29. package/.next/server/app/api/gateway/route.js.nft.json +1 -1
  30. package/.next/server/app/api/ide/claude/apply/route.js.nft.json +1 -1
  31. package/.next/server/app/api/ide/claude/available-models/route.js.nft.json +1 -1
  32. package/.next/server/app/api/ide/claude/save/route.js.nft.json +1 -1
  33. package/.next/server/app/api/ide/claude/status/route.js.nft.json +1 -1
  34. package/.next/server/app/api/ide/claude/test/route.js +1 -1
  35. package/.next/server/app/api/ide/claude/test/route.js.nft.json +1 -1
  36. package/.next/server/app/api/ide/openclaw/apply/route/app-paths-manifest.json +3 -0
  37. package/.next/server/app/api/ide/openclaw/apply/route/build-manifest.json +11 -0
  38. package/.next/server/app/api/ide/openclaw/apply/route/server-reference-manifest.json +4 -0
  39. package/.next/server/app/api/ide/openclaw/apply/route.js +7 -0
  40. package/.next/server/app/api/ide/openclaw/apply/route.js.map +5 -0
  41. package/.next/server/app/api/ide/openclaw/apply/route.js.nft.json +1 -0
  42. package/.next/server/app/api/ide/openclaw/apply/route_client-reference-manifest.js +2 -0
  43. package/.next/server/app/api/ide/openclaw/available-models/route/app-paths-manifest.json +3 -0
  44. package/.next/server/app/api/ide/openclaw/available-models/route/build-manifest.json +11 -0
  45. package/.next/server/app/api/ide/openclaw/available-models/route/server-reference-manifest.json +4 -0
  46. package/.next/server/app/api/ide/openclaw/available-models/route.js +7 -0
  47. package/.next/server/app/api/ide/openclaw/available-models/route.js.map +5 -0
  48. package/.next/server/app/api/ide/openclaw/available-models/route.js.nft.json +1 -0
  49. package/.next/server/app/api/ide/openclaw/available-models/route_client-reference-manifest.js +2 -0
  50. package/.next/server/app/api/ide/openclaw/preview/route/app-paths-manifest.json +3 -0
  51. package/.next/server/app/api/ide/openclaw/preview/route/build-manifest.json +11 -0
  52. package/.next/server/app/api/ide/openclaw/preview/route/server-reference-manifest.json +4 -0
  53. package/.next/server/app/api/ide/openclaw/preview/route.js +7 -0
  54. package/.next/server/app/api/ide/openclaw/preview/route.js.map +5 -0
  55. package/.next/server/app/api/ide/openclaw/preview/route.js.nft.json +1 -0
  56. package/.next/server/app/api/ide/openclaw/preview/route_client-reference-manifest.js +2 -0
  57. package/.next/server/app/api/ide/openclaw/restore/route/app-paths-manifest.json +3 -0
  58. package/.next/server/app/api/ide/openclaw/restore/route/build-manifest.json +11 -0
  59. package/.next/server/app/api/ide/openclaw/restore/route/server-reference-manifest.json +4 -0
  60. package/.next/server/app/api/ide/openclaw/restore/route.js +6 -0
  61. package/.next/server/app/api/ide/openclaw/restore/route.js.map +5 -0
  62. package/.next/server/app/api/ide/openclaw/restore/route.js.nft.json +1 -0
  63. package/.next/server/app/api/ide/openclaw/restore/route_client-reference-manifest.js +2 -0
  64. package/.next/server/app/api/ide/openclaw/save/route/app-paths-manifest.json +3 -0
  65. package/.next/server/app/api/ide/openclaw/save/route/build-manifest.json +11 -0
  66. package/.next/server/app/api/ide/openclaw/save/route/server-reference-manifest.json +4 -0
  67. package/.next/server/app/api/ide/openclaw/save/route.js +7 -0
  68. package/.next/server/app/api/ide/openclaw/save/route.js.map +5 -0
  69. package/.next/server/app/api/ide/openclaw/save/route.js.nft.json +1 -0
  70. package/.next/server/app/api/ide/openclaw/save/route_client-reference-manifest.js +2 -0
  71. package/.next/server/app/api/ide/openclaw/status/route/app-paths-manifest.json +3 -0
  72. package/.next/server/app/api/ide/openclaw/status/route/build-manifest.json +11 -0
  73. package/.next/server/app/api/ide/openclaw/status/route/server-reference-manifest.json +4 -0
  74. package/.next/server/app/api/ide/openclaw/status/route.js +7 -0
  75. package/.next/server/app/api/ide/openclaw/status/route.js.map +5 -0
  76. package/.next/server/app/api/ide/openclaw/status/route.js.nft.json +1 -0
  77. package/.next/server/app/api/ide/openclaw/status/route_client-reference-manifest.js +2 -0
  78. package/.next/server/app/api/ide/openclaw/test/route/app-paths-manifest.json +3 -0
  79. package/.next/server/app/api/ide/openclaw/test/route/build-manifest.json +11 -0
  80. package/.next/server/app/api/ide/openclaw/test/route/server-reference-manifest.json +4 -0
  81. package/.next/server/app/api/ide/openclaw/test/route.js +6 -0
  82. package/.next/server/app/api/ide/openclaw/test/route.js.map +5 -0
  83. package/.next/server/app/api/ide/openclaw/test/route.js.nft.json +1 -0
  84. package/.next/server/app/api/ide/openclaw/test/route_client-reference-manifest.js +2 -0
  85. package/.next/server/app/api/ide/opencode/apply/route/app-paths-manifest.json +3 -0
  86. package/.next/server/app/api/ide/opencode/apply/route/build-manifest.json +11 -0
  87. package/.next/server/app/api/ide/opencode/apply/route/server-reference-manifest.json +4 -0
  88. package/.next/server/app/api/ide/opencode/apply/route.js +7 -0
  89. package/.next/server/app/api/ide/opencode/apply/route.js.map +5 -0
  90. package/.next/server/app/api/ide/opencode/apply/route.js.nft.json +1 -0
  91. package/.next/server/app/api/ide/opencode/apply/route_client-reference-manifest.js +2 -0
  92. package/.next/server/app/api/ide/opencode/available-models/route/app-paths-manifest.json +3 -0
  93. package/.next/server/app/api/ide/opencode/available-models/route/build-manifest.json +11 -0
  94. package/.next/server/app/api/ide/opencode/available-models/route/server-reference-manifest.json +4 -0
  95. package/.next/server/app/api/ide/opencode/available-models/route.js +7 -0
  96. package/.next/server/app/api/ide/opencode/available-models/route.js.map +5 -0
  97. package/.next/server/app/api/ide/opencode/available-models/route.js.nft.json +1 -0
  98. package/.next/server/app/api/ide/opencode/available-models/route_client-reference-manifest.js +2 -0
  99. package/.next/server/app/api/ide/opencode/preview/route/app-paths-manifest.json +3 -0
  100. package/.next/server/app/api/ide/opencode/preview/route/build-manifest.json +11 -0
  101. package/.next/server/app/api/ide/opencode/preview/route/server-reference-manifest.json +4 -0
  102. package/.next/server/app/api/ide/opencode/preview/route.js +7 -0
  103. package/.next/server/app/api/ide/opencode/preview/route.js.map +5 -0
  104. package/.next/server/app/api/ide/opencode/preview/route.js.nft.json +1 -0
  105. package/.next/server/app/api/ide/opencode/preview/route_client-reference-manifest.js +2 -0
  106. package/.next/server/app/api/ide/opencode/restore/route/app-paths-manifest.json +3 -0
  107. package/.next/server/app/api/ide/opencode/restore/route/build-manifest.json +11 -0
  108. package/.next/server/app/api/ide/opencode/restore/route/server-reference-manifest.json +4 -0
  109. package/.next/server/app/api/ide/opencode/restore/route.js +6 -0
  110. package/.next/server/app/api/ide/opencode/restore/route.js.map +5 -0
  111. package/.next/server/app/api/ide/opencode/restore/route.js.nft.json +1 -0
  112. package/.next/server/app/api/ide/opencode/restore/route_client-reference-manifest.js +2 -0
  113. package/.next/server/app/api/ide/opencode/save/route/app-paths-manifest.json +3 -0
  114. package/.next/server/app/api/ide/opencode/save/route/build-manifest.json +11 -0
  115. package/.next/server/app/api/ide/opencode/save/route/server-reference-manifest.json +4 -0
  116. package/.next/server/app/api/ide/opencode/save/route.js +7 -0
  117. package/.next/server/app/api/ide/opencode/save/route.js.map +5 -0
  118. package/.next/server/app/api/ide/opencode/save/route.js.nft.json +1 -0
  119. package/.next/server/app/api/ide/opencode/save/route_client-reference-manifest.js +2 -0
  120. package/.next/server/app/api/ide/opencode/status/route/app-paths-manifest.json +3 -0
  121. package/.next/server/app/api/ide/opencode/status/route/build-manifest.json +11 -0
  122. package/.next/server/app/api/ide/opencode/status/route/server-reference-manifest.json +4 -0
  123. package/.next/server/app/api/ide/opencode/status/route.js +7 -0
  124. package/.next/server/app/api/ide/opencode/status/route.js.map +5 -0
  125. package/.next/server/app/api/ide/opencode/status/route.js.nft.json +1 -0
  126. package/.next/server/app/api/ide/opencode/status/route_client-reference-manifest.js +2 -0
  127. package/.next/server/app/api/ide/opencode/test/route/app-paths-manifest.json +3 -0
  128. package/.next/server/app/api/ide/opencode/test/route/build-manifest.json +11 -0
  129. package/.next/server/app/api/ide/opencode/test/route/server-reference-manifest.json +4 -0
  130. package/.next/server/app/api/ide/opencode/test/route.js +6 -0
  131. package/.next/server/app/api/ide/opencode/test/route.js.map +5 -0
  132. package/.next/server/app/api/ide/opencode/test/route.js.nft.json +1 -0
  133. package/.next/server/app/api/ide/opencode/test/route_client-reference-manifest.js +2 -0
  134. package/.next/server/app/api/logs/route.js.nft.json +1 -1
  135. package/.next/server/app/api/models/route.js.nft.json +1 -1
  136. package/.next/server/app/api/providers/route.js.nft.json +1 -1
  137. package/.next/server/app/api/providers/test/route.js.nft.json +1 -1
  138. package/.next/server/app/api/service/force-stop/route.js.nft.json +1 -1
  139. package/.next/server/app/api/service/start/route.js.nft.json +1 -1
  140. package/.next/server/app/api/service/status/route.js.nft.json +1 -1
  141. package/.next/server/app/api/service/stop/route.js.nft.json +1 -1
  142. package/.next/server/app/ide/page.js +1 -1
  143. package/.next/server/app/ide/page.js.nft.json +1 -1
  144. package/.next/server/app/ide/page_client-reference-manifest.js +1 -1
  145. package/.next/server/app/ide.html +1 -1
  146. package/.next/server/app/ide.rsc +3 -3
  147. package/.next/server/app/ide.segments/_full.segment.rsc +3 -3
  148. package/.next/server/app/ide.segments/_head.segment.rsc +1 -1
  149. package/.next/server/app/ide.segments/_index.segment.rsc +2 -2
  150. package/.next/server/app/ide.segments/_tree.segment.rsc +2 -2
  151. package/.next/server/app/ide.segments/ide/__PAGE__.segment.rsc +2 -2
  152. package/.next/server/app/ide.segments/ide.segment.rsc +1 -1
  153. package/.next/server/app/index.html +1 -1
  154. package/.next/server/app/index.rsc +2 -2
  155. package/.next/server/app/index.segments/__PAGE__.segment.rsc +1 -1
  156. package/.next/server/app/index.segments/_full.segment.rsc +2 -2
  157. package/.next/server/app/index.segments/_head.segment.rsc +1 -1
  158. package/.next/server/app/index.segments/_index.segment.rsc +2 -2
  159. package/.next/server/app/index.segments/_tree.segment.rsc +2 -2
  160. package/.next/server/app/logs/page.js +1 -1
  161. package/.next/server/app/logs/page.js.nft.json +1 -1
  162. package/.next/server/app/logs/page_client-reference-manifest.js +1 -1
  163. package/.next/server/app/logs.html +1 -1
  164. package/.next/server/app/logs.rsc +3 -3
  165. package/.next/server/app/logs.segments/_full.segment.rsc +3 -3
  166. package/.next/server/app/logs.segments/_head.segment.rsc +1 -1
  167. package/.next/server/app/logs.segments/_index.segment.rsc +2 -2
  168. package/.next/server/app/logs.segments/_tree.segment.rsc +2 -2
  169. package/.next/server/app/logs.segments/logs/__PAGE__.segment.rsc +2 -2
  170. package/.next/server/app/logs.segments/logs.segment.rsc +1 -1
  171. package/.next/server/app/models/page.js +1 -1
  172. package/.next/server/app/models/page.js.nft.json +1 -1
  173. package/.next/server/app/models/page_client-reference-manifest.js +1 -1
  174. package/.next/server/app/models.html +1 -1
  175. package/.next/server/app/models.rsc +2 -2
  176. package/.next/server/app/models.segments/_full.segment.rsc +2 -2
  177. package/.next/server/app/models.segments/_head.segment.rsc +1 -1
  178. package/.next/server/app/models.segments/_index.segment.rsc +2 -2
  179. package/.next/server/app/models.segments/_tree.segment.rsc +2 -2
  180. package/.next/server/app/models.segments/models/__PAGE__.segment.rsc +1 -1
  181. package/.next/server/app/models.segments/models.segment.rsc +1 -1
  182. package/.next/server/app/page.js +1 -1
  183. package/.next/server/app/page.js.nft.json +1 -1
  184. package/.next/server/app/page_client-reference-manifest.js +1 -1
  185. package/.next/server/app/providers/page.js +1 -1
  186. package/.next/server/app/providers/page.js.nft.json +1 -1
  187. package/.next/server/app/providers/page_client-reference-manifest.js +1 -1
  188. package/.next/server/app/providers.html +1 -1
  189. package/.next/server/app/providers.rsc +2 -2
  190. package/.next/server/app/providers.segments/_full.segment.rsc +2 -2
  191. package/.next/server/app/providers.segments/_head.segment.rsc +1 -1
  192. package/.next/server/app/providers.segments/_index.segment.rsc +2 -2
  193. package/.next/server/app/providers.segments/_tree.segment.rsc +2 -2
  194. package/.next/server/app/providers.segments/providers/__PAGE__.segment.rsc +1 -1
  195. package/.next/server/app/providers.segments/providers.segment.rsc +1 -1
  196. package/.next/server/app-paths-manifest.json +14 -0
  197. package/.next/server/chunks/[root-of-the-server]__001d5756._.js +3 -0
  198. package/.next/server/chunks/[root-of-the-server]__001d5756._.js.map +1 -0
  199. package/.next/server/chunks/[root-of-the-server]__05f8578b._.js +3 -0
  200. package/.next/server/chunks/[root-of-the-server]__05f8578b._.js.map +1 -0
  201. package/.next/server/chunks/[root-of-the-server]__1480f018._.js +1 -1
  202. package/.next/server/chunks/[root-of-the-server]__1480f018._.js.map +1 -1
  203. package/.next/server/chunks/[root-of-the-server]__1909f3aa._.js +1 -1
  204. package/.next/server/chunks/[root-of-the-server]__1909f3aa._.js.map +1 -1
  205. package/.next/server/chunks/[root-of-the-server]__1d4b7fc5._.js +1 -1
  206. package/.next/server/chunks/[root-of-the-server]__1d4b7fc5._.js.map +1 -1
  207. package/.next/server/chunks/[root-of-the-server]__372ef2bf._.js +1 -1
  208. package/.next/server/chunks/[root-of-the-server]__372ef2bf._.js.map +1 -1
  209. package/.next/server/chunks/[root-of-the-server]__3aaf963c._.js +1 -1
  210. package/.next/server/chunks/[root-of-the-server]__3aaf963c._.js.map +1 -1
  211. package/.next/server/chunks/[root-of-the-server]__43810962._.js +3 -0
  212. package/.next/server/chunks/[root-of-the-server]__43810962._.js.map +1 -0
  213. package/.next/server/chunks/[root-of-the-server]__55cd88b8._.js +3 -0
  214. package/.next/server/chunks/[root-of-the-server]__55cd88b8._.js.map +1 -0
  215. package/.next/server/chunks/[root-of-the-server]__5e8276bc._.js +1 -1
  216. package/.next/server/chunks/[root-of-the-server]__5e8276bc._.js.map +1 -1
  217. package/.next/server/chunks/[root-of-the-server]__6ce199d2._.js +1 -1
  218. package/.next/server/chunks/[root-of-the-server]__6ce199d2._.js.map +1 -1
  219. package/.next/server/chunks/[root-of-the-server]__760eaa16._.js +3 -0
  220. package/.next/server/chunks/[root-of-the-server]__760eaa16._.js.map +1 -0
  221. package/.next/server/chunks/[root-of-the-server]__772134c6._.js +1 -1
  222. package/.next/server/chunks/[root-of-the-server]__772134c6._.js.map +1 -1
  223. package/.next/server/chunks/[root-of-the-server]__7b77f523._.js +1 -1
  224. package/.next/server/chunks/[root-of-the-server]__7b77f523._.js.map +1 -1
  225. package/.next/server/chunks/[root-of-the-server]__7c298a19._.js +3 -0
  226. package/.next/server/chunks/[root-of-the-server]__7c298a19._.js.map +1 -0
  227. package/.next/server/chunks/[root-of-the-server]__85540228._.js +3 -0
  228. package/.next/server/chunks/[root-of-the-server]__85540228._.js.map +1 -0
  229. package/.next/server/chunks/[root-of-the-server]__94fe8d3c._.js +3 -0
  230. package/.next/server/chunks/[root-of-the-server]__94fe8d3c._.js.map +1 -0
  231. package/.next/server/chunks/[root-of-the-server]__97622908._.js +3 -0
  232. package/.next/server/chunks/[root-of-the-server]__97622908._.js.map +1 -0
  233. package/.next/server/chunks/[root-of-the-server]__a02e6618._.js +3 -0
  234. package/.next/server/chunks/[root-of-the-server]__a02e6618._.js.map +1 -0
  235. package/.next/server/chunks/[root-of-the-server]__a32a20a7._.js +3 -0
  236. package/.next/server/chunks/[root-of-the-server]__a32a20a7._.js.map +1 -0
  237. package/.next/server/chunks/[root-of-the-server]__af5b556a._.js +3 -0
  238. package/.next/server/chunks/[root-of-the-server]__af5b556a._.js.map +1 -0
  239. package/.next/server/chunks/[root-of-the-server]__c1b4b601._.js +18 -18
  240. package/.next/server/chunks/[root-of-the-server]__c1b4b601._.js.map +1 -1
  241. package/.next/server/chunks/[root-of-the-server]__cafe113e._.js +3 -0
  242. package/.next/server/chunks/[root-of-the-server]__cafe113e._.js.map +1 -0
  243. package/.next/server/chunks/[root-of-the-server]__ccfc7f1d._.js +1 -1
  244. package/.next/server/chunks/[root-of-the-server]__ccfc7f1d._.js.map +1 -1
  245. package/.next/server/chunks/[root-of-the-server]__dc8b0bed._.js +3 -0
  246. package/.next/server/chunks/[root-of-the-server]__dc8b0bed._.js.map +1 -0
  247. package/.next/server/chunks/[root-of-the-server]__f8949f88._.js +1 -1
  248. package/.next/server/chunks/[root-of-the-server]__f8949f88._.js.map +1 -1
  249. package/.next/server/chunks/_next-internal_server_app_api_ide_openclaw_apply_route_actions_2cb9e4b4.js +3 -0
  250. package/.next/server/chunks/_next-internal_server_app_api_ide_openclaw_apply_route_actions_2cb9e4b4.js.map +1 -0
  251. package/.next/server/chunks/_next-internal_server_app_api_ide_openclaw_preview_route_actions_9814a8e4.js +3 -0
  252. package/.next/server/chunks/_next-internal_server_app_api_ide_openclaw_preview_route_actions_9814a8e4.js.map +1 -0
  253. package/.next/server/chunks/_next-internal_server_app_api_ide_openclaw_restore_route_actions_10ad8f9d.js +3 -0
  254. package/.next/server/chunks/_next-internal_server_app_api_ide_openclaw_restore_route_actions_10ad8f9d.js.map +1 -0
  255. package/.next/server/chunks/_next-internal_server_app_api_ide_openclaw_save_route_actions_044ad081.js +3 -0
  256. package/.next/server/chunks/_next-internal_server_app_api_ide_openclaw_save_route_actions_044ad081.js.map +1 -0
  257. package/.next/server/chunks/_next-internal_server_app_api_ide_openclaw_status_route_actions_ed9786d2.js +3 -0
  258. package/.next/server/chunks/_next-internal_server_app_api_ide_openclaw_status_route_actions_ed9786d2.js.map +1 -0
  259. package/.next/server/chunks/_next-internal_server_app_api_ide_openclaw_test_route_actions_ce2cb808.js +3 -0
  260. package/.next/server/chunks/_next-internal_server_app_api_ide_openclaw_test_route_actions_ce2cb808.js.map +1 -0
  261. package/.next/server/chunks/_next-internal_server_app_api_ide_opencode_apply_route_actions_6c422244.js +3 -0
  262. package/.next/server/chunks/_next-internal_server_app_api_ide_opencode_apply_route_actions_6c422244.js.map +1 -0
  263. package/.next/server/chunks/_next-internal_server_app_api_ide_opencode_preview_route_actions_256c82e0.js +3 -0
  264. package/.next/server/chunks/_next-internal_server_app_api_ide_opencode_preview_route_actions_256c82e0.js.map +1 -0
  265. package/.next/server/chunks/_next-internal_server_app_api_ide_opencode_restore_route_actions_371993d3.js +3 -0
  266. package/.next/server/chunks/_next-internal_server_app_api_ide_opencode_restore_route_actions_371993d3.js.map +1 -0
  267. package/.next/server/chunks/_next-internal_server_app_api_ide_opencode_save_route_actions_6e4c9c41.js +3 -0
  268. package/.next/server/chunks/_next-internal_server_app_api_ide_opencode_save_route_actions_6e4c9c41.js.map +1 -0
  269. package/.next/server/chunks/_next-internal_server_app_api_ide_opencode_status_route_actions_498ad77b.js +3 -0
  270. package/.next/server/chunks/_next-internal_server_app_api_ide_opencode_status_route_actions_498ad77b.js.map +1 -0
  271. package/.next/server/chunks/_next-internal_server_app_api_ide_opencode_test_route_actions_c71be510.js +3 -0
  272. package/.next/server/chunks/_next-internal_server_app_api_ide_opencode_test_route_actions_c71be510.js.map +1 -0
  273. package/.next/server/chunks/ce889_server_app_api_ide_openclaw_available-models_route_actions_e568e70b.js +3 -0
  274. package/.next/server/chunks/ce889_server_app_api_ide_openclaw_available-models_route_actions_e568e70b.js.map +1 -0
  275. package/.next/server/chunks/ce889_server_app_api_ide_opencode_available-models_route_actions_95230db3.js +3 -0
  276. package/.next/server/chunks/ce889_server_app_api_ide_opencode_available-models_route_actions_95230db3.js.map +1 -0
  277. package/.next/server/chunks/ssr/{[root-of-the-server]__bec95712._.js → [root-of-the-server]__81937253._.js} +2 -2
  278. package/.next/server/chunks/ssr/{[root-of-the-server]__bec95712._.js.map → [root-of-the-server]__81937253._.js.map} +1 -1
  279. package/.next/server/chunks/ssr/{[root-of-the-server]__71c85955._.js → [root-of-the-server]__976ad963._.js} +2 -2
  280. package/.next/server/chunks/ssr/{[root-of-the-server]__71c85955._.js.map → [root-of-the-server]__976ad963._.js.map} +1 -1
  281. package/.next/server/chunks/ssr/src_app_ide_page_tsx_8962793b._.js +1 -1
  282. package/.next/server/chunks/ssr/src_app_ide_page_tsx_8962793b._.js.map +1 -1
  283. package/.next/server/chunks/ssr/src_app_logs_page_tsx_7b7b7b83._.js +1 -1
  284. package/.next/server/chunks/ssr/src_app_logs_page_tsx_7b7b7b83._.js.map +1 -1
  285. package/.next/server/pages/404.html +1 -1
  286. package/.next/server/pages/500.html +2 -2
  287. package/.next/static/chunks/0f120c117962200b.css +1 -0
  288. package/.next/static/chunks/64f547b3bcd3aef4.js +1 -0
  289. package/.next/static/chunks/{81c904164fe81379.js → 7c8b7cbb3339f139.js} +1 -1
  290. package/.next/static/chunks/8ed839b2e4948968.js +1 -0
  291. package/.next/types/routes.d.ts +15 -1
  292. package/.next/types/validator.ts +126 -0
  293. package/README.md +100 -111
  294. package/dist/.next/dev/types/validator.js +56 -0
  295. package/dist/.next/types/validator.js +56 -0
  296. package/dist/src/app/api/gateway/[...path]/route.js +1 -1
  297. package/dist/src/app/api/gateway/route.js +1 -1
  298. package/dist/src/app/api/ide/claude/apply/route.js +42 -31
  299. package/dist/src/app/api/ide/claude/status/route.js +6 -1
  300. package/dist/src/app/api/ide/openclaw/apply/route.js +92 -0
  301. package/dist/src/app/api/ide/openclaw/available-models/route.js +46 -0
  302. package/dist/src/app/api/ide/openclaw/build-config.js +101 -0
  303. package/dist/src/app/api/ide/openclaw/preview/route.js +49 -0
  304. package/dist/src/app/api/ide/openclaw/restore/route.js +24 -0
  305. package/dist/src/app/api/ide/openclaw/save/route.js +54 -0
  306. package/dist/src/app/api/ide/openclaw/status/route.js +139 -0
  307. package/dist/src/app/api/ide/openclaw/test/route.js +158 -0
  308. package/dist/src/app/api/ide/opencode/apply/route.js +89 -0
  309. package/dist/src/app/api/ide/opencode/available-models/route.js +46 -0
  310. package/dist/src/app/api/ide/opencode/build-config.js +54 -0
  311. package/dist/src/app/api/ide/opencode/preview/route.js +36 -0
  312. package/dist/src/app/api/ide/opencode/restore/route.js +40 -0
  313. package/dist/src/app/api/ide/opencode/save/route.js +123 -0
  314. package/dist/src/app/api/ide/opencode/status/route.js +106 -0
  315. package/dist/src/app/api/ide/opencode/test/route.js +136 -0
  316. package/dist/src/app/api/logs/route.js +2 -2
  317. package/dist/src/app/api/models/route.js +5 -5
  318. package/dist/src/app/api/providers/route.js +4 -4
  319. package/dist/src/app/api/providers/test/route.js +1 -1
  320. package/dist/src/app/api/service/start/route.js +1 -1
  321. package/dist/src/app/api/service/status/route.js +1 -1
  322. package/dist/src/app/api/service/stop/route.js +1 -1
  323. package/dist/src/app/ide/page.js +591 -81
  324. package/dist/src/app/logs/page.js +15 -1
  325. package/dist/src/cli/index.js +218 -20
  326. package/dist/src/db/database.js +56 -5
  327. package/dist/src/db/queries.js +6 -6
  328. package/dist/src/server/logger.js +22 -4
  329. package/package.json +2 -1
  330. package/src/app/api/gateway/[...path]/route.ts +1 -1
  331. package/src/app/api/gateway/route.ts +1 -1
  332. package/src/app/api/ide/claude/apply/route.ts +46 -31
  333. package/src/app/api/ide/claude/status/route.ts +12 -2
  334. package/src/app/api/ide/openclaw/apply/route.ts +103 -0
  335. package/src/app/api/ide/openclaw/available-models/route.ts +59 -0
  336. package/src/app/api/ide/openclaw/build-config.ts +152 -0
  337. package/src/app/api/ide/openclaw/preview/route.ts +57 -0
  338. package/src/app/api/ide/openclaw/restore/route.ts +27 -0
  339. package/src/app/api/ide/openclaw/save/route.ts +67 -0
  340. package/src/app/api/ide/openclaw/status/route.ts +178 -0
  341. package/src/app/api/ide/openclaw/test/route.ts +194 -0
  342. package/src/app/api/ide/opencode/apply/route.ts +92 -0
  343. package/src/app/api/ide/opencode/available-models/route.ts +59 -0
  344. package/src/app/api/ide/opencode/build-config.ts +69 -0
  345. package/src/app/api/ide/opencode/preview/route.ts +40 -0
  346. package/src/app/api/ide/opencode/restore/route.ts +52 -0
  347. package/src/app/api/ide/opencode/save/route.ts +131 -0
  348. package/src/app/api/ide/opencode/status/route.ts +128 -0
  349. package/src/app/api/ide/opencode/test/route.ts +145 -0
  350. package/src/app/api/logs/route.ts +2 -2
  351. package/src/app/api/models/route.ts +5 -5
  352. package/src/app/api/providers/route.ts +4 -4
  353. package/src/app/api/providers/test/route.ts +1 -1
  354. package/src/app/api/service/start/route.ts +1 -1
  355. package/src/app/api/service/status/route.ts +1 -1
  356. package/src/app/api/service/stop/route.ts +1 -1
  357. package/src/app/globals.css +17 -0
  358. package/src/app/ide/page.tsx +1535 -132
  359. package/src/app/logs/page.tsx +17 -5
  360. package/src/cli/index.ts +228 -25
  361. package/src/db/database.ts +60 -8
  362. package/src/db/queries.ts +6 -6
  363. package/src/server/logger.ts +19 -4
  364. package/.next/static/chunks/6418ca50028376b7.css +0 -1
  365. package/.next/static/chunks/9ec3b97741b6575e.js +0 -1
  366. /package/.next/static/{PkfqdzwOZgX-UhSNUuhdp → dYin74gcpdlg8TGoGv-_d}/_buildManifest.js +0 -0
  367. /package/.next/static/{PkfqdzwOZgX-UhSNUuhdp → dYin74gcpdlg8TGoGv-_d}/_clientMiddlewareManifest.json +0 -0
  368. /package/.next/static/{PkfqdzwOZgX-UhSNUuhdp → dYin74gcpdlg8TGoGv-_d}/_ssgManifest.js +0 -0
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/app/api/ide/openclaw/test/route.ts","../../../node_modules/next/dist/esm/build/templates/app-route.js"],"sourcesContent":["import { NextRequest, NextResponse } from 'next/server';\nimport { existsSync, readFileSync } from 'fs';\nimport { join } from 'path';\nimport { homedir } from 'os';\nimport { spawn } from 'child_process';\n\nconst OPENCLAW_DIR = join(homedir(), '.openclaw');\nconst OPENCLAW_FILE = join(OPENCLAW_DIR, 'openclaw.json');\n\nconst RUN_TIMEOUT_MS = 30_000;\n\ninterface TestResult {\n success: boolean;\n error?: string;\n message?: string;\n checks?: Record<string, boolean>;\n configSummary?: {\n baseUrl?: string;\n apiKey?: string;\n routerProvider?: string;\n primaryModel?: string;\n fallbackModels?: string[];\n imageModel?: string;\n fallbackImageModels?: string[];\n };\n probeResult?: {\n success: boolean;\n stdout: string;\n stderr: string;\n error?: string;\n };\n}\n\nfunction runCommand(args: string[]): Promise<{ success: boolean; stdout: string; stderr: string; error?: string; code?: number }> {\n return new Promise((resolve) => {\n const child = spawn('openclaw', args, {\n shell: process.platform === 'win32',\n stdio: ['ignore', 'pipe', 'pipe'],\n });\n\n let stdout = '';\n let stderr = '';\n\n child.stdout?.on('data', (chunk: Buffer) => {\n stdout += chunk.toString('utf-8');\n });\n child.stderr?.on('data', (chunk: Buffer) => {\n stderr += chunk.toString('utf-8');\n });\n\n child.on('error', (err) => {\n resolve({ success: false, stdout, stderr, error: err.message });\n });\n\n child.on('close', (code) => {\n resolve({ success: code === 0, stdout, stderr, code: code ?? undefined });\n });\n\n setTimeout(() => {\n if (!child.killed) {\n child.kill();\n resolve({ success: false, stdout, stderr, error: 'Timeout' });\n }\n }, RUN_TIMEOUT_MS);\n });\n}\n\nfunction maskApiKey(apiKey: string): string {\n if (!apiKey || apiKey === 'your-gateway-api-key') return apiKey;\n if (apiKey.length <= 8) return apiKey.slice(0, 2) + '***' + apiKey.slice(-2);\n return apiKey.slice(0, 4) + '****' + apiKey.slice(-4);\n}\n\nexport async function GET(request: NextRequest) {\n try {\n // Check config file exists\n if (!existsSync(OPENCLAW_FILE)) {\n return NextResponse.json({\n success: false,\n error: 'Configuration file not found',\n suggestion: 'Please apply configuration first',\n } as TestResult);\n }\n\n const content = readFileSync(OPENCLAW_FILE, 'utf-8');\n let config: any;\n try {\n config = JSON.parse(content);\n } catch {\n return NextResponse.json({\n success: false,\n error: 'Invalid configuration format',\n } as TestResult);\n }\n\n // Extract config summary\n const modelsConfig = config.models || {};\n const providers = modelsConfig.providers || {};\n const aarProvider = providers['aar-gateway'];\n\n const configSummary: TestResult['configSummary'] = {\n baseUrl: aarProvider?.baseUrl,\n apiKey: maskApiKey(aarProvider?.apiKey || ''),\n routerProvider: aarProvider ? 'aar' : undefined,\n };\n\n const primaryModel = config.agents?.defaults?.model?.primary;\n if (primaryModel) {\n configSummary.primaryModel = primaryModel;\n }\n\n const fallbackModels = config.agents?.defaults?.model?.fallbacks;\n if (Array.isArray(fallbackModels)) {\n configSummary.fallbackModels = fallbackModels;\n }\n\n const imageModel = config.agents?.defaults?.imageModel?.primary;\n if (imageModel) {\n configSummary.imageModel = imageModel;\n }\n\n const fallbackImageModels = config.agents?.defaults?.imageModel?.fallbacks;\n if (Array.isArray(fallbackImageModels)) {\n configSummary.fallbackImageModels = fallbackImageModels;\n }\n\n // Run probe command to test provider accessibility\n const probeResult = await runCommand([\n 'models', 'status',\n '--probe',\n '--probe-provider', 'aar-gateway',\n '--json'\n ]);\n\n let probeSuccess = false;\n let probeMessage = 'Provider not found or not accessible';\n\n if (probeResult.success) {\n // Try to parse JSON output\n try {\n const parsed = JSON.parse(probeResult.stdout);\n // Check if probe was successful\n probeSuccess = parsed?.success === true || parsed?.status === 'ok';\n if (probeSuccess) {\n probeMessage = 'Provider is accessible and responding';\n } else {\n probeMessage = parsed?.message || 'Probe returned unsuccessful status';\n }\n } catch {\n // If not JSON, check for success indicators in text\n probeSuccess = probeResult.stdout.toLowerCase().includes('ok') ||\n probeResult.stdout.toLowerCase().includes('success') ||\n probeResult.stdout.toLowerCase().includes('aar-gateway');\n probeMessage = probeSuccess\n ? 'Provider is accessible'\n : 'Could not verify provider status';\n }\n } else {\n probeMessage = probeResult.error || `Command failed (code ${probeResult.code})`;\n }\n\n const checks: Record<string, boolean> = {\n hasBaseUrl: !!aarProvider?.baseUrl,\n hasApiKey: !!aarProvider?.apiKey && aarProvider?.apiKey !== 'your-gateway-api-key',\n hasModels: Array.isArray(aarProvider?.models) && aarProvider.models.length > 0,\n hasPrimaryModel: !!primaryModel,\n hasProvider: !!aarProvider,\n probeSuccess,\n };\n\n const success = checks.hasBaseUrl && checks.hasApiKey && checks.hasProvider && probeSuccess;\n\n const result: TestResult = {\n success,\n message: success ? 'Configuration verified successfully' : 'Configuration verification failed',\n checks,\n configSummary,\n probeResult: {\n success: probeSuccess,\n stdout: probeResult.stdout.slice(-3000),\n stderr: probeResult.stderr.slice(-500),\n error: probeResult.error,\n },\n };\n\n return NextResponse.json(result);\n } catch (error: any) {\n console.error('OpenClaw Test API error:', error);\n return NextResponse.json({\n success: false,\n error: error.message || 'Internal server error',\n } as TestResult);\n }\n}\n","import { AppRouteRouteModule } from \"next/dist/esm/server/route-modules/app-route/module.compiled\";\nimport { RouteKind } from \"next/dist/esm/server/route-kind\";\nimport { patchFetch as _patchFetch } from \"next/dist/esm/server/lib/patch-fetch\";\nimport { addRequestMeta, getRequestMeta } from \"next/dist/esm/server/request-meta\";\nimport { getTracer, SpanKind } from \"next/dist/esm/server/lib/trace/tracer\";\nimport { setManifestsSingleton } from \"next/dist/esm/server/app-render/manifests-singleton\";\nimport { normalizeAppPath } from \"next/dist/esm/shared/lib/router/utils/app-paths\";\nimport { NodeNextRequest, NodeNextResponse } from \"next/dist/esm/server/base-http/node\";\nimport { NextRequestAdapter, signalFromNodeResponse } from \"next/dist/esm/server/web/spec-extension/adapters/next-request\";\nimport { BaseServerSpan } from \"next/dist/esm/server/lib/trace/constants\";\nimport { getRevalidateReason } from \"next/dist/esm/server/instrumentation/utils\";\nimport { sendResponse } from \"next/dist/esm/server/send-response\";\nimport { fromNodeOutgoingHttpHeaders, toNodeOutgoingHttpHeaders } from \"next/dist/esm/server/web/utils\";\nimport { getCacheControlHeader } from \"next/dist/esm/server/lib/cache-control\";\nimport { INFINITE_CACHE, NEXT_CACHE_TAGS_HEADER } from \"next/dist/esm/lib/constants\";\nimport { NoFallbackError } from \"next/dist/esm/shared/lib/no-fallback-error.external\";\nimport { CachedRouteKind } from \"next/dist/esm/server/response-cache\";\nimport * as userland from \"INNER_APP_ROUTE\";\n// We inject the nextConfigOutput here so that we can use them in the route\n// module.\nconst nextConfigOutput = \"\"\nconst routeModule = new AppRouteRouteModule({\n definition: {\n kind: RouteKind.APP_ROUTE,\n page: \"/api/ide/openclaw/test/route\",\n pathname: \"/api/ide/openclaw/test\",\n filename: \"route\",\n bundlePath: \"\"\n },\n distDir: process.env.__NEXT_RELATIVE_DIST_DIR || '',\n relativeProjectDir: process.env.__NEXT_RELATIVE_PROJECT_DIR || '',\n resolvedPagePath: \"[project]/src/app/api/ide/openclaw/test/route.ts\",\n nextConfigOutput,\n userland\n});\n// Pull out the exports that we need to expose from the module. This should\n// be eliminated when we've moved the other routes to the new format. These\n// are used to hook into the route.\nconst { workAsyncStorage, workUnitAsyncStorage, serverHooks } = routeModule;\nfunction patchFetch() {\n return _patchFetch({\n workAsyncStorage,\n workUnitAsyncStorage\n });\n}\nexport { routeModule, workAsyncStorage, workUnitAsyncStorage, serverHooks, patchFetch, };\nexport async function handler(req, res, ctx) {\n if (routeModule.isDev) {\n addRequestMeta(req, 'devRequestTimingInternalsEnd', process.hrtime.bigint());\n }\n let srcPage = \"/api/ide/openclaw/test/route\";\n // turbopack doesn't normalize `/index` in the page name\n // so we need to to process dynamic routes properly\n // TODO: fix turbopack providing differing value from webpack\n if (process.env.TURBOPACK) {\n srcPage = srcPage.replace(/\\/index$/, '') || '/';\n } else if (srcPage === '/index') {\n // we always normalize /index specifically\n srcPage = '/';\n }\n const multiZoneDraftMode = process.env.__NEXT_MULTI_ZONE_DRAFT_MODE;\n const prepareResult = await routeModule.prepare(req, res, {\n srcPage,\n multiZoneDraftMode\n });\n if (!prepareResult) {\n res.statusCode = 400;\n res.end('Bad Request');\n ctx.waitUntil == null ? void 0 : ctx.waitUntil.call(ctx, Promise.resolve());\n return null;\n }\n const { buildId, params, nextConfig, parsedUrl, isDraftMode, prerenderManifest, routerServerContext, isOnDemandRevalidate, revalidateOnlyGenerated, resolvedPathname, clientReferenceManifest, serverActionsManifest } = prepareResult;\n const normalizedSrcPage = normalizeAppPath(srcPage);\n let isIsr = Boolean(prerenderManifest.dynamicRoutes[normalizedSrcPage] || prerenderManifest.routes[resolvedPathname]);\n const render404 = async ()=>{\n // TODO: should route-module itself handle rendering the 404\n if (routerServerContext == null ? void 0 : routerServerContext.render404) {\n await routerServerContext.render404(req, res, parsedUrl, false);\n } else {\n res.end('This page could not be found');\n }\n return null;\n };\n if (isIsr && !isDraftMode) {\n const isPrerendered = Boolean(prerenderManifest.routes[resolvedPathname]);\n const prerenderInfo = prerenderManifest.dynamicRoutes[normalizedSrcPage];\n if (prerenderInfo) {\n if (prerenderInfo.fallback === false && !isPrerendered) {\n if (nextConfig.experimental.adapterPath) {\n return await render404();\n }\n throw new NoFallbackError();\n }\n }\n }\n let cacheKey = null;\n if (isIsr && !routeModule.isDev && !isDraftMode) {\n cacheKey = resolvedPathname;\n // ensure /index and / is normalized to one key\n cacheKey = cacheKey === '/index' ? '/' : cacheKey;\n }\n const supportsDynamicResponse = // If we're in development, we always support dynamic HTML\n routeModule.isDev === true || // If this is not SSG or does not have static paths, then it supports\n // dynamic HTML.\n !isIsr;\n // This is a revalidation request if the request is for a static\n // page and it is not being resumed from a postponed render and\n // it is not a dynamic RSC request then it is a revalidation\n // request.\n const isStaticGeneration = isIsr && !supportsDynamicResponse;\n // Before rendering (which initializes component tree modules), we have to\n // set the reference manifests to our global store so Server Action's\n // encryption util can access to them at the top level of the page module.\n if (serverActionsManifest && clientReferenceManifest) {\n setManifestsSingleton({\n page: srcPage,\n clientReferenceManifest,\n serverActionsManifest\n });\n }\n const method = req.method || 'GET';\n const tracer = getTracer();\n const activeSpan = tracer.getActiveScopeSpan();\n const context = {\n params,\n prerenderManifest,\n renderOpts: {\n experimental: {\n authInterrupts: Boolean(nextConfig.experimental.authInterrupts)\n },\n cacheComponents: Boolean(nextConfig.cacheComponents),\n supportsDynamicResponse,\n incrementalCache: getRequestMeta(req, 'incrementalCache'),\n cacheLifeProfiles: nextConfig.cacheLife,\n waitUntil: ctx.waitUntil,\n onClose: (cb)=>{\n res.on('close', cb);\n },\n onAfterTaskError: undefined,\n onInstrumentationRequestError: (error, _request, errorContext, silenceLog)=>routeModule.onRequestError(req, error, errorContext, silenceLog, routerServerContext)\n },\n sharedContext: {\n buildId\n }\n };\n const nodeNextReq = new NodeNextRequest(req);\n const nodeNextRes = new NodeNextResponse(res);\n const nextReq = NextRequestAdapter.fromNodeNextRequest(nodeNextReq, signalFromNodeResponse(res));\n try {\n const invokeRouteModule = async (span)=>{\n return routeModule.handle(nextReq, context).finally(()=>{\n if (!span) return;\n span.setAttributes({\n 'http.status_code': res.statusCode,\n 'next.rsc': false\n });\n const rootSpanAttributes = tracer.getRootSpanAttributes();\n // We were unable to get attributes, probably OTEL is not enabled\n if (!rootSpanAttributes) {\n return;\n }\n if (rootSpanAttributes.get('next.span_type') !== BaseServerSpan.handleRequest) {\n console.warn(`Unexpected root span type '${rootSpanAttributes.get('next.span_type')}'. Please report this Next.js issue https://github.com/vercel/next.js`);\n return;\n }\n const route = rootSpanAttributes.get('next.route');\n if (route) {\n const name = `${method} ${route}`;\n span.setAttributes({\n 'next.route': route,\n 'http.route': route,\n 'next.span_name': name\n });\n span.updateName(name);\n } else {\n span.updateName(`${method} ${srcPage}`);\n }\n });\n };\n const isMinimalMode = Boolean(process.env.MINIMAL_MODE || getRequestMeta(req, 'minimalMode'));\n const handleResponse = async (currentSpan)=>{\n var _cacheEntry_value;\n const responseGenerator = async ({ previousCacheEntry })=>{\n try {\n if (!isMinimalMode && isOnDemandRevalidate && revalidateOnlyGenerated && !previousCacheEntry) {\n res.statusCode = 404;\n // on-demand revalidate always sets this header\n res.setHeader('x-nextjs-cache', 'REVALIDATED');\n res.end('This page could not be found');\n return null;\n }\n const response = await invokeRouteModule(currentSpan);\n req.fetchMetrics = context.renderOpts.fetchMetrics;\n let pendingWaitUntil = context.renderOpts.pendingWaitUntil;\n // Attempt using provided waitUntil if available\n // if it's not we fallback to sendResponse's handling\n if (pendingWaitUntil) {\n if (ctx.waitUntil) {\n ctx.waitUntil(pendingWaitUntil);\n pendingWaitUntil = undefined;\n }\n }\n const cacheTags = context.renderOpts.collectedTags;\n // If the request is for a static response, we can cache it so long\n // as it's not edge.\n if (isIsr) {\n const blob = await response.blob();\n // Copy the headers from the response.\n const headers = toNodeOutgoingHttpHeaders(response.headers);\n if (cacheTags) {\n headers[NEXT_CACHE_TAGS_HEADER] = cacheTags;\n }\n if (!headers['content-type'] && blob.type) {\n headers['content-type'] = blob.type;\n }\n const revalidate = typeof context.renderOpts.collectedRevalidate === 'undefined' || context.renderOpts.collectedRevalidate >= INFINITE_CACHE ? false : context.renderOpts.collectedRevalidate;\n const expire = typeof context.renderOpts.collectedExpire === 'undefined' || context.renderOpts.collectedExpire >= INFINITE_CACHE ? undefined : context.renderOpts.collectedExpire;\n // Create the cache entry for the response.\n const cacheEntry = {\n value: {\n kind: CachedRouteKind.APP_ROUTE,\n status: response.status,\n body: Buffer.from(await blob.arrayBuffer()),\n headers\n },\n cacheControl: {\n revalidate,\n expire\n }\n };\n return cacheEntry;\n } else {\n // send response without caching if not ISR\n await sendResponse(nodeNextReq, nodeNextRes, response, context.renderOpts.pendingWaitUntil);\n return null;\n }\n } catch (err) {\n // if this is a background revalidate we need to report\n // the request error here as it won't be bubbled\n if (previousCacheEntry == null ? void 0 : previousCacheEntry.isStale) {\n const silenceLog = false;\n await routeModule.onRequestError(req, err, {\n routerKind: 'App Router',\n routePath: srcPage,\n routeType: 'route',\n revalidateReason: getRevalidateReason({\n isStaticGeneration,\n isOnDemandRevalidate\n })\n }, silenceLog, routerServerContext);\n }\n throw err;\n }\n };\n const cacheEntry = await routeModule.handleResponse({\n req,\n nextConfig,\n cacheKey,\n routeKind: RouteKind.APP_ROUTE,\n isFallback: false,\n prerenderManifest,\n isRoutePPREnabled: false,\n isOnDemandRevalidate,\n revalidateOnlyGenerated,\n responseGenerator,\n waitUntil: ctx.waitUntil,\n isMinimalMode\n });\n // we don't create a cacheEntry for ISR\n if (!isIsr) {\n return null;\n }\n if ((cacheEntry == null ? void 0 : (_cacheEntry_value = cacheEntry.value) == null ? void 0 : _cacheEntry_value.kind) !== CachedRouteKind.APP_ROUTE) {\n var _cacheEntry_value1;\n throw Object.defineProperty(new Error(`Invariant: app-route received invalid cache entry ${cacheEntry == null ? void 0 : (_cacheEntry_value1 = cacheEntry.value) == null ? void 0 : _cacheEntry_value1.kind}`), \"__NEXT_ERROR_CODE\", {\n value: \"E701\",\n enumerable: false,\n configurable: true\n });\n }\n if (!isMinimalMode) {\n res.setHeader('x-nextjs-cache', isOnDemandRevalidate ? 'REVALIDATED' : cacheEntry.isMiss ? 'MISS' : cacheEntry.isStale ? 'STALE' : 'HIT');\n }\n // Draft mode should never be cached\n if (isDraftMode) {\n res.setHeader('Cache-Control', 'private, no-cache, no-store, max-age=0, must-revalidate');\n }\n const headers = fromNodeOutgoingHttpHeaders(cacheEntry.value.headers);\n if (!(isMinimalMode && isIsr)) {\n headers.delete(NEXT_CACHE_TAGS_HEADER);\n }\n // If cache control is already set on the response we don't\n // override it to allow users to customize it via next.config\n if (cacheEntry.cacheControl && !res.getHeader('Cache-Control') && !headers.get('Cache-Control')) {\n headers.set('Cache-Control', getCacheControlHeader(cacheEntry.cacheControl));\n }\n await sendResponse(nodeNextReq, nodeNextRes, // @ts-expect-error - Argument of type 'Buffer<ArrayBufferLike>' is not assignable to parameter of type 'BodyInit | null | undefined'.\n new Response(cacheEntry.value.body, {\n headers,\n status: cacheEntry.value.status || 200\n }));\n return null;\n };\n // TODO: activeSpan code path is for when wrapped by\n // next-server can be removed when this is no longer used\n if (activeSpan) {\n await handleResponse(activeSpan);\n } else {\n await tracer.withPropagatedContext(req.headers, ()=>tracer.trace(BaseServerSpan.handleRequest, {\n spanName: `${method} ${srcPage}`,\n kind: SpanKind.SERVER,\n attributes: {\n 'http.method': method,\n 'http.target': req.url\n }\n }, handleResponse));\n }\n } catch (err) {\n if (!(err instanceof NoFallbackError)) {\n const silenceLog = false;\n await routeModule.onRequestError(req, err, {\n routerKind: 'App Router',\n routePath: normalizedSrcPage,\n routeType: 'route',\n revalidateReason: getRevalidateReason({\n isStaticGeneration,\n isOnDemandRevalidate\n })\n }, silenceLog, routerServerContext);\n }\n // rethrow so that we can handle serving error page\n // If this is during static generation, throw the error again.\n if (isIsr) throw err;\n // Otherwise, send a 500 response.\n await sendResponse(nodeNextReq, nodeNextRes, new Response(null, {\n status: 500\n }));\n return null;\n }\n}\n\n//# sourceMappingURL=app-route.js.map\n"],"names":[],"mappings":"2nCCAA,IAAA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OAC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CAAE,SAChC,EACA,OAAQ,EAAW,KAAK,CAAC,MAAM,EAAI,GACvC,IACO,IACX,EAGI,EACA,MAAM,EAAe,EADT,CAGZ,MAAM,EAAO,qBAAqB,CAAC,EAAI,OAAO,CAAE,IAAI,EAAO,KAAK,CAAC,EAAA,cAAc,CAAC,aAAa,CAAE,CACvF,SAAU,CAAA,EAAG,EAAO,CAAC,EAAE,EAAA,CAAS,CAChC,KAAM,EAAA,QAAQ,CAAC,MAAM,CACrB,WAAY,CACR,cAAe,EACf,cAAe,EAAI,GAAG,AAC1B,CACJ,EAAG,GAEf,CAAE,MAAO,EAAK,CAeV,GAdM,aAAe,EAAA,eAAe,EAEhC,CAFmC,KAE7B,EAAY,cAAc,CAAC,EAAK,EAAK,CACvC,WAAY,aACZ,UAAW,EACX,UAAW,QACX,iBAAkB,CAAA,EAAA,EAAA,mBAAA,AAAmB,EAAC,oBAClC,uBACA,CACJ,EACJ,GAAG,AATgB,EASJ,GAIf,EAAO,MAAM,EAKjB,OAHA,MAAM,CAAA,EAAA,EAAA,YAAA,AAAY,EAAC,EAAa,EAAa,IAAI,SAAS,KAAM,CAC5D,OAAQ,GACZ,IACO,IACX,CACJ,EAEA,qCAAqC","ignoreList":[1]}
@@ -1,3 +1,3 @@
1
- module.exports=[93695,(e,t,r)=>{t.exports=e.x("next/dist/shared/lib/no-fallback-error.external.js",()=>require("next/dist/shared/lib/no-fallback-error.external.js"))},14747,(e,t,r)=>{t.exports=e.x("path",()=>require("path"))},70406,(e,t,r)=>{t.exports=e.x("next/dist/compiled/@opentelemetry/api",()=>require("next/dist/compiled/@opentelemetry/api"))},18622,(e,t,r)=>{t.exports=e.x("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js",()=>require("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js"))},56704,(e,t,r)=>{t.exports=e.x("next/dist/server/app-render/work-async-storage.external.js",()=>require("next/dist/server/app-render/work-async-storage.external.js"))},32319,(e,t,r)=>{t.exports=e.x("next/dist/server/app-render/work-unit-async-storage.external.js",()=>require("next/dist/server/app-render/work-unit-async-storage.external.js"))},24725,(e,t,r)=>{t.exports=e.x("next/dist/server/app-render/after-task-async-storage.external.js",()=>require("next/dist/server/app-render/after-task-async-storage.external.js"))},88441,e=>{"use strict";var t=e.i(47909),r=e.i(74017),a=e.i(96250),n=e.i(59756),s=e.i(61916),o=e.i(74677),i=e.i(69741),l=e.i(16795),d=e.i(87718),u=e.i(95169),p=e.i(47587),c=e.i(66012),h=e.i(70101),x=e.i(26937),R=e.i(10372),g=e.i(93695);e.i(52474);var E=e.i(220),v=e.i(89171),f=e.i(22734),y=e.i(14747),m=e.i(46786),A=e.i(71560),O=e.i(97731);let C=(0,y.join)((0,m.homedir)(),".claude"),N=(0,y.join)(C,"settings.json"),_=(0,y.join)(C,"settings.json.aar.bak"),w=(0,y.join)((0,m.homedir)(),".aar"),T=(0,y.join)(w,"settings.tmp.json");async function P(t){try{let t,r,a,n=(0,f.existsSync)(N),s=(0,f.existsSync)(_);await (0,A.getDatabase)();let o=await (0,O.getConfig)("api_key"),i=await (0,O.getConfig)("port"),l=o?.value||"your-gateway-api-key",d=`http://localhost:${i?.value||"1357"}`;if(!n)return v.NextResponse.json({applied:!1,modelMapping:{},gatewayAddress:d,apiKey:I(l),backupExists:!1,lastUpdated:void 0,matchCurrentGateway:!1,routerProvider:void 0});let u=(0,f.readFileSync)(N,"utf-8");try{a=JSON.parse(u)}catch(e){return v.NextResponse.json({error:"Invalid settings.json format"},{status:500})}let p=a.env?.ANTHROPIC_BASE_URL,c=a.env?.ANTHROPIC_AUTH_TOKEN,h=p===d&&c===l,x={};if(!h&&(0,f.existsSync)(T))try{let e=(0,f.readFileSync)(T,"utf-8"),t=JSON.parse(e);t.modelMapping&&(x=t.modelMapping,console.log("[IDE Status] Loading temporary config:",x))}catch(e){console.error("[IDE Status] Failed to parse temp config:",e)}let R={applied:!0,modelMapping:(t=a.env||{},r={},t.ANTHROPIC_DEFAULT_HAIKU_MODEL&&(r.haiku=t.ANTHROPIC_DEFAULT_HAIKU_MODEL),t.ANTHROPIC_DEFAULT_SONNET_MODEL&&(r.sonnet=t.ANTHROPIC_DEFAULT_SONNET_MODEL),t.ANTHROPIC_DEFAULT_OPUS_MODEL&&(r.opus=t.ANTHROPIC_DEFAULT_OPUS_MODEL),t.ANTHROPIC_MODEL&&(r.default=t.ANTHROPIC_MODEL),t.ANTHROPIC_REASONING_MODEL&&(r.reasoning=t.ANTHROPIC_REASONING_MODEL),r),gatewayAddress:p,apiKey:I(c||l),backupExists:s,lastUpdated:function(){let{statSync:t}=e.r(22734);try{let e=t(N);return new Date(e.mtime).toISOString()}catch(e){return null}}()||null,matchCurrentGateway:h,routerProvider:a.router_provider,tempMapping:x};return v.NextResponse.json(R)}catch(e){return console.error("IDE Status API error:",e),v.NextResponse.json({error:e.message||"Internal server error",stack:void 0},{status:500})}}function I(e){return e&&"your-gateway-api-key"!==e?e.length<=8?e.slice(0,2)+"***"+e.slice(-2):e.slice(0,4)+"****"+e.slice(-4):e}e.s(["GET",()=>P],35912);var S=e.i(35912);let D=new t.AppRouteRouteModule({definition:{kind:r.RouteKind.APP_ROUTE,page:"/api/ide/claude/status/route",pathname:"/api/ide/claude/status",filename:"route",bundlePath:""},distDir:".next",relativeProjectDir:"",resolvedPagePath:"[project]/src/app/api/ide/claude/status/route.ts",nextConfigOutput:"",userland:S}),{workAsyncStorage:H,workUnitAsyncStorage:b,serverHooks:j}=D;function U(){return(0,a.patchFetch)({workAsyncStorage:H,workUnitAsyncStorage:b})}async function k(e,t,a){D.isDev&&(0,n.addRequestMeta)(e,"devRequestTimingInternalsEnd",process.hrtime.bigint());let v="/api/ide/claude/status/route";v=v.replace(/\/index$/,"")||"/";let f=await D.prepare(e,t,{srcPage:v,multiZoneDraftMode:!1});if(!f)return t.statusCode=400,t.end("Bad Request"),null==a.waitUntil||a.waitUntil.call(a,Promise.resolve()),null;let{buildId:y,params:m,nextConfig:A,parsedUrl:O,isDraftMode:C,prerenderManifest:N,routerServerContext:_,isOnDemandRevalidate:w,revalidateOnlyGenerated:T,resolvedPathname:P,clientReferenceManifest:I,serverActionsManifest:S}=f,H=(0,i.normalizeAppPath)(v),b=!!(N.dynamicRoutes[H]||N.routes[P]),j=async()=>((null==_?void 0:_.render404)?await _.render404(e,t,O,!1):t.end("This page could not be found"),null);if(b&&!C){let e=!!N.routes[P],t=N.dynamicRoutes[H];if(t&&!1===t.fallback&&!e){if(A.experimental.adapterPath)return await j();throw new g.NoFallbackError}}let U=null;!b||D.isDev||C||(U="/index"===(U=P)?"/":U);let k=!0===D.isDev||!b,M=b&&!k;S&&I&&(0,o.setManifestsSingleton)({page:v,clientReferenceManifest:I,serverActionsManifest:S});let L=e.method||"GET",q=(0,s.getTracer)(),F=q.getActiveScopeSpan(),K={params:m,prerenderManifest:N,renderOpts:{experimental:{authInterrupts:!!A.experimental.authInterrupts},cacheComponents:!!A.cacheComponents,supportsDynamicResponse:k,incrementalCache:(0,n.getRequestMeta)(e,"incrementalCache"),cacheLifeProfiles:A.cacheLife,waitUntil:a.waitUntil,onClose:e=>{t.on("close",e)},onAfterTaskError:void 0,onInstrumentationRequestError:(t,r,a,n)=>D.onRequestError(e,t,a,n,_)},sharedContext:{buildId:y}},$=new l.NodeNextRequest(e),G=new l.NodeNextResponse(t),B=d.NextRequestAdapter.fromNodeNextRequest($,(0,d.signalFromNodeResponse)(t));try{let o=async e=>D.handle(B,K).finally(()=>{if(!e)return;e.setAttributes({"http.status_code":t.statusCode,"next.rsc":!1});let r=q.getRootSpanAttributes();if(!r)return;if(r.get("next.span_type")!==u.BaseServerSpan.handleRequest)return void console.warn(`Unexpected root span type '${r.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let a=r.get("next.route");if(a){let t=`${L} ${a}`;e.setAttributes({"next.route":a,"http.route":a,"next.span_name":t}),e.updateName(t)}else e.updateName(`${L} ${v}`)}),i=!!(0,n.getRequestMeta)(e,"minimalMode"),l=async n=>{var s,l;let d=async({previousCacheEntry:r})=>{try{if(!i&&w&&T&&!r)return t.statusCode=404,t.setHeader("x-nextjs-cache","REVALIDATED"),t.end("This page could not be found"),null;let s=await o(n);e.fetchMetrics=K.renderOpts.fetchMetrics;let l=K.renderOpts.pendingWaitUntil;l&&a.waitUntil&&(a.waitUntil(l),l=void 0);let d=K.renderOpts.collectedTags;if(!b)return await (0,c.sendResponse)($,G,s,K.renderOpts.pendingWaitUntil),null;{let e=await s.blob(),t=(0,h.toNodeOutgoingHttpHeaders)(s.headers);d&&(t[R.NEXT_CACHE_TAGS_HEADER]=d),!t["content-type"]&&e.type&&(t["content-type"]=e.type);let r=void 0!==K.renderOpts.collectedRevalidate&&!(K.renderOpts.collectedRevalidate>=R.INFINITE_CACHE)&&K.renderOpts.collectedRevalidate,a=void 0===K.renderOpts.collectedExpire||K.renderOpts.collectedExpire>=R.INFINITE_CACHE?void 0:K.renderOpts.collectedExpire;return{value:{kind:E.CachedRouteKind.APP_ROUTE,status:s.status,body:Buffer.from(await e.arrayBuffer()),headers:t},cacheControl:{revalidate:r,expire:a}}}}catch(t){throw(null==r?void 0:r.isStale)&&await D.onRequestError(e,t,{routerKind:"App Router",routePath:v,routeType:"route",revalidateReason:(0,p.getRevalidateReason)({isStaticGeneration:M,isOnDemandRevalidate:w})},!1,_),t}},u=await D.handleResponse({req:e,nextConfig:A,cacheKey:U,routeKind:r.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:N,isRoutePPREnabled:!1,isOnDemandRevalidate:w,revalidateOnlyGenerated:T,responseGenerator:d,waitUntil:a.waitUntil,isMinimalMode:i});if(!b)return null;if((null==u||null==(s=u.value)?void 0:s.kind)!==E.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==u||null==(l=u.value)?void 0:l.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});i||t.setHeader("x-nextjs-cache",w?"REVALIDATED":u.isMiss?"MISS":u.isStale?"STALE":"HIT"),C&&t.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let g=(0,h.fromNodeOutgoingHttpHeaders)(u.value.headers);return i&&b||g.delete(R.NEXT_CACHE_TAGS_HEADER),!u.cacheControl||t.getHeader("Cache-Control")||g.get("Cache-Control")||g.set("Cache-Control",(0,x.getCacheControlHeader)(u.cacheControl)),await (0,c.sendResponse)($,G,new Response(u.value.body,{headers:g,status:u.value.status||200})),null};F?await l(F):await q.withPropagatedContext(e.headers,()=>q.trace(u.BaseServerSpan.handleRequest,{spanName:`${L} ${v}`,kind:s.SpanKind.SERVER,attributes:{"http.method":L,"http.target":e.url}},l))}catch(t){if(t instanceof g.NoFallbackError||await D.onRequestError(e,t,{routerKind:"App Router",routePath:H,routeType:"route",revalidateReason:(0,p.getRevalidateReason)({isStaticGeneration:M,isOnDemandRevalidate:w})},!1,_),b)throw t;return await (0,c.sendResponse)($,G,new Response(null,{status:500})),null}}e.s(["handler",()=>k,"patchFetch",()=>U,"routeModule",()=>D,"serverHooks",()=>j,"workAsyncStorage",()=>H,"workUnitAsyncStorage",()=>b],88441)}];
1
+ module.exports=[93695,(e,t,r)=>{t.exports=e.x("next/dist/shared/lib/no-fallback-error.external.js",()=>require("next/dist/shared/lib/no-fallback-error.external.js"))},14747,(e,t,r)=>{t.exports=e.x("path",()=>require("path"))},70406,(e,t,r)=>{t.exports=e.x("next/dist/compiled/@opentelemetry/api",()=>require("next/dist/compiled/@opentelemetry/api"))},18622,(e,t,r)=>{t.exports=e.x("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js",()=>require("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js"))},56704,(e,t,r)=>{t.exports=e.x("next/dist/server/app-render/work-async-storage.external.js",()=>require("next/dist/server/app-render/work-async-storage.external.js"))},32319,(e,t,r)=>{t.exports=e.x("next/dist/server/app-render/work-unit-async-storage.external.js",()=>require("next/dist/server/app-render/work-unit-async-storage.external.js"))},24725,(e,t,r)=>{t.exports=e.x("next/dist/server/app-render/after-task-async-storage.external.js",()=>require("next/dist/server/app-render/after-task-async-storage.external.js"))},88441,e=>{"use strict";var t=e.i(47909),r=e.i(74017),a=e.i(96250),n=e.i(59756),s=e.i(61916),i=e.i(74677),o=e.i(69741),l=e.i(16795),d=e.i(87718),u=e.i(95169),p=e.i(47587),c=e.i(66012),h=e.i(70101),x=e.i(26937),R=e.i(10372),g=e.i(93695);e.i(52474);var E=e.i(220),v=e.i(89171),y=e.i(22734),A=e.i(14747),f=e.i(46786),m=e.i(71560),w=e.i(97731);let O=(0,A.join)((0,f.homedir)(),".claude"),C=(0,A.join)(O,"settings.json"),N=(0,A.join)(O,"settings.json.aar.bak"),_=(0,A.join)((0,f.homedir)(),".aar"),T=(0,A.join)(_,"settings.tmp.json");async function P(t){try{let t,r,a,n=(0,y.existsSync)(C),s=(0,y.existsSync)(N);await (0,m.getDatabase)();let i=await (0,w.getConfig)("api_key"),o=await (0,w.getConfig)("port"),l=i?.value||"your-gateway-api-key",d=`http://localhost:${o?.value||"1357"}`;if(!n)return v.NextResponse.json({applied:!1,modelMapping:{},gatewayAddress:d,apiKey:I(l),backupExists:!1,lastUpdated:void 0,matchCurrentGateway:!1,routerProvider:void 0,currentGatewayAddress:d,currentGatewayApiKey:l});let u=(0,y.readFileSync)(C,"utf-8");try{a=JSON.parse(u)}catch(e){return v.NextResponse.json({error:"Invalid settings.json format"},{status:500})}let p=a.env?.ANTHROPIC_BASE_URL,c=a.env?.ANTHROPIC_AUTH_TOKEN,h=p===d&&c===l,x={};if(!h&&(0,y.existsSync)(T))try{let e=(0,y.readFileSync)(T,"utf-8"),t=JSON.parse(e);t.modelMapping&&(x=t.modelMapping,console.log("[IDE Status] Loading temporary config:",x))}catch(e){console.error("[IDE Status] Failed to parse temp config:",e)}let R={applied:!0,modelMapping:(t=a.env||{},r={},t.ANTHROPIC_DEFAULT_HAIKU_MODEL&&(r.haiku=t.ANTHROPIC_DEFAULT_HAIKU_MODEL),t.ANTHROPIC_DEFAULT_SONNET_MODEL&&(r.sonnet=t.ANTHROPIC_DEFAULT_SONNET_MODEL),t.ANTHROPIC_DEFAULT_OPUS_MODEL&&(r.opus=t.ANTHROPIC_DEFAULT_OPUS_MODEL),t.ANTHROPIC_MODEL&&(r.default=t.ANTHROPIC_MODEL),t.ANTHROPIC_REASONING_MODEL&&(r.reasoning=t.ANTHROPIC_REASONING_MODEL),r),gatewayAddress:p,apiKey:I(c||l),backupExists:s,lastUpdated:function(){let{statSync:t}=e.r(22734);try{let e=t(C);return new Date(e.mtime).toISOString()}catch(e){return null}}()||null,matchCurrentGateway:h,routerProvider:a.router_provider,tempMapping:x,config:a,currentGatewayAddress:d,currentGatewayApiKey:l};return v.NextResponse.json(R)}catch(e){return console.error("IDE Status API error:",e),v.NextResponse.json({error:e.message||"Internal server error",stack:void 0},{status:500})}}function I(e){return e&&"your-gateway-api-key"!==e?e.length<=8?e.slice(0,2)+"***"+e.slice(-2):e.slice(0,4)+"****"+e.slice(-4):e}e.s(["GET",()=>P],35912);var S=e.i(35912);let D=new t.AppRouteRouteModule({definition:{kind:r.RouteKind.APP_ROUTE,page:"/api/ide/claude/status/route",pathname:"/api/ide/claude/status",filename:"route",bundlePath:""},distDir:".next",relativeProjectDir:"",resolvedPagePath:"[project]/src/app/api/ide/claude/status/route.ts",nextConfigOutput:"",userland:S}),{workAsyncStorage:H,workUnitAsyncStorage:b,serverHooks:j}=D;function U(){return(0,a.patchFetch)({workAsyncStorage:H,workUnitAsyncStorage:b})}async function k(e,t,a){D.isDev&&(0,n.addRequestMeta)(e,"devRequestTimingInternalsEnd",process.hrtime.bigint());let v="/api/ide/claude/status/route";v=v.replace(/\/index$/,"")||"/";let y=await D.prepare(e,t,{srcPage:v,multiZoneDraftMode:!1});if(!y)return t.statusCode=400,t.end("Bad Request"),null==a.waitUntil||a.waitUntil.call(a,Promise.resolve()),null;let{buildId:A,params:f,nextConfig:m,parsedUrl:w,isDraftMode:O,prerenderManifest:C,routerServerContext:N,isOnDemandRevalidate:_,revalidateOnlyGenerated:T,resolvedPathname:P,clientReferenceManifest:I,serverActionsManifest:S}=y,H=(0,o.normalizeAppPath)(v),b=!!(C.dynamicRoutes[H]||C.routes[P]),j=async()=>((null==N?void 0:N.render404)?await N.render404(e,t,w,!1):t.end("This page could not be found"),null);if(b&&!O){let e=!!C.routes[P],t=C.dynamicRoutes[H];if(t&&!1===t.fallback&&!e){if(m.experimental.adapterPath)return await j();throw new g.NoFallbackError}}let U=null;!b||D.isDev||O||(U="/index"===(U=P)?"/":U);let k=!0===D.isDev||!b,M=b&&!k;S&&I&&(0,i.setManifestsSingleton)({page:v,clientReferenceManifest:I,serverActionsManifest:S});let L=e.method||"GET",q=(0,s.getTracer)(),F=q.getActiveScopeSpan(),K={params:f,prerenderManifest:C,renderOpts:{experimental:{authInterrupts:!!m.experimental.authInterrupts},cacheComponents:!!m.cacheComponents,supportsDynamicResponse:k,incrementalCache:(0,n.getRequestMeta)(e,"incrementalCache"),cacheLifeProfiles:m.cacheLife,waitUntil:a.waitUntil,onClose:e=>{t.on("close",e)},onAfterTaskError:void 0,onInstrumentationRequestError:(t,r,a,n)=>D.onRequestError(e,t,a,n,N)},sharedContext:{buildId:A}},G=new l.NodeNextRequest(e),$=new l.NodeNextResponse(t),B=d.NextRequestAdapter.fromNodeNextRequest(G,(0,d.signalFromNodeResponse)(t));try{let i=async e=>D.handle(B,K).finally(()=>{if(!e)return;e.setAttributes({"http.status_code":t.statusCode,"next.rsc":!1});let r=q.getRootSpanAttributes();if(!r)return;if(r.get("next.span_type")!==u.BaseServerSpan.handleRequest)return void console.warn(`Unexpected root span type '${r.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let a=r.get("next.route");if(a){let t=`${L} ${a}`;e.setAttributes({"next.route":a,"http.route":a,"next.span_name":t}),e.updateName(t)}else e.updateName(`${L} ${v}`)}),o=!!(0,n.getRequestMeta)(e,"minimalMode"),l=async n=>{var s,l;let d=async({previousCacheEntry:r})=>{try{if(!o&&_&&T&&!r)return t.statusCode=404,t.setHeader("x-nextjs-cache","REVALIDATED"),t.end("This page could not be found"),null;let s=await i(n);e.fetchMetrics=K.renderOpts.fetchMetrics;let l=K.renderOpts.pendingWaitUntil;l&&a.waitUntil&&(a.waitUntil(l),l=void 0);let d=K.renderOpts.collectedTags;if(!b)return await (0,c.sendResponse)(G,$,s,K.renderOpts.pendingWaitUntil),null;{let e=await s.blob(),t=(0,h.toNodeOutgoingHttpHeaders)(s.headers);d&&(t[R.NEXT_CACHE_TAGS_HEADER]=d),!t["content-type"]&&e.type&&(t["content-type"]=e.type);let r=void 0!==K.renderOpts.collectedRevalidate&&!(K.renderOpts.collectedRevalidate>=R.INFINITE_CACHE)&&K.renderOpts.collectedRevalidate,a=void 0===K.renderOpts.collectedExpire||K.renderOpts.collectedExpire>=R.INFINITE_CACHE?void 0:K.renderOpts.collectedExpire;return{value:{kind:E.CachedRouteKind.APP_ROUTE,status:s.status,body:Buffer.from(await e.arrayBuffer()),headers:t},cacheControl:{revalidate:r,expire:a}}}}catch(t){throw(null==r?void 0:r.isStale)&&await D.onRequestError(e,t,{routerKind:"App Router",routePath:v,routeType:"route",revalidateReason:(0,p.getRevalidateReason)({isStaticGeneration:M,isOnDemandRevalidate:_})},!1,N),t}},u=await D.handleResponse({req:e,nextConfig:m,cacheKey:U,routeKind:r.RouteKind.APP_ROUTE,isFallback:!1,prerenderManifest:C,isRoutePPREnabled:!1,isOnDemandRevalidate:_,revalidateOnlyGenerated:T,responseGenerator:d,waitUntil:a.waitUntil,isMinimalMode:o});if(!b)return null;if((null==u||null==(s=u.value)?void 0:s.kind)!==E.CachedRouteKind.APP_ROUTE)throw Object.defineProperty(Error(`Invariant: app-route received invalid cache entry ${null==u||null==(l=u.value)?void 0:l.kind}`),"__NEXT_ERROR_CODE",{value:"E701",enumerable:!1,configurable:!0});o||t.setHeader("x-nextjs-cache",_?"REVALIDATED":u.isMiss?"MISS":u.isStale?"STALE":"HIT"),O&&t.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate");let g=(0,h.fromNodeOutgoingHttpHeaders)(u.value.headers);return o&&b||g.delete(R.NEXT_CACHE_TAGS_HEADER),!u.cacheControl||t.getHeader("Cache-Control")||g.get("Cache-Control")||g.set("Cache-Control",(0,x.getCacheControlHeader)(u.cacheControl)),await (0,c.sendResponse)(G,$,new Response(u.value.body,{headers:g,status:u.value.status||200})),null};F?await l(F):await q.withPropagatedContext(e.headers,()=>q.trace(u.BaseServerSpan.handleRequest,{spanName:`${L} ${v}`,kind:s.SpanKind.SERVER,attributes:{"http.method":L,"http.target":e.url}},l))}catch(t){if(t instanceof g.NoFallbackError||await D.onRequestError(e,t,{routerKind:"App Router",routePath:H,routeType:"route",revalidateReason:(0,p.getRevalidateReason)({isStaticGeneration:M,isOnDemandRevalidate:_})},!1,N),b)throw t;return await (0,c.sendResponse)(G,$,new Response(null,{status:500})),null}}e.s(["handler",()=>k,"patchFetch",()=>U,"routeModule",()=>D,"serverHooks",()=>j,"workAsyncStorage",()=>H,"workUnitAsyncStorage",()=>b],88441)}];
2
2
 
3
3
  //# sourceMappingURL=%5Broot-of-the-server%5D__f8949f88._.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../src/app/api/ide/claude/status/route.ts","../../../node_modules/next/dist/esm/build/templates/app-route.js"],"sourcesContent":["import { NextRequest, NextResponse } from 'next/server';\nimport { existsSync, readFileSync } from 'fs';\nimport { join } from 'path';\nimport { homedir } from 'os';\nimport { getDatabase } from '@/db/database';\nimport { getConfig } from '@/db/queries';\n\n// Claude settings.json 文件路径\nconst CLAUDE_DIR = join(homedir(), '.claude');\nconst SETTINGS_FILE = join(CLAUDE_DIR, 'settings.json');\nconst BACKUP_FILE = join(CLAUDE_DIR, 'settings.json.aar.bak');\n\n// AAR 临时配置文件\nconst AAR_DIR = join(homedir(), '.aar');\nconst TEMP_SETTINGS_FILE = join(AAR_DIR, 'settings.tmp.json');\n\n// 默认模型映射(与 apply API 保持一致)\nconst DEFAULT_MODEL_MAPPING = {\n haiku: 'GLM-4.5-air',\n sonnet: 'MiniMax-M2.1',\n opus: 'GLM-4.7',\n default: 'GLM-4.7',\n} as const;\n\ntype ConfigStatus = {\n applied: boolean;\n modelMapping: { haiku?: string; sonnet?: string; opus?: string; default?: string; reasoning?: string };\n gatewayAddress?: string;\n apiKey?: string;\n lastUpdated?: string | null;\n backupExists: boolean;\n matchCurrentGateway?: boolean; // 是否匹配当前网关配置\n routerProvider?: string; // 路由提供者标识,'aar' 表示配置来自当前工具\n tempMapping?: { haiku?: string; sonnet?: string; opus?: string; default?: string; reasoning?: string }; // 临时配置模型映射\n};\n\n/**\n * 查询 Claude IDE 配置状态\n */\nexport async function GET(request: NextRequest) {\n try {\n const settingsFileExists = existsSync(SETTINGS_FILE);\n const backupFileExists = existsSync(BACKUP_FILE);\n\n // 从数据库读取当前网关配置\n await getDatabase();\n const gatewayApiKeyConfig = await getConfig('api_key');\n const portConfig = await getConfig('port');\n const gatewayApiKey = gatewayApiKeyConfig?.value || 'your-gateway-api-key';\n const gatewayAddress = `http://localhost:${portConfig?.value || '1357'}`;\n\n if (!settingsFileExists) {\n // 配置文件不存在,返回未应用状态\n return NextResponse.json({\n applied: false,\n modelMapping: {},\n gatewayAddress: gatewayAddress,\n apiKey: maskApiKey(gatewayApiKey),\n backupExists: false,\n lastUpdated: undefined,\n matchCurrentGateway: false,\n routerProvider: undefined,\n });\n }\n\n // 读取配置文件\n const configContent = readFileSync(SETTINGS_FILE, 'utf-8');\n let config: any;\n try {\n config = JSON.parse(configContent);\n } catch (error: any) {\n return NextResponse.json(\n { error: 'Invalid settings.json format' },\n { status: 500 }\n );\n }\n\n // 检查配置是否匹配当前网关\n const appliedBaseUrl = config.env?.ANTHROPIC_BASE_URL;\n const appliedApiKey = config.env?.ANTHROPIC_AUTH_TOKEN;\n const matchCurrentGateway = appliedBaseUrl === gatewayAddress && appliedApiKey === gatewayApiKey;\n\n // 如果不匹配当前网关,尝试读取临时配置\n let tempMapping: ConfigStatus['tempMapping'] = {};\n if (!matchCurrentGateway) {\n const tempFileExists = existsSync(TEMP_SETTINGS_FILE);\n if (tempFileExists) {\n try {\n const tempContent = readFileSync(TEMP_SETTINGS_FILE, 'utf-8');\n const tempConfig = JSON.parse(tempContent);\n if (tempConfig.modelMapping) {\n tempMapping = tempConfig.modelMapping;\n console.log('[IDE Status] Loading temporary config:', tempMapping);\n }\n } catch (error) {\n console.error('[IDE Status] Failed to parse temp config:', error);\n }\n }\n }\n\n // 提取配置状态\n const status: ConfigStatus = {\n applied: true,\n modelMapping: extractModelMapping(config),\n gatewayAddress: appliedBaseUrl,\n apiKey: maskApiKey(appliedApiKey || gatewayApiKey),\n backupExists: backupFileExists,\n lastUpdated: getFileModTime() || null,\n matchCurrentGateway,\n routerProvider: config.router_provider,\n tempMapping,\n };\n\n return NextResponse.json(status);\n } catch (error: any) {\n console.error('IDE Status API error:', error);\n return NextResponse.json(\n { error: error.message || 'Internal server error', stack: process.env.NODE_ENV === 'development' ? error.stack : undefined },\n { status: 500 }\n );\n }\n}\n\n/**\n * 脱敏 API KEY\n */\nfunction maskApiKey(apiKey: string): string {\n if (!apiKey || apiKey === 'your-gateway-api-key') {\n return apiKey;\n }\n // 只显示前4位和后4位,中间用****代替\n if (apiKey.length <= 8) {\n // 如果太短,只显示前2位和后2位\n return apiKey.slice(0, 2) + '***' + apiKey.slice(-2);\n }\n return apiKey.slice(0, 4) + '****' + apiKey.slice(-4);\n}\n\n/**\n * 从配置中提取模型映射\n */\nfunction extractModelMapping(config: any): ConfigStatus['modelMapping'] {\n const env = config.env || {};\n const mapping: ConfigStatus['modelMapping'] = {};\n\n if (env.ANTHROPIC_DEFAULT_HAIKU_MODEL) {\n mapping.haiku = env.ANTHROPIC_DEFAULT_HAIKU_MODEL;\n }\n if (env.ANTHROPIC_DEFAULT_SONNET_MODEL) {\n mapping.sonnet = env.ANTHROPIC_DEFAULT_SONNET_MODEL;\n }\n if (env.ANTHROPIC_DEFAULT_OPUS_MODEL) {\n mapping.opus = env.ANTHROPIC_DEFAULT_OPUS_MODEL;\n }\n if (env.ANTHROPIC_MODEL) {\n mapping.default = env.ANTHROPIC_MODEL;\n }\n if (env.ANTHROPIC_REASONING_MODEL) {\n mapping.reasoning = env.ANTHROPIC_REASONING_MODEL;\n }\n\n return mapping;\n}\n\n/**\n * 获取文件修改时间\n */\nfunction getFileModTime(): string | null {\n const { statSync } = require('fs');\n try {\n const stats = statSync(SETTINGS_FILE);\n return new Date(stats.mtime).toISOString();\n } catch (error: any) {\n return null;\n }\n}\n","import { AppRouteRouteModule } from \"next/dist/esm/server/route-modules/app-route/module.compiled\";\nimport { RouteKind } from \"next/dist/esm/server/route-kind\";\nimport { patchFetch as _patchFetch } from \"next/dist/esm/server/lib/patch-fetch\";\nimport { addRequestMeta, getRequestMeta } from \"next/dist/esm/server/request-meta\";\nimport { getTracer, SpanKind } from \"next/dist/esm/server/lib/trace/tracer\";\nimport { setManifestsSingleton } from \"next/dist/esm/server/app-render/manifests-singleton\";\nimport { normalizeAppPath } from \"next/dist/esm/shared/lib/router/utils/app-paths\";\nimport { NodeNextRequest, NodeNextResponse } from \"next/dist/esm/server/base-http/node\";\nimport { NextRequestAdapter, signalFromNodeResponse } from \"next/dist/esm/server/web/spec-extension/adapters/next-request\";\nimport { BaseServerSpan } from \"next/dist/esm/server/lib/trace/constants\";\nimport { getRevalidateReason } from \"next/dist/esm/server/instrumentation/utils\";\nimport { sendResponse } from \"next/dist/esm/server/send-response\";\nimport { fromNodeOutgoingHttpHeaders, toNodeOutgoingHttpHeaders } from \"next/dist/esm/server/web/utils\";\nimport { getCacheControlHeader } from \"next/dist/esm/server/lib/cache-control\";\nimport { INFINITE_CACHE, NEXT_CACHE_TAGS_HEADER } from \"next/dist/esm/lib/constants\";\nimport { NoFallbackError } from \"next/dist/esm/shared/lib/no-fallback-error.external\";\nimport { CachedRouteKind } from \"next/dist/esm/server/response-cache\";\nimport * as userland from \"INNER_APP_ROUTE\";\n// We inject the nextConfigOutput here so that we can use them in the route\n// module.\nconst nextConfigOutput = \"\"\nconst routeModule = new AppRouteRouteModule({\n definition: {\n kind: RouteKind.APP_ROUTE,\n page: \"/api/ide/claude/status/route\",\n pathname: \"/api/ide/claude/status\",\n filename: \"route\",\n bundlePath: \"\"\n },\n distDir: process.env.__NEXT_RELATIVE_DIST_DIR || '',\n relativeProjectDir: process.env.__NEXT_RELATIVE_PROJECT_DIR || '',\n resolvedPagePath: \"[project]/src/app/api/ide/claude/status/route.ts\",\n nextConfigOutput,\n userland\n});\n// Pull out the exports that we need to expose from the module. This should\n// be eliminated when we've moved the other routes to the new format. These\n// are used to hook into the route.\nconst { workAsyncStorage, workUnitAsyncStorage, serverHooks } = routeModule;\nfunction patchFetch() {\n return _patchFetch({\n workAsyncStorage,\n workUnitAsyncStorage\n });\n}\nexport { routeModule, workAsyncStorage, workUnitAsyncStorage, serverHooks, patchFetch, };\nexport async function handler(req, res, ctx) {\n if (routeModule.isDev) {\n addRequestMeta(req, 'devRequestTimingInternalsEnd', process.hrtime.bigint());\n }\n let srcPage = \"/api/ide/claude/status/route\";\n // turbopack doesn't normalize `/index` in the page name\n // so we need to to process dynamic routes properly\n // TODO: fix turbopack providing differing value from webpack\n if (process.env.TURBOPACK) {\n srcPage = srcPage.replace(/\\/index$/, '') || '/';\n } else if (srcPage === '/index') {\n // we always normalize /index specifically\n srcPage = '/';\n }\n const multiZoneDraftMode = process.env.__NEXT_MULTI_ZONE_DRAFT_MODE;\n const prepareResult = await routeModule.prepare(req, res, {\n srcPage,\n multiZoneDraftMode\n });\n if (!prepareResult) {\n res.statusCode = 400;\n res.end('Bad Request');\n ctx.waitUntil == null ? void 0 : ctx.waitUntil.call(ctx, Promise.resolve());\n return null;\n }\n const { buildId, params, nextConfig, parsedUrl, isDraftMode, prerenderManifest, routerServerContext, isOnDemandRevalidate, revalidateOnlyGenerated, resolvedPathname, clientReferenceManifest, serverActionsManifest } = prepareResult;\n const normalizedSrcPage = normalizeAppPath(srcPage);\n let isIsr = Boolean(prerenderManifest.dynamicRoutes[normalizedSrcPage] || prerenderManifest.routes[resolvedPathname]);\n const render404 = async ()=>{\n // TODO: should route-module itself handle rendering the 404\n if (routerServerContext == null ? void 0 : routerServerContext.render404) {\n await routerServerContext.render404(req, res, parsedUrl, false);\n } else {\n res.end('This page could not be found');\n }\n return null;\n };\n if (isIsr && !isDraftMode) {\n const isPrerendered = Boolean(prerenderManifest.routes[resolvedPathname]);\n const prerenderInfo = prerenderManifest.dynamicRoutes[normalizedSrcPage];\n if (prerenderInfo) {\n if (prerenderInfo.fallback === false && !isPrerendered) {\n if (nextConfig.experimental.adapterPath) {\n return await render404();\n }\n throw new NoFallbackError();\n }\n }\n }\n let cacheKey = null;\n if (isIsr && !routeModule.isDev && !isDraftMode) {\n cacheKey = resolvedPathname;\n // ensure /index and / is normalized to one key\n cacheKey = cacheKey === '/index' ? '/' : cacheKey;\n }\n const supportsDynamicResponse = // If we're in development, we always support dynamic HTML\n routeModule.isDev === true || // If this is not SSG or does not have static paths, then it supports\n // dynamic HTML.\n !isIsr;\n // This is a revalidation request if the request is for a static\n // page and it is not being resumed from a postponed render and\n // it is not a dynamic RSC request then it is a revalidation\n // request.\n const isStaticGeneration = isIsr && !supportsDynamicResponse;\n // Before rendering (which initializes component tree modules), we have to\n // set the reference manifests to our global store so Server Action's\n // encryption util can access to them at the top level of the page module.\n if (serverActionsManifest && clientReferenceManifest) {\n setManifestsSingleton({\n page: srcPage,\n clientReferenceManifest,\n serverActionsManifest\n });\n }\n const method = req.method || 'GET';\n const tracer = getTracer();\n const activeSpan = tracer.getActiveScopeSpan();\n const context = {\n params,\n prerenderManifest,\n renderOpts: {\n experimental: {\n authInterrupts: Boolean(nextConfig.experimental.authInterrupts)\n },\n cacheComponents: Boolean(nextConfig.cacheComponents),\n supportsDynamicResponse,\n incrementalCache: getRequestMeta(req, 'incrementalCache'),\n cacheLifeProfiles: nextConfig.cacheLife,\n waitUntil: ctx.waitUntil,\n onClose: (cb)=>{\n res.on('close', cb);\n },\n onAfterTaskError: undefined,\n onInstrumentationRequestError: (error, _request, errorContext, silenceLog)=>routeModule.onRequestError(req, error, errorContext, silenceLog, routerServerContext)\n },\n sharedContext: {\n buildId\n }\n };\n const nodeNextReq = new NodeNextRequest(req);\n const nodeNextRes = new NodeNextResponse(res);\n const nextReq = NextRequestAdapter.fromNodeNextRequest(nodeNextReq, signalFromNodeResponse(res));\n try {\n const invokeRouteModule = async (span)=>{\n return routeModule.handle(nextReq, context).finally(()=>{\n if (!span) return;\n span.setAttributes({\n 'http.status_code': res.statusCode,\n 'next.rsc': false\n });\n const rootSpanAttributes = tracer.getRootSpanAttributes();\n // We were unable to get attributes, probably OTEL is not enabled\n if (!rootSpanAttributes) {\n return;\n }\n if (rootSpanAttributes.get('next.span_type') !== BaseServerSpan.handleRequest) {\n console.warn(`Unexpected root span type '${rootSpanAttributes.get('next.span_type')}'. Please report this Next.js issue https://github.com/vercel/next.js`);\n return;\n }\n const route = rootSpanAttributes.get('next.route');\n if (route) {\n const name = `${method} ${route}`;\n span.setAttributes({\n 'next.route': route,\n 'http.route': route,\n 'next.span_name': name\n });\n span.updateName(name);\n } else {\n span.updateName(`${method} ${srcPage}`);\n }\n });\n };\n const isMinimalMode = Boolean(process.env.MINIMAL_MODE || getRequestMeta(req, 'minimalMode'));\n const handleResponse = async (currentSpan)=>{\n var _cacheEntry_value;\n const responseGenerator = async ({ previousCacheEntry })=>{\n try {\n if (!isMinimalMode && isOnDemandRevalidate && revalidateOnlyGenerated && !previousCacheEntry) {\n res.statusCode = 404;\n // on-demand revalidate always sets this header\n res.setHeader('x-nextjs-cache', 'REVALIDATED');\n res.end('This page could not be found');\n return null;\n }\n const response = await invokeRouteModule(currentSpan);\n req.fetchMetrics = context.renderOpts.fetchMetrics;\n let pendingWaitUntil = context.renderOpts.pendingWaitUntil;\n // Attempt using provided waitUntil if available\n // if it's not we fallback to sendResponse's handling\n if (pendingWaitUntil) {\n if (ctx.waitUntil) {\n ctx.waitUntil(pendingWaitUntil);\n pendingWaitUntil = undefined;\n }\n }\n const cacheTags = context.renderOpts.collectedTags;\n // If the request is for a static response, we can cache it so long\n // as it's not edge.\n if (isIsr) {\n const blob = await response.blob();\n // Copy the headers from the response.\n const headers = toNodeOutgoingHttpHeaders(response.headers);\n if (cacheTags) {\n headers[NEXT_CACHE_TAGS_HEADER] = cacheTags;\n }\n if (!headers['content-type'] && blob.type) {\n headers['content-type'] = blob.type;\n }\n const revalidate = typeof context.renderOpts.collectedRevalidate === 'undefined' || context.renderOpts.collectedRevalidate >= INFINITE_CACHE ? false : context.renderOpts.collectedRevalidate;\n const expire = typeof context.renderOpts.collectedExpire === 'undefined' || context.renderOpts.collectedExpire >= INFINITE_CACHE ? undefined : context.renderOpts.collectedExpire;\n // Create the cache entry for the response.\n const cacheEntry = {\n value: {\n kind: CachedRouteKind.APP_ROUTE,\n status: response.status,\n body: Buffer.from(await blob.arrayBuffer()),\n headers\n },\n cacheControl: {\n revalidate,\n expire\n }\n };\n return cacheEntry;\n } else {\n // send response without caching if not ISR\n await sendResponse(nodeNextReq, nodeNextRes, response, context.renderOpts.pendingWaitUntil);\n return null;\n }\n } catch (err) {\n // if this is a background revalidate we need to report\n // the request error here as it won't be bubbled\n if (previousCacheEntry == null ? void 0 : previousCacheEntry.isStale) {\n const silenceLog = false;\n await routeModule.onRequestError(req, err, {\n routerKind: 'App Router',\n routePath: srcPage,\n routeType: 'route',\n revalidateReason: getRevalidateReason({\n isStaticGeneration,\n isOnDemandRevalidate\n })\n }, silenceLog, routerServerContext);\n }\n throw err;\n }\n };\n const cacheEntry = await routeModule.handleResponse({\n req,\n nextConfig,\n cacheKey,\n routeKind: RouteKind.APP_ROUTE,\n isFallback: false,\n prerenderManifest,\n isRoutePPREnabled: false,\n isOnDemandRevalidate,\n revalidateOnlyGenerated,\n responseGenerator,\n waitUntil: ctx.waitUntil,\n isMinimalMode\n });\n // we don't create a cacheEntry for ISR\n if (!isIsr) {\n return null;\n }\n if ((cacheEntry == null ? void 0 : (_cacheEntry_value = cacheEntry.value) == null ? void 0 : _cacheEntry_value.kind) !== CachedRouteKind.APP_ROUTE) {\n var _cacheEntry_value1;\n throw Object.defineProperty(new Error(`Invariant: app-route received invalid cache entry ${cacheEntry == null ? void 0 : (_cacheEntry_value1 = cacheEntry.value) == null ? void 0 : _cacheEntry_value1.kind}`), \"__NEXT_ERROR_CODE\", {\n value: \"E701\",\n enumerable: false,\n configurable: true\n });\n }\n if (!isMinimalMode) {\n res.setHeader('x-nextjs-cache', isOnDemandRevalidate ? 'REVALIDATED' : cacheEntry.isMiss ? 'MISS' : cacheEntry.isStale ? 'STALE' : 'HIT');\n }\n // Draft mode should never be cached\n if (isDraftMode) {\n res.setHeader('Cache-Control', 'private, no-cache, no-store, max-age=0, must-revalidate');\n }\n const headers = fromNodeOutgoingHttpHeaders(cacheEntry.value.headers);\n if (!(isMinimalMode && isIsr)) {\n headers.delete(NEXT_CACHE_TAGS_HEADER);\n }\n // If cache control is already set on the response we don't\n // override it to allow users to customize it via next.config\n if (cacheEntry.cacheControl && !res.getHeader('Cache-Control') && !headers.get('Cache-Control')) {\n headers.set('Cache-Control', getCacheControlHeader(cacheEntry.cacheControl));\n }\n await sendResponse(nodeNextReq, nodeNextRes, // @ts-expect-error - Argument of type 'Buffer<ArrayBufferLike>' is not assignable to parameter of type 'BodyInit | null | undefined'.\n new Response(cacheEntry.value.body, {\n headers,\n status: cacheEntry.value.status || 200\n }));\n return null;\n };\n // TODO: activeSpan code path is for when wrapped by\n // next-server can be removed when this is no longer used\n if (activeSpan) {\n await handleResponse(activeSpan);\n } else {\n await tracer.withPropagatedContext(req.headers, ()=>tracer.trace(BaseServerSpan.handleRequest, {\n spanName: `${method} ${srcPage}`,\n kind: SpanKind.SERVER,\n attributes: {\n 'http.method': method,\n 'http.target': req.url\n }\n }, handleResponse));\n }\n } catch (err) {\n if (!(err instanceof NoFallbackError)) {\n const silenceLog = false;\n await routeModule.onRequestError(req, err, {\n routerKind: 'App Router',\n routePath: normalizedSrcPage,\n routeType: 'route',\n revalidateReason: getRevalidateReason({\n isStaticGeneration,\n isOnDemandRevalidate\n })\n }, silenceLog, routerServerContext);\n }\n // rethrow so that we can handle serving error page\n // If this is during static generation, throw the error again.\n if (isIsr) throw err;\n // Otherwise, send a 500 response.\n await sendResponse(nodeNextReq, nodeNextRes, new Response(null, {\n status: 500\n }));\n return null;\n }\n}\n\n//# sourceMappingURL=app-route.js.map\n"],"names":[],"mappings":"8iCCAA,IAAA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,CAAA,CAAA,OAAA,IAAA,EAAA,EAAA,CAAA,CAAA,KDhBA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OAGA,IAAM,EAAa,CAAA,EAAA,EAAA,IAAA,AAAI,EAAC,CAAA,EAAA,EAAA,OAAA,AAAO,IAAI,WAC7B,EAAgB,CAAA,EAAA,EAAA,IAAA,AAAI,EAAC,EAAY,iBACjC,EAAc,CAAA,EAAA,EAAA,IAAA,AAAI,EAAC,EAAY,yBAG/B,EAAU,CAAA,E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b,CAAC,EAAA,sBAAsB,GAIrC,EAAW,YAAY,EAAK,EAAD,AAAK,SAAS,CAAC,kBAAqB,EAAQ,AAAT,GAAY,CAAC,kBAAkB,AAC7F,EAAQ,GAAG,CAAC,gBAAiB,CAAA,EAAA,EAAA,qBAAA,AAAqB,EAAC,EAAW,YAAY,GAE9E,MAAM,CAAA,EAAA,EAAA,YAAA,AAAY,EAAC,EAAa,EAChC,IAAI,SAAS,EAAW,KAAK,CAAC,IAAI,CAAE,SAChC,EACA,OAAQ,EAAW,KAAK,CAAC,MAAM,EAAI,GACvC,IACO,IACX,EAGI,EACA,MAAM,EAAe,EADT,CAGZ,MAAM,EAAO,qBAAqB,CAAC,EAAI,OAAO,CAAE,IAAI,EAAO,KAAK,CAAC,EAAA,cAAc,CAAC,aAAa,CAAE,CACvF,SAAU,CAAA,EAAG,EAAO,CAAC,EAAE,EAAA,CAAS,CAChC,KAAM,EAAA,QAAQ,CAAC,MAAM,CACrB,WAAY,CACR,cAAe,EACf,cAAe,EAAI,GAAG,AAC1B,CACJ,EAAG,GAEf,CAAE,MAAO,EAAK,CAeV,GAdM,aAAe,EAAA,eAAe,EAEhC,CAFmC,KAE7B,EAAY,cAAc,CAAC,EAAK,EAAK,CACvC,WAAY,aACZ,UAAW,EACX,UAAW,QACX,iBAAkB,CAAA,EAAA,EAAA,mBAAmB,AAAnB,EAAoB,CAClC,qBACA,sBACJ,EACJ,GAAG,AATgB,EASJ,GAIf,EAAO,MAAM,EAKjB,OAHA,MAAM,CAAA,EAAA,EAAA,YAAA,AAAY,EAAC,EAAa,EAAa,IAAI,SAAS,KAAM,CAC5D,OAAQ,GACZ,IACO,IACX,CACJ,EAEA,qCAAqC","ignoreList":[1]}
1
+ {"version":3,"sources":["../../../src/app/api/ide/claude/status/route.ts","../../../node_modules/next/dist/esm/build/templates/app-route.js"],"sourcesContent":["import { NextRequest, NextResponse } from 'next/server';\nimport { existsSync, readFileSync } from 'fs';\nimport { join } from 'path';\nimport { homedir } from 'os';\nimport { getDatabase } from '@/db/database';\nimport { getConfig } from '@/db/queries';\n\n// Claude settings.json 文件路径\nconst CLAUDE_DIR = join(homedir(), '.claude');\nconst SETTINGS_FILE = join(CLAUDE_DIR, 'settings.json');\nconst BACKUP_FILE = join(CLAUDE_DIR, 'settings.json.aar.bak');\n\n// AAR 临时配置文件\nconst AAR_DIR = join(homedir(), '.aar');\nconst TEMP_SETTINGS_FILE = join(AAR_DIR, 'settings.tmp.json');\n\n// 默认模型映射(与 apply API 保持一致)\nconst DEFAULT_MODEL_MAPPING = {\n haiku: 'GLM-4.5-air',\n sonnet: 'MiniMax-M2.1',\n opus: 'GLM-4.7',\n default: 'GLM-4.7',\n} as const;\n\ntype ConfigStatus = {\n applied: boolean;\n modelMapping: { haiku?: string; sonnet?: string; opus?: string; default?: string; reasoning?: string };\n gatewayAddress?: string;\n apiKey?: string;\n lastUpdated?: string | null;\n backupExists: boolean;\n matchCurrentGateway?: boolean; // 是否匹配当前网关配置(仅当 routerProvider === 'aar' 时有效)\n routerProvider?: string; // 路由提供者标识,'aar' 表示配置来自当前工具\n tempMapping?: { haiku?: string; sonnet?: string; opus?: string; default?: string; reasoning?: string }; // 临时配置模型映射\n config?: Record<string, unknown>; // 当前配置文件完整内容,用于「生效中」展示\n /** 当前网关地址(来自数据库),用于预览 */\n currentGatewayAddress?: string;\n /** 当前网关 API Key(来自数据库,脱敏),用于预览 */\n currentGatewayApiKey?: string;\n};\n\n/**\n * 查询 Claude IDE 配置状态\n */\nexport async function GET(request: NextRequest) {\n try {\n const settingsFileExists = existsSync(SETTINGS_FILE);\n const backupFileExists = existsSync(BACKUP_FILE);\n\n // 从数据库读取当前网关配置\n await getDatabase();\n const gatewayApiKeyConfig = await getConfig('api_key');\n const portConfig = await getConfig('port');\n const gatewayApiKey = gatewayApiKeyConfig?.value || 'your-gateway-api-key';\n const gatewayAddress = `http://localhost:${portConfig?.value || '1357'}`;\n\n if (!settingsFileExists) {\n // 配置文件不存在,返回未应用状态\n return NextResponse.json({\n applied: false,\n modelMapping: {},\n gatewayAddress: gatewayAddress,\n apiKey: maskApiKey(gatewayApiKey),\n backupExists: false,\n lastUpdated: undefined,\n matchCurrentGateway: false,\n routerProvider: undefined,\n currentGatewayAddress: gatewayAddress,\n currentGatewayApiKey: gatewayApiKey,\n });\n }\n\n // 读取配置文件\n const configContent = readFileSync(SETTINGS_FILE, 'utf-8');\n let config: any;\n try {\n config = JSON.parse(configContent);\n } catch (error: any) {\n return NextResponse.json(\n { error: 'Invalid settings.json format' },\n { status: 500 }\n );\n }\n\n // 检查配置是否匹配当前网关\n const appliedBaseUrl = config.env?.ANTHROPIC_BASE_URL;\n const appliedApiKey = config.env?.ANTHROPIC_AUTH_TOKEN;\n const matchCurrentGateway = appliedBaseUrl === gatewayAddress && appliedApiKey === gatewayApiKey;\n\n // 如果不匹配当前网关,尝试读取临时配置\n let tempMapping: ConfigStatus['tempMapping'] = {};\n if (!matchCurrentGateway) {\n const tempFileExists = existsSync(TEMP_SETTINGS_FILE);\n if (tempFileExists) {\n try {\n const tempContent = readFileSync(TEMP_SETTINGS_FILE, 'utf-8');\n const tempConfig = JSON.parse(tempContent);\n if (tempConfig.modelMapping) {\n tempMapping = tempConfig.modelMapping;\n console.log('[IDE Status] Loading temporary config:', tempMapping);\n }\n } catch (error) {\n console.error('[IDE Status] Failed to parse temp config:', error);\n }\n }\n }\n\n // 提取配置状态;返回完整 config 供前端在非 AAR 时展示原有配置文件\n const status: ConfigStatus = {\n applied: true,\n modelMapping: extractModelMapping(config),\n gatewayAddress: appliedBaseUrl,\n apiKey: maskApiKey(appliedApiKey || gatewayApiKey),\n backupExists: backupFileExists,\n lastUpdated: getFileModTime() || null,\n matchCurrentGateway,\n routerProvider: config.router_provider,\n tempMapping,\n config,\n currentGatewayAddress: gatewayAddress,\n currentGatewayApiKey: gatewayApiKey,\n };\n\n return NextResponse.json(status);\n } catch (error: any) {\n console.error('IDE Status API error:', error);\n return NextResponse.json(\n { error: error.message || 'Internal server error', stack: process.env.NODE_ENV === 'development' ? error.stack : undefined },\n { status: 500 }\n );\n }\n}\n\n/**\n * 脱敏 API KEY\n */\nfunction maskApiKey(apiKey: string): string {\n if (!apiKey || apiKey === 'your-gateway-api-key') {\n return apiKey;\n }\n // 只显示前4位和后4位,中间用****代替\n if (apiKey.length <= 8) {\n // 如果太短,只显示前2位和后2位\n return apiKey.slice(0, 2) + '***' + apiKey.slice(-2);\n }\n return apiKey.slice(0, 4) + '****' + apiKey.slice(-4);\n}\n\n/**\n * 从配置中提取模型映射\n */\nfunction extractModelMapping(config: any): ConfigStatus['modelMapping'] {\n const env = config.env || {};\n const mapping: ConfigStatus['modelMapping'] = {};\n\n if (env.ANTHROPIC_DEFAULT_HAIKU_MODEL) {\n mapping.haiku = env.ANTHROPIC_DEFAULT_HAIKU_MODEL;\n }\n if (env.ANTHROPIC_DEFAULT_SONNET_MODEL) {\n mapping.sonnet = env.ANTHROPIC_DEFAULT_SONNET_MODEL;\n }\n if (env.ANTHROPIC_DEFAULT_OPUS_MODEL) {\n mapping.opus = env.ANTHROPIC_DEFAULT_OPUS_MODEL;\n }\n if (env.ANTHROPIC_MODEL) {\n mapping.default = env.ANTHROPIC_MODEL;\n }\n if (env.ANTHROPIC_REASONING_MODEL) {\n mapping.reasoning = env.ANTHROPIC_REASONING_MODEL;\n }\n\n return mapping;\n}\n\n/**\n * 获取文件修改时间\n */\nfunction getFileModTime(): string | null {\n const { statSync } = require('fs');\n try {\n const stats = statSync(SETTINGS_FILE);\n return new Date(stats.mtime).toISOString();\n } catch (error: any) {\n return null;\n }\n}\n","import { AppRouteRouteModule } from \"next/dist/esm/server/route-modules/app-route/module.compiled\";\nimport { RouteKind } from \"next/dist/esm/server/route-kind\";\nimport { patchFetch as _patchFetch } from \"next/dist/esm/server/lib/patch-fetch\";\nimport { addRequestMeta, getRequestMeta } from \"next/dist/esm/server/request-meta\";\nimport { getTracer, SpanKind } from \"next/dist/esm/server/lib/trace/tracer\";\nimport { setManifestsSingleton } from \"next/dist/esm/server/app-render/manifests-singleton\";\nimport { normalizeAppPath } from \"next/dist/esm/shared/lib/router/utils/app-paths\";\nimport { NodeNextRequest, NodeNextResponse } from \"next/dist/esm/server/base-http/node\";\nimport { NextRequestAdapter, signalFromNodeResponse } from \"next/dist/esm/server/web/spec-extension/adapters/next-request\";\nimport { BaseServerSpan } from \"next/dist/esm/server/lib/trace/constants\";\nimport { getRevalidateReason } from \"next/dist/esm/server/instrumentation/utils\";\nimport { sendResponse } from \"next/dist/esm/server/send-response\";\nimport { fromNodeOutgoingHttpHeaders, toNodeOutgoingHttpHeaders } from \"next/dist/esm/server/web/utils\";\nimport { getCacheControlHeader } from \"next/dist/esm/server/lib/cache-control\";\nimport { INFINITE_CACHE, NEXT_CACHE_TAGS_HEADER } from \"next/dist/esm/lib/constants\";\nimport { NoFallbackError } from \"next/dist/esm/shared/lib/no-fallback-error.external\";\nimport { CachedRouteKind } from \"next/dist/esm/server/response-cache\";\nimport * as userland from \"INNER_APP_ROUTE\";\n// We inject the nextConfigOutput here so that we can use them in the route\n// module.\nconst nextConfigOutput = \"\"\nconst routeModule = new AppRouteRouteModule({\n definition: {\n kind: RouteKind.APP_ROUTE,\n page: \"/api/ide/claude/status/route\",\n pathname: \"/api/ide/claude/status\",\n filename: \"route\",\n bundlePath: \"\"\n },\n distDir: process.env.__NEXT_RELATIVE_DIST_DIR || '',\n relativeProjectDir: process.env.__NEXT_RELATIVE_PROJECT_DIR || '',\n resolvedPagePath: \"[project]/src/app/api/ide/claude/status/route.ts\",\n nextConfigOutput,\n userland\n});\n// Pull out the exports that we need to expose from the module. This should\n// be eliminated when we've moved the other routes to the new format. These\n// are used to hook into the route.\nconst { workAsyncStorage, workUnitAsyncStorage, serverHooks } = routeModule;\nfunction patchFetch() {\n return _patchFetch({\n workAsyncStorage,\n workUnitAsyncStorage\n });\n}\nexport { routeModule, workAsyncStorage, workUnitAsyncStorage, serverHooks, patchFetch, };\nexport async function handler(req, res, ctx) {\n if (routeModule.isDev) {\n addRequestMeta(req, 'devRequestTimingInternalsEnd', process.hrtime.bigint());\n }\n let srcPage = \"/api/ide/claude/status/route\";\n // turbopack doesn't normalize `/index` in the page name\n // so we need to to process dynamic routes properly\n // TODO: fix turbopack providing differing value from webpack\n if (process.env.TURBOPACK) {\n srcPage = srcPage.replace(/\\/index$/, '') || '/';\n } else if (srcPage === '/index') {\n // we always normalize /index specifically\n srcPage = '/';\n }\n const multiZoneDraftMode = process.env.__NEXT_MULTI_ZONE_DRAFT_MODE;\n const prepareResult = await routeModule.prepare(req, res, {\n srcPage,\n multiZoneDraftMode\n });\n if (!prepareResult) {\n res.statusCode = 400;\n res.end('Bad Request');\n ctx.waitUntil == null ? void 0 : ctx.waitUntil.call(ctx, Promise.resolve());\n return null;\n }\n const { buildId, params, nextConfig, parsedUrl, isDraftMode, prerenderManifest, routerServerContext, isOnDemandRevalidate, revalidateOnlyGenerated, resolvedPathname, clientReferenceManifest, serverActionsManifest } = prepareResult;\n const normalizedSrcPage = normalizeAppPath(srcPage);\n let isIsr = Boolean(prerenderManifest.dynamicRoutes[normalizedSrcPage] || prerenderManifest.routes[resolvedPathname]);\n const render404 = async ()=>{\n // TODO: should route-module itself handle rendering the 404\n if (routerServerContext == null ? void 0 : routerServerContext.render404) {\n await routerServerContext.render404(req, res, parsedUrl, false);\n } else {\n res.end('This page could not be found');\n }\n return null;\n };\n if (isIsr && !isDraftMode) {\n const isPrerendered = Boolean(prerenderManifest.routes[resolvedPathname]);\n const prerenderInfo = prerenderManifest.dynamicRoutes[normalizedSrcPage];\n if (prerenderInfo) {\n if (prerenderInfo.fallback === false && !isPrerendered) {\n if (nextConfig.experimental.adapterPath) {\n return await render404();\n }\n throw new NoFallbackError();\n }\n }\n }\n let cacheKey = null;\n if (isIsr && !routeModule.isDev && !isDraftMode) {\n cacheKey = resolvedPathname;\n // ensure /index and / is normalized to one key\n cacheKey = cacheKey === '/index' ? '/' : cacheKey;\n }\n const supportsDynamicResponse = // If we're in development, we always support dynamic HTML\n routeModule.isDev === true || // If this is not SSG or does not have static paths, then it supports\n // dynamic HTML.\n !isIsr;\n // This is a revalidation request if the request is for a static\n // page and it is not being resumed from a postponed render and\n // it is not a dynamic RSC request then it is a revalidation\n // request.\n const isStaticGeneration = isIsr && !supportsDynamicResponse;\n // Before rendering (which initializes component tree modules), we have to\n // set the reference manifests to our global store so Server Action's\n // encryption util can access to them at the top level of the page module.\n if (serverActionsManifest && clientReferenceManifest) {\n setManifestsSingleton({\n page: srcPage,\n clientReferenceManifest,\n serverActionsManifest\n });\n }\n const method = req.method || 'GET';\n const tracer = getTracer();\n const activeSpan = tracer.getActiveScopeSpan();\n const context = {\n params,\n prerenderManifest,\n renderOpts: {\n experimental: {\n authInterrupts: Boolean(nextConfig.experimental.authInterrupts)\n },\n cacheComponents: Boolean(nextConfig.cacheComponents),\n supportsDynamicResponse,\n incrementalCache: getRequestMeta(req, 'incrementalCache'),\n cacheLifeProfiles: nextConfig.cacheLife,\n waitUntil: ctx.waitUntil,\n onClose: (cb)=>{\n res.on('close', cb);\n },\n onAfterTaskError: undefined,\n onInstrumentationRequestError: (error, _request, errorContext, silenceLog)=>routeModule.onRequestError(req, error, errorContext, silenceLog, routerServerContext)\n },\n sharedContext: {\n buildId\n }\n };\n const nodeNextReq = new NodeNextRequest(req);\n const nodeNextRes = new NodeNextResponse(res);\n const nextReq = NextRequestAdapter.fromNodeNextRequest(nodeNextReq, signalFromNodeResponse(res));\n try {\n const invokeRouteModule = async (span)=>{\n return routeModule.handle(nextReq, context).finally(()=>{\n if (!span) return;\n span.setAttributes({\n 'http.status_code': res.statusCode,\n 'next.rsc': false\n });\n const rootSpanAttributes = tracer.getRootSpanAttributes();\n // We were unable to get attributes, probably OTEL is not enabled\n if (!rootSpanAttributes) {\n return;\n }\n if (rootSpanAttributes.get('next.span_type') !== BaseServerSpan.handleRequest) {\n console.warn(`Unexpected root span type '${rootSpanAttributes.get('next.span_type')}'. Please report this Next.js issue https://github.com/vercel/next.js`);\n return;\n }\n const route = rootSpanAttributes.get('next.route');\n if (route) {\n const name = `${method} ${route}`;\n span.setAttributes({\n 'next.route': route,\n 'http.route': route,\n 'next.span_name': name\n });\n span.updateName(name);\n } else {\n span.updateName(`${method} ${srcPage}`);\n }\n });\n };\n const isMinimalMode = Boolean(process.env.MINIMAL_MODE || getRequestMeta(req, 'minimalMode'));\n const handleResponse = async (currentSpan)=>{\n var _cacheEntry_value;\n const responseGenerator = async ({ previousCacheEntry })=>{\n try {\n if (!isMinimalMode && isOnDemandRevalidate && revalidateOnlyGenerated && !previousCacheEntry) {\n res.statusCode = 404;\n // on-demand revalidate always sets this header\n res.setHeader('x-nextjs-cache', 'REVALIDATED');\n res.end('This page could not be found');\n return null;\n }\n const response = await invokeRouteModule(currentSpan);\n req.fetchMetrics = context.renderOpts.fetchMetrics;\n let pendingWaitUntil = context.renderOpts.pendingWaitUntil;\n // Attempt using provided waitUntil if available\n // if it's not we fallback to sendResponse's handling\n if (pendingWaitUntil) {\n if (ctx.waitUntil) {\n ctx.waitUntil(pendingWaitUntil);\n pendingWaitUntil = undefined;\n }\n }\n const cacheTags = context.renderOpts.collectedTags;\n // If the request is for a static response, we can cache it so long\n // as it's not edge.\n if (isIsr) {\n const blob = await response.blob();\n // Copy the headers from the response.\n const headers = toNodeOutgoingHttpHeaders(response.headers);\n if (cacheTags) {\n headers[NEXT_CACHE_TAGS_HEADER] = cacheTags;\n }\n if (!headers['content-type'] && blob.type) {\n headers['content-type'] = blob.type;\n }\n const revalidate = typeof context.renderOpts.collectedRevalidate === 'undefined' || context.renderOpts.collectedRevalidate >= INFINITE_CACHE ? false : context.renderOpts.collectedRevalidate;\n const expire = typeof context.renderOpts.collectedExpire === 'undefined' || context.renderOpts.collectedExpire >= INFINITE_CACHE ? undefined : context.renderOpts.collectedExpire;\n // Create the cache entry for the response.\n const cacheEntry = {\n value: {\n kind: CachedRouteKind.APP_ROUTE,\n status: response.status,\n body: Buffer.from(await blob.arrayBuffer()),\n headers\n },\n cacheControl: {\n revalidate,\n expire\n }\n };\n return cacheEntry;\n } else {\n // send response without caching if not ISR\n await sendResponse(nodeNextReq, nodeNextRes, response, context.renderOpts.pendingWaitUntil);\n return null;\n }\n } catch (err) {\n // if this is a background revalidate we need to report\n // the request error here as it won't be bubbled\n if (previousCacheEntry == null ? void 0 : previousCacheEntry.isStale) {\n const silenceLog = false;\n await routeModule.onRequestError(req, err, {\n routerKind: 'App Router',\n routePath: srcPage,\n routeType: 'route',\n revalidateReason: getRevalidateReason({\n isStaticGeneration,\n isOnDemandRevalidate\n })\n }, silenceLog, routerServerContext);\n }\n throw err;\n }\n };\n const cacheEntry = await routeModule.handleResponse({\n req,\n nextConfig,\n cacheKey,\n routeKind: RouteKind.APP_ROUTE,\n isFallback: false,\n prerenderManifest,\n isRoutePPREnabled: false,\n isOnDemandRevalidate,\n revalidateOnlyGenerated,\n responseGenerator,\n waitUntil: ctx.waitUntil,\n isMinimalMode\n });\n // we don't create a cacheEntry for ISR\n if (!isIsr) {\n return null;\n }\n if ((cacheEntry == null ? void 0 : (_cacheEntry_value = cacheEntry.value) == null ? void 0 : _cacheEntry_value.kind) !== CachedRouteKind.APP_ROUTE) {\n var _cacheEntry_value1;\n throw Object.defineProperty(new Error(`Invariant: app-route received invalid cache entry ${cacheEntry == null ? void 0 : (_cacheEntry_value1 = cacheEntry.value) == null ? void 0 : _cacheEntry_value1.kind}`), \"__NEXT_ERROR_CODE\", {\n value: \"E701\",\n enumerable: false,\n configurable: true\n });\n }\n if (!isMinimalMode) {\n res.setHeader('x-nextjs-cache', isOnDemandRevalidate ? 'REVALIDATED' : cacheEntry.isMiss ? 'MISS' : cacheEntry.isStale ? 'STALE' : 'HIT');\n }\n // Draft mode should never be cached\n if (isDraftMode) {\n res.setHeader('Cache-Control', 'private, no-cache, no-store, max-age=0, must-revalidate');\n }\n const headers = fromNodeOutgoingHttpHeaders(cacheEntry.value.headers);\n if (!(isMinimalMode && isIsr)) {\n headers.delete(NEXT_CACHE_TAGS_HEADER);\n }\n // If cache control is already set on the response we don't\n // override it to allow users to customize it via next.config\n if (cacheEntry.cacheControl && !res.getHeader('Cache-Control') && !headers.get('Cache-Control')) {\n headers.set('Cache-Control', getCacheControlHeader(cacheEntry.cacheControl));\n }\n await sendResponse(nodeNextReq, nodeNextRes, // @ts-expect-error - Argument of type 'Buffer<ArrayBufferLike>' is not assignable to parameter of type 'BodyInit | null | undefined'.\n new Response(cacheEntry.value.body, {\n headers,\n status: cacheEntry.value.status || 200\n }));\n return null;\n };\n // TODO: activeSpan code path is for when wrapped by\n // next-server can be removed when this is no longer used\n if (activeSpan) {\n await handleResponse(activeSpan);\n } else {\n await tracer.withPropagatedContext(req.headers, ()=>tracer.trace(BaseServerSpan.handleRequest, {\n spanName: `${method} ${srcPage}`,\n kind: SpanKind.SERVER,\n attributes: {\n 'http.method': method,\n 'http.target': req.url\n }\n }, handleResponse));\n }\n } catch (err) {\n if (!(err instanceof NoFallbackError)) {\n const silenceLog = false;\n await routeModule.onRequestError(req, err, {\n routerKind: 'App Router',\n routePath: normalizedSrcPage,\n routeType: 'route',\n revalidateReason: getRevalidateReason({\n isStaticGeneration,\n isOnDemandRevalidate\n })\n }, silenceLog, routerServerContext);\n }\n // rethrow so that we can handle serving error page\n // If this is during static generation, throw the error again.\n if (isIsr) throw err;\n // Otherwise, send a 500 response.\n await sendResponse(nodeNextReq, nodeNextRes, new Response(null, {\n status: 500\n }));\n return null;\n }\n}\n\n//# sourceMappingURL=app-route.js.map\n"],"names":[],"mappings":"8iCCAA,IAAA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,CAAA,CAAA,OACA,EAAA,EAAA,C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G,EAAO,CAAC,EAAE,EAAA,CAAS,CAChC,KAAM,EAAA,QAAQ,CAAC,MAAM,CACrB,WAAY,CACR,cAAe,EACf,cAAe,EAAI,GAAG,AAC1B,CACJ,EAAG,GAEf,CAAE,MAAO,EAAK,CAeV,GAdM,aAAe,EAAA,eAAe,EAEhC,CAFmC,KAE7B,EAAY,cAAc,CAAC,EAAK,EAAK,CACvC,WAAY,aACZ,UAAW,EACX,UAAW,QACX,iBAAkB,CAAA,EAAA,EAAA,mBAAA,AAAmB,EAAC,oBAClC,EACA,sBACJ,EACJ,GAAG,AATgB,EASJ,GAIf,EAAO,MAAM,EAKjB,OAHA,MAAM,CAAA,EAAA,EAAA,YAAA,AAAY,EAAC,EAAa,EAAa,IAAI,SAAS,KAAM,CAC5D,OAAQ,GACZ,IACO,IACX,CACJ,EAEA,qCAAqC","ignoreList":[1]}
@@ -0,0 +1,3 @@
1
+ module.exports=[80727,(e,o,d)=>{}];
2
+
3
+ //# sourceMappingURL=_next-internal_server_app_api_ide_openclaw_apply_route_actions_2cb9e4b4.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ module.exports=[61058,(e,o,d)=>{}];
2
+
3
+ //# sourceMappingURL=_next-internal_server_app_api_ide_openclaw_preview_route_actions_9814a8e4.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ module.exports=[50104,(e,o,d)=>{}];
2
+
3
+ //# sourceMappingURL=_next-internal_server_app_api_ide_openclaw_restore_route_actions_10ad8f9d.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ module.exports=[21761,(e,o,d)=>{}];
2
+
3
+ //# sourceMappingURL=_next-internal_server_app_api_ide_openclaw_save_route_actions_044ad081.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ module.exports=[29938,(e,o,d)=>{}];
2
+
3
+ //# sourceMappingURL=_next-internal_server_app_api_ide_openclaw_status_route_actions_ed9786d2.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ module.exports=[62021,(e,o,d)=>{}];
2
+
3
+ //# sourceMappingURL=_next-internal_server_app_api_ide_openclaw_test_route_actions_ce2cb808.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ module.exports=[64366,(e,o,d)=>{}];
2
+
3
+ //# sourceMappingURL=_next-internal_server_app_api_ide_opencode_apply_route_actions_6c422244.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ module.exports=[42137,(e,o,d)=>{}];
2
+
3
+ //# sourceMappingURL=_next-internal_server_app_api_ide_opencode_preview_route_actions_256c82e0.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ module.exports=[1971,(e,o,d)=>{}];
2
+
3
+ //# sourceMappingURL=_next-internal_server_app_api_ide_opencode_restore_route_actions_371993d3.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ module.exports=[36913,(e,o,d)=>{}];
2
+
3
+ //# sourceMappingURL=_next-internal_server_app_api_ide_opencode_save_route_actions_6e4c9c41.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ module.exports=[64282,(e,o,d)=>{}];
2
+
3
+ //# sourceMappingURL=_next-internal_server_app_api_ide_opencode_status_route_actions_498ad77b.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ module.exports=[17433,(e,o,d)=>{}];
2
+
3
+ //# sourceMappingURL=_next-internal_server_app_api_ide_opencode_test_route_actions_c71be510.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ module.exports=[74098,(e,o,d)=>{}];
2
+
3
+ //# sourceMappingURL=ce889_server_app_api_ide_openclaw_available-models_route_actions_e568e70b.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":""}
@@ -0,0 +1,3 @@
1
+ module.exports=[34640,(e,o,d)=>{}];
2
+
3
+ //# sourceMappingURL=ce889_server_app_api_ide_opencode_available-models_route_actions_95230db3.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":[],"names":[],"mappings":""}
@@ -1,3 +1,3 @@
1
- module.exports=[24951,(a,b,c)=>{"use strict";b.exports=a.r(18622)},11857,(a,b,c)=>{"use strict";b.exports=a.r(24951).vendored["react-rsc"].ReactServerDOMTurbopackServer},20635,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/action-async-storage.external.js",()=>require("next/dist/server/app-render/action-async-storage.external.js"))},43285,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/dynamic-access-async-storage.external.js",()=>require("next/dist/server/app-render/dynamic-access-async-storage.external.js"))},14747,(a,b,c)=>{b.exports=a.x("path",()=>require("path"))},70406,(a,b,c)=>{b.exports=a.x("next/dist/compiled/@opentelemetry/api",()=>require("next/dist/compiled/@opentelemetry/api"))},18622,(a,b,c)=>{b.exports=a.x("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js",()=>require("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js"))},56704,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/work-async-storage.external.js",()=>require("next/dist/server/app-render/work-async-storage.external.js"))},32319,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/work-unit-async-storage.external.js",()=>require("next/dist/server/app-render/work-unit-async-storage.external.js"))},24725,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/after-task-async-storage.external.js",()=>require("next/dist/server/app-render/after-task-async-storage.external.js"))},24361,(a,b,c)=>{b.exports=a.x("util",()=>require("util"))},7997,(a,b,c)=>{"use strict";b.exports=a.r(24951).vendored["react-rsc"].ReactJsxRuntime},717,(a,b,c)=>{"use strict";b.exports=a.r(24951).vendored["react-rsc"].React}];
1
+ module.exports=[14747,(a,b,c)=>{b.exports=a.x("path",()=>require("path"))},70406,(a,b,c)=>{b.exports=a.x("next/dist/compiled/@opentelemetry/api",()=>require("next/dist/compiled/@opentelemetry/api"))},18622,(a,b,c)=>{b.exports=a.x("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js",()=>require("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js"))},56704,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/work-async-storage.external.js",()=>require("next/dist/server/app-render/work-async-storage.external.js"))},32319,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/work-unit-async-storage.external.js",()=>require("next/dist/server/app-render/work-unit-async-storage.external.js"))},24725,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/after-task-async-storage.external.js",()=>require("next/dist/server/app-render/after-task-async-storage.external.js"))},24951,(a,b,c)=>{"use strict";b.exports=a.r(18622)},11857,(a,b,c)=>{"use strict";b.exports=a.r(24951).vendored["react-rsc"].ReactServerDOMTurbopackServer},20635,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/action-async-storage.external.js",()=>require("next/dist/server/app-render/action-async-storage.external.js"))},43285,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/dynamic-access-async-storage.external.js",()=>require("next/dist/server/app-render/dynamic-access-async-storage.external.js"))},24361,(a,b,c)=>{b.exports=a.x("util",()=>require("util"))},7997,(a,b,c)=>{"use strict";b.exports=a.r(24951).vendored["react-rsc"].ReactJsxRuntime},717,(a,b,c)=>{"use strict";b.exports=a.r(24951).vendored["react-rsc"].React}];
2
2
 
3
- //# sourceMappingURL=%5Broot-of-the-server%5D__bec95712._.js.map
3
+ //# sourceMappingURL=%5Broot-of-the-server%5D__81937253._.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../node_modules/next/src/server/route-modules/app-page/module.compiled.js","../../../../node_modules/next/src/server/route-modules/app-page/vendored/rsc/react-server-dom-turbopack-server.ts","../../../../node_modules/next/src/server/route-modules/app-page/vendored/rsc/react-jsx-runtime.ts","../../../../node_modules/next/src/server/route-modules/app-page/vendored/rsc/react.ts"],"sourcesContent":["if (process.env.NEXT_RUNTIME === 'edge') {\n module.exports = require('next/dist/server/route-modules/app-page/module.js')\n} else {\n if (process.env.__NEXT_EXPERIMENTAL_REACT) {\n if (process.env.NODE_ENV === 'development') {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo-experimental.runtime.dev.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page-experimental.runtime.dev.js')\n }\n } else {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo-experimental.runtime.prod.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page-experimental.runtime.prod.js')\n }\n }\n } else {\n if (process.env.NODE_ENV === 'development') {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo.runtime.dev.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page.runtime.dev.js')\n }\n } else {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo.runtime.prod.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page.runtime.prod.js')\n }\n }\n }\n}\n","module.exports = (\n require('../../module.compiled') as typeof import('../../module.compiled')\n).vendored['react-rsc']!.ReactServerDOMTurbopackServer\n","module.exports = (\n require('../../module.compiled') as typeof import('../../module.compiled')\n).vendored['react-rsc']!.ReactJsxRuntime\n","module.exports = (\n require('../../module.compiled') as typeof import('../../module.compiled')\n).vendored['react-rsc']!.React\n"],"names":["process","env","NEXT_RUNTIME","module","exports","require","__NEXT_EXPERIMENTAL_REACT","NODE_ENV","TURBOPACK","vendored","ReactServerDOMTurbopackServer","ReactJsxRuntime","React"],"mappings":"6CA0BQG,EAAOC,OAAO,CAAGC,EAAQ,CAAA,CAAA,IAAA,iCC1BjCF,EAAOC,OAAO,CACZC,EAAQ,CAAA,CAAA,IAAA,GACRI,QAAQ,CAAC,YAAY,CAAEC,6BAA6B,+yCCFtDP,EAAOC,OAAO,CACZC,EAAQ,CAAA,CAAA,IAAA,GACRI,QAAQ,CAAC,YAAY,CAAEE,eAAe,6BCFxCR,EAAOC,OAAO,CACZC,EAAQ,CAAA,CAAA,IAAA,GACRI,QAAQ,CAAC,YAAY,CAAEG,KAAK","ignoreList":[0,1,2,3]}
1
+ {"version":3,"sources":["../../../../node_modules/next/src/server/route-modules/app-page/module.compiled.js","../../../../node_modules/next/src/server/route-modules/app-page/vendored/rsc/react-server-dom-turbopack-server.ts","../../../../node_modules/next/src/server/route-modules/app-page/vendored/rsc/react-jsx-runtime.ts","../../../../node_modules/next/src/server/route-modules/app-page/vendored/rsc/react.ts"],"sourcesContent":["if (process.env.NEXT_RUNTIME === 'edge') {\n module.exports = require('next/dist/server/route-modules/app-page/module.js')\n} else {\n if (process.env.__NEXT_EXPERIMENTAL_REACT) {\n if (process.env.NODE_ENV === 'development') {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo-experimental.runtime.dev.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page-experimental.runtime.dev.js')\n }\n } else {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo-experimental.runtime.prod.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page-experimental.runtime.prod.js')\n }\n }\n } else {\n if (process.env.NODE_ENV === 'development') {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo.runtime.dev.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page.runtime.dev.js')\n }\n } else {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo.runtime.prod.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page.runtime.prod.js')\n }\n }\n }\n}\n","module.exports = (\n require('../../module.compiled') as typeof import('../../module.compiled')\n).vendored['react-rsc']!.ReactServerDOMTurbopackServer\n","module.exports = (\n require('../../module.compiled') as typeof import('../../module.compiled')\n).vendored['react-rsc']!.ReactJsxRuntime\n","module.exports = (\n require('../../module.compiled') as typeof import('../../module.compiled')\n).vendored['react-rsc']!.React\n"],"names":["process","env","NEXT_RUNTIME","module","exports","require","__NEXT_EXPERIMENTAL_REACT","NODE_ENV","TURBOPACK","vendored","ReactServerDOMTurbopackServer","ReactJsxRuntime","React"],"mappings":"45BA0BQG,GAAOC,OAAO,CAAGC,EAAQ,CAAA,CAAA,IAAA,iCC1BjCF,EAAOC,OAAO,CACZC,EAAQ,CAAA,CAAA,IAAA,GACRI,QAAQ,CAAC,YAAY,CAAEC,6BAA6B,+bCFtDP,EAAOC,OAAO,CACZC,EAAQ,CAAA,CAAA,IAAA,GACRI,QAAQ,CAAC,YAAY,CAAEE,eAAe,6BCFxCR,EAAOC,OAAO,CACZC,EAAQ,CAAA,CAAA,IAAA,GACRI,QAAQ,CAAC,YAAY,CAAEG,KAAK","ignoreList":[0,1,2,3]}
@@ -1,3 +1,3 @@
1
- module.exports=[24951,(a,b,c)=>{"use strict";b.exports=a.r(18622)},11857,(a,b,c)=>{"use strict";b.exports=a.r(24951).vendored["react-rsc"].ReactServerDOMTurbopackServer},20635,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/action-async-storage.external.js",()=>require("next/dist/server/app-render/action-async-storage.external.js"))},43285,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/dynamic-access-async-storage.external.js",()=>require("next/dist/server/app-render/dynamic-access-async-storage.external.js"))},14747,(a,b,c)=>{b.exports=a.x("path",()=>require("path"))},70406,(a,b,c)=>{b.exports=a.x("next/dist/compiled/@opentelemetry/api",()=>require("next/dist/compiled/@opentelemetry/api"))},18622,(a,b,c)=>{b.exports=a.x("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js",()=>require("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js"))},56704,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/work-async-storage.external.js",()=>require("next/dist/server/app-render/work-async-storage.external.js"))},32319,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/work-unit-async-storage.external.js",()=>require("next/dist/server/app-render/work-unit-async-storage.external.js"))},24725,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/after-task-async-storage.external.js",()=>require("next/dist/server/app-render/after-task-async-storage.external.js"))},24361,(a,b,c)=>{b.exports=a.x("util",()=>require("util"))},7997,(a,b,c)=>{"use strict";b.exports=a.r(24951).vendored["react-rsc"].ReactJsxRuntime},717,(a,b,c)=>{"use strict";b.exports=a.r(24951).vendored["react-rsc"].React},4276,(a,b,c)=>{let{createClientModuleProxy:d}=a.r(11857);a.n(d("[project]/node_modules/next/dist/client/components/builtin/global-error.js <module evaluation>"))},82509,(a,b,c)=>{let{createClientModuleProxy:d}=a.r(11857);a.n(d("[project]/node_modules/next/dist/client/components/builtin/global-error.js"))},66114,a=>{"use strict";a.i(4276);var b=a.i(82509);a.n(b)}];
1
+ module.exports=[14747,(a,b,c)=>{b.exports=a.x("path",()=>require("path"))},70406,(a,b,c)=>{b.exports=a.x("next/dist/compiled/@opentelemetry/api",()=>require("next/dist/compiled/@opentelemetry/api"))},18622,(a,b,c)=>{b.exports=a.x("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js",()=>require("next/dist/compiled/next-server/app-page-turbo.runtime.prod.js"))},56704,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/work-async-storage.external.js",()=>require("next/dist/server/app-render/work-async-storage.external.js"))},32319,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/work-unit-async-storage.external.js",()=>require("next/dist/server/app-render/work-unit-async-storage.external.js"))},24725,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/after-task-async-storage.external.js",()=>require("next/dist/server/app-render/after-task-async-storage.external.js"))},24951,(a,b,c)=>{"use strict";b.exports=a.r(18622)},11857,(a,b,c)=>{"use strict";b.exports=a.r(24951).vendored["react-rsc"].ReactServerDOMTurbopackServer},20635,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/action-async-storage.external.js",()=>require("next/dist/server/app-render/action-async-storage.external.js"))},43285,(a,b,c)=>{b.exports=a.x("next/dist/server/app-render/dynamic-access-async-storage.external.js",()=>require("next/dist/server/app-render/dynamic-access-async-storage.external.js"))},24361,(a,b,c)=>{b.exports=a.x("util",()=>require("util"))},7997,(a,b,c)=>{"use strict";b.exports=a.r(24951).vendored["react-rsc"].ReactJsxRuntime},717,(a,b,c)=>{"use strict";b.exports=a.r(24951).vendored["react-rsc"].React},4276,(a,b,c)=>{let{createClientModuleProxy:d}=a.r(11857);a.n(d("[project]/node_modules/next/dist/client/components/builtin/global-error.js <module evaluation>"))},82509,(a,b,c)=>{let{createClientModuleProxy:d}=a.r(11857);a.n(d("[project]/node_modules/next/dist/client/components/builtin/global-error.js"))},66114,a=>{"use strict";a.i(4276);var b=a.i(82509);a.n(b)}];
2
2
 
3
- //# sourceMappingURL=%5Broot-of-the-server%5D__71c85955._.js.map
3
+ //# sourceMappingURL=%5Broot-of-the-server%5D__976ad963._.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../node_modules/next/src/server/route-modules/app-page/module.compiled.js","../../../../node_modules/next/src/server/route-modules/app-page/vendored/rsc/react-server-dom-turbopack-server.ts","../../../../node_modules/next/src/server/route-modules/app-page/vendored/rsc/react-jsx-runtime.ts","../../../../node_modules/next/src/server/route-modules/app-page/vendored/rsc/react.ts","../../../../node_modules/next/dist/client/components/builtin/global-error.js/__nextjs-internal-proxy.cjs","../../../../node_modules/next/src/client/components/builtin/global-error.tsx"],"sourcesContent":["if (process.env.NEXT_RUNTIME === 'edge') {\n module.exports = require('next/dist/server/route-modules/app-page/module.js')\n} else {\n if (process.env.__NEXT_EXPERIMENTAL_REACT) {\n if (process.env.NODE_ENV === 'development') {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo-experimental.runtime.dev.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page-experimental.runtime.dev.js')\n }\n } else {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo-experimental.runtime.prod.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page-experimental.runtime.prod.js')\n }\n }\n } else {\n if (process.env.NODE_ENV === 'development') {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo.runtime.dev.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page.runtime.dev.js')\n }\n } else {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo.runtime.prod.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page.runtime.prod.js')\n }\n }\n }\n}\n","module.exports = (\n require('../../module.compiled') as typeof import('../../module.compiled')\n).vendored['react-rsc']!.ReactServerDOMTurbopackServer\n","module.exports = (\n require('../../module.compiled') as typeof import('../../module.compiled')\n).vendored['react-rsc']!.ReactJsxRuntime\n","module.exports = (\n require('../../module.compiled') as typeof import('../../module.compiled')\n).vendored['react-rsc']!.React\n","// This file is generated by next-core EcmascriptClientReferenceModule.\nconst { createClientModuleProxy } = require(\"react-server-dom-turbopack/server\");\n\n__turbopack_context__.n(createClientModuleProxy(\"[project]/node_modules/next/dist/client/components/builtin/global-error.js\"));\n","'use client'\n\nimport { HandleISRError } from '../handle-isr-error'\n\nconst styles = {\n error: {\n // https://github.com/sindresorhus/modern-normalize/blob/main/modern-normalize.css#L38-L52\n fontFamily:\n 'system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"',\n height: '100vh',\n textAlign: 'center',\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n justifyContent: 'center',\n },\n text: {\n fontSize: '14px',\n fontWeight: 400,\n lineHeight: '28px',\n margin: '0 8px',\n },\n} as const\n\nexport type GlobalErrorComponent = React.ComponentType<{\n error: any\n}>\nfunction DefaultGlobalError({ error }: { error: any }) {\n const digest: string | undefined = error?.digest\n return (\n <html id=\"__next_error__\">\n <head></head>\n <body>\n <HandleISRError error={error} />\n <div style={styles.error}>\n <div>\n <h2 style={styles.text}>\n Application error: a {digest ? 'server' : 'client'}-side exception\n has occurred while loading {window.location.hostname} (see the{' '}\n {digest ? 'server logs' : 'browser console'} for more\n information).\n </h2>\n {digest ? <p style={styles.text}>{`Digest: ${digest}`}</p> : null}\n </div>\n </div>\n </body>\n </html>\n )\n}\n\n// Exported so that the import signature in the loaders can be identical to user\n// supplied custom global error signatures.\nexport default DefaultGlobalError\n"],"names":["process","env","NEXT_RUNTIME","module","exports","require","__NEXT_EXPERIMENTAL_REACT","NODE_ENV","TURBOPACK","vendored","ReactServerDOMTurbopackServer","ReactJsxRuntime","React","styles","error","fontFamily","height","textAlign","display","flexDirection","alignItems","justifyContent","text","fontSize","fontWeight","lineHeight","margin","DefaultGlobalError","digest","html","id","head","body","HandleISRError","div","style","h2","window","location","hostname","p"],"mappings":"6CA0BQG,EAAOC,OAAO,CAAGC,EAAQ,CAAA,CAAA,IAAA,iCC1BjCF,EAAOC,OAAO,CACZC,EAAQ,CAAA,CAAA,IAAA,GACRI,QAAQ,CAAC,YAAY,CAAEC,6BAA6B,+yCCFtDP,EAAOC,OAAO,CACZC,EAAQ,CAAA,CAAA,IAAA,GACRI,QAAQ,CAAC,YAAY,CAAEE,eAAe,6BCFxCR,EAAOC,OAAO,CACZC,EAAQ,CAAA,CAAA,IAAA,GACRI,QAAQ,CAAC,YAAY,CAAEG,KAAK,iBCD9B,GAAM,yBAAE,CAAuB,CAAE,CAAA,EAAA,CAAA,CAAA,OAEjC,EAAsB,CAAC,CAAC,EAAwB,oHAFhD,GAAM,yBAAE,CAAuB,CAAE,CAAA,EAAA,CAAA,CAAA,OAEjC,EAAsB,CAAC,CAAC,EAAwB","ignoreList":[0,1,2,3,4]}
1
+ {"version":3,"sources":["../../../../node_modules/next/src/server/route-modules/app-page/module.compiled.js","../../../../node_modules/next/src/server/route-modules/app-page/vendored/rsc/react-server-dom-turbopack-server.ts","../../../../node_modules/next/src/server/route-modules/app-page/vendored/rsc/react-jsx-runtime.ts","../../../../node_modules/next/src/server/route-modules/app-page/vendored/rsc/react.ts","../../../../node_modules/next/dist/client/components/builtin/global-error.js/__nextjs-internal-proxy.cjs","../../../../node_modules/next/src/client/components/builtin/global-error.tsx"],"sourcesContent":["if (process.env.NEXT_RUNTIME === 'edge') {\n module.exports = require('next/dist/server/route-modules/app-page/module.js')\n} else {\n if (process.env.__NEXT_EXPERIMENTAL_REACT) {\n if (process.env.NODE_ENV === 'development') {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo-experimental.runtime.dev.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page-experimental.runtime.dev.js')\n }\n } else {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo-experimental.runtime.prod.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page-experimental.runtime.prod.js')\n }\n }\n } else {\n if (process.env.NODE_ENV === 'development') {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo.runtime.dev.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page.runtime.dev.js')\n }\n } else {\n if (process.env.TURBOPACK) {\n module.exports = require('next/dist/compiled/next-server/app-page-turbo.runtime.prod.js')\n } else {\n module.exports = require('next/dist/compiled/next-server/app-page.runtime.prod.js')\n }\n }\n }\n}\n","module.exports = (\n require('../../module.compiled') as typeof import('../../module.compiled')\n).vendored['react-rsc']!.ReactServerDOMTurbopackServer\n","module.exports = (\n require('../../module.compiled') as typeof import('../../module.compiled')\n).vendored['react-rsc']!.ReactJsxRuntime\n","module.exports = (\n require('../../module.compiled') as typeof import('../../module.compiled')\n).vendored['react-rsc']!.React\n","// This file is generated by next-core EcmascriptClientReferenceModule.\nconst { createClientModuleProxy } = require(\"react-server-dom-turbopack/server\");\n\n__turbopack_context__.n(createClientModuleProxy(\"[project]/node_modules/next/dist/client/components/builtin/global-error.js\"));\n","'use client'\n\nimport { HandleISRError } from '../handle-isr-error'\n\nconst styles = {\n error: {\n // https://github.com/sindresorhus/modern-normalize/blob/main/modern-normalize.css#L38-L52\n fontFamily:\n 'system-ui,\"Segoe UI\",Roboto,Helvetica,Arial,sans-serif,\"Apple Color Emoji\",\"Segoe UI Emoji\"',\n height: '100vh',\n textAlign: 'center',\n display: 'flex',\n flexDirection: 'column',\n alignItems: 'center',\n justifyContent: 'center',\n },\n text: {\n fontSize: '14px',\n fontWeight: 400,\n lineHeight: '28px',\n margin: '0 8px',\n },\n} as const\n\nexport type GlobalErrorComponent = React.ComponentType<{\n error: any\n}>\nfunction DefaultGlobalError({ error }: { error: any }) {\n const digest: string | undefined = error?.digest\n return (\n <html id=\"__next_error__\">\n <head></head>\n <body>\n <HandleISRError error={error} />\n <div style={styles.error}>\n <div>\n <h2 style={styles.text}>\n Application error: a {digest ? 'server' : 'client'}-side exception\n has occurred while loading {window.location.hostname} (see the{' '}\n {digest ? 'server logs' : 'browser console'} for more\n information).\n </h2>\n {digest ? <p style={styles.text}>{`Digest: ${digest}`}</p> : null}\n </div>\n </div>\n </body>\n </html>\n )\n}\n\n// Exported so that the import signature in the loaders can be identical to user\n// supplied custom global error signatures.\nexport default DefaultGlobalError\n"],"names":["process","env","NEXT_RUNTIME","module","exports","require","__NEXT_EXPERIMENTAL_REACT","NODE_ENV","TURBOPACK","vendored","ReactServerDOMTurbopackServer","ReactJsxRuntime","React","styles","error","fontFamily","height","textAlign","display","flexDirection","alignItems","justifyContent","text","fontSize","fontWeight","lineHeight","margin","DefaultGlobalError","digest","html","id","head","body","HandleISRError","div","style","h2","window","location","hostname","p"],"mappings":"45BA0BQG,GAAOC,OAAO,CAAGC,EAAQ,CAAA,CAAA,IAAA,iCC1BjCF,EAAOC,OAAO,CACZC,EAAQ,CAAA,CAAA,IAAA,GACRI,QAAQ,CAAC,YAAY,CAAEC,6BAA6B,+bCFtDP,EAAOC,OAAO,CACZC,EAAQ,CAAA,CAAA,IAAA,GACRI,QAAQ,CAAC,YAAY,CAAEE,eAAe,6BCFxCR,EAAOC,OAAO,CACZC,EAAQ,CAAA,CAAA,IAAA,GACRI,QAAQ,CAAC,YAAY,CAAEG,KAAK,iBCD9B,GAAM,yBAAE,CAAuB,CAAE,CAAA,EAAA,CAAA,CAAA,OAEjC,EAAsB,CAAC,CAAC,EAAwB,oHAFhD,GAAM,yBAAE,CAAuB,CAAE,CAAA,EAAA,CAAA,CAAA,OAEjC,EAAsB,CAAC,CAAC,EAAwB","ignoreList":[0,1,2,3,4]}