9router 0.2.16 → 0.2.17

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 (183) hide show
  1. package/LICENSE +4 -0
  2. package/app/.next/BUILD_ID +1 -1
  3. package/app/.next/app-build-manifest.json +136 -136
  4. package/app/.next/app-path-routes-manifest.json +19 -19
  5. package/app/.next/build-manifest.json +5 -5
  6. package/app/.next/prerender-manifest.json +34 -34
  7. package/app/.next/react-loadable-manifest.json +13 -0
  8. package/app/.next/server/app/(dashboard)/dashboard/cli-tools/page.js +5 -5
  9. package/app/.next/server/app/(dashboard)/dashboard/cli-tools/page.js.nft.json +1 -1
  10. package/app/.next/server/app/(dashboard)/dashboard/cli-tools/page_client-reference-manifest.js +1 -1
  11. package/app/.next/server/app/(dashboard)/dashboard/combos/page.js +2 -2
  12. package/app/.next/server/app/(dashboard)/dashboard/combos/page.js.nft.json +1 -1
  13. package/app/.next/server/app/(dashboard)/dashboard/combos/page_client-reference-manifest.js +1 -1
  14. package/app/.next/server/app/(dashboard)/dashboard/endpoint/page.js +1 -1
  15. package/app/.next/server/app/(dashboard)/dashboard/endpoint/page.js.nft.json +1 -1
  16. package/app/.next/server/app/(dashboard)/dashboard/endpoint/page_client-reference-manifest.js +1 -1
  17. package/app/.next/server/app/(dashboard)/dashboard/page.js +1 -1
  18. package/app/.next/server/app/(dashboard)/dashboard/page.js.nft.json +1 -1
  19. package/app/.next/server/app/(dashboard)/dashboard/page_client-reference-manifest.js +1 -1
  20. package/app/.next/server/app/(dashboard)/dashboard/profile/page.js +2 -2
  21. package/app/.next/server/app/(dashboard)/dashboard/profile/page.js.nft.json +1 -1
  22. package/app/.next/server/app/(dashboard)/dashboard/profile/page_client-reference-manifest.js +1 -1
  23. package/app/.next/server/app/(dashboard)/dashboard/providers/[id]/page.js +2 -2
  24. package/app/.next/server/app/(dashboard)/dashboard/providers/[id]/page.js.nft.json +1 -1
  25. package/app/.next/server/app/(dashboard)/dashboard/providers/[id]/page_client-reference-manifest.js +1 -1
  26. package/app/.next/server/app/(dashboard)/dashboard/providers/new/page.js +1 -1
  27. package/app/.next/server/app/(dashboard)/dashboard/providers/new/page.js.nft.json +1 -1
  28. package/app/.next/server/app/(dashboard)/dashboard/providers/new/page_client-reference-manifest.js +1 -1
  29. package/app/.next/server/app/(dashboard)/dashboard/providers/page.js +2 -2
  30. package/app/.next/server/app/(dashboard)/dashboard/providers/page.js.nft.json +1 -1
  31. package/app/.next/server/app/(dashboard)/dashboard/providers/page_client-reference-manifest.js +1 -1
  32. package/app/.next/server/app/_not-found/page.js +2 -2
  33. package/app/.next/server/app/_not-found/page.js.nft.json +1 -1
  34. package/app/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  35. package/app/.next/server/app/_not-found.html +1 -1
  36. package/app/.next/server/app/_not-found.rsc +2 -2
  37. package/app/.next/server/app/api/cli-tools/claude-settings/route_client-reference-manifest.js +1 -1
  38. package/app/.next/server/app/api/cli-tools/codex-settings/route_client-reference-manifest.js +1 -1
  39. package/app/.next/server/app/api/cloud/auth/route.js +1 -1
  40. package/app/.next/server/app/api/cloud/auth/route_client-reference-manifest.js +1 -1
  41. package/app/.next/server/app/api/cloud/credentials/update/route.js +1 -1
  42. package/app/.next/server/app/api/cloud/credentials/update/route_client-reference-manifest.js +1 -1
  43. package/app/.next/server/app/api/cloud/model/resolve/route.js +1 -1
  44. package/app/.next/server/app/api/cloud/model/resolve/route_client-reference-manifest.js +1 -1
  45. package/app/.next/server/app/api/cloud/models/alias/route.js +1 -1
  46. package/app/.next/server/app/api/cloud/models/alias/route_client-reference-manifest.js +1 -1
  47. package/app/.next/server/app/api/combos/[id]/route.js +1 -1
  48. package/app/.next/server/app/api/combos/[id]/route_client-reference-manifest.js +1 -1
  49. package/app/.next/server/app/api/combos/route.js +1 -1
  50. package/app/.next/server/app/api/combos/route_client-reference-manifest.js +1 -1
  51. package/app/.next/server/app/api/init/route.js +1 -1
  52. package/app/.next/server/app/api/init/route.js.nft.json +1 -1
  53. package/app/.next/server/app/api/init/route_client-reference-manifest.js +1 -1
  54. package/app/.next/server/app/api/keys/[id]/route.js +1 -1
  55. package/app/.next/server/app/api/keys/[id]/route_client-reference-manifest.js +1 -1
  56. package/app/.next/server/app/api/keys/route.js +1 -1
  57. package/app/.next/server/app/api/keys/route_client-reference-manifest.js +1 -1
  58. package/app/.next/server/app/api/models/alias/route.js +1 -1
  59. package/app/.next/server/app/api/models/alias/route_client-reference-manifest.js +1 -1
  60. package/app/.next/server/app/api/models/route.js +1 -1
  61. package/app/.next/server/app/api/models/route.js.nft.json +1 -1
  62. package/app/.next/server/app/api/models/route_client-reference-manifest.js +1 -1
  63. package/app/.next/server/app/api/oauth/[provider]/[action]/route.js +1 -1
  64. package/app/.next/server/app/api/oauth/[provider]/[action]/route_client-reference-manifest.js +1 -1
  65. package/app/.next/server/app/api/providers/[id]/models/route.js +1 -1
  66. package/app/.next/server/app/api/providers/[id]/models/route_client-reference-manifest.js +1 -1
  67. package/app/.next/server/app/api/providers/[id]/route.js +1 -1
  68. package/app/.next/server/app/api/providers/[id]/route_client-reference-manifest.js +1 -1
  69. package/app/.next/server/app/api/providers/[id]/test/route.js +1 -1
  70. package/app/.next/server/app/api/providers/[id]/test/route_client-reference-manifest.js +1 -1
  71. package/app/.next/server/app/api/providers/client/route.js +1 -1
  72. package/app/.next/server/app/api/providers/client/route_client-reference-manifest.js +1 -1
  73. package/app/.next/server/app/api/providers/route.js +1 -1
  74. package/app/.next/server/app/api/providers/route.js.nft.json +1 -1
  75. package/app/.next/server/app/api/providers/route_client-reference-manifest.js +1 -1
  76. package/app/.next/server/app/api/providers/validate/route_client-reference-manifest.js +1 -1
  77. package/app/.next/server/app/api/settings/route.js +1 -1
  78. package/app/.next/server/app/api/settings/route_client-reference-manifest.js +1 -1
  79. package/app/.next/server/app/api/shutdown/route_client-reference-manifest.js +1 -1
  80. package/app/.next/server/app/api/sync/cloud/route.js +1 -1
  81. package/app/.next/server/app/api/sync/cloud/route_client-reference-manifest.js +1 -1
  82. package/app/.next/server/app/api/sync/initialize/route.js +1 -1
  83. package/app/.next/server/app/api/sync/initialize/route.js.nft.json +1 -1
  84. package/app/.next/server/app/api/sync/initialize/route_client-reference-manifest.js +1 -1
  85. package/app/.next/server/app/api/tags/route_client-reference-manifest.js +1 -1
  86. package/app/.next/server/app/api/usage/[connectionId]/route.js +1 -1
  87. package/app/.next/server/app/api/usage/[connectionId]/route_client-reference-manifest.js +1 -1
  88. package/app/.next/server/app/api/v1/api/chat/route.js +1 -1
  89. package/app/.next/server/app/api/v1/api/chat/route.js.nft.json +1 -1
  90. package/app/.next/server/app/api/v1/api/chat/route_client-reference-manifest.js +1 -1
  91. package/app/.next/server/app/api/v1/chat/completions/route.js +1 -1
  92. package/app/.next/server/app/api/v1/chat/completions/route.js.nft.json +1 -1
  93. package/app/.next/server/app/api/v1/chat/completions/route_client-reference-manifest.js +1 -1
  94. package/app/.next/server/app/api/v1/messages/count_tokens/route_client-reference-manifest.js +1 -1
  95. package/app/.next/server/app/api/v1/messages/route.js +1 -1
  96. package/app/.next/server/app/api/v1/messages/route.js.nft.json +1 -1
  97. package/app/.next/server/app/api/v1/messages/route_client-reference-manifest.js +1 -1
  98. package/app/.next/server/app/api/v1/responses/route.js +1 -1
  99. package/app/.next/server/app/api/v1/responses/route.js.nft.json +1 -1
  100. package/app/.next/server/app/api/v1/responses/route_client-reference-manifest.js +1 -1
  101. package/app/.next/server/app/api/v1/route_client-reference-manifest.js +1 -1
  102. package/app/.next/server/app/api/v1beta/models/[...path]/route.js +1 -1
  103. package/app/.next/server/app/api/v1beta/models/[...path]/route.js.nft.json +1 -1
  104. package/app/.next/server/app/api/v1beta/models/[...path]/route_client-reference-manifest.js +1 -1
  105. package/app/.next/server/app/api/v1beta/models/route.js +1 -1
  106. package/app/.next/server/app/api/v1beta/models/route.js.nft.json +1 -1
  107. package/app/.next/server/app/api/v1beta/models/route_client-reference-manifest.js +1 -1
  108. package/app/.next/server/app/callback/page.js +1 -1
  109. package/app/.next/server/app/callback/page.js.nft.json +1 -1
  110. package/app/.next/server/app/callback/page_client-reference-manifest.js +1 -1
  111. package/app/.next/server/app/callback.html +1 -1
  112. package/app/.next/server/app/callback.rsc +2 -2
  113. package/app/.next/server/app/dashboard/cli-tools.html +1 -1
  114. package/app/.next/server/app/dashboard/cli-tools.rsc +4 -4
  115. package/app/.next/server/app/dashboard/combos.html +1 -1
  116. package/app/.next/server/app/dashboard/combos.rsc +4 -4
  117. package/app/.next/server/app/dashboard/endpoint.html +1 -1
  118. package/app/.next/server/app/dashboard/endpoint.rsc +4 -4
  119. package/app/.next/server/app/dashboard/profile.html +1 -1
  120. package/app/.next/server/app/dashboard/profile.rsc +4 -4
  121. package/app/.next/server/app/dashboard/providers/new.html +1 -1
  122. package/app/.next/server/app/dashboard/providers/new.rsc +4 -4
  123. package/app/.next/server/app/dashboard/providers.html +1 -1
  124. package/app/.next/server/app/dashboard/providers.rsc +4 -4
  125. package/app/.next/server/app/dashboard.html +1 -1
  126. package/app/.next/server/app/dashboard.rsc +4 -4
  127. package/app/.next/server/app/index.html +1 -1
  128. package/app/.next/server/app/index.rsc +2 -2
  129. package/app/.next/server/app/landing/page.js +1 -1
  130. package/app/.next/server/app/landing/page.js.nft.json +1 -1
  131. package/app/.next/server/app/landing/page_client-reference-manifest.js +1 -1
  132. package/app/.next/server/app/landing.html +1 -1
  133. package/app/.next/server/app/landing.rsc +2 -2
  134. package/app/.next/server/app/page.js +1 -1
  135. package/app/.next/server/app/page.js.nft.json +1 -1
  136. package/app/.next/server/app/page_client-reference-manifest.js +1 -1
  137. package/app/.next/server/app-paths-manifest.json +19 -19
  138. package/app/.next/server/chunks/1354.js +3 -3
  139. package/app/.next/server/chunks/3103.js +1 -1
  140. package/app/.next/server/chunks/5170.js +1 -1
  141. package/app/.next/server/chunks/533.js +1 -0
  142. package/app/.next/server/chunks/{6689.js → 5451.js} +2 -2
  143. package/app/.next/server/chunks/5977.js +1 -1
  144. package/app/.next/server/chunks/9858.js +1 -0
  145. package/app/.next/server/middleware-build-manifest.js +1 -1
  146. package/app/.next/server/middleware-react-loadable-manifest.js +1 -1
  147. package/app/.next/server/pages/404.html +1 -1
  148. package/app/.next/server/pages/500.html +1 -1
  149. package/app/.next/server/webpack-runtime.js +1 -1
  150. package/app/.next/static/chunks/1393-74e0710828062f40.js +1 -0
  151. package/app/.next/static/chunks/2819-00dd2839ed1323e4.js +1 -0
  152. package/app/.next/static/chunks/3431.b7e68d807c631773.js +1 -0
  153. package/app/.next/static/chunks/9220.745ac8c97d067b9a.js +1 -0
  154. package/app/.next/static/chunks/9955-cba200dfd971f126.js +1 -0
  155. package/app/.next/static/chunks/app/(dashboard)/dashboard/cli-tools/page-1ef1ec29086061fd.js +1 -0
  156. package/app/.next/static/chunks/app/(dashboard)/dashboard/combos/page-f18c8b5778e91a72.js +1 -0
  157. package/app/.next/static/chunks/app/(dashboard)/dashboard/endpoint/page-636932605724d0ce.js +1 -0
  158. package/app/.next/static/chunks/app/(dashboard)/dashboard/page-81c3e3fb971037c1.js +1 -0
  159. package/app/.next/static/chunks/app/(dashboard)/dashboard/profile/page-327e2f8b73368cc2.js +1 -0
  160. package/app/.next/static/chunks/app/(dashboard)/dashboard/providers/[id]/page-800270dff34413c0.js +1 -0
  161. package/app/.next/static/chunks/app/(dashboard)/dashboard/providers/new/page-9e075d79ef785c9b.js +1 -0
  162. package/app/.next/static/chunks/app/(dashboard)/dashboard/providers/page-eea1c0bf95c10035.js +1 -0
  163. package/app/.next/static/chunks/app/(dashboard)/{layout-239cdcb35472d644.js → layout-65f98ae0eccfc7b8.js} +1 -1
  164. package/app/.next/static/chunks/webpack-5865472aea7b6340.js +1 -0
  165. package/app/package.json +2 -0
  166. package/cli.js +11 -38
  167. package/package.json +1 -1
  168. package/app/.next/server/chunks/1582.js +0 -1
  169. package/app/.next/server/chunks/3576.js +0 -1
  170. package/app/.next/static/chunks/1393-c0bf788a0bc19102.js +0 -1
  171. package/app/.next/static/chunks/4244-0a98cf2e73799efe.js +0 -1
  172. package/app/.next/static/chunks/9955-a027f64b1a9bf4e5.js +0 -1
  173. package/app/.next/static/chunks/app/(dashboard)/dashboard/cli-tools/page-9009a2a4fdcd878c.js +0 -1
  174. package/app/.next/static/chunks/app/(dashboard)/dashboard/combos/page-95da854765deba41.js +0 -1
  175. package/app/.next/static/chunks/app/(dashboard)/dashboard/endpoint/page-98e477f1e2603f2b.js +0 -1
  176. package/app/.next/static/chunks/app/(dashboard)/dashboard/page-1dce481cbcf036bc.js +0 -1
  177. package/app/.next/static/chunks/app/(dashboard)/dashboard/profile/page-c3dd45dfdb0b9dec.js +0 -1
  178. package/app/.next/static/chunks/app/(dashboard)/dashboard/providers/[id]/page-60e73b7047f9e428.js +0 -1
  179. package/app/.next/static/chunks/app/(dashboard)/dashboard/providers/new/page-1f016f32f42ef1f9.js +0 -1
  180. package/app/.next/static/chunks/app/(dashboard)/dashboard/providers/page-407c2ce547816028.js +0 -1
  181. package/app/.next/static/chunks/webpack-e009a29a8139b7cb.js +0 -1
  182. /package/app/.next/static/{CjtizKLK3s08esa00wWI0 → jTOq4rGDmshmQFiyCGWaU}/_buildManifest.js +0 -0
  183. /package/app/.next/static/{CjtizKLK3s08esa00wWI0 → jTOq4rGDmshmQFiyCGWaU}/_ssgManifest.js +0 -0
@@ -5,11 +5,11 @@
5
5
  "devFiles": [],
6
6
  "ampDevFiles": [],
7
7
  "lowPriorityFiles": [
8
- "static/CjtizKLK3s08esa00wWI0/_buildManifest.js",
9
- "static/CjtizKLK3s08esa00wWI0/_ssgManifest.js"
8
+ "static/jTOq4rGDmshmQFiyCGWaU/_buildManifest.js",
9
+ "static/jTOq4rGDmshmQFiyCGWaU/_ssgManifest.js"
10
10
  ],
11
11
  "rootMainFiles": [
12
- "static/chunks/webpack-e009a29a8139b7cb.js",
12
+ "static/chunks/webpack-5865472aea7b6340.js",
13
13
  "static/chunks/4bd1b696-f785427dddbba9fb.js",
14
14
  "static/chunks/1255-9494d7e861e97d68.js",
15
15
  "static/chunks/main-app-1a9105a16c026010.js"
@@ -17,13 +17,13 @@
17
17
  "rootMainFilesTree": {},
18
18
  "pages": {
19
19
  "/_app": [
20
- "static/chunks/webpack-e009a29a8139b7cb.js",
20
+ "static/chunks/webpack-5865472aea7b6340.js",
21
21
  "static/chunks/framework-90fc9b0f7c4706c1.js",
22
22
  "static/chunks/main-b718c5aeb6d6e180.js",
23
23
  "static/chunks/pages/_app-6c8c2371b16a04b8.js"
24
24
  ],
25
25
  "/_error": [
26
- "static/chunks/webpack-e009a29a8139b7cb.js",
26
+ "static/chunks/webpack-5865472aea7b6340.js",
27
27
  "static/chunks/framework-90fc9b0f7c4706c1.js",
28
28
  "static/chunks/main-b718c5aeb6d6e180.js",
29
29
  "static/chunks/pages/_error-94812ad32cad7365.js"
@@ -30,8 +30,7 @@
30
30
  "x-next-revalidate-tag-token"
31
31
  ]
32
32
  },
33
- "/_not-found": {
34
- "initialStatus": 404,
33
+ "/callback": {
35
34
  "experimentalBypassFor": [
36
35
  {
37
36
  "type": "header",
@@ -44,8 +43,8 @@
44
43
  }
45
44
  ],
46
45
  "initialRevalidateSeconds": false,
47
- "srcRoute": "/_not-found",
48
- "dataRoute": "/_not-found.rsc",
46
+ "srcRoute": "/callback",
47
+ "dataRoute": "/callback.rsc",
49
48
  "allowHeader": [
50
49
  "host",
51
50
  "x-matched-path",
@@ -55,7 +54,7 @@
55
54
  "x-next-revalidate-tag-token"
56
55
  ]
57
56
  },
58
- "/dashboard/endpoint": {
57
+ "/": {
59
58
  "experimentalBypassFor": [
60
59
  {
61
60
  "type": "header",
@@ -68,8 +67,8 @@
68
67
  }
69
68
  ],
70
69
  "initialRevalidateSeconds": false,
71
- "srcRoute": "/dashboard/endpoint",
72
- "dataRoute": "/dashboard/endpoint.rsc",
70
+ "srcRoute": "/",
71
+ "dataRoute": "/index.rsc",
73
72
  "allowHeader": [
74
73
  "host",
75
74
  "x-matched-path",
@@ -79,7 +78,7 @@
79
78
  "x-next-revalidate-tag-token"
80
79
  ]
81
80
  },
82
- "/dashboard/providers": {
81
+ "/dashboard/profile": {
83
82
  "experimentalBypassFor": [
84
83
  {
85
84
  "type": "header",
@@ -92,8 +91,8 @@
92
91
  }
93
92
  ],
94
93
  "initialRevalidateSeconds": false,
95
- "srcRoute": "/dashboard/providers",
96
- "dataRoute": "/dashboard/providers.rsc",
94
+ "srcRoute": "/dashboard/profile",
95
+ "dataRoute": "/dashboard/profile.rsc",
97
96
  "allowHeader": [
98
97
  "host",
99
98
  "x-matched-path",
@@ -103,7 +102,7 @@
103
102
  "x-next-revalidate-tag-token"
104
103
  ]
105
104
  },
106
- "/dashboard": {
105
+ "/dashboard/providers/new": {
107
106
  "experimentalBypassFor": [
108
107
  {
109
108
  "type": "header",
@@ -116,8 +115,8 @@
116
115
  }
117
116
  ],
118
117
  "initialRevalidateSeconds": false,
119
- "srcRoute": "/dashboard",
120
- "dataRoute": "/dashboard.rsc",
118
+ "srcRoute": "/dashboard/providers/new",
119
+ "dataRoute": "/dashboard/providers/new.rsc",
121
120
  "allowHeader": [
122
121
  "host",
123
122
  "x-matched-path",
@@ -127,7 +126,7 @@
127
126
  "x-next-revalidate-tag-token"
128
127
  ]
129
128
  },
130
- "/callback": {
129
+ "/dashboard": {
131
130
  "experimentalBypassFor": [
132
131
  {
133
132
  "type": "header",
@@ -140,8 +139,8 @@
140
139
  }
141
140
  ],
142
141
  "initialRevalidateSeconds": false,
143
- "srcRoute": "/callback",
144
- "dataRoute": "/callback.rsc",
142
+ "srcRoute": "/dashboard",
143
+ "dataRoute": "/dashboard.rsc",
145
144
  "allowHeader": [
146
145
  "host",
147
146
  "x-matched-path",
@@ -151,7 +150,7 @@
151
150
  "x-next-revalidate-tag-token"
152
151
  ]
153
152
  },
154
- "/landing": {
153
+ "/dashboard/endpoint": {
155
154
  "experimentalBypassFor": [
156
155
  {
157
156
  "type": "header",
@@ -164,8 +163,8 @@
164
163
  }
165
164
  ],
166
165
  "initialRevalidateSeconds": false,
167
- "srcRoute": "/landing",
168
- "dataRoute": "/landing.rsc",
166
+ "srcRoute": "/dashboard/endpoint",
167
+ "dataRoute": "/dashboard/endpoint.rsc",
169
168
  "allowHeader": [
170
169
  "host",
171
170
  "x-matched-path",
@@ -175,7 +174,7 @@
175
174
  "x-next-revalidate-tag-token"
176
175
  ]
177
176
  },
178
- "/": {
177
+ "/dashboard/cli-tools": {
179
178
  "experimentalBypassFor": [
180
179
  {
181
180
  "type": "header",
@@ -188,8 +187,8 @@
188
187
  }
189
188
  ],
190
189
  "initialRevalidateSeconds": false,
191
- "srcRoute": "/",
192
- "dataRoute": "/index.rsc",
190
+ "srcRoute": "/dashboard/cli-tools",
191
+ "dataRoute": "/dashboard/cli-tools.rsc",
193
192
  "allowHeader": [
194
193
  "host",
195
194
  "x-matched-path",
@@ -199,7 +198,7 @@
199
198
  "x-next-revalidate-tag-token"
200
199
  ]
201
200
  },
202
- "/dashboard/providers/new": {
201
+ "/dashboard/combos": {
203
202
  "experimentalBypassFor": [
204
203
  {
205
204
  "type": "header",
@@ -212,8 +211,8 @@
212
211
  }
213
212
  ],
214
213
  "initialRevalidateSeconds": false,
215
- "srcRoute": "/dashboard/providers/new",
216
- "dataRoute": "/dashboard/providers/new.rsc",
214
+ "srcRoute": "/dashboard/combos",
215
+ "dataRoute": "/dashboard/combos.rsc",
217
216
  "allowHeader": [
218
217
  "host",
219
218
  "x-matched-path",
@@ -223,7 +222,7 @@
223
222
  "x-next-revalidate-tag-token"
224
223
  ]
225
224
  },
226
- "/dashboard/combos": {
225
+ "/dashboard/providers": {
227
226
  "experimentalBypassFor": [
228
227
  {
229
228
  "type": "header",
@@ -236,8 +235,8 @@
236
235
  }
237
236
  ],
238
237
  "initialRevalidateSeconds": false,
239
- "srcRoute": "/dashboard/combos",
240
- "dataRoute": "/dashboard/combos.rsc",
238
+ "srcRoute": "/dashboard/providers",
239
+ "dataRoute": "/dashboard/providers.rsc",
241
240
  "allowHeader": [
242
241
  "host",
243
242
  "x-matched-path",
@@ -247,7 +246,7 @@
247
246
  "x-next-revalidate-tag-token"
248
247
  ]
249
248
  },
250
- "/dashboard/profile": {
249
+ "/landing": {
251
250
  "experimentalBypassFor": [
252
251
  {
253
252
  "type": "header",
@@ -260,8 +259,8 @@
260
259
  }
261
260
  ],
262
261
  "initialRevalidateSeconds": false,
263
- "srcRoute": "/dashboard/profile",
264
- "dataRoute": "/dashboard/profile.rsc",
262
+ "srcRoute": "/landing",
263
+ "dataRoute": "/landing.rsc",
265
264
  "allowHeader": [
266
265
  "host",
267
266
  "x-matched-path",
@@ -271,7 +270,8 @@
271
270
  "x-next-revalidate-tag-token"
272
271
  ]
273
272
  },
274
- "/dashboard/cli-tools": {
273
+ "/_not-found": {
274
+ "initialStatus": 404,
275
275
  "experimentalBypassFor": [
276
276
  {
277
277
  "type": "header",
@@ -284,8 +284,8 @@
284
284
  }
285
285
  ],
286
286
  "initialRevalidateSeconds": false,
287
- "srcRoute": "/dashboard/cli-tools",
288
- "dataRoute": "/dashboard/cli-tools.rsc",
287
+ "srcRoute": "/_not-found",
288
+ "dataRoute": "/_not-found.rsc",
289
289
  "allowHeader": [
290
290
  "host",
291
291
  "x-matched-path",
@@ -3,6 +3,19 @@
3
3
  "id": 3971,
4
4
  "files": []
5
5
  },
6
+ "../open-sse/handlers/chatCore.js -> http": {
7
+ "id": 3431,
8
+ "files": [
9
+ "static/chunks/3431.b7e68d807c631773.js"
10
+ ]
11
+ },
12
+ "../open-sse/handlers/chatCore.js -> https": {
13
+ "id": 9220,
14
+ "files": [
15
+ "static/chunks/3431.b7e68d807c631773.js",
16
+ "static/chunks/9220.745ac8c97d067b9a.js"
17
+ ]
18
+ },
6
19
  "../open-sse/translator/index.js -> ./from-openai/claude.js": {
7
20
  "id": 1441,
8
21
  "files": [
@@ -1,16 +1,16 @@
1
- (()=>{var a={};a.id=2326,a.ids=[2326],a.modules={261:a=>{"use strict";a.exports=require("next/dist/shared/lib/router/utils/app-paths")},3295:a=>{"use strict";a.exports=require("next/dist/server/app-render/after-task-async-storage.external.js")},10846:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},15608:(a,b,c)=>{Promise.resolve().then(c.bind(c,78233))},19121:a=>{"use strict";a.exports=require("next/dist/server/app-render/action-async-storage.external.js")},21820:a=>{"use strict";a.exports=require("os")},25336:(a,b,c)=>{Promise.resolve().then(c.bind(c,68997))},26713:a=>{"use strict";a.exports=require("next/dist/shared/lib/router/utils/is-bot")},28354:a=>{"use strict";a.exports=require("util")},29021:a=>{"use strict";a.exports=require("fs")},29294:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},33873:a=>{"use strict";a.exports=require("path")},35187:(a,b,c)=>{"use strict";c.r(b),c.d(b,{default:()=>g});var d=c(75338),e=c(62789),f=c(78233);async function g(){let a=await (0,e.D1)();return(0,d.jsx)(f.default,{machineId:a})}},41025:a=>{"use strict";a.exports=require("next/dist/server/app-render/dynamic-access-async-storage.external.js")},51455:a=>{"use strict";a.exports=require("node:fs/promises")},55268:(a,b,c)=>{"use strict";c.r(b),c.d(b,{GlobalError:()=>D.a,__next_app__:()=>J,handler:()=>L,pages:()=>I,routeModule:()=>K,tree:()=>H});var d=c(49754),e=c(9117),f=c(46595),g=c(32324),h=c(39326),i=c(38928),j=c(20175),k=c(12),l=c(54290),m=c(12696),n=c(82802),o=c(77533),p=c(45229),q=c(32822),r=c(261),s=c(26453),t=c(52474),u=c(26713),v=c(51356),w=c(62685),x=c(36225),y=c(63446),z=c(2762),A=c(45742),B=c(86439),C=c(81170),D=c.n(C),E=c(62506),F=c(91203),G={};for(let a in E)0>["default","tree","pages","GlobalError","__next_app__","routeModule","handler"].indexOf(a)&&(G[a]=()=>E[a]);c.d(b,G);let H={children:["",{children:["(dashboard)",{children:["dashboard",{children:["cli-tools",{children:["__PAGE__",{},{page:[()=>Promise.resolve().then(c.bind(c,35187)),"/Users/Working/router4/app/src/app/(dashboard)/dashboard/cli-tools/page.js"]}]},{}]},{}]},{layout:[()=>Promise.resolve().then(c.bind(c,64826)),"/Users/Working/router4/app/src/app/(dashboard)/layout.js"],"not-found":[()=>Promise.resolve().then(c.t.bind(c,87028,23)),"next/dist/client/components/builtin/not-found.js"],forbidden:[()=>Promise.resolve().then(c.t.bind(c,90461,23)),"next/dist/client/components/builtin/forbidden.js"],unauthorized:[()=>Promise.resolve().then(c.t.bind(c,32768,23)),"next/dist/client/components/builtin/unauthorized.js"],metadata:{icon:[async a=>(await Promise.resolve().then(c.bind(c,70440))).default(a)],apple:[],openGraph:[],twitter:[],manifest:void 0}}]},{layout:[()=>Promise.resolve().then(c.bind(c,97634)),"/Users/Working/router4/app/src/app/layout.js"],"global-error":[()=>Promise.resolve().then(c.t.bind(c,81170,23)),"next/dist/client/components/builtin/global-error.js"],"not-found":[()=>Promise.resolve().then(c.t.bind(c,87028,23)),"next/dist/client/components/builtin/not-found.js"],forbidden:[()=>Promise.resolve().then(c.t.bind(c,90461,23)),"next/dist/client/components/builtin/forbidden.js"],unauthorized:[()=>Promise.resolve().then(c.t.bind(c,32768,23)),"next/dist/client/components/builtin/unauthorized.js"],metadata:{icon:[async a=>(await Promise.resolve().then(c.bind(c,70440))).default(a)],apple:[],openGraph:[],twitter:[],manifest:void 0}}]}.children,I=["/Users/Working/router4/app/src/app/(dashboard)/dashboard/cli-tools/page.js"],J={require:c,loadChunk:()=>Promise.resolve()},K=new d.AppPageRouteModule({definition:{kind:e.RouteKind.APP_PAGE,page:"/(dashboard)/dashboard/cli-tools/page",pathname:"/dashboard/cli-tools",bundlePath:"",filename:"",appPaths:[]},userland:{loaderTree:H},distDir:".next",relativeProjectDir:""});async function L(a,b,d){var C;let G="/(dashboard)/dashboard/cli-tools/page";"/index"===G&&(G="/");let M=(0,h.getRequestMeta)(a,"postponed"),N=(0,h.getRequestMeta)(a,"minimalMode"),O=await K.prepare(a,b,{srcPage:G,multiZoneDraftMode:!1});if(!O)return b.statusCode=400,b.end("Bad Request"),null==d.waitUntil||d.waitUntil.call(d,Promise.resolve()),null;let{buildId:P,query:Q,params:R,parsedUrl:S,pageIsDynamic:T,buildManifest:U,nextFontManifest:V,reactLoadableManifest:W,serverActionsManifest:X,clientReferenceManifest:Y,subresourceIntegrityManifest:Z,prerenderManifest:$,isDraftMode:_,resolvedPathname:aa,revalidateOnlyGenerated:ab,routerServerContext:ac,nextConfig:ad,interceptionRoutePatterns:ae}=O,af=S.pathname||"/",ag=(0,r.normalizeAppPath)(G),{isOnDemandRevalidate:ah}=O,ai=K.match(af,$),aj=!!$.routes[aa],ak=!!(ai||aj||$.routes[ag]),al=a.headers["user-agent"]||"",am=(0,u.getBotType)(al),an=(0,p.isHtmlBotRequest)(a),ao=(0,h.getRequestMeta)(a,"isPrefetchRSCRequest")??"1"===a.headers[t.NEXT_ROUTER_PREFETCH_HEADER],ap=(0,h.getRequestMeta)(a,"isRSCRequest")??!!a.headers[t.RSC_HEADER],aq=(0,s.getIsPossibleServerAction)(a),ar=(0,m.checkIsAppPPREnabled)(ad.experimental.ppr)&&(null==(C=$.routes[ag]??$.dynamicRoutes[ag])?void 0:C.renderingMode)==="PARTIALLY_STATIC",as=!1,at=!1,au=ar?M:void 0,av=ar&&ap&&!ao,aw=(0,h.getRequestMeta)(a,"segmentPrefetchRSCRequest"),ax=!al||(0,p.shouldServeStreamingMetadata)(al,ad.htmlLimitedBots);an&&ar&&(ak=!1,ax=!1);let ay=!0===K.isDev||!ak||"string"==typeof M||av,az=an&&ar,aA=null;_||!ak||ay||aq||au||av||(aA=aa);let aB=aA;!aB&&K.isDev&&(aB=aa),K.isDev||_||!ak||!ap||av||(0,k.d)(a.headers);let aC={...E,tree:H,pages:I,GlobalError:D(),handler:L,routeModule:K,__next_app__:J};X&&Y&&(0,o.setReferenceManifestsSingleton)({page:G,clientReferenceManifest:Y,serverActionsManifest:X,serverModuleMap:(0,q.createServerModuleMap)({serverActionsManifest:X})});let aD=a.method||"GET",aE=(0,g.getTracer)(),aF=aE.getActiveScopeSpan();try{let f=K.getVaryHeader(aa,ae);b.setHeader("Vary",f);let k=async(c,d)=>{let e=new l.NodeNextRequest(a),f=new l.NodeNextResponse(b);return K.render(e,f,d).finally(()=>{if(!c)return;c.setAttributes({"http.status_code":b.statusCode,"next.rsc":!1});let d=aE.getRootSpanAttributes();if(!d)return;if(d.get("next.span_type")!==i.BaseServerSpan.handleRequest)return void console.warn(`Unexpected root span type '${d.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=d.get("next.route");if(e){let a=`${aD} ${e}`;c.setAttributes({"next.route":e,"http.route":e,"next.span_name":a}),c.updateName(a)}else c.updateName(`${aD} ${a.url}`)})},m=async({span:e,postponed:f,fallbackRouteParams:g})=>{let i={query:Q,params:R,page:ag,sharedContext:{buildId:P},serverComponentsHmrCache:(0,h.getRequestMeta)(a,"serverComponentsHmrCache"),fallbackRouteParams:g,renderOpts:{App:()=>null,Document:()=>null,pageConfig:{},ComponentMod:aC,Component:(0,j.T)(aC),params:R,routeModule:K,page:G,postponed:f,shouldWaitOnAllReady:az,serveStreamingMetadata:ax,supportsDynamicResponse:"string"==typeof f||ay,buildManifest:U,nextFontManifest:V,reactLoadableManifest:W,subresourceIntegrityManifest:Z,serverActionsManifest:X,clientReferenceManifest:Y,setIsrStatus:null==ac?void 0:ac.setIsrStatus,dir:c(33873).join(process.cwd(),K.relativeProjectDir),isDraftMode:_,isRevalidate:ak&&!f&&!av,botType:am,isOnDemandRevalidate:ah,isPossibleServerAction:aq,assetPrefix:ad.assetPrefix,nextConfigOutput:ad.output,crossOrigin:ad.crossOrigin,trailingSlash:ad.trailingSlash,previewProps:$.preview,deploymentId:ad.deploymentId,enableTainting:ad.experimental.taint,htmlLimitedBots:ad.htmlLimitedBots,devtoolSegmentExplorer:ad.experimental.devtoolSegmentExplorer,reactMaxHeadersLength:ad.reactMaxHeadersLength,multiZoneDraftMode:!1,incrementalCache:(0,h.getRequestMeta)(a,"incrementalCache"),cacheLifeProfiles:ad.experimental.cacheLife,basePath:ad.basePath,serverActions:ad.experimental.serverActions,...as?{nextExport:!0,supportsDynamicResponse:!1,isStaticGeneration:!0,isRevalidate:!0,isDebugDynamicAccesses:as}:{},experimental:{isRoutePPREnabled:ar,expireTime:ad.expireTime,staleTimes:ad.experimental.staleTimes,cacheComponents:!!ad.experimental.cacheComponents,clientSegmentCache:!!ad.experimental.clientSegmentCache,clientParamParsing:!!ad.experimental.clientParamParsing,dynamicOnHover:!!ad.experimental.dynamicOnHover,inlineCss:!!ad.experimental.inlineCss,authInterrupts:!!ad.experimental.authInterrupts,clientTraceMetadata:ad.experimental.clientTraceMetadata||[]},waitUntil:d.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:()=>{},onInstrumentationRequestError:(b,c,d)=>K.onRequestError(a,b,d,ac),err:(0,h.getRequestMeta)(a,"invokeError"),dev:K.isDev}},l=await k(e,i),{metadata:m}=l,{cacheControl:n,headers:o={},fetchTags:p}=m;if(p&&(o[y.NEXT_CACHE_TAGS_HEADER]=p),a.fetchMetrics=m.fetchMetrics,ak&&(null==n?void 0:n.revalidate)===0&&!K.isDev&&!ar){let a=m.staticBailoutInfo,b=Object.defineProperty(Error(`Page changed from static to dynamic at runtime ${aa}${(null==a?void 0:a.description)?`, reason: ${a.description}`:""}
2
- see more here https://nextjs.org/docs/messages/app-static-to-dynamic-error`),"__NEXT_ERROR_CODE",{value:"E132",enumerable:!1,configurable:!0});if(null==a?void 0:a.stack){let c=a.stack;b.stack=b.message+c.substring(c.indexOf("\n"))}throw b}return{value:{kind:v.CachedRouteKind.APP_PAGE,html:l,headers:o,rscData:m.flightData,postponed:m.postponed,status:m.statusCode,segmentData:m.segmentData},cacheControl:n}},o=async({hasResolved:c,previousCacheEntry:f,isRevalidating:g,span:i})=>{let j,k=!1===K.isDev,l=c||b.writableEnded;if(ah&&ab&&!f&&!N)return(null==ac?void 0:ac.render404)?await ac.render404(a,b):(b.statusCode=404,b.end("This page could not be found")),null;if(ai&&(j=(0,w.parseFallbackField)(ai.fallback)),j===w.FallbackMode.PRERENDER&&(0,u.isBot)(al)&&(!ar||an)&&(j=w.FallbackMode.BLOCKING_STATIC_RENDER),(null==f?void 0:f.isStale)===-1&&(ah=!0),ah&&(j!==w.FallbackMode.NOT_FOUND||f)&&(j=w.FallbackMode.BLOCKING_STATIC_RENDER),!N&&j!==w.FallbackMode.BLOCKING_STATIC_RENDER&&aB&&!l&&!_&&T&&(k||!aj)){let b;if((k||ai)&&j===w.FallbackMode.NOT_FOUND)throw new B.NoFallbackError;if(ar&&!ap){let c="string"==typeof(null==ai?void 0:ai.fallback)?ai.fallback:k?ag:null;if(b=await K.handleResponse({cacheKey:c,req:a,nextConfig:ad,routeKind:e.RouteKind.APP_PAGE,isFallback:!0,prerenderManifest:$,isRoutePPREnabled:ar,responseGenerator:async()=>m({span:i,postponed:void 0,fallbackRouteParams:k||at?(0,n.u)(ag):null}),waitUntil:d.waitUntil}),null===b)return null;if(b)return delete b.cacheControl,b}}let o=ah||g||!au?void 0:au;if(as&&void 0!==o)return{cacheControl:{revalidate:1,expire:void 0},value:{kind:v.CachedRouteKind.PAGES,html:x.default.EMPTY,pageData:{},headers:void 0,status:void 0}};let p=T&&ar&&((0,h.getRequestMeta)(a,"renderFallbackShell")||at)?(0,n.u)(af):null;return m({span:i,postponed:o,fallbackRouteParams:p})},p=async c=>{var f,g,i,j,k;let l,n=await K.handleResponse({cacheKey:aA,responseGenerator:a=>o({span:c,...a}),routeKind:e.RouteKind.APP_PAGE,isOnDemandRevalidate:ah,isRoutePPREnabled:ar,req:a,nextConfig:ad,prerenderManifest:$,waitUntil:d.waitUntil});if(_&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate"),K.isDev&&b.setHeader("Cache-Control","no-store, must-revalidate"),!n){if(aA)throw Object.defineProperty(Error("invariant: cache entry required but not generated"),"__NEXT_ERROR_CODE",{value:"E62",enumerable:!1,configurable:!0});return null}if((null==(f=n.value)?void 0:f.kind)!==v.CachedRouteKind.APP_PAGE)throw Object.defineProperty(Error(`Invariant app-page handler received invalid cache entry ${null==(i=n.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E707",enumerable:!1,configurable:!0});let p="string"==typeof n.value.postponed;ak&&!av&&(!p||ao)&&(N||b.setHeader("x-nextjs-cache",ah?"REVALIDATED":n.isMiss?"MISS":n.isStale?"STALE":"HIT"),b.setHeader(t.NEXT_IS_PRERENDER_HEADER,"1"));let{value:q}=n;if(au)l={revalidate:0,expire:void 0};else if(N&&ap&&!ao&&ar)l={revalidate:0,expire:void 0};else if(!K.isDev)if(_)l={revalidate:0,expire:void 0};else if(ak){if(n.cacheControl)if("number"==typeof n.cacheControl.revalidate){if(n.cacheControl.revalidate<1)throw Object.defineProperty(Error(`Invalid revalidate configuration provided: ${n.cacheControl.revalidate} < 1`),"__NEXT_ERROR_CODE",{value:"E22",enumerable:!1,configurable:!0});l={revalidate:n.cacheControl.revalidate,expire:(null==(j=n.cacheControl)?void 0:j.expire)??ad.expireTime}}else l={revalidate:y.CACHE_ONE_YEAR,expire:void 0}}else b.getHeader("Cache-Control")||(l={revalidate:0,expire:void 0});if(n.cacheControl=l,"string"==typeof aw&&(null==q?void 0:q.kind)===v.CachedRouteKind.APP_PAGE&&q.segmentData){b.setHeader(t.NEXT_DID_POSTPONE_HEADER,"2");let c=null==(k=q.headers)?void 0:k[y.NEXT_CACHE_TAGS_HEADER];N&&ak&&c&&"string"==typeof c&&b.setHeader(y.NEXT_CACHE_TAGS_HEADER,c);let d=q.segmentData.get(aw);return void 0!==d?(0,A.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:x.default.fromStatic(d,t.RSC_CONTENT_TYPE_HEADER),cacheControl:n.cacheControl}):(b.statusCode=204,(0,A.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:x.default.EMPTY,cacheControl:n.cacheControl}))}let r=(0,h.getRequestMeta)(a,"onCacheEntry");if(r&&await r({...n,value:{...n.value,kind:"PAGE"}},{url:(0,h.getRequestMeta)(a,"initURL")}))return null;if(p&&au)throw Object.defineProperty(Error("Invariant: postponed state should not be present on a resume request"),"__NEXT_ERROR_CODE",{value:"E396",enumerable:!1,configurable:!0});if(q.headers){let a={...q.headers};for(let[c,d]of(N&&ak||delete a[y.NEXT_CACHE_TAGS_HEADER],Object.entries(a)))if(void 0!==d)if(Array.isArray(d))for(let a of d)b.appendHeader(c,a);else"number"==typeof d&&(d=d.toString()),b.appendHeader(c,d)}let s=null==(g=q.headers)?void 0:g[y.NEXT_CACHE_TAGS_HEADER];if(N&&ak&&s&&"string"==typeof s&&b.setHeader(y.NEXT_CACHE_TAGS_HEADER,s),!q.status||ap&&ar||(b.statusCode=q.status),!N&&q.status&&F.RedirectStatusCode[q.status]&&ap&&(b.statusCode=200),p&&b.setHeader(t.NEXT_DID_POSTPONE_HEADER,"1"),ap&&!_){if(void 0===q.rscData){if(q.postponed)throw Object.defineProperty(Error("Invariant: Expected postponed to be undefined"),"__NEXT_ERROR_CODE",{value:"E372",enumerable:!1,configurable:!0});return(0,A.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:q.html,cacheControl:av?{revalidate:0,expire:void 0}:n.cacheControl})}return(0,A.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:x.default.fromStatic(q.rscData,t.RSC_CONTENT_TYPE_HEADER),cacheControl:n.cacheControl})}let u=q.html;if(!p||N||ap)return(0,A.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:u,cacheControl:n.cacheControl});if(as)return u.push(new ReadableStream({start(a){a.enqueue(z.ENCODED_TAGS.CLOSED.BODY_AND_HTML),a.close()}})),(0,A.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:u,cacheControl:{revalidate:0,expire:void 0}});let w=new TransformStream;return u.push(w.readable),m({span:c,postponed:q.postponed,fallbackRouteParams:null}).then(async a=>{var b,c;if(!a)throw Object.defineProperty(Error("Invariant: expected a result to be returned"),"__NEXT_ERROR_CODE",{value:"E463",enumerable:!1,configurable:!0});if((null==(b=a.value)?void 0:b.kind)!==v.CachedRouteKind.APP_PAGE)throw Object.defineProperty(Error(`Invariant: expected a page response, got ${null==(c=a.value)?void 0:c.kind}`),"__NEXT_ERROR_CODE",{value:"E305",enumerable:!1,configurable:!0});await a.value.html.pipeTo(w.writable)}).catch(a=>{w.writable.abort(a).catch(a=>{console.error("couldn't abort transformer",a)})}),(0,A.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:u,cacheControl:{revalidate:0,expire:void 0}})};if(!aF)return await aE.withPropagatedContext(a.headers,()=>aE.trace(i.BaseServerSpan.handleRequest,{spanName:`${aD} ${a.url}`,kind:g.SpanKind.SERVER,attributes:{"http.method":aD,"http.target":a.url}},p));await p(aF)}catch(b){throw b instanceof B.NoFallbackError||await K.onRequestError(a,b,{routerKind:"App Router",routePath:G,routeType:"render",revalidateReason:(0,f.c)({isRevalidate:ak,isOnDemandRevalidate:ah})},ac),b}}},55511:a=>{"use strict";a.exports=require("crypto")},62789:(a,b,c)=>{"use strict";c.d(b,{D1:()=>e});var d=c(31852);async function e(){return await (0,d.Xj)()}},63033:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},68997:(a,b,c)=>{"use strict";c.d(b,{default:()=>o});var d=c(21124),e=c(38301),f=c(89178);let g={claude:{id:"claude",name:"Claude Code",icon:"terminal",color:"#D97757",description:"Anthropic Claude Code CLI",configType:"env",envVars:{baseUrl:"ANTHROPIC_BASE_URL",model:"ANTHROPIC_MODEL",opusModel:"ANTHROPIC_DEFAULT_OPUS_MODEL",sonnetModel:"ANTHROPIC_DEFAULT_SONNET_MODEL",haikuModel:"ANTHROPIC_DEFAULT_HAIKU_MODEL"},modelAliases:["default","sonnet","opus","haiku","opusplan"],settingsFile:"~/.claude/settings.json",defaultModels:[{id:"opus",name:"Claude Opus",alias:"opus",envKey:"ANTHROPIC_DEFAULT_OPUS_MODEL",defaultValue:"cc/claude-opus-4-5-20251101"},{id:"sonnet",name:"Claude Sonnet",alias:"sonnet",envKey:"ANTHROPIC_DEFAULT_SONNET_MODEL",defaultValue:"cc/claude-sonnet-4-5-20250929"},{id:"haiku",name:"Claude Haiku",alias:"haiku",envKey:"ANTHROPIC_DEFAULT_HAIKU_MODEL",defaultValue:"cc/claude-haiku-4-5-20251001"}]},codex:{id:"codex",name:"OpenAI Codex CLI",image:"/providers/codex.png",color:"#10A37F",description:"OpenAI Codex CLI",configType:"custom"},cursor:{id:"cursor",name:"Cursor",image:"/providers/cursor.png",color:"#000000",description:"Cursor AI Code Editor",configType:"guide",requiresCloud:!0,notes:[{type:"warning",text:"Requires Cursor Pro account to use this feature."},{type:"cloudCheck",text:"Cursor routes requests through its own server, so local endpoint is not supported. Please enable Cloud Endpoint in Settings."}],guideSteps:[{step:1,title:"Open Settings",desc:"Go to Settings → Models"},{step:2,title:"Enable OpenAI API",desc:'Enable "OpenAI API key" option'},{step:3,title:"Base URL",value:"{{baseUrl}}/v1",copyable:!0},{step:4,title:"API Key",type:"apiKeySelector"},{step:5,title:"Add Custom Model",desc:'Click "View All Model" → "Add Custom Model"'},{step:6,title:"Select Model",type:"modelSelector"}]},cline:{id:"cline",name:"CLINE",image:"/providers/cline.png",color:"#00D1B2",description:"CLINE AI Assistant",configType:"guide",guideSteps:[{step:1,title:"Open Settings",desc:"Go to CLINE Settings panel"},{step:2,title:"Select Provider",desc:"Choose API Provider → Ollama"},{step:3,title:"Base URL",value:"{{baseUrl}}",copyable:!0},{step:4,title:"API Key",type:"apiKeySelector"},{step:5,title:"Select Model",type:"modelSelector"}]},roo:{id:"roo",name:"Roo",image:"/providers/roo.png",color:"#FF6B6B",description:"Roo AI Assistant",configType:"guide",guideSteps:[{step:1,title:"Open Settings",desc:"Go to Roo Settings panel"},{step:2,title:"Select Provider",desc:"Choose API Provider → Ollama"},{step:3,title:"Base URL",value:"{{baseUrl}}",copyable:!0},{step:4,title:"API Key",type:"apiKeySelector"},{step:5,title:"Select Model",type:"modelSelector"}]},continue:{id:"continue",name:"Continue",image:"/providers/continue.png",color:"#7C3AED",description:"Continue AI Assistant",configType:"guide",guideSteps:[{step:1,title:"Open Config",desc:"Open Continue configuration file"},{step:2,title:"API Key",type:"apiKeySelector"},{step:3,title:"Select Model",type:"modelSelector"},{step:4,title:"Add Model Config",desc:"Add the following configuration to your models array:"}],codeBlock:{language:"json",code:`{
1
+ (()=>{var a={};a.id=2326,a.ids=[2326],a.modules={261:a=>{"use strict";a.exports=require("next/dist/shared/lib/router/utils/app-paths")},3295:a=>{"use strict";a.exports=require("next/dist/server/app-render/after-task-async-storage.external.js")},10846:a=>{"use strict";a.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},15608:(a,b,c)=>{Promise.resolve().then(c.bind(c,78233))},19121:a=>{"use strict";a.exports=require("next/dist/server/app-render/action-async-storage.external.js")},21820:a=>{"use strict";a.exports=require("os")},25336:(a,b,c)=>{Promise.resolve().then(c.bind(c,75623))},26713:a=>{"use strict";a.exports=require("next/dist/shared/lib/router/utils/is-bot")},28354:a=>{"use strict";a.exports=require("util")},29021:a=>{"use strict";a.exports=require("fs")},29294:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-async-storage.external.js")},33873:a=>{"use strict";a.exports=require("path")},35187:(a,b,c)=>{"use strict";c.r(b),c.d(b,{default:()=>g});var d=c(75338),e=c(62789),f=c(78233);async function g(){let a=await (0,e.D1)();return(0,d.jsx)(f.default,{machineId:a})}},41025:a=>{"use strict";a.exports=require("next/dist/server/app-render/dynamic-access-async-storage.external.js")},51455:a=>{"use strict";a.exports=require("node:fs/promises")},55268:(a,b,c)=>{"use strict";c.r(b),c.d(b,{GlobalError:()=>D.a,__next_app__:()=>J,handler:()=>L,pages:()=>I,routeModule:()=>K,tree:()=>H});var d=c(49754),e=c(9117),f=c(46595),g=c(32324),h=c(39326),i=c(38928),j=c(20175),k=c(12),l=c(54290),m=c(12696),n=c(82802),o=c(77533),p=c(45229),q=c(32822),r=c(261),s=c(26453),t=c(52474),u=c(26713),v=c(51356),w=c(62685),x=c(36225),y=c(63446),z=c(2762),A=c(45742),B=c(86439),C=c(81170),D=c.n(C),E=c(62506),F=c(91203),G={};for(let a in E)0>["default","tree","pages","GlobalError","__next_app__","routeModule","handler"].indexOf(a)&&(G[a]=()=>E[a]);c.d(b,G);let H={children:["",{children:["(dashboard)",{children:["dashboard",{children:["cli-tools",{children:["__PAGE__",{},{page:[()=>Promise.resolve().then(c.bind(c,35187)),"/Users/Working/router4/app/src/app/(dashboard)/dashboard/cli-tools/page.js"]}]},{}]},{}]},{layout:[()=>Promise.resolve().then(c.bind(c,64826)),"/Users/Working/router4/app/src/app/(dashboard)/layout.js"],"not-found":[()=>Promise.resolve().then(c.t.bind(c,87028,23)),"next/dist/client/components/builtin/not-found.js"],forbidden:[()=>Promise.resolve().then(c.t.bind(c,90461,23)),"next/dist/client/components/builtin/forbidden.js"],unauthorized:[()=>Promise.resolve().then(c.t.bind(c,32768,23)),"next/dist/client/components/builtin/unauthorized.js"],metadata:{icon:[async a=>(await Promise.resolve().then(c.bind(c,70440))).default(a)],apple:[],openGraph:[],twitter:[],manifest:void 0}}]},{layout:[()=>Promise.resolve().then(c.bind(c,97634)),"/Users/Working/router4/app/src/app/layout.js"],"global-error":[()=>Promise.resolve().then(c.t.bind(c,81170,23)),"next/dist/client/components/builtin/global-error.js"],"not-found":[()=>Promise.resolve().then(c.t.bind(c,87028,23)),"next/dist/client/components/builtin/not-found.js"],forbidden:[()=>Promise.resolve().then(c.t.bind(c,90461,23)),"next/dist/client/components/builtin/forbidden.js"],unauthorized:[()=>Promise.resolve().then(c.t.bind(c,32768,23)),"next/dist/client/components/builtin/unauthorized.js"],metadata:{icon:[async a=>(await Promise.resolve().then(c.bind(c,70440))).default(a)],apple:[],openGraph:[],twitter:[],manifest:void 0}}]}.children,I=["/Users/Working/router4/app/src/app/(dashboard)/dashboard/cli-tools/page.js"],J={require:c,loadChunk:()=>Promise.resolve()},K=new d.AppPageRouteModule({definition:{kind:e.RouteKind.APP_PAGE,page:"/(dashboard)/dashboard/cli-tools/page",pathname:"/dashboard/cli-tools",bundlePath:"",filename:"",appPaths:[]},userland:{loaderTree:H},distDir:".next",relativeProjectDir:""});async function L(a,b,d){var C;let G="/(dashboard)/dashboard/cli-tools/page";"/index"===G&&(G="/");let M=(0,h.getRequestMeta)(a,"postponed"),N=(0,h.getRequestMeta)(a,"minimalMode"),O=await K.prepare(a,b,{srcPage:G,multiZoneDraftMode:!1});if(!O)return b.statusCode=400,b.end("Bad Request"),null==d.waitUntil||d.waitUntil.call(d,Promise.resolve()),null;let{buildId:P,query:Q,params:R,parsedUrl:S,pageIsDynamic:T,buildManifest:U,nextFontManifest:V,reactLoadableManifest:W,serverActionsManifest:X,clientReferenceManifest:Y,subresourceIntegrityManifest:Z,prerenderManifest:$,isDraftMode:_,resolvedPathname:aa,revalidateOnlyGenerated:ab,routerServerContext:ac,nextConfig:ad,interceptionRoutePatterns:ae}=O,af=S.pathname||"/",ag=(0,r.normalizeAppPath)(G),{isOnDemandRevalidate:ah}=O,ai=K.match(af,$),aj=!!$.routes[aa],ak=!!(ai||aj||$.routes[ag]),al=a.headers["user-agent"]||"",am=(0,u.getBotType)(al),an=(0,p.isHtmlBotRequest)(a),ao=(0,h.getRequestMeta)(a,"isPrefetchRSCRequest")??"1"===a.headers[t.NEXT_ROUTER_PREFETCH_HEADER],ap=(0,h.getRequestMeta)(a,"isRSCRequest")??!!a.headers[t.RSC_HEADER],aq=(0,s.getIsPossibleServerAction)(a),ar=(0,m.checkIsAppPPREnabled)(ad.experimental.ppr)&&(null==(C=$.routes[ag]??$.dynamicRoutes[ag])?void 0:C.renderingMode)==="PARTIALLY_STATIC",as=!1,at=!1,au=ar?M:void 0,av=ar&&ap&&!ao,aw=(0,h.getRequestMeta)(a,"segmentPrefetchRSCRequest"),ax=!al||(0,p.shouldServeStreamingMetadata)(al,ad.htmlLimitedBots);an&&ar&&(ak=!1,ax=!1);let ay=!0===K.isDev||!ak||"string"==typeof M||av,az=an&&ar,aA=null;_||!ak||ay||aq||au||av||(aA=aa);let aB=aA;!aB&&K.isDev&&(aB=aa),K.isDev||_||!ak||!ap||av||(0,k.d)(a.headers);let aC={...E,tree:H,pages:I,GlobalError:D(),handler:L,routeModule:K,__next_app__:J};X&&Y&&(0,o.setReferenceManifestsSingleton)({page:G,clientReferenceManifest:Y,serverActionsManifest:X,serverModuleMap:(0,q.createServerModuleMap)({serverActionsManifest:X})});let aD=a.method||"GET",aE=(0,g.getTracer)(),aF=aE.getActiveScopeSpan();try{let f=K.getVaryHeader(aa,ae);b.setHeader("Vary",f);let k=async(c,d)=>{let e=new l.NodeNextRequest(a),f=new l.NodeNextResponse(b);return K.render(e,f,d).finally(()=>{if(!c)return;c.setAttributes({"http.status_code":b.statusCode,"next.rsc":!1});let d=aE.getRootSpanAttributes();if(!d)return;if(d.get("next.span_type")!==i.BaseServerSpan.handleRequest)return void console.warn(`Unexpected root span type '${d.get("next.span_type")}'. Please report this Next.js issue https://github.com/vercel/next.js`);let e=d.get("next.route");if(e){let a=`${aD} ${e}`;c.setAttributes({"next.route":e,"http.route":e,"next.span_name":a}),c.updateName(a)}else c.updateName(`${aD} ${a.url}`)})},m=async({span:e,postponed:f,fallbackRouteParams:g})=>{let i={query:Q,params:R,page:ag,sharedContext:{buildId:P},serverComponentsHmrCache:(0,h.getRequestMeta)(a,"serverComponentsHmrCache"),fallbackRouteParams:g,renderOpts:{App:()=>null,Document:()=>null,pageConfig:{},ComponentMod:aC,Component:(0,j.T)(aC),params:R,routeModule:K,page:G,postponed:f,shouldWaitOnAllReady:az,serveStreamingMetadata:ax,supportsDynamicResponse:"string"==typeof f||ay,buildManifest:U,nextFontManifest:V,reactLoadableManifest:W,subresourceIntegrityManifest:Z,serverActionsManifest:X,clientReferenceManifest:Y,setIsrStatus:null==ac?void 0:ac.setIsrStatus,dir:c(33873).join(process.cwd(),K.relativeProjectDir),isDraftMode:_,isRevalidate:ak&&!f&&!av,botType:am,isOnDemandRevalidate:ah,isPossibleServerAction:aq,assetPrefix:ad.assetPrefix,nextConfigOutput:ad.output,crossOrigin:ad.crossOrigin,trailingSlash:ad.trailingSlash,previewProps:$.preview,deploymentId:ad.deploymentId,enableTainting:ad.experimental.taint,htmlLimitedBots:ad.htmlLimitedBots,devtoolSegmentExplorer:ad.experimental.devtoolSegmentExplorer,reactMaxHeadersLength:ad.reactMaxHeadersLength,multiZoneDraftMode:!1,incrementalCache:(0,h.getRequestMeta)(a,"incrementalCache"),cacheLifeProfiles:ad.experimental.cacheLife,basePath:ad.basePath,serverActions:ad.experimental.serverActions,...as?{nextExport:!0,supportsDynamicResponse:!1,isStaticGeneration:!0,isRevalidate:!0,isDebugDynamicAccesses:as}:{},experimental:{isRoutePPREnabled:ar,expireTime:ad.expireTime,staleTimes:ad.experimental.staleTimes,cacheComponents:!!ad.experimental.cacheComponents,clientSegmentCache:!!ad.experimental.clientSegmentCache,clientParamParsing:!!ad.experimental.clientParamParsing,dynamicOnHover:!!ad.experimental.dynamicOnHover,inlineCss:!!ad.experimental.inlineCss,authInterrupts:!!ad.experimental.authInterrupts,clientTraceMetadata:ad.experimental.clientTraceMetadata||[]},waitUntil:d.waitUntil,onClose:a=>{b.on("close",a)},onAfterTaskError:()=>{},onInstrumentationRequestError:(b,c,d)=>K.onRequestError(a,b,d,ac),err:(0,h.getRequestMeta)(a,"invokeError"),dev:K.isDev}},l=await k(e,i),{metadata:m}=l,{cacheControl:n,headers:o={},fetchTags:p}=m;if(p&&(o[y.NEXT_CACHE_TAGS_HEADER]=p),a.fetchMetrics=m.fetchMetrics,ak&&(null==n?void 0:n.revalidate)===0&&!K.isDev&&!ar){let a=m.staticBailoutInfo,b=Object.defineProperty(Error(`Page changed from static to dynamic at runtime ${aa}${(null==a?void 0:a.description)?`, reason: ${a.description}`:""}
2
+ see more here https://nextjs.org/docs/messages/app-static-to-dynamic-error`),"__NEXT_ERROR_CODE",{value:"E132",enumerable:!1,configurable:!0});if(null==a?void 0:a.stack){let c=a.stack;b.stack=b.message+c.substring(c.indexOf("\n"))}throw b}return{value:{kind:v.CachedRouteKind.APP_PAGE,html:l,headers:o,rscData:m.flightData,postponed:m.postponed,status:m.statusCode,segmentData:m.segmentData},cacheControl:n}},o=async({hasResolved:c,previousCacheEntry:f,isRevalidating:g,span:i})=>{let j,k=!1===K.isDev,l=c||b.writableEnded;if(ah&&ab&&!f&&!N)return(null==ac?void 0:ac.render404)?await ac.render404(a,b):(b.statusCode=404,b.end("This page could not be found")),null;if(ai&&(j=(0,w.parseFallbackField)(ai.fallback)),j===w.FallbackMode.PRERENDER&&(0,u.isBot)(al)&&(!ar||an)&&(j=w.FallbackMode.BLOCKING_STATIC_RENDER),(null==f?void 0:f.isStale)===-1&&(ah=!0),ah&&(j!==w.FallbackMode.NOT_FOUND||f)&&(j=w.FallbackMode.BLOCKING_STATIC_RENDER),!N&&j!==w.FallbackMode.BLOCKING_STATIC_RENDER&&aB&&!l&&!_&&T&&(k||!aj)){let b;if((k||ai)&&j===w.FallbackMode.NOT_FOUND)throw new B.NoFallbackError;if(ar&&!ap){let c="string"==typeof(null==ai?void 0:ai.fallback)?ai.fallback:k?ag:null;if(b=await K.handleResponse({cacheKey:c,req:a,nextConfig:ad,routeKind:e.RouteKind.APP_PAGE,isFallback:!0,prerenderManifest:$,isRoutePPREnabled:ar,responseGenerator:async()=>m({span:i,postponed:void 0,fallbackRouteParams:k||at?(0,n.u)(ag):null}),waitUntil:d.waitUntil}),null===b)return null;if(b)return delete b.cacheControl,b}}let o=ah||g||!au?void 0:au;if(as&&void 0!==o)return{cacheControl:{revalidate:1,expire:void 0},value:{kind:v.CachedRouteKind.PAGES,html:x.default.EMPTY,pageData:{},headers:void 0,status:void 0}};let p=T&&ar&&((0,h.getRequestMeta)(a,"renderFallbackShell")||at)?(0,n.u)(af):null;return m({span:i,postponed:o,fallbackRouteParams:p})},p=async c=>{var f,g,i,j,k;let l,n=await K.handleResponse({cacheKey:aA,responseGenerator:a=>o({span:c,...a}),routeKind:e.RouteKind.APP_PAGE,isOnDemandRevalidate:ah,isRoutePPREnabled:ar,req:a,nextConfig:ad,prerenderManifest:$,waitUntil:d.waitUntil});if(_&&b.setHeader("Cache-Control","private, no-cache, no-store, max-age=0, must-revalidate"),K.isDev&&b.setHeader("Cache-Control","no-store, must-revalidate"),!n){if(aA)throw Object.defineProperty(Error("invariant: cache entry required but not generated"),"__NEXT_ERROR_CODE",{value:"E62",enumerable:!1,configurable:!0});return null}if((null==(f=n.value)?void 0:f.kind)!==v.CachedRouteKind.APP_PAGE)throw Object.defineProperty(Error(`Invariant app-page handler received invalid cache entry ${null==(i=n.value)?void 0:i.kind}`),"__NEXT_ERROR_CODE",{value:"E707",enumerable:!1,configurable:!0});let p="string"==typeof n.value.postponed;ak&&!av&&(!p||ao)&&(N||b.setHeader("x-nextjs-cache",ah?"REVALIDATED":n.isMiss?"MISS":n.isStale?"STALE":"HIT"),b.setHeader(t.NEXT_IS_PRERENDER_HEADER,"1"));let{value:q}=n;if(au)l={revalidate:0,expire:void 0};else if(N&&ap&&!ao&&ar)l={revalidate:0,expire:void 0};else if(!K.isDev)if(_)l={revalidate:0,expire:void 0};else if(ak){if(n.cacheControl)if("number"==typeof n.cacheControl.revalidate){if(n.cacheControl.revalidate<1)throw Object.defineProperty(Error(`Invalid revalidate configuration provided: ${n.cacheControl.revalidate} < 1`),"__NEXT_ERROR_CODE",{value:"E22",enumerable:!1,configurable:!0});l={revalidate:n.cacheControl.revalidate,expire:(null==(j=n.cacheControl)?void 0:j.expire)??ad.expireTime}}else l={revalidate:y.CACHE_ONE_YEAR,expire:void 0}}else b.getHeader("Cache-Control")||(l={revalidate:0,expire:void 0});if(n.cacheControl=l,"string"==typeof aw&&(null==q?void 0:q.kind)===v.CachedRouteKind.APP_PAGE&&q.segmentData){b.setHeader(t.NEXT_DID_POSTPONE_HEADER,"2");let c=null==(k=q.headers)?void 0:k[y.NEXT_CACHE_TAGS_HEADER];N&&ak&&c&&"string"==typeof c&&b.setHeader(y.NEXT_CACHE_TAGS_HEADER,c);let d=q.segmentData.get(aw);return void 0!==d?(0,A.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:x.default.fromStatic(d,t.RSC_CONTENT_TYPE_HEADER),cacheControl:n.cacheControl}):(b.statusCode=204,(0,A.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:x.default.EMPTY,cacheControl:n.cacheControl}))}let r=(0,h.getRequestMeta)(a,"onCacheEntry");if(r&&await r({...n,value:{...n.value,kind:"PAGE"}},{url:(0,h.getRequestMeta)(a,"initURL")}))return null;if(p&&au)throw Object.defineProperty(Error("Invariant: postponed state should not be present on a resume request"),"__NEXT_ERROR_CODE",{value:"E396",enumerable:!1,configurable:!0});if(q.headers){let a={...q.headers};for(let[c,d]of(N&&ak||delete a[y.NEXT_CACHE_TAGS_HEADER],Object.entries(a)))if(void 0!==d)if(Array.isArray(d))for(let a of d)b.appendHeader(c,a);else"number"==typeof d&&(d=d.toString()),b.appendHeader(c,d)}let s=null==(g=q.headers)?void 0:g[y.NEXT_CACHE_TAGS_HEADER];if(N&&ak&&s&&"string"==typeof s&&b.setHeader(y.NEXT_CACHE_TAGS_HEADER,s),!q.status||ap&&ar||(b.statusCode=q.status),!N&&q.status&&F.RedirectStatusCode[q.status]&&ap&&(b.statusCode=200),p&&b.setHeader(t.NEXT_DID_POSTPONE_HEADER,"1"),ap&&!_){if(void 0===q.rscData){if(q.postponed)throw Object.defineProperty(Error("Invariant: Expected postponed to be undefined"),"__NEXT_ERROR_CODE",{value:"E372",enumerable:!1,configurable:!0});return(0,A.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:q.html,cacheControl:av?{revalidate:0,expire:void 0}:n.cacheControl})}return(0,A.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:x.default.fromStatic(q.rscData,t.RSC_CONTENT_TYPE_HEADER),cacheControl:n.cacheControl})}let u=q.html;if(!p||N||ap)return(0,A.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:u,cacheControl:n.cacheControl});if(as)return u.push(new ReadableStream({start(a){a.enqueue(z.ENCODED_TAGS.CLOSED.BODY_AND_HTML),a.close()}})),(0,A.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:u,cacheControl:{revalidate:0,expire:void 0}});let w=new TransformStream;return u.push(w.readable),m({span:c,postponed:q.postponed,fallbackRouteParams:null}).then(async a=>{var b,c;if(!a)throw Object.defineProperty(Error("Invariant: expected a result to be returned"),"__NEXT_ERROR_CODE",{value:"E463",enumerable:!1,configurable:!0});if((null==(b=a.value)?void 0:b.kind)!==v.CachedRouteKind.APP_PAGE)throw Object.defineProperty(Error(`Invariant: expected a page response, got ${null==(c=a.value)?void 0:c.kind}`),"__NEXT_ERROR_CODE",{value:"E305",enumerable:!1,configurable:!0});await a.value.html.pipeTo(w.writable)}).catch(a=>{w.writable.abort(a).catch(a=>{console.error("couldn't abort transformer",a)})}),(0,A.sendRenderResult)({req:a,res:b,generateEtags:ad.generateEtags,poweredByHeader:ad.poweredByHeader,result:u,cacheControl:{revalidate:0,expire:void 0}})};if(!aF)return await aE.withPropagatedContext(a.headers,()=>aE.trace(i.BaseServerSpan.handleRequest,{spanName:`${aD} ${a.url}`,kind:g.SpanKind.SERVER,attributes:{"http.method":aD,"http.target":a.url}},p));await p(aF)}catch(b){throw b instanceof B.NoFallbackError||await K.onRequestError(a,b,{routerKind:"App Router",routePath:G,routeType:"render",revalidateReason:(0,f.c)({isRevalidate:ak,isOnDemandRevalidate:ah})},ac),b}}},55511:a=>{"use strict";a.exports=require("crypto")},55591:a=>{"use strict";a.exports=require("https")},62789:(a,b,c)=>{"use strict";c.d(b,{D1:()=>e});var d=c(31852);async function e(){return await (0,d.Xj)()}},63033:a=>{"use strict";a.exports=require("next/dist/server/app-render/work-unit-async-storage.external.js")},65832:(a,b,c)=>{"use strict";c.a(a,async(a,d)=>{try{c.d(b,{A:()=>j});var e=c(21124),f=c(38301),g=c(56865),h=c(24515),i=a([g]);function j({toolId:a,tool:b,isExpanded:c,onToggle:d,baseUrl:i,apiKeys:j,activeProviders:k=[],cloudEnabled:l=!1}){let[m,n]=(0,f.useState)(null),[o,p]=(0,f.useState)(!1),[q,r]=(0,f.useState)(""),[s,t]=(0,f.useState)(()=>j?.length>0?j[0].key:""),u=a=>{let b=s&&s.trim()?s:l?"your-api-key":"sk_9router";return a.replace(/\{\{baseUrl\}\}/g,i||"http://localhost:3000").replace(/\{\{apiKey\}\}/g,b).replace(/\{\{model\}\}/g,q||"provider/model-id")},v=async(a,b)=>{await navigator.clipboard.writeText(u(a)),n(b),setTimeout(()=>n(null),2e3)},w=k.length>0,x=()=>!b.requiresCloud||!!l;return(0,e.jsxs)(g.Zp,{className:"overflow-hidden",children:[(0,e.jsxs)("div",{className:"flex items-center justify-between hover:cursor-pointer",onClick:d,children:[(0,e.jsxs)("div",{className:"flex items-center gap-4",children:[(0,e.jsx)("div",{className:"size-12 rounded-xl flex items-center justify-center",style:{backgroundColor:`${b.color}15`},children:b.image?(0,e.jsx)(h.default,{src:b.image,alt:b.name,width:32,height:32,className:"size-8 object-contain rounded-lg",onError:a=>{a.target.style.display="none"}}):b.icon?(0,e.jsx)("span",{className:"material-symbols-outlined text-2xl",style:{color:b.color},children:b.icon}):(0,e.jsx)(h.default,{src:`/providers/${a}.png`,alt:b.name,width:32,height:32,className:"size-8 object-contain rounded-lg",onError:a=>{a.target.style.display="none"}})}),(0,e.jsxs)("div",{children:[(0,e.jsx)("h3",{className:"font-semibold text-lg",children:b.name}),(0,e.jsx)("p",{className:"text-sm text-text-muted",children:b.description})]})]}),(0,e.jsx)("span",{className:`material-symbols-outlined text-text-muted transition-transform ${c?"rotate-180":""}`,children:"expand_more"})]}),c&&(0,e.jsx)("div",{className:"mt-6 pt-6 border-t border-border",children:b.guideSteps?(0,e.jsxs)("div",{className:"flex flex-col gap-4",children:[b.notes&&0!==b.notes.length?(0,e.jsx)("div",{className:"flex flex-col gap-2 mb-4",children:b.notes.map((a,b)=>{if("cloudCheck"===a.type&&l)return null;let c="warning"===a.type,d="cloudCheck"===a.type&&!l,f="bg-blue-500/10 border-blue-500/30",g="text-blue-600 dark:text-blue-400",h="text-blue-500",i="info";return c?(f="bg-yellow-500/10 border-yellow-500/30",g="text-yellow-600 dark:text-yellow-400",h="text-yellow-500",i="warning"):d&&(f="bg-red-500/10 border-red-500/30",g="text-red-600 dark:text-red-400",h="text-red-500",i="error"),(0,e.jsxs)("div",{className:`flex items-start gap-3 p-3 rounded-lg border ${f}`,children:[(0,e.jsx)("span",{className:`material-symbols-outlined text-lg ${h}`,children:i}),(0,e.jsx)("p",{className:`text-sm ${g}`,children:a.text})]},b)})}):null,x()&&b.guideSteps.map(a=>(0,e.jsxs)("div",{className:"flex items-start gap-4",children:[(0,e.jsx)("div",{className:"size-8 rounded-full flex items-center justify-center shrink-0 text-sm font-semibold text-white",style:{backgroundColor:b.color},children:a.step}),(0,e.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,e.jsx)("p",{className:"font-medium text-text",children:a.title}),a.desc&&(0,e.jsx)("p",{className:"text-sm text-text-muted mt-0.5",children:a.desc}),"apiKeySelector"===a.type&&(0,e.jsx)("div",{className:"mt-2 flex items-center gap-2",children:j&&j.length>0?(0,e.jsxs)(e.Fragment,{children:[(0,e.jsx)("select",{value:s,onChange:a=>t(a.target.value),className:"flex-1 px-3 py-2 bg-bg-secondary rounded-lg text-sm border border-border focus:outline-none focus:ring-1 focus:ring-primary/50",children:j.map(a=>(0,e.jsx)("option",{value:a.key,children:a.key},a.id))}),(0,e.jsx)("button",{onClick:()=>v(s,"apiKey"),className:"shrink-0 px-3 py-2 bg-bg-secondary hover:bg-bg-tertiary rounded-lg border border-border transition-colors",children:(0,e.jsx)("span",{className:"material-symbols-outlined text-lg",children:"apiKey"===m?"check":"content_copy"})})]}):(0,e.jsx)("span",{className:"text-sm text-text-muted",children:l?"No API keys - Create one in Keys page":"sk_9router"})}),"modelSelector"===a.type&&(0,e.jsxs)("div",{className:"mt-2 flex items-center gap-2",children:[(0,e.jsx)("input",{type:"text",value:q,onChange:a=>r(a.target.value),placeholder:"provider/model-id",className:"flex-1 px-3 py-2 bg-bg-secondary rounded-lg text-sm border border-border focus:outline-none focus:ring-1 focus:ring-primary/50"}),(0,e.jsx)("button",{onClick:()=>p(!0),disabled:!w,className:`shrink-0 px-3 py-2 rounded-lg border text-sm transition-colors ${w?"bg-bg-secondary border-border text-text-main hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Select Model"}),q&&(0,e.jsxs)(e.Fragment,{children:[(0,e.jsx)("button",{onClick:()=>v(q,"model"),className:"shrink-0 px-3 py-2 bg-bg-secondary hover:bg-bg-tertiary rounded-lg border border-border transition-colors",children:(0,e.jsx)("span",{className:"material-symbols-outlined text-lg",children:"model"===m?"check":"content_copy"})}),(0,e.jsx)("button",{onClick:()=>r(""),className:"p-2 text-text-muted hover:text-red-500 rounded transition-colors",title:"Clear",children:(0,e.jsx)("span",{className:"material-symbols-outlined text-lg",children:"close"})})]})]}),a.value&&(0,e.jsxs)("div",{className:"mt-2 flex items-center gap-2",children:[(0,e.jsx)("code",{className:"flex-1 px-3 py-2 bg-bg-secondary rounded-lg text-sm font-mono border border-border truncate",children:u(a.value)}),a.copyable&&(0,e.jsx)("button",{onClick:()=>v(a.value,`${a.step}-${a.title}`),className:"shrink-0 px-3 py-2 bg-bg-secondary hover:bg-bg-tertiary rounded-lg border border-border transition-colors",children:(0,e.jsx)("span",{className:"material-symbols-outlined text-lg",children:m===`${a.step}-${a.title}`?"check":"content_copy"})})]})]})]},a.step)),x()&&b.codeBlock&&(0,e.jsxs)("div",{className:"mt-2",children:[(0,e.jsxs)("div",{className:"flex items-center justify-between mb-2",children:[(0,e.jsx)("span",{className:"text-xs text-text-muted uppercase tracking-wide",children:b.codeBlock.language}),(0,e.jsxs)("button",{onClick:()=>v(b.codeBlock.code,"codeblock"),className:"flex items-center gap-1 px-2 py-1 text-xs bg-bg-secondary hover:bg-bg-tertiary rounded border border-border transition-colors",children:[(0,e.jsx)("span",{className:"material-symbols-outlined text-sm",children:"codeblock"===m?"check":"content_copy"}),"codeblock"===m?"Copied!":"Copy"]})]}),(0,e.jsx)("pre",{className:"p-4 bg-bg-secondary rounded-lg border border-border overflow-x-auto",children:(0,e.jsx)("code",{className:"text-sm font-mono whitespace-pre",children:u(b.codeBlock.code)})})]})]}):(0,e.jsx)("p",{className:"text-text-muted text-sm",children:"Coming soon..."})}),(0,e.jsx)(g.rq,{isOpen:o,onClose:()=>p(!1),onSelect:a=>{r(a.value)},selectedModel:q,activeProviders:k,title:"Select Model"})]})}g=(i.then?(await i)():i)[0],d()}catch(a){d(a)}})},68061:(a,b,c)=>{"use strict";c.d(b,{d:()=>d});let d={claude:{id:"claude",name:"Claude Code",icon:"terminal",color:"#D97757",description:"Anthropic Claude Code CLI",configType:"env",envVars:{baseUrl:"ANTHROPIC_BASE_URL",model:"ANTHROPIC_MODEL",opusModel:"ANTHROPIC_DEFAULT_OPUS_MODEL",sonnetModel:"ANTHROPIC_DEFAULT_SONNET_MODEL",haikuModel:"ANTHROPIC_DEFAULT_HAIKU_MODEL"},modelAliases:["default","sonnet","opus","haiku","opusplan"],settingsFile:"~/.claude/settings.json",defaultModels:[{id:"opus",name:"Claude Opus",alias:"opus",envKey:"ANTHROPIC_DEFAULT_OPUS_MODEL",defaultValue:"cc/claude-opus-4-5-20251101"},{id:"sonnet",name:"Claude Sonnet",alias:"sonnet",envKey:"ANTHROPIC_DEFAULT_SONNET_MODEL",defaultValue:"cc/claude-sonnet-4-5-20250929"},{id:"haiku",name:"Claude Haiku",alias:"haiku",envKey:"ANTHROPIC_DEFAULT_HAIKU_MODEL",defaultValue:"cc/claude-haiku-4-5-20251001"}]},codex:{id:"codex",name:"OpenAI Codex CLI",image:"/providers/codex.png",color:"#10A37F",description:"OpenAI Codex CLI",configType:"custom"},cursor:{id:"cursor",name:"Cursor",image:"/providers/cursor.png",color:"#000000",description:"Cursor AI Code Editor",configType:"guide",requiresCloud:!0,notes:[{type:"warning",text:"Requires Cursor Pro account to use this feature."},{type:"cloudCheck",text:"Cursor routes requests through its own server, so local endpoint is not supported. Please enable Cloud Endpoint in Settings."}],guideSteps:[{step:1,title:"Open Settings",desc:"Go to Settings → Models"},{step:2,title:"Enable OpenAI API",desc:'Enable "OpenAI API key" option'},{step:3,title:"Base URL",value:"{{baseUrl}}/v1",copyable:!0},{step:4,title:"API Key",type:"apiKeySelector"},{step:5,title:"Add Custom Model",desc:'Click "View All Model" → "Add Custom Model"'},{step:6,title:"Select Model",type:"modelSelector"}]},cline:{id:"cline",name:"CLINE",image:"/providers/cline.png",color:"#00D1B2",description:"CLINE AI Assistant",configType:"guide",guideSteps:[{step:1,title:"Open Settings",desc:"Go to CLINE Settings panel"},{step:2,title:"Select Provider",desc:"Choose API Provider → Ollama"},{step:3,title:"Base URL",value:"{{baseUrl}}",copyable:!0},{step:4,title:"API Key",type:"apiKeySelector"},{step:5,title:"Select Model",type:"modelSelector"}]},roo:{id:"roo",name:"Roo",image:"/providers/roo.png",color:"#FF6B6B",description:"Roo AI Assistant",configType:"guide",guideSteps:[{step:1,title:"Open Settings",desc:"Go to Roo Settings panel"},{step:2,title:"Select Provider",desc:"Choose API Provider → Ollama"},{step:3,title:"Base URL",value:"{{baseUrl}}",copyable:!0},{step:4,title:"API Key",type:"apiKeySelector"},{step:5,title:"Select Model",type:"modelSelector"}]},continue:{id:"continue",name:"Continue",image:"/providers/continue.png",color:"#7C3AED",description:"Continue AI Assistant",configType:"guide",guideSteps:[{step:1,title:"Open Config",desc:"Open Continue configuration file"},{step:2,title:"API Key",type:"apiKeySelector"},{step:3,title:"Select Model",type:"modelSelector"},{step:4,title:"Add Model Config",desc:"Add the following configuration to your models array:"}],codeBlock:{language:"json",code:`{
3
3
  "apiBase": "{{baseUrl}}",
4
4
  "title": "{{model}}",
5
5
  "model": "{{model}}",
6
6
  "provider": "openai",
7
7
  "apiKey": "{{apiKey}}"
8
- }`}}};var h=c(77538),i=c(24515);let j="https://9router.com";function k({tool:a,isExpanded:b,onToggle:c,activeProviders:g,modelMappings:h,onModelMappingChange:k,baseUrl:l,hasActiveProviders:m,apiKeys:n,cloudEnabled:o}){let[p,q]=(0,e.useState)(null),[r,s]=(0,e.useState)(!1),[t,u]=(0,e.useState)(!1),[v,w]=(0,e.useState)(!1),[x,y]=(0,e.useState)(null),[z,A]=(0,e.useState)(!1),[B,C]=(0,e.useState)(!1),[D,E]=(0,e.useState)(null),[F,G]=(0,e.useState)(""),[H,I]=(0,e.useState)(!1),[J,K]=(0,e.useState)({}),L=(()=>{if(!p?.installed)return null;let a=p.settings?.env?.ANTHROPIC_BASE_URL;if(!a)return"not_configured";let b=a.includes("localhost")||a.includes("127.0.0.1"),c=o&&j&&a.startsWith(j);return b||c?"configured":"other"})(),M=async()=>{s(!0);try{let a=await fetch("/api/cli-tools/claude-settings"),b=await a.json();q(b)}catch(a){q({installed:!1,error:a.message})}finally{s(!1)}},N=async()=>{u(!0),y(null);try{let b={ANTHROPIC_BASE_URL:l},c=F?.trim()||(n?.length>0?n[0].key:null)||(o?null:"sk_9router");c&&(b.ANTHROPIC_AUTH_TOKEN=c),a.defaultModels.forEach(a=>{let c=h[a.alias];c&&a.envKey&&(b[a.envKey]=c)});let d=await fetch("/api/cli-tools/claude-settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({env:b})}),e=await d.json();d.ok?(y({type:"success",text:"Settings applied successfully!"}),q(a=>({...a,hasBackup:!0,settings:{...a?.settings,env:b}}))):y({type:"error",text:e.error||"Failed to apply settings"})}catch(a){y({type:"error",text:a.message})}finally{u(!1)}},O=async()=>{w(!0),y(null);try{let b=await fetch("/api/cli-tools/claude-settings",{method:"DELETE"}),c=await b.json();b.ok?(y({type:"success",text:"Settings reset successfully!"}),a.defaultModels.forEach(a=>k(a.alias,a.defaultValue||"")),G("")):y({type:"error",text:c.error||"Failed to reset settings"})}catch(a){y({type:"error",text:a.message})}finally{w(!1)}},P=()=>{let b={ANTHROPIC_BASE_URL:l,ANTHROPIC_AUTH_TOKEN:F&&F.trim()?F:o?"<API_KEY_FROM_DASHBOARD>":"sk_9router"};return a.defaultModels.forEach(a=>{let c=h[a.alias];c&&a.envKey&&(b[a.envKey]=c)}),JSON.stringify({env:b},null,2)},Q=async a=>{try{await navigator.clipboard.writeText(a),I(!0),setTimeout(()=>I(!1),2e3)}catch(a){console.log("Failed to copy:",a)}};return(0,d.jsxs)(f.Zp,{className:"overflow-hidden",children:[(0,d.jsxs)("div",{className:"flex items-center justify-between hover:cursor-pointer",onClick:c,children:[(0,d.jsxs)("div",{className:"flex items-center gap-4",children:[(0,d.jsx)("div",{className:"size-12 rounded-xl flex items-center justify-center",style:{backgroundColor:`${a.color}15`},children:(0,d.jsx)(i.default,{src:"/providers/claude.png",alt:a.name,width:32,height:32,className:"size-8 object-contain rounded-lg",onError:a=>{a.target.style.display="none"}})}),(0,d.jsxs)("div",{children:[(0,d.jsxs)("div",{className:"flex items-center gap-2",children:[(0,d.jsx)("h3",{className:"font-semibold text-lg",children:a.name}),"configured"===L&&(0,d.jsx)("span",{className:"px-2 py-0.5 text-xs font-medium bg-green-500/10 text-green-600 dark:text-green-400 rounded-full",children:"Connected"}),"not_configured"===L&&(0,d.jsx)("span",{className:"px-2 py-0.5 text-xs font-medium bg-yellow-500/10 text-yellow-600 dark:text-yellow-400 rounded-full",children:"Not configured"}),"other"===L&&(0,d.jsx)("span",{className:"px-2 py-0.5 text-xs font-medium bg-blue-500/10 text-blue-600 dark:text-blue-400 rounded-full",children:"Other endpoint"})]}),(0,d.jsx)("p",{className:"text-sm text-text-muted",children:a.description})]})]}),(0,d.jsx)("span",{className:`material-symbols-outlined text-text-muted transition-transform ${b?"rotate-180":""}`,children:"expand_more"})]}),b&&(0,d.jsxs)("div",{className:"mt-4 pt-4 border-t border-border flex flex-col gap-4",children:[r&&(0,d.jsxs)("div",{className:"flex items-center gap-2 text-text-muted",children:[(0,d.jsx)("span",{className:"material-symbols-outlined animate-spin",children:"progress_activity"}),(0,d.jsx)("span",{children:"Checking Claude CLI..."})]}),!r&&p&&!p.installed&&(0,d.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,d.jsxs)("div",{className:"flex items-center gap-3 p-4 bg-yellow-500/10 border border-yellow-500/30 rounded-lg",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-yellow-500",children:"warning"}),(0,d.jsxs)("div",{className:"flex-1",children:[(0,d.jsx)("p",{className:"font-medium text-yellow-600 dark:text-yellow-400",children:"Claude CLI not installed"}),(0,d.jsx)("p",{className:"text-sm text-text-muted",children:"Please install Claude CLI to use this feature."})]}),(0,d.jsxs)(f.$n,{variant:"outline",size:"sm",onClick:()=>A(!z),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[18px] mr-1",children:z?"expand_less":"help"}),z?"Hide":"How to Install"]})]}),z&&(0,d.jsxs)("div",{className:"p-4 bg-surface border border-border rounded-lg",children:[(0,d.jsx)("h4",{className:"font-medium mb-3",children:"Installation Guide"}),(0,d.jsxs)("div",{className:"space-y-3 text-sm",children:[(0,d.jsxs)("div",{children:[(0,d.jsx)("p",{className:"text-text-muted mb-1",children:"macOS / Linux / Windows:"}),(0,d.jsx)("code",{className:"block px-3 py-2 bg-black/5 dark:bg-white/5 rounded font-mono text-xs",children:"npm install -g @anthropic-ai/claude-code"})]}),(0,d.jsxs)("p",{className:"text-text-muted",children:["After installation, run ",(0,d.jsx)("code",{className:"px-1 bg-black/5 dark:bg-white/5 rounded",children:"claude"})," to verify."]})]})]})]}),!r&&p?.installed&&(0,d.jsxs)(d.Fragment,{children:[(0,d.jsxs)("div",{className:"flex items-center gap-2",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-green-500 text-[16px]",children:"check_circle"}),(0,d.jsx)("span",{className:"text-xs text-text-muted shrink-0",children:"URL:"}),(0,d.jsx)("code",{className:"text-xs font-mono text-text-main truncate",children:l})]}),(0,d.jsxs)("div",{className:"flex items-center gap-2",children:[(0,d.jsx)("span",{className:"text-xs text-text-muted shrink-0",children:"Key:"}),n.length>0?(0,d.jsx)("select",{value:F,onChange:a=>G(a.target.value),className:"flex-1 px-2 py-1.5 bg-surface rounded text-xs border border-border focus:outline-none focus:ring-1 focus:ring-primary/50",children:n.map(a=>(0,d.jsx)("option",{value:a.key,children:a.key},a.id))}):(0,d.jsx)("span",{className:"text-xs text-text-muted",children:o?"No API keys - Create one in Keys page":"sk_9router"})]}),(0,d.jsx)("div",{className:"flex flex-col gap-2",children:a.defaultModels.map(a=>(0,d.jsxs)("div",{className:"flex items-center gap-2",children:[(0,d.jsx)("span",{className:"w-32 shrink-0 text-sm font-semibold text-text-main text-right",children:a.name}),(0,d.jsx)("span",{className:"material-symbols-outlined text-text-muted text-[14px]",children:"arrow_forward"}),(0,d.jsx)("input",{type:"text",value:h[a.alias]||"",onChange:b=>k(a.alias,b.target.value),placeholder:"provider/model-id",className:"flex-1 px-2 py-1.5 bg-surface rounded border border-border text-xs focus:outline-none focus:ring-1 focus:ring-primary/50"}),(0,d.jsx)("button",{onClick:()=>{E(a.alias),C(!0)},disabled:!m,className:`px-2 py-1.5 rounded border text-xs transition-colors shrink-0 whitespace-nowrap ${m?"bg-surface border-border text-text-main hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Select Model"}),h[a.alias]&&(0,d.jsx)("button",{onClick:()=>k(a.alias,""),className:"p-1 text-text-muted hover:text-red-500 rounded transition-colors",title:"Clear",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"close"})})]},a.alias))}),x&&(0,d.jsxs)("div",{className:`flex items-center gap-2 px-2 py-1.5 rounded text-xs ${"success"===x.type?"bg-green-500/10 text-green-600":"bg-red-500/10 text-red-600"}`,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"success"===x.type?"check_circle":"error"}),(0,d.jsx)("span",{children:x.text})]}),(0,d.jsxs)("div",{className:"flex items-center gap-2",children:[(0,d.jsxs)(f.$n,{variant:"primary",size:"sm",onClick:N,disabled:!m,loading:t,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"save"}),"Apply"]}),(0,d.jsxs)(f.$n,{variant:"outline",size:"sm",onClick:O,disabled:!p?.has9Router,loading:v,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"restore"}),"Reset"]}),(0,d.jsx)(f.$n,{variant:"ghost",size:"sm",onClick:M,children:(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"refresh"})})]}),(0,d.jsxs)("div",{className:"pt-4 border-t border-border flex flex-col gap-3",children:[(0,d.jsx)("p",{className:"text-xs text-text-muted",children:"Or copy config manually:"}),(0,d.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,d.jsxs)("div",{className:"flex items-center justify-between",children:[(0,d.jsx)("span",{className:"text-xs font-medium text-text-main",children:"~/.claude/settings.json"}),(0,d.jsxs)(f.$n,{variant:"ghost",size:"sm",onClick:()=>Q(P()),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:H?"check":"content_copy"}),H?"Copied!":"Copy"]})]}),(0,d.jsx)("pre",{className:"px-3 py-2 bg-black/5 dark:bg-white/5 rounded font-mono text-xs overflow-x-auto whitespace-pre-wrap break-all max-h-40 overflow-y-auto",children:P()})]})]})]})]}),(0,d.jsx)(f.rq,{isOpen:B,onClose:()=>C(!1),onSelect:a=>{D&&k(D,a.value)},selectedModel:D?h[D]:null,activeProviders:g,modelAliases:J,title:`Select model for ${D}`})]})}function l({tool:a,isExpanded:b,onToggle:c,baseUrl:g,apiKeys:h,activeProviders:j,cloudEnabled:k}){let[l,m]=(0,e.useState)(null),[n,o]=(0,e.useState)(!1),[p,q]=(0,e.useState)(!1),[r,s]=(0,e.useState)(!1),[t,u]=(0,e.useState)(null),[v,w]=(0,e.useState)(!1),[x,y]=(0,e.useState)(""),[z,A]=(0,e.useState)(""),[B,C]=(0,e.useState)(!1),[D,E]=(0,e.useState)(!1),[F,G]=(0,e.useState)({}),H=l?.installed?l.config?l.config.includes(g)||l.config.includes("localhost")||l.config.includes("127.0.0.1")?"configured":"other":"not_configured":null,I=async()=>{o(!0);try{let a=await fetch("/api/cli-tools/codex-settings"),b=await a.json();m(b)}catch(a){m({installed:!1,error:a.message})}finally{o(!1)}},J=async()=>{q(!0),u(null);try{let a=x&&x.trim()||k?x:"sk_9router",b=await fetch("/api/cli-tools/codex-settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({baseUrl:g,apiKey:a,model:z})}),c=await b.json();b.ok?(u({type:"success",text:"Settings applied successfully!"}),I()):u({type:"error",text:c.error||"Failed to apply settings"})}catch(a){u({type:"error",text:a.message})}finally{q(!1)}},K=async()=>{s(!0),u(null);try{let a=await fetch("/api/cli-tools/codex-settings",{method:"DELETE"}),b=await a.json();a.ok?(u({type:"success",text:"Settings reset successfully!"}),A(""),I()):u({type:"error",text:b.error||"Failed to reset settings"})}catch(a){u({type:"error",text:a.message})}finally{s(!1)}},L=`# 9Router Configuration for Codex CLI
8
+ }`}}}},71814:(a,b,c)=>{"use strict";c.a(a,async(a,d)=>{try{c.d(b,{A:()=>j});var e=c(21124),f=c(38301),g=c(56865),h=c(24515),i=a([g]);function j({tool:a,isExpanded:b,onToggle:c,baseUrl:d,apiKeys:i,activeProviders:j,cloudEnabled:k}){let[l,m]=(0,f.useState)(null),[n,o]=(0,f.useState)(!1),[p,q]=(0,f.useState)(!1),[r,s]=(0,f.useState)(!1),[t,u]=(0,f.useState)(null),[v,w]=(0,f.useState)(!1),[x,y]=(0,f.useState)(""),[z,A]=(0,f.useState)(""),[B,C]=(0,f.useState)(!1),[D,E]=(0,f.useState)(!1),[F,G]=(0,f.useState)({}),H=l?.installed?l.config?l.config.includes(d)||l.config.includes("localhost")||l.config.includes("127.0.0.1")?"configured":"other":"not_configured":null,I=async()=>{o(!0);try{let a=await fetch("/api/cli-tools/codex-settings"),b=await a.json();m(b)}catch(a){m({installed:!1,error:a.message})}finally{o(!1)}},J=async()=>{q(!0),u(null);try{let a=x&&x.trim()||k?x:"sk_9router",b=await fetch("/api/cli-tools/codex-settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({baseUrl:d,apiKey:a,model:z})}),c=await b.json();b.ok?(u({type:"success",text:"Settings applied successfully!"}),I()):u({type:"error",text:c.error||"Failed to apply settings"})}catch(a){u({type:"error",text:a.message})}finally{q(!1)}},K=async()=>{s(!0),u(null);try{let a=await fetch("/api/cli-tools/codex-settings",{method:"DELETE"}),b=await a.json();a.ok?(u({type:"success",text:"Settings reset successfully!"}),A(""),I()):u({type:"error",text:b.error||"Failed to reset settings"})}catch(a){u({type:"error",text:a.message})}finally{s(!1)}},L=`# 9Router Configuration for Codex CLI
9
9
  model = "${z}"
10
10
  model_provider = "9router"
11
11
 
12
12
  [model_providers.9router]
13
13
  name = "9Router"
14
- base_url = "${g}/v1"
14
+ base_url = "${d}/v1"
15
15
  wire_api = "responses"
16
- `,M=JSON.stringify({OPENAI_API_KEY:x&&x.trim()?x:k?"<API_KEY_FROM_DASHBOARD>":"sk_9router"},null,2),N=async a=>{try{await navigator.clipboard.writeText(a),C(!0),setTimeout(()=>C(!1),2e3)}catch(a){console.log("Failed to copy:",a)}};return(0,d.jsxs)(f.Zp,{className:"overflow-hidden",children:[(0,d.jsxs)("div",{className:"flex items-center justify-between hover:cursor-pointer",onClick:c,children:[(0,d.jsxs)("div",{className:"flex items-center gap-4",children:[(0,d.jsx)("div",{className:"size-12 rounded-xl flex items-center justify-center",style:{backgroundColor:`${a.color}15`},children:(0,d.jsx)(i.default,{src:"/providers/codex.png",alt:a.name,width:32,height:32,className:"size-8 object-contain rounded-lg",onError:a=>{a.target.style.display="none"}})}),(0,d.jsxs)("div",{children:[(0,d.jsxs)("div",{className:"flex items-center gap-2",children:[(0,d.jsx)("h3",{className:"font-semibold text-lg",children:a.name}),"configured"===H&&(0,d.jsx)("span",{className:"px-2 py-0.5 text-xs font-medium bg-green-500/10 text-green-600 dark:text-green-400 rounded-full",children:"Connected"}),"not_configured"===H&&(0,d.jsx)("span",{className:"px-2 py-0.5 text-xs font-medium bg-yellow-500/10 text-yellow-600 dark:text-yellow-400 rounded-full",children:"Not configured"}),"other"===H&&(0,d.jsx)("span",{className:"px-2 py-0.5 text-xs font-medium bg-blue-500/10 text-blue-600 dark:text-blue-400 rounded-full",children:"Other endpoint"})]}),(0,d.jsx)("p",{className:"text-sm text-text-muted",children:a.description})]})]}),(0,d.jsx)("span",{className:`material-symbols-outlined text-text-muted transition-transform ${b?"rotate-180":""}`,children:"expand_more"})]}),b&&(0,d.jsxs)("div",{className:"mt-4 pt-4 border-t border-border flex flex-col gap-4",children:[n&&(0,d.jsxs)("div",{className:"flex items-center gap-2 text-text-muted",children:[(0,d.jsx)("span",{className:"material-symbols-outlined animate-spin",children:"progress_activity"}),(0,d.jsx)("span",{children:"Checking Codex CLI..."})]}),!n&&l&&!l.installed&&(0,d.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,d.jsxs)("div",{className:"flex items-center gap-3 p-4 bg-yellow-500/10 border border-yellow-500/30 rounded-lg",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-yellow-500",children:"warning"}),(0,d.jsxs)("div",{className:"flex-1",children:[(0,d.jsx)("p",{className:"font-medium text-yellow-600 dark:text-yellow-400",children:"Codex CLI not installed"}),(0,d.jsx)("p",{className:"text-sm text-text-muted",children:"Please install Codex CLI to use auto-apply feature."})]}),(0,d.jsxs)(f.$n,{variant:"outline",size:"sm",onClick:()=>w(!v),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[18px] mr-1",children:v?"expand_less":"help"}),v?"Hide":"How to Install"]})]}),v&&(0,d.jsxs)("div",{className:"p-4 bg-surface border border-border rounded-lg",children:[(0,d.jsx)("h4",{className:"font-medium mb-3",children:"Installation Guide"}),(0,d.jsxs)("div",{className:"space-y-3 text-sm",children:[(0,d.jsxs)("div",{children:[(0,d.jsx)("p",{className:"text-text-muted mb-1",children:"macOS / Linux / Windows:"}),(0,d.jsx)("code",{className:"block px-3 py-2 bg-black/5 dark:bg-white/5 rounded font-mono text-xs",children:"npm install -g @openai/codex"})]}),(0,d.jsxs)("p",{className:"text-text-muted",children:["After installation, run ",(0,d.jsx)("code",{className:"px-1 bg-black/5 dark:bg-white/5 rounded",children:"codex"})," to verify."]}),(0,d.jsx)("div",{className:"pt-2 border-t border-border",children:(0,d.jsxs)("p",{className:"text-text-muted text-xs",children:["Codex uses ",(0,d.jsx)("code",{className:"px-1 bg-black/5 dark:bg-white/5 rounded",children:"~/.codex/auth.json"})," with ",(0,d.jsx)("code",{className:"px-1 bg-black/5 dark:bg-white/5 rounded",children:"OPENAI_API_KEY"}),'. Click "Apply" to auto-configure.']})})]})]})]}),!n&&l?.installed&&(0,d.jsxs)(d.Fragment,{children:[(0,d.jsxs)("div",{className:"flex items-center gap-2",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-green-500 text-[16px]",children:"check_circle"}),(0,d.jsx)("span",{className:"text-xs text-text-muted shrink-0",children:"URL:"}),(0,d.jsxs)("code",{className:"text-xs font-mono text-text-main truncate",children:[g,"/v1"]})]}),(0,d.jsxs)("div",{className:"flex items-center gap-2",children:[(0,d.jsx)("span",{className:"text-xs text-text-muted shrink-0",children:"Key:"}),h.length>0?(0,d.jsx)("select",{value:x,onChange:a=>y(a.target.value),className:"flex-1 px-2 py-1.5 bg-surface rounded text-xs border border-border focus:outline-none focus:ring-1 focus:ring-primary/50",children:h.map(a=>(0,d.jsx)("option",{value:a.key,children:a.key},a.id))}):(0,d.jsx)("span",{className:"text-xs text-text-muted",children:k?"No API keys - Create one in Keys page":"sk_9router"})]}),(0,d.jsxs)("div",{className:"flex items-center gap-2",children:[(0,d.jsx)("span",{className:"w-16 shrink-0 text-sm font-semibold text-text-main text-right",children:"Model"}),(0,d.jsx)("span",{className:"material-symbols-outlined text-text-muted text-[14px]",children:"arrow_forward"}),(0,d.jsx)("input",{type:"text",value:z,onChange:a=>A(a.target.value),placeholder:"provider/model-id",className:"flex-1 px-2 py-1.5 bg-surface rounded border border-border text-xs focus:outline-none focus:ring-1 focus:ring-primary/50"}),(0,d.jsx)("button",{onClick:()=>E(!0),disabled:!j?.length,className:`px-2 py-1.5 rounded border text-xs transition-colors shrink-0 whitespace-nowrap ${j?.length?"bg-surface border-border text-text-main hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Select Model"}),z&&(0,d.jsx)("button",{onClick:()=>A(""),className:"p-1 text-text-muted hover:text-red-500 rounded transition-colors",title:"Clear",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"close"})})]}),t&&(0,d.jsxs)("div",{className:`flex items-center gap-2 px-2 py-1.5 rounded text-xs ${"success"===t.type?"bg-green-500/10 text-green-600":"bg-red-500/10 text-red-600"}`,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"success"===t.type?"check_circle":"error"}),(0,d.jsx)("span",{children:t.text})]}),(0,d.jsxs)("div",{className:"flex items-center gap-2",children:[(0,d.jsxs)(f.$n,{variant:"primary",size:"sm",onClick:J,disabled:!x||!z,loading:p,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"save"}),"Apply"]}),(0,d.jsxs)(f.$n,{variant:"outline",size:"sm",onClick:K,disabled:!l.has9Router,loading:r,children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"restore"}),"Reset"]}),(0,d.jsx)(f.$n,{variant:"ghost",size:"sm",onClick:I,children:(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"refresh"})})]})]}),(0,d.jsxs)("div",{className:"pt-4 border-t border-border flex flex-col gap-3",children:[(0,d.jsx)("p",{className:"text-xs text-text-muted",children:"Or copy config manually:"}),(0,d.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,d.jsxs)("div",{className:"flex items-center justify-between",children:[(0,d.jsx)("span",{className:"text-xs font-medium text-text-main",children:"~/.codex/config.toml"}),(0,d.jsxs)(f.$n,{variant:"ghost",size:"sm",onClick:()=>N(L),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:B?"check":"content_copy"}),B?"Copied!":"Copy"]})]}),(0,d.jsx)("pre",{className:"px-3 py-2 bg-black/5 dark:bg-white/5 rounded font-mono text-xs overflow-x-auto whitespace-pre-wrap break-all max-h-32 overflow-y-auto",children:L})]}),(0,d.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,d.jsxs)("div",{className:"flex items-center justify-between",children:[(0,d.jsx)("span",{className:"text-xs font-medium text-text-main",children:"~/.codex/auth.json"}),(0,d.jsxs)(f.$n,{variant:"ghost",size:"sm",onClick:()=>N(M),children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:B?"check":"content_copy"}),B?"Copied!":"Copy"]})]}),(0,d.jsx)("pre",{className:"px-3 py-2 bg-black/5 dark:bg-white/5 rounded font-mono text-xs overflow-x-auto whitespace-pre-wrap break-all max-h-32 overflow-y-auto",children:M})]})]})]}),(0,d.jsx)(f.rq,{isOpen:D,onClose:()=>E(!1),onSelect:a=>{A(a.value),E(!1)},selectedModel:z,activeProviders:j,modelAliases:F,title:"Select Model for Codex"})]})}function m({toolId:a,tool:b,isExpanded:c,onToggle:g,baseUrl:h,apiKeys:j,activeProviders:k=[],cloudEnabled:l=!1}){let[m,n]=(0,e.useState)(null),[o,p]=(0,e.useState)(!1),[q,r]=(0,e.useState)(""),[s,t]=(0,e.useState)(()=>j?.length>0?j[0].key:""),u=a=>{let b=s&&s.trim()?s:l?"your-api-key":"sk_9router";return a.replace(/\{\{baseUrl\}\}/g,h||"http://localhost:3000").replace(/\{\{apiKey\}\}/g,b).replace(/\{\{model\}\}/g,q||"provider/model-id")},v=async(a,b)=>{await navigator.clipboard.writeText(u(a)),n(b),setTimeout(()=>n(null),2e3)},w=k.length>0,x=()=>!b.requiresCloud||!!l;return(0,d.jsxs)(f.Zp,{className:"overflow-hidden",children:[(0,d.jsxs)("div",{className:"flex items-center justify-between hover:cursor-pointer",onClick:g,children:[(0,d.jsxs)("div",{className:"flex items-center gap-4",children:[(0,d.jsx)("div",{className:"size-12 rounded-xl flex items-center justify-center",style:{backgroundColor:`${b.color}15`},children:b.image?(0,d.jsx)(i.default,{src:b.image,alt:b.name,width:32,height:32,className:"size-8 object-contain rounded-lg",onError:a=>{a.target.style.display="none"}}):b.icon?(0,d.jsx)("span",{className:"material-symbols-outlined text-2xl",style:{color:b.color},children:b.icon}):(0,d.jsx)(i.default,{src:`/providers/${a}.png`,alt:b.name,width:32,height:32,className:"size-8 object-contain rounded-lg",onError:a=>{a.target.style.display="none"}})}),(0,d.jsxs)("div",{children:[(0,d.jsx)("h3",{className:"font-semibold text-lg",children:b.name}),(0,d.jsx)("p",{className:"text-sm text-text-muted",children:b.description})]})]}),(0,d.jsx)("span",{className:`material-symbols-outlined text-text-muted transition-transform ${c?"rotate-180":""}`,children:"expand_more"})]}),c&&(0,d.jsx)("div",{className:"mt-6 pt-6 border-t border-border",children:b.guideSteps?(0,d.jsxs)("div",{className:"flex flex-col gap-4",children:[b.notes&&0!==b.notes.length?(0,d.jsx)("div",{className:"flex flex-col gap-2 mb-4",children:b.notes.map((a,b)=>{if("cloudCheck"===a.type&&l)return null;let c="warning"===a.type,e="cloudCheck"===a.type&&!l,f="bg-blue-500/10 border-blue-500/30",g="text-blue-600 dark:text-blue-400",h="text-blue-500",i="info";return c?(f="bg-yellow-500/10 border-yellow-500/30",g="text-yellow-600 dark:text-yellow-400",h="text-yellow-500",i="warning"):e&&(f="bg-red-500/10 border-red-500/30",g="text-red-600 dark:text-red-400",h="text-red-500",i="error"),(0,d.jsxs)("div",{className:`flex items-start gap-3 p-3 rounded-lg border ${f}`,children:[(0,d.jsx)("span",{className:`material-symbols-outlined text-lg ${h}`,children:i}),(0,d.jsx)("p",{className:`text-sm ${g}`,children:a.text})]},b)})}):null,x()&&b.guideSteps.map(a=>(0,d.jsxs)("div",{className:"flex items-start gap-4",children:[(0,d.jsx)("div",{className:"size-8 rounded-full flex items-center justify-center shrink-0 text-sm font-semibold text-white",style:{backgroundColor:b.color},children:a.step}),(0,d.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,d.jsx)("p",{className:"font-medium text-text",children:a.title}),a.desc&&(0,d.jsx)("p",{className:"text-sm text-text-muted mt-0.5",children:a.desc}),"apiKeySelector"===a.type&&(0,d.jsx)("div",{className:"mt-2 flex items-center gap-2",children:j&&j.length>0?(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)("select",{value:s,onChange:a=>t(a.target.value),className:"flex-1 px-3 py-2 bg-bg-secondary rounded-lg text-sm border border-border focus:outline-none focus:ring-1 focus:ring-primary/50",children:j.map(a=>(0,d.jsx)("option",{value:a.key,children:a.key},a.id))}),(0,d.jsx)("button",{onClick:()=>v(s,"apiKey"),className:"shrink-0 px-3 py-2 bg-bg-secondary hover:bg-bg-tertiary rounded-lg border border-border transition-colors",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-lg",children:"apiKey"===m?"check":"content_copy"})})]}):(0,d.jsx)("span",{className:"text-sm text-text-muted",children:l?"No API keys - Create one in Keys page":"sk_9router"})}),"modelSelector"===a.type&&(0,d.jsxs)("div",{className:"mt-2 flex items-center gap-2",children:[(0,d.jsx)("input",{type:"text",value:q,onChange:a=>r(a.target.value),placeholder:"provider/model-id",className:"flex-1 px-3 py-2 bg-bg-secondary rounded-lg text-sm border border-border focus:outline-none focus:ring-1 focus:ring-primary/50"}),(0,d.jsx)("button",{onClick:()=>p(!0),disabled:!w,className:`shrink-0 px-3 py-2 rounded-lg border text-sm transition-colors ${w?"bg-bg-secondary border-border text-text-main hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Select Model"}),q&&(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)("button",{onClick:()=>v(q,"model"),className:"shrink-0 px-3 py-2 bg-bg-secondary hover:bg-bg-tertiary rounded-lg border border-border transition-colors",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-lg",children:"model"===m?"check":"content_copy"})}),(0,d.jsx)("button",{onClick:()=>r(""),className:"p-2 text-text-muted hover:text-red-500 rounded transition-colors",title:"Clear",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-lg",children:"close"})})]})]}),a.value&&(0,d.jsxs)("div",{className:"mt-2 flex items-center gap-2",children:[(0,d.jsx)("code",{className:"flex-1 px-3 py-2 bg-bg-secondary rounded-lg text-sm font-mono border border-border truncate",children:u(a.value)}),a.copyable&&(0,d.jsx)("button",{onClick:()=>v(a.value,`${a.step}-${a.title}`),className:"shrink-0 px-3 py-2 bg-bg-secondary hover:bg-bg-tertiary rounded-lg border border-border transition-colors",children:(0,d.jsx)("span",{className:"material-symbols-outlined text-lg",children:m===`${a.step}-${a.title}`?"check":"content_copy"})})]})]})]},a.step)),x()&&b.codeBlock&&(0,d.jsxs)("div",{className:"mt-2",children:[(0,d.jsxs)("div",{className:"flex items-center justify-between mb-2",children:[(0,d.jsx)("span",{className:"text-xs text-text-muted uppercase tracking-wide",children:b.codeBlock.language}),(0,d.jsxs)("button",{onClick:()=>v(b.codeBlock.code,"codeblock"),className:"flex items-center gap-1 px-2 py-1 text-xs bg-bg-secondary hover:bg-bg-tertiary rounded border border-border transition-colors",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-sm",children:"codeblock"===m?"check":"content_copy"}),"codeblock"===m?"Copied!":"Copy"]})]}),(0,d.jsx)("pre",{className:"p-4 bg-bg-secondary rounded-lg border border-border overflow-x-auto",children:(0,d.jsx)("code",{className:"text-sm font-mono whitespace-pre",children:u(b.codeBlock.code)})})]})]}):(0,d.jsx)("p",{className:"text-text-muted text-sm",children:"Coming soon..."})}),(0,d.jsx)(f.rq,{isOpen:o,onClose:()=>p(!1),onSelect:a=>{r(a.value)},selectedModel:q,activeProviders:k,title:"Select Model"})]})}let n="https://9router.com";function o({machineId:a}){let[b,c]=(0,e.useState)([]),[i,j]=(0,e.useState)(!0),[o,p]=(0,e.useState)(null),[q,r]=(0,e.useState)({}),[s,t]=(0,e.useState)(!1),[u,v]=(0,e.useState)([]),w=()=>b.filter(a=>!1!==a.isActive);if(i)return(0,d.jsx)("div",{className:"flex flex-col gap-6",children:(0,d.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,d.jsx)(f.Qv,{}),(0,d.jsx)(f.Qv,{}),(0,d.jsx)(f.Qv,{})]})});let x=(()=>{let a=w(),b=[],c=new Set;return a.forEach(a=>{let d=h.Xg[a.provider]||a.provider;(0,h.KC)(a.provider).forEach(e=>{let f=`${d}/${e.id}`;c.has(f)||(c.add(f),b.push({value:f,label:`${d}/${e.id}`,provider:a.provider,alias:d,connectionName:a.name,modelId:e.id}))})}),0===b.length&&Object.entries(h.vq).forEach(([a,c])=>{c.forEach(c=>{let d=`${a}/${c.id}`;b.push({value:d,label:`${a}/${c.id}`,provider:a,alias:a,connectionName:a,modelId:c.id})})}),b})().length>0;return(0,d.jsxs)("div",{className:"flex flex-col gap-6",children:[!x&&(0,d.jsx)(f.Zp,{className:"border-yellow-500/50 bg-yellow-500/5",children:(0,d.jsxs)("div",{className:"flex items-center gap-3",children:[(0,d.jsx)("span",{className:"material-symbols-outlined text-yellow-500",children:"warning"}),(0,d.jsxs)("div",{children:[(0,d.jsx)("p",{className:"font-medium text-yellow-600 dark:text-yellow-400",children:"No active providers"}),(0,d.jsx)("p",{className:"text-sm text-text-muted",children:"Please add and connect providers first to configure CLI tools."})]})]})}),(0,d.jsx)("div",{className:"flex flex-col gap-4",children:Object.entries(g).map(([a,b])=>((a,b)=>{let c={tool:b,isExpanded:o===a,onToggle:()=>p(o===a?null:a),baseUrl:s&&n?n:"http://localhost:3000",apiKeys:u};switch(a){case"claude":return(0,d.jsx)(k,{...c,activeProviders:w(),modelMappings:q[a]||{},onModelMappingChange:(b,c)=>{r(d=>({...d,[a]:{...d[a],[b]:c}}))},hasActiveProviders:x,cloudEnabled:s},a);case"codex":return(0,d.jsx)(l,{...c,activeProviders:w(),cloudEnabled:s},a);default:return(0,d.jsx)(m,{toolId:a,...c,activeProviders:w(),cloudEnabled:s},a)}})(a,b))})]})}},73024:a=>{"use strict";a.exports=require("node:fs")},73136:a=>{"use strict";a.exports=require("node:url")},76760:a=>{"use strict";a.exports=require("node:path")},77598:a=>{"use strict";a.exports=require("node:crypto")},78233:(a,b,c)=>{"use strict";c.d(b,{default:()=>d});let d=(0,c(97954).registerClientReference)(function(){throw Error("Attempted to call the default export of \"/Users/Working/router4/app/src/app/(dashboard)/dashboard/cli-tools/CLIToolsPageClient.js\" from the server, but it's on the client. It's not possible to invoke a client function from the server, it can only be rendered as a Component or passed to props of a Client Component.")},"/Users/Working/router4/app/src/app/(dashboard)/dashboard/cli-tools/CLIToolsPageClient.js","default")},79551:a=>{"use strict";a.exports=require("url")},79646:a=>{"use strict";a.exports=require("child_process")},86439:a=>{"use strict";a.exports=require("next/dist/shared/lib/no-fallback-error.external")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[5873,1428,2826,8298,799,7506,4515,1582,3103,1354],()=>b(b.s=55268));module.exports=c})();
16
+ `,M=x&&x.trim()?x:k?"<API_KEY_FROM_DASHBOARD>":"sk_9router",N=JSON.stringify({OPENAI_API_KEY:M},null,2),O=async a=>{try{await navigator.clipboard.writeText(a),C(!0),setTimeout(()=>C(!1),2e3)}catch(a){console.log("Failed to copy:",a)}};return(0,e.jsxs)(g.Zp,{className:"overflow-hidden",children:[(0,e.jsxs)("div",{className:"flex items-center justify-between hover:cursor-pointer",onClick:c,children:[(0,e.jsxs)("div",{className:"flex items-center gap-4",children:[(0,e.jsx)("div",{className:"size-12 rounded-xl flex items-center justify-center",style:{backgroundColor:`${a.color}15`},children:(0,e.jsx)(h.default,{src:"/providers/codex.png",alt:a.name,width:32,height:32,className:"size-8 object-contain rounded-lg",onError:a=>{a.target.style.display="none"}})}),(0,e.jsxs)("div",{children:[(0,e.jsxs)("div",{className:"flex items-center gap-2",children:[(0,e.jsx)("h3",{className:"font-semibold text-lg",children:a.name}),"configured"===H&&(0,e.jsx)("span",{className:"px-2 py-0.5 text-xs font-medium bg-green-500/10 text-green-600 dark:text-green-400 rounded-full",children:"Connected"}),"not_configured"===H&&(0,e.jsx)("span",{className:"px-2 py-0.5 text-xs font-medium bg-yellow-500/10 text-yellow-600 dark:text-yellow-400 rounded-full",children:"Not configured"}),"other"===H&&(0,e.jsx)("span",{className:"px-2 py-0.5 text-xs font-medium bg-blue-500/10 text-blue-600 dark:text-blue-400 rounded-full",children:"Other endpoint"})]}),(0,e.jsx)("p",{className:"text-sm text-text-muted",children:a.description})]})]}),(0,e.jsx)("span",{className:`material-symbols-outlined text-text-muted transition-transform ${b?"rotate-180":""}`,children:"expand_more"})]}),b&&(0,e.jsxs)("div",{className:"mt-4 pt-4 border-t border-border flex flex-col gap-4",children:[n&&(0,e.jsxs)("div",{className:"flex items-center gap-2 text-text-muted",children:[(0,e.jsx)("span",{className:"material-symbols-outlined animate-spin",children:"progress_activity"}),(0,e.jsx)("span",{children:"Checking Codex CLI..."})]}),!n&&l&&!l.installed&&(0,e.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,e.jsxs)("div",{className:"flex items-center gap-3 p-4 bg-yellow-500/10 border border-yellow-500/30 rounded-lg",children:[(0,e.jsx)("span",{className:"material-symbols-outlined text-yellow-500",children:"warning"}),(0,e.jsxs)("div",{className:"flex-1",children:[(0,e.jsx)("p",{className:"font-medium text-yellow-600 dark:text-yellow-400",children:"Codex CLI not installed"}),(0,e.jsx)("p",{className:"text-sm text-text-muted",children:"Please install Codex CLI to use auto-apply feature."})]}),(0,e.jsxs)(g.$n,{variant:"outline",size:"sm",onClick:()=>w(!v),children:[(0,e.jsx)("span",{className:"material-symbols-outlined text-[18px] mr-1",children:v?"expand_less":"help"}),v?"Hide":"How to Install"]})]}),v&&(0,e.jsxs)("div",{className:"p-4 bg-surface border border-border rounded-lg",children:[(0,e.jsx)("h4",{className:"font-medium mb-3",children:"Installation Guide"}),(0,e.jsxs)("div",{className:"space-y-3 text-sm",children:[(0,e.jsxs)("div",{children:[(0,e.jsx)("p",{className:"text-text-muted mb-1",children:"macOS / Linux / Windows:"}),(0,e.jsx)("code",{className:"block px-3 py-2 bg-black/5 dark:bg-white/5 rounded font-mono text-xs",children:"npm install -g @openai/codex"})]}),(0,e.jsxs)("p",{className:"text-text-muted",children:["After installation, run ",(0,e.jsx)("code",{className:"px-1 bg-black/5 dark:bg-white/5 rounded",children:"codex"})," to verify."]}),(0,e.jsx)("div",{className:"pt-2 border-t border-border",children:(0,e.jsxs)("p",{className:"text-text-muted text-xs",children:["Codex uses ",(0,e.jsx)("code",{className:"px-1 bg-black/5 dark:bg-white/5 rounded",children:"~/.codex/auth.json"})," with ",(0,e.jsx)("code",{className:"px-1 bg-black/5 dark:bg-white/5 rounded",children:"OPENAI_API_KEY"}),'. Click "Apply" to auto-configure.']})})]})]})]}),!n&&l?.installed&&(0,e.jsxs)(e.Fragment,{children:[(0,e.jsxs)("div",{className:"flex items-center gap-2",children:[(0,e.jsx)("span",{className:"material-symbols-outlined text-green-500 text-[16px]",children:"check_circle"}),(0,e.jsx)("span",{className:"text-xs text-text-muted shrink-0",children:"URL:"}),(0,e.jsxs)("code",{className:"text-xs font-mono text-text-main truncate",children:[d,"/v1"]})]}),(0,e.jsxs)("div",{className:"flex items-center gap-2",children:[(0,e.jsx)("span",{className:"text-xs text-text-muted shrink-0",children:"Key:"}),i.length>0?(0,e.jsx)("select",{value:x,onChange:a=>y(a.target.value),className:"flex-1 px-2 py-1.5 bg-surface rounded text-xs border border-border focus:outline-none focus:ring-1 focus:ring-primary/50",children:i.map(a=>(0,e.jsx)("option",{value:a.key,children:a.key},a.id))}):(0,e.jsx)("span",{className:"text-xs text-text-muted",children:k?"No API keys - Create one in Keys page":"sk_9router"})]}),(0,e.jsxs)("div",{className:"flex items-center gap-2",children:[(0,e.jsx)("span",{className:"w-16 shrink-0 text-sm font-semibold text-text-main text-right",children:"Model"}),(0,e.jsx)("span",{className:"material-symbols-outlined text-text-muted text-[14px]",children:"arrow_forward"}),(0,e.jsx)("input",{type:"text",value:z,onChange:a=>A(a.target.value),placeholder:"provider/model-id",className:"flex-1 px-2 py-1.5 bg-surface rounded border border-border text-xs focus:outline-none focus:ring-1 focus:ring-primary/50"}),(0,e.jsx)("button",{onClick:()=>E(!0),disabled:!j?.length,className:`px-2 py-1.5 rounded border text-xs transition-colors shrink-0 whitespace-nowrap ${j?.length?"bg-surface border-border text-text-main hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Select Model"}),z&&(0,e.jsx)("button",{onClick:()=>A(""),className:"p-1 text-text-muted hover:text-red-500 rounded transition-colors",title:"Clear",children:(0,e.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"close"})})]}),t&&(0,e.jsxs)("div",{className:`flex items-center gap-2 px-2 py-1.5 rounded text-xs ${"success"===t.type?"bg-green-500/10 text-green-600":"bg-red-500/10 text-red-600"}`,children:[(0,e.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"success"===t.type?"check_circle":"error"}),(0,e.jsx)("span",{children:t.text})]}),(0,e.jsxs)("div",{className:"flex items-center gap-2",children:[(0,e.jsxs)(g.$n,{variant:"primary",size:"sm",onClick:J,disabled:!x||!z,loading:p,children:[(0,e.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"save"}),"Apply"]}),(0,e.jsxs)(g.$n,{variant:"outline",size:"sm",onClick:K,disabled:!l.has9Router,loading:r,children:[(0,e.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"restore"}),"Reset"]}),(0,e.jsx)(g.$n,{variant:"ghost",size:"sm",onClick:I,children:(0,e.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"refresh"})})]})]}),(0,e.jsxs)("div",{className:"pt-4 border-t border-border flex flex-col gap-3",children:[(0,e.jsx)("p",{className:"text-xs text-text-muted",children:"Or copy config manually:"}),(0,e.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,e.jsxs)("div",{className:"flex items-center justify-between",children:[(0,e.jsx)("span",{className:"text-xs font-medium text-text-main",children:"~/.codex/config.toml"}),(0,e.jsxs)(g.$n,{variant:"ghost",size:"sm",onClick:()=>O(L),children:[(0,e.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:B?"check":"content_copy"}),B?"Copied!":"Copy"]})]}),(0,e.jsx)("pre",{className:"px-3 py-2 bg-black/5 dark:bg-white/5 rounded font-mono text-xs overflow-x-auto whitespace-pre-wrap break-all max-h-32 overflow-y-auto",children:L})]}),(0,e.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,e.jsxs)("div",{className:"flex items-center justify-between",children:[(0,e.jsx)("span",{className:"text-xs font-medium text-text-main",children:"~/.codex/auth.json"}),(0,e.jsxs)(g.$n,{variant:"ghost",size:"sm",onClick:()=>O(N),children:[(0,e.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:B?"check":"content_copy"}),B?"Copied!":"Copy"]})]}),(0,e.jsx)("pre",{className:"px-3 py-2 bg-black/5 dark:bg-white/5 rounded font-mono text-xs overflow-x-auto whitespace-pre-wrap break-all max-h-32 overflow-y-auto",children:N})]})]})]}),(0,e.jsx)(g.rq,{isOpen:D,onClose:()=>E(!1),onSelect:a=>{A(a.value),E(!1)},selectedModel:z,activeProviders:j,modelAliases:F,title:"Select Model for Codex"})]})}g=(i.then?(await i)():i)[0],d()}catch(a){d(a)}})},73024:a=>{"use strict";a.exports=require("node:fs")},73136:a=>{"use strict";a.exports=require("node:url")},75623:(a,b,c)=>{"use strict";c.a(a,async(a,d)=>{try{c.d(b,{default:()=>l});var e=c(21124),f=c(38301),g=c(56865),h=c(68061),i=c(91666),j=c(84705),k=a([g,i,j]);[g,i,j]=k.then?(await k)():k;let m="https://9router.com";function l({machineId:a}){let[b,c]=(0,f.useState)([]),[d,k]=(0,f.useState)(!0),[l,n]=(0,f.useState)(null),[o,p]=(0,f.useState)({}),[q,r]=(0,f.useState)(!1),[s,t]=(0,f.useState)([]),u=()=>b.filter(a=>!1!==a.isActive);if(d)return(0,e.jsx)("div",{className:"flex flex-col gap-6",children:(0,e.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,e.jsx)(g.Qv,{}),(0,e.jsx)(g.Qv,{}),(0,e.jsx)(g.Qv,{})]})});let v=(()=>{let a=u(),b=[],c=new Set;return a.forEach(a=>{let d=i.Xg[a.provider]||a.provider;(0,i.KC)(a.provider).forEach(e=>{let f=`${d}/${e.id}`;c.has(f)||(c.add(f),b.push({value:f,label:`${d}/${e.id}`,provider:a.provider,alias:d,connectionName:a.name,modelId:e.id}))})}),0===b.length&&Object.entries(i.vq).forEach(([a,c])=>{c.forEach(c=>{let d=`${a}/${c.id}`;b.push({value:d,label:`${a}/${c.id}`,provider:a,alias:a,connectionName:a,modelId:c.id})})}),b})().length>0;return(0,e.jsxs)("div",{className:"flex flex-col gap-6",children:[!v&&(0,e.jsx)(g.Zp,{className:"border-yellow-500/50 bg-yellow-500/5",children:(0,e.jsxs)("div",{className:"flex items-center gap-3",children:[(0,e.jsx)("span",{className:"material-symbols-outlined text-yellow-500",children:"warning"}),(0,e.jsxs)("div",{children:[(0,e.jsx)("p",{className:"font-medium text-yellow-600 dark:text-yellow-400",children:"No active providers"}),(0,e.jsx)("p",{className:"text-sm text-text-muted",children:"Please add and connect providers first to configure CLI tools."})]})]})}),(0,e.jsx)("div",{className:"flex flex-col gap-4",children:Object.entries(h.d).map(([a,b])=>((a,b)=>{let c={tool:b,isExpanded:l===a,onToggle:()=>n(l===a?null:a),baseUrl:q&&m?m:"http://localhost:3000",apiKeys:s};switch(a){case"claude":return(0,e.jsx)(j.Tk,{...c,activeProviders:u(),modelMappings:o[a]||{},onModelMappingChange:(b,c)=>{p(d=>({...d,[a]:{...d[a],[b]:c}}))},hasActiveProviders:v,cloudEnabled:q},a);case"codex":return(0,e.jsx)(j.Ah,{...c,activeProviders:u(),cloudEnabled:q},a);default:return(0,e.jsx)(j.a7,{toolId:a,...c,activeProviders:u(),cloudEnabled:q},a)}})(a,b))})]})}d()}catch(a){d(a)}})},76760:a=>{"use strict";a.exports=require("node:path")},77598:a=>{"use strict";a.exports=require("node:crypto")},78233:(a,b,c)=>{"use strict";c.d(b,{default:()=>d});let d=(0,c(97954).registerClientReference)(function(){throw Error("Attempted to call the default export of \"/Users/Working/router4/app/src/app/(dashboard)/dashboard/cli-tools/CLIToolsPageClient.js\" from the server, but it's on the client. It's not possible to invoke a client function from the server, it can only be rendered as a Component or passed to props of a Client Component.")},"/Users/Working/router4/app/src/app/(dashboard)/dashboard/cli-tools/CLIToolsPageClient.js","default")},79646:a=>{"use strict";a.exports=require("child_process")},81630:a=>{"use strict";a.exports=require("http")},82235:(a,b,c)=>{"use strict";c.a(a,async(a,d)=>{try{c.d(b,{A:()=>j});var e=c(21124),f=c(38301),g=c(56865),h=c(24515),i=a([g]);g=(i.then?(await i)():i)[0];let k="https://9router.com";function j({tool:a,isExpanded:b,onToggle:c,activeProviders:d,modelMappings:i,onModelMappingChange:j,baseUrl:l,hasActiveProviders:m,apiKeys:n,cloudEnabled:o}){let[p,q]=(0,f.useState)(null),[r,s]=(0,f.useState)(!1),[t,u]=(0,f.useState)(!1),[v,w]=(0,f.useState)(!1),[x,y]=(0,f.useState)(null),[z,A]=(0,f.useState)(!1),[B,C]=(0,f.useState)(!1),[D,E]=(0,f.useState)(null),[F,G]=(0,f.useState)(""),[H,I]=(0,f.useState)(!1),[J,K]=(0,f.useState)({}),L=(()=>{if(!p?.installed)return null;let a=p.settings?.env?.ANTHROPIC_BASE_URL;if(!a)return"not_configured";let b=a.includes("localhost")||a.includes("127.0.0.1"),c=o&&k&&a.startsWith(k);return b||c?"configured":"other"})(),M=async()=>{s(!0);try{let a=await fetch("/api/cli-tools/claude-settings"),b=await a.json();q(b)}catch(a){q({installed:!1,error:a.message})}finally{s(!1)}},N=async()=>{u(!0),y(null);try{let b={ANTHROPIC_BASE_URL:l},c=F?.trim()||(n?.length>0?n[0].key:null)||(o?null:"sk_9router");c&&(b.ANTHROPIC_AUTH_TOKEN=c),a.defaultModels.forEach(a=>{let c=i[a.alias];c&&a.envKey&&(b[a.envKey]=c)});let d=await fetch("/api/cli-tools/claude-settings",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({env:b})}),e=await d.json();d.ok?(y({type:"success",text:"Settings applied successfully!"}),q(a=>({...a,hasBackup:!0,settings:{...a?.settings,env:b}}))):y({type:"error",text:e.error||"Failed to apply settings"})}catch(a){y({type:"error",text:a.message})}finally{u(!1)}},O=async()=>{w(!0),y(null);try{let b=await fetch("/api/cli-tools/claude-settings",{method:"DELETE"}),c=await b.json();b.ok?(y({type:"success",text:"Settings reset successfully!"}),a.defaultModels.forEach(a=>j(a.alias,a.defaultValue||"")),G("")):y({type:"error",text:c.error||"Failed to reset settings"})}catch(a){y({type:"error",text:a.message})}finally{w(!1)}},P=()=>{let b=F&&F.trim()?F:o?"<API_KEY_FROM_DASHBOARD>":"sk_9router",c={ANTHROPIC_BASE_URL:l,ANTHROPIC_AUTH_TOKEN:b};return a.defaultModels.forEach(a=>{let b=i[a.alias];b&&a.envKey&&(c[a.envKey]=b)}),JSON.stringify({env:c},null,2)},Q=async a=>{try{await navigator.clipboard.writeText(a),I(!0),setTimeout(()=>I(!1),2e3)}catch(a){console.log("Failed to copy:",a)}};return(0,e.jsxs)(g.Zp,{className:"overflow-hidden",children:[(0,e.jsxs)("div",{className:"flex items-center justify-between hover:cursor-pointer",onClick:c,children:[(0,e.jsxs)("div",{className:"flex items-center gap-4",children:[(0,e.jsx)("div",{className:"size-12 rounded-xl flex items-center justify-center",style:{backgroundColor:`${a.color}15`},children:(0,e.jsx)(h.default,{src:"/providers/claude.png",alt:a.name,width:32,height:32,className:"size-8 object-contain rounded-lg",onError:a=>{a.target.style.display="none"}})}),(0,e.jsxs)("div",{children:[(0,e.jsxs)("div",{className:"flex items-center gap-2",children:[(0,e.jsx)("h3",{className:"font-semibold text-lg",children:a.name}),"configured"===L&&(0,e.jsx)("span",{className:"px-2 py-0.5 text-xs font-medium bg-green-500/10 text-green-600 dark:text-green-400 rounded-full",children:"Connected"}),"not_configured"===L&&(0,e.jsx)("span",{className:"px-2 py-0.5 text-xs font-medium bg-yellow-500/10 text-yellow-600 dark:text-yellow-400 rounded-full",children:"Not configured"}),"other"===L&&(0,e.jsx)("span",{className:"px-2 py-0.5 text-xs font-medium bg-blue-500/10 text-blue-600 dark:text-blue-400 rounded-full",children:"Other endpoint"})]}),(0,e.jsx)("p",{className:"text-sm text-text-muted",children:a.description})]})]}),(0,e.jsx)("span",{className:`material-symbols-outlined text-text-muted transition-transform ${b?"rotate-180":""}`,children:"expand_more"})]}),b&&(0,e.jsxs)("div",{className:"mt-4 pt-4 border-t border-border flex flex-col gap-4",children:[r&&(0,e.jsxs)("div",{className:"flex items-center gap-2 text-text-muted",children:[(0,e.jsx)("span",{className:"material-symbols-outlined animate-spin",children:"progress_activity"}),(0,e.jsx)("span",{children:"Checking Claude CLI..."})]}),!r&&p&&!p.installed&&(0,e.jsxs)("div",{className:"flex flex-col gap-4",children:[(0,e.jsxs)("div",{className:"flex items-center gap-3 p-4 bg-yellow-500/10 border border-yellow-500/30 rounded-lg",children:[(0,e.jsx)("span",{className:"material-symbols-outlined text-yellow-500",children:"warning"}),(0,e.jsxs)("div",{className:"flex-1",children:[(0,e.jsx)("p",{className:"font-medium text-yellow-600 dark:text-yellow-400",children:"Claude CLI not installed"}),(0,e.jsx)("p",{className:"text-sm text-text-muted",children:"Please install Claude CLI to use this feature."})]}),(0,e.jsxs)(g.$n,{variant:"outline",size:"sm",onClick:()=>A(!z),children:[(0,e.jsx)("span",{className:"material-symbols-outlined text-[18px] mr-1",children:z?"expand_less":"help"}),z?"Hide":"How to Install"]})]}),z&&(0,e.jsxs)("div",{className:"p-4 bg-surface border border-border rounded-lg",children:[(0,e.jsx)("h4",{className:"font-medium mb-3",children:"Installation Guide"}),(0,e.jsxs)("div",{className:"space-y-3 text-sm",children:[(0,e.jsxs)("div",{children:[(0,e.jsx)("p",{className:"text-text-muted mb-1",children:"macOS / Linux / Windows:"}),(0,e.jsx)("code",{className:"block px-3 py-2 bg-black/5 dark:bg-white/5 rounded font-mono text-xs",children:"npm install -g @anthropic-ai/claude-code"})]}),(0,e.jsxs)("p",{className:"text-text-muted",children:["After installation, run ",(0,e.jsx)("code",{className:"px-1 bg-black/5 dark:bg-white/5 rounded",children:"claude"})," to verify."]})]})]})]}),!r&&p?.installed&&(0,e.jsxs)(e.Fragment,{children:[(0,e.jsxs)("div",{className:"flex items-center gap-2",children:[(0,e.jsx)("span",{className:"material-symbols-outlined text-green-500 text-[16px]",children:"check_circle"}),(0,e.jsx)("span",{className:"text-xs text-text-muted shrink-0",children:"URL:"}),(0,e.jsx)("code",{className:"text-xs font-mono text-text-main truncate",children:l})]}),(0,e.jsxs)("div",{className:"flex items-center gap-2",children:[(0,e.jsx)("span",{className:"text-xs text-text-muted shrink-0",children:"Key:"}),n.length>0?(0,e.jsx)("select",{value:F,onChange:a=>G(a.target.value),className:"flex-1 px-2 py-1.5 bg-surface rounded text-xs border border-border focus:outline-none focus:ring-1 focus:ring-primary/50",children:n.map(a=>(0,e.jsx)("option",{value:a.key,children:a.key},a.id))}):(0,e.jsx)("span",{className:"text-xs text-text-muted",children:o?"No API keys - Create one in Keys page":"sk_9router"})]}),(0,e.jsx)("div",{className:"flex flex-col gap-2",children:a.defaultModels.map(a=>(0,e.jsxs)("div",{className:"flex items-center gap-2",children:[(0,e.jsx)("span",{className:"w-32 shrink-0 text-sm font-semibold text-text-main text-right",children:a.name}),(0,e.jsx)("span",{className:"material-symbols-outlined text-text-muted text-[14px]",children:"arrow_forward"}),(0,e.jsx)("input",{type:"text",value:i[a.alias]||"",onChange:b=>j(a.alias,b.target.value),placeholder:"provider/model-id",className:"flex-1 px-2 py-1.5 bg-surface rounded border border-border text-xs focus:outline-none focus:ring-1 focus:ring-primary/50"}),(0,e.jsx)("button",{onClick:()=>{var b;return b=a.alias,void(E(b),C(!0))},disabled:!m,className:`px-2 py-1.5 rounded border text-xs transition-colors shrink-0 whitespace-nowrap ${m?"bg-surface border-border text-text-main hover:border-primary cursor-pointer":"opacity-50 cursor-not-allowed border-border"}`,children:"Select Model"}),i[a.alias]&&(0,e.jsx)("button",{onClick:()=>j(a.alias,""),className:"p-1 text-text-muted hover:text-red-500 rounded transition-colors",title:"Clear",children:(0,e.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"close"})})]},a.alias))}),x&&(0,e.jsxs)("div",{className:`flex items-center gap-2 px-2 py-1.5 rounded text-xs ${"success"===x.type?"bg-green-500/10 text-green-600":"bg-red-500/10 text-red-600"}`,children:[(0,e.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"success"===x.type?"check_circle":"error"}),(0,e.jsx)("span",{children:x.text})]}),(0,e.jsxs)("div",{className:"flex items-center gap-2",children:[(0,e.jsxs)(g.$n,{variant:"primary",size:"sm",onClick:N,disabled:!m,loading:t,children:[(0,e.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"save"}),"Apply"]}),(0,e.jsxs)(g.$n,{variant:"outline",size:"sm",onClick:O,disabled:!p?.has9Router,loading:v,children:[(0,e.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:"restore"}),"Reset"]}),(0,e.jsx)(g.$n,{variant:"ghost",size:"sm",onClick:M,children:(0,e.jsx)("span",{className:"material-symbols-outlined text-[14px]",children:"refresh"})})]}),(0,e.jsxs)("div",{className:"pt-4 border-t border-border flex flex-col gap-3",children:[(0,e.jsx)("p",{className:"text-xs text-text-muted",children:"Or copy config manually:"}),(0,e.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,e.jsxs)("div",{className:"flex items-center justify-between",children:[(0,e.jsx)("span",{className:"text-xs font-medium text-text-main",children:"~/.claude/settings.json"}),(0,e.jsxs)(g.$n,{variant:"ghost",size:"sm",onClick:()=>Q(P()),children:[(0,e.jsx)("span",{className:"material-symbols-outlined text-[14px] mr-1",children:H?"check":"content_copy"}),H?"Copied!":"Copy"]})]}),(0,e.jsx)("pre",{className:"px-3 py-2 bg-black/5 dark:bg-white/5 rounded font-mono text-xs overflow-x-auto whitespace-pre-wrap break-all max-h-40 overflow-y-auto",children:P()})]})]})]})]}),(0,e.jsx)(g.rq,{isOpen:B,onClose:()=>C(!1),onSelect:a=>{D&&j(D,a.value)},selectedModel:D?i[D]:null,activeProviders:d,modelAliases:J,title:`Select model for ${D}`})]})}d()}catch(a){d(a)}})},84705:(a,b,c)=>{"use strict";c.a(a,async(a,d)=>{try{c.d(b,{Ah:()=>f.A,Tk:()=>e.A,a7:()=>g.A});var e=c(82235),f=c(71814),g=c(65832),h=a([e,f,g]);[e,f,g]=h.then?(await h)():h,d()}catch(a){d(a)}})},86439:a=>{"use strict";a.exports=require("next/dist/shared/lib/no-fallback-error.external")}};var b=require("../../../../webpack-runtime.js");b.C(a);var c=b.X(0,[5873,1428,2826,8298,799,7506,4515,9858,3103,1354],()=>b(b.s=55268));module.exports=c})();
@@ -1 +1 @@
1
- {"version":1,"files":["../../../../../../../package.json","../../../../../../node_modules/next/dist/client/components/app-router-headers.js","../../../../../../node_modules/next/dist/compiled/@opentelemetry/api/index.js","../../../../../../node_modules/next/dist/compiled/@opentelemetry/api/package.json","../../../../../../node_modules/next/dist/compiled/jsonwebtoken/index.js","../../../../../../node_modules/next/dist/compiled/jsonwebtoken/package.json","../../../../../../node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js","../../../../../../node_modules/next/dist/lib/client-and-server-references.js","../../../../../../node_modules/next/dist/lib/constants.js","../../../../../../node_modules/next/dist/lib/interop-default.js","../../../../../../node_modules/next/dist/lib/is-error.js","../../../../../../node_modules/next/dist/lib/semver-noop.js","../../../../../../node_modules/next/dist/server/app-render/action-async-storage-instance.js","../../../../../../node_modules/next/dist/server/app-render/action-async-storage.external.js","../../../../../../node_modules/next/dist/server/app-render/after-task-async-storage-instance.js","../../../../../../node_modules/next/dist/server/app-render/after-task-async-storage.external.js","../../../../../../node_modules/next/dist/server/app-render/async-local-storage.js","../../../../../../node_modules/next/dist/server/app-render/cache-signal.js","../../../../../../node_modules/next/dist/server/app-render/dynamic-access-async-storage-instance.js","../../../../../../node_modules/next/dist/server/app-render/dynamic-access-async-storage.external.js","../../../../../../node_modules/next/dist/server/app-render/module-loading/track-module-loading.external.js","../../../../../../node_modules/next/dist/server/app-render/module-loading/track-module-loading.instance.js","../../../../../../node_modules/next/dist/server/app-render/work-async-storage-instance.js","../../../../../../node_modules/next/dist/server/app-render/work-async-storage.external.js","../../../../../../node_modules/next/dist/server/app-render/work-unit-async-storage-instance.js","../../../../../../node_modules/next/dist/server/app-render/work-unit-async-storage.external.js","../../../../../../node_modules/next/dist/server/lib/cache-handlers/default.external.js","../../../../../../node_modules/next/dist/server/lib/incremental-cache/memory-cache.external.js","../../../../../../node_modules/next/dist/server/lib/incremental-cache/shared-cache-controls.external.js","../../../../../../node_modules/next/dist/server/lib/incremental-cache/tags-manifest.external.js","../../../../../../node_modules/next/dist/server/lib/lru-cache.js","../../../../../../node_modules/next/dist/server/lib/router-utils/instrumentation-globals.external.js","../../../../../../node_modules/next/dist/server/lib/router-utils/instrumentation-node-extensions.js","../../../../../../node_modules/next/dist/server/lib/trace/constants.js","../../../../../../node_modules/next/dist/server/lib/trace/tracer.js","../../../../../../node_modules/next/dist/server/load-manifest.external.js","../../../../../../node_modules/next/dist/server/response-cache/types.js","../../../../../../node_modules/next/dist/shared/lib/deep-freeze.js","../../../../../../node_modules/next/dist/shared/lib/invariant-error.js","../../../../../../node_modules/next/dist/shared/lib/is-plain-object.js","../../../../../../node_modules/next/dist/shared/lib/is-thenable.js","../../../../../../node_modules/next/dist/shared/lib/no-fallback-error.external.js","../../../../../../node_modules/next/dist/shared/lib/page-path/ensure-leading-slash.js","../../../../../../node_modules/next/dist/shared/lib/router/utils/app-paths.js","../../../../../../node_modules/next/dist/shared/lib/router/utils/html-bots.js","../../../../../../node_modules/next/dist/shared/lib/router/utils/is-bot.js","../../../../../../node_modules/next/dist/shared/lib/segment.js","../../../../../../node_modules/next/dist/shared/lib/server-reference-info.js","../../../../../../node_modules/next/package.json","../../../../../../package.json","../../../../../package.json","../../../../chunks/1104.js","../../../../chunks/1354.js","../../../../chunks/1428.js","../../../../chunks/1582.js","../../../../chunks/1717.js","../../../../chunks/2045.js","../../../../chunks/2328.js","../../../../chunks/2826.js","../../../../chunks/3103.js","../../../../chunks/3809.js","../../../../chunks/4515.js","../../../../chunks/4656.js","../../../../chunks/5873.js","../../../../chunks/7506.js","../../../../chunks/799.js","../../../../chunks/8298.js","../../../../chunks/8764.js","../../../../chunks/9285.js","../../../../webpack-runtime.js","page_client-reference-manifest.js"]}
1
+ {"version":1,"files":["../../../../../../../package.json","../../../../../../node_modules/next/dist/client/components/app-router-headers.js","../../../../../../node_modules/next/dist/compiled/@opentelemetry/api/index.js","../../../../../../node_modules/next/dist/compiled/@opentelemetry/api/package.json","../../../../../../node_modules/next/dist/compiled/jsonwebtoken/index.js","../../../../../../node_modules/next/dist/compiled/jsonwebtoken/package.json","../../../../../../node_modules/next/dist/compiled/next-server/app-page.runtime.prod.js","../../../../../../node_modules/next/dist/lib/client-and-server-references.js","../../../../../../node_modules/next/dist/lib/constants.js","../../../../../../node_modules/next/dist/lib/interop-default.js","../../../../../../node_modules/next/dist/lib/is-error.js","../../../../../../node_modules/next/dist/lib/semver-noop.js","../../../../../../node_modules/next/dist/server/app-render/action-async-storage-instance.js","../../../../../../node_modules/next/dist/server/app-render/action-async-storage.external.js","../../../../../../node_modules/next/dist/server/app-render/after-task-async-storage-instance.js","../../../../../../node_modules/next/dist/server/app-render/after-task-async-storage.external.js","../../../../../../node_modules/next/dist/server/app-render/async-local-storage.js","../../../../../../node_modules/next/dist/server/app-render/cache-signal.js","../../../../../../node_modules/next/dist/server/app-render/dynamic-access-async-storage-instance.js","../../../../../../node_modules/next/dist/server/app-render/dynamic-access-async-storage.external.js","../../../../../../node_modules/next/dist/server/app-render/module-loading/track-module-loading.external.js","../../../../../../node_modules/next/dist/server/app-render/module-loading/track-module-loading.instance.js","../../../../../../node_modules/next/dist/server/app-render/work-async-storage-instance.js","../../../../../../node_modules/next/dist/server/app-render/work-async-storage.external.js","../../../../../../node_modules/next/dist/server/app-render/work-unit-async-storage-instance.js","../../../../../../node_modules/next/dist/server/app-render/work-unit-async-storage.external.js","../../../../../../node_modules/next/dist/server/lib/cache-handlers/default.external.js","../../../../../../node_modules/next/dist/server/lib/incremental-cache/memory-cache.external.js","../../../../../../node_modules/next/dist/server/lib/incremental-cache/shared-cache-controls.external.js","../../../../../../node_modules/next/dist/server/lib/incremental-cache/tags-manifest.external.js","../../../../../../node_modules/next/dist/server/lib/lru-cache.js","../../../../../../node_modules/next/dist/server/lib/router-utils/instrumentation-globals.external.js","../../../../../../node_modules/next/dist/server/lib/router-utils/instrumentation-node-extensions.js","../../../../../../node_modules/next/dist/server/lib/trace/constants.js","../../../../../../node_modules/next/dist/server/lib/trace/tracer.js","../../../../../../node_modules/next/dist/server/load-manifest.external.js","../../../../../../node_modules/next/dist/server/response-cache/types.js","../../../../../../node_modules/next/dist/shared/lib/deep-freeze.js","../../../../../../node_modules/next/dist/shared/lib/invariant-error.js","../../../../../../node_modules/next/dist/shared/lib/is-plain-object.js","../../../../../../node_modules/next/dist/shared/lib/is-thenable.js","../../../../../../node_modules/next/dist/shared/lib/no-fallback-error.external.js","../../../../../../node_modules/next/dist/shared/lib/page-path/ensure-leading-slash.js","../../../../../../node_modules/next/dist/shared/lib/router/utils/app-paths.js","../../../../../../node_modules/next/dist/shared/lib/router/utils/html-bots.js","../../../../../../node_modules/next/dist/shared/lib/router/utils/is-bot.js","../../../../../../node_modules/next/dist/shared/lib/segment.js","../../../../../../node_modules/next/dist/shared/lib/server-reference-info.js","../../../../../../node_modules/next/package.json","../../../../../../package.json","../../../../../package.json","../../../../chunks/1104.js","../../../../chunks/1354.js","../../../../chunks/1428.js","../../../../chunks/1717.js","../../../../chunks/2045.js","../../../../chunks/2328.js","../../../../chunks/2826.js","../../../../chunks/3103.js","../../../../chunks/3809.js","../../../../chunks/4515.js","../../../../chunks/4656.js","../../../../chunks/5873.js","../../../../chunks/7506.js","../../../../chunks/799.js","../../../../chunks/8298.js","../../../../chunks/8764.js","../../../../chunks/9285.js","../../../../chunks/9858.js","../../../../webpack-runtime.js","page_client-reference-manifest.js"]}