@claudiolabs/claudin 1.1.35 → 1.1.37

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 (820) hide show
  1. package/dist/chunks/App-1.1.37-gvacrdsk.mjs +1 -0
  2. package/dist/chunks/ApproveApiKey-1.1.37-rnnbn40a.mjs +1 -0
  3. package/dist/chunks/AutoModeOptInDialog-1.1.37-g6ta4m2v.mjs +1 -0
  4. package/dist/chunks/BypassPermissionsModeDialog-1.1.37-pk4aghdz.mjs +1 -0
  5. package/dist/chunks/ClaudeMdExternalIncludesDialog-1.1.37-hymvtk1w.mjs +1 -0
  6. package/dist/chunks/ConsoleOAuthFlow-1.1.37-p8fwd4tm.mjs +1 -0
  7. package/dist/chunks/DiffDialog-1.1.37-hb26z7b7.mjs +6 -0
  8. package/dist/chunks/Doctor-1.1.37-g60gf1vr.mjs +1 -0
  9. package/dist/chunks/ExplorerDialog-1.1.37-w0ek8efz.mjs +6 -0
  10. package/dist/chunks/ITermBackend-1.1.37-tp4qnkf7.mjs +1 -0
  11. package/dist/chunks/InvalidConfigDialog-1.1.37-5ds363er.mjs +1 -0
  12. package/dist/chunks/InvalidSettingsDialog-1.1.37-qaz2nf35.mjs +1 -0
  13. package/dist/chunks/MigrationDialog-1.1.37-cxe5gn9z.mjs +1 -0
  14. package/dist/chunks/Onboarding-1.1.37-jsrbvfaa.mjs +1 -0
  15. package/dist/chunks/ProviderManager-1.1.37-kmfet3bc.mjs +1 -0
  16. package/dist/chunks/REPL-1.1.37-mx8g4asq.mjs +1 -0
  17. package/dist/chunks/ResumeConversation-1.1.37-1j1egpzv.mjs +1 -0
  18. package/dist/chunks/TeleportProgress-1.1.37-s6gpj3tk.mjs +1 -0
  19. package/dist/chunks/TeleportRepoMismatchDialog-1.1.37-06r6s8k3.mjs +1 -0
  20. package/dist/chunks/TeleportResumeWrapper-1.1.37-vk5478hq.mjs +1 -0
  21. package/dist/chunks/TmuxBackend-1.1.37-08ypek7f.mjs +9 -0
  22. package/dist/chunks/ToolSearchTool-1.1.37-j3j1tnac.mjs +1 -0
  23. package/dist/chunks/TrustDialog-1.1.37-dy4r3sef.mjs +1 -0
  24. package/dist/chunks/activeProvider-1.1.37-r4p9gt6p.mjs +1 -0
  25. package/dist/chunks/add-dir-1.1.37-hsgnnqm5.mjs +1 -0
  26. package/dist/chunks/agentTypes-1.1.37-e0zrjgxd.mjs +1 -0
  27. package/dist/chunks/agents-1.1.37-770krh9a.mjs +110 -0
  28. package/dist/chunks/agents-1.1.37-n5gk09na.mjs +3 -0
  29. package/dist/chunks/api-1.1.37-bwy6n0v8.mjs +1 -0
  30. package/dist/chunks/asciicast-1.1.37-t7zpdmt1.mjs +1 -0
  31. package/dist/chunks/auth-1.1.37-apskerg1.mjs +1 -0
  32. package/dist/chunks/auth-1.1.37-t0yjn0qg.mjs +1 -0
  33. package/dist/chunks/autoMode-1.1.37-a94rgbvb.mjs +52 -0
  34. package/dist/chunks/autoModeSetup-1.1.37-8g5tdnzc.mjs +44 -0
  35. package/dist/chunks/autoUpdater-1.1.37-pe8hzmys.mjs +1 -0
  36. package/dist/chunks/backgroundHousekeeping-1.1.37-r98mdthk.mjs +1 -0
  37. package/dist/chunks/branch-1.1.37-1a761dqp.mjs +4 -0
  38. package/dist/chunks/bridge-1.1.37-djx2nh0s.mjs +2 -0
  39. package/dist/chunks/bridgeConfig-1.1.37-wsz2v4gw.mjs +1 -0
  40. package/dist/chunks/bridgeEnabled-1.1.37-pht9tpgd.mjs +1 -0
  41. package/dist/chunks/bridgeMain-1.1.37-btaaq723.mjs +64 -0
  42. package/dist/chunks/bridgePointer-1.1.37-97bjx2gt.mjs +1 -0
  43. package/dist/chunks/btw-1.1.37-kzbnzfwv.mjs +1 -0
  44. package/dist/chunks/buddy-1.1.37-r155thdv.mjs +3 -0
  45. package/dist/chunks/cache-probe-1.1.37-szdjedc6.mjs +21 -0
  46. package/dist/chunks/cacheStats-1.1.37-zcq6bfv7.mjs +4 -0
  47. package/dist/chunks/caches-1.1.37-m3bsp8q4.mjs +1 -0
  48. package/dist/chunks/cd-1.1.37-bgh3jr0j.mjs +3 -0
  49. package/dist/chunks/claudeDesktop-1.1.37-d5rmp7j9.mjs +1 -0
  50. package/dist/chunks/claudemd-1.1.37-zqxz2brp.mjs +1 -0
  51. package/dist/chunks/clear-1.1.37-a28jd9f5.mjs +1 -0
  52. package/dist/chunks/clearTerminal-1.1.37-1vwtn9rv.mjs +1 -0
  53. package/dist/chunks/cli-1.1.37-07v28734.mjs +24 -0
  54. package/dist/chunks/cli-1.1.37-0g18ppvn.mjs +2 -0
  55. package/dist/chunks/cli-1.1.37-0t8trtcs.mjs +135 -0
  56. package/dist/chunks/cli-1.1.37-160hvn22.mjs +2 -0
  57. package/dist/chunks/cli-1.1.37-16r2w6eh.mjs +2 -0
  58. package/dist/chunks/cli-1.1.37-16ycb15m.mjs +2 -0
  59. package/dist/chunks/cli-1.1.37-1esm8vyn.mjs +2 -0
  60. package/dist/chunks/cli-1.1.37-1nx0h24b.mjs +34 -0
  61. package/dist/chunks/cli-1.1.37-1sn4ganc.mjs +6 -0
  62. package/dist/chunks/cli-1.1.37-22erav9m.mjs +2 -0
  63. package/dist/chunks/cli-1.1.37-240c02km.mjs +4 -0
  64. package/dist/chunks/cli-1.1.37-26cht952.mjs +4 -0
  65. package/dist/chunks/cli-1.1.37-2gsgt0yq.mjs +2 -0
  66. package/dist/chunks/cli-1.1.37-2xne39h9.mjs +6 -0
  67. package/dist/chunks/cli-1.1.37-37swmf5n.mjs +2 -0
  68. package/dist/chunks/cli-1.1.37-39bw2pz6.mjs +2 -0
  69. package/dist/chunks/cli-1.1.37-3j7g0j34.mjs +2 -0
  70. package/dist/chunks/cli-1.1.37-3k4d07av.mjs +2 -0
  71. package/dist/chunks/cli-1.1.37-3pyzesy7.mjs +2 -0
  72. package/dist/chunks/cli-1.1.37-41q5f236.mjs +63 -0
  73. package/dist/chunks/cli-1.1.37-422098yx.mjs +26 -0
  74. package/dist/chunks/cli-1.1.37-45phxq6t.mjs +2 -0
  75. package/dist/chunks/cli-1.1.37-46pcgpjk.mjs +5 -0
  76. package/dist/chunks/cli-1.1.37-4829k99z.mjs +8 -0
  77. package/dist/chunks/cli-1.1.37-4cwzzzkp.mjs +2 -0
  78. package/dist/chunks/cli-1.1.37-4cyg3kha.mjs +15 -0
  79. package/dist/chunks/cli-1.1.37-4s29t03n.mjs +2 -0
  80. package/dist/chunks/cli-1.1.37-519yanf4.mjs +2 -0
  81. package/dist/chunks/cli-1.1.37-51efrsrh.mjs +2 -0
  82. package/dist/chunks/cli-1.1.37-58pbecmv.mjs +2 -0
  83. package/dist/chunks/cli-1.1.37-5gj77q8j.mjs +2 -0
  84. package/dist/chunks/cli-1.1.37-5k40cazp.mjs +2 -0
  85. package/dist/chunks/cli-1.1.37-5ppknhpq.mjs +50 -0
  86. package/dist/chunks/cli-1.1.37-67ncf860.mjs +2 -0
  87. package/dist/chunks/cli-1.1.37-6defhmsy.mjs +2 -0
  88. package/dist/chunks/cli-1.1.37-6k9f1kb2.mjs +6 -0
  89. package/dist/chunks/cli-1.1.37-6pcx2j1q.mjs +2 -0
  90. package/dist/chunks/cli-1.1.37-72ezs6b8.mjs +2 -0
  91. package/dist/chunks/cli-1.1.37-7483gf56.mjs +3 -0
  92. package/dist/chunks/cli-1.1.37-7614bfhm.mjs +25 -0
  93. package/dist/chunks/cli-1.1.37-7f3hdq3p.mjs +2 -0
  94. package/dist/chunks/cli-1.1.37-7h3edez5.mjs +2 -0
  95. package/dist/chunks/cli-1.1.37-7prgb5qb.mjs +2 -0
  96. package/dist/chunks/cli-1.1.37-7qda9cmg.mjs +2 -0
  97. package/dist/chunks/cli-1.1.37-8n5vy3kh.mjs +2 -0
  98. package/dist/chunks/cli-1.1.37-8v3e4pnr.mjs +2 -0
  99. package/dist/chunks/cli-1.1.37-8wfxbqcm.mjs +20 -0
  100. package/dist/chunks/cli-1.1.37-944j3qt1.mjs +2 -0
  101. package/dist/chunks/cli-1.1.37-94bfnv5a.mjs +2 -0
  102. package/dist/chunks/cli-1.1.37-96sf5t1p.mjs +2 -0
  103. package/dist/chunks/cli-1.1.37-9x24mgyx.mjs +2 -0
  104. package/dist/chunks/cli-1.1.37-a3xp4gqs.mjs +3 -0
  105. package/dist/chunks/cli-1.1.37-a489vqjv.mjs +2 -0
  106. package/dist/chunks/cli-1.1.37-a5ddx2f0.mjs +2 -0
  107. package/dist/chunks/cli-1.1.37-a6pppj4k.mjs +2 -0
  108. package/dist/chunks/cli-1.1.37-a7jrq85d.mjs +2 -0
  109. package/dist/chunks/cli-1.1.37-ayhzfa69.mjs +2 -0
  110. package/dist/chunks/cli-1.1.37-ayqpwfm4.mjs +2 -0
  111. package/dist/chunks/cli-1.1.37-b26at90a.mjs +4 -0
  112. package/dist/chunks/cli-1.1.37-be0x6tdq.mjs +18 -0
  113. package/dist/chunks/cli-1.1.37-bkp0a6f1.mjs +2 -0
  114. package/dist/chunks/cli-1.1.37-cmbtcpwy.mjs +2 -0
  115. package/dist/chunks/cli-1.1.37-crpgw5qe.mjs +133 -0
  116. package/dist/chunks/cli-1.1.37-cw718qh8.mjs +42 -0
  117. package/dist/chunks/cli-1.1.37-d1fcgxg0.mjs +2 -0
  118. package/dist/chunks/cli-1.1.37-d23vxnm9.mjs +2 -0
  119. package/dist/chunks/cli-1.1.37-d6n91ex7.mjs +15 -0
  120. package/dist/chunks/cli-1.1.37-dj2tqhmt.mjs +2 -0
  121. package/dist/chunks/cli-1.1.37-dt1m5cht.mjs +2 -0
  122. package/dist/chunks/cli-1.1.37-ecm5tm4s.mjs +2 -0
  123. package/dist/chunks/cli-1.1.37-ekft3ygw.mjs +2 -0
  124. package/dist/chunks/cli-1.1.37-ev14s3y6.mjs +4 -0
  125. package/dist/chunks/cli-1.1.37-ex5tn3t8.mjs +6 -0
  126. package/dist/chunks/cli-1.1.37-f4cc288j.mjs +2 -0
  127. package/dist/chunks/cli-1.1.37-f7e57y66.mjs +2 -0
  128. package/dist/chunks/cli-1.1.37-f9mv7jky.mjs +2 -0
  129. package/dist/chunks/cli-1.1.37-fdkc3sf9.mjs +2 -0
  130. package/dist/chunks/cli-1.1.37-fksjv0et.mjs +2 -0
  131. package/dist/chunks/cli-1.1.37-fsjyvbbb.mjs +2 -0
  132. package/dist/chunks/cli-1.1.37-g7m905sy.mjs +3 -0
  133. package/dist/chunks/cli-1.1.37-g7xfccj8.mjs +2 -0
  134. package/dist/chunks/cli-1.1.37-g9d8qc79.mjs +2 -0
  135. package/dist/chunks/cli-1.1.37-gfbpxehy.mjs +2 -0
  136. package/dist/chunks/cli-1.1.37-gpk56nss.mjs +2 -0
  137. package/dist/chunks/cli-1.1.37-grsmntjy.mjs +5557 -0
  138. package/dist/chunks/cli-1.1.37-gswxz7xc.mjs +25 -0
  139. package/dist/chunks/cli-1.1.37-h0jx10pf.mjs +11 -0
  140. package/dist/chunks/cli-1.1.37-h4spe8tn.mjs +16 -0
  141. package/dist/chunks/cli-1.1.37-h7r11vsm.mjs +15 -0
  142. package/dist/chunks/cli-1.1.37-he99jbx1.mjs +2 -0
  143. package/dist/chunks/cli-1.1.37-hef24tpw.mjs +3 -0
  144. package/dist/chunks/cli-1.1.37-hgz1n58h.mjs +2 -0
  145. package/dist/chunks/cli-1.1.37-htprtn3s.mjs +2 -0
  146. package/dist/chunks/cli-1.1.37-hwan9xgw.mjs +2 -0
  147. package/dist/chunks/cli-1.1.37-j1vf4g9d.mjs +4 -0
  148. package/dist/chunks/cli-1.1.37-j6kremq2.mjs +2 -0
  149. package/dist/chunks/cli-1.1.37-jb5tx7mz.mjs +2 -0
  150. package/dist/chunks/cli-1.1.37-jbqk7r70.mjs +2 -0
  151. package/dist/chunks/cli-1.1.37-jfqs1fqm.mjs +2 -0
  152. package/dist/chunks/cli-1.1.37-jr1vseya.mjs +4 -0
  153. package/dist/chunks/cli-1.1.37-jr69vbpp.mjs +3 -0
  154. package/dist/chunks/cli-1.1.37-jv2bhmv9.mjs +2 -0
  155. package/dist/chunks/cli-1.1.37-jz75ctqt.mjs +4 -0
  156. package/dist/chunks/cli-1.1.37-kahw2epk.mjs +39 -0
  157. package/dist/chunks/cli-1.1.37-kb946f3c.mjs +2 -0
  158. package/dist/chunks/cli-1.1.37-kemsps6y.mjs +60 -0
  159. package/dist/chunks/cli-1.1.37-khfxdt5q.mjs +2 -0
  160. package/dist/chunks/cli-1.1.37-kn42c81a.mjs +3 -0
  161. package/dist/chunks/cli-1.1.37-kwaccfak.mjs +2 -0
  162. package/dist/chunks/cli-1.1.37-m1fep5be.mjs +2 -0
  163. package/dist/chunks/cli-1.1.37-m456xrwv.mjs +2 -0
  164. package/dist/chunks/cli-1.1.37-m5yt8y0j.mjs +2 -0
  165. package/dist/chunks/cli-1.1.37-m6gntr6v.mjs +2 -0
  166. package/dist/chunks/cli-1.1.37-ma9krcyk.mjs +2 -0
  167. package/dist/chunks/cli-1.1.37-mexv9k9t.mjs +2 -0
  168. package/dist/chunks/cli-1.1.37-mf2q6gmp.mjs +2 -0
  169. package/dist/chunks/cli-1.1.37-mqc9bwxe.mjs +2 -0
  170. package/dist/chunks/cli-1.1.37-mrvnfwyz.mjs +2 -0
  171. package/dist/chunks/cli-1.1.37-mw2jz1zw.mjs +7 -0
  172. package/dist/chunks/cli-1.1.37-n183zk9b.mjs +24 -0
  173. package/dist/chunks/cli-1.1.37-n5rtec8d.mjs +2 -0
  174. package/dist/chunks/cli-1.1.37-n96tca8q.mjs +2 -0
  175. package/dist/chunks/cli-1.1.37-ncfrm58b.mjs +2 -0
  176. package/dist/chunks/cli-1.1.37-nhcj6483.mjs +2 -0
  177. package/dist/chunks/cli-1.1.37-nmaxyg7j.mjs +2 -0
  178. package/dist/chunks/cli-1.1.37-nzbxb3mg.mjs +2 -0
  179. package/dist/chunks/cli-1.1.37-p6s3mz30.mjs +9 -0
  180. package/dist/chunks/cli-1.1.37-pek0pwba.mjs +2 -0
  181. package/dist/chunks/cli-1.1.37-ptf1j7na.mjs +2 -0
  182. package/dist/chunks/cli-1.1.37-pvh445g5.mjs +3 -0
  183. package/dist/chunks/cli-1.1.37-pw36zafa.mjs +2 -0
  184. package/dist/chunks/cli-1.1.37-q1053cc2.mjs +17 -0
  185. package/dist/chunks/cli-1.1.37-qcn1j79h.mjs +2 -0
  186. package/dist/chunks/cli-1.1.37-qq29akkh.mjs +2 -0
  187. package/dist/chunks/cli-1.1.37-qx20qhv7.mjs +2 -0
  188. package/dist/chunks/cli-1.1.37-rdmqbzqh.mjs +2 -0
  189. package/dist/chunks/cli-1.1.37-rwsh9ddm.mjs +3 -0
  190. package/dist/chunks/cli-1.1.37-ryrmx9mz.mjs +10 -0
  191. package/dist/chunks/cli-1.1.37-s09fpmwg.mjs +2 -0
  192. package/dist/chunks/cli-1.1.37-s66bx6wx.mjs +24 -0
  193. package/dist/chunks/cli-1.1.37-sf9mv58v.mjs +10 -0
  194. package/dist/chunks/cli-1.1.37-sm7wj6sf.mjs +4 -0
  195. package/dist/chunks/cli-1.1.37-sqyyjrzq.mjs +5 -0
  196. package/dist/chunks/cli-1.1.37-ss1k0v1c.mjs +2 -0
  197. package/dist/chunks/cli-1.1.37-ssstmvw3.mjs +3 -0
  198. package/dist/chunks/cli-1.1.37-sxzqtyda.mjs +2 -0
  199. package/dist/chunks/cli-1.1.37-syfanvjj.mjs +2 -0
  200. package/dist/chunks/cli-1.1.37-sygz2s62.mjs +2 -0
  201. package/dist/chunks/cli-1.1.37-tb7ktts9.mjs +2 -0
  202. package/dist/chunks/cli-1.1.37-tkdarzaz.mjs +2 -0
  203. package/dist/chunks/cli-1.1.37-tntw41wr.mjs +2 -0
  204. package/dist/chunks/cli-1.1.37-tqgcfdy1.mjs +2 -0
  205. package/dist/chunks/cli-1.1.37-v43zxjn1.mjs +2 -0
  206. package/dist/chunks/cli-1.1.37-v7ra9bdg.mjs +10 -0
  207. package/dist/chunks/cli-1.1.37-v901k2xy.mjs +2 -0
  208. package/dist/chunks/cli-1.1.37-v90enr9t.mjs +2 -0
  209. package/dist/chunks/cli-1.1.37-vfcg5s15.mjs +2 -0
  210. package/dist/chunks/cli-1.1.37-vg7rr3sv.mjs +2 -0
  211. package/dist/chunks/cli-1.1.37-vhmf8afh.mjs +2 -0
  212. package/dist/chunks/cli-1.1.37-vhmsvame.mjs +2 -0
  213. package/dist/chunks/cli-1.1.37-vrdgh1e0.mjs +2 -0
  214. package/dist/chunks/cli-1.1.37-w0tvj01c.mjs +2 -0
  215. package/dist/chunks/cli-1.1.37-wm28b2wb.mjs +2 -0
  216. package/dist/chunks/cli-1.1.37-wv9phckk.mjs +9 -0
  217. package/dist/chunks/cli-1.1.37-x03y4qkg.mjs +2 -0
  218. package/dist/chunks/cli-1.1.37-x0nz472y.mjs +2 -0
  219. package/dist/chunks/cli-1.1.37-x27pf2df.mjs +2 -0
  220. package/dist/chunks/cli-1.1.37-x363x6yv.mjs +12 -0
  221. package/dist/chunks/cli-1.1.37-xqs4w5xj.mjs +2 -0
  222. package/dist/chunks/cli-1.1.37-xxa2yvvm.mjs +2 -0
  223. package/dist/chunks/cli-1.1.37-y101rdsg.mjs +2 -0
  224. package/dist/chunks/cli-1.1.37-y2c4zsfh.mjs +6 -0
  225. package/dist/chunks/cli-1.1.37-y3knvtaz.mjs +2 -0
  226. package/dist/chunks/cli-1.1.37-ye5hkqff.mjs +2 -0
  227. package/dist/chunks/cli-1.1.37-yx7j10g7.mjs +2 -0
  228. package/dist/chunks/cli-1.1.37-z0tedaby.mjs +2 -0
  229. package/dist/chunks/cli-1.1.37-z414tkgs.mjs +2 -0
  230. package/dist/chunks/cli-1.1.37-z4wav0zf.mjs +251 -0
  231. package/dist/chunks/cli-1.1.37-z6pkdynf.mjs +2 -0
  232. package/dist/chunks/cli-1.1.37-z9fbkmx6.mjs +2 -0
  233. package/dist/chunks/cli-1.1.37-zb319x4t.mjs +21 -0
  234. package/dist/chunks/cli-1.1.37-zdpyj00a.mjs +2 -0
  235. package/dist/chunks/cli-1.1.37-zmvkkbkz.mjs +2 -0
  236. package/dist/chunks/cli-1.1.37-zp02yw3a.mjs +7 -0
  237. package/dist/chunks/cli-1.1.37-zv5qmddr.mjs +2 -0
  238. package/dist/chunks/cli-1.1.37-zyh3q51q.mjs +2 -0
  239. package/dist/chunks/client-1.1.37-xgmkbazy.mjs +1 -0
  240. package/dist/chunks/color-1.1.37-y730edtg.mjs +1 -0
  241. package/dist/chunks/compact-1.1.37-w4h4spv3.mjs +2 -0
  242. package/dist/chunks/config-1.1.37-kw2by168.mjs +1 -0
  243. package/dist/chunks/config-1.1.37-nxkma2y7.mjs +1 -0
  244. package/dist/chunks/constants-1.1.37-ctp81rsa.mjs +1 -0
  245. package/dist/chunks/context-1.1.37-ayxgyhvf.mjs +1 -0
  246. package/dist/chunks/context-noninteractive-1.1.37-9fnpakkn.mjs +1 -0
  247. package/dist/chunks/conversation-1.1.37-c5qptech.mjs +1 -0
  248. package/dist/chunks/copilotHeaders-1.1.37-2jh9xkzj.mjs +1 -0
  249. package/dist/chunks/copy-1.1.37-3x6yh3re.mjs +9 -0
  250. package/dist/chunks/cost-1.1.37-k4egf2cb.mjs +1 -0
  251. package/dist/chunks/createSession-1.1.37-ps0330f5.mjs +1 -0
  252. package/dist/chunks/debug-1.1.37-rg6428fc.mjs +1 -0
  253. package/dist/chunks/defaultActionDeps-1.1.37-0p69kpbf.mjs +1458 -0
  254. package/dist/chunks/desktop-1.1.37-vw4rzhtp.mjs +2 -0
  255. package/dist/chunks/detectRepository-1.1.37-de5st3z1.mjs +1 -0
  256. package/dist/chunks/detection-1.1.37-2ah57ykf.mjs +1 -0
  257. package/dist/chunks/diff-1.1.37-h35ry5bf.mjs +1 -0
  258. package/dist/chunks/doctor-1.1.37-4sdv75rj.mjs +1 -0
  259. package/dist/chunks/doctorDiagnostic-1.1.37-aj2q1yxr.mjs +1 -0
  260. package/dist/chunks/earlyInput-1.1.37-f1bz41ba.mjs +1 -0
  261. package/dist/chunks/effort-1.1.37-qme7s71h.mjs +13 -0
  262. package/dist/chunks/engine-1.1.37-vhnerrj8.mjs +1 -0
  263. package/dist/chunks/envUtils-1.1.37-jmnztajb.mjs +1 -0
  264. package/dist/chunks/errors-1.1.37-gx18q68s.mjs +1 -0
  265. package/dist/chunks/exampleCommands-1.1.37-jeewe5zp.mjs +1 -0
  266. package/dist/chunks/execFileNoThrow-1.1.37-9znv87jk.mjs +1 -0
  267. package/dist/chunks/exit-1.1.37-g21nsxb0.mjs +1 -0
  268. package/dist/chunks/explorer-1.1.37-x26rvwxm.mjs +1 -0
  269. package/dist/chunks/export-1.1.37-f9367qzp.mjs +2 -0
  270. package/dist/chunks/fast-1.1.37-66kcejyq.mjs +1 -0
  271. package/dist/chunks/feedback-1.1.37-cmzfc89p.mjs +16 -0
  272. package/dist/chunks/git-1.1.37-2v8rmfsp.mjs +1 -0
  273. package/dist/chunks/githubModelsCredentials-1.1.37-qa9ahy75.mjs +1 -0
  274. package/dist/chunks/goal-1.1.37-qxqx92gp.mjs +4 -0
  275. package/dist/chunks/headless-1.1.37-dkg8aqth.mjs +2 -0
  276. package/dist/chunks/heapdump-1.1.37-4hzv26jg.mjs +6 -0
  277. package/dist/chunks/help-1.1.37-94a27s9t.mjs +1 -0
  278. package/dist/chunks/hooks-1.1.37-ekx4v46c.mjs +79 -0
  279. package/dist/chunks/hooks-1.1.37-yeewd50h.mjs +1 -0
  280. package/dist/chunks/ide-1.1.37-knedgvva.mjs +3 -0
  281. package/dist/chunks/image-processor-napi-1.1.37-cdpery4t.mjs +1 -0
  282. package/dist/chunks/import-1.1.37-e6j4yen6.mjs +261 -0
  283. package/dist/chunks/inboundAttachments-1.1.37-jjm28zc3.mjs +1 -0
  284. package/dist/chunks/index-1.1.37-21b053j0.mjs +1 -0
  285. package/dist/chunks/index-1.1.37-3v1qr5g5.mjs +9 -0
  286. package/dist/chunks/index-1.1.37-5jd6yv91.mjs +1 -0
  287. package/dist/chunks/index-1.1.37-5m0x7mgr.mjs +2 -0
  288. package/dist/chunks/index-1.1.37-7p4s9e93.mjs +5 -0
  289. package/dist/chunks/index-1.1.37-8d8wz2jd.mjs +1 -0
  290. package/dist/chunks/index-1.1.37-8nj0y31t.mjs +1 -0
  291. package/dist/chunks/index-1.1.37-9mdrpppp.mjs +1 -0
  292. package/dist/chunks/index-1.1.37-fsrw22yr.mjs +1 -0
  293. package/dist/chunks/index-1.1.37-gbkrjwx2.mjs +1 -0
  294. package/dist/chunks/index-1.1.37-j22mymj3.mjs +1 -0
  295. package/dist/chunks/index-1.1.37-j7mg2v2z.mjs +1 -0
  296. package/dist/chunks/index-1.1.37-jt0qvhqx.mjs +9 -0
  297. package/dist/chunks/index-1.1.37-kqbx8bd4.mjs +1 -0
  298. package/dist/chunks/index-1.1.37-md3nqn7b.mjs +1 -0
  299. package/dist/chunks/index-1.1.37-nvrt1jkm.mjs +1 -0
  300. package/dist/chunks/index-1.1.37-qs532q75.mjs +2 -0
  301. package/dist/chunks/index-1.1.37-vrf2sks4.mjs +1 -0
  302. package/dist/chunks/index-1.1.37-w2vtqz1f.mjs +30 -0
  303. package/dist/chunks/index-1.1.37-wtf428dj.mjs +1 -0
  304. package/dist/chunks/index-1.1.37-x3qnjdnj.mjs +23 -0
  305. package/dist/chunks/index-1.1.37-xvds1tk7.mjs +1 -0
  306. package/dist/chunks/index-1.1.37-ycghwm8a.mjs +1 -0
  307. package/dist/chunks/init-1.1.37-rej95xjh.mjs +2 -0
  308. package/dist/chunks/initReplBridge-1.1.37-fg8xhcbg.mjs +1 -0
  309. package/dist/chunks/ink-1.1.37-9hasxe0p.mjs +1 -0
  310. package/dist/chunks/insights-1.1.37-t8pdcny6.mjs +870 -0
  311. package/dist/chunks/install-1.1.37-3qw7jywz.mjs +1 -0
  312. package/dist/chunks/install-github-app-1.1.37-xxm8pfc7.mjs +149 -0
  313. package/dist/chunks/install-slack-app-1.1.37-k2gvh481.mjs +1 -0
  314. package/dist/chunks/interactiveHelpers-1.1.37-65a5va0g.mjs +1 -0
  315. package/dist/chunks/latestVersionCache-1.1.37-3a47ekt3.mjs +1 -0
  316. package/dist/chunks/loadAgentsDir-1.1.37-tacjzkxh.mjs +1 -0
  317. package/dist/chunks/loadPluginHooks-1.1.37-xp0k0sev.mjs +1 -0
  318. package/dist/chunks/log-1.1.37-zxjr2p0h.mjs +1 -0
  319. package/dist/chunks/main-1.1.37-z5knsc2c.mjs +1 -0
  320. package/dist/chunks/managedEnv-1.1.37-v6d9x7gc.mjs +1 -0
  321. package/dist/chunks/mcp-1.1.37-2f8vksgy.mjs +1 -0
  322. package/dist/chunks/mcp-1.1.37-t42e1h6v.mjs +17 -0
  323. package/dist/chunks/mcp-1.1.37-z5yx7ce8.mjs +4 -0
  324. package/dist/chunks/mcpb-1.1.37-nxn1ew24.mjs +1 -0
  325. package/dist/chunks/memory-1.1.37-e17frzj2.mjs +128 -0
  326. package/dist/chunks/model-1.1.37-415ebhh8.mjs +2 -0
  327. package/dist/chunks/model-1.1.37-51zfsc21.mjs +1 -0
  328. package/dist/chunks/new-1.1.37-qmpxmvhh.mjs +1 -0
  329. package/dist/chunks/node-1.1.37-60r1zc7a.mjs +1 -0
  330. package/dist/chunks/node-1.1.37-bzzjhz9b.mjs +15 -0
  331. package/dist/chunks/oauth-1.1.37-an1mr5z0.mjs +1 -0
  332. package/dist/chunks/openaiShim-1.1.37-d7tbje1m.mjs +14 -0
  333. package/dist/chunks/output-style-1.1.37-ky7bh1p8.mjs +1 -0
  334. package/dist/chunks/package-F6O7J2XI-1.1.37-cpdvge3d.mjs +1 -0
  335. package/dist/chunks/permissions-1.1.37-jfdwfjhx.mjs +1 -0
  336. package/dist/chunks/permissions-1.1.37-xa1rr619.mjs +3 -0
  337. package/dist/chunks/plan-1.1.37-mkad4kke.mjs +1 -0
  338. package/dist/chunks/plist-1.1.37-jp82073r.mjs +1 -0
  339. package/dist/chunks/plugin-1.1.37-4y7stngn.mjs +29 -0
  340. package/dist/chunks/pluginStartupCheck-1.1.37-mb876t1m.mjs +1 -0
  341. package/dist/chunks/plugins-1.1.37-vgwj76jr.mjs +9 -0
  342. package/dist/chunks/preActionHook-1.1.37-y5x9wxpb.mjs +2 -0
  343. package/dist/chunks/print-1.1.37-39471kxm.mjs +57 -0
  344. package/dist/chunks/process-1.1.37-0sxw7yj7.mjs +1 -0
  345. package/dist/chunks/processBashCommand-1.1.37-3a9hjw0c.mjs +1 -0
  346. package/dist/chunks/processSlashCommand-1.1.37-qkdzw4bn.mjs +9 -0
  347. package/dist/chunks/prompt-1.1.37-7ty4xbzv.mjs +1 -0
  348. package/dist/chunks/prompt-1.1.37-t1pkc4hm.mjs +1 -0
  349. package/dist/chunks/prompts-1.1.37-vc8tkqtx.mjs +1 -0
  350. package/dist/chunks/provider-1.1.37-d5ky3fex.mjs +2 -0
  351. package/dist/chunks/providerProfiles-1.1.37-qds9eqzt.mjs +1 -0
  352. package/dist/chunks/providerValidation-1.1.37-njz9qc5m.mjs +6 -0
  353. package/dist/chunks/registerSubcommands-1.1.37-mh25jf7y.mjs +26 -0
  354. package/dist/chunks/registry-1.1.37-j99mgf8f.mjs +1 -0
  355. package/dist/chunks/release-notes-1.1.37-9gkg8tfr.mjs +5 -0
  356. package/dist/chunks/reload-plugins-1.1.37-4sptja72.mjs +2 -0
  357. package/dist/chunks/remote-env-1.1.37-t2zt0dx6.mjs +1 -0
  358. package/dist/chunks/rename-1.1.37-r3rf1zcp.mjs +1 -0
  359. package/dist/chunks/replLauncher-1.1.37-q72zpdec.mjs +1 -0
  360. package/dist/chunks/resume-1.1.37-7y7v8kjq.mjs +2 -0
  361. package/dist/chunks/rewind-1.1.37-g7g9fq2x.mjs +1 -0
  362. package/dist/chunks/rootOptions-1.1.37-gab9zhq2.mjs +1 -0
  363. package/dist/chunks/runWorkflowHeadless-1.1.37-hfkacx24.mjs +10 -0
  364. package/dist/chunks/sandbox-adapter-1.1.37-0z182pcd.mjs +1 -0
  365. package/dist/chunks/sandbox-toggle-1.1.37-qpef07xe.mjs +1 -0
  366. package/dist/chunks/session-1.1.37-23e3vg40.mjs +2 -0
  367. package/dist/chunks/sessionStorage-1.1.37-80sj7d1y.mjs +1 -0
  368. package/dist/chunks/settings-1.1.37-9ydtb00s.mjs +1 -0
  369. package/dist/chunks/setup-1.1.37-zw16kqhk.mjs +12 -0
  370. package/dist/chunks/sinks-1.1.37-zfyvj9zb.mjs +1 -0
  371. package/dist/chunks/skills-1.1.37-k5m03dxr.mjs +1 -0
  372. package/dist/chunks/startupProfiler-1.1.37-c215kgmn.mjs +1 -0
  373. package/dist/chunks/startupUpdateCheck-1.1.37-gkvkp8j3.mjs +1 -0
  374. package/dist/chunks/state-1.1.37-n5ptmgvs.mjs +1 -0
  375. package/dist/chunks/stats-1.1.37-aa4vr5s9.mjs +1 -0
  376. package/dist/chunks/status-1.1.37-ay3wwhz4.mjs +1 -0
  377. package/dist/chunks/stickers-1.1.37-9s6a0we7.mjs +1 -0
  378. package/dist/chunks/subprocessEnv-1.1.37-j60ejzj9.mjs +1 -0
  379. package/dist/chunks/tasks-1.1.37-0kkyatcs.mjs +1 -0
  380. package/dist/chunks/teamHelpers-1.1.37-bh946f2s.mjs +1 -0
  381. package/dist/chunks/teammateModeSnapshot-1.1.37-hvr3p8hm.mjs +1 -0
  382. package/dist/chunks/teleport-1.1.37-r8pztaf5.mjs +1 -0
  383. package/dist/chunks/terminalSetup-1.1.37-db8a6fsx.mjs +1 -0
  384. package/dist/chunks/theme-1.1.37-syjd1g1y.mjs +1 -0
  385. package/dist/chunks/toolPool-1.1.37-99ckwfft.mjs +1 -0
  386. package/dist/chunks/toolSearch-1.1.37-w702g2e2.mjs +1 -0
  387. package/dist/chunks/tools-1.1.37-q0g8gdy1.mjs +1 -0
  388. package/dist/chunks/turndown.cjs-1.1.37-p3av7xdw.mjs +69 -0
  389. package/dist/chunks/types-1.1.37-0zw1rq84.mjs +1 -0
  390. package/dist/chunks/update-1.1.37-njeg6bcd.mjs +72 -0
  391. package/dist/chunks/upload-1.1.37-gzm0qpn7.mjs +7 -0
  392. package/dist/chunks/upstreamproxy-1.1.37-v8bpt97q.mjs +14 -0
  393. package/dist/chunks/usage-1.1.37-b2a8dppj.mjs +1 -0
  394. package/dist/chunks/util-1.1.37-psbfj1x5.mjs +1 -0
  395. package/dist/chunks/utils-1.1.37-efqgjtyn.mjs +1 -0
  396. package/dist/chunks/vim-1.1.37-3vwhey1j.mjs +1 -0
  397. package/dist/chunks/watchLoop-1.1.37-hmgj516c.mjs +13 -0
  398. package/dist/chunks/wiki-1.1.37-y24wnewk.mjs +132 -0
  399. package/dist/chunks/workflows-1.1.37-eywdbk9a.mjs +1 -0
  400. package/dist/chunks/worktree-1.1.37-k9y7x7fq.mjs +1 -0
  401. package/dist/chunks/worktreeModeEnabled-1.1.37-bq8bmkt7.mjs +1 -0
  402. package/dist/chunks/wrapper-1.1.37-mam70w68.mjs +7 -0
  403. package/dist/cli.mjs +2 -2
  404. package/package.json +9 -9
  405. package/dist/chunks/App-1.1.35-r3nj6jfs.mjs +0 -1
  406. package/dist/chunks/ApproveApiKey-1.1.35-8nvhxyw9.mjs +0 -1
  407. package/dist/chunks/AutoModeOptInDialog-1.1.35-1ywwnh39.mjs +0 -1
  408. package/dist/chunks/BypassPermissionsModeDialog-1.1.35-bvk75rww.mjs +0 -1
  409. package/dist/chunks/ClaudeMdExternalIncludesDialog-1.1.35-1ct3fw8c.mjs +0 -1
  410. package/dist/chunks/ConsoleOAuthFlow-1.1.35-nt22bzb6.mjs +0 -1
  411. package/dist/chunks/DiffDialog-1.1.35-98xrgmtc.mjs +0 -6
  412. package/dist/chunks/Doctor-1.1.35-k34y3jy9.mjs +0 -1
  413. package/dist/chunks/ExplorerDialog-1.1.35-nan1wyke.mjs +0 -6
  414. package/dist/chunks/ITermBackend-1.1.35-kt3ng0j6.mjs +0 -1
  415. package/dist/chunks/InvalidConfigDialog-1.1.35-k7wnc3v8.mjs +0 -1
  416. package/dist/chunks/InvalidSettingsDialog-1.1.35-3dp4jb6e.mjs +0 -1
  417. package/dist/chunks/MigrationDialog-1.1.35-6pa67bzn.mjs +0 -1
  418. package/dist/chunks/Onboarding-1.1.35-4sje6bjv.mjs +0 -1
  419. package/dist/chunks/ProviderManager-1.1.35-99y8t1j9.mjs +0 -1
  420. package/dist/chunks/REPL-1.1.35-0vqh1ns0.mjs +0 -1
  421. package/dist/chunks/ResumeConversation-1.1.35-104fszyr.mjs +0 -1
  422. package/dist/chunks/TeleportProgress-1.1.35-xcz2dypc.mjs +0 -1
  423. package/dist/chunks/TeleportRepoMismatchDialog-1.1.35-nfckw5cx.mjs +0 -1
  424. package/dist/chunks/TeleportResumeWrapper-1.1.35-6528ybrk.mjs +0 -1
  425. package/dist/chunks/TmuxBackend-1.1.35-rqncjk99.mjs +0 -9
  426. package/dist/chunks/ToolSearchTool-1.1.35-0t2d7g7n.mjs +0 -1
  427. package/dist/chunks/TrustDialog-1.1.35-j9d3asbg.mjs +0 -1
  428. package/dist/chunks/activeProvider-1.1.35-fkjy6sz1.mjs +0 -1
  429. package/dist/chunks/add-dir-1.1.35-4gh89hh4.mjs +0 -1
  430. package/dist/chunks/agentTypes-1.1.35-nx5q66t5.mjs +0 -1
  431. package/dist/chunks/agents-1.1.35-0kyfdt7w.mjs +0 -3
  432. package/dist/chunks/agents-1.1.35-1vzstv4y.mjs +0 -110
  433. package/dist/chunks/api-1.1.35-ab0j2x7t.mjs +0 -1
  434. package/dist/chunks/asciicast-1.1.35-xgjp2wrs.mjs +0 -1
  435. package/dist/chunks/auth-1.1.35-2fpa9v9f.mjs +0 -1
  436. package/dist/chunks/auth-1.1.35-deksnwe8.mjs +0 -1
  437. package/dist/chunks/autoMode-1.1.35-8d2qr79q.mjs +0 -52
  438. package/dist/chunks/autoModeSetup-1.1.35-hg5dxv1t.mjs +0 -44
  439. package/dist/chunks/autoUpdater-1.1.35-5pzsrenf.mjs +0 -1
  440. package/dist/chunks/backgroundHousekeeping-1.1.35-2kythx4m.mjs +0 -1
  441. package/dist/chunks/branch-1.1.35-tmksh596.mjs +0 -4
  442. package/dist/chunks/bridge-1.1.35-0za41yjp.mjs +0 -2
  443. package/dist/chunks/bridgeConfig-1.1.35-qtvayvc3.mjs +0 -1
  444. package/dist/chunks/bridgeEnabled-1.1.35-3mhemdrx.mjs +0 -1
  445. package/dist/chunks/bridgeMain-1.1.35-7awverkv.mjs +0 -88
  446. package/dist/chunks/bridgePointer-1.1.35-5gpfg6h4.mjs +0 -1
  447. package/dist/chunks/btw-1.1.35-6hy8wabr.mjs +0 -1
  448. package/dist/chunks/buddy-1.1.35-8z3tb1ne.mjs +0 -3
  449. package/dist/chunks/cache-probe-1.1.35-adn6dpak.mjs +0 -21
  450. package/dist/chunks/cacheStats-1.1.35-z3268gay.mjs +0 -4
  451. package/dist/chunks/caches-1.1.35-1qqfgvsm.mjs +0 -1
  452. package/dist/chunks/cd-1.1.35-vqy7n0x0.mjs +0 -3
  453. package/dist/chunks/claudeDesktop-1.1.35-enw3hpss.mjs +0 -1
  454. package/dist/chunks/claudemd-1.1.35-wsav3shz.mjs +0 -1
  455. package/dist/chunks/clear-1.1.35-21ry6n0m.mjs +0 -1
  456. package/dist/chunks/clearTerminal-1.1.35-sg808cbp.mjs +0 -1
  457. package/dist/chunks/cli-1.1.35-02qx9a8j.mjs +0 -2
  458. package/dist/chunks/cli-1.1.35-0axe3ev5.mjs +0 -2
  459. package/dist/chunks/cli-1.1.35-0feday40.mjs +0 -20
  460. package/dist/chunks/cli-1.1.35-0p69hr1j.mjs +0 -2
  461. package/dist/chunks/cli-1.1.35-0qrw70p1.mjs +0 -2
  462. package/dist/chunks/cli-1.1.35-0tc3wmtp.mjs +0 -5
  463. package/dist/chunks/cli-1.1.35-0vpxr2rk.mjs +0 -2
  464. package/dist/chunks/cli-1.1.35-0zkzg6at.mjs +0 -2
  465. package/dist/chunks/cli-1.1.35-1618y169.mjs +0 -2
  466. package/dist/chunks/cli-1.1.35-18wszrez.mjs +0 -15
  467. package/dist/chunks/cli-1.1.35-1bzyzrvt.mjs +0 -2
  468. package/dist/chunks/cli-1.1.35-1ceb2tjb.mjs +0 -2
  469. package/dist/chunks/cli-1.1.35-1gae8a5m.mjs +0 -2
  470. package/dist/chunks/cli-1.1.35-1x2wb524.mjs +0 -2
  471. package/dist/chunks/cli-1.1.35-21w0bna1.mjs +0 -2
  472. package/dist/chunks/cli-1.1.35-22q1jqqq.mjs +0 -2
  473. package/dist/chunks/cli-1.1.35-2gxxpyvc.mjs +0 -2
  474. package/dist/chunks/cli-1.1.35-2sm1x5n8.mjs +0 -2
  475. package/dist/chunks/cli-1.1.35-2x0m7ewe.mjs +0 -9
  476. package/dist/chunks/cli-1.1.35-34h7nfzz.mjs +0 -11
  477. package/dist/chunks/cli-1.1.35-389ej7r1.mjs +0 -2
  478. package/dist/chunks/cli-1.1.35-38s8y5cf.mjs +0 -2
  479. package/dist/chunks/cli-1.1.35-3keqk8xr.mjs +0 -2
  480. package/dist/chunks/cli-1.1.35-3zrjqd93.mjs +0 -2
  481. package/dist/chunks/cli-1.1.35-41srzc8c.mjs +0 -2
  482. package/dist/chunks/cli-1.1.35-46bm9f8q.mjs +0 -2
  483. package/dist/chunks/cli-1.1.35-4d0cm3mc.mjs +0 -2
  484. package/dist/chunks/cli-1.1.35-4d9merys.mjs +0 -2
  485. package/dist/chunks/cli-1.1.35-4g77zek0.mjs +0 -24
  486. package/dist/chunks/cli-1.1.35-4kft2wxe.mjs +0 -2
  487. package/dist/chunks/cli-1.1.35-4njf7z42.mjs +0 -2
  488. package/dist/chunks/cli-1.1.35-4typvdqe.mjs +0 -2
  489. package/dist/chunks/cli-1.1.35-589b1qht.mjs +0 -2
  490. package/dist/chunks/cli-1.1.35-5b39mwe0.mjs +0 -2
  491. package/dist/chunks/cli-1.1.35-5j12hjjm.mjs +0 -2
  492. package/dist/chunks/cli-1.1.35-5v115fee.mjs +0 -2
  493. package/dist/chunks/cli-1.1.35-61gmwbbt.mjs +0 -2
  494. package/dist/chunks/cli-1.1.35-688xsqg8.mjs +0 -2
  495. package/dist/chunks/cli-1.1.35-6c4v5dpe.mjs +0 -15
  496. package/dist/chunks/cli-1.1.35-6nhv8vhv.mjs +0 -2
  497. package/dist/chunks/cli-1.1.35-6p10e278.mjs +0 -2
  498. package/dist/chunks/cli-1.1.35-7g4yw92j.mjs +0 -2
  499. package/dist/chunks/cli-1.1.35-7hfdc6xn.mjs +0 -2
  500. package/dist/chunks/cli-1.1.35-7mxbj45y.mjs +0 -2
  501. package/dist/chunks/cli-1.1.35-7mz6cnfb.mjs +0 -6
  502. package/dist/chunks/cli-1.1.35-7nsr0a6p.mjs +0 -2
  503. package/dist/chunks/cli-1.1.35-7p1685r1.mjs +0 -2
  504. package/dist/chunks/cli-1.1.35-7tt5b2wx.mjs +0 -2
  505. package/dist/chunks/cli-1.1.35-7y74em05.mjs +0 -2
  506. package/dist/chunks/cli-1.1.35-82ak1wpt.mjs +0 -7
  507. package/dist/chunks/cli-1.1.35-854kyr9a.mjs +0 -3
  508. package/dist/chunks/cli-1.1.35-85zb0hfp.mjs +0 -2
  509. package/dist/chunks/cli-1.1.35-873xb9w7.mjs +0 -2
  510. package/dist/chunks/cli-1.1.35-8b1qqrev.mjs +0 -135
  511. package/dist/chunks/cli-1.1.35-8d9f31xx.mjs +0 -2
  512. package/dist/chunks/cli-1.1.35-8qdvqjz3.mjs +0 -2
  513. package/dist/chunks/cli-1.1.35-8ttx7y70.mjs +0 -2
  514. package/dist/chunks/cli-1.1.35-959df5vk.mjs +0 -2
  515. package/dist/chunks/cli-1.1.35-9817kkw4.mjs +0 -3
  516. package/dist/chunks/cli-1.1.35-9dkpx812.mjs +0 -2
  517. package/dist/chunks/cli-1.1.35-9tnc0a3x.mjs +0 -2
  518. package/dist/chunks/cli-1.1.35-9z4kwrpr.mjs +0 -6
  519. package/dist/chunks/cli-1.1.35-a7ygtwdr.mjs +0 -5
  520. package/dist/chunks/cli-1.1.35-a8677mcz.mjs +0 -2
  521. package/dist/chunks/cli-1.1.35-a9y8qxsj.mjs +0 -6
  522. package/dist/chunks/cli-1.1.35-an20pj6q.mjs +0 -2
  523. package/dist/chunks/cli-1.1.35-arj7fm1n.mjs +0 -2
  524. package/dist/chunks/cli-1.1.35-b0n88pf7.mjs +0 -2
  525. package/dist/chunks/cli-1.1.35-bbq4frhw.mjs +0 -2
  526. package/dist/chunks/cli-1.1.35-bhmad6rp.mjs +0 -3
  527. package/dist/chunks/cli-1.1.35-bka68014.mjs +0 -2
  528. package/dist/chunks/cli-1.1.35-bq7wadxz.mjs +0 -2
  529. package/dist/chunks/cli-1.1.35-c05841mj.mjs +0 -2
  530. package/dist/chunks/cli-1.1.35-c3vqfrj0.mjs +0 -45
  531. package/dist/chunks/cli-1.1.35-c4thx500.mjs +0 -26
  532. package/dist/chunks/cli-1.1.35-cj42e7aq.mjs +0 -24
  533. package/dist/chunks/cli-1.1.35-cjdzbmst.mjs +0 -2
  534. package/dist/chunks/cli-1.1.35-cjsf2kh3.mjs +0 -2
  535. package/dist/chunks/cli-1.1.35-cm0anghq.mjs +0 -2
  536. package/dist/chunks/cli-1.1.35-cp6wwahj.mjs +0 -4
  537. package/dist/chunks/cli-1.1.35-d6kd2zv5.mjs +0 -2
  538. package/dist/chunks/cli-1.1.35-d7n85zf2.mjs +0 -2
  539. package/dist/chunks/cli-1.1.35-da72zgbs.mjs +0 -50
  540. package/dist/chunks/cli-1.1.35-dfcj4fkz.mjs +0 -2
  541. package/dist/chunks/cli-1.1.35-dk4f6kgr.mjs +0 -2
  542. package/dist/chunks/cli-1.1.35-dnacc640.mjs +0 -252
  543. package/dist/chunks/cli-1.1.35-dw3fv0g8.mjs +0 -60
  544. package/dist/chunks/cli-1.1.35-dwaz1jv4.mjs +0 -2
  545. package/dist/chunks/cli-1.1.35-e08b8j98.mjs +0 -18
  546. package/dist/chunks/cli-1.1.35-eqcgyqke.mjs +0 -39
  547. package/dist/chunks/cli-1.1.35-ewtk80cp.mjs +0 -3
  548. package/dist/chunks/cli-1.1.35-f6sa351s.mjs +0 -5
  549. package/dist/chunks/cli-1.1.35-f8jgxvev.mjs +0 -2
  550. package/dist/chunks/cli-1.1.35-fgkpe9g9.mjs +0 -2
  551. package/dist/chunks/cli-1.1.35-fjtf9x1v.mjs +0 -2
  552. package/dist/chunks/cli-1.1.35-fr8gap0y.mjs +0 -2
  553. package/dist/chunks/cli-1.1.35-ftvtbdm6.mjs +0 -4
  554. package/dist/chunks/cli-1.1.35-fwyc7v71.mjs +0 -7
  555. package/dist/chunks/cli-1.1.35-fz50q22a.mjs +0 -2
  556. package/dist/chunks/cli-1.1.35-g2vg6fw2.mjs +0 -2
  557. package/dist/chunks/cli-1.1.35-g7086zkj.mjs +0 -2
  558. package/dist/chunks/cli-1.1.35-g74y15na.mjs +0 -2
  559. package/dist/chunks/cli-1.1.35-gcjyc9x3.mjs +0 -2
  560. package/dist/chunks/cli-1.1.35-gr966v4t.mjs +0 -2
  561. package/dist/chunks/cli-1.1.35-h06ng57d.mjs +0 -2
  562. package/dist/chunks/cli-1.1.35-h262sgvd.mjs +0 -4
  563. package/dist/chunks/cli-1.1.35-h71ph12s.mjs +0 -2
  564. package/dist/chunks/cli-1.1.35-h7qpm4z8.mjs +0 -3
  565. package/dist/chunks/cli-1.1.35-hm1wpf1w.mjs +0 -2
  566. package/dist/chunks/cli-1.1.35-htvjtg4f.mjs +0 -2
  567. package/dist/chunks/cli-1.1.35-hwphkmp4.mjs +0 -2
  568. package/dist/chunks/cli-1.1.35-hy9jtbmb.mjs +0 -5570
  569. package/dist/chunks/cli-1.1.35-hyqzaskn.mjs +0 -2
  570. package/dist/chunks/cli-1.1.35-j1ypjsz5.mjs +0 -2
  571. package/dist/chunks/cli-1.1.35-j7xxkgf1.mjs +0 -133
  572. package/dist/chunks/cli-1.1.35-jajp8grw.mjs +0 -2
  573. package/dist/chunks/cli-1.1.35-jdqn8gkp.mjs +0 -2
  574. package/dist/chunks/cli-1.1.35-jfzp91gv.mjs +0 -2
  575. package/dist/chunks/cli-1.1.35-jn52m495.mjs +0 -2
  576. package/dist/chunks/cli-1.1.35-jq1wvnwe.mjs +0 -17
  577. package/dist/chunks/cli-1.1.35-jrexyjt9.mjs +0 -2
  578. package/dist/chunks/cli-1.1.35-jvhs6ypf.mjs +0 -10
  579. package/dist/chunks/cli-1.1.35-jx42cnmn.mjs +0 -15
  580. package/dist/chunks/cli-1.1.35-k6jh38a3.mjs +0 -2
  581. package/dist/chunks/cli-1.1.35-kbrngf5h.mjs +0 -2
  582. package/dist/chunks/cli-1.1.35-kcgcs2dj.mjs +0 -2
  583. package/dist/chunks/cli-1.1.35-kdw3m4z1.mjs +0 -25
  584. package/dist/chunks/cli-1.1.35-kh8s6rf2.mjs +0 -4
  585. package/dist/chunks/cli-1.1.35-kkhrpw6q.mjs +0 -2
  586. package/dist/chunks/cli-1.1.35-kp2hgrdb.mjs +0 -24
  587. package/dist/chunks/cli-1.1.35-ktb8z2s9.mjs +0 -3
  588. package/dist/chunks/cli-1.1.35-kvw88dmk.mjs +0 -2
  589. package/dist/chunks/cli-1.1.35-kz5tydkv.mjs +0 -2
  590. package/dist/chunks/cli-1.1.35-m20xytkt.mjs +0 -2
  591. package/dist/chunks/cli-1.1.35-m6efjk78.mjs +0 -2
  592. package/dist/chunks/cli-1.1.35-ma6czbht.mjs +0 -2
  593. package/dist/chunks/cli-1.1.35-ms3xdp4c.mjs +0 -42
  594. package/dist/chunks/cli-1.1.35-ms5g0jwj.mjs +0 -2
  595. package/dist/chunks/cli-1.1.35-nahyfraf.mjs +0 -2
  596. package/dist/chunks/cli-1.1.35-ne21zedp.mjs +0 -2
  597. package/dist/chunks/cli-1.1.35-ngg53c9c.mjs +0 -2
  598. package/dist/chunks/cli-1.1.35-pa3rjff6.mjs +0 -2
  599. package/dist/chunks/cli-1.1.35-pgcrgrc3.mjs +0 -2
  600. package/dist/chunks/cli-1.1.35-pms9wnd8.mjs +0 -2
  601. package/dist/chunks/cli-1.1.35-pr69kkhz.mjs +0 -2
  602. package/dist/chunks/cli-1.1.35-prf6sjs7.mjs +0 -2
  603. package/dist/chunks/cli-1.1.35-ps66nanc.mjs +0 -2
  604. package/dist/chunks/cli-1.1.35-pycaqt81.mjs +0 -2
  605. package/dist/chunks/cli-1.1.35-q1axe4bk.mjs +0 -2
  606. package/dist/chunks/cli-1.1.35-qb0eb8th.mjs +0 -2
  607. package/dist/chunks/cli-1.1.35-qbahm5cg.mjs +0 -2
  608. package/dist/chunks/cli-1.1.35-qgjs5ex0.mjs +0 -7
  609. package/dist/chunks/cli-1.1.35-qnfq8bw4.mjs +0 -4
  610. package/dist/chunks/cli-1.1.35-qvdpj1qb.mjs +0 -2
  611. package/dist/chunks/cli-1.1.35-qxj39xzd.mjs +0 -8
  612. package/dist/chunks/cli-1.1.35-qygaywxg.mjs +0 -34
  613. package/dist/chunks/cli-1.1.35-r4rm2297.mjs +0 -4
  614. package/dist/chunks/cli-1.1.35-r80cjbt8.mjs +0 -2
  615. package/dist/chunks/cli-1.1.35-rmfsk9nw.mjs +0 -2
  616. package/dist/chunks/cli-1.1.35-s05wj44h.mjs +0 -3
  617. package/dist/chunks/cli-1.1.35-s066wwsj.mjs +0 -3
  618. package/dist/chunks/cli-1.1.35-s367nd6g.mjs +0 -2
  619. package/dist/chunks/cli-1.1.35-s3d0nchc.mjs +0 -2
  620. package/dist/chunks/cli-1.1.35-s6n3pb03.mjs +0 -2
  621. package/dist/chunks/cli-1.1.35-s85hd24a.mjs +0 -16
  622. package/dist/chunks/cli-1.1.35-sg0tga4d.mjs +0 -2
  623. package/dist/chunks/cli-1.1.35-swxcv3xf.mjs +0 -6
  624. package/dist/chunks/cli-1.1.35-szkn08rr.mjs +0 -2
  625. package/dist/chunks/cli-1.1.35-t2vx6b45.mjs +0 -17
  626. package/dist/chunks/cli-1.1.35-t5kexs8c.mjs +0 -6
  627. package/dist/chunks/cli-1.1.35-t8c5b3qj.mjs +0 -4
  628. package/dist/chunks/cli-1.1.35-ta15z2yx.mjs +0 -10
  629. package/dist/chunks/cli-1.1.35-tsrq3cxy.mjs +0 -2
  630. package/dist/chunks/cli-1.1.35-tsx8c30n.mjs +0 -2
  631. package/dist/chunks/cli-1.1.35-ve889dy8.mjs +0 -3
  632. package/dist/chunks/cli-1.1.35-w1mzdb9s.mjs +0 -2
  633. package/dist/chunks/cli-1.1.35-w6kgq9n5.mjs +0 -2
  634. package/dist/chunks/cli-1.1.35-w73x0912.mjs +0 -2
  635. package/dist/chunks/cli-1.1.35-w9wzew2x.mjs +0 -4
  636. package/dist/chunks/cli-1.1.35-wmcp8vyj.mjs +0 -2
  637. package/dist/chunks/cli-1.1.35-wpa5rfnt.mjs +0 -12
  638. package/dist/chunks/cli-1.1.35-wtjyzsga.mjs +0 -2
  639. package/dist/chunks/cli-1.1.35-ww28b5vj.mjs +0 -2
  640. package/dist/chunks/cli-1.1.35-x5ft52g3.mjs +0 -2
  641. package/dist/chunks/cli-1.1.35-xbhjhs1c.mjs +0 -3
  642. package/dist/chunks/cli-1.1.35-xdzsf38z.mjs +0 -2
  643. package/dist/chunks/cli-1.1.35-xs5mj8ee.mjs +0 -21
  644. package/dist/chunks/cli-1.1.35-y6bdqv7z.mjs +0 -2
  645. package/dist/chunks/cli-1.1.35-y6xhcehv.mjs +0 -25
  646. package/dist/chunks/cli-1.1.35-yns1ngnz.mjs +0 -2
  647. package/dist/chunks/cli-1.1.35-yta9zrj6.mjs +0 -2
  648. package/dist/chunks/cli-1.1.35-zbz78cha.mjs +0 -9
  649. package/dist/chunks/cli-1.1.35-zf7zq3kb.mjs +0 -63
  650. package/dist/chunks/client-1.1.35-2j9sd0sg.mjs +0 -1
  651. package/dist/chunks/color-1.1.35-nf9dqw3m.mjs +0 -1
  652. package/dist/chunks/compact-1.1.35-h8mqxxs0.mjs +0 -2
  653. package/dist/chunks/config-1.1.35-7t0vfbst.mjs +0 -1
  654. package/dist/chunks/config-1.1.35-cfhvn2fq.mjs +0 -1
  655. package/dist/chunks/constants-1.1.35-kst22e3x.mjs +0 -1
  656. package/dist/chunks/context-1.1.35-2nc26t9y.mjs +0 -1
  657. package/dist/chunks/context-noninteractive-1.1.35-0ym77q3t.mjs +0 -1
  658. package/dist/chunks/conversation-1.1.35-0q4g6qt8.mjs +0 -1
  659. package/dist/chunks/copilotHeaders-1.1.35-7a5mc98p.mjs +0 -1
  660. package/dist/chunks/copy-1.1.35-n37rvhzj.mjs +0 -9
  661. package/dist/chunks/cost-1.1.35-hjmwjk6s.mjs +0 -1
  662. package/dist/chunks/createSession-1.1.35-v7c15fc8.mjs +0 -1
  663. package/dist/chunks/debug-1.1.35-2hf8mhst.mjs +0 -1
  664. package/dist/chunks/defaultActionDeps-1.1.35-15jcbncs.mjs +0 -1480
  665. package/dist/chunks/desktop-1.1.35-6w6gjpff.mjs +0 -2
  666. package/dist/chunks/detectRepository-1.1.35-eztj0q3f.mjs +0 -1
  667. package/dist/chunks/detection-1.1.35-rfkb2dxe.mjs +0 -1
  668. package/dist/chunks/diff-1.1.35-xb27tkcx.mjs +0 -1
  669. package/dist/chunks/doctor-1.1.35-ddg564v7.mjs +0 -1
  670. package/dist/chunks/doctorDiagnostic-1.1.35-1gfkz0p1.mjs +0 -1
  671. package/dist/chunks/earlyInput-1.1.35-5wsb4bkz.mjs +0 -1
  672. package/dist/chunks/effort-1.1.35-r53ttmc3.mjs +0 -13
  673. package/dist/chunks/engine-1.1.35-xthhbk9w.mjs +0 -1
  674. package/dist/chunks/envLessBridgeConfig-1.1.35-t6narn79.mjs +0 -1
  675. package/dist/chunks/envUtils-1.1.35-t6yq14ba.mjs +0 -1
  676. package/dist/chunks/errors-1.1.35-6m0kryy5.mjs +0 -1
  677. package/dist/chunks/exampleCommands-1.1.35-c7dhfj0z.mjs +0 -1
  678. package/dist/chunks/execFileNoThrow-1.1.35-39xh2ycx.mjs +0 -1
  679. package/dist/chunks/exit-1.1.35-zc8g5mnv.mjs +0 -1
  680. package/dist/chunks/explorer-1.1.35-784hbx9r.mjs +0 -1
  681. package/dist/chunks/export-1.1.35-5q6zdykx.mjs +0 -2
  682. package/dist/chunks/fast-1.1.35-fpsnnadp.mjs +0 -1
  683. package/dist/chunks/feedback-1.1.35-mdm8easg.mjs +0 -16
  684. package/dist/chunks/git-1.1.35-j2med41y.mjs +0 -1
  685. package/dist/chunks/githubModelsCredentials-1.1.35-4xzf0z5w.mjs +0 -1
  686. package/dist/chunks/goal-1.1.35-yp44rshy.mjs +0 -4
  687. package/dist/chunks/headless-1.1.35-rxvrbe58.mjs +0 -2
  688. package/dist/chunks/heapdump-1.1.35-xkthm0kj.mjs +0 -6
  689. package/dist/chunks/help-1.1.35-6ppc7eee.mjs +0 -1
  690. package/dist/chunks/hooks-1.1.35-0e80c1wz.mjs +0 -79
  691. package/dist/chunks/hooks-1.1.35-f791gbgk.mjs +0 -1
  692. package/dist/chunks/ide-1.1.35-pz8m36fj.mjs +0 -3
  693. package/dist/chunks/image-processor-napi-1.1.35-56y5k454.mjs +0 -1
  694. package/dist/chunks/import-1.1.35-fcn1y643.mjs +0 -261
  695. package/dist/chunks/inboundAttachments-1.1.35-n6b7ppqk.mjs +0 -1
  696. package/dist/chunks/index-1.1.35-434cwyrk.mjs +0 -1
  697. package/dist/chunks/index-1.1.35-4ngbsgjz.mjs +0 -1
  698. package/dist/chunks/index-1.1.35-7nsjazx1.mjs +0 -1
  699. package/dist/chunks/index-1.1.35-8rnbf6ea.mjs +0 -1
  700. package/dist/chunks/index-1.1.35-e5amgccf.mjs +0 -1
  701. package/dist/chunks/index-1.1.35-eejex06g.mjs +0 -5
  702. package/dist/chunks/index-1.1.35-epm25vr2.mjs +0 -9
  703. package/dist/chunks/index-1.1.35-jxpschvm.mjs +0 -1
  704. package/dist/chunks/index-1.1.35-mdgw0byv.mjs +0 -9
  705. package/dist/chunks/index-1.1.35-n36e4pzf.mjs +0 -1
  706. package/dist/chunks/index-1.1.35-nnrmrgn5.mjs +0 -30
  707. package/dist/chunks/index-1.1.35-p1fttaxb.mjs +0 -1
  708. package/dist/chunks/index-1.1.35-p3ttta20.mjs +0 -1
  709. package/dist/chunks/index-1.1.35-pjz1v5fa.mjs +0 -1
  710. package/dist/chunks/index-1.1.35-pqswr512.mjs +0 -23
  711. package/dist/chunks/index-1.1.35-q464ks4t.mjs +0 -1
  712. package/dist/chunks/index-1.1.35-r5cefbke.mjs +0 -2
  713. package/dist/chunks/index-1.1.35-rf0z1h76.mjs +0 -1
  714. package/dist/chunks/index-1.1.35-wg3dwx0w.mjs +0 -2
  715. package/dist/chunks/index-1.1.35-xcm76j0n.mjs +0 -1
  716. package/dist/chunks/index-1.1.35-y7q90201.mjs +0 -1
  717. package/dist/chunks/index-1.1.35-y9scvznb.mjs +0 -1
  718. package/dist/chunks/index-1.1.35-yy5qsdz8.mjs +0 -1
  719. package/dist/chunks/init-1.1.35-hawgzj6s.mjs +0 -2
  720. package/dist/chunks/initReplBridge-1.1.35-aee08exn.mjs +0 -1
  721. package/dist/chunks/ink-1.1.35-9vhjhx60.mjs +0 -1
  722. package/dist/chunks/insights-1.1.35-2782qak6.mjs +0 -870
  723. package/dist/chunks/install-1.1.35-nptjkfk3.mjs +0 -1
  724. package/dist/chunks/install-github-app-1.1.35-v4ahg5m0.mjs +0 -149
  725. package/dist/chunks/install-slack-app-1.1.35-rc6ch1k0.mjs +0 -1
  726. package/dist/chunks/interactiveHelpers-1.1.35-1755rb8a.mjs +0 -1
  727. package/dist/chunks/keybindings-1.1.35-9qz4bvrq.mjs +0 -2
  728. package/dist/chunks/latestVersionCache-1.1.35-ff7kd1x3.mjs +0 -1
  729. package/dist/chunks/loadAgentsDir-1.1.35-nwtm30nv.mjs +0 -1
  730. package/dist/chunks/loadPluginHooks-1.1.35-jxqkv874.mjs +0 -1
  731. package/dist/chunks/log-1.1.35-h5x69tbw.mjs +0 -1
  732. package/dist/chunks/main-1.1.35-1e6064ax.mjs +0 -1
  733. package/dist/chunks/managedEnv-1.1.35-s6143dpv.mjs +0 -1
  734. package/dist/chunks/mcp-1.1.35-0tswravz.mjs +0 -1
  735. package/dist/chunks/mcp-1.1.35-bdv2pgpj.mjs +0 -17
  736. package/dist/chunks/mcp-1.1.35-khngfse0.mjs +0 -4
  737. package/dist/chunks/mcpb-1.1.35-p4jn8q66.mjs +0 -1
  738. package/dist/chunks/memory-1.1.35-zvk9c80b.mjs +0 -128
  739. package/dist/chunks/model-1.1.35-j8hp9tcm.mjs +0 -1
  740. package/dist/chunks/model-1.1.35-mb41ksj1.mjs +0 -2
  741. package/dist/chunks/node-1.1.35-312s6waw.mjs +0 -1
  742. package/dist/chunks/node-1.1.35-zzk2fc7x.mjs +0 -15
  743. package/dist/chunks/oauth-1.1.35-2pwvpgey.mjs +0 -1
  744. package/dist/chunks/openaiShim-1.1.35-6gbm01ym.mjs +0 -14
  745. package/dist/chunks/output-style-1.1.35-gbk18883.mjs +0 -1
  746. package/dist/chunks/package-F6O7J2XI-1.1.35-0z3efknf.mjs +0 -1
  747. package/dist/chunks/permissions-1.1.35-c11nnhp0.mjs +0 -3
  748. package/dist/chunks/permissions-1.1.35-vqtbrznv.mjs +0 -1
  749. package/dist/chunks/plan-1.1.35-5nz3m4kh.mjs +0 -1
  750. package/dist/chunks/plist-1.1.35-4bd0g91w.mjs +0 -1
  751. package/dist/chunks/plugin-1.1.35-0tg6jzxg.mjs +0 -29
  752. package/dist/chunks/pluginStartupCheck-1.1.35-z1parxqs.mjs +0 -1
  753. package/dist/chunks/plugins-1.1.35-z14pz0dr.mjs +0 -9
  754. package/dist/chunks/preActionHook-1.1.35-9dyzn96j.mjs +0 -2
  755. package/dist/chunks/print-1.1.35-89rm2txf.mjs +0 -57
  756. package/dist/chunks/process-1.1.35-7x8d7kyn.mjs +0 -1
  757. package/dist/chunks/processBashCommand-1.1.35-hj8xz358.mjs +0 -1
  758. package/dist/chunks/processSlashCommand-1.1.35-egejjqfw.mjs +0 -9
  759. package/dist/chunks/prompt-1.1.35-aaz8q4j6.mjs +0 -1
  760. package/dist/chunks/prompt-1.1.35-f3fackax.mjs +0 -1
  761. package/dist/chunks/prompts-1.1.35-58wwfjfd.mjs +0 -1
  762. package/dist/chunks/provider-1.1.35-xwj158q8.mjs +0 -2
  763. package/dist/chunks/providerProfiles-1.1.35-6wzwgty6.mjs +0 -1
  764. package/dist/chunks/providerValidation-1.1.35-z9h8ampz.mjs +0 -6
  765. package/dist/chunks/registerSubcommands-1.1.35-7ewvmysm.mjs +0 -26
  766. package/dist/chunks/registry-1.1.35-y4zandg8.mjs +0 -1
  767. package/dist/chunks/release-notes-1.1.35-s31rkdxh.mjs +0 -5
  768. package/dist/chunks/reload-plugins-1.1.35-18xd3nwy.mjs +0 -2
  769. package/dist/chunks/remote-env-1.1.35-0v4tk5np.mjs +0 -1
  770. package/dist/chunks/remoteBridgeCore-1.1.35-ev420056.mjs +0 -1
  771. package/dist/chunks/rename-1.1.35-m8chhebj.mjs +0 -1
  772. package/dist/chunks/replLauncher-1.1.35-483j4br6.mjs +0 -1
  773. package/dist/chunks/resume-1.1.35-vaxxp18n.mjs +0 -2
  774. package/dist/chunks/rewind-1.1.35-scs8763b.mjs +0 -1
  775. package/dist/chunks/rootOptions-1.1.35-9j5y8k9x.mjs +0 -1
  776. package/dist/chunks/runWorkflowHeadless-1.1.35-zjy5t791.mjs +0 -10
  777. package/dist/chunks/sandbox-adapter-1.1.35-qrmypwca.mjs +0 -1
  778. package/dist/chunks/sandbox-toggle-1.1.35-c2k8p98n.mjs +0 -1
  779. package/dist/chunks/session-1.1.35-78ew080a.mjs +0 -2
  780. package/dist/chunks/sessionStorage-1.1.35-0tyr8wn3.mjs +0 -1
  781. package/dist/chunks/settings-1.1.35-808m5j14.mjs +0 -1
  782. package/dist/chunks/setup-1.1.35-ebpewe9s.mjs +0 -12
  783. package/dist/chunks/sinks-1.1.35-nj35kk9h.mjs +0 -1
  784. package/dist/chunks/skills-1.1.35-zczajd48.mjs +0 -1
  785. package/dist/chunks/startupProfiler-1.1.35-wa5psc2j.mjs +0 -1
  786. package/dist/chunks/startupUpdateCheck-1.1.35-0wac30ap.mjs +0 -1
  787. package/dist/chunks/state-1.1.35-gcp827qz.mjs +0 -1
  788. package/dist/chunks/stats-1.1.35-f1kndsge.mjs +0 -1
  789. package/dist/chunks/status-1.1.35-gwtdrkx2.mjs +0 -1
  790. package/dist/chunks/stickers-1.1.35-fa69zd3v.mjs +0 -1
  791. package/dist/chunks/subprocessEnv-1.1.35-8wsc86ft.mjs +0 -1
  792. package/dist/chunks/tasks-1.1.35-0wd1t6v2.mjs +0 -1
  793. package/dist/chunks/teamHelpers-1.1.35-13qqfhxa.mjs +0 -1
  794. package/dist/chunks/teammateModeSnapshot-1.1.35-wdbfsm1h.mjs +0 -1
  795. package/dist/chunks/teleport-1.1.35-tmhzqx90.mjs +0 -1
  796. package/dist/chunks/terminalSetup-1.1.35-6xq5nt25.mjs +0 -1
  797. package/dist/chunks/theme-1.1.35-4b6gd2dx.mjs +0 -1
  798. package/dist/chunks/thinkback-1.1.35-x88djqdz.mjs +0 -1
  799. package/dist/chunks/thinkback-play-1.1.35-g6n14rjh.mjs +0 -1
  800. package/dist/chunks/toolPool-1.1.35-0qd67zrc.mjs +0 -1
  801. package/dist/chunks/toolSearch-1.1.35-54dpcvf8.mjs +0 -1
  802. package/dist/chunks/tools-1.1.35-3hjsc7mm.mjs +0 -1
  803. package/dist/chunks/trustedDevice-1.1.35-szkdvqcz.mjs +0 -1
  804. package/dist/chunks/turndown.cjs-1.1.35-4azkv4s5.mjs +0 -69
  805. package/dist/chunks/types-1.1.35-ncfe8wzg.mjs +0 -1
  806. package/dist/chunks/ultrareviewCommand-1.1.35-d271ddpn.mjs +0 -4
  807. package/dist/chunks/update-1.1.35-5zabq625.mjs +0 -72
  808. package/dist/chunks/upload-1.1.35-gey82edy.mjs +0 -7
  809. package/dist/chunks/upstreamproxy-1.1.35-bbztgd01.mjs +0 -14
  810. package/dist/chunks/usage-1.1.35-sx2ahz77.mjs +0 -1
  811. package/dist/chunks/util-1.1.35-aph6a5hy.mjs +0 -1
  812. package/dist/chunks/utils-1.1.35-avpezj08.mjs +0 -1
  813. package/dist/chunks/vim-1.1.35-e0jh10q6.mjs +0 -1
  814. package/dist/chunks/watchLoop-1.1.35-baxd01b0.mjs +0 -13
  815. package/dist/chunks/wiki-1.1.35-cns1572n.mjs +0 -132
  816. package/dist/chunks/workflows-1.1.35-0r21887z.mjs +0 -1
  817. package/dist/chunks/worktree-1.1.35-0mj24by3.mjs +0 -1
  818. package/dist/chunks/worktreeModeEnabled-1.1.35-6ej7pdyw.mjs +0 -1
  819. package/dist/chunks/wrapper-1.1.35-fpcy8t3v.mjs +0 -7
  820. /package/dist/chunks/{cli-1.1.35-hnqagxgk.mjs → cli-1.1.37-tfvyj3nx.mjs} +0 -0
@@ -0,0 +1,2 @@
1
+ import{H$ as T,T$ as $}from"./cli-1.1.37-z4wav0zf.mjs";import{$ga as O,bha as Y}from"./cli-1.1.37-jv2bhmv9.mjs";import{Qia as E,Tia as X}from"./cli-1.1.37-sqyyjrzq.mjs";import{gqa as V}from"./cli-1.1.37-5k40cazp.mjs";function j(){B.clear()}async function P(){let z=await Z();if(!z)return null;if(z.host!=="github.com")return null;return`${z.owner}/${z.name}`}async function Z(){let z=O();if(B.has(z))return B.get(z)??null;try{let q=await T();if(E(`Git remote URL: ${q}`),!q)return E("No git remote URL found"),B.set(z,null),null;let x=Q(q);return E(`Parsed repository: ${x?`${x.host}/${x.owner}/${x.name}`:null} from URL: ${q}`),B.set(z,x),x}catch(q){return E(`Error detecting repository: ${q}`),B.set(z,null),null}}function Q(z){let q=z.trim(),x=q.match(/^git@([^:]+):([^/]+)\/([^/]+?)(?:\.git)?$/);if(x?.[1]&&x[2]&&x[3]){if(!N(x[1]))return null;return{host:x[1],owner:x[2],name:x[3]}}let A=q.match(/^(https?|ssh|git):\/\/(?:[^@]+@)?([^/:]+(?::\d+)?)\/([^/]+)\/([^/]+?)(?:\.git)?$/);if(A?.[1]&&A[2]&&A[3]&&A[4]){let I=A[1],J=A[2],K=J.split(":")[0]??"";if(!N(K))return null;return{host:I==="https"||I==="http"?J:K,owner:A[3],name:A[4]}}return null}function S(z){let q=z.trim(),x=Q(q);if(x){if(x.host!=="github.com")return null;return`${x.owner}/${x.name}`}if(!q.includes("://")&&!q.includes("@")&&q.includes("/")){let A=q.split("/");if(A.length===2&&A[0]&&A[1]){let I=A[1].replace(/\.git$/,"");return`${A[0]}/${I}`}}return E(`Could not parse repository from: ${q}`),null}function N(z){if(!z.includes("."))return!1;let q=z.split(".").pop();if(!q)return!1;return/^[a-zA-Z]+$/.test(q)}var B;var _=V(()=>{Y();X();$();B=new Map});
2
+ export{j as T8,P as U8,Z as V8,Q as W8,S as X8,_ as Y8};
@@ -0,0 +1,2 @@
1
+ import{H6 as y,L6 as V}from"./cli-1.1.37-xqs4w5xj.mjs";import{V9 as q,X9 as K,i$ as p,k$ as Q}from"./cli-1.1.37-z4wav0zf.mjs";import{gqa as J}from"./cli-1.1.37-5k40cazp.mjs";function g(){return!!z}async function D(){if(b!==null)return b;return b=!!z,b}function F(){return W||null}async function P(){return(await p(y,["-V"])).code===0}function l(){if(f!==null)return f;let k=process.env.TERM_PROGRAM,B=!!process.env.ITERM_SESSION_ID,H=q.terminal==="iTerm.app";return f=k==="iTerm.app"||B||H,f}async function w(){return(await p(Y,["session","list"])).code===0}var z,W,b=null,f=null,Y="it2";var Z=J(()=>{K();Q();V();z=process.env.TMUX,W=process.env.TMUX_PANE});
2
+ export{g as w6,D as x6,F as y6,P as z6,l as A6,Y as B6,w as C6,Z as D6};
@@ -0,0 +1,3 @@
1
+ import{Aga as T,wga as N}from"./cli-1.1.37-wm28b2wb.mjs";import{gqa as Q}from"./cli-1.1.37-5k40cazp.mjs";function X(){if(!process.stdin.isTTY||F||process.argv.includes("-p")||process.argv.includes("--print"))return;F=!0,A="";try{process.stdin.setEncoding("utf8"),process.stdin.setRawMode(!0),process.stdin.ref(),J=()=>{let q=process.stdin.read();while(q!==null){if(typeof q==="string")U(q);q=process.stdin.read()}},process.stdin.on("readable",J)}catch{F=!1}}function U(q){let v=0;while(v<q.length){let M=q[v],z=M.charCodeAt(0);if(z===3){K(),process.exit(130);return}if(z===4){K();return}if(z===127||z===8){if(A.length>0){let O=N(A);A=A.slice(0,-(O.length||1))}v++;continue}if(z===27){v++;while(v<q.length&&!(q.charCodeAt(v)>=64&&q.charCodeAt(v)<=126))v++;if(v<q.length)v++;continue}if(z<32&&z!==9&&z!==10&&z!==13){v++;continue}if(z===13){A+=`
2
+ `,v++;continue}A+=M,v++}}function K(){if(!F)return;if(F=!1,J)process.stdin.removeListener("readable",J),J=null}function Y(){K();let q=A.trim();return A="",q}function Z(q){A=q}var A="",F=!1,J=null;var V=Q(()=>{T()});
3
+ export{X as SX,K as TX,Y as UX,Z as VX,V as WX};
@@ -0,0 +1,2 @@
1
+ import{tia as W,yia as Z}from"./cli-1.1.37-sqyyjrzq.mjs";import{oja as V,vja as Y}from"./cli-1.1.37-240c02km.mjs";import{gqa as X}from"./cli-1.1.37-5k40cazp.mjs";function H(q){return q.replace(k,(J,x,z)=>{if(z.length<F)return`"${x}":"[REDACTED]"`;let K=`${z.slice(0,8)}...${z.slice(-4)}`;return`"${x}":"${K}"`})}function y(q){let J=q.replace(/\n/g,"\\n");if(J.length<=Q)return J;return J.slice(0,Q)+`... (${J.length} chars)`}function j(q){let J=typeof q==="string"?q:W(q),x=H(J);if(x.length<=Q)return x;return x.slice(0,Q)+`... (${x.length} chars)`}function P(q){let J=V(q);if(q&&typeof q==="object"&&"response"in q){let x=q.response;if(x?.data&&typeof x.data==="object"){let z=x.data,K=typeof z.message==="string"?z.message:typeof z.error==="object"&&z.error&&("message"in z.error)&&typeof z.error.message==="string"?z.error.message:void 0;if(K)return`${J}: ${K}`}}return J}function h(q){if(q&&typeof q==="object"&&"response"in q&&q.response&&typeof q.response.status==="number")return q.response.status;return}function A(q){if(!q||typeof q!=="object")return;if("message"in q&&typeof q.message==="string")return q.message;if("error"in q&&q.error!==null&&typeof q.error==="object"&&"message"in q.error&&typeof q.error.message==="string")return q.error.message;return}var Q=2000,$,k,F=16;var O=X(()=>{Y();Z();$=["session_ingress_token","environment_secret","access_token","secret","token"],k=new RegExp(`"(${$.join("|")})"\\s*:\\s*"([^"]*)"`,"g")});
2
+ export{y as We,j as Xe,P as Ye,h as Ze,A as _e,O as $e};
@@ -0,0 +1,17 @@
1
+ import{eqa as y,hqa as b}from"./cli-1.1.37-5k40cazp.mjs";var P0=y(($w)=>{$w.HttpAuthLocation=void 0;(function($){$.HEADER="header",$.QUERY="query"})($w.HttpAuthLocation||($w.HttpAuthLocation={}));$w.HttpApiKeyAuthLocation=void 0;(function($){$.HEADER="header",$.QUERY="query"})($w.HttpApiKeyAuthLocation||($w.HttpApiKeyAuthLocation={}));$w.EndpointURLScheme=void 0;(function($){$.HTTP="http",$.HTTPS="https"})($w.EndpointURLScheme||($w.EndpointURLScheme={}));$w.AlgorithmId=void 0;(function($){$.MD5="md5",$.CRC32="crc32",$.CRC32C="crc32c",$.SHA1="sha1",$.SHA256="sha256"})($w.AlgorithmId||($w.AlgorithmId={}));var rT=($)=>{let T=[];if($.sha256!==void 0)T.push({algorithmId:()=>$w.AlgorithmId.SHA256,checksumConstructor:()=>$.sha256});if($.md5!=null)T.push({algorithmId:()=>$w.AlgorithmId.MD5,checksumConstructor:()=>$.md5});return{addChecksumAlgorithm(w){T.push(w)},checksumAlgorithms(){return T}}},lT=($)=>{let T={};return $.checksumAlgorithms().forEach((w)=>{T[w.algorithmId()]=w.checksumConstructor()}),T},oT=($)=>{return rT($)},aT=($)=>{return lT($)};$w.FieldPosition=void 0;(function($){$[$.HEADER=0]="HEADER",$[$.TRAILER=1]="TRAILER"})($w.FieldPosition||($w.FieldPosition={}));var eT="__smithy_context";$w.IniSectionType=void 0;(function($){$.PROFILE="profile",$.SSO_SESSION="sso-session",$.SERVICES="services"})($w.IniSectionType||($w.IniSectionType={}));$w.RequestHandlerProtocol=void 0;(function($){$.HTTP_0_9="http/0.9",$.HTTP_1_0="http/1.0",$.TDS_8_0="tds/8.0"})($w.RequestHandlerProtocol||($w.RequestHandlerProtocol={}));$w.SMITHY_CONTEXT_KEY=eT;$w.getDefaultClientConfiguration=oT;$w.resolveDefaultRuntimeConfig=aT});var D0=y((sw)=>{var m=P0(),Iw=h1(),g=($,T)=>{let w=[];if($)w.push($);if(T)for(let P of T)w.push(P);return w},c=($,T)=>{return`${$||"anonymous"}${T&&T.length>0?` (a.k.a. ${T.join(",")})`:""}`},I0=()=>{let $=[],T=[],w=!1,P=new Set,I=(X)=>X.sort((J,f)=>l1[f.step]-l1[J.step]||o1[f.priority||"normal"]-o1[J.priority||"normal"]),h=(X)=>{let J=!1,f=(G)=>{let Q=g(G.name,G.aliases);if(Q.includes(X)){J=!0;for(let Z of Q)P.delete(Z);return!1}return!0};return $=$.filter(f),T=T.filter(f),J},U=(X)=>{let J=!1,f=(G)=>{if(G.middleware===X){J=!0;for(let Q of g(G.name,G.aliases))P.delete(Q);return!1}return!0};return $=$.filter(f),T=T.filter(f),J},A=(X)=>{return $.forEach((J)=>{X.add(J.middleware,{...J})}),T.forEach((J)=>{X.addRelativeTo(J.middleware,{...J})}),X.identifyOnResolve?.(Y.identifyOnResolve()),X},_=(X)=>{let J=[];return X.before.forEach((f)=>{if(f.before.length===0&&f.after.length===0)J.push(f);else J.push(..._(f))}),J.push(X),X.after.reverse().forEach((f)=>{if(f.before.length===0&&f.after.length===0)J.push(f);else J.push(..._(f))}),J},M=(X=!1)=>{let J=[],f=[],G={};return $.forEach((Z)=>{let R={...Z,before:[],after:[]};for(let V of g(R.name,R.aliases))G[V]=R;J.push(R)}),T.forEach((Z)=>{let R={...Z,before:[],after:[]};for(let V of g(R.name,R.aliases))G[V]=R;f.push(R)}),f.forEach((Z)=>{if(Z.toMiddleware){let R=G[Z.toMiddleware];if(R===void 0){if(X)return;throw Error(`${Z.toMiddleware} is not found when adding ${c(Z.name,Z.aliases)} middleware ${Z.relation} ${Z.toMiddleware}`)}if(Z.relation==="after")R.after.push(Z);if(Z.relation==="before")R.before.push(Z)}}),I(J).map(_).reduce((Z,R)=>{return Z.push(...R),Z},[])},Y={add:(X,J={})=>{let{name:f,override:G,aliases:Q}=J,Z={step:"initialize",priority:"normal",middleware:X,...J},R=g(f,Q);if(R.length>0){if(R.some((V)=>P.has(V))){if(!G)throw Error(`Duplicate middleware name '${c(f,Q)}'`);for(let V of R){let L=$.findIndex((T0)=>T0.name===V||T0.aliases?.some((l0)=>l0===V));if(L===-1)continue;let W=$[L];if(W.step!==Z.step||Z.priority!==W.priority)throw Error(`"${c(W.name,W.aliases)}" middleware with ${W.priority} priority in ${W.step} step cannot be overridden by "${c(f,Q)}" middleware with ${Z.priority} priority in ${Z.step} step.`);$.splice(L,1)}}for(let V of R)P.add(V)}$.push(Z)},addRelativeTo:(X,J)=>{let{name:f,override:G,aliases:Q}=J,Z={middleware:X,...J},R=g(f,Q);if(R.length>0){if(R.some((V)=>P.has(V))){if(!G)throw Error(`Duplicate middleware name '${c(f,Q)}'`);for(let V of R){let L=T.findIndex((T0)=>T0.name===V||T0.aliases?.some((l0)=>l0===V));if(L===-1)continue;let W=T[L];if(W.toMiddleware!==Z.toMiddleware||W.relation!==Z.relation)throw Error(`"${c(W.name,W.aliases)}" middleware ${W.relation} "${W.toMiddleware}" middleware cannot be overridden by "${c(f,Q)}" middleware ${Z.relation} "${Z.toMiddleware}" middleware.`);T.splice(L,1)}}for(let V of R)P.add(V)}T.push(Z)},clone:()=>A(I0()),use:(X)=>{X.applyToStack(Y)},remove:(X)=>{if(typeof X==="string")return h(X);else return U(X)},removeByTag:(X)=>{let J=!1,f=(G)=>{let{tags:Q,name:Z,aliases:R}=G;if(Q&&Q.includes(X)){let V=g(Z,R);for(let L of V)P.delete(L);return J=!0,!1}return!0};return $=$.filter(f),T=T.filter(f),J},concat:(X)=>{let J=A(I0());return J.use(X),J.identifyOnResolve(w||J.identifyOnResolve()||(X.identifyOnResolve?.()??!1)),J},applyToStack:A,identify:()=>{return M(!0).map((X)=>{let J=X.step??X.relation+" "+X.toMiddleware;return c(X.name,X.aliases)+" - "+J})},identifyOnResolve(X){if(typeof X==="boolean")w=X;return w},resolve:(X,J)=>{for(let f of M().map((G)=>G.middleware).reverse())X=f(X,J);if(w)console.log(Y.identify());return X}};return Y},l1={initialize:5,serialize:4,build:3,finalizeRequest:2,deserialize:1},o1={high:3,normal:2,low:1},hw=($)=>$[m.SMITHY_CONTEXT_KEY]||($[m.SMITHY_CONTEXT_KEY]={}),Uw=($)=>{if(typeof $==="function")return $;let T=Promise.resolve($);return()=>T},Aw=($)=>()=>{throw Error($)},_w=($)=>()=>Promise.reject($),W0=()=>{let $=new WeakSet;return(T,w)=>{if(typeof w==="object"&&w!==null){if($.has(w))return"[Circular]";$.add(w)}return w}},Mw=($)=>{return new Promise((T)=>setTimeout(T,$*1000))},$$={minDelay:2,maxDelay:120};sw.WaiterState=void 0;(function($){$.ABORTED="ABORTED",$.FAILURE="FAILURE",$.SUCCESS="SUCCESS",$.RETRY="RETRY",$.TIMEOUT="TIMEOUT"})(sw.WaiterState||(sw.WaiterState={}));var Xw=($)=>{if($.state===sw.WaiterState.ABORTED){let T=Error(`${JSON.stringify({...$,reason:"Request was aborted"},W0())}`);throw T.name="AbortError",T}else if($.state===sw.WaiterState.TIMEOUT){let T=Error(`${JSON.stringify({...$,reason:"Waiter has timed out"},W0())}`);throw T.name="TimeoutError",T}else if($.state!==sw.WaiterState.SUCCESS)throw Error(`${JSON.stringify($,W0())}`);return $},Jw=async({minDelay:$,maxDelay:T,maxWaitTime:w,abortController:P,client:I,abortSignal:h},U,A)=>{let _={},[M,Y]=[$*1000,T*1000],X=0,J=Date.now()+w*1000,f=Date.now()+60000,G=!1;while(!0){if(X>0){let R=Gw(M,Y,X,J);if(P?.signal?.aborted||h?.aborted)return _["AbortController signal aborted."]|=0,_["AbortController signal aborted."]+=1,{state:sw.WaiterState.ABORTED,observedResponses:_};if(Date.now()+R>J)return{state:sw.WaiterState.TIMEOUT,observedResponses:_};await Mw(R/1000)}let{state:Q,reason:Z}=await A(I,U);if(Z){let R=fw(Z);_[R]|=0,_[R]+=1}if(Q!==sw.WaiterState.RETRY)return{state:Q,reason:Z,final:Z,observedResponses:_};if(X+=1,!G&&Date.now()>=f)Yw(_,I),G=!0}},Yw=($={},T)=>{let w=Object.keys($),P=0;for(let U of w){let A=$[U]|0;if(U.startsWith("403:"))P+=A}let I=T?.config?.logger,h=typeof I?.warn==="function"&&!I.constructor?.name?.includes?.("NoOpLogger")?I:console;if(P>=3||w[w.length-1]?.startsWith("403:"))h.warn("@smithy/util-waiter WARN - 403 status code encountered during waiter polling.")},fw=($)=>{let T=$?.$response?.statusCode??$?.$metadata?.httpStatusCode;if($?.$responseBodyText)return`${T?T+": ":""}Deserialization error for body: ${$.$responseBodyText}`;if(T){if($?.$response||$?.message)return`${T??"Unknown"}: ${$?.message}`;return`${T}: OK`}return String($?.message??JSON.stringify($,W0())??"Unknown")},Gw=($,T,w,P)=>{let I=Math.log(T/$)/Math.log(2)+1;if(w>I)return T;let h=$*2**(w-1),U=Math.min(h,T),A=Zw($,U);if(Date.now()+A>P){let _=P-Date.now();return Math.max(0,_-500)}return A},Zw=($,T)=>$+Math.random()*(T-$),Rw=($)=>{if($.maxWaitTime<=0)throw Error("WaiterConfiguration.maxWaitTime must be greater than 0");else if($.minDelay<=0)throw Error("WaiterConfiguration.minDelay must be greater than 0");else if($.maxDelay<=0)throw Error("WaiterConfiguration.maxDelay must be greater than 0");else if($.maxWaitTime<=$.minDelay)throw Error(`WaiterConfiguration.maxWaitTime [${$.maxWaitTime}] must be greater than WaiterConfiguration.minDelay [${$.minDelay}] for this waiter`);else if($.maxDelay<$.minDelay)throw Error(`WaiterConfiguration.maxDelay [${$.maxDelay}] must be greater than WaiterConfiguration.minDelay [${$.minDelay}] for this waiter`)},a1=($)=>{let T,w=new Promise((P)=>{if(T=()=>P({state:sw.WaiterState.ABORTED}),typeof $.addEventListener==="function")$.addEventListener("abort",T);else $.onabort=T});return{clearListener(){if(typeof $.removeEventListener==="function")$.removeEventListener("abort",T)},aborted:w}},Qw=async($,T,w)=>{let P={...$$,...$};Rw(P);let I=[Jw(P,T,w)],h=[];if($.abortSignal){let{aborted:U,clearListener:A}=a1($.abortSignal);h.push(A),I.push(U)}if($.abortController?.signal){let{aborted:U,clearListener:A}=a1($.abortController.signal);h.push(A),I.push(U)}return Promise.race(I).then((U)=>{for(let A of h)A();return U})};class T${config;middlewareStack=I0();initConfig;handlers;constructor($){this.config=$;let{protocol:T,protocolSettings:w}=$;if(w){if(typeof T==="function")$.protocol=new T(w)}}send($,T,w){let P=typeof T!=="function"?T:void 0,I=typeof T==="function"?T:w,h=P===void 0&&this.config.cacheMiddleware===!0,U;if(h){if(!this.handlers)this.handlers=new WeakMap;let A=this.handlers;if(A.has($.constructor))U=A.get($.constructor);else U=$.resolveMiddleware(this.middlewareStack,this.config,P),A.set($.constructor,U)}else delete this.handlers,U=$.resolveMiddleware(this.middlewareStack,this.config,P);if(I)U($).then((A)=>I(null,A.output),(A)=>I(A)).catch(()=>{});else return U($).then((A)=>A.output)}destroy(){this.config?.requestHandler?.destroy?.(),delete this.handlers}}var P1="***SensitiveInformation***";function H0($,T){if(T==null)return T;let w=Iw.NormalizedSchema.of($);if(w.getMergedTraits().sensitive)return P1;if(w.isListSchema()){if(!!w.getValueSchema().getMergedTraits().sensitive)return P1}else if(w.isMapSchema()){if(!!w.getKeySchema().getMergedTraits().sensitive||!!w.getValueSchema().getMergedTraits().sensitive)return P1}else if(w.isStructSchema()&&typeof T==="object"){let P=T,I={};for(let[h,U]of w.structIterator())if(P[h]!=null)I[h]=H0(U,P[h]);return I}return T}class U1{middlewareStack=I0();schema;static classBuilder(){return new w$}resolveMiddlewareWithContext($,T,w,{middlewareFn:P,clientName:I,commandName:h,inputFilterSensitiveLog:U,outputFilterSensitiveLog:A,smithyContext:_,additionalContext:M,CommandCtor:Y}){for(let Z of P.bind(this)(Y,$,T,w))this.middlewareStack.use(Z);let X=$.concat(this.middlewareStack),{logger:J}=T,f={logger:J,clientName:I,commandName:h,inputFilterSensitiveLog:U,outputFilterSensitiveLog:A,[m.SMITHY_CONTEXT_KEY]:{commandInstance:this,..._},...M},{requestHandler:G}=T,Q=w??{};if(_.eventStream)Q={isEventStream:!0,...Q};return X.resolve((Z)=>G.handle(Z.request,Q),f)}}class w${_init=()=>{};_ep={};_middlewareFn=()=>[];_commandName="";_clientName="";_additionalContext={};_smithyContext={};_inputFilterSensitiveLog=void 0;_outputFilterSensitiveLog=void 0;_serializer=null;_deserializer=null;_operationSchema;init($){this._init=$}ep($){return this._ep=$,this}m($){return this._middlewareFn=$,this}s($,T,w={}){return this._smithyContext={service:$,operation:T,...w},this}c($={}){return this._additionalContext=$,this}n($,T){return this._clientName=$,this._commandName=T,this}f($=(w)=>w,T=(w)=>w){return this._inputFilterSensitiveLog=$,this._outputFilterSensitiveLog=T,this}ser($){return this._serializer=$,this}de($){return this._deserializer=$,this}sc($){return this._operationSchema=$,this._smithyContext.operationSchema=$,this}build(){let $=this,T;return T=class extends U1{input;static getEndpointParameterInstructions(){return $._ep}constructor(...[w]){super();this.input=w??{},$._init(this),this.schema=$._operationSchema}resolveMiddleware(w,P,I){let h=$._operationSchema,U=h?.[4]??h?.input,A=h?.[5]??h?.output;return this.resolveMiddlewareWithContext(w,P,I,{CommandCtor:T,middlewareFn:$._middlewareFn,clientName:$._clientName,commandName:$._commandName,inputFilterSensitiveLog:$._inputFilterSensitiveLog??(h?H0.bind(null,U):(_)=>_),outputFilterSensitiveLog:$._outputFilterSensitiveLog??(h?H0.bind(null,A):(_)=>_),smithyContext:$._smithyContext,additionalContext:$._additionalContext})}serialize=$._serializer;deserialize=$._deserializer}}}var Vw="***SensitiveInformation***",Ow=($,T,w)=>{for(let[h,U]of Object.entries($)){let A=async function(M,Y,X){let J=new U(M);if(typeof Y==="function")this.send(J,Y);else if(typeof X==="function"){if(typeof Y!=="object")throw Error(`Expected http options but got ${typeof Y}`);this.send(J,Y||{},X)}else return this.send(J,Y)},_=(h[0].toLowerCase()+h.slice(1)).replace(/Command$/,"");T.prototype[_]=A}let{paginators:P={},waiters:I={}}=w??{};for(let[h,U]of Object.entries(P))if(T.prototype[h]===void 0)T.prototype[h]=function(A={},_,...M){return U({..._,client:this},A,...M)};for(let[h,U]of Object.entries(I))if(T.prototype[h]===void 0)T.prototype[h]=async function(A={},_,...M){let Y=_;if(typeof _==="number")Y={maxWaitTime:_};return U({...Y,client:this},A,...M)}};class t extends Error{$fault;$response;$retryable;$metadata;constructor($){super($.message);Object.setPrototypeOf(this,Object.getPrototypeOf(this).constructor.prototype),this.name=$.name,this.$fault=$.$fault,this.$metadata=$.$metadata}static isInstance($){if(!$)return!1;let T=$;return t.prototype.isPrototypeOf(T)||Boolean(T.$fault)&&Boolean(T.$metadata)&&(T.$fault==="client"||T.$fault==="server")}static[Symbol.hasInstance]($){if(!$)return!1;let T=$;if(this===t)return t.isInstance($);if(t.isInstance($)){if(T.name&&this.name)return this.prototype.isPrototypeOf($)||T.name===this.name;return this.prototype.isPrototypeOf($)}return!1}}var P$=($,T={})=>{Object.entries(T).filter(([,P])=>P!==void 0).forEach(([P,I])=>{if($[P]==null||$[P]==="")$[P]=I});let w=$.message||$.Message||"UnknownError";return $.message=w,delete $.Message,$},I$=({output:$,parsedBody:T,exceptionCtor:w,errorCode:P})=>{let I=Lw($),h=I.httpStatusCode?I.httpStatusCode+"":void 0,U=new w({name:T?.code||T?.Code||P||h||"UnknownError",$fault:"client",$metadata:I});throw P$(U,T)},Nw=($)=>{return({output:T,parsedBody:w,errorCode:P})=>{I$({output:T,parsedBody:w,exceptionCtor:$,errorCode:P})}},Lw=($)=>({httpStatusCode:$.statusCode,requestId:$.headers["x-amzn-requestid"]??$.headers["x-amzn-request-id"]??$.headers["x-amz-request-id"],extendedRequestId:$.headers["x-amz-id-2"],cfId:$.headers["x-amz-cf-id"]}),Ww=($)=>{switch($){case"standard":return{retryMode:"standard",connectionTimeout:3100};case"in-region":return{retryMode:"standard",connectionTimeout:1100};case"cross-region":return{retryMode:"standard",connectionTimeout:3100};case"mobile":return{retryMode:"standard",connectionTimeout:30000};default:return{}}},e1=!1,Hw=($)=>{if($&&!e1&&parseInt($.substring(1,$.indexOf(".")))<16)e1=!0},h$=Object.values(m.AlgorithmId),U$=($)=>{let T=[];for(let w in m.AlgorithmId){let P=m.AlgorithmId[w];if($[P]===void 0)continue;T.push({algorithmId:()=>P,checksumConstructor:()=>$[P]})}for(let[w,P]of Object.entries($.checksumAlgorithms??{}))T.push({algorithmId:()=>w,checksumConstructor:()=>P});return{addChecksumAlgorithm(w){$.checksumAlgorithms=$.checksumAlgorithms??{};let P=w.algorithmId(),I=w.checksumConstructor();if(h$.includes(P))$.checksumAlgorithms[P.toUpperCase()]=I;else $.checksumAlgorithms[P]=I;T.push(w)},checksumAlgorithms(){return T}}},A$=($)=>{let T={};return $.checksumAlgorithms().forEach((w)=>{let P=w.algorithmId();if(h$.includes(P))T[P]=w.checksumConstructor()}),T},_$=($)=>{return{setRetryStrategy(T){$.retryStrategy=T},retryStrategy(){return $.retryStrategy}}},M$=($)=>{let T={};return T.retryStrategy=$.retryStrategy(),T},X$=($)=>{return Object.assign(U$($),_$($))},Dw=X$,Ew=($)=>{return Object.assign(A$($),M$($))},Kw=($)=>Array.isArray($)?$:[$],J$=($)=>{for(let w in $)if($.hasOwnProperty(w)&&$[w]["#text"]!==void 0)$[w]=$[w]["#text"];else if(typeof $[w]==="object"&&$[w]!==null)$[w]=J$($[w]);return $},Bw=($)=>{return $!=null};class Y${trace(){}debug(){}info(){}warn(){}error(){}}function f$($,T,w){let P,I,h;if(typeof T>"u"&&typeof w>"u")P={},h=$;else if(P=$,typeof T==="function")return I=T,h=w,Fw(P,I,h);else h=T;for(let U of Object.keys(h)){if(!Array.isArray(h[U])){P[U]=h[U];continue}G$(P,null,h,U)}return P}var qw=($)=>{let T={};for(let[w,P]of Object.entries($||{}))T[w]=[,P];return T},xw=($,T)=>{let w={};for(let P in T)G$(w,$,T,P);return w},Fw=($,T,w)=>{return f$($,Object.entries(w).reduce((P,[I,h])=>{if(Array.isArray(h))P[I]=h;else if(typeof h==="function")P[I]=[T,h()];else P[I]=[T,h];return P},{}))},G$=($,T,w,P)=>{if(T!==null){let U=w[P];if(typeof U==="function")U=[,U];let[A=zw,_=Sw,M=P]=U;if(typeof A==="function"&&A(T[M])||typeof A!=="function"&&!!A)$[P]=_(T[M]);return}let[I,h]=w[P];if(typeof h==="function"){let U,A=I===void 0&&(U=h())!=null,_=typeof I==="function"&&!!I(void 0)||typeof I!=="function"&&!!I;if(A)$[P]=U;else if(_)$[P]=h()}else{let U=I===void 0&&h!=null,A=typeof I==="function"&&!!I(h)||typeof I!=="function"&&!!I;if(U||A)$[P]=h}},zw=($)=>$!=null,Sw=($)=>$,jw=($)=>{if($!==$)return"NaN";switch($){case 1/0:return"Infinity";case-1/0:return"-Infinity";default:return $}},Cw=($)=>$.toISOString().replace(".000Z","Z"),I1=($)=>{if($==null)return{};if(Array.isArray($))return $.filter((T)=>T!=null).map(I1);if(typeof $==="object"){let T={};for(let w of Object.keys($)){if($[w]==null)continue;T[w]=I1($[w])}return T}return $};sw.AlgorithmId=m.AlgorithmId;sw.Client=T$;sw.Command=U1;sw.NoOpLogger=Y$;sw.SENSITIVE_STRING=Vw;sw.ServiceException=t;sw._json=I1;sw.checkExceptions=Xw;sw.constructStack=I0;sw.convertMap=qw;sw.createAggregatedClient=Ow;sw.createWaiter=Qw;sw.decorateServiceException=P$;sw.emitWarningIfUnsupportedVersion=Hw;sw.getArrayIfSingleItem=Kw;sw.getChecksumConfiguration=U$;sw.getDefaultClientConfiguration=Dw;sw.getDefaultExtensionConfiguration=X$;sw.getRetryConfiguration=_$;sw.getSmithyContext=hw;sw.getValueFromTextNode=J$;sw.invalidFunction=Aw;sw.invalidProvider=_w;sw.isSerializableHeaderValue=Bw;sw.loadConfigsForDefaultMode=Ww;sw.map=f$;sw.normalizeProvider=Uw;sw.resolveChecksumRuntimeConfig=A$;sw.resolveDefaultRuntimeConfig=Ew;sw.resolveRetryRuntimeConfig=M$;sw.schemaLogFilter=H0;sw.serializeDateTime=Cw;sw.serializeFloat=jw;sw.take=xw;sw.throwDefaultError=I$;sw.waiterServiceDefaults=$$;sw.withBaseException=Nw});var C$=y((ZI)=>{var OP=b("node:os"),i=b("node:path"),NP=b("node:crypto"),N$=b("node:fs/promises"),E0=P0(),K0=D0(),LP=F0();class u extends Error{name="ProviderError";tryNextLink;constructor($,T=!0){let w,P=!0;if(typeof T==="boolean")w=void 0,P=T;else if(T!=null&&typeof T==="object")w=T.logger,P=T.tryNextLink??!0;super($);this.tryNextLink=P,Object.setPrototypeOf(this,u.prototype),w?.debug?.(`@smithy/property-provider ${P?"->":"(!)"} ${$}`)}static from($,T=!0){return Object.assign(new this($.message,T),$)}}class h0 extends u{name="CredentialsProviderError";constructor($,T=!0){super($,T);Object.setPrototypeOf(this,h0.prototype)}}class J1 extends u{name="TokenProviderError";constructor($,T=!0){super($,T);Object.setPrototypeOf(this,J1.prototype)}}var L$=(...$)=>async()=>{if($.length===0)throw new u("No providers in chain");let T;for(let w of $)try{return await w()}catch(P){if(T=P,P?.tryNextLink)continue;throw P}throw T},W$=($)=>()=>Promise.resolve($),Y1=($,T,w)=>{let P,I,h,U=!1,A=async()=>{if(!I)I=$();try{P=await I,h=!0,U=!1}finally{I=void 0}return P};if(T===void 0)return async(_)=>{if(!h||_?.forceRefresh)P=await A();return P};return async(_)=>{if(!h||_?.forceRefresh)P=await A();if(U)return P;if(w&&!w(P))return U=!0,P;if(T(P))return await A(),P;return P}},F=($,T,w)=>{if(!(T in $))return;if($[T]==="true")return!0;if($[T]==="false")return!1;throw Error(`Cannot load ${w} "${T}". Expected "true" or "false", got ${$[T]}.`)},WP=($,T,w)=>{if(!(T in $))return;let P=parseInt($[T],10);if(Number.isNaN(P))throw TypeError(`Cannot load ${w} '${T}'. Expected number, got '${$[T]}'.`);return P};ZI.SelectorType=void 0;(function($){$.ENV="env",$.CONFIG="shared config entry"})(ZI.SelectorType||(ZI.SelectorType={}));var A1={},HP=()=>{if(process&&process.geteuid)return`${process.geteuid()}`;return"DEFAULT"},U0=()=>{let{HOME:$,USERPROFILE:T,HOMEPATH:w,HOMEDRIVE:P=`C:${i.sep}`}=process.env;if($)return $;if(T)return T;if(w)return`${P}${w}`;let I=HP();if(!A1[I])A1[I]=OP.homedir();return A1[I]},H$="AWS_PROFILE",D$="default",E$=($)=>$.profile||process.env[H$]||D$,K$=($)=>{let w=NP.createHash("sha1").update($).digest("hex");return i.join(U0(),".aws","sso","cache",`${w}.json`)},B0={},DP=async($)=>{if(B0[$])return B0[$];let T=K$($),w=await N$.readFile(T,"utf8");return JSON.parse(w)},d=".",EP=($)=>Object.entries($).filter(([T])=>{let w=T.indexOf(d);if(w===-1)return!1;return Object.values(E0.IniSectionType).includes(T.substring(0,w))}).reduce((T,[w,P])=>{let I=w.indexOf(d),h=w.substring(0,I)===E0.IniSectionType.PROFILE?w.substring(I+1):w;return T[h]=P,T},{...$.default&&{default:$.default}}),KP="AWS_CONFIG_FILE",B$=()=>process.env[KP]||i.join(U0(),".aws","config"),BP="AWS_SHARED_CREDENTIALS_FILE",qP=()=>process.env[BP]||i.join(U0(),".aws","credentials"),xP=/^([\w-]+)\s(["'])?([\w-@\+\.%:/]+)\2$/,FP=["__proto__","profile __proto__"],M1=($)=>{let T={},w,P;for(let I of $.split(/\r?\n/)){let h=I.split(/(^|\s)[;#]/)[0].trim();if(h[0]==="["&&h[h.length-1]==="]"){w=void 0,P=void 0;let A=h.substring(1,h.length-1),_=xP.exec(A);if(_){let[,M,,Y]=_;if(Object.values(E0.IniSectionType).includes(M))w=[M,Y].join(d)}else w=A;if(FP.includes(A))throw Error(`Found invalid profile name "${A}"`)}else if(w){let A=h.indexOf("=");if(![0,-1].includes(A)){let[_,M]=[h.substring(0,A).trim(),h.substring(A+1).trim()];if(M==="")P=_;else{if(P&&I.trimStart()===I)P=void 0;T[w]=T[w]||{};let Y=P?[P,_].join(d):_;T[w][Y]=M}}}}return T},_1={},q0={},x0=($,T)=>{if(q0[$]!==void 0)return q0[$];if(!_1[$]||T?.ignoreCache)_1[$]=N$.readFile($,"utf8");return _1[$]},Z$=()=>({}),f1=async($={})=>{let{filepath:T=qP(),configFilepath:w=B$()}=$,P=U0(),I="~/",h=T;if(T.startsWith("~/"))h=i.join(P,T.slice(2));let U=w;if(w.startsWith("~/"))U=i.join(P,w.slice(2));let A=await Promise.all([x0(U,{ignoreCache:$.ignoreCache}).then(M1).then(EP).catch(Z$),x0(h,{ignoreCache:$.ignoreCache}).then(M1).catch(Z$)]);return{configFile:A[0],credentialsFile:A[1]}},zP=($)=>Object.entries($).filter(([T])=>T.startsWith(E0.IniSectionType.SSO_SESSION+d)).reduce((T,[w,P])=>({...T,[w.substring(w.indexOf(d)+1)]:P}),{}),SP=()=>({}),jP=async($={})=>x0($.configFilepath??B$()).then(M1).then(zP).catch(SP),CP=(...$)=>{let T={};for(let w of $)for(let[P,I]of Object.entries(w))if(T[P]!==void 0)Object.assign(T[P],I);else T[P]=I;return T},sP=async($)=>{let T=await f1($);return CP(T.configFile,T.credentialsFile)},cP={getFileRecord(){return q0},interceptFile($,T){q0[$]=Promise.resolve(T)},getTokenRecord(){return B0},interceptToken($,T){B0[$]=T}};function q$($){try{let T=new Set(Array.from($.match(/([A-Z_]){3,}/g)??[]));return T.delete("CONFIG"),T.delete("CONFIG_PREFIX_SEPARATOR"),T.delete("ENV"),[...T].join(", ")}catch(T){return $}}var bP=($,T)=>async()=>{try{let w=$(process.env,T);if(w===void 0)throw Error();return w}catch(w){throw new h0(w.message||`Not found in ENV: ${q$($.toString())}`,{logger:T?.logger})}},kP=($,{preferredFile:T="config",...w}={})=>async()=>{let P=E$(w),{configFile:I,credentialsFile:h}=await f1(w),U=h[P]||{},A=I[P]||{},_=T==="config"?{...U,...A}:{...A,...U};try{let Y=$(_,T==="config"?I:h);if(Y===void 0)throw Error();return Y}catch(M){throw new h0(M.message||`Not found in config files w/ profile [${P}]: ${q$($.toString())}`,{logger:w.logger})}},pP=($)=>typeof $==="function",x$=($)=>pP($)?async()=>await $():W$($),X1=({environmentVariableSelector:$,configFileSelector:T,default:w},P={})=>{let{signingName:I,logger:h}=P;return Y1(L$(bP($,{signingName:I,logger:h}),kP(T,P),x$(w)))},G1="AWS_USE_DUALSTACK_ENDPOINT",Z1="use_dualstack_endpoint",yP=!1,gP={environmentVariableSelector:($)=>F($,G1,ZI.SelectorType.ENV),configFileSelector:($)=>F($,Z1,ZI.SelectorType.CONFIG),default:!1},mP={environmentVariableSelector:($)=>F($,G1,ZI.SelectorType.ENV),configFileSelector:($)=>F($,Z1,ZI.SelectorType.CONFIG),default:void 0},R1="AWS_USE_FIPS_ENDPOINT",Q1="use_fips_endpoint",dP=!1,vP={environmentVariableSelector:($)=>F($,R1,ZI.SelectorType.ENV),configFileSelector:($)=>F($,Q1,ZI.SelectorType.CONFIG),default:!1},nP={environmentVariableSelector:($)=>F($,R1,ZI.SelectorType.ENV),configFileSelector:($)=>F($,Q1,ZI.SelectorType.CONFIG),default:void 0},tP=($)=>{let{tls:T,endpoint:w,urlParser:P,useDualstackEndpoint:I}=$;return Object.assign($,{tls:T??!0,endpoint:K0.normalizeProvider(typeof w==="string"?P(w):w),isCustomEndpoint:!0,useDualstackEndpoint:K0.normalizeProvider(I??!1)})},iP=async($)=>{let{tls:T=!0}=$,w=await $.region();if(!new RegExp(/^([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]{0,61}[a-zA-Z0-9])$/).test(w))throw Error("Invalid region in client config");let I=await $.useDualstackEndpoint(),h=await $.useFipsEndpoint(),{hostname:U}=await $.regionInfoProvider(w,{useDualstackEndpoint:I,useFipsEndpoint:h})??{};if(!U)throw Error("Cannot resolve hostname from client config");return $.urlParser(`${T?"https:":"http:"}//${U}`)},uP=($)=>{let T=K0.normalizeProvider($.useDualstackEndpoint??!1),{endpoint:w,useFipsEndpoint:P,urlParser:I,tls:h}=$;return Object.assign($,{tls:h??!0,endpoint:w?K0.normalizeProvider(typeof w==="string"?I(w):w):()=>iP({...$,useDualstackEndpoint:T,useFipsEndpoint:P}),isCustomEndpoint:!!w,useDualstackEndpoint:T})},F$="AWS_REGION",z$="region",S$={environmentVariableSelector:($)=>$[F$],configFileSelector:($)=>$[z$],default:()=>{throw Error("Region is missing")}},rP={preferredFile:"credentials"},R$=new Set,lP=($,T=LP.isValidHostLabel)=>{if(!R$.has($)&&!T($))if($==="*")console.warn('@smithy/config-resolver WARN - Please use the caller region instead of "*". See "sigv4a" in https://github.com/aws/aws-sdk-js-v3/blob/main/supplemental-docs/CLIENTS.md.');else throw Error(`Region not accepted: region="${$}" is not a valid hostname component.`);else R$.add($)},j$=($)=>typeof $==="string"&&($.startsWith("fips-")||$.endsWith("-fips")),oP=($)=>j$($)?["fips-aws-global","aws-fips"].includes($)?"us-east-1":$.replace(/fips-(dkr-|prod-)?|-fips/,""):$,aP=($)=>{let{region:T,useFipsEndpoint:w}=$;if(!T)throw Error("Region is missing");return Object.assign($,{region:async()=>{let P=typeof T==="function"?await T():T,I=oP(P);return lP(I),I},useFipsEndpoint:async()=>{let P=typeof T==="string"?T:await T();if(j$(P))return!0;return typeof w!=="function"?Promise.resolve(!!w):w()}})},Q$=($=[],{useFipsEndpoint:T,useDualstackEndpoint:w})=>$.find(({tags:P})=>T===P.includes("fips")&&w===P.includes("dualstack"))?.hostname,eP=($,{regionHostname:T,partitionHostname:w})=>T?T:w?w.replace("{region}",$):void 0,$I=($,{partitionHash:T})=>Object.keys(T||{}).find((w)=>T[w].regions.includes($))??"aws",TI=($,{signingRegion:T,regionRegex:w,useFipsEndpoint:P})=>{if(T)return T;else if(P){let I=w.replace("\\\\","\\").replace(/^\^/g,"\\.").replace(/\$$/g,"\\."),h=$.match(I);if(h)return h[0].slice(1,-1)}},wI=($,{useFipsEndpoint:T=!1,useDualstackEndpoint:w=!1,signingService:P,regionHash:I,partitionHash:h})=>{let U=$I($,{partitionHash:h}),A=$ in I?$:h[U]?.endpoint??$,_={useFipsEndpoint:T,useDualstackEndpoint:w},M=Q$(I[A]?.variants,_),Y=Q$(h[U]?.variants,_),X=eP(A,{regionHostname:M,partitionHostname:Y});if(X===void 0)throw Error(`Endpoint resolution failed for: ${{resolvedRegion:A,useFipsEndpoint:T,useDualstackEndpoint:w}}`);let J=TI(X,{signingRegion:I[A]?.signingRegion,regionRegex:h[U].regionRegex,useFipsEndpoint:T});return{partition:U,signingService:P,hostname:X,...J&&{signingRegion:J},...I[A]?.signingService&&{signingService:I[A].signingService}}},PI="AWS_EXECUTION_ENV",V$="AWS_REGION",O$="AWS_DEFAULT_REGION",II="AWS_EC2_METADATA_DISABLED",hI=["in-region","cross-region","mobile","standard","legacy"],UI="/latest/meta-data/placement/region",AI="AWS_DEFAULTS_MODE",_I="defaults_mode",MI={environmentVariableSelector:($)=>{return $[AI]},configFileSelector:($)=>{return $[_I]},default:"legacy"},XI=({region:$=X1(S$),defaultsMode:T=X1(MI)}={})=>Y1(async()=>{let w=typeof T==="function"?await T():T;switch(w?.toLowerCase()){case"auto":return JI($);case"in-region":case"cross-region":case"mobile":case"standard":case"legacy":return Promise.resolve(w?.toLocaleLowerCase());case void 0:return Promise.resolve("legacy");default:throw Error(`Invalid parameter for "defaultsMode", expect ${hI.join(", ")}, got ${w}`)}}),JI=async($)=>{if($){let T=typeof $==="function"?await $():$,w=await YI();if(!w)return"standard";if(T===w)return"in-region";else return"cross-region"}return"standard"},YI=async()=>{if(process.env[PI]&&(process.env[V$]||process.env[O$]))return process.env[V$]??process.env[O$];if(!process.env[II])try{let $=await fI();return(await GI({hostname:$.hostname,path:UI})).toString()}catch($){}},fI=async()=>{let $=process.env.AWS_EC2_METADATA_SERVICE_ENDPOINT;if($){let w=new URL($);return{hostname:w.hostname,path:w.pathname}}if(process.env.AWS_EC2_METADATA_SERVICE_ENDPOINT_MODE==="IPv6")return{hostname:"fd00:ec2::254",path:"/"};return{hostname:"169.254.169.254",path:"/"}},GI=async({hostname:$,path:T})=>{let{request:w}=await import("node:http");return new Promise((P,I)=>{let h=w({method:"GET",hostname:$.replace(/^\[(.+)]$/,"$1"),path:T,timeout:1000,signal:AbortSignal.timeout(1000)});h.on("error",(U)=>{I(U),h.destroy()}),h.on("timeout",()=>{I(Error("TimeoutError from instance metadata service")),h.destroy()}),h.on("response",(U)=>{let{statusCode:A=400}=U;if(A<200||300<=A){I(Object.assign(Error("Error response received from instance metadata service"),{statusCode:A})),h.destroy();return}let _=[];U.on("data",(M)=>_.push(M)),U.on("end",()=>{P(Buffer.concat(_)),h.destroy()})}),h.end()})};ZI.CONFIG_PREFIX_SEPARATOR=d;ZI.CONFIG_USE_DUALSTACK_ENDPOINT=Z1;ZI.CONFIG_USE_FIPS_ENDPOINT=Q1;ZI.CredentialsProviderError=h0;ZI.DEFAULT_PROFILE=D$;ZI.DEFAULT_USE_DUALSTACK_ENDPOINT=yP;ZI.DEFAULT_USE_FIPS_ENDPOINT=dP;ZI.ENV_PROFILE=H$;ZI.ENV_USE_DUALSTACK_ENDPOINT=G1;ZI.ENV_USE_FIPS_ENDPOINT=R1;ZI.NODE_REGION_CONFIG_FILE_OPTIONS=rP;ZI.NODE_REGION_CONFIG_OPTIONS=S$;ZI.NODE_USE_DUALSTACK_ENDPOINT_CONFIG_OPTIONS=gP;ZI.NODE_USE_FIPS_ENDPOINT_CONFIG_OPTIONS=vP;ZI.ProviderError=u;ZI.REGION_ENV_NAME=F$;ZI.REGION_INI_NAME=z$;ZI.TokenProviderError=J1;ZI.booleanSelector=F;ZI.chain=L$;ZI.externalDataInterceptor=cP;ZI.fromStatic=x$;ZI.fromValue=W$;ZI.getHomeDir=U0;ZI.getProfileName=E$;ZI.getRegionInfo=wI;ZI.getSSOTokenFilepath=K$;ZI.getSSOTokenFromFile=DP;ZI.loadConfig=X1;ZI.loadSharedConfigFiles=f1;ZI.loadSsoSessionData=jP;ZI.memoize=Y1;ZI.nodeDualstackConfigSelectors=mP;ZI.nodeFipsConfigSelectors=nP;ZI.numberSelector=WP;ZI.parseKnownFiles=sP;ZI.readFile=x0;ZI.resolveCustomEndpointsConfig=tP;ZI.resolveDefaultsModeConfig=XI;ZI.resolveEndpointsConfig=uP;ZI.resolveRegionConfig=aP});var F0=y((yh)=>{var N1=C$(),s$=C0(),z0=D0(),L1=P0(),c$="AWS_ENDPOINT_URL",b$="endpoint_url",Ph=($)=>({environmentVariableSelector:(T)=>{let w=$.split(" ").map((h)=>h.toUpperCase()),P=T[[c$,...w].join("_")];if(P)return P;let I=T[c$];if(I)return I;return},configFileSelector:(T,w)=>{if(w&&T.services){let I=w[["services",T.services].join(N1.CONFIG_PREFIX_SEPARATOR)];if(I){let h=$.split(" ").map((A)=>A.toLowerCase()),U=I[[h.join("_"),b$].join(N1.CONFIG_PREFIX_SEPARATOR)];if(U)return U}}let P=T[b$];if(P)return P;return},default:void 0}),S0=async($)=>N1.loadConfig(Ph($??""))(),Ih=async($)=>{let T=$?.Bucket||"";if(typeof $.Bucket==="string")$.Bucket=T.replace(/#/g,encodeURIComponent("#")).replace(/\?/g,encodeURIComponent("?"));if(Mh(T)){if($.ForcePathStyle===!0)throw Error("Path-style addressing cannot be used with ARN buckets")}else if(!_h(T)||T.indexOf(".")!==-1&&!String($.Endpoint).startsWith("http:")||T.toLowerCase()!==T||T.length<3)$.ForcePathStyle=!0;if($.DisableMultiRegionAccessPoints)$.disableMultiRegionAccessPoints=!0,$.DisableMRAP=!0;return $},hh=/^[a-z0-9][a-z0-9\.\-]{1,61}[a-z0-9]$/,Uh=/(\d+\.){3}\d+/,Ah=/\.\./,_h=($)=>hh.test($)&&!Uh.test($)&&!Ah.test($),Mh=($)=>{let[T,w,P,,,I]=$.split(":"),h=T==="arn"&&$.split(":").length>=6,U=Boolean(h&&w&&P&&I);if(h&&!U)throw Error(`Invalid ARN: ${$} was an invalid ARN.`);return U},Xh=($,T,w,P=!1)=>{let I=async()=>{let h;if(P)h=w.clientContextParams?.[$]??w[$]??w[T];else h=w[$]??w[T];if(typeof h==="function")return h();return h};if($==="credentialScope"||T==="CredentialScope")return async()=>{let h=typeof w.credentials==="function"?await w.credentials():w.credentials;return h?.credentialScope??h?.CredentialScope};if($==="accountId"||T==="AccountId")return async()=>{let h=typeof w.credentials==="function"?await w.credentials():w.credentials;return h?.accountId??h?.AccountId};if($==="endpoint"||T==="endpoint")return async()=>{if(w.isCustomEndpoint===!1)return;let h=await I();if(h&&typeof h==="object"){if("url"in h)return h.url.href;if("hostname"in h){let{protocol:U,hostname:A,port:_,path:M}=h;return`${U}//${A}${_?":"+_:""}${M}`}}return h};return I},j0=($)=>{if(typeof $==="object"){if("url"in $){let T=s$.parseUrl($.url);if($.headers){T.headers={};for(let w in $.headers)T.headers[w.toLowerCase()]=$.headers[w].join(", ")}return T}return $}return s$.parseUrl($)};function k$($){return async(T,w,P,I)=>{if(!P.isCustomEndpoint){let A;if(P.serviceConfiguredEndpoint)A=await P.serviceConfiguredEndpoint();else A=await $(P.serviceId);if(A)P.endpoint=()=>Promise.resolve(j0(A)),P.isCustomEndpoint=!0}let h=await p$(T,w,P);if(typeof P.endpointProvider!=="function")throw Error("config.endpointProvider is not set.");let U=P.endpointProvider(h,I);if(P.isCustomEndpoint&&P.endpoint){let A=await P.endpoint();if(A?.headers){U.headers??={};for(let[_,M]of Object.entries(A.headers))U.headers[_]=Array.isArray(M)?M:[M]}}return U}}var p$=async($,T,w)=>{let P={},I=T?.getEndpointParameterInstructions?.()||{};for(let[h,U]of Object.entries(I))switch(U.type){case"staticContextParams":P[h]=U.value;break;case"contextParams":P[h]=$[U.name];break;case"clientContextParams":case"builtInParams":P[h]=await Xh(U.name,h,w,U.type!=="builtInParams")();break;case"operationContextParams":P[h]=U.get($);break;default:throw Error("Unrecognized endpoint parameter instruction: "+JSON.stringify(U))}if(Object.keys(I).length===0)Object.assign(P,w);if(String(w.serviceId).toLowerCase()==="s3")await Ih(P);return P};function Jh($,T,w){if(!$.__smithy_context)$.__smithy_context={features:{}};else if(!$.__smithy_context.features)$.__smithy_context.features={};$.__smithy_context.features[T]=w}function y$($){let T=k$($);return({config:w,instructions:P})=>{return(I,h)=>async(U)=>{if(w.isCustomEndpoint)Jh(h,"ENDPOINT_OVERRIDE","N");let A=await T(U.input,{getEndpointParameterInstructions(){return P}},{...w},h);h.endpointV2=A,h.authSchemes=A.properties?.authSchemes;let _=h.authSchemes?.[0];if(_){h.signing_region=_.signingRegion,h.signing_service=_.signingName;let Y=z0.getSmithyContext(h)?.selectedHttpAuthScheme?.httpAuthOption;if(Y)Y.signingProperties=Object.assign(Y.signingProperties||{},{signing_region:_.signingRegion,signingRegion:_.signingRegion,signing_service:_.signingName,signingName:_.signingName,signingRegionSet:_.signingRegionSet},_.properties)}return I({...U})}}}var Yh={name:"serializerMiddleware"},g$={step:"serialize",tags:["ENDPOINT_PARAMETERS","ENDPOINT_V2","ENDPOINT"],name:"endpointV2Middleware",override:!0,relation:"before",toMiddleware:Yh.name};function fh($){let T=y$($);return(w,P)=>({applyToStack:(I)=>{I.addRelativeTo(T({config:w,instructions:P}),g$)}})}function Gh($){return(T)=>{let w=T.tls??!0,{endpoint:P,useDualstackEndpoint:I,useFipsEndpoint:h}=T,U=P!=null?async()=>j0(await z0.normalizeProvider(P)()):void 0,_=Object.assign(T,{endpoint:U,tls:w,isCustomEndpoint:!!P,useDualstackEndpoint:z0.normalizeProvider(I??!1),useFipsEndpoint:z0.normalizeProvider(h??!1)}),M=void 0;return _.serviceConfiguredEndpoint=async()=>{if(T.serviceId&&!M)M=$(T.serviceId);return M},_}}class W1{nodes;root;conditions;results;constructor($,T,w,P){this.nodes=$,this.root=T,this.conditions=w,this.results=P}static from($,T,w,P){return new W1($,T,w,P)}}class m${capacity;data=new Map;parameters=[];constructor({size:$,params:T}){if(this.capacity=$??50,T)this.parameters=T}get($,T){let w=this.hash($);if(w===!1)return T();if(!this.data.has(w)){if(this.data.size>this.capacity+10){let P=this.data.keys(),I=0;while(!0){let{value:h,done:U}=P.next();if(this.data.delete(h),U||++I>10)break}}this.data.set(w,T())}return this.data.get(w)}size(){return this.data.size}hash($){let T="",{parameters:w}=this;if(w.length===0)return!1;for(let P of w){let I=String($[P]??"");if(I.includes("|;"))return!1;T+=I+"|;"}return T}}class N extends Error{constructor($){super($);this.name="EndpointError"}}var A0="endpoints";function k($){if(typeof $!=="object"||$==null)return $;if("ref"in $)return`$${k($.ref)}`;if("fn"in $)return`${$.fn}(${($.argv||[]).map(k).join(", ")})`;return JSON.stringify($,null,2)}var d$={},Zh=($,T)=>$===T;function Rh(...$){for(let T of $)if(T!=null)return T;return}var Qh=($)=>{let T=$.split("."),w=[];for(let P of T){let I=P.indexOf("[");if(I!==-1){if(P.indexOf("]")!==P.length-1)throw new N(`Path: '${$}' does not end with ']'`);let h=P.slice(I+1,-1);if(Number.isNaN(parseInt(h)))throw new N(`Invalid array index: '${h}' in path: '${$}'`);if(I!==0)w.push(P.slice(0,I));w.push(h)}else w.push(P)}return w},v$=($,T)=>Qh(T).reduce((w,P)=>{if(typeof w!=="object")throw new N(`Index '${P}' in '${T}' not found in '${JSON.stringify($)}'`);else if(Array.isArray(w)){let I=parseInt(P);return w[I<0?w.length+I:I]}return w[P]},$),Vh=($)=>$!=null,Oh=new RegExp("^(?!.*-$)(?!-)[a-zA-Z0-9-]{1,63}$"),H1=($,T=!1)=>{if(!T)return Oh.test($);let w=$.split(".");for(let P of w)if(!H1(P))return!1;return!0};function Nh($,T,w){return $?T:w}var Lh=($)=>!$,Wh=new RegExp("^(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)(?:\\.(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)){3}$"),n$=($)=>Wh.test($)||$.startsWith("[")&&$.endsWith("]"),V1={[L1.EndpointURLScheme.HTTP]:80,[L1.EndpointURLScheme.HTTPS]:443},Hh=($)=>{let T=(()=>{try{if($ instanceof URL)return $;if(typeof $==="object"&&"hostname"in $){let{hostname:J,port:f,protocol:G="",path:Q="",query:Z={}}=$,R=new URL(`${G}//${J}${f?`:${f}`:""}${Q}`);return R.search=Object.entries(Z).map(([V,L])=>`${V}=${L}`).join("&"),R}return new URL($)}catch(J){return null}})();if(!T)return console.error(`Unable to parse ${JSON.stringify($)} as a whatwg URL.`),null;let w=T.href,{host:P,hostname:I,pathname:h,protocol:U,search:A}=T;if(A)return null;let _=U.slice(0,-1);if(!Object.values(L1.EndpointURLScheme).includes(_))return null;let M=n$(I),Y=w.includes(`${P}:${V1[_]}`)||typeof $==="string"&&$.includes(`${P}:${V1[_]}`),X=`${P}${Y?`:${V1[_]}`:""}`;return{scheme:_,authority:X,path:h,normalizedPath:h.endsWith("/")?h:`${h}/`,isIp:M}};function Dh($,T,w){if(w===1)return[$];if($==="")return[""];let P=$.split(T);if(w===0)return P;return P.slice(0,w-1).concat(P.slice(1).join(T))}var Eh=($,T)=>$===T,Kh=($,T,w,P)=>{if($==null||T>=w||$.length<w||/[^\u0000-\u007f]/.test($))return null;if(!P)return $.substring(T,w);return $.substring($.length-w,$.length-T)},Bh=($)=>encodeURIComponent($).replace(/[!*'()]/g,(T)=>`%${T.charCodeAt(0).toString(16).toUpperCase()}`),qh={booleanEquals:Zh,coalesce:Rh,getAttr:v$,isSet:Vh,isValidHostLabel:H1,ite:Nh,not:Lh,parseURL:Hh,split:Dh,stringEquals:Eh,substring:Kh,uriEncode:Bh},t$=($,T)=>{let w=[],{referenceRecord:P,endpointParams:I}=T,h=0;while(h<$.length){let U=$.indexOf("{",h);if(U===-1){w.push($.slice(h));break}w.push($.slice(h,U));let A=$.indexOf("}",U);if(A===-1){w.push($.slice(U));break}if($[U+1]==="{"&&$[A+1]==="}")w.push($.slice(U+1,A)),h=A+2;let _=$.substring(U+1,A);if(_.includes("#")){let[M,Y]=_.split("#");w.push(v$(P[M]??I[M],Y))}else w.push(P[_]??I[_]);h=A+1}return w.join("")},xh=({ref:$},T)=>{return T.referenceRecord[$]??T.endpointParams[$]},_0=($,T,w)=>{if(typeof $==="string")return t$($,w);else if($.fn)return u$.callFunction($,w);else if($.ref)return xh($,w);throw new N(`'${T}': ${String($)} is not a string, function or reference.`)},i$=({fn:$,argv:T},w)=>{let P=Array(T.length);for(let U=0;U<P.length;++U){let A=T[U];if(typeof A==="boolean"||typeof A==="number")P[U]=A;else P[U]=u$.evaluateExpression(A,"arg",w)}let I=$.indexOf(".");if(I!==-1){let A=d$[$.slice(0,I)]?.[$.slice(I+1)];if(typeof A==="function")return A(...P)}let h=qh[$];if(typeof h==="function")return h(...P);throw Error(`function ${$} not loaded in endpointFunctions.`)},u$={evaluateExpression:_0,callFunction:i$},r$=($,T)=>{let{assign:w}=$;if(w&&w in T.referenceRecord)throw new N(`'${w}' is already defined in Reference Record.`);let P=i$($,T);T.logger?.debug?.(`${A0} evaluateCondition: ${k($)} = ${k(P)}`);let I=P===""?!0:!!P;if(w!=null)return{result:I,toAssign:{name:w,value:P}};return{result:I}},l$=($,T)=>Object.entries($??{}).reduce((w,[P,I])=>{return w[P]=I.map((h)=>{let U=_0(h,"Header value entry",T);if(typeof U!=="string")throw new N(`Header '${P}' value '${U}' is not a string`);return U}),w},{}),D1=($,T)=>Object.entries($).reduce((w,[P,I])=>{return w[P]=a$.getEndpointProperty(I,T),w},{}),o$=($,T)=>{if(Array.isArray($))return $.map((w)=>o$(w,T));switch(typeof $){case"string":return t$($,T);case"object":if($===null)throw new N(`Unexpected endpoint property: ${$}`);return a$.getEndpointProperties($,T);case"boolean":return $;default:throw new N(`Unexpected endpoint property type: ${typeof $}`)}},a$={getEndpointProperty:o$,getEndpointProperties:D1},e$=($,T)=>{let w=_0($,"Endpoint URL",T);if(typeof w==="string")try{return new URL(w)}catch(P){throw console.error(`Failed to construct URL with ${w}`,P),P}throw new N(`Endpoint URL must be a string, got ${typeof w}`)},O1=1e8,Fh=($,T)=>{let{nodes:w,root:P,results:I,conditions:h}=$,U=P,A={},_={referenceRecord:A,endpointParams:T.endpointParams,logger:T.logger};while(U!==1&&U!==-1&&U<O1){let M=3*(Math.abs(U)-1),[Y,X,J]=[w[M],w[M+1],w[M+2]],[f,G,Q]=h[Y],Z=r$({fn:f,assign:Q,argv:G},_);if(Z.toAssign){let{name:R,value:V}=Z.toAssign;A[R]=V}U=U>=0===Z.result?X:J}if(U>=O1){let M=I[U-O1];if(M[0]===-1){let[,f]=M;throw new N(_0(f,"Error",_))}let[Y,X,J]=M;return{url:e$(Y,_),properties:D1(X,_),headers:l$(J??{},_)}}throw new N("No matching endpoint.")},E1=($=[],T)=>{let w={},P={...T,referenceRecord:{...T.referenceRecord}},I=!1;for(let h of $){let{result:U,toAssign:A}=r$(h,P);if(!U)return{result:U};if(A)I=!0,w[A.name]=A.value,P.referenceRecord[A.name]=A.value,T.logger?.debug?.(`${A0} assign: ${A.name} := ${k(A.value)}`)}if(I)return{result:!0,referenceRecord:w};return{result:!0}},zh=($,T)=>{let{conditions:w,endpoint:P}=$,{result:I,referenceRecord:h}=E1(w,T);if(!I)return;let U=h?{...T,referenceRecord:{...T.referenceRecord,...h}}:T,{url:A,properties:_,headers:M}=P;T.logger?.debug?.(`${A0} Resolving endpoint from template: ${k(P)}`);let Y={url:e$(A,U)};if(M!=null)Y.headers=l$(M,U);if(_!=null)Y.properties=D1(_,U);return Y},Sh=($,T)=>{let{conditions:w,error:P}=$,{result:I,referenceRecord:h}=E1(w,T);if(!I)return;let U=h?{...T,referenceRecord:{...T.referenceRecord,...h}}:T;throw new N(_0(P,"Error",U))},$T=($,T)=>{for(let w of $)if(w.type==="endpoint"){let P=zh(w,T);if(P)return P}else if(w.type==="error")Sh(w,T);else if(w.type==="tree"){let P=TT.evaluateTreeRule(w,T);if(P)return P}else throw new N(`Unknown endpoint rule: ${w}`);throw new N("Rules evaluation failed")},jh=($,T)=>{let{conditions:w,rules:P}=$,{result:I,referenceRecord:h}=E1(w,T);if(!I)return;let U=h?{...T,referenceRecord:{...T.referenceRecord,...h}}:T;return TT.evaluateRules(P,U)},TT={evaluateRules:$T,evaluateTreeRule:jh},Ch=($,T)=>{let{endpointParams:w,logger:P}=T,{parameters:I,rules:h}=$;T.logger?.debug?.(`${A0} Initial EndpointParams: ${k(w)}`);for(let A in I){let _=I[A],M=w[A];if(M==null&&_.default!=null){w[A]=_.default;continue}if(_.required&&M==null)throw new N(`Missing required parameter: '${A}'`)}let U=$T(h,{endpointParams:w,logger:P,referenceRecord:{}});return T.logger?.debug?.(`${A0} Resolved endpoint: ${k(U)}`),U},sh=($)=>{let{endpoint:T}=$;if(T===void 0)$.endpoint=async()=>{throw Error("@smithy/middleware-endpoint: (default endpointRuleSet) endpoint is not set - you must configure an endpoint.")};return $},ch=k$(S0),bh=Gh(S0),kh=y$(S0),ph=fh(S0);yh.BinaryDecisionDiagram=W1;yh.EndpointCache=m$;yh.EndpointError=N;yh.customEndpointFunctions=d$;yh.decideEndpoint=Fh;yh.endpointMiddleware=kh;yh.endpointMiddlewareOptions=g$;yh.getEndpointFromInstructions=ch;yh.getEndpointPlugin=ph;yh.isIpAddress=n$;yh.isValidHostLabel=H1;yh.middlewareEndpointToEndpointV1=j0;yh.resolveEndpoint=Ch;yh.resolveEndpointConfig=bh;yh.resolveEndpointRequiredConfig=sh;yh.resolveParams=p$;yh.toEndpointV1=j0});var ST=y((DA)=>{var K1=b("node:fs"),IU=C0(),hU=F0(),wT=b("node:crypto"),q=b("node:stream"),UU=($,T,w=(P)=>P)=>$,AU=($)=>{switch($){case"true":return!0;case"false":return!1;default:throw Error(`Unable to parse boolean value "${$}"`)}},_U=($)=>{if($===null||$===void 0)return;if(typeof $==="number"){if($===0||$===1)f0.warn(c0(`Expected boolean, got ${typeof $}: ${$}`));if($===0)return!1;if($===1)return!0}if(typeof $==="string"){let T=$.toLowerCase();if(T==="false"||T==="true")f0.warn(c0(`Expected boolean, got ${typeof $}: ${$}`));if(T==="false")return!1;if(T==="true")return!0}if(typeof $==="boolean")return $;throw TypeError(`Expected boolean, got ${typeof $}: ${$}`)},J0=($)=>{if($===null||$===void 0)return;if(typeof $==="string"){let T=parseFloat($);if(!Number.isNaN(T)){if(String(T)!==String($))f0.warn(c0(`Expected number but observed string: ${$}`));return T}}if(typeof $==="number")return $;throw TypeError(`Expected number, got ${typeof $}: ${$}`)},MU=Math.ceil(340282346638528860000000000000000000000),s0=($)=>{let T=J0($);if(T!==void 0&&!Number.isNaN(T)&&T!==1/0&&T!==-1/0){if(Math.abs(T)>MU)throw TypeError(`Expected 32-bit float, got ${$}`)}return T},Y0=($)=>{if($===null||$===void 0)return;if(Number.isInteger($)&&!Number.isNaN($))return $;throw TypeError(`Expected integer, got ${typeof $}: ${$}`)},XU=Y0,x1=($)=>j1($,32),F1=($)=>j1($,16),z1=($)=>j1($,8),j1=($,T)=>{let w=Y0($);if(w!==void 0&&JU(w,T)!==w)throw TypeError(`Expected ${T}-bit integer, got ${$}`);return w},JU=($,T)=>{switch(T){case 32:return Int32Array.of($)[0];case 16:return Int16Array.of($)[0];case 8:return Int8Array.of($)[0]}},YU=($,T)=>{if($===null||$===void 0){if(T)throw TypeError(`Expected a non-null value for ${T}`);throw TypeError("Expected a non-null value")}return $},MT=($)=>{if($===null||$===void 0)return;if(typeof $==="object"&&!Array.isArray($))return $;let T=Array.isArray($)?"array":typeof $;throw TypeError(`Expected object, got ${T}: ${$}`)},fU=($)=>{if($===null||$===void 0)return;if(typeof $==="string")return $;if(["boolean","number","bigint"].includes(typeof $))return f0.warn(c0(`Expected string, got ${typeof $}: ${$}`)),String($);throw TypeError(`Expected string, got ${typeof $}: ${$}`)},GU=($)=>{if($===null||$===void 0)return;let T=MT($),w=[];for(let P in T)if(T[P]!=null)w.push(P);if(w.length===0)throw TypeError("Unions must have exactly one non-null member. None were found.");if(w.length>1)throw TypeError(`Unions must have exactly one non-null member. Keys ${w} were not null.`);return T},C1=($)=>{if(typeof $=="string")return J0(e($));return J0($)},ZU=C1,XT=($)=>{if(typeof $=="string")return s0(e($));return s0($)},RU=/(-?(?:0|[1-9]\d*)(?:\.\d+)?(?:[eE][+-]?\d+)?)|(-?Infinity)|(NaN)/g,e=($)=>{let T=$.match(RU);if(T===null||T[0].length!==$.length)throw TypeError("Expected real number, got implicit NaN");return parseFloat($)},s1=($)=>{if(typeof $=="string")return JT($);return J0($)},QU=s1,VU=s1,OU=($)=>{if(typeof $=="string")return JT($);return s0($)},JT=($)=>{switch($){case"NaN":return NaN;case"Infinity":return 1/0;case"-Infinity":return-1/0;default:throw Error(`Unable to parse float value: ${$}`)}},YT=($)=>{if(typeof $==="string")return Y0(e($));return Y0($)},NU=YT,LU=($)=>{if(typeof $==="string")return x1(e($));return x1($)},l=($)=>{if(typeof $==="string")return F1(e($));return F1($)},fT=($)=>{if(typeof $==="string")return z1(e($));return z1($)},c0=($)=>{return String(TypeError($).stack||$).split(`
2
+ `).slice(0,5).filter((T)=>!T.includes("stackTraceWarning")).join(`
3
+ `)},f0={warn:console.warn},WU=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],c1=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function HU($){let T=$.getUTCFullYear(),w=$.getUTCMonth(),P=$.getUTCDay(),I=$.getUTCDate(),h=$.getUTCHours(),U=$.getUTCMinutes(),A=$.getUTCSeconds(),_=I<10?`0${I}`:`${I}`,M=h<10?`0${h}`:`${h}`,Y=U<10?`0${U}`:`${U}`,X=A<10?`0${A}`:`${A}`;return`${WU[P]}, ${_} ${c1[w]} ${T} ${M}:${Y}:${X} GMT`}var DU=new RegExp(/^(\d{4})-(\d{2})-(\d{2})[tT](\d{2}):(\d{2}):(\d{2})(?:\.(\d+))?[zZ]$/),EU=($)=>{if($===null||$===void 0)return;if(typeof $!=="string")throw TypeError("RFC-3339 date-times must be expressed as strings");let T=DU.exec($);if(!T)throw TypeError("Invalid RFC-3339 date-time value");let[w,P,I,h,U,A,_,M]=T,Y=l(o(P)),X=x(I,"month",1,12),J=x(h,"day",1,31);return M0(Y,X,J,{hours:U,minutes:A,seconds:_,fractionalMilliseconds:M})},KU=new RegExp(/^(\d{4})-(\d{2})-(\d{2})[tT](\d{2}):(\d{2}):(\d{2})(?:\.(\d+))?(([-+]\d{2}\:\d{2})|[zZ])$/),BU=($)=>{if($===null||$===void 0)return;if(typeof $!=="string")throw TypeError("RFC-3339 date-times must be expressed as strings");let T=KU.exec($);if(!T)throw TypeError("Invalid RFC-3339 date-time value");let[w,P,I,h,U,A,_,M,Y]=T,X=l(o(P)),J=x(I,"month",1,12),f=x(h,"day",1,31),G=M0(X,J,f,{hours:U,minutes:A,seconds:_,fractionalMilliseconds:M});if(Y.toUpperCase()!="Z")G.setTime(G.getTime()-yU(Y));return G},qU=new RegExp(/^(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d{2}) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? GMT$/),xU=new RegExp(/^(?:Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday), (\d{2})-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d{2}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? GMT$/),FU=new RegExp(/^(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( [1-9]|\d{2}) (\d{1,2}):(\d{2}):(\d{2})(?:\.(\d+))? (\d{4})$/),zU=($)=>{if($===null||$===void 0)return;if(typeof $!=="string")throw TypeError("RFC-7231 date-times must be expressed as strings");let T=qU.exec($);if(T){let[w,P,I,h,U,A,_,M]=T;return M0(l(o(h)),B1(I),x(P,"day",1,31),{hours:U,minutes:A,seconds:_,fractionalMilliseconds:M})}if(T=xU.exec($),T){let[w,P,I,h,U,A,_,M]=T;return sU(M0(jU(h),B1(I),x(P,"day",1,31),{hours:U,minutes:A,seconds:_,fractionalMilliseconds:M}))}if(T=FU.exec($),T){let[w,P,I,h,U,A,_,M]=T;return M0(l(o(M)),B1(P),x(I.trimLeft(),"day",1,31),{hours:h,minutes:U,seconds:A,fractionalMilliseconds:_})}throw TypeError("Invalid RFC-7231 date-time value")},SU=($)=>{if($===null||$===void 0)return;let T;if(typeof $==="number")T=$;else if(typeof $==="string")T=C1($);else if(typeof $==="object"&&$.tag===1)T=$.value;else throw TypeError("Epoch timestamps must be expressed as floating point numbers or their string representation");if(Number.isNaN(T)||T===1/0||T===-1/0)throw TypeError("Epoch timestamps must be valid, non-Infinite, non-NaN numerics");return new Date(Math.round(T*1000))},M0=($,T,w,P)=>{let I=T-1;return bU($,I,w),new Date(Date.UTC($,I,w,x(P.hours,"hour",0,23),x(P.minutes,"minute",0,59),x(P.seconds,"seconds",0,60),pU(P.fractionalMilliseconds)))},jU=($)=>{let T=new Date().getUTCFullYear(),w=Math.floor(T/100)*100+l(o($));if(w<T)return w+100;return w},CU=1576800000000,sU=($)=>{if($.getTime()-new Date().getTime()>CU)return new Date(Date.UTC($.getUTCFullYear()-100,$.getUTCMonth(),$.getUTCDate(),$.getUTCHours(),$.getUTCMinutes(),$.getUTCSeconds(),$.getUTCMilliseconds()));return $},B1=($)=>{let T=c1.indexOf($);if(T<0)throw TypeError(`Invalid month: ${$}`);return T+1},cU=[31,28,31,30,31,30,31,31,30,31,30,31],bU=($,T,w)=>{let P=cU[T];if(T===1&&kU($))P=29;if(w>P)throw TypeError(`Invalid day for ${c1[T]} in ${$}: ${w}`)},kU=($)=>{return $%4===0&&($%100!==0||$%400===0)},x=($,T,w,P)=>{let I=fT(o($));if(I<w||I>P)throw TypeError(`${T} must be between ${w} and ${P}, inclusive`);return I},pU=($)=>{if($===null||$===void 0)return 0;return XT("0."+$)*1000},yU=($)=>{let T=$[0],w=1;if(T=="+")w=1;else if(T=="-")w=-1;else throw TypeError(`Offset direction, ${T}, must be "+" or "-"`);let P=Number($.substring(1,3)),I=Number($.substring(4,6));return w*(P*60+I)*60*1000},o=($)=>{let T=0;while(T<$.length-1&&$.charAt(T)==="0")T++;if(T===0)return $;return $.slice(T)},PT=typeof crypto<"u"&&typeof crypto.randomUUID==="function"?crypto.randomUUID.bind(crypto):void 0,H=Array.from({length:256},($,T)=>T.toString(16).padStart(2,"0")),GT=()=>{if(PT)return PT();let $=new Uint8Array(16);return crypto.getRandomValues($),$[6]=$[6]&15|64,$[8]=$[8]&63|128,H[$[0]]+H[$[1]]+H[$[2]]+H[$[3]]+"-"+H[$[4]]+H[$[5]]+"-"+H[$[6]]+H[$[7]]+"-"+H[$[8]]+H[$[9]]+"-"+H[$[10]]+H[$[11]]+H[$[12]]+H[$[13]]+H[$[14]]+H[$[15]]},v=function(T){return Object.assign(new String(T),{deserializeJSON(){return JSON.parse(String(T))},toString(){return String(T)},toJSON(){return String(T)}})};v.from=($)=>{if($&&typeof $==="object"&&($ instanceof v||("deserializeJSON"in $)))return $;else if(typeof $==="string"||Object.getPrototypeOf($)===String.prototype)return v(String($));return v(JSON.stringify($))};v.fromObject=v.from;function gU($){if($.includes(",")||$.includes('"'))$=`"${$.replace(/"/g,"\\\"")}"`;return $}var b1="(?:Mon|Tue|Wed|Thu|Fri|Sat|Sun)(?:[ne|u?r]?s?day)?",k1="(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)",p1="(\\d?\\d):(\\d{2}):(\\d{2})(?:\\.(\\d+))?",ZT="(\\d?\\d)",RT="(\\d{4})",mU=new RegExp(/^(\d{4})-(\d\d)-(\d\d)[tT](\d\d):(\d\d):(\d\d)(\.(\d+))?(([-+]\d\d:\d\d)|[zZ])$/),dU=new RegExp(`^${b1}, ${ZT} ${k1} ${RT} ${p1} GMT$`),vU=new RegExp(`^${b1}, ${ZT}-${k1}-(\\d\\d) ${p1} GMT$`),nU=new RegExp(`^${b1} ${k1} ( [1-9]|\\d\\d) ${p1} ${RT}$`),tU=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],iU=($)=>{if($==null)return;let T=NaN;if(typeof $==="number")T=$;else if(typeof $==="string"){if(!/^-?\d*\.?\d+$/.test($))throw TypeError("parseEpochTimestamp - numeric string invalid.");T=Number.parseFloat($)}else if(typeof $==="object"&&$.tag===1)T=$.value;if(isNaN(T)||Math.abs(T)===1/0)throw TypeError("Epoch timestamps must be valid finite numbers.");return new Date(Math.round(T*1000))},uU=($)=>{if($==null)return;if(typeof $!=="string")throw TypeError("RFC3339 timestamps must be strings");let T=mU.exec($);if(!T)throw TypeError(`Invalid RFC3339 timestamp format ${$}`);let[,w,P,I,h,U,A,,_,M]=T;z(P,1,12),z(I,1,31),z(h,0,23),z(U,0,59),z(A,0,60);let Y=new Date(Date.UTC(Number(w),Number(P)-1,Number(I),Number(h),Number(U),Number(A),Number(_)?Math.round(parseFloat(`0.${_}`)*1000):0));if(Y.setUTCFullYear(Number(w)),M.toUpperCase()!="Z"){let[,X,J,f]=/([+-])(\d\d):(\d\d)/.exec(M)||[void 0,"+",0,0],G=X==="-"?1:-1;Y.setTime(Y.getTime()+G*(Number(J)*60*60*1000+Number(f)*60*1000))}return Y},rU=($)=>{if($==null)return;if(typeof $!=="string")throw TypeError("RFC7231 timestamps must be strings.");let T,w,P,I,h,U,A,_;if(_=dU.exec($))[,T,w,P,I,h,U,A]=_;else if(_=vU.exec($))[,T,w,P,I,h,U,A]=_,P=(Number(P)+1900).toString();else if(_=nU.exec($))[,w,T,I,h,U,A,P]=_;if(P&&U){let M=Date.UTC(Number(P),tU.indexOf(w),Number(T),Number(I),Number(h),Number(U),A?Math.round(parseFloat(`0.${A}`)*1000):0);z(T,1,31),z(I,0,23),z(h,0,59),z(U,0,60);let Y=new Date(M);return Y.setUTCFullYear(Number(P)),Y}throw TypeError(`Invalid RFC7231 date-time value ${$}.`)};function z($,T,w){let P=Number($);if(P<T||P>w)throw Error(`Value ${P} out of range [${T}, ${w}]`)}function lU($,T,w){if(w<=0||!Number.isInteger(w))throw Error("Invalid number of delimiters ("+w+") for splitEvery.");let P=$.split(T);if(w===1)return P;let I=[],h="";for(let U=0;U<P.length;U++){if(h==="")h=P[U];else h+=T+P[U];if((U+1)%w===0)I.push(h),h=""}if(h!=="")I.push(h);return I}var oU=($)=>{let T=$.length,w=[],P=!1,I=void 0,h=0;for(let U=0;U<T;++U){let A=$[U];switch(A){case'"':if(I!=="\\")P=!P;break;case",":if(!P)w.push($.slice(h,U)),h=U+1;break}I=A}return w.push($.slice(h)),w.map((U)=>{U=U.trim();let A=U.length;if(A<2)return U;if(U[0]==='"'&&U[A-1]==='"')U=U.slice(1,A-1);return U.replace(/\\"/g,'"')})},IT=/^-?\d*(\.\d+)?$/;class k0{string;type;constructor($,T){if(this.string=$,this.type=T,!IT.test($))throw Error('@smithy/core/serde - NumericValue must only contain [0-9], at most one decimal point ".", and an optional negation prefix "-".')}toString(){return this.string}static[Symbol.hasInstance]($){if(!$||typeof $!=="object")return!1;let T=$;return k0.prototype.isPrototypeOf($)||T.type==="bigDecimal"&&IT.test(T.string)}}function aU($){return new k0(String($),"bigDecimal")}var QT={},S1={};for(let $=0;$<256;$++){let T=$.toString(16).toLowerCase();if(T.length===1)T=`0${T}`;QT[$]=T,S1[T]=$}function eU($){if($.length%2!==0)throw Error("Hex encoded strings must have an even number length");let T=new Uint8Array($.length/2);for(let w=0;w<$.length;w+=2){let P=$.slice(w,w+2).toLowerCase();if(P in S1)T[w/2]=S1[P];else throw Error(`Cannot decode unrecognized sequence ${P} as hexadecimal`)}return T}function VT($){let T="";for(let w=0;w<$.byteLength;w++)T+=QT[$[w]];return T}var OT=($)=>typeof ArrayBuffer==="function"&&$ instanceof ArrayBuffer||Object.prototype.toString.call($)==="[object ArrayBuffer]",a=($,T=0,w=$.byteLength-T)=>{if(!OT($))throw TypeError(`The "input" argument must be ArrayBuffer. Received type ${typeof $} (${$})`);return Buffer.from($,T,w)},p0=($,T)=>{if(typeof $!=="string")throw TypeError(`The "input" argument must be of type string. Received type ${typeof $} (${$})`);return T?Buffer.from($,T):Buffer.from($)},$A=/^[A-Za-z0-9+/]*={0,2}$/,y1=($)=>{if($.length*3%4!==0)throw TypeError("Incorrect padding on base64 string.");if(!$A.exec($))throw TypeError("Invalid base64 string.");let T=p0($,"base64");return new Uint8Array(T.buffer,T.byteOffset,T.byteLength)},y0=($)=>{let T=p0($,"utf8");return new Uint8Array(T.buffer,T.byteOffset,T.byteLength/Uint8Array.BYTES_PER_ELEMENT)},G0=($)=>{let T;if(typeof $==="string")T=y0($);else T=$;if(typeof T!=="object"||typeof T.byteOffset!=="number"||typeof T.byteLength!=="number")throw Error("@smithy/util-base64: toBase64 encoder function only accepts string | Uint8Array.");return a(T.buffer,T.byteOffset,T.byteLength).toString("base64")},TA=($)=>{if(!$)return 0;if(typeof $==="string")return Buffer.byteLength($);else if(typeof $.byteLength==="number")return $.byteLength;else if(typeof $.size==="number")return $.size;else if(typeof $.start==="number"&&typeof $.end==="number")return $.end+1-$.start;else if($ instanceof K1.ReadStream){if($.path!=null)return K1.lstatSync($.path).size;else if(typeof $.fd==="number")return K1.fstatSync($.fd).size}throw Error(`Body Length computation failed for ${$}`)},NT=($)=>{if(typeof $==="string")return y0($);if(ArrayBuffer.isView($))return new Uint8Array($.buffer,$.byteOffset,$.byteLength/Uint8Array.BYTES_PER_ELEMENT);return new Uint8Array($)},g1=($)=>{if(typeof $==="string")return $;if(typeof $!=="object"||typeof $.byteOffset!=="number"||typeof $.byteLength!=="number")throw Error("@smithy/util-utf8: toUtf8 encoder function only accepts string | Uint8Array.");return a($.buffer,$.byteOffset,$.byteLength).toString("utf8")},LT=($,T)=>(w,P)=>async(I)=>{let{response:h}=await w(I);try{let U=await T(h,$);return{response:h,output:U}}catch(U){if(Object.defineProperty(U,"$response",{value:h,enumerable:!1,writable:!1,configurable:!1}),!("$metadata"in U)){try{U.message+=`
4
+ Deserialization error: to see the raw response, inspect the hidden field {error}.$response on this object.`}catch(_){if(!P.logger||P.logger?.constructor?.name==="NoOpLogger")console.warn("Deserialization error: to see the raw response, inspect the hidden field {error}.$response on this object.");else P.logger?.warn?.("Deserialization error: to see the raw response, inspect the hidden field {error}.$response on this object.")}if(typeof U.$responseBodyText<"u"){if(U.$response)U.$response.body=U.$responseBodyText}try{if(IU.HttpResponse.isInstance(h)){let{headers:_={}}=h,M=Object.entries(_);U.$metadata={httpStatusCode:h.statusCode,requestId:q1(/^x-[\w-]+-request-?id$/,M),extendedRequestId:q1(/^x-[\w-]+-id-2$/,M),cfId:q1(/^x-[\w-]+-cf-id$/,M)}}}catch(_){}}throw U}},q1=($,T)=>{return(T.find(([w])=>{return w.match($)})||[void 0,void 0])[1]},WT=($,T)=>(w,P)=>async(I)=>{let h=$,U=P.endpointV2?async()=>hU.toEndpointV1(P.endpointV2):h.endpoint;if(!U)throw Error("No valid endpoint provider available.");let A=await T(I.input,{...$,endpoint:U});return w({...I,request:A})},HT={name:"deserializerMiddleware",step:"deserialize",tags:["DESERIALIZER"],override:!0},DT={name:"serializerMiddleware",step:"serialize",tags:["SERIALIZER"],override:!0};function wA($,T,w){return{applyToStack:(P)=>{P.add(LT($,w),HT),P.add(WT($,T),DT)}}}class ET{algorithmIdentifier;secret;hash;constructor($,T){this.algorithmIdentifier=$,this.secret=T,this.reset()}update($,T){this.hash.update(NT(hT($,T)))}digest(){return Promise.resolve(this.hash.digest())}reset(){this.hash=this.secret?wT.createHmac(this.algorithmIdentifier,hT(this.secret)):wT.createHash(this.algorithmIdentifier)}}function hT($,T){if(Buffer.isBuffer($))return $;if(typeof $==="string")return p0($,T);if(ArrayBuffer.isView($))return a($.buffer,$.byteOffset,$.byteLength);return a($)}class X0 extends Uint8Array{static fromString($,T="utf-8"){if(typeof $==="string"){if(T==="base64")return X0.mutate(y1($));return X0.mutate(y0($))}throw Error(`Unsupported conversion from ${typeof $} to Uint8ArrayBlobAdapter.`)}static mutate($){return Object.setPrototypeOf($,X0.prototype),$}transformToString($="utf-8"){if($==="base64")return G0(this);return g1(this)}}var KT=class extends q.Duplex{expectedChecksum;checksumSourceLocation;checksum;source;base64Encoder;pendingCallback=null;constructor({expectedChecksum:T,checksum:w,source:P,checksumSourceLocation:I,base64Encoder:h}){super();if(typeof P.pipe==="function")this.source=P;else throw Error(`@smithy/util-stream: unsupported source type ${P?.constructor?.name??P} in ChecksumStream.`);this.base64Encoder=h??G0,this.expectedChecksum=T,this.checksum=w,this.checksumSourceLocation=I,this.source.pipe(this)}_read(T){if(this.pendingCallback){let w=this.pendingCallback;this.pendingCallback=null,w()}}_write(T,w,P){try{if(this.checksum.update(T),!this.push(T)){this.pendingCallback=P;return}}catch(I){return P(I)}return P()}async _final(T){try{let w=await this.checksum.digest(),P=this.base64Encoder(w);if(this.expectedChecksum!==P)return T(Error(`Checksum mismatch: expected "${this.expectedChecksum}" but received "${P}" in response header "${this.checksumSourceLocation}".`))}catch(w){return T(w)}return this.push(null),T()}},S=($)=>typeof ReadableStream==="function"&&($?.constructor?.name===ReadableStream.name||$ instanceof ReadableStream),BT=($)=>{return typeof Blob==="function"&&($?.constructor?.name===Blob.name||$ instanceof Blob)},PA=typeof ReadableStream==="function"?ReadableStream:function(){};class qT extends PA{}var IA=({expectedChecksum:$,checksum:T,source:w,checksumSourceLocation:P,base64Encoder:I})=>{if(!S(w))throw Error(`@smithy/util-stream: unsupported source type ${w?.constructor?.name??w} in ChecksumStream.`);let h=I??G0;if(typeof TransformStream!=="function")throw Error("@smithy/util-stream: unable to instantiate ChecksumStream because API unavailable: ReadableStream/TransformStream.");let U=new TransformStream({start(){},async transform(_,M){T.update(_),M.enqueue(_)},async flush(_){let M=await T.digest(),Y=h(M);if($!==Y){let X=Error(`Checksum mismatch: expected "${$}" but received "${Y}" in response header "${P}".`);_.error(X)}else _.terminate()}});w.pipeThrough(U);let A=U.readable;return Object.setPrototypeOf(A,qT.prototype),A};function hA($){if(typeof ReadableStream==="function"&&S($.source))return IA($);return new KT($)}class b0{allocByteArray;byteLength=0;byteArrays=[];constructor($){this.allocByteArray=$}push($){this.byteArrays.push($),this.byteLength+=$.byteLength}flush(){if(this.byteArrays.length===1){let w=this.byteArrays[0];return this.reset(),w}let $=this.allocByteArray(this.byteLength),T=0;for(let w=0;w<this.byteArrays.length;++w){let P=this.byteArrays[w];$.set(P,T),T+=P.byteLength}return this.reset(),$}reset(){this.byteArrays=[],this.byteLength=0}}function UA($,T,w){let P=$.getReader(),I=!1,h=0,U=["",new b0((M)=>new Uint8Array(M))],A=-1,_=async(M)=>{let{value:Y,done:X}=await P.read(),J=Y;if(X){if(A!==-1){let f=r(U,A);if(p(f)>0)M.enqueue(f)}M.close()}else{let f=FT(J,!1);if(A!==f){if(A>=0)M.enqueue(r(U,A));A=f}if(A===-1){M.enqueue(J);return}let G=p(J);h+=G;let Q=p(U[A]);if(G>=T&&Q===0)M.enqueue(J);else{let Z=xT(U,A,J);if(!I&&h>T*2)I=!0,w?.warn(`@smithy/util-stream - stream chunk size ${G} is below threshold of ${T}, automatically buffering.`);if(Z>=T)M.enqueue(r(U,A));else await _(M)}}};return new ReadableStream({pull:_})}function xT($,T,w){switch(T){case 0:return $[0]+=w,p($[0]);case 1:case 2:return $[T].push(w),p($[T])}}function r($,T){switch(T){case 0:let w=$[0];return $[0]="",w;case 1:case 2:return $[T].flush()}throw Error(`@smithy/util-stream - invalid index ${T} given to flush()`)}function p($){return $?.byteLength??$?.length??0}function FT($,T=!0){if(T&&typeof Buffer<"u"&&$ instanceof Buffer)return 2;if($ instanceof Uint8Array)return 1;if(typeof $==="string")return 0;return-1}function AA($,T,w){if(S($))return UA($,T,w);let P=new q.Readable({read(){}}),I=!1,h=0,U=["",new b0((_)=>new Uint8Array(_)),new b0((_)=>Buffer.from(new Uint8Array(_)))],A=-1;return $.on("data",(_)=>{let M=FT(_,!0);if(A!==M){if(A>=0)P.push(r(U,A));A=M}if(A===-1){P.push(_);return}let Y=p(_);h+=Y;let X=p(U[A]);if(Y>=T&&X===0)P.push(_);else{let J=xT(U,A,_);if(!I&&h>T*2)I=!0,w?.warn(`@smithy/util-stream - stream chunk size ${Y} is below threshold of ${T}, automatically buffering.`);if(J>=T)P.push(r(U,A))}}),$.on("end",()=>{if(A!==-1){let _=r(U,A);if(p(_)>0)P.push(_)}P.push(null)}),P}var _A=($,T)=>{let{base64Encoder:w,bodyLengthChecker:P,checksumAlgorithmFn:I,checksumLocationName:h,streamHasher:U}=T,A=w!==void 0&&P!==void 0&&I!==void 0&&h!==void 0&&U!==void 0,_=A?U(I,$):void 0,M=$.getReader();return new ReadableStream({async pull(Y){let{value:X,done:J}=await M.read();if(J){if(Y.enqueue(`0\r
5
+ `),A){let f=w(await _);Y.enqueue(`${h}:${f}\r
6
+ `),Y.enqueue(`\r
7
+ `)}Y.close()}else Y.enqueue(`${(P(X)||0).toString(16)}\r
8
+ ${X}\r
9
+ `)}})};function MA($,T){let w=$,P=$;if(S(P))return _A(P,T);let{base64Encoder:I,bodyLengthChecker:h,checksumAlgorithmFn:U,checksumLocationName:A,streamHasher:_}=T,M=I!==void 0&&U!==void 0&&A!==void 0&&_!==void 0,Y=M?_(U,w):void 0,X=new q.Readable({read:()=>{}});return w.on("data",(J)=>{let f=h(J)||0;if(f===0)return;X.push(`${f.toString(16)}\r
10
+ `),X.push(J),X.push(`\r
11
+ `)}),w.on("end",async()=>{if(X.push(`0\r
12
+ `),M){let J=I(await Y);X.push(`${A}:${J}\r
13
+ `),X.push(`\r
14
+ `)}X.push(null)}),X}async function XA($,T){let w=0,P=[],I=$.getReader(),h=!1;while(!h){let{done:_,value:M}=await I.read();if(M)P.push(M),w+=M?.byteLength??0;if(w>=T)break;h=_}I.releaseLock();let U=new Uint8Array(Math.min(T,w)),A=0;for(let _ of P){if(_.byteLength>U.byteLength-A){U.set(_.subarray(0,U.byteLength-A),A);break}else U.set(_,A);A+=_.length}return U}var JA=($,T)=>{if(S($))return XA($,T);return new Promise((w,P)=>{let I=new YA;I.limit=T,$.pipe(I),$.on("error",(h)=>{I.end(),P(h)}),I.on("error",P),I.on("finish",function(){let h=new Uint8Array(Buffer.concat(this.buffers));w(h)})})},YA=class extends q.Writable{buffers=[];limit=1/0;bytesBuffered=0;_write(T,w,P){if(this.buffers.push(T),this.bytesBuffered+=T.byteLength??0,this.bytesBuffered>=this.limit){let I=this.bytesBuffered-this.limit,h=this.buffers[this.buffers.length-1];this.buffers[this.buffers.length-1]=h.subarray(0,h.byteLength-I),this.emit("finish")}P()}},fA=async($)=>{if(typeof Blob==="function"&&$ instanceof Blob||$.constructor?.name==="Blob"){if(Blob.prototype.arrayBuffer!==void 0)return new Uint8Array(await $.arrayBuffer());return GA($)}return ZA($)};async function GA($){let T=await RA($),w=y1(T);return new Uint8Array(w)}async function ZA($){let T=[],w=$.getReader(),P=!1,I=0;while(!P){let{done:A,value:_}=await w.read();if(_)T.push(_),I+=_.length;P=A}let h=new Uint8Array(I),U=0;for(let A of T)h.set(A,U),U+=A.length;return h}function RA($){return new Promise((T,w)=>{let P=new FileReader;P.onloadend=()=>{if(P.readyState!==2)return w(Error("Reader aborted too early"));let I=P.result??"",h=I.indexOf(","),U=h>-1?h+1:I.length;T(I.substring(U))},P.onabort=()=>w(Error("Read aborted")),P.onerror=()=>w(P.error),P.readAsDataURL($)})}var UT="The stream has already been transformed.",QA=($)=>{if(!AT($)&&!S($)){let I=$?.__proto__?.constructor?.name||$;throw Error(`Unexpected stream implementation, expect Blob or ReadableStream, got ${I}`)}let T=!1,w=async()=>{if(T)throw Error(UT);return T=!0,await fA($)},P=(I)=>{if(typeof I.stream!=="function")throw Error(`Cannot transform payload Blob to web stream. Please make sure the Blob.stream() is polyfilled.
15
+ If you are using React Native, this API is not yet supported, see: https://react-native.canny.io/feature-requests/p/fetch-streaming-body`);return I.stream()};return Object.assign($,{transformToByteArray:w,transformToString:async(I)=>{let h=await w();if(I==="base64")return G0(h);else if(I==="hex")return VT(h);else if(I===void 0||I==="utf8"||I==="utf-8")return g1(h);else if(typeof TextDecoder==="function")return new TextDecoder(I).decode(h);else throw Error("TextDecoder is not available, please make sure polyfill is provided.")},transformToWebStream:()=>{if(T)throw Error(UT);if(T=!0,AT($))return P($);else if(S($))return $;else throw Error(`Cannot transform payload to web stream, got ${$}`)}})},AT=($)=>typeof Blob==="function"&&$ instanceof Blob;class zT extends q.Writable{bufferedBytes=[];_write($,T,w){this.bufferedBytes.push($),w()}}var VA=($)=>typeof ReadableStream==="function"&&$ instanceof ReadableStream;async function OA($){let T=[],w=$.getReader(),P=!1,I=0;while(!P){let{done:A,value:_}=await w.read();if(_)T.push(_),I+=_.length;P=A}let h=new Uint8Array(I),U=0;for(let A of T)h.set(A,U),U+=A.length;return h}var NA=($)=>{if(VA($))return OA($);return new Promise((T,w)=>{let P=new zT;$.pipe(P),$.on("error",(I)=>{P.end(),w(I)}),P.on("error",w),P.on("finish",function(){let I=new Uint8Array(Buffer.concat(this.bufferedBytes));T(I)})})},_T="The stream has already been transformed.",LA=($)=>{if(!($ instanceof q.Readable))try{return QA($)}catch(P){let I=$?.__proto__?.constructor?.name||$;throw Error(`Unexpected stream implementation, expect Stream.Readable instance, got ${I}`)}let T=!1,w=async()=>{if(T)throw Error(_T);return T=!0,await NA($)};return Object.assign($,{transformToByteArray:w,transformToString:async(P)=>{let I=await w();if(P===void 0||Buffer.isEncoding(P))return a(I.buffer,I.byteOffset,I.byteLength).toString(P);else return new TextDecoder(P).decode(I)},transformToWebStream:()=>{if(T)throw Error(_T);if($.readableFlowing!==null)throw Error("The stream has been consumed by other callbacks.");if(typeof q.Readable.toWeb!=="function")throw Error("Readable.toWeb() is not supported. Please ensure a polyfill is available.");return T=!0,q.Readable.toWeb($)}})};async function WA($){if(typeof $.stream==="function")$=$.stream();return $.tee()}async function HA($){if(S($)||BT($))return WA($);let T=new q.PassThrough,w=new q.PassThrough;return $.pipe(T),$.pipe(w),[T,w]}DA.ChecksumStream=KT;DA.Hash=ET;DA.LazyJsonString=v;DA.NumericValue=k0;DA.Uint8ArrayBlobAdapter=X0;DA._parseEpochTimestamp=iU;DA._parseRfc3339DateTimeWithOffset=uU;DA._parseRfc7231DateTime=rU;DA.calculateBodyLength=TA;DA.copyDocumentWithTransform=UU;DA.createBufferedReadable=AA;DA.createChecksumStream=hA;DA.dateToUtcString=HU;DA.deserializerMiddleware=LT;DA.deserializerMiddlewareOption=HT;DA.expectBoolean=_U;DA.expectByte=z1;DA.expectFloat32=s0;DA.expectInt=XU;DA.expectInt32=x1;DA.expectLong=Y0;DA.expectNonNull=YU;DA.expectNumber=J0;DA.expectObject=MT;DA.expectShort=F1;DA.expectString=fU;DA.expectUnion=GU;DA.fromArrayBuffer=a;DA.fromBase64=y1;DA.fromHex=eU;DA.fromString=p0;DA.fromUtf8=y0;DA.generateIdempotencyToken=GT;DA.getAwsChunkedEncodingStream=MA;DA.getSerdePlugin=wA;DA.handleFloat=QU;DA.headStream=JA;DA.isArrayBuffer=OT;DA.isBlob=BT;DA.isReadableStream=S;DA.limitedParseDouble=s1;DA.limitedParseFloat=VU;DA.limitedParseFloat32=OU;DA.logger=f0;DA.nv=aU;DA.parseBoolean=AU;DA.parseEpochTimestamp=SU;DA.parseRfc3339DateTime=EU;DA.parseRfc3339DateTimeWithOffset=BU;DA.parseRfc7231DateTime=zU;DA.quoteHeader=gU;DA.sdkStreamMixin=LA;DA.serializerMiddleware=WT;DA.serializerMiddlewareOption=DT;DA.splitEvery=lU;DA.splitHeader=oU;DA.splitStream=HA;DA.strictParseByte=fT;DA.strictParseDouble=C1;DA.strictParseFloat=ZU;DA.strictParseFloat32=XT;DA.strictParseInt=NU;DA.strictParseInt32=LU;DA.strictParseLong=YT;DA.strictParseShort=l;DA.toBase64=G0;DA.toHex=VT;DA.toUint8Array=NT;DA.toUtf8=g1;DA.v4=GT});var C0=y((o_)=>{var O=ST(),E=h1(),g_=P0(),n=async($=new Uint8Array,T)=>{if($ instanceof Uint8Array)return O.Uint8ArrayBlobAdapter.mutate($);if(!$)return O.Uint8ArrayBlobAdapter.mutate(new Uint8Array);let w=T.streamCollector($);return O.Uint8ArrayBlobAdapter.mutate(await w)};function R0($){return encodeURIComponent($).replace(/[!'()*]/g,function(T){return"%"+T.charCodeAt(0).toString(16).toUpperCase()})}class $0{serdeContext;setSerdeContext($){this.serdeContext=$}}class j{method;protocol;hostname;port;path;query;headers;username;password;fragment;body;constructor($){this.method=$.method||"GET",this.hostname=$.hostname||"localhost",this.port=$.port,this.query=$.query||{},this.headers=$.headers||{},this.body=$.body,this.protocol=$.protocol?$.protocol.slice(-1)!==":"?`${$.protocol}:`:$.protocol:"https:",this.path=$.path?$.path.charAt(0)!=="/"?`/${$.path}`:$.path:"/",this.username=$.username,this.password=$.password,this.fragment=$.fragment}static clone($){let T=new j({...$,headers:{...$.headers}});if(T.query)T.query=m_(T.query);return T}static isInstance($){if(!$)return!1;let T=$;return"method"in T&&"protocol"in T&&"hostname"in T&&"path"in T&&typeof T.query==="object"&&typeof T.headers==="object"}clone(){return j.clone(this)}}function m_($){return Object.keys($).reduce((T,w)=>{let P=$[w];return{...T,[w]:Array.isArray(P)?[...P]:P}},{})}class m1{statusCode;reason;headers;body;constructor($){this.statusCode=$.statusCode,this.reason=$.reason,this.headers=$.headers||{},this.body=$.body}static isInstance($){if(!$)return!1;let T=$;return typeof T.statusCode==="number"&&typeof T.headers==="object"}}class g0 extends $0{options;compositeErrorRegistry;constructor($){super();this.options=$,this.compositeErrorRegistry=E.TypeRegistry.for($.defaultNamespace);for(let T of $.errorTypeRegistries??[])this.compositeErrorRegistry.copyFrom(T)}getRequestType(){return j}getResponseType(){return m1}setSerdeContext($){if(this.serdeContext=$,this.serializer.setSerdeContext($),this.deserializer.setSerdeContext($),this.getPayloadCodec())this.getPayloadCodec().setSerdeContext($)}updateServiceEndpoint($,T){if("url"in T){if($.protocol=T.url.protocol,$.hostname=T.url.hostname,$.port=T.url.port?Number(T.url.port):void 0,$.path=T.url.pathname,$.fragment=T.url.hash||void 0,$.username=T.url.username||void 0,$.password=T.url.password||void 0,!$.query)$.query={};for(let[w,P]of T.url.searchParams.entries())$.query[w]=P;if(T.headers)for(let w in T.headers)$.headers[w]=T.headers[w].join(", ");return $}else{if($.protocol=T.protocol,$.hostname=T.hostname,$.port=T.port?Number(T.port):void 0,$.path=T.path,$.query={...T.query},T.headers)for(let w in T.headers)$.headers[w]=T.headers[w];return $}}setHostPrefix($,T,w){if(this.serdeContext?.disableHostPrefix)return;let P=E.NormalizedSchema.of(T.input),I=E.translateTraits(T.traits??{});if(I.endpoint){let h=I.endpoint?.[0];if(typeof h==="string"){for(let[U,A]of P.structIterator()){if(!A.getMergedTraits().hostLabel)continue;let _=w[U];if(typeof _!=="string")throw Error(`@smithy/core/schema - ${U} in input must be a string as hostLabel.`);h=h.replace(`{${U}}`,_)}$.hostname=h+$.hostname}}}deserializeMetadata($){return{httpStatusCode:$.statusCode,requestId:$.headers["x-amzn-requestid"]??$.headers["x-amzn-request-id"]??$.headers["x-amz-request-id"],extendedRequestId:$.headers["x-amz-id-2"],cfId:$.headers["x-amz-cf-id"]}}async serializeEventStream({eventStream:$,requestSchema:T,initialRequest:w}){return(await this.loadEventStreamCapability()).serializeEventStream({eventStream:$,requestSchema:T,initialRequest:w})}async deserializeEventStream({response:$,responseSchema:T,initialResponseContainer:w}){return(await this.loadEventStreamCapability()).deserializeEventStream({response:$,responseSchema:T,initialResponseContainer:w})}async loadEventStreamCapability(){let{EventStreamSerde:$}=await import("./index-1.1.37-kqbx8bd4.mjs");return new $({marshaller:this.getEventStreamMarshaller(),serializer:this.serializer,deserializer:this.deserializer,serdeContext:this.serdeContext,defaultContentType:this.getDefaultContentType()})}getDefaultContentType(){throw Error(`@smithy/core/protocols - ${this.constructor.name} getDefaultContentType() implementation missing.`)}async deserializeHttpMessage($,T,w,P,I){return[]}getEventStreamMarshaller(){let $=this.serdeContext;if(!$.eventStreamMarshaller)throw Error("@smithy/core - HttpProtocol: eventStreamMarshaller missing in serdeContext.");return $.eventStreamMarshaller}}class CT extends g0{async serializeRequest($,T,w){let P=T&&typeof T==="object"?T:{},I=this.serializer,h={},U={},A=await w.endpoint(),_=E.NormalizedSchema.of($?.input),M=[],Y=[],X=!1,J,f=new j({protocol:"",hostname:"",port:void 0,path:"",fragment:void 0,query:h,headers:U,body:void 0});if(A){this.updateServiceEndpoint(f,A),this.setHostPrefix(f,$,P);let G=E.translateTraits($.traits);if(G.http){f.method=G.http[0];let[Q,Z]=G.http[1].split("?");if(f.path=="/")f.path=Q;else f.path+=Q;let R=new URLSearchParams(Z??"");for(let[V,L]of R)h[V]=L}}for(let[G,Q]of _.structIterator()){let Z=Q.getMergedTraits()??{},R=P[G];if(R==null&&!Q.isIdempotencyToken()){if(Z.httpLabel){if(f.path.includes(`{${G}+}`)||f.path.includes(`{${G}}`))throw Error(`No value provided for input HTTP label: ${G}.`)}continue}if(Z.httpPayload)if(Q.isStreaming())if(Q.isStructSchema()){if(P[G])J=await this.serializeEventStream({eventStream:P[G],requestSchema:_})}else J=R;else I.write(Q,R),J=I.flush();else if(Z.httpLabel){I.write(Q,R);let V=I.flush();if(f.path.includes(`{${G}+}`))f.path=f.path.replace(`{${G}+}`,V.split("/").map(R0).join("/"));else if(f.path.includes(`{${G}}`))f.path=f.path.replace(`{${G}}`,R0(V))}else if(Z.httpHeader)I.write(Q,R),U[Z.httpHeader.toLowerCase()]=String(I.flush());else if(typeof Z.httpPrefixHeaders==="string")for(let V in R){let L=R[V],W=Z.httpPrefixHeaders+V;I.write([Q.getValueSchema(),{httpHeader:W}],L),U[W.toLowerCase()]=I.flush()}else if(Z.httpQuery||Z.httpQueryParams)this.serializeQuery(Q,R,h);else X=!0,M.push(G),Y.push(Q)}if(X&&P){let[G,Q]=(_.getName(!0)??"#Unknown").split("#"),Z=_.getSchema()[6],R=[3,G,Q,_.getMergedTraits(),M,Y,void 0];if(Z)R[6]=Z;else R.pop();I.write(R,P),J=I.flush()}return f.headers=U,f.query=h,f.body=J,f}serializeQuery($,T,w){let P=this.serializer,I=$.getMergedTraits();if(I.httpQueryParams){for(let h in T)if(!(h in w)){let U=T[h],A=$.getValueSchema();Object.assign(A.getMergedTraits(),{...I,httpQuery:h,httpQueryParams:void 0}),this.serializeQuery(A,U,w)}return}if($.isListSchema()){let h=!!$.getMergedTraits().sparse,U=[];for(let A of T){P.write([$.getValueSchema(),I],A);let _=P.flush();if(h||_!==void 0)U.push(_)}w[I.httpQuery]=U}else P.write([$,I],T),w[I.httpQuery]=P.flush()}async deserializeResponse($,T,w){let P=this.deserializer,I=E.NormalizedSchema.of($.output),h={};if(w.statusCode>=300){let A=await n(w.body,T);if(A.byteLength>0)Object.assign(h,await P.read(15,A));throw await this.handleError($,T,w,h,this.deserializeMetadata(w)),Error("@smithy/core/protocols - HTTP Protocol error handler failed to throw.")}for(let A in w.headers){let _=w.headers[A];delete w.headers[A],w.headers[A.toLowerCase()]=_}let U=await this.deserializeHttpMessage(I,T,w,h);if(U.length){let A=await n(w.body,T);if(A.byteLength>0){let _=await P.read(I,A);for(let M of U)if(_[M]!=null)h[M]=_[M]}}else if(U.discardResponseBody)await n(w.body,T);return h.$metadata=this.deserializeMetadata(w),h}async deserializeHttpMessage($,T,w,P,I){let h;if(P instanceof Set)h=I;else h=P;let U=!0,A=this.deserializer,_=E.NormalizedSchema.of($),M=[];for(let[Y,X]of _.structIterator()){let J=X.getMemberTraits();if(J.httpPayload){if(U=!1,X.isStreaming())if(X.isStructSchema())h[Y]=await this.deserializeEventStream({response:w,responseSchema:_});else h[Y]=O.sdkStreamMixin(w.body);else if(w.body){let G=await n(w.body,T);if(G.byteLength>0)h[Y]=await A.read(X,G)}}else if(J.httpHeader){let f=String(J.httpHeader).toLowerCase(),G=w.headers[f];if(G!=null)if(X.isListSchema()){let Q=X.getValueSchema();Q.getMergedTraits().httpHeader=f;let Z;if(Q.isTimestampSchema()&&Q.getSchema()===4)Z=O.splitEvery(G,",",2);else Z=O.splitHeader(G);let R=[];for(let V of Z)R.push(await A.read(Q,V.trim()));h[Y]=R}else h[Y]=await A.read(X,G)}else if(J.httpPrefixHeaders!==void 0){h[Y]={};for(let f in w.headers)if(f.startsWith(J.httpPrefixHeaders)){let G=w.headers[f],Q=X.getValueSchema();Q.getMergedTraits().httpHeader=f,h[Y][f.slice(J.httpPrefixHeaders.length)]=await A.read(Q,G)}}else if(J.httpResponseCode)h[Y]=w.statusCode;else M.push(Y)}return M.discardResponseBody=U,M}}class sT extends g0{async serializeRequest($,T,w){let P=this.serializer,I={},h={},U=await w.endpoint(),A=E.NormalizedSchema.of($?.input),_=A.getSchema(),M,Y=T&&typeof T==="object"?T:{},X=new j({protocol:"",hostname:"",port:void 0,path:"/",fragment:void 0,query:I,headers:h,body:void 0});if(U)this.updateServiceEndpoint(X,U),this.setHostPrefix(X,$,Y);if(Y){let J=A.getEventStreamMember();if(J){if(Y[J]){let f={};for(let[G,Q]of A.structIterator())if(G!==J&&Y[G])P.write(Q,Y[G]),f[G]=P.flush();M=await this.serializeEventStream({eventStream:Y[J],requestSchema:A,initialRequest:f})}}else P.write(_,Y),M=P.flush()}return X.headers=Object.assign(X.headers,h),X.query=I,X.body=M,X.method="POST",X}async deserializeResponse($,T,w){let P=this.deserializer,I=E.NormalizedSchema.of($.output),h={};if(w.statusCode>=300){let A=await n(w.body,T);if(A.byteLength>0)Object.assign(h,await P.read(15,A));throw await this.handleError($,T,w,h,this.deserializeMetadata(w)),Error("@smithy/core/protocols - RPC Protocol error handler failed to throw.")}for(let A in w.headers){let _=w.headers[A];delete w.headers[A],w.headers[A.toLowerCase()]=_}let U=I.getEventStreamMember();if(U)h[U]=await this.deserializeEventStream({response:w,responseSchema:I,initialResponseContainer:h});else{let A=await n(w.body,T);if(A.byteLength>0)Object.assign(h,await P.read(I,A))}return h.$metadata=this.deserializeMetadata(w),h}}var cT=($,T,w,P,I,h)=>{if(T!=null&&T[w]!==void 0){let U=P();if(U==null||U.length<=0)throw Error("Empty value provided for input HTTP label: "+w+".");$=$.replace(I,h?U.split("/").map((A)=>R0(A)).join("/"):R0(U))}else throw Error("No value provided for input HTTP label: "+w+".");return $};function d_($,T){return new d1($,T)}class d1{input;context;query={};method="";headers={};path="";body=null;hostname="";resolvePathStack=[];constructor($,T){this.input=$,this.context=T}async build(){let{hostname:$,protocol:T="https",port:w,path:P}=await this.context.endpoint();this.path=P;for(let I of this.resolvePathStack)I(this.path);return new j({protocol:T,hostname:this.hostname||$,port:w,method:this.method,path:this.path,query:this.query,body:this.body,headers:this.headers})}hn($){return this.hostname=$,this}bp($){return this.resolvePathStack.push((T)=>{this.path=`${T?.endsWith("/")?T.slice(0,-1):T||""}`+$}),this}p($,T,w,P){return this.resolvePathStack.push((I)=>{this.path=cT(I,this.input,$,T,w,P)}),this}h($){return this.headers=$,this}q($){return this.query=$,this}b($){return this.body=$,this}m($){return this.method=$,this}}function v1($,T){if(T.timestampFormat.useTrait){if($.isTimestampSchema()&&($.getSchema()===5||$.getSchema()===6||$.getSchema()===7))return $.getSchema()}let{httpLabel:w,httpPrefixHeaders:P,httpHeader:I,httpQuery:h}=$.getMergedTraits();return(T.httpBindings?typeof P==="string"||Boolean(I)?6:Boolean(h)||Boolean(w)?5:void 0:void 0)??T.timestampFormat.default}class n1 extends $0{settings;constructor($){super();this.settings=$}read($,T){let w=E.NormalizedSchema.of($);if(w.isListSchema())return O.splitHeader(T).map((P)=>this.read(w.getValueSchema(),P));if(w.isBlobSchema())return(this.serdeContext?.base64Decoder??O.fromBase64)(T);if(w.isTimestampSchema())switch(v1(w,this.settings)){case 5:return O._parseRfc3339DateTimeWithOffset(T);case 6:return O._parseRfc7231DateTime(T);case 7:return O._parseEpochTimestamp(T);default:return console.warn("Missing timestamp format, parsing value with Date constructor:",T),new Date(T)}if(w.isStringSchema()){let P=w.getMergedTraits().mediaType,I=T;if(P){if(w.getMergedTraits().httpHeader)I=this.base64ToUtf8(I);if(P==="application/json"||P.endsWith("+json"))I=O.LazyJsonString.from(I);return I}}if(w.isNumericSchema())return Number(T);if(w.isBigIntegerSchema())return BigInt(T);if(w.isBigDecimalSchema())return new O.NumericValue(T,"bigDecimal");if(w.isBooleanSchema())return String(T).toLowerCase()==="true";return T}base64ToUtf8($){return(this.serdeContext?.utf8Encoder??O.toUtf8)((this.serdeContext?.base64Decoder??O.fromBase64)($))}}class bT extends $0{codecDeserializer;stringDeserializer;constructor($,T){super();this.codecDeserializer=$,this.stringDeserializer=new n1(T)}setSerdeContext($){this.stringDeserializer.setSerdeContext($),this.codecDeserializer.setSerdeContext($),this.serdeContext=$}read($,T){let w=E.NormalizedSchema.of($),P=w.getMergedTraits(),I=this.serdeContext?.utf8Encoder??O.toUtf8;if(P.httpHeader||P.httpResponseCode)return this.stringDeserializer.read(w,I(T));if(P.httpPayload){if(w.isBlobSchema()){let h=this.serdeContext?.utf8Decoder??O.fromUtf8;if(typeof T==="string")return h(T);return T}else if(w.isStringSchema()){if("byteLength"in T)return I(T);return T}}return this.codecDeserializer.read(w,T)}}class t1 extends $0{settings;stringBuffer="";constructor($){super();this.settings=$}write($,T){let w=E.NormalizedSchema.of($);switch(typeof T){case"object":if(T===null){this.stringBuffer="null";return}if(w.isTimestampSchema()){if(!(T instanceof Date))throw Error(`@smithy/core/protocols - received non-Date value ${T} when schema expected Date in ${w.getName(!0)}`);switch(v1(w,this.settings)){case 5:this.stringBuffer=T.toISOString().replace(".000Z","Z");break;case 6:this.stringBuffer=O.dateToUtcString(T);break;case 7:this.stringBuffer=String(T.getTime()/1000);break;default:console.warn("Missing timestamp format, using epoch seconds",T),this.stringBuffer=String(T.getTime()/1000)}return}if(w.isBlobSchema()&&"byteLength"in T){this.stringBuffer=(this.serdeContext?.base64Encoder??O.toBase64)(T);return}if(w.isListSchema()&&Array.isArray(T)){let h="";for(let U of T){this.write([w.getValueSchema(),w.getMergedTraits()],U);let A=this.flush(),_=w.getValueSchema().isTimestampSchema()?A:O.quoteHeader(A);if(h!=="")h+=", ";h+=_}this.stringBuffer=h;return}this.stringBuffer=JSON.stringify(T,null,2);break;case"string":let P=w.getMergedTraits().mediaType,I=T;if(P){if(P==="application/json"||P.endsWith("+json"))I=O.LazyJsonString.from(I);if(w.getMergedTraits().httpHeader){this.stringBuffer=(this.serdeContext?.base64Encoder??O.toBase64)(I.toString());return}}this.stringBuffer=T;break;default:if(w.isIdempotencyToken())this.stringBuffer=O.generateIdempotencyToken();else this.stringBuffer=String(T)}}flush(){let $=this.stringBuffer;return this.stringBuffer="",$}}class kT{codecSerializer;stringSerializer;buffer;constructor($,T,w=new t1(T)){this.codecSerializer=$,this.stringSerializer=w}setSerdeContext($){this.codecSerializer.setSerdeContext($),this.stringSerializer.setSerdeContext($)}write($,T){let w=E.NormalizedSchema.of($),P=w.getMergedTraits();if(P.httpHeader||P.httpLabel||P.httpQuery){this.stringSerializer.write(w,T),this.buffer=this.stringSerializer.flush();return}return this.codecSerializer.write(w,T)}flush(){if(this.buffer!==void 0){let $=this.buffer;return this.buffer=void 0,$}return this.codecSerializer.flush()}}class pT{name;kind;values;constructor({name:$,kind:T=g_.FieldPosition.HEADER,values:w=[]}){this.name=$,this.kind=T,this.values=w}add($){this.values.push($)}set($){this.values=$}remove($){this.values=this.values.filter((T)=>T!==$)}toString(){return this.values.map(($)=>$.includes(",")||$.includes(" ")?`"${$}"`:$).join(", ")}get(){return this.values}}class yT{entries={};encoding;constructor({fields:$=[],encoding:T="utf-8"}){$.forEach(this.setField.bind(this)),this.encoding=T}setField($){this.entries[$.name.toLowerCase()]=$}getField($){return this.entries[$.toLowerCase()]}removeField($){delete this.entries[$.toLowerCase()]}getByType($){return Object.values(this.entries).filter((T)=>T.kind===$)}}function v_($){return/^[a-z0-9][a-z0-9\.\-]*[a-z0-9]$/.test($)}var n_=($)=>{return{setHttpHandler(T){$.httpHandler=T},httpHandler(){return $.httpHandler},updateHttpClientConfig(T,w){$.httpHandler?.updateHttpClientConfig(T,w)},httpHandlerConfigs(){return $.httpHandler.httpHandlerConfigs()}}},t_=($)=>{return{httpHandler:$.httpHandler()}},jT="content-length";function gT($){return(T)=>async(w)=>{let P=w.request;if(j.isInstance(P)){let{body:I,headers:h}=P;if(I&&Object.keys(h).map((U)=>U.toLowerCase()).indexOf(jT)===-1)try{let U=$(I);P.headers={...P.headers,[jT]:String(U)}}catch(U){}}return T({...w,request:P})}}var mT={step:"build",tags:["SET_CONTENT_LENGTH","CONTENT_LENGTH"],name:"contentLengthMiddleware",override:!0},i_=($)=>({applyToStack:(T)=>{T.add(gT($.bodyLengthChecker),mT)}}),Z0=($)=>encodeURIComponent($).replace(/[!'()*]/g,u_),u_=($)=>`%${$.charCodeAt(0).toString(16).toUpperCase()}`,r_=($)=>$.split("/").map(Z0).join("/");function l_($){let T=[];for(let w of Object.keys($).sort()){let P=$[w];if(w=Z0(w),Array.isArray(P))for(let I=0,h=P.length;I<h;I++)T.push(`${w}=${Z0(P[I])}`);else{let I=w;if(P||typeof P==="string")I+=`=${Z0(P)}`;T.push(I)}}return T.join("&")}function dT($){let T={};if($=$.replace(/^\?/,""),$)for(let w of $.split("&")){let[P,I=null]=w.split("=");if(P=decodeURIComponent(P),I)I=decodeURIComponent(I);if(!(P in T))T[P]=I;else if(Array.isArray(T[P]))T[P].push(I);else T[P]=[T[P],I]}return T}var vT=($)=>{if(typeof $==="string")return vT(new URL($));let{hostname:T,pathname:w,port:P,protocol:I,search:h}=$,U;if(h)U=dT(h);return{hostname:T,port:P?parseInt(P):void 0,protocol:I,path:w,query:U}};o_.Field=pT;o_.Fields=yT;o_.FromStringShapeDeserializer=n1;o_.HttpBindingProtocol=CT;o_.HttpInterceptingShapeDeserializer=bT;o_.HttpInterceptingShapeSerializer=kT;o_.HttpProtocol=g0;o_.HttpRequest=j;o_.HttpResponse=m1;o_.RequestBuilder=d1;o_.RpcProtocol=sT;o_.SerdeContext=$0;o_.ToStringShapeSerializer=t1;o_.buildQueryString=l_;o_.collectBody=n;o_.contentLengthMiddleware=gT;o_.contentLengthMiddlewareOptions=mT;o_.determineTimestampFormat=v1;o_.escapeUri=Z0;o_.escapeUriPath=r_;o_.extendedEncodeURIComponent=R0;o_.getContentLengthPlugin=i_;o_.getHttpHandlerExtensionConfiguration=n_;o_.isValidHostname=v_;o_.parseQueryString=dT;o_.parseUrl=vT;o_.requestBuilder=d_;o_.resolveHttpHandlerRuntimeConfig=t_;o_.resolvedPath=cT});var h1=y((y6)=>{var nT=D0(),B6=C0(),q6=F0(),m0=($)=>{if(typeof $==="function")return $();return $},r1=($,T,w,P,I)=>({name:T,namespace:$,traits:w,input:P,output:I}),x6=($)=>(T,w)=>async(P)=>{let{response:I}=await T(P),{operationSchema:h}=nT.getSmithyContext(w),[,U,A,_,M,Y]=h??[];try{let X=await $.protocol.deserializeResponse(r1(U,A,_,M,Y),{...$,...w},I);return{response:I,output:X}}catch(X){if(Object.defineProperty(X,"$response",{value:I,enumerable:!1,writable:!1,configurable:!1}),!("$metadata"in X)){try{X.message+=`
16
+ Deserialization error: to see the raw response, inspect the hidden field {error}.$response on this object.`}catch(f){if(!w.logger||w.logger?.constructor?.name==="NoOpLogger")console.warn("Deserialization error: to see the raw response, inspect the hidden field {error}.$response on this object.");else w.logger?.warn?.("Deserialization error: to see the raw response, inspect the hidden field {error}.$response on this object.")}if(typeof X.$responseBodyText<"u"){if(X.$response)X.$response.body=X.$responseBodyText}try{if(B6.HttpResponse.isInstance(I)){let{headers:f={}}=I,G=Object.entries(f);X.$metadata={httpStatusCode:I.statusCode,requestId:i1(/^x-[\w-]+-request-?id$/,G),extendedRequestId:i1(/^x-[\w-]+-id-2$/,G),cfId:i1(/^x-[\w-]+-cf-id$/,G)}}}catch(f){}}throw X}},i1=($,T)=>{return(T.find(([w])=>{return w.match($)})||[void 0,void 0])[1]},F6=($)=>(T,w)=>async(P)=>{let{operationSchema:I}=nT.getSmithyContext(w),[,h,U,A,_,M]=I??[],Y=w.endpointV2?async()=>q6.toEndpointV1(w.endpointV2):$.endpoint,X=await $.protocol.serializeRequest(r1(h,U,A,_,M),P.input,{...$,...w,endpoint:Y});return T({...P,request:X})},tT={name:"deserializerMiddleware",step:"deserialize",tags:["DESERIALIZER"],override:!0},iT={name:"serializerMiddleware",step:"serialize",tags:["SERIALIZER"],override:!0};function z6($){return{applyToStack:(T)=>{T.add(F6($),iT),T.add(x6($),tT),$.protocol.setSerdeContext($)}}}class D{name;namespace;traits;static assign($,T){return Object.assign($,T)}static[Symbol.hasInstance]($){let T=this.prototype.isPrototypeOf($);if(!T&&typeof $==="object"&&$!==null)return $.symbol===this.symbol;return T}getName(){return this.namespace+"#"+this.name}}class t0 extends D{static symbol=Symbol.for("@smithy/lis");name;traits;valueSchema;symbol=t0.symbol}var S6=($,T,w,P)=>D.assign(new t0,{name:T,namespace:$,traits:w,valueSchema:P});class i0 extends D{static symbol=Symbol.for("@smithy/map");name;traits;keySchema;valueSchema;symbol=i0.symbol}var j6=($,T,w,P,I)=>D.assign(new i0,{name:T,namespace:$,traits:w,keySchema:P,valueSchema:I});class u0 extends D{static symbol=Symbol.for("@smithy/ope");name;traits;input;output;symbol=u0.symbol}var C6=($,T,w,P,I)=>D.assign(new u0,{name:T,namespace:$,traits:w,input:P,output:I});class N0 extends D{static symbol=Symbol.for("@smithy/str");name;traits;memberNames;memberList;symbol=N0.symbol}var s6=($,T,w,P,I)=>D.assign(new N0,{name:T,namespace:$,traits:w,memberNames:P,memberList:I});class r0 extends N0{static symbol=Symbol.for("@smithy/err");ctor;symbol=r0.symbol}var c6=($,T,w,P,I,h)=>D.assign(new r0,{name:T,namespace:$,traits:w,memberNames:P,memberList:I,ctor:null}),d0=[];function O0($){if(typeof $==="object")return $;if($=$|0,d0[$])return d0[$];let T={},w=0;for(let P of["httpLabel","idempotent","idempotencyToken","sensitive","httpPayload","httpResponseCode","httpQueryParams"])if(($>>w++&1)===1)T[P]=1;return d0[$]=T}var Q0={it:Symbol.for("@smithy/nor-struct-it"),ns:Symbol.for("@smithy/ns")},v0=[],n0={};class s{ref;memberName;static symbol=Symbol.for("@smithy/nor");symbol=s.symbol;name;schema;_isMemberSchema;traits;memberTraits;normalizedTraits;constructor($,T){this.ref=$,this.memberName=T;let w=[],P=$,I=$;this._isMemberSchema=!1;while(u1(P))w.push(P[1]),P=P[0],I=m0(P),this._isMemberSchema=!0;if(w.length>0){this.memberTraits={};for(let h=w.length-1;h>=0;--h){let U=w[h];Object.assign(this.memberTraits,O0(U))}}else this.memberTraits=0;if(I instanceof s){let h=this.memberTraits;Object.assign(this,I),this.memberTraits=Object.assign({},h,I.getMemberTraits(),this.getMemberTraits()),this.normalizedTraits=void 0,this.memberName=T??I.memberName;return}if(this.schema=m0(I),uT(this.schema))this.name=`${this.schema[1]}#${this.schema[2]}`,this.traits=this.schema[3];else this.name=this.memberName??String(I),this.traits=0;if(this._isMemberSchema&&!T)throw Error(`@smithy/core/schema - NormalizedSchema member init ${this.getName(!0)} missing member name.`)}static[Symbol.hasInstance]($){let T=this.prototype.isPrototypeOf($);if(!T&&typeof $==="object"&&$!==null)return $.symbol===this.symbol;return T}static of($){let T=typeof $==="function"||typeof $==="object"&&$!==null;if(typeof $==="number"){if(v0[$])return v0[$]}else if(typeof $==="string"){if(n0[$])return n0[$]}else if(T){if($[Q0.ns])return $[Q0.ns]}let w=m0($);if(w instanceof s)return w;if(u1(w)){let[I,h]=w;if(I instanceof s)return Object.assign(I.getMergedTraits(),O0(h)),I;throw Error(`@smithy/core/schema - may not init unwrapped member schema=${JSON.stringify($,null,2)}.`)}let P=new s(w);if(T)return $[Q0.ns]=P;if(typeof w==="string")return n0[w]=P;if(typeof w==="number")return v0[w]=P;return P}getSchema(){let $=this.schema;if(Array.isArray($)&&$[0]===0)return $[4];return $}getName($=!1){let{name:T}=this;return!$&&T&&T.includes("#")?T.split("#")[1]:T||void 0}getMemberName(){return this.memberName}isMemberSchema(){return this._isMemberSchema}isListSchema(){let $=this.getSchema();return typeof $==="number"?$>=64&&$<128:$[0]===1}isMapSchema(){let $=this.getSchema();return typeof $==="number"?$>=128&&$<=255:$[0]===2}isStructSchema(){let $=this.getSchema();if(typeof $!=="object")return!1;let T=$[0];return T===3||T===-3||T===4}isUnionSchema(){let $=this.getSchema();if(typeof $!=="object")return!1;return $[0]===4}isBlobSchema(){let $=this.getSchema();return $===21||$===42}isTimestampSchema(){let $=this.getSchema();return typeof $==="number"&&$>=4&&$<=7}isUnitSchema(){return this.getSchema()==="unit"}isDocumentSchema(){return this.getSchema()===15}isStringSchema(){return this.getSchema()===0}isBooleanSchema(){return this.getSchema()===2}isNumericSchema(){return this.getSchema()===1}isBigIntegerSchema(){return this.getSchema()===17}isBigDecimalSchema(){return this.getSchema()===19}isStreaming(){let{streaming:$}=this.getMergedTraits();return!!$||this.getSchema()===42}isIdempotencyToken(){return!!this.getMergedTraits().idempotencyToken}getMergedTraits(){return this.normalizedTraits??(this.normalizedTraits={...this.getOwnTraits(),...this.getMemberTraits()})}getMemberTraits(){return O0(this.memberTraits)}getOwnTraits(){return O0(this.traits)}getKeySchema(){let[$,T]=[this.isDocumentSchema(),this.isMapSchema()];if(!$&&!T)throw Error(`@smithy/core/schema - cannot get key for non-map: ${this.getName(!0)}`);let w=this.getSchema(),P=$?15:w[4]??0;return V0([P,0],"key")}getValueSchema(){let $=this.getSchema(),[T,w,P]=[this.isDocumentSchema(),this.isMapSchema(),this.isListSchema()],I=typeof $==="number"?63&$:$&&typeof $==="object"&&(w||P)?$[3+$[0]]:T?15:void 0;if(I!=null)return V0([I,0],w?"value":"member");throw Error(`@smithy/core/schema - ${this.getName(!0)} has no value member.`)}getMemberSchema($){let T=this.getSchema();if(this.isStructSchema()&&T[4].includes($)){let w=T[4].indexOf($),P=T[5][w];return V0(u1(P)?P:[P,0],$)}if(this.isDocumentSchema())return V0([15,0],$);throw Error(`@smithy/core/schema - ${this.getName(!0)} has no member=${$}.`)}getMemberSchemas(){let $={};try{for(let[T,w]of this.structIterator())$[T]=w}catch(T){}return $}getEventStreamMember(){if(this.isStructSchema()){for(let[$,T]of this.structIterator())if(T.isStreaming()&&T.isStructSchema())return $}return""}*structIterator(){if(this.isUnitSchema())return;if(!this.isStructSchema())throw Error("@smithy/core/schema - cannot iterate non-struct schema.");let $=this.getSchema(),T=$[4].length,w=$[Q0.it];if(w&&T===w.length){yield*w;return}w=Array(T);for(let P=0;P<T;++P){let I=$[4][P],h=V0([$[5][P],0],I);yield w[P]=[I,h]}$[Q0.it]=w}}function V0($,T){if($ instanceof s)return Object.assign($,{memberName:T,_isMemberSchema:!0});return new s($,T)}var u1=($)=>Array.isArray($)&&$.length===2,uT=($)=>Array.isArray($)&&$.length>=5;class L0 extends D{static symbol=Symbol.for("@smithy/sim");name;schemaRef;traits;symbol=L0.symbol}var b6=($,T,w,P)=>D.assign(new L0,{name:T,namespace:$,traits:P,schemaRef:w}),k6=($,T,w,P)=>D.assign(new L0,{name:T,namespace:$,traits:w,schemaRef:P}),p6={BLOB:21,STREAMING_BLOB:42,BOOLEAN:2,STRING:0,NUMERIC:1,BIG_INTEGER:17,BIG_DECIMAL:19,DOCUMENT:15,TIMESTAMP_DEFAULT:4,TIMESTAMP_DATE_TIME:5,TIMESTAMP_HTTP_DATE:6,TIMESTAMP_EPOCH_SECONDS:7,LIST_MODIFIER:64,MAP_MODIFIER:128};class C{namespace;schemas;exceptions;static registries=new Map;constructor($,T=new Map,w=new Map){this.namespace=$,this.schemas=T,this.exceptions=w}static for($){if(!C.registries.has($))C.registries.set($,new C($));return C.registries.get($)}copyFrom($){let{schemas:T,exceptions:w}=this;for(let[P,I]of $.schemas)if(!T.has(P))T.set(P,I);for(let[P,I]of $.exceptions)if(!w.has(P))w.set(P,I)}register($,T){let w=this.normalizeShapeId($);for(let P of[this,C.for(w.split("#")[0])])P.schemas.set(w,T)}getSchema($){let T=this.normalizeShapeId($);if(!this.schemas.has(T))throw Error(`@smithy/core/schema - schema not found for ${T}`);return this.schemas.get(T)}registerError($,T){let w=$,P=w[1];for(let I of[this,C.for(P)])I.schemas.set(P+"#"+w[2],w),I.exceptions.set(w,T)}getErrorCtor($){let T=$;if(this.exceptions.has(T))return this.exceptions.get(T);return C.for(T[1]).exceptions.get(T)}getBaseException(){for(let $ of this.exceptions.keys())if(Array.isArray($)){let[,T,w]=$,P=T+"#"+w;if(P.startsWith("smithy.ts.sdk.synthetic.")&&P.endsWith("ServiceException"))return $}return}find($){for(let T of this.schemas.values())if($(T))return T;return}clear(){this.schemas.clear(),this.exceptions.clear()}normalizeShapeId($){if($.includes("#"))return $;return this.namespace+"#"+$}}y6.ErrorSchema=r0;y6.ListSchema=t0;y6.MapSchema=i0;y6.NormalizedSchema=s;y6.OperationSchema=u0;y6.SCHEMA=p6;y6.Schema=D;y6.SimpleSchema=L0;y6.StructureSchema=N0;y6.TypeRegistry=C;y6.deref=m0;y6.deserializerMiddlewareOption=tT;y6.error=c6;y6.getSchemaSerdePlugin=z6;y6.isStaticSchema=uT;y6.list=S6;y6.map=j6;y6.op=C6;y6.operation=r1;y6.serializerMiddlewareOption=iT;y6.sim=b6;y6.simAdapter=k6;y6.simpleSchemaCacheN=v0;y6.simpleSchemaCacheS=n0;y6.struct=s6;y6.traitsCache=d0;y6.translateTraits=O0});
17
+ export{P0 as Xpa,h1 as Ypa,D0 as Zpa,C$ as _pa,F0 as $pa,ST as aqa,C0 as bqa};
@@ -0,0 +1,2 @@
1
+ import{Uoa as D,pka as A,tka as B}from"./cli-1.1.37-ekft3ygw.mjs";import{gqa as C}from"./cli-1.1.37-5k40cazp.mjs";function z(q){k=[q,...k.filter((x)=>x!==q)]}function H(){y?.(),z(A()),y=B(z)}function J(){return k}function K(q){k=k.filter((x)=>x!==q)}var k,y;var F=C(()=>{D();k=[]});
2
+ export{H as Th,J as Uh,K as Vh,F as Wh};
@@ -0,0 +1,2 @@
1
+ import{Ix as X,Jx as h,KE as Y,WE as p}from"./cli-1.1.37-grsmntjy.mjs";import{RX as D,ZV as v,lX as B}from"./cli-1.1.37-kemsps6y.mjs";import{s1 as I,t1 as J,u1 as W}from"./cli-1.1.37-z414tkgs.mjs";import{_9 as U,oea as b}from"./cli-1.1.37-z4wav0zf.mjs";import{cqa as G}from"./cli-1.1.37-5k40cazp.mjs";D();b();p();h();W();var Z=G(v(),1);function C(S){let k=Z.c(17),{customApiKeyTruncated:q,onDone:L}=S,M;if(k[0]!==q||k[1]!==L)M=function(f){k:switch(f){case"yes":{U((z)=>({...z,customApiKeyResponses:{...z.customApiKeyResponses,approved:[...z.customApiKeyResponses?.approved??[],q]}})),L(!0);break k}case"no":U((z)=>({...z,customApiKeyResponses:{...z.customApiKeyResponses,rejected:[...z.customApiKeyResponses?.rejected??[],q]}})),L(!1)}},k[0]=q,k[1]=L,k[2]=M;else M=k[2];let w=M,E;if(k[3]!==w)E=()=>w("no"),k[3]=w,k[4]=E;else E=k[4];let N;if(k[5]===Symbol.for("react.memo_cache_sentinel"))N=I(B,{bold:!0,children:"ANTHROPIC_API_KEY"}),k[5]=N;else N=k[5];let F;if(k[6]!==q)F=J(B,{children:[N,J(B,{children:[": sk-ant-...",q]})]}),k[6]=q,k[7]=F;else F=k[7];let O;if(k[8]===Symbol.for("react.memo_cache_sentinel"))O=I(B,{children:"Do you want to use this API key?"}),k[8]=O;else O=k[8];let P;if(k[9]===Symbol.for("react.memo_cache_sentinel"))P={label:"Yes",value:"yes"},k[9]=P;else P=k[9];let Q;if(k[10]===Symbol.for("react.memo_cache_sentinel"))Q=[P,{label:J(B,{children:["No (",I(B,{bold:!0,children:"recommended"}),")"]}),value:"no"}],k[10]=Q;else Q=k[10];let H;if(k[11]!==w)H=I(Y,{defaultValue:"no",defaultFocusValue:"no",options:Q,onChange:(V)=>w(V),onCancel:()=>w("no")}),k[11]=w,k[12]=H;else H=k[12];let R;if(k[13]!==E||k[14]!==F||k[15]!==H)R=J(X,{title:"Detected a custom API key in your environment",color:"warning",onCancel:E,children:[F,O,H]}),k[13]=E,k[14]=F,k[15]=H,k[16]=R;else R=k[16];return R}
2
+ export{C as Q};
@@ -0,0 +1,2 @@
1
+ import{AW as H,RW as I,SW as V,TW as p,yW as N,zW as U}from"./cli-1.1.37-kemsps6y.mjs";import{s1 as L,u1 as P}from"./cli-1.1.37-z414tkgs.mjs";import{v1 as F}from"./cli-1.1.37-v90enr9t.mjs";import{Oma as T,Uoa as A}from"./cli-1.1.37-ekft3ygw.mjs";import{cqa as _,gqa as $}from"./cli-1.1.37-5k40cazp.mjs";function v({children:W,ref:X,stickyScroll:Y,...E}){let w=C.useRef(null),[,Z]=C.useState(0),G=C.useRef(new Set),J=C.useRef(!1),O=()=>{for(let g of G.current)g()};function K(g){if(T(),N(g),O(),J.current)return;J.current=!0,queueMicrotask(()=>{J.current=!1,U(g)})}return C.useImperativeHandle(X,()=>({scrollTo(g){let q=w.current;if(!q)return;q.stickyScroll=!1,q.pendingScrollDelta=void 0,q.scrollAnchor=void 0,q.scrollTop=Math.max(0,Math.floor(g)),K(q)},scrollToElement(g,q=0){let z=w.current;if(!z)return;z.stickyScroll=!1,z.pendingScrollDelta=void 0,z.scrollAnchor={el:g,offset:q},K(z)},scrollBy(g){let q=w.current;if(!q)return;q.stickyScroll=!1,q.scrollAnchor=void 0,q.pendingScrollDelta=(q.pendingScrollDelta??0)+Math.floor(g),K(q)},scrollToBottom(){let g=w.current;if(!g)return;g.pendingScrollDelta=void 0,g.stickyScroll=!0,N(g),O(),Z((q)=>q+1)},getScrollTop(){return w.current?.scrollTop??0},getPendingDelta(){return w.current?.pendingScrollDelta??0},getScrollHeight(){return w.current?.scrollHeight??0},getFreshScrollHeight(){return w.current?.childNodes[0]?.yogaNode?.getComputedHeight()??w.current?.scrollHeight??0},getViewportHeight(){return w.current?.scrollViewportHeight??0},getViewportTop(){return w.current?.scrollViewportTop??0},isSticky(){let g=w.current;if(!g)return!1;return g.stickyScroll??Boolean(g.attributes.stickyScroll)},subscribe(g){return G.current.add(g),()=>G.current.delete(g)},setClampBounds(g,q){let z=w.current;if(!z)return;z.scrollClampMin=g,z.scrollClampMax=q}}),[]),L("ink-box",{ref:(g)=>{if(w.current=g,g)g.scrollTop??=0},style:{flexWrap:"nowrap",flexDirection:E.flexDirection??"row",flexGrow:E.flexGrow??0,flexShrink:E.flexShrink??1,...E,overflowX:"scroll",overflowY:"scroll"},...Y?{stickyScroll:!0}:{},children:L(V,{flexDirection:"column",flexGrow:1,flexShrink:0,width:"100%",children:W})})}var C,S;var D=$(()=>{A();H();I();p();P();C=_(F(),1);S=v});
2
+ export{S as Hh,D as Ih};
@@ -0,0 +1,2 @@
1
+ import{B9 as N,Cfa as E,z9 as V,zfa as W}from"./cli-1.1.37-z4wav0zf.mjs";import{gqa as $,hqa as L}from"./cli-1.1.37-5k40cazp.mjs";import{existsSync as S}from"node:fs";import{homedir as X}from"node:os";import{join as R}from"node:path";function B(b){let q=b?.trim();return q?q:void 0}function Y(b=process.env){return B(b.GOOGLE_CLOUD_PROJECT)??B(b.GCLOUD_PROJECT)??B(b.GOOGLE_PROJECT_ID)}function k(b=process.env){let q=B(b.GEMINI_AUTH_MODE)?.toLowerCase();if(q==="api-key"||q==="adc")return q;return}function x(b=process.env){let q=B(b.GOOGLE_APPLICATION_CREDENTIALS),w=new Set;if(q)w.add(q);w.add(R(X(),".config","gcloud","application_default_credentials.json"));let F=B(b.APPDATA);if(F)w.add(R(F,"gcloud","application_default_credentials.json"));return[...w]}function K(b=process.env){return x(b).some((q)=>S(q))}function y(b){if(typeof b==="string")return B(b);return B(b?.token)}async function P(){let{GoogleAuth:b}=await import("google-auth-library");return new b({scopes:[U]})}async function Z(b,q){if(!K(b))return{kind:"none"};try{let w=await(q.createGoogleAuth??P)(),F=await w.getClient(),J=y(await F.getAccessToken());if(!J)return{kind:"none"};let Q=Y(b)??(typeof w.getProjectId==="function"?B(await w.getProjectId().catch(()=>{return})):void 0);return{kind:"adc",credential:J,...Q?{projectId:Q}:{}}}catch{return{kind:"none"}}}async function j(b=process.env,q={}){let w=k(b),F=W(),J=F?.transport==="gemini"?B(F.apiKey):void 0,O=w==="adc"?void 0:J;if(O&&(w===void 0||w==="api-key"))return{kind:"api-key",credential:O};if(w==="api-key")return{kind:"none"};if(q.createGoogleAuth)return Z(b,q);return _(B(b.GOOGLE_APPLICATION_CREDENTIALS),B(b.APPDATA),X(),Y(b))}var U="https://www.googleapis.com/auth/cloud-platform",f=300000,_;var D=$(()=>{E();N();_=V(async(b,q,w,F)=>Z({GOOGLE_APPLICATION_CREDENTIALS:b,APPDATA:q,GOOGLE_CLOUD_PROJECT:F,GCLOUD_PROJECT:F,GOOGLE_PROJECT_ID:F,HOME:w},{}),f)});
2
+ export{j as Ki,D as Li};
@@ -0,0 +1,3 @@
1
+ import{ce as rJ,de as eY}from"./cli-1.1.37-v7ra9bdg.mjs";import{Ng as nJ,Og as sY}from"./cli-1.1.37-7h3edez5.mjs";import{Ci as zY,Di as zZ}from"./cli-1.1.37-8v3e4pnr.mjs";import{Ao as wY,Ax as DY,Bx as NY,DA as XY,DL as o,Dx as DZ,EA as XZ,EE as AY,EL as OJ,FL as iJ,Gx as MY,HE as MZ,Hx as NZ,KK as lJ,PK as tY,PL as uY,RE as CY,SE as AZ,SJ as vY,TE as EY,TJ as EZ,UE as CZ,YO as WY,ZO as vZ,aS as GJ,im as PY,ix as BJ,jm as PZ,kx as iY,nx as OY,ox as OZ,rx as aJ,sx as nY,tx as HJ,ux as rY,vx as PJ,wx as oY,zR as kY,zo as jJ}from"./cli-1.1.37-grsmntjy.mjs";import{GX as HY,NW as BY,RX as MJ,ZV as lY,jX as v,lX as V}from"./cli-1.1.37-kemsps6y.mjs";import{s1 as Q,t1 as B,u1 as t}from"./cli-1.1.37-z414tkgs.mjs";import{v1 as dJ}from"./cli-1.1.37-v90enr9t.mjs";import{F$ as FY,Hfa as mJ,Kfa as AJ,Pfa as SJ,T$ as HZ,f9 as ZY,g9 as ZZ}from"./cli-1.1.37-z4wav0zf.mjs";import{Sfa as b,Tfa as JZ,Vfa as u,Zfa as YZ,cga as FJ,ega as QJ,kga as TJ}from"./cli-1.1.37-j1vf4g9d.mjs";import{Uoa as LJ,vka as zJ}from"./cli-1.1.37-ekft3ygw.mjs";import{cqa as NJ,gqa as JJ}from"./cli-1.1.37-5k40cazp.mjs";function fZ(Y,J,Z){let K=zJ();if(!J||!Y.projectPath||Y.projectPath===K)return{isCrossProject:!1};let X=o(Y);return{isCrossProject:!0,isSameRepoWorktree:!1,command:`cd ${jJ([Y.projectPath])} && claude --resume ${X}`,projectPath:Y.projectPath}}var hY=JJ(()=>{LJ();wY();GJ()});import{basename as xJ}from"path";function IJ(Y){return`$${(Y??0).toFixed(2)}`}function aY(Y,J){return Y.worktreeSession?.worktreeName??xJ(Y.projectPath??J)}function gJ(Y){let{currentSessionId:J,current:Z,cwd:K,now:X}=Y,U=new Map(Y.instanceSessionIds.map((z,G)=>[z,G])),A=new Map(Y.liveElsewhere.map((z)=>[z.sessionId,z])),M=[],H=new Set;for(let z of Y.logs){let G=o(z);if(!G||H.has(G))continue;H.add(G);let E=G===J,P=E?void 0:A.get(G),S=E?"current":P?"elsewhere":U.has(G)?"open":"inactive",R=E?Z.contextTokens??z.contextTokens:z.contextTokens,k=E?Z:P,c=k?.runningAgents??0;M.push({sessionId:G,log:z,status:S,running:Boolean(k?.turnActive)||c>0,title:((E?Z.title:void 0)??mJ(z)).replace(cY," "),agents:String(c),where:aY(z,K),branch:z.gitBranch??"",tokens:R?FJ(R):"",cost:IJ(k?.costUSD??Y.releasedCostUSD?.get(G)??z.costUSD??z.costState?.totalCostUSD),when:QJ(z.modified,{now:X}),holder:P?{pid:P.pid,cwd:P.cwd}:void 0})}if(J!==void 0&&!H.has(J))M.push({sessionId:J,status:"current",running:Z.turnActive||Z.runningAgents>0,title:Z.title??"(new session)",agents:String(Z.runningAgents),where:xJ(K),branch:Z.branch??"",tokens:Z.contextTokens?FJ(Z.contextTokens):"",cost:IJ(Z.costUSD),when:"now"});let L=(z)=>z.log?.modified.getTime()??X.getTime();return M.sort((z,G)=>fJ[z.status]-fJ[G.status]||(z.status==="open"?U.get(z.sessionId)-U.get(G.sessionId):L(G)-L(z)))}function wJ(Y,J){let Z=J.toLowerCase().split(dY).filter(Boolean);if(Z.length===0)return[...Y];return Y.filter((K)=>{let X=K.log,U=[K.title,K.where,K.branch,X?.firstPrompt,X?.tag,X?.prRepository&&X.prNumber?`${X.prRepository}#${X.prNumber}`:void 0,K.sessionId].filter(Boolean).join(`
2
+ `).toLowerCase();return Z.every((A)=>U.includes(A))})}function hJ(Y){let J=[];return Y.forEach((Z,K)=>{if(Z.status==="inactive"&&K>0&&Y[K-1].status!=="inactive")J.push({kind:"divider"});J.push({kind:"row",index:K})}),J}function uJ(Y,J,Z,K){let X=Y;if(J<X)X=J;else if(J>=X+Z)X=J-Z+1;return Math.max(0,Math.min(X,K-Z))}function gZ(Y){let J=[];if(Y.busy)J.push("the running turn");if(Y.runningAgents>0)J.push(`${Y.runningAgents} background agent${Y.runningAgents===1?"":"s"}`);return J.length>0?J.join(" and "):void 0}var fJ,cY,dY;var cJ=JJ(()=>{uY();SJ();TJ();fJ={current:0,open:1,elsewhere:2,inactive:3},cY=/\s*\n\s*/g,dY=/\s+/});function tJ(Y){let J=oJ.c(33),{log:Z,onExit:K,onSelect:X}=Y,[U,A]=DJ.default.useState(null),M,H;if(J[0]!==Z)M=()=>{if(A(null),OJ(Z))iJ(Z).then(A)},H=[Z],J[0]=Z,J[1]=M,J[2]=H;else M=J[1],H=J[2];DJ.default.useEffect(M,H);let L=OJ(Z)&&U===null,z=U??Z,G;if(J[3]!==z)G=o(z)||"",J[3]=z,J[4]=G;else G=J[4];let E=G,P;if(J[5]===Symbol.for("react.memo_cache_sentinel"))P=lJ(),J[5]=P;else P=J[5];let S=P,R;if(J[6]===Symbol.for("react.memo_cache_sentinel"))R={context:"Confirmation"},J[6]=R;else R=J[6];BJ("confirm:no",K,R);let k;if(J[7]!==U||J[8]!==Z||J[9]!==X)k=()=>{X(U??Z)},J[7]=U,J[8]=Z,J[9]=X,J[10]=k;else k=J[10];let c=k,d;if(J[11]===Symbol.for("react.memo_cache_sentinel"))d={context:"Confirmation"},J[11]=d;else d=J[11];if(BJ("confirm:yes",c,d),L){let T;if(J[12]===Symbol.for("react.memo_cache_sentinel"))T=Q(nJ,{message:"Loading session…"}),J[12]=T;else T=J[12];let w;if(J[13]===Symbol.for("react.memo_cache_sentinel"))w=B(v,{flexDirection:"column",padding:1,children:[T,Q(V,{dimColor:!0,children:Q(PJ,{children:Q(HJ,{action:"confirm:no",context:"Confirmation",fallback:"Esc",description:"cancel"})})})]}),J[13]=w;else w=J[13];return w}let x;if(J[14]===Symbol.for("react.memo_cache_sentinel"))x=[],J[14]=x;else x=J[14];let a,$;if(J[15]===Symbol.for("react.memo_cache_sentinel"))$=[],a=new Set,J[15]=a,J[16]=$;else a=J[15],$=J[16];let N;if(J[17]===Symbol.for("react.memo_cache_sentinel"))N=[],J[17]=N;else N=J[17];let O;if(J[18]!==E||J[19]!==z.messages)O=Q(rJ,{messages:z.messages,tools:S,commands:x,verbose:!0,toolJSX:null,toolUseConfirmQueue:$,inProgressToolUseIDs:a,isMessageSelectorVisible:!1,conversationId:E,screen:"transcript",streamingToolUses:N,showAllInTranscript:!0,isLoading:!1}),J[18]=E,J[19]=z.messages,J[20]=O;else O=J[20];let j;if(J[21]!==z.modified)j=QJ(z.modified),J[21]=z.modified,J[22]=j;else j=J[22];let l=z.gitBranch?` · ${z.gitBranch}`:"",f;if(J[23]!==z.messageCount||J[24]!==j||J[25]!==l)f=B(V,{children:[j," ·"," ",z.messageCount," messages",l]}),J[23]=z.messageCount,J[24]=j,J[25]=l,J[26]=f;else f=J[26];let i;if(J[27]===Symbol.for("react.memo_cache_sentinel"))i=Q(V,{dimColor:!0,children:B(PJ,{children:[Q(aJ,{shortcut:"Enter",action:"resume"}),Q(HJ,{action:"confirm:no",context:"Confirmation",fallback:"Esc",description:"cancel"})]})}),J[27]=i;else i=J[27];let I;if(J[28]!==f)I=B(v,{flexShrink:0,flexDirection:"column",borderTopDimColor:!0,borderBottom:!1,borderLeft:!1,borderRight:!1,borderStyle:"single",paddingLeft:2,children:[f,i]}),J[28]=f,J[29]=I;else I=J[29];let g;if(J[30]!==O||J[31]!==I)g=B(v,{flexDirection:"column",children:[O,I]}),J[30]=O,J[31]=I,J[32]=g;else g=J[32];return g}var oJ,DJ;var sJ=JJ(()=>{MJ();iY();tY();TJ();GJ();rY();oY();nY();sY();eY();t();oJ=NJ(lY(),1),DJ=NJ(dJ(),1)});function UZ(Y){let J=Math.max(16,Math.min(60,Math.round(Y*0.25))),Z=Math.max(QZ,Math.min(Math.round(Y*0.4),Y-YJ-eJ-J-JY)),K=Math.max(0,Y-YJ-eJ-Z-J-JY),X=Math.floor(K/4);return{title:Z,agents:QY+X,place:J,tokens:KY+X,cost:VY+X,when:qY+K-X*3}}function YY(Y,J){let Z=u(Y,J);return Z+" ".repeat(Math.max(0,J-b(Z)))}function m(Y,J){let Z=u(Y,J);return" ".repeat(Math.max(0,J-b(Z)))+Z}function GZ(Y,J,Z){let K=Z-2;if(!J)return{where:u(Y,K),branch:""};let X=K-b(Y)-3;if(X>=Math.min(8,b(J)))return{where:Y,branch:u(J,X)};return{where:"",branch:u(J,K-2)}}function FZ({where:Y,branch:J,width:Z}){let K=zY()?VZ:"⎇",X=GZ(Y,J,Z),U=X.branch?`${K} ${X.branch}`:"",A=` ${X.where}${X.where&&U?" ":""}${U} `,M=" ".repeat(Math.max(0,Z-b(A)));if(!X.where&&!U)return Q(V,{children:" ".repeat(Z)});return B(V,{children:[B(V,{backgroundColor:"messageActionsBackground",children:[` ${X.where}${X.where&&U?" ":""}`,Q(V,{color:"suggestion",children:U})," "]}),M]})}function BZ({row:Y,focused:J,columns:Z,dotVisible:K}){let X=Y.status==="current"?KZ:"",U=u(Y.title,Z.title-b(X)),A=" ".repeat(Math.max(0,Z.title-b(U)-b(X)));return B(V,{children:[Q(V,{color:"suggestion",children:J?`${ZY.pointer} `:" "}),Q(V,{color:qZ[Y.status],children:K?"● ":" "}),Q(V,{color:J?"suggestion":void 0,bold:J,children:U}),B(V,{dimColor:!0,children:[X,A,y]}),Q(V,{dimColor:Y.agents==="0",children:m(Y.agents,Z.agents)}),y,Q(FZ,{where:Y.where,branch:Y.branch,width:Z.place}),B(V,{dimColor:!0,children:[y,m(Y.tokens,Z.tokens),y]}),Q(V,{color:"claude",children:m(Y.cost,Z.cost)}),B(V,{dimColor:!0,children:[y,m(Y.when,Z.when)]})]})}function UY({rows:Y,lines:J,focusedIndex:Z,start:K,height:X,width:U}){let[A,M]=XY(Y.some((P)=>P.running)),H=UZ(U),L=" ".repeat(YJ)+YY("Description",H.title)+y+m("Agents",H.agents)+y+YY("Branch/worktree",H.place)+y+m("Tokens",H.tokens)+y+m("Cost",H.cost)+y+m("When",H.when),z=b(L),G="── inactive ",E="── inactive "+"─".repeat(Math.max(0,z-YJ-b("── inactive ")));return B(v,{ref:A,flexDirection:"column",flexShrink:0,children:[Q(V,{dimColor:!0,bold:!0,children:L}),Q(v,{flexDirection:"column",height:X*ZJ,children:J.slice(K,K+X).map((P)=>P.kind==="divider"?Q(v,{marginBottom:ZJ-1,children:B(V,{dimColor:!0,children:[" ".repeat(YJ),E]})},"divider"):Q(v,{marginBottom:ZJ-1,children:Q(BZ,{row:Y[P.index],focused:P.index===Z,columns:H,dotVisible:!Y[P.index].running||M})},Y[P.index].sessionId))})]})}var y=" ",YJ=4,eJ,QY=6,KY=7,VY=8,qY=8,JY,QZ=12,KZ=" (current)",VZ="",ZJ=2,qZ;var GY=JJ(()=>{ZZ();MJ();JZ();zZ();XZ();YZ();t();eJ=y.length*5,JY=QY+KY+VY+qY,qZ={current:"success",open:"success",elsewhere:"warning",inactive:"inactive"}});function _0({logs:Y,loading:J=!1,currentSessionId:Z,readCurrent:K=bZ,instanceSessionIds:X=RZ,getRunningWork:U,onSelect:A,onCancel:M,onLoadMore:H,onLogsChanged:L,showAllProjects:z,onToggleAllProjects:G,initialSearchQuery:E,maxHeight:P,loadLiveSessions:S=vY}){AY("sessions-screen");let R=NY(PY()),k=DY(),c=BY(),d=P??R.rows,x=R.columns-(k?2:4),a=d-WZ-(k?0:kZ),$=Math.max(2,Math.floor(a/ZJ)),[N,O]=D.default.useState("list"),[j,l]=D.default.useState([]),[f,i]=D.default.useState(()=>new Map),[I,g]=D.default.useState(),[T,w]=D.default.useState(),[p,_Y]=D.default.useState(),[KJ,yY]=D.default.useState(!1),[bY,XJ]=D.default.useState(""),[RY,CJ]=D.default.useState(0),[$Y,pY]=D.default.useState(),[VJ,LY]=D.default.useState(K),EJ=D.default.useRef(0);D.default.useEffect(()=>{let q=[],F=(e)=>{let gY=new Set(e.map((r)=>r.sessionId)),RJ=q.filter((r)=>!gY.has(r.sessionId)&&r.costUSD!==void 0);if(RJ.length>0)i((r)=>{let $J=new Map(r);for(let pJ of RJ)$J.set(pJ.sessionId,pJ.costUSD);return $J});q=e,l(e)},_=()=>{S().then(F,AJ),LY(K())};_();let n=setInterval(_,_Z);return()=>clearInterval(n)},[S,K]),D.default.useEffect(()=>{FY().then(_Y,AJ)},[]);let vJ=OY(M,void 0,N!=="rename"),{query:s,setQuery:jY,cursorOffset:fY}=CY({isActive:N==="search",onExit:()=>O("list"),onExitUp:()=>O("list"),initialQuery:E}),qJ=D.default.useMemo(()=>gJ({logs:Y,currentSessionId:Z,instanceSessionIds:X,liveElsewhere:j,releasedCostUSD:f,current:p?{...VJ,branch:p}:VJ,cwd:zJ(),now:new Date}),[Y,Z,X,j,f,VJ,p]),C=D.default.useMemo(()=>{let q=KJ&&p?qJ.filter((F)=>F.log?.gitBranch===p):qJ;return wJ(q,s)},[qJ,KJ,p,s]),UJ=D.default.useMemo(()=>hJ(C),[C]),WJ=C.findIndex((q)=>q.sessionId===$Y),IY=C[0]?.status==="current"&&C.length>1?1:0,h=WJ>=0?WJ:IY,W=C[h],TY=UJ.findIndex((q)=>q.kind==="row"&&q.index===h),kJ=uJ(EJ.current,Math.max(0,TY),$,UJ.length);EJ.current=kJ,D.default.useEffect(()=>{if(H&&h+$*2>=C.length)H($*3)},[h,C.length,$,H]);async function _J(q){if(q.status==="current"){M();return}if(!q.log)return;let F=await S();l(F);let _=F.find((e)=>e.sessionId===q.sessionId);if(_){g(`Open in another claudin (pid ${_.pid}, ${_.cwd}). Quit it there to continue here.`);return}let n=U?.();if(n){w({log:q.log,work:n}),O("confirm");return}A(q.log)}async function mY(q){let F=q.trim();if(W?.log&&F)await kY(W.sessionId,F,W.log.fullPath),L?.();XJ(""),O("list")}function yJ(q){let F=C[Math.max(0,Math.min(C.length-1,h+q))];if(F)pY(F.sessionId)}if(HY((q,F)=>{if(N==="confirm"){if(F.return&&T)A(T.log);else if(F.escape)w(void 0),O("list");return}if(N==="rename"){if(F.escape)XJ(""),O("list");return}if(g(void 0),F.upArrow)yJ(-1);else if(F.downArrow)yJ(1);else if(F.return){if(W)_J(W)}else if(F.escape)M();else if(F.ctrl){let _=q.toLowerCase();if(_==="a")G?.();else if(_==="b"&&p)yY((n)=>!n);else if(_==="v"&&W?.log)O("preview");else if(_==="r"&&W?.log)XJ(""),CJ(0),O("rename")}else if(q==="/")O("search");else if(q&&!F.meta&&!F.tab)jY(s+q),O("search")},{isActive:N==="list"||N==="confirm"||N==="rename"}),N==="preview"&&W?.log)return Q(tJ,{log:W.log,onExit:()=>O("list"),onSelect:()=>{O("list"),_J(W)}});let bJ=[z?"all projects":void 0,KJ&&p?`branch ${p}`:void 0].filter(Boolean),SY=N==="rename"&&W?B(v,{flexDirection:"row",children:[Q(V,{children:"Rename: "}),Q(WY,{value:bY,onChange:XJ,onSubmit:(q)=>void mY(q),placeholder:W.title,columns:Math.max(10,x-8),cursorOffset:RY,onChangeCursorOffset:CJ,showCursor:!0})]}):N==="confirm"&&T?B(V,{color:"warning",children:["Switching stops ",T.work," in this session. Enter to switch · Esc to stay"]}):I?Q(V,{color:"warning",children:I}):J?Q(V,{dimColor:!0,children:"Loading sessions…"}):C.length===0?Q(V,{dimColor:!0,children:s?"No sessions match.":"No sessions yet."}):Q(V,{children:" "}),xY=vJ.pending?`Press ${vJ.keyName} again to exit`:N==="search"?"Type to search · Enter/↓ to the list · Esc clear":N==="rename"?"Enter save · Esc cancel":["↑↓ select · Enter open · type to search",G?`Ctrl+A ${z?"this project":"all projects"}`:void 0,p?"Ctrl+B branch":void 0,"Ctrl+V preview · Ctrl+R rename · Esc close"].filter(Boolean).join(" · ");return Q(MY,{color:"suggestion",children:B(v,{flexDirection:"column",children:[B(V,{children:[Q(V,{bold:!0,color:"suggestion",children:"Sessions"}),B(V,{dimColor:!0,children:[C.length>0?` (${h+1} of ${C.length})`:"",bJ.length>0?` · ${bJ.join(" · ")}`:""]})]}),Q(EY,{query:s,placeholder:"Search…",isFocused:N==="search",isTerminalFocused:c,cursorOffset:fY}),Q(UY,{rows:C,lines:UJ,focusedIndex:h,start:kJ,height:$,width:x}),Q(v,{marginTop:1,children:SY}),Q(V,{dimColor:!0,children:xY})]})})}var D,WZ=8,kZ=2,_Z=1500,yZ,bZ=()=>yZ,RZ;var $Z=JJ(()=>{LJ();EZ();GJ();sJ();cJ();GY();SJ();DZ();MZ();NZ();OZ();AZ();PZ();MJ();CZ();vZ();HZ();t();D=NJ(dJ(),1),yZ={turnActive:!1,runningAgents:0,costUSD:0},RZ=[]});
3
+ export{fZ as Jd,hY as Kd,gZ as Ld,cJ as Md,_0 as Nd,$Z as Od};
@@ -0,0 +1,10 @@
1
+ import{mb as s}from"./cli-1.1.37-khfxdt5q.mjs";import{In as p,Jn as ZJ,Jp as x,Lp as a,Sr as k,Tr as M,Ur as m,uj as E,vj as w,xj as D}from"./cli-1.1.37-grsmntjy.mjs";import{B5 as S,E5 as QJ,K5 as o,L5 as h,M5 as u,R5 as c}from"./cli-1.1.37-x363x6yv.mjs";import{W5 as O,X5 as y}from"./cli-1.1.37-m1fep5be.mjs";import{H8 as i,p8 as P}from"./cli-1.1.37-07v28734.mjs";import{h_ as W,j_ as U}from"./cli-1.1.37-z4wav0zf.mjs";import{Qia as V,Tia as _,tia as B,uia as e,yia as C}from"./cli-1.1.37-sqyyjrzq.mjs";import{oja as H,pja as t,vja as r}from"./cli-1.1.37-240c02km.mjs";import{Bja as b,Jja as KJ}from"./cli-1.1.37-94bfnv5a.mjs";import{hqa as JJ}from"./cli-1.1.37-5k40cazp.mjs";i();_();U();D();C();class R extends Error{retryAfterMs;constructor(J,K){super(J);this.retryAfterMs=K}}class q{pending=[];pendingAtClose=0;draining=!1;closed=!1;backpressureResolvers=[];sleepResolve=null;flushResolvers=[];droppedBatches=0;config;constructor(J){this.config=J}get droppedBatchCount(){return this.droppedBatches}get pendingCount(){return this.closed?this.pendingAtClose:this.pending.length}async enqueue(J){if(this.closed)return;let K=Array.isArray(J)?J:[J];if(K.length===0)return;while(this.pending.length+K.length>this.config.maxQueueSize&&!this.closed)await new Promise((Q)=>{this.backpressureResolvers.push(Q)});if(this.closed)return;this.pending.push(...K),this.drain()}flush(){if(this.pending.length===0&&!this.draining)return Promise.resolve();return this.drain(),new Promise((J)=>{this.flushResolvers.push(J)})}close(){if(this.closed)return;this.closed=!0,this.pendingAtClose=this.pending.length,this.pending=[],this.sleepResolve?.(),this.sleepResolve=null;for(let J of this.backpressureResolvers)J();this.backpressureResolvers=[];for(let J of this.flushResolvers)J();this.flushResolvers=[]}async drain(){if(this.draining||this.closed)return;this.draining=!0;let J=0;try{while(this.pending.length>0&&!this.closed){let K=this.takeBatch();if(K.length===0)continue;try{await this.config.send(K),J=0}catch(Q){if(J++,this.config.maxConsecutiveFailures!==void 0&&J>=this.config.maxConsecutiveFailures){this.droppedBatches++,this.config.onBatchDropped?.(K.length,J),J=0,this.releaseBackpressure();continue}this.pending=K.concat(this.pending);let Z=Q instanceof R?Q.retryAfterMs:void 0;await this.sleep(this.retryDelay(J,Z));continue}this.releaseBackpressure()}}finally{if(this.draining=!1,this.pending.length===0){for(let K of this.flushResolvers)K();this.flushResolvers=[]}}}takeBatch(){let{maxBatchSize:J,maxBatchBytes:K}=this.config;if(K===void 0)return this.pending.splice(0,J);let Q=0,Z=0;while(Z<this.pending.length&&Z<J){let $;try{$=Buffer.byteLength(B(this.pending[Z]))}catch{this.pending.splice(Z,1);continue}if(Z>0&&Q+$>K)break;Q+=$,Z++}return this.pending.splice(0,Z)}retryDelay(J,K){let Q=Math.random()*this.config.jitterMs;if(K!==void 0)return Math.max(this.config.baseDelayMs,Math.min(K,this.config.maxDelayMs))+Q;return Math.min(this.config.baseDelayMs*2**(J-1),this.config.maxDelayMs)+Q}releaseBackpressure(){let J=this.backpressureResolvers;this.backpressureResolvers=[];for(let K of J)K()}sleep(J){return new Promise((K)=>{this.sleepResolve=K,setTimeout((Q,Z)=>{Q.sleepResolve=null,Z()},J,this,K)})}}ZJ();_();U();KJ();QJ();c();m();C();var $J=`{"type":"keep_alive"}
2
+ `,GJ=1000,VJ=1000,d=30000,WJ=600000,YJ=1e4,zJ=300000,I=d*2,XJ=new Set([1002,4001,4003]);class F{ws=null;lastSentId=null;url;state="idle";onData;onCloseCallback;onConnectCallback;headers;sessionId;autoReconnect;reconnectAttempts=0;reconnectStartTime=null;reconnectTimer=null;lastReconnectAttemptTime=null;lastActivityTime=0;pingInterval=null;pongReceived=!0;keepAliveInterval=null;messageBuffer;isBunWs=!1;connectStartTime=0;refreshHeaders;constructor(J,K={},Q,Z,$){this.url=J,this.headers=K,this.sessionId=Q,this.refreshHeaders=Z,this.autoReconnect=$?.autoReconnect??!0,this.messageBuffer=new p(GJ)}async connect(){if(this.state!=="idle"&&this.state!=="reconnecting"){V(`WebSocketTransport: Cannot connect, current state is ${this.state}`,{level:"error"}),W("error","cli_websocket_connect_failed");return}this.state="reconnecting",this.connectStartTime=Date.now(),V(`WebSocketTransport: Opening ${this.url.href}`),W("info","cli_websocket_connect_opening");let J={...this.headers};if(this.lastSentId)J["X-Last-Request-Id"]=this.lastSentId,V(`WebSocketTransport: Adding X-Last-Request-Id header: ${this.lastSentId}`);if(typeof Bun<"u"){let K=new globalThis.WebSocket(this.url.href,{headers:J,proxy:u(this.url.href),tls:S()||void 0});this.ws=K,this.isBunWs=!0,K.addEventListener("open",this.onBunOpen),K.addEventListener("message",this.onBunMessage),K.addEventListener("error",this.onBunError),K.addEventListener("close",this.onBunClose),K.addEventListener("pong",this.onPong)}else{let{default:K}=await import("./wrapper-1.1.37-mam70w68.mjs"),Q=new K(this.url.href,{headers:J,agent:h(this.url.href),...S()});this.ws=Q,this.isBunWs=!1,Q.on("open",this.onNodeOpen),Q.on("message",this.onNodeMessage),Q.on("error",this.onNodeError),Q.on("close",this.onNodeClose),Q.on("pong",this.onPong)}}onBunOpen=()=>{if(this.handleOpenEvent(),this.lastSentId)this.replayBufferedMessages("")};onBunMessage=(J)=>{let K=typeof J.data==="string"?J.data:String(J.data);if(this.lastActivityTime=Date.now(),W("info","cli_websocket_message_received",{length:K.length}),this.onData)this.onData(K)};onBunError=()=>{V("WebSocketTransport: Error",{level:"error"}),W("error","cli_websocket_connect_error")};onBunClose=(J)=>{let K=J.code===1000||J.code===1001;V(`WebSocketTransport: Closed: ${J.code}`,K?void 0:{level:"error"}),W("error","cli_websocket_connect_closed"),this.handleConnectionError(J.code)};onNodeOpen=()=>{let J=this.ws;if(this.handleOpenEvent(),!J)return;let Q=J.upgradeReq;if(Q?.headers?.["x-last-request-id"]){let Z=Q.headers["x-last-request-id"];this.replayBufferedMessages(Z)}};onNodeMessage=(J)=>{let K=J.toString();if(this.lastActivityTime=Date.now(),W("info","cli_websocket_message_received",{length:K.length}),this.onData)this.onData(K)};onNodeError=(J)=>{V(`WebSocketTransport: Error: ${J.message}`,{level:"error"}),W("error","cli_websocket_connect_error")};onNodeClose=(J,K)=>{let Q=J===1000||J===1001;V(`WebSocketTransport: Closed: ${J}`,Q?void 0:{level:"error"}),W("error","cli_websocket_connect_closed"),this.handleConnectionError(J)};onPong=()=>{this.pongReceived=!0};handleOpenEvent(){let J=Date.now()-this.connectStartTime;V("WebSocketTransport: Connected"),W("info","cli_websocket_connect_connected",{duration_ms:J}),this.reconnectAttempts=0,this.reconnectStartTime=null,this.lastReconnectAttemptTime=null,this.lastActivityTime=Date.now(),this.state="connected",this.onConnectCallback?.(),this.startPingInterval(),this.startKeepaliveInterval(),k(()=>{this.write({type:"keep_alive"})})}sendLine(J){if(!this.ws||this.state!=="connected")return V("WebSocketTransport: Not connected"),W("info","cli_websocket_send_not_connected"),!1;try{return this.ws.send(J),this.lastActivityTime=Date.now(),!0}catch(K){return V(`WebSocketTransport: Failed to send: ${K}`,{level:"error"}),W("error","cli_websocket_send_error"),this.handleConnectionError(),!1}}removeWsListeners(J){if(this.isBunWs){let K=J;K.removeEventListener("open",this.onBunOpen),K.removeEventListener("message",this.onBunMessage),K.removeEventListener("error",this.onBunError),K.removeEventListener("close",this.onBunClose),K.removeEventListener("pong",this.onPong)}else{let K=J;K.off("open",this.onNodeOpen),K.off("message",this.onNodeMessage),K.off("error",this.onNodeError),K.off("close",this.onNodeClose),K.off("pong",this.onPong)}}doDisconnect(){if(this.stopPingInterval(),this.stopKeepaliveInterval(),M(),this.ws)this.removeWsListeners(this.ws),this.ws.close(),this.ws=null}handleConnectionError(J){if(V(`WebSocketTransport: Disconnected from ${this.url.href}`+(J!=null?` (code ${J})`:"")),W("info","cli_websocket_disconnected"),this.doDisconnect(),this.state==="closing"||this.state==="closed")return;let K=!1;if(J===4003&&this.refreshHeaders){let $=this.refreshHeaders();if($.Authorization!==this.headers.Authorization)Object.assign(this.headers,$),K=!0,V("WebSocketTransport: 4003 received but headers refreshed, scheduling reconnect"),W("info","cli_websocket_4003_token_refreshed")}if(J!=null&&XJ.has(J)&&!K){V(`WebSocketTransport: Permanent close code ${J}, not reconnecting`,{level:"error"}),W("error","cli_websocket_permanent_close",{closeCode:J}),this.state="closed",this.onCloseCallback?.(J);return}if(!this.autoReconnect){this.state="closed",this.onCloseCallback?.(J);return}let Q=Date.now();if(!this.reconnectStartTime)this.reconnectStartTime=Q;if(this.lastReconnectAttemptTime!==null&&Q-this.lastReconnectAttemptTime>I)V(`WebSocketTransport: Detected system sleep (${Math.round((Q-this.lastReconnectAttemptTime)/1000)}s gap), resetting reconnection budget`),W("info","cli_websocket_sleep_detected",{gapMs:Q-this.lastReconnectAttemptTime}),this.reconnectStartTime=Q,this.reconnectAttempts=0;this.lastReconnectAttemptTime=Q;let Z=Q-this.reconnectStartTime;if(Z<WJ){if(this.reconnectTimer)clearTimeout(this.reconnectTimer),this.reconnectTimer=null;if(!K&&this.refreshHeaders){let Y=this.refreshHeaders();Object.assign(this.headers,Y),V("WebSocketTransport: Refreshed headers for reconnect")}this.state="reconnecting",this.reconnectAttempts++;let $=Math.min(VJ*Math.pow(2,this.reconnectAttempts-1),d),G=Math.max(0,$+$*0.25*(2*Math.random()-1));V(`WebSocketTransport: Reconnecting in ${Math.round(G)}ms (attempt ${this.reconnectAttempts}, ${Math.round(Z/1000)}s elapsed)`),W("error","cli_websocket_reconnect_attempt",{reconnectAttempts:this.reconnectAttempts}),this.reconnectTimer=setTimeout(()=>{this.reconnectTimer=null,this.connect()},G)}else if(V(`WebSocketTransport: Reconnection time budget exhausted after ${Math.round(Z/1000)}s for ${this.url.href}`,{level:"error"}),W("error","cli_websocket_reconnect_exhausted",{reconnectAttempts:this.reconnectAttempts,elapsedMs:Z}),this.state="closed",this.onCloseCallback)this.onCloseCallback(J)}close(){if(this.reconnectTimer)clearTimeout(this.reconnectTimer),this.reconnectTimer=null;this.stopPingInterval(),this.stopKeepaliveInterval(),M(),this.state="closing",this.doDisconnect()}replayBufferedMessages(J){let K=this.messageBuffer.toArray();if(K.length===0)return;let Q=0;if(J){let $=K.findIndex((G)=>("uuid"in G)&&G.uuid===J);if($>=0){Q=$+1;let G=K.slice(Q);if(this.messageBuffer.clear(),this.messageBuffer.addAll(G),G.length===0)this.lastSentId=null;V(`WebSocketTransport: Evicted ${Q} confirmed messages, ${G.length} remaining`),W("info","cli_websocket_evicted_confirmed_messages",{evicted:Q,remaining:G.length})}}let Z=K.slice(Q);if(Z.length===0){V("WebSocketTransport: No new messages to replay"),W("info","cli_websocket_no_messages_to_replay");return}V(`WebSocketTransport: Replaying ${Z.length} buffered messages`),W("info","cli_websocket_messages_to_replay",{count:Z.length});for(let $ of Z){let G=B($)+`
3
+ `;if(!this.sendLine(G)){this.handleConnectionError();break}}}isConnectedStatus(){return this.state==="connected"}isClosedStatus(){return this.state==="closed"}setOnData(J){this.onData=J}setOnConnect(J){this.onConnectCallback=J}setOnClose(J){this.onCloseCallback=J}getStateLabel(){return this.state}async write(J){if("uuid"in J&&typeof J.uuid==="string")this.messageBuffer.add(J),this.lastSentId=J.uuid;let K=B(J)+`
4
+ `;if(this.state!=="connected")return;let Q=this.sessionId?` session=${this.sessionId}`:"",Z=this.getControlMessageDetailLabel(J);V(`WebSocketTransport: Sending message type=${J.type}${Q}${Z}`),this.sendLine(K)}getControlMessageDetailLabel(J){if(J.type==="control_request"){let{request_id:K,request:Q}=J,Z=Q.subtype==="can_use_tool"?Q.tool_name:"";return` subtype=${Q.subtype} request_id=${K}${Z?` tool=${Z}`:""}`}if(J.type==="control_response"){let{subtype:K,request_id:Q}=J.response;return` subtype=${K} request_id=${Q}`}return""}startPingInterval(){this.stopPingInterval(),this.pongReceived=!0;let J=Date.now();this.pingInterval=setInterval(()=>{if(this.state==="connected"&&this.ws){let K=Date.now(),Q=K-J;if(J=K,Q>I){V(`WebSocketTransport: ${Math.round(Q/1000)}s tick gap detected — process was suspended, forcing reconnect`),W("info","cli_websocket_sleep_detected_on_ping",{gapMs:Q}),this.handleConnectionError();return}if(!this.pongReceived){V("WebSocketTransport: No pong received, connection appears dead",{level:"error"}),W("error","cli_websocket_pong_timeout"),this.handleConnectionError();return}this.pongReceived=!1;try{this.ws.ping?.()}catch(Z){V(`WebSocketTransport: Ping failed: ${Z}`,{level:"error"}),W("error","cli_websocket_ping_failed")}}},YJ)}stopPingInterval(){if(this.pingInterval)clearInterval(this.pingInterval),this.pingInterval=null}startKeepaliveInterval(){if(this.stopKeepaliveInterval(),b(process.env.CLAUDE_CODE_REMOTE))return;this.keepAliveInterval=setInterval(()=>{if(this.state==="connected"&&this.ws)try{this.ws.send($J),this.lastActivityTime=Date.now(),V("WebSocketTransport: Sent periodic keep_alive data frame")}catch(J){V(`WebSocketTransport: Periodic keep_alive failed: ${J}`,{level:"error"}),W("error","cli_websocket_keepalive_failed")}},zJ)}stopKeepaliveInterval(){if(this.keepAliveInterval)clearInterval(this.keepAliveInterval),this.keepAliveInterval=null}}var LJ=100,jJ=15000,BJ=3000;class qJ extends F{postUrl;uploader;streamEventBuffer=[];streamEventTimer=null;constructor(J,K={},Q,Z,$){super(J,K,Q,Z,$);let{maxConsecutiveFailures:G,onBatchDropped:Y}=$??{};this.postUrl=OJ(J),this.uploader=new q({maxBatchSize:500,maxQueueSize:1e5,baseDelayMs:500,maxDelayMs:8000,jitterMs:1000,maxConsecutiveFailures:G,onBatchDropped:(X,z)=>{W("error","cli_hybrid_batch_dropped_max_failures",{batchSize:X,failures:z}),Y?.(X,z)},send:(X)=>this.postOnce(X)}),V(`HybridTransport: POST URL = ${this.postUrl}`),W("info","cli_hybrid_transport_initialized")}async write(J){if(J.type==="stream_event"){if(this.streamEventBuffer.push(J),!this.streamEventTimer)this.streamEventTimer=setTimeout(()=>this.flushStreamEvents(),LJ);return}return await this.uploader.enqueue([...this.takeStreamEvents(),J]),this.uploader.flush()}async writeBatch(J){return await this.uploader.enqueue([...this.takeStreamEvents(),...J]),this.uploader.flush()}get droppedBatchCount(){return this.uploader.droppedBatchCount}flush(){return this.uploader.enqueue(this.takeStreamEvents()),this.uploader.flush()}takeStreamEvents(){if(this.streamEventTimer)clearTimeout(this.streamEventTimer),this.streamEventTimer=null;let J=this.streamEventBuffer;return this.streamEventBuffer=[],J}flushStreamEvents(){this.streamEventTimer=null,this.uploader.enqueue(this.takeStreamEvents())}close(){if(this.streamEventTimer)clearTimeout(this.streamEventTimer),this.streamEventTimer=null;this.streamEventBuffer=[];let J=this.uploader,K;Promise.race([J.flush(),new Promise((Q)=>{K=setTimeout(Q,BJ)})]).finally(()=>{clearTimeout(K),J.close()}),super.close()}async postOnce(J){let K=E();if(!K){V("HybridTransport: No session token available for POST"),W("warn","cli_hybrid_post_no_token");return}let Q={Authorization:`Bearer ${K}`,"Content-Type":"application/json"},Z;try{Z=await P.post(this.postUrl,{events:J},{headers:Q,validateStatus:()=>!0,timeout:jJ})}catch($){throw V(`HybridTransport: POST error: ${$.message}`),W("warn","cli_hybrid_post_network_error"),$}if(Z.status>=200&&Z.status<300){V(`HybridTransport: POST success count=${J.length}`);return}if(Z.status>=400&&Z.status<500&&Z.status!==429){V(`HybridTransport: POST returned ${Z.status} (permanent), dropping`),W("warn","cli_hybrid_post_client_error",{status:Z.status});return}throw V(`HybridTransport: POST returned ${Z.status} (retryable)`),W("warn","cli_hybrid_post_retryable_error",{status:Z.status}),Error(`POST failed with ${Z.status}`)}}function OJ(J){let K=J.protocol==="wss:"?"https:":"http:",Q=J.pathname;if(Q=Q.replace("/ws/","/session/"),!Q.endsWith("/events"))Q=Q.endsWith("/")?Q+"events":Q+"/events";return`${K}//${J.host}${Q}${J.search}`}import{randomUUID as l}from"crypto";_();U();r();c();m();D();y();a();y();class f{inflight=null;pending=null;closed=!1;config;constructor(J){this.config=J}enqueue(J){if(this.closed)return;this.pending=this.pending?g(this.pending,J):J,this.drain()}close(){this.closed=!0,this.pending=null}async drain(){if(this.inflight||this.closed)return;if(!this.pending)return;let J=this.pending;this.pending=null,this.inflight=this.sendWithRetry(J).then(()=>{if(this.inflight=null,this.pending&&!this.closed)this.drain()})}async sendWithRetry(J){let K=J,Q=0;while(!this.closed){if(await this.config.send(K))return;if(Q++,await O(this.retryDelay(Q)),this.pending&&!this.closed)K=g(K,this.pending),this.pending=null}}retryDelay(J){let K=Math.min(this.config.baseDelayMs*2**(J-1),this.config.maxDelayMs),Q=Math.random()*this.config.jitterMs;return K+Q}}function g(J,K){let Q={...J};for(let[Z,$]of Object.entries(K))if((Z==="external_metadata"||Z==="internal_metadata")&&Q[Z]&&typeof Q[Z]==="object"&&typeof $==="object"&&$!==null)Q[Z]={...Q[Z],...$};else Q[Z]=$;return Q}var HJ=20000,RJ=100;function n(){return!0}class N extends Error{reason;constructor(J){super(`CCRClient init failed: ${J}`);this.reason=J}}var xJ=10;function MJ(){return{byMessage:new Map,scopeToMessage:new Map}}function T(J){return`${J.session_id}:${J.parent_tool_use_id??""}`}function AJ(J,K){let Q=[],Z=new Map;for(let $ of J){let G=$.event;switch(G.type){case"message_start":{let Y=G.message.id,X=K.scopeToMessage.get(T($));if(X)K.byMessage.delete(X);K.scopeToMessage.set(T($),Y),K.byMessage.set(Y,[]),Q.push($);break}case"content_block_delta":{if(G.delta.type!=="text_delta"){Q.push($);break}let Y=K.scopeToMessage.get(T($)),X=Y?K.byMessage.get(Y):void 0;if(!X){Q.push($);break}let z=X[G.index]??=[];z.push(G.delta.text);let L=Z.get(z);if(L){L.event.delta.text=z.join("");break}let j={type:"stream_event",uuid:$.uuid,session_id:$.session_id,parent_tool_use_id:$.parent_tool_use_id,event:{type:"content_block_delta",index:G.index,delta:{type:"text_delta",text:z.join("")}}};Z.set(z,j),Q.push(j);break}default:Q.push($)}}return Q}function _J(J,K){J.byMessage.delete(K.message.id);let Q=T(K);if(J.scopeToMessage.get(Q)===K.message.id)J.scopeToMessage.delete(Q)}class UJ{workerEpoch=0;heartbeatIntervalMs;heartbeatJitterFraction;heartbeatTimer=null;heartbeatInFlight=!1;closed=!1;consecutiveAuthFailures=0;currentState=null;sessionBaseUrl;sessionId;http=o({keepAlive:!0});streamEventBuffer=[];streamEventTimer=null;streamTextAccumulator=MJ();workerState;eventUploader;internalEventUploader;deliveryUploader;onEpochMismatch;getAuthHeaders;constructor(J,K,Q){if(this.onEpochMismatch=Q?.onEpochMismatch??(()=>{process.exit(1)}),this.heartbeatIntervalMs=Q?.heartbeatIntervalMs??HJ,this.heartbeatJitterFraction=Q?.heartbeatJitterFraction??0,this.getAuthHeaders=Q?.getAuthHeaders??w,K.protocol!=="http:"&&K.protocol!=="https:")throw Error(`CCRClient: Expected http(s) URL, got ${K.protocol}`);let Z=K.pathname.replace(/\/$/,"");this.sessionBaseUrl=`${K.protocol}//${K.host}${Z}`,this.sessionId=Z.split("/").pop()||"",this.workerState=new f({send:($)=>this.request("put","/worker",{worker_epoch:this.workerEpoch,...$},"PUT worker").then((G)=>G.ok),baseDelayMs:500,maxDelayMs:30000,jitterMs:500}),this.eventUploader=new q({maxBatchSize:100,maxBatchBytes:10485760,maxQueueSize:1e5,send:async($)=>{let G=await this.request("post","/worker/events",{worker_epoch:this.workerEpoch,events:$},"client events");if(!G.ok)throw new R("client event POST failed",G.retryAfterMs)},baseDelayMs:500,maxDelayMs:30000,jitterMs:500}),this.internalEventUploader=new q({maxBatchSize:100,maxBatchBytes:10485760,maxQueueSize:200,send:async($)=>{let G=await this.request("post","/worker/internal-events",{worker_epoch:this.workerEpoch,events:$},"internal events");if(!G.ok)throw new R("internal event POST failed",G.retryAfterMs)},baseDelayMs:500,maxDelayMs:30000,jitterMs:500}),this.deliveryUploader=new q({maxBatchSize:64,maxQueueSize:64,send:async($)=>{let G=await this.request("post","/worker/events/delivery",{worker_epoch:this.workerEpoch,updates:$.map((Y)=>({event_id:Y.eventId,status:Y.status}))},"delivery batch");if(!G.ok)throw new R("delivery POST failed",G.retryAfterMs)},baseDelayMs:500,maxDelayMs:30000,jitterMs:500}),J.setOnEvent(($)=>{this.reportDelivery($.event_id,"received")})}async initialize(J){let K=Date.now();if(Object.keys(this.getAuthHeaders()).length===0)throw new N("no_auth_headers");if(J===void 0){let Y=process.env.CLAUDE_CODE_WORKER_EPOCH;J=Y?parseInt(Y,10):NaN}if(isNaN(J))throw new N("missing_epoch");this.workerEpoch=J;let Q=this.getWorkerState();if(!(await this.request("put","/worker",{worker_status:"idle",worker_epoch:this.workerEpoch,external_metadata:{pending_action:null,task_summary:null}},"PUT worker (init)")).ok)throw new N("worker_register_failed");this.currentState="idle",this.startHeartbeat(),k(()=>{this.writeEvent({type:"keep_alive"})}),V(`CCRClient: initialized, epoch=${this.workerEpoch}`),W("info","cli_worker_lifecycle_initialized",{epoch:this.workerEpoch,duration_ms:Date.now()-K});let{metadata:$,durationMs:G}=await Q;if(!this.closed)W("info","cli_worker_state_restored",{duration_ms:G,had_state:$!==null});return $}async getWorkerState(){let J=Date.now(),K=this.getAuthHeaders();if(Object.keys(K).length===0)return{metadata:null,durationMs:0};return{metadata:(await this.getWithRetry(`${this.sessionBaseUrl}/worker`,K,"worker_state"))?.worker?.external_metadata??null,durationMs:Date.now()-J}}async request(J,K,Q,Z,{timeout:$=1e4}={}){let G=this.getAuthHeaders();if(Object.keys(G).length===0)return{ok:!1};try{let Y=await this.http[J](`${this.sessionBaseUrl}${K}`,Q,{headers:{...G,"Content-Type":"application/json","anthropic-version":"2023-06-01","User-Agent":x()},validateStatus:n,timeout:$});if(Y.status>=200&&Y.status<300)return this.consecutiveAuthFailures=0,{ok:!0};if(Y.status===409)this.handleEpochMismatch();if(Y.status===401||Y.status===403){let X=E(),z=X?s(X):null;if(z!==null&&z*1000<Date.now())V(`CCRClient: session_token expired (exp=${new Date(z*1000).toISOString()}) — no refresh was delivered, exiting`,{level:"error"}),W("error","cli_worker_token_expired_no_refresh"),this.onEpochMismatch();if(this.consecutiveAuthFailures++,this.consecutiveAuthFailures>=xJ)V(`CCRClient: ${this.consecutiveAuthFailures} consecutive auth failures with a valid-looking token — server-side auth unrecoverable, exiting`,{level:"error"}),W("error","cli_worker_auth_failures_exhausted"),this.onEpochMismatch()}if(V(`CCRClient: ${Z} returned ${Y.status}`,{level:"warn"}),W("warn","cli_worker_request_failed",{method:J,path:K,status:Y.status}),Y.status===429){let X=Y.headers?.["retry-after"],z=typeof X==="string"?parseInt(X,10):NaN;if(!isNaN(z)&&z>=0)return{ok:!1,retryAfterMs:z*1000}}return{ok:!1}}catch(Y){return V(`CCRClient: ${Z} failed: ${H(Y)}`,{level:"warn"}),W("warn","cli_worker_request_error",{method:J,path:K,error_code:t(Y)}),{ok:!1}}}reportState(J,K){if(J===this.currentState&&!K)return;this.currentState=J,this.workerState.enqueue({worker_status:J,requires_action_details:K?{tool_name:K.tool_name,action_description:K.action_description,request_id:K.request_id}:null})}reportMetadata(J){this.workerState.enqueue({external_metadata:J})}handleEpochMismatch(){V("CCRClient: Epoch mismatch (409), shutting down",{level:"error"}),W("error","cli_worker_epoch_mismatch"),this.onEpochMismatch()}startHeartbeat(){this.stopHeartbeat();let J=()=>{let Q=this.heartbeatIntervalMs*this.heartbeatJitterFraction*(2*Math.random()-1);this.heartbeatTimer=setTimeout(K,this.heartbeatIntervalMs+Q)},K=()=>{if(this.sendHeartbeat(),this.heartbeatTimer===null)return;J()};J()}stopHeartbeat(){if(this.heartbeatTimer)clearTimeout(this.heartbeatTimer),this.heartbeatTimer=null}async sendHeartbeat(){if(this.heartbeatInFlight)return;this.heartbeatInFlight=!0;try{if((await this.request("post","/worker/heartbeat",{session_id:this.sessionId,worker_epoch:this.workerEpoch},"Heartbeat",{timeout:5000})).ok)V("CCRClient: Heartbeat sent")}finally{this.heartbeatInFlight=!1}}async writeEvent(J){if(J.type==="stream_event"){if(this.streamEventBuffer.push(J),!this.streamEventTimer)this.streamEventTimer=setTimeout(()=>void this.flushStreamEventBuffer(),RJ);return}if(await this.flushStreamEventBuffer(),J.type==="assistant")_J(this.streamTextAccumulator,J);await this.eventUploader.enqueue(this.toClientEvent(J))}toClientEvent(J){let K=J;return{payload:{...K,uuid:typeof K.uuid==="string"?K.uuid:l()}}}async flushStreamEventBuffer(){if(this.streamEventTimer)clearTimeout(this.streamEventTimer),this.streamEventTimer=null;if(this.streamEventBuffer.length===0)return;let J=this.streamEventBuffer;this.streamEventBuffer=[];let K=AJ(J,this.streamTextAccumulator);await this.eventUploader.enqueue(K.map((Q)=>({payload:Q,ephemeral:!0})))}async writeInternalEvent(J,K,{isCompaction:Q=!1,agentId:Z}={}){let $={payload:{type:J,...K,uuid:typeof K.uuid==="string"?K.uuid:l()},...Q&&{is_compaction:!0},...Z&&{agent_id:Z}};await this.internalEventUploader.enqueue($)}flushInternalEvents(){return this.internalEventUploader.flush()}async flush(){return await this.flushStreamEventBuffer(),this.eventUploader.flush()}async readInternalEvents(){return this.paginatedGet("/worker/internal-events",{},"internal_events")}async readSubagentInternalEvents(){return this.paginatedGet("/worker/internal-events",{subagents:"true"},"subagent_events")}async paginatedGet(J,K,Q){let Z=this.getAuthHeaders();if(Object.keys(Z).length===0)return null;let $=[],G;do{let Y=new URL(`${this.sessionBaseUrl}${J}`);for(let[z,L]of Object.entries(K))Y.searchParams.set(z,L);if(G)Y.searchParams.set("cursor",G);let X=await this.getWithRetry(Y.toString(),Z,Q);if(!X)return null;$.push(...X.data??[]),G=X.next_cursor}while(G);return V(`CCRClient: Read ${$.length} internal events from ${J}${K.subagents?" (subagents)":""}`),$}async getWithRetry(J,K,Q){for(let Z=1;Z<=10;Z++){let $;try{$=await this.http.get(J,{headers:{...K,"anthropic-version":"2023-06-01","User-Agent":x()},validateStatus:n,timeout:30000})}catch(G){if(V(`CCRClient: GET ${J} failed (attempt ${Z}/10): ${H(G)}`,{level:"warn"}),Z<10){let Y=Math.min(500*2**(Z-1),30000)+Math.random()*500;await O(Y)}continue}if($.status>=200&&$.status<300)return $.data;if($.status===409)this.handleEpochMismatch();if(V(`CCRClient: GET ${J} returned ${$.status} (attempt ${Z}/10)`,{level:"warn"}),Z<10){let G=Math.min(500*2**(Z-1),30000)+Math.random()*500;await O(G)}}return V("CCRClient: GET retries exhausted",{level:"error"}),W("error","cli_worker_get_retries_exhausted",{context:Q}),null}reportDelivery(J,K){this.deliveryUploader.enqueue({eventId:J,status:K})}getWorkerEpoch(){return this.workerEpoch}get internalEventsPending(){return this.internalEventUploader.pendingCount}close(){if(this.closed=!0,this.stopHeartbeat(),M(),this.streamEventTimer)clearTimeout(this.streamEventTimer),this.streamEventTimer=null;this.streamEventBuffer=[],this.streamTextAccumulator.byMessage.clear(),this.streamTextAccumulator.scopeToMessage.clear(),this.workerState.close(),this.eventUploader.close(),this.internalEventUploader.close(),this.deliveryUploader.close()}}i();_();U();r();D();y();C();a();var kJ=1000,PJ=30000,EJ=600000,NJ=45000,TJ=new Set([401,403,404]),A=10,wJ=500,CJ=8000,SJ={stream:!0};function FJ(){return!0}function DJ(J){let K=[],Q=0,Z;while((Z=J.indexOf(`
5
+
6
+ `,Q))!==-1){let $=J.slice(Q,Z);if(Q=Z+2,!$.trim())continue;let G={},Y=!1;for(let X of $.split(`
7
+ `)){if(X.startsWith(":")){Y=!0;continue}let z=X.indexOf(":");if(z===-1)continue;let L=X.slice(0,z),j=X[z+1]===" "?X.slice(z+2):X.slice(z+1);switch(L){case"event":G.event=j;break;case"id":G.id=j;break;case"data":G.data=G.data?G.data+`
8
+ `+j:j;break}}if(G.data||Y)K.push(G)}return{frames:K,remaining:J.slice(Q)}}class yJ{url;state="idle";onData;onCloseCallback;onEventCallback;headers;sessionId;refreshHeaders;getAuthHeaders;abortController=null;lastSequenceNum=0;seenSequenceNums=new Set;reconnectAttempts=0;reconnectStartTime=null;reconnectTimer=null;livenessTimer=null;postUrl;constructor(J,K={},Q,Z,$,G){this.url=J;if(this.headers=K,this.sessionId=Q,this.refreshHeaders=Z,this.getAuthHeaders=G??w,this.postUrl=fJ(J),$!==void 0&&$>0)this.lastSequenceNum=$;V(`SSETransport: SSE URL = ${J.href}`),V(`SSETransport: POST URL = ${this.postUrl}`),W("info","cli_sse_transport_initialized")}getLastSequenceNum(){return this.lastSequenceNum}async connect(){if(this.state!=="idle"&&this.state!=="reconnecting"){V(`SSETransport: Cannot connect, current state is ${this.state}`,{level:"error"}),W("error","cli_sse_connect_failed");return}this.state="reconnecting";let J=Date.now(),K=new URL(this.url.href);if(this.lastSequenceNum>0)K.searchParams.set("from_sequence_num",String(this.lastSequenceNum));let Q=this.getAuthHeaders(),Z={...this.headers,...Q,Accept:"text/event-stream","anthropic-version":"2023-06-01","User-Agent":x()};if(Q.Cookie)delete Z.Authorization;if(this.lastSequenceNum>0)Z["Last-Event-ID"]=String(this.lastSequenceNum);V(`SSETransport: Opening ${K.href}`),W("info","cli_sse_connect_opening"),this.abortController=new AbortController;try{let $=await fetch(K.href,{headers:Z,signal:this.abortController.signal});if(!$.ok){let Y=TJ.has($.status);if(V(`SSETransport: HTTP ${$.status}${Y?" (permanent)":""}`,{level:"error"}),W("error","cli_sse_connect_http_error",{status:$.status}),Y){this.state="closed",this.onCloseCallback?.($.status);return}this.handleConnectionError();return}if(!$.body){V("SSETransport: No response body"),this.handleConnectionError();return}let G=Date.now()-J;V("SSETransport: Connected"),W("info","cli_sse_connect_connected",{duration_ms:G}),this.state="connected",this.reconnectAttempts=0,this.reconnectStartTime=null,this.resetLivenessTimer(),await this.readStream($.body)}catch($){if(this.abortController?.signal.aborted)return;V(`SSETransport: Connection error: ${H($)}`,{level:"error"}),W("error","cli_sse_connect_error"),this.handleConnectionError()}}async readStream(J){let K=J.getReader(),Q=new TextDecoder,Z="";try{while(!0){let{done:$,value:G}=await K.read();if($)break;Z+=Q.decode(G,SJ);let{frames:Y,remaining:X}=DJ(Z);Z=X;for(let z of Y){if(this.resetLivenessTimer(),z.id){let L=parseInt(z.id,10);if(!isNaN(L)){if(this.seenSequenceNums.has(L))V(`SSETransport: DUPLICATE frame seq=${L} (lastSequenceNum=${this.lastSequenceNum}, seenCount=${this.seenSequenceNums.size})`,{level:"warn"}),W("warn","cli_sse_duplicate_sequence");else if(this.seenSequenceNums.add(L),this.seenSequenceNums.size>1000){let j=this.lastSequenceNum-200;for(let v of this.seenSequenceNums)if(v<j)this.seenSequenceNums.delete(v)}if(L>this.lastSequenceNum)this.lastSequenceNum=L}}if(z.event&&z.data)this.handleSSEFrame(z.event,z.data);else if(z.data)V("SSETransport: Frame has data: but no event: field — dropped",{level:"warn"}),W("warn","cli_sse_frame_missing_event_field")}}}catch($){if(this.abortController?.signal.aborted)return;V(`SSETransport: Stream read error: ${H($)}`,{level:"error"}),W("error","cli_sse_stream_read_error")}finally{K.releaseLock()}if(this.state!=="closing"&&this.state!=="closed")V("SSETransport: Stream ended, reconnecting"),this.handleConnectionError()}handleSSEFrame(J,K){if(J!=="client_event"){V(`SSETransport: Unexpected SSE event type '${J}' on worker stream`,{level:"warn"}),W("warn","cli_sse_unexpected_event_type",{event_type:J});return}let Q;try{Q=e(K)}catch($){V(`SSETransport: Failed to parse client_event data: ${H($)}`,{level:"error"});return}let Z=Q.payload;if(Z&&typeof Z==="object"&&"type"in Z){let $=this.sessionId?` session=${this.sessionId}`:"";V(`SSETransport: Event seq=${Q.sequence_num} event_id=${Q.event_id} event_type=${Q.event_type} payload_type=${String(Z.type)}${$}`),W("info","cli_sse_message_received"),this.onData?.(B(Z)+`
9
+ `)}else V(`SSETransport: Ignoring client_event with no type in payload: event_id=${Q.event_id}`);this.onEventCallback?.(Q)}handleConnectionError(){if(this.clearLivenessTimer(),this.state==="closing"||this.state==="closed")return;this.abortController?.abort(),this.abortController=null;let J=Date.now();if(!this.reconnectStartTime)this.reconnectStartTime=J;let K=J-this.reconnectStartTime;if(K<EJ){if(this.reconnectTimer)clearTimeout(this.reconnectTimer),this.reconnectTimer=null;if(this.refreshHeaders){let $=this.refreshHeaders();Object.assign(this.headers,$),V("SSETransport: Refreshed headers for reconnect")}this.state="reconnecting",this.reconnectAttempts++;let Q=Math.min(kJ*Math.pow(2,this.reconnectAttempts-1),PJ),Z=Math.max(0,Q+Q*0.25*(2*Math.random()-1));V(`SSETransport: Reconnecting in ${Math.round(Z)}ms (attempt ${this.reconnectAttempts}, ${Math.round(K/1000)}s elapsed)`),W("error","cli_sse_reconnect_attempt",{reconnectAttempts:this.reconnectAttempts}),this.reconnectTimer=setTimeout(()=>{this.reconnectTimer=null,this.connect()},Z)}else V(`SSETransport: Reconnection time budget exhausted after ${Math.round(K/1000)}s`,{level:"error"}),W("error","cli_sse_reconnect_exhausted",{reconnectAttempts:this.reconnectAttempts,elapsedMs:K}),this.state="closed",this.onCloseCallback?.()}onLivenessTimeout=()=>{this.livenessTimer=null,V("SSETransport: Liveness timeout, reconnecting",{level:"error"}),W("error","cli_sse_liveness_timeout"),this.abortController?.abort(),this.handleConnectionError()};resetLivenessTimer(){this.clearLivenessTimer(),this.livenessTimer=setTimeout(this.onLivenessTimeout,NJ)}clearLivenessTimer(){if(this.livenessTimer)clearTimeout(this.livenessTimer),this.livenessTimer=null}async write(J){let K=this.getAuthHeaders();if(Object.keys(K).length===0){V("SSETransport: No session token available for POST"),W("warn","cli_sse_post_no_token");return}let Q={...K,"Content-Type":"application/json","anthropic-version":"2023-06-01","User-Agent":x()};V(`SSETransport: POST body keys=${Object.keys(J).join(",")}`);for(let Z=1;Z<=A;Z++){try{let G=await P.post(this.postUrl,J,{headers:Q,validateStatus:FJ});if(G.status===200||G.status===201){V(`SSETransport: POST success type=${J.type}`);return}if(V(`SSETransport: POST ${G.status} body=${B(G.data).slice(0,200)}`),G.status>=400&&G.status<500&&G.status!==429){V(`SSETransport: POST returned ${G.status} (client error), not retrying`),W("warn","cli_sse_post_client_error",{status:G.status});return}V(`SSETransport: POST returned ${G.status}, attempt ${Z}/${A}`),W("warn","cli_sse_post_retryable_error",{status:G.status,attempt:Z})}catch(G){V(`SSETransport: POST error: ${G.message}, attempt ${Z}/${A}`),W("warn","cli_sse_post_network_error",{attempt:Z})}if(Z===A){V(`SSETransport: POST failed after ${A} attempts, continuing`),W("warn","cli_sse_post_retries_exhausted");return}let $=Math.min(wJ*Math.pow(2,Z-1),CJ);await O($)}}isConnectedStatus(){return this.state==="connected"}isClosedStatus(){return this.state==="closed"}setOnData(J){this.onData=J}setOnClose(J){this.onCloseCallback=J}setOnEvent(J){this.onEventCallback=J}close(){if(this.reconnectTimer)clearTimeout(this.reconnectTimer),this.reconnectTimer=null;this.clearLivenessTimer(),this.state="closing",this.abortController?.abort(),this.abortController=null}}function fJ(J){let K=J.pathname;if(K.endsWith("/stream"))K=K.slice(0,-7);return`${J.protocol}//${J.host}${K}`}
10
+ export{F as Wa,qJ as Xa,N as Ya,UJ as Za,yJ as _a};
@@ -0,0 +1,2 @@
1
+ import{cs as M,gs as qq,qp as h,sp as Oq,tp as n,vp as Wq}from"./cli-1.1.37-grsmntjy.mjs";import{H8 as r,p8 as f}from"./cli-1.1.37-07v28734.mjs";import{Kfa as S,Pba as c,Pfa as e,Rba as d,Uba as g,Vba as u,_ba as Vq}from"./cli-1.1.37-z4wav0zf.mjs";import{Vga as m,Wga as Uq}from"./cli-1.1.37-41q5f236.mjs";import{Cia as L,Gia as T,Qia as U,Tia as t,tia as y,uia as R,yia as P}from"./cli-1.1.37-sqyyjrzq.mjs";import{oja as V,pja as O,qja as D,vja as _}from"./cli-1.1.37-240c02km.mjs";import{gqa as N}from"./cli-1.1.37-5k40cazp.mjs";import{homedir as o}from"os";import{resolve as s}from"path";async function Dq(Q){let q=Q.trim(),$=L(),X=q.match(/^([a-zA-Z0-9._-]+@[^:]+:.+?(?:\.git)?)(#(.+))?$/);if(X?.[1]){let z=X[1],G=X[3];return G?{source:"git",url:z,ref:G}:{source:"git",url:z}}if(q.startsWith("http://")||q.startsWith("https://")){let z=q.match(/^([^#]+)(#(.+))?$/),G=z?.[1]||q,Z=z?.[3];if(G.endsWith(".git")||G.includes("/_git/"))return Z?{source:"git",url:G,ref:Z}:{source:"git",url:G};let Y;try{Y=new URL(G)}catch(x){return{source:"url",url:G}}if(Y.hostname==="github.com"||Y.hostname==="www.github.com"){if(Y.pathname.match(/^\/([^/]+\/[^/]+?)(\/|\.git|$)/)?.[1]){let J=G.endsWith(".git")?G:`${G}.git`;return Z?{source:"git",url:J,ref:Z}:{source:"git",url:J}}}return{source:"url",url:G}}let K=process.platform==="win32"&&(q.startsWith(".\\")||q.startsWith("..\\")||/^[a-zA-Z]:[/\\]/.test(q));if(q.startsWith("./")||q.startsWith("../")||q.startsWith("/")||q.startsWith("~")||K){let z=s(q.startsWith("~")?q.replace(/^~/,o()):q),G;try{G=await $.stat(z)}catch(Z){let Y=O(Z);return{error:Y==="ENOENT"?`Path does not exist: ${z}`:`Cannot access path: ${z} (${Y??Z})`}}if(G.isFile())if(z.endsWith(".json"))return{source:"file",path:z};else return{error:`File path must point to a .json file (marketplace.json), but got: ${z}`};else if(G.isDirectory())return{source:"directory",path:z};else return{error:`Path is neither a file nor a directory: ${z}`}}if(q.includes("/")&&!q.startsWith("@")){if(q.includes(":"))return null;let z=q.match(/^([^#@]+)(?:[#@](.+))?$/),G=z?.[1]||q,Z=z?.[2];return Z?{source:"github",repo:G,ref:Z}:{source:"github",repo:G}}return null}var a=N(()=>{_();T()});import{randomBytes as Qq}from"crypto";import{readFile as Xq,rename as Zq,unlink as $q,writeFile as Bq}from"fs/promises";import{join as Gq}from"path";function p(){return Gq(M(),Yq)}async function Jq(){let Q=p();try{let q=await Xq(Q,{encoding:"utf-8"}),$=R(q);if(typeof $!=="object"||$===null||!("version"in $)||!("fetchedAt"in $)||!("counts"in $))return U("Install counts cache has invalid structure"),null;let X=$;if(X.version!==w)return U(`Install counts cache version mismatch (got ${X.version}, expected ${w})`),null;if(typeof X.fetchedAt!=="string"||!Array.isArray(X.counts))return U("Install counts cache has invalid structure"),null;let B=new Date(X.fetchedAt).getTime();if(Number.isNaN(B))return U("Install counts cache has invalid fetchedAt timestamp"),null;if(!X.counts.every((G)=>typeof G==="object"&&G!==null&&typeof G.plugin==="string"&&typeof G.unique_installs==="number"))return U("Install counts cache has malformed entries"),null;if(Date.now()-B>xq)return U("Install counts cache is stale (>24h old)"),null;return{version:X.version,fetchedAt:X.fetchedAt,counts:X.counts}}catch(q){if(O(q)!=="ENOENT")U(`Failed to load install counts cache: ${V(q)}`);return null}}async function Kq(Q){let q=p(),$=`${q}.${Qq(8).toString("hex")}.tmp`;try{let X=M();await L().mkdir(X);let B=y(Q,null,2);await Bq($,B,{encoding:"utf-8",mode:384}),await Zq($,q),U("Install counts cache saved successfully")}catch(X){S(X);try{await $q($)}catch{}}}async function zq(){U(`Fetching install counts from ${b}`);try{let Q=await f.get(b,{timeout:1e4});if(!Q.data?.plugins||!Array.isArray(Q.data.plugins))throw Error("Invalid response format from install counts API");return Q.data.plugins}catch(Q){throw Q}}async function dq(){let Q=await Jq();if(Q){U("Using cached install counts");let q=new Map;for(let $ of Q.counts)q.set($.plugin,$.unique_installs);return q}try{let q=await zq(),$={version:w,fetchedAt:new Date().toISOString(),counts:q};await Kq($);let X=new Map;for(let B of q)X.set(B.plugin,B.unique_installs);return X}catch(q){return S(q),U(`Failed to fetch install counts: ${V(q)}`),null}}function gq(Q){if(Q<1000)return String(Q);if(Q<1e6){let B=(Q/1000).toFixed(1);return B.endsWith(".0")?`${B.slice(0,-2)}K`:`${B}K`}let $=(Q/1e6).toFixed(1);return $.endsWith(".0")?`${$.slice(0,-2)}M`:`${$}M`}var w=1,Yq="install-counts-cache.json",b="https://raw.githubusercontent.com/anthropics/claude-plugins-official/refs/heads/stats/stats/plugin-installs.json",xq=86400000;var Hq=N(()=>{r();t();_();T();e();P();qq()});import{readdir as Rq,readFile as A,stat as vq}from"fs/promises";import*as H from"path";function Iq(Q){let q=H.basename(Q),$=H.basename(H.dirname(Q));if(q==="plugin.json")return"plugin";if(q==="marketplace.json")return"marketplace";if($===".claude-plugin")return"plugin";return"unknown"}function C(Q){return Q.issues.map((q)=>({path:q.path.join(".")||"root",message:q.message,code:q.code}))}function I(Q,q,$,X){if(Q.includes(".."))$.push({path:q,message:X?`Path contains "..": ${Q}. ${X}`:`Path contains ".." which could be a path traversal attempt: ${Q}`})}function Lq(Q){let q=Q.replace(/^(\.\.\/)+/,"");return`Plugin source paths are resolved relative to the marketplace root (the directory containing .claude-plugin/), not relative to marketplace.json. Use "${q!==Q?`./${q}`:"./plugins/my-plugin"}" instead of "${Q}".`}async function E(Q){let q=[],$=[],X=H.resolve(Q),B;try{B=await A(X,{encoding:"utf-8"})}catch(Z){let Y=O(Z),x;if(Y==="ENOENT")x=`File not found: ${X}`;else if(Y==="EISDIR")x=`Path is not a file: ${X}`;else x=`Failed to read file: ${V(Z)}`;return{success:!1,errors:[{path:"file",message:x,code:Y}],warnings:[],filePath:X,fileType:"plugin"}}let K;try{K=R(B)}catch(Z){return{success:!1,errors:[{path:"json",message:`Invalid JSON syntax: ${V(Z)}`}],warnings:[],filePath:X,fileType:"plugin"}}if(K&&typeof K==="object"){let Z=K;if(Z.commands)(Array.isArray(Z.commands)?Z.commands:[Z.commands]).forEach((x,J)=>{if(typeof x==="string")I(x,`commands[${J}]`,q)});if(Z.agents)(Array.isArray(Z.agents)?Z.agents:[Z.agents]).forEach((x,J)=>{if(typeof x==="string")I(x,`agents[${J}]`,q)});if(Z.skills)(Array.isArray(Z.skills)?Z.skills:[Z.skills]).forEach((x,J)=>{if(typeof x==="string")I(x,`skills[${J}]`,q)})}let z=K;if(typeof K==="object"&&K!==null){let Z=K,Y=Object.keys(Z).filter((x)=>Aq.has(x));if(Y.length>0){let x={...Z};for(let J of Y)delete x[J],$.push({path:J,message:`Field '${J}' belongs in the marketplace entry (marketplace.json), `+"not plugin.json. It's harmless here but unused — Claudin "+"ignores it at load time."});z=x}}let G=d().strict().safeParse(z);if(!G.success)q.push(...C(G.error));if(G.success){let Z=G.data;if(!/^[a-z0-9]+(-[a-z0-9]+)*$/.test(Z.name))$.push({path:"name",message:`Plugin name "${Z.name}" is not kebab-case. Claudin accepts it, but the Claude.ai marketplace sync requires kebab-case (lowercase letters, digits, and hyphens only, e.g., "my-plugin").`});if(!Z.version)$.push({path:"version",message:'No version specified. Consider adding a version following semver (e.g., "1.0.0")'});if(!Z.description)$.push({path:"description",message:"No description provided. Adding a description helps users understand what your plugin does"});if(!Z.author)$.push({path:"author",message:"No author information provided. Consider adding author details for plugin attribution"})}return{success:q.length===0,errors:q,warnings:$,filePath:X,fileType:"plugin"}}async function j(Q){let q=[],$=[],X=H.resolve(Q),B;try{B=await A(X,{encoding:"utf-8"})}catch(Z){let Y=O(Z),x;if(Y==="ENOENT")x=`File not found: ${X}`;else if(Y==="EISDIR")x=`Path is not a file: ${X}`;else x=`Failed to read file: ${V(Z)}`;return{success:!1,errors:[{path:"file",message:x,code:Y}],warnings:[],filePath:X,fileType:"marketplace"}}let K;try{K=R(B)}catch(Z){return{success:!1,errors:[{path:"json",message:`Invalid JSON syntax: ${V(Z)}`}],warnings:[],filePath:X,fileType:"marketplace"}}if(K&&typeof K==="object"){let Z=K;if(Array.isArray(Z.plugins))Z.plugins.forEach((Y,x)=>{if(Y&&typeof Y==="object"&&"source"in Y){let J=Y.source;if(typeof J==="string")I(J,`plugins[${x}].source`,q,Lq(J));if(J&&typeof J==="object"&&"path"in J&&typeof J.path==="string")I(J.path,`plugins[${x}].source.path`,q)}})}let G=u().extend({plugins:m.array(g().strict())}).strict().safeParse(K);if(!G.success)q.push(...C(G.error));if(G.success){let Z=G.data;if(!Z.plugins||Z.plugins.length===0)$.push({path:"plugins",message:"Marketplace has no plugins defined"});if(Z.plugins){Z.plugins.forEach((J,W)=>{if(Z.plugins.filter((v)=>v.name===J.name).length>1)q.push({path:`plugins[${W}].name`,message:`Duplicate plugin name "${J.name}" found in marketplace`})});let Y=H.dirname(X),x=H.basename(Y)===".claude-plugin"?H.dirname(Y):Y;for(let[J,W]of Z.plugins.entries()){if(!W.version||typeof W.source!=="string"||!W.source.startsWith("./"))continue;let k=H.join(x,W.source,".claude-plugin","plugin.json"),v;try{let i=await A(k,{encoding:"utf-8"}),F=R(i);if(typeof F.version==="string")v=F.version}catch{continue}if(v&&v!==W.version)$.push({path:`plugins[${J}].version`,message:`Entry declares version "${W.version}" but ${W.source}/.claude-plugin/plugin.json says "${v}". `+"At install time, plugin.json wins (calculatePluginVersion precedence) — the entry version is silently ignored. "+`Update this entry to "${v}" to match.`})}}if(!Z.metadata?.description)$.push({path:"metadata.description",message:"No marketplace description provided. Adding a description helps users understand what this marketplace offers"})}return{success:q.length===0,errors:q,warnings:$,filePath:X,fileType:"marketplace"}}function Nq(Q,q,$){let X=[],B=[],K=q.match(n);if(!K)return B.push({path:"frontmatter",message:"No frontmatter block found. Add YAML frontmatter between --- delimiters at the top of the file to set description and other metadata."}),{success:!0,errors:X,warnings:B,filePath:Q,fileType:$};let z=K[1]||"",G;try{G=h(z)}catch(J){return X.push({path:"frontmatter",message:`YAML frontmatter failed to parse: ${V(J)}. At runtime this ${$} loads with empty metadata (all frontmatter fields silently dropped).`}),{success:!1,errors:X,warnings:B,filePath:Q,fileType:$}}if(G===null||typeof G!=="object"||Array.isArray(G))return X.push({path:"frontmatter",message:`Frontmatter must be a YAML mapping (key: value pairs), got ${Array.isArray(G)?"an array":G===null?"null":typeof G}.`}),{success:!1,errors:X,warnings:B,filePath:Q,fileType:$};let Z=G;if(Z.description!==void 0){let J=Z.description;if(typeof J!=="string"&&typeof J!=="number"&&typeof J!=="boolean"&&J!==null)X.push({path:"description",message:`description must be a string, got ${Array.isArray(J)?"array":typeof J}. At runtime this value is dropped.`})}else B.push({path:"description",message:`No description in frontmatter. A description helps users and Claude understand when to use this ${$}.`});if(Z.name!==void 0&&Z.name!==null&&typeof Z.name!=="string")X.push({path:"name",message:`name must be a string, got ${typeof Z.name}.`});let Y=Z["allowed-tools"];if(Y!==void 0&&Y!==null){if(typeof Y!=="string"&&!Array.isArray(Y))X.push({path:"allowed-tools",message:`allowed-tools must be a string or array of strings, got ${typeof Y}.`});else if(Array.isArray(Y)&&Y.some((J)=>typeof J!=="string"))X.push({path:"allowed-tools",message:"allowed-tools array must contain only strings."})}let x=Z.shell;if(x!==void 0&&x!==null)if(typeof x!=="string")X.push({path:"shell",message:`shell must be a string, got ${typeof x}.`});else{let J=x.trim().toLowerCase();if(J!=="bash"&&J!=="powershell")X.push({path:"shell",message:`shell must be 'bash' or 'powershell', got '${x}'.`})}return{success:X.length===0,errors:X,warnings:B,filePath:Q,fileType:$}}async function _q(Q){let q;try{q=await A(Q,{encoding:"utf-8"})}catch(B){if(O(B)==="ENOENT")return{success:!0,errors:[],warnings:[],filePath:Q,fileType:"hooks"};return{success:!1,errors:[{path:"file",message:`Failed to read file: ${V(B)}`}],warnings:[],filePath:Q,fileType:"hooks"}}let $;try{$=R(q)}catch(B){return{success:!1,errors:[{path:"json",message:`Invalid JSON syntax: ${V(B)}. At runtime this breaks the entire plugin load.`}],warnings:[],filePath:Q,fileType:"hooks"}}let X=c().safeParse($);if(!X.success)return{success:!1,errors:C(X.error),warnings:[],filePath:Q,fileType:"hooks"};return{success:!0,errors:[],warnings:[],filePath:Q,fileType:"hooks"}}async function l(Q,q){let $;try{$=await Rq(Q,{withFileTypes:!0})}catch(B){let K=O(B);if(K==="ENOENT"||K==="ENOTDIR")return[];throw B}if(q)return $.filter((B)=>B.isDirectory()).map((B)=>H.join(Q,B.name,"SKILL.md"));let X=[];for(let B of $){let K=H.join(Q,B.name);if(B.isDirectory())X.push(...await l(K,!1));else if(B.isFile()&&B.name.toLowerCase().endsWith(".md"))X.push(K)}return X}async function tq(Q){let q=[],$=[["skill",H.join(Q,"skills")],["agent",H.join(Q,"agents")],["command",H.join(Q,"commands")]];for(let[B,K]of $){let z=await l(K,B==="skill");for(let G of z){let Z;try{Z=await A(G,{encoding:"utf-8"})}catch(x){if(D(x))continue;q.push({success:!1,errors:[{path:"file",message:`Failed to read: ${V(x)}`}],warnings:[],filePath:G,fileType:B});continue}let Y=Nq(G,Z,B);if(Y.errors.length>0||Y.warnings.length>0)q.push(Y)}}let X=await _q(H.join(Q,"hooks","hooks.json"));if(X.errors.length>0||X.warnings.length>0)q.push(X);return q}async function rq(Q){let q=H.resolve(Q),$=null;try{$=await vq(q)}catch(B){if(!D(B))throw B}if($?.isDirectory()){let B=H.join(q,".claude-plugin","marketplace.json"),K=await j(B);if(K.errors[0]?.code!=="ENOENT")return K;let z=H.join(q,".claude-plugin","plugin.json"),G=await E(z);if(G.errors[0]?.code!=="ENOENT")return G;return{success:!1,errors:[{path:"directory",message:"No manifest found in directory. Expected .claude-plugin/marketplace.json or .claude-plugin/plugin.json"}],warnings:[],filePath:q,fileType:"plugin"}}switch(Iq(Q)){case"plugin":return E(Q);case"marketplace":return j(Q);case"unknown":{try{let B=await A(q,{encoding:"utf-8"}),K=R(B);if(Array.isArray(K.plugins))return j(Q)}catch(B){if(O(B)==="ENOENT")return{success:!1,errors:[{path:"file",message:`File not found: ${q}`}],warnings:[],filePath:q,fileType:"plugin"}}return E(Q)}}}var Aq;var wq=N(()=>{Uq();_();Wq();P();Oq();Vq();Aq=new Set(["category","source","tags","strict","id"])});
2
+ export{Dq as gc,a as hc,dq as ic,gq as jc,Hq as kc,tq as lc,rq as mc,wq as nc};