cf 1.0.0-beta.23 → 1.0.0-beta.25

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 (244) hide show
  1. package/dist/_meta/commands.json +547 -150
  2. package/dist/_meta/hand-written-commands.json +46 -2
  3. package/dist/_meta/schemas.json +277 -2
  4. package/dist/{abuse-reports-SaxhQy6n.mjs → abuse-reports-BIS9MZn7.mjs} +3 -3
  5. package/dist/{access-BI_7K9ye.mjs → access-__sFDSFL.mjs} +1 -1
  6. package/dist/{accounts-yCqYkAyG.mjs → accounts-CmggwRjh.mjs} +36 -34
  7. package/dist/{acm-Cyvj0TLt.mjs → acm-AAhRZUAU.mjs} +1 -1
  8. package/dist/{addressing-CPjDXCGE.mjs → addressing-DVeJNPZc.mjs} +1 -1
  9. package/dist/{agent-memory-EoP2Uwo7.mjs → agent-memory-DQhWO6sc.mjs} +1 -1
  10. package/dist/{ai-DU5T7Rw7.mjs → ai-CULO9sno.mjs} +3 -3
  11. package/dist/{ai-audit-DVT8qGLn.mjs → ai-audit-udn4HF34.mjs} +1 -1
  12. package/dist/{ai-gateway-BYtptiIM.mjs → ai-gateway-Bm2MMdec.mjs} +3 -3
  13. package/dist/{ai-search-CJJ5XZTd.mjs → ai-search-GRN_gXgU.mjs} +1 -1
  14. package/dist/{ai-security-CidIWQ2m.mjs → ai-security-DXy9ht-9.mjs} +2 -2
  15. package/dist/{alerting-CVatzxaS.mjs → alerting-CssnaN2i.mjs} +1 -1
  16. package/dist/{analytics-BWJAOVxo.mjs → analytics-BVo7Ax0w.mjs} +1 -1
  17. package/dist/{analytics-engine-CZgKAEo0.mjs → analytics-engine-BBd0Bydx.mjs} +1 -1
  18. package/dist/{api-security-CAeFfkOp.mjs → api-security-C-D9OKtH.mjs} +3 -3
  19. package/dist/{argo-YKMl_X-Q.mjs → argo-DSziwzvA.mjs} +1 -1
  20. package/dist/{artifacts-CrWK_jdk.mjs → artifacts-nVMgn4dn.mjs} +1 -1
  21. package/dist/{audit-logs-C7Z4o6lL.mjs → audit-logs-DIZ5oA_y.mjs} +1 -1
  22. package/dist/auth-Bls_1yRW.mjs +2 -0
  23. package/dist/{auth-DkPhAgZv.mjs → auth-CB9wjyad.mjs} +1 -1
  24. package/dist/auth-JsvLULHA.mjs +7 -0
  25. package/dist/{auth-token-C-ushV4K.mjs → auth-token-BAgw7kYP.mjs} +1 -1
  26. package/dist/{autoconfig-CwWsgTP2.mjs → autoconfig-CajkMb3B.mjs} +19 -11
  27. package/dist/{basin-catalog-Df0BLUfb.mjs → basin-catalog-BRvGeKm3.mjs} +9 -9
  28. package/dist/{billing-C7qD2cBJ.mjs → billing-BhPoqyKC.mjs} +1 -1
  29. package/dist/{blocks-hVx18MUM.mjs → blocks-D2tE8dp2.mjs} +1 -1
  30. package/dist/{bot-management-Dv2tluEZ.mjs → bot-management-BfjX5DuH.mjs} +1 -1
  31. package/dist/{botnet-feed-DrIY4gpG.mjs → botnet-feed-VOL5P4s3.mjs} +1 -1
  32. package/dist/{brand-protection-of9uwStG.mjs → brand-protection-CSVHQ9Pt.mjs} +2 -2
  33. package/dist/{browser-run-CbMV-Pf5.mjs → browser-run-cxOd2cZE.mjs} +1 -1
  34. package/dist/{build-Yf5bvUk2.mjs → build-BfkzV5_c.mjs} +1 -1
  35. package/dist/build-DCdLWwOg.mjs +2 -0
  36. package/dist/{builds-DQrlz2-K.mjs → builds-y5BQCJ81.mjs} +1 -1
  37. package/dist/{cache-suoMuQMh.mjs → cache-Bvr988Hj.mjs} +1 -1
  38. package/dist/cf-DgLg6Hop.mjs +18 -0
  39. package/dist/{chunk-3PJ54H4K-C8sxQzhB.mjs → chunk-3PJ54H4K-CbRAWQWI.mjs} +1 -1
  40. package/dist/{chunk-DSGVRFIS-CP2xC0bc.mjs → chunk-DSGVRFIS-Dq2PrGsi.mjs} +1 -1
  41. package/dist/{cli-BjAkPFKt.mjs → cli-BTxJfFus.mjs} +1 -1
  42. package/dist/{client-side-security-lh4tvRH8.mjs → client-side-security-CFmO0uz9.mjs} +1 -1
  43. package/dist/{cloud-connector-C65g5ddh.mjs → cloud-connector-CtwPdFBa.mjs} +1 -1
  44. package/dist/{cloudflared-FEg1GxHT.mjs → cloudflared-DPkNN1Qv.mjs} +1 -1
  45. package/dist/{cloudforce-one-C2K8Sbji.mjs → cloudforce-one-DHrMaxnU.mjs} +59 -59
  46. package/dist/{command-BfoLlrr1.mjs → command-6_Ms3TZv.mjs} +1 -1
  47. package/dist/{command-DrdxR1tJ.mjs → command-BWyx7dNO.mjs} +1 -1
  48. package/dist/{command-DCJgoFz9.mjs → command-BXCk1OsI.mjs} +1 -1
  49. package/dist/{command-BqEoltQG.mjs → command-CCDzJjIB.mjs} +1 -1
  50. package/dist/{command-CKXrXY0q.mjs → command-CDYTsmxe.mjs} +1 -1
  51. package/dist/{command-CBQp3Znu.mjs → command-CXwKBbj9.mjs} +1 -1
  52. package/dist/{command-DRBtP4R8.mjs → command-ClneauMx.mjs} +1 -1
  53. package/dist/{command-Cby3gjqh.mjs → command-CmK8-DJ9.mjs} +1 -1
  54. package/dist/{command-BaIY4UuC.mjs → command-Ct3tf-P5.mjs} +1 -1
  55. package/dist/{command-CszTdUQV.mjs → command-DPOjEs1B.mjs} +1 -1
  56. package/dist/{command-D3E7d8E7.mjs → command-DqWBPiew.mjs} +1 -1
  57. package/dist/{command-C2ZXXZI4.mjs → command-YFWLEK8W.mjs} +1 -1
  58. package/dist/{command-BHJu931_.mjs → command-ckixJeTm.mjs} +1 -1
  59. package/dist/{command-C5465_vZ.mjs → command-lJJ7sEZe.mjs} +1 -1
  60. package/dist/{completions-DIIrktem.mjs → completions-B1rYgw_a.mjs} +1 -1
  61. package/dist/{connector-interrupts-B4xZTu7K.mjs → connector-interrupts-DecTdK6X.mjs} +1 -1
  62. package/dist/{connector-telemetry-events-DtTO6KCB.mjs → connector-telemetry-events-wePxPACj.mjs} +1 -1
  63. package/dist/{connector-telemetry-snapshots-BS1Cq8v_.mjs → connector-telemetry-snapshots-D8sXR1qx.mjs} +1 -1
  64. package/dist/{connectors-CUywNbTu.mjs → connectors-C-6RQ_Q1.mjs} +1 -1
  65. package/dist/{containers-DCL31jYE.mjs → containers-C_byVTZF.mjs} +193 -193
  66. package/dist/{containers-CQxEk5xO.mjs → containers-D65Gpj9Q.mjs} +2 -2
  67. package/dist/{content-scan-6BGlT-em.mjs → content-scan-DbIDQ-Yu.mjs} +1 -1
  68. package/dist/{context-DoGlohS-.mjs → context-DCon1tRZ.mjs} +1 -1
  69. package/dist/{cps-BoQ1alPM.mjs → cps-DGLmzCzp.mjs} +1 -1
  70. package/dist/{csam-scanner-OFnvPsqP.mjs → csam-scanner-R7Ih-Dnw.mjs} +1 -1
  71. package/dist/{custom-csrs-BT-kjyPt.mjs → custom-csrs-D0RnVoJ7.mjs} +1 -1
  72. package/dist/{custom-hostnames-ItOUZwKc.mjs → custom-hostnames-BFWR-tR_.mjs} +1 -1
  73. package/dist/{custom-nameservers-BZ1SzRQI.mjs → custom-nameservers-Dn_9Ssti.mjs} +1 -1
  74. package/dist/{custom-pages-rIzNbxrh.mjs → custom-pages-HqIQcb77.mjs} +1 -1
  75. package/dist/{d1-DtEeX2ua.mjs → d1-CopIY9RT.mjs} +2 -2
  76. package/dist/{delegate-3IgxBeFH.mjs → delegate-CTj0dYET.mjs} +1 -1
  77. package/dist/delegate.mjs +1 -1
  78. package/dist/{deploy-CvIiOhGj.mjs → deploy-BVTA83rN.mjs} +1 -1
  79. package/dist/{deploy-context-CCahKKFs.mjs → deploy-context-CO8ZSRwx.mjs} +1 -1
  80. package/dist/{deploy-input-BusFZFqu.mjs → deploy-input-PhKRxa_2.mjs} +1 -1
  81. package/dist/dev-CM5GLHNn.mjs +4 -0
  82. package/dist/{diagnostics-Di6xJHuC.mjs → diagnostics-DPjl0aCm.mjs} +1 -1
  83. package/dist/{dist-D5YYi2LO.mjs → dist-ataVE8ob.mjs} +3 -3
  84. package/dist/{dls-CAlQiQv4.mjs → dls-BLTIVlbh.mjs} +1 -1
  85. package/dist/{dns-BzxLC4D1.mjs → dns-DkqVq-nB.mjs} +60 -58
  86. package/dist/{dns-firewall-CHVL95X_.mjs → dns-firewall-D1bb1byu.mjs} +1 -1
  87. package/dist/{docs-SWvG8lKe.mjs → docs-tOv_OllI.mjs} +1 -1
  88. package/dist/{durable-objects-DZl4seSi.mjs → durable-objects-OJhns_to.mjs} +1 -1
  89. package/dist/{email-auth-hHJQmtYR.mjs → email-auth-BbsIBNlu.mjs} +1 -1
  90. package/dist/{email-domains-BBFPOLQx.mjs → email-domains-pWZi1M4q.mjs} +1 -1
  91. package/dist/{email-routing-Cimk4lg2.mjs → email-routing-DnitWE1A.mjs} +1 -1
  92. package/dist/{email-security-DiNFIpmg.mjs → email-security-DiWtb7cx.mjs} +2 -2
  93. package/dist/{email-sending-yIqoikwn.mjs → email-sending-DuDjXykw.mjs} +1 -1
  94. package/dist/{errors-d_Ld5w3d.mjs → errors-CCFmptqJ.mjs} +1 -1
  95. package/dist/{field-extractors-CiuZnMX2.mjs → field-extractors-DNNnkBZH.mjs} +1 -1
  96. package/dist/{firewall-B8QK0M1Y.mjs → firewall-C7eZRNVF.mjs} +22 -16
  97. package/dist/{flagship-Dh0-PZgv.mjs → flagship-BczjsrJ5.mjs} +1 -1
  98. package/dist/{fraud-DDebasT8.mjs → fraud-wE0UM2SM.mjs} +1 -1
  99. package/dist/{google-tag-gateway-BPrh4DbT.mjs → google-tag-gateway-6mvtxcJK.mjs} +1 -1
  100. package/dist/{healthchecks-CF8SJ-wN.mjs → healthchecks-aIB3DebS.mjs} +1 -1
  101. package/dist/{hyperdrive-B9uPSMiW.mjs → hyperdrive-DHRP8SJS.mjs} +1 -1
  102. package/dist/{iam-g9EBjHMK.mjs → iam-6t7-ScrS.mjs} +1 -1
  103. package/dist/{images-BqSlZF88.mjs → images-CLgvxd0t.mjs} +1 -1
  104. package/dist/index.mjs +1 -1
  105. package/dist/{init-CIfT7Qx1.mjs → init-B_DBTMXU.mjs} +1 -1
  106. package/dist/{intel-D8nT11Y4.mjs → intel-jnoIVlYG.mjs} +2 -2
  107. package/dist/{interactive-DOWEcR6_.mjs → interactive-1g0dnrA8.mjs} +1 -1
  108. package/dist/{internal-C7zUQ4fS.mjs → internal-Ba3b-Z8J.mjs} +1 -1
  109. package/dist/{ips-DwrIBecV.mjs → ips-CQ4gFfex.mjs} +1 -1
  110. package/dist/{k2-7r63P37v.mjs → k2-Bsm6rzNX.mjs} +1 -1
  111. package/dist/{kv-BQSq0aQ5.mjs → kv-DQfnNE-w.mjs} +1 -1
  112. package/dist/{lazy-command-JgUZQW-c.mjs → lazy-command-DjGzxiUT.mjs} +1 -1
  113. package/dist/{leaked-credential-checks-Bu2NYq31.mjs → leaked-credential-checks-CaqjG3Oz.mjs} +1 -1
  114. package/dist/list-4MfEFwJN.mjs +2 -0
  115. package/dist/list-ByCv9-Fl.mjs +2 -0
  116. package/dist/{live-ZSukf_dI.mjs → live-BfobGv8W.mjs} +1 -1
  117. package/dist/{load-balancers-CthmhsmC.mjs → load-balancers-BzSCp2Uh.mjs} +1 -1
  118. package/dist/{local-Y4rIAAtA.mjs → local-BNmz58v4.mjs} +1 -1
  119. package/dist/local-ChR3YIMU.mjs +2 -0
  120. package/dist/local-runtime-DvH92pV8.mjs +2 -0
  121. package/dist/{login-lXb4Sqs9.mjs → login-B9wYab6S.mjs} +2 -2
  122. package/dist/login-ierSCYE6.mjs +2 -0
  123. package/dist/{logpush-Mw2VklWj.mjs → logpush-DgfiSd1b.mjs} +2 -2
  124. package/dist/{logs-DQrNjo77.mjs → logs-Dan7xU-k.mjs} +1 -1
  125. package/dist/{magic-cloud-networking-D8s1hN3K.mjs → magic-cloud-networking-DP8fWC4a.mjs} +3 -3
  126. package/dist/{magic-network-monitoring-f0ccLJlt.mjs → magic-network-monitoring-TAjt04vN.mjs} +1 -1
  127. package/dist/{magic-transit-7WpZJc0a.mjs → magic-transit-BSuLHnQ5.mjs} +1 -1
  128. package/dist/{managed-defense-QLYmbNgC.mjs → managed-defense-CTnIZLg4.mjs} +1 -1
  129. package/dist/{managed-transforms-CkaQn7tC.mjs → managed-transforms-BETvesjp.mjs} +1 -1
  130. package/dist/{mcp-Di1X9Amj.mjs → mcp-DhjMGaKc.mjs} +1 -1
  131. package/dist/{mesh-CkvqQb6B.mjs → mesh-jxLLG3t4.mjs} +1 -1
  132. package/dist/{migrate-KOhIz9fX.mjs → migrate-Bkhk38nJ.mjs} +1 -1
  133. package/dist/{monetization-C9c2OCag.mjs → monetization-BqDgHlPv.mjs} +1 -1
  134. package/dist/{network-0PlPsgfJ.mjs → network-D6BRpgOv.mjs} +2 -2
  135. package/dist/{network-interconnects-BeiuYp7F.mjs → network-interconnects-tP41GbnL.mjs} +1 -1
  136. package/dist/{o11y-Ys4wGQJ8.mjs → o11y-h4cIC_1T.mjs} +1 -1
  137. package/dist/{oauth-BX5dMp7e.mjs → oauth-CuM12iNb.mjs} +1 -1
  138. package/dist/{oauth-clients-DhVG_Upv.mjs → oauth-clients-B0voUiXM.mjs} +1 -1
  139. package/dist/{oauth-BL039mqa.mjs → oauth-nDH3nTCa.mjs} +2 -2
  140. package/dist/oauth-scopes-Bhns1ZHW.mjs +4 -0
  141. package/dist/{organization-8ateLjgl.mjs → organization-Cy55HoRR.mjs} +4 -4
  142. package/dist/organizations-7Q3d9vcW.mjs +4 -0
  143. package/dist/{origin-post-quantum-encryption-D9qT0WUV.mjs → origin-post-quantum-encryption-XBMPCdSL.mjs} +1 -1
  144. package/dist/package-DK3JX4I3.mjs +2 -0
  145. package/dist/{page-rules-DlOky6Zl.mjs → page-rules-BlT5xlhH.mjs} +1 -1
  146. package/dist/{pages-BcqYjzyx.mjs → pages-CIbL62L2.mjs} +3 -3
  147. package/dist/{pay-per-crawl-DtYmYcHH.mjs → pay-per-crawl-BzsBqo_m.mjs} +1 -1
  148. package/dist/{pay-per-use-DOUCWPNy.mjs → pay-per-use-DtejLYJ8.mjs} +1 -1
  149. package/dist/{pipelines-8yHQduBt.mjs → pipelines-LjLb8jq6.mjs} +1 -1
  150. package/dist/{precursor-CX7gjIRG.mjs → precursor-BKp5_Ag4.mjs} +1 -1
  151. package/dist/{previews-WL-CudUP.mjs → previews-zRYO9uO9.mjs} +1 -1
  152. package/dist/{progress-D2_AF54c.mjs → progress-_Jux05O5.mjs} +1 -1
  153. package/dist/{prompt-BBR19lgj.mjs → prompt-SNVLBS1b.mjs} +1 -1
  154. package/dist/{queues-BDNnjJ5M.mjs → queues-Ci4rGGC4.mjs} +1 -1
  155. package/dist/{r2-B9b18zom.mjs → r2-qm2hgS43.mjs} +1 -1
  156. package/dist/radar-C_ydbJe_.mjs +300 -0
  157. package/dist/{raw-fetch-BFcMz5hY.mjs → raw-fetch-D3ydyJYW.mjs} +1 -1
  158. package/dist/{ready-C8zZ63yB.mjs → ready-hk-_B8z3.mjs} +1 -1
  159. package/dist/{realtime-C8z8iTs4.mjs → realtime-BAvjYmYw.mjs} +2 -2
  160. package/dist/{registrar-BTMp4ivm.mjs → registrar-DD7WZaP2.mjs} +10 -10
  161. package/dist/{registrar-sandbox-C2PG_Alv.mjs → registrar-sandbox-DbxloH5s.mjs} +2 -2
  162. package/dist/{reporting-BQY6_uXf.mjs → reporting-CRVg3J1C.mjs} +1 -1
  163. package/dist/{request-headers-_yTB3kAw.mjs → request-headers-Cn01EsbI.mjs} +1 -1
  164. package/dist/{request-tracers-Dijdzs6y.mjs → request-tracers-BWs0rdFS.mjs} +1 -1
  165. package/dist/{resource-sharing-DYaOk_EC.mjs → resource-sharing-yipIkdbd.mjs} +2 -2
  166. package/dist/{rules-TsOBYamD.mjs → rules-CCtaBLiN.mjs} +1 -1
  167. package/dist/{rulesets-BICRAp0v.mjs → rulesets-DBEvCNDS.mjs} +1 -1
  168. package/dist/{rum-wY_8vewy.mjs → rum-gDOKylu_.mjs} +1 -1
  169. package/dist/{run-C2-1SFrS.mjs → run-Br8sYjNF.mjs} +1 -1
  170. package/dist/run-LOgTLpob.mjs +2 -0
  171. package/dist/schema-cache-Cb64Nqbt.mjs +3 -0
  172. package/dist/schema-flags-BcbbCWR5.mjs +4 -0
  173. package/dist/{scim-BCB-RVUX.mjs → scim-CM8Xah56.mjs} +1 -1
  174. package/dist/{secrets-store-BR-h9nxX.mjs → secrets-store-BEnXiYCC.mjs} +2 -2
  175. package/dist/{security-insights-C3pM4_QG.mjs → security-insights-Be5GvdBA.mjs} +5 -5
  176. package/dist/{security-txt-BYeDQJyf.mjs → security-txt-BF0PWAEW.mjs} +1 -1
  177. package/dist/{session-CG79ZLE9.mjs → session-B7vOqdZU.mjs} +1 -1
  178. package/dist/shared-CBMFY1VY.mjs +2 -0
  179. package/dist/{signed-url-BWwUnIl-.mjs → signed-url-VDDQlllt.mjs} +1 -1
  180. package/dist/{smart-shield-Dlsh9Xdx.mjs → smart-shield-DQku_wYi.mjs} +1 -1
  181. package/dist/{snippets-DWTJdzIF.mjs → snippets-B3FCEMuh.mjs} +1 -1
  182. package/dist/spawn-9sE67p7c.mjs +5 -0
  183. package/dist/{spectrum-RbNSnJya.mjs → spectrum-nLirlVue.mjs} +5 -5
  184. package/dist/{speed-Bh18cP0e.mjs → speed-C1hCyMPy.mjs} +1 -1
  185. package/dist/{sql-BKjCDDS-.mjs → sql-DVQOKThL.mjs} +1 -1
  186. package/dist/src-Bh2gHpI7.mjs +131 -0
  187. package/dist/{ssl-BHMbK4Be.mjs → ssl-CYDRgr24.mjs} +2 -2
  188. package/dist/{startup-profile-B7yHR_YB.mjs → startup-profile-BLvw_Wmc.mjs} +1 -1
  189. package/dist/startup-profile-ByxSdhEl.mjs +2 -0
  190. package/dist/{state-DNuVv5i-.mjs → state-B8n0QU04.mjs} +1 -1
  191. package/dist/state-BTOzaT5L.mjs +2 -0
  192. package/dist/{stream-BFs1vbTA.mjs → stream-DHyejrI6.mjs} +1 -1
  193. package/dist/{tags-ACINMEUC.mjs → tags-DOL6dKQE.mjs} +2 -2
  194. package/dist/{telemetry-Da9TmAgm.mjs → telemetry-DJ8-Q2pU.mjs} +1 -1
  195. package/dist/telemetry-kjElc1zT.mjs +2 -0
  196. package/dist/{tenant-Decq0ghq.mjs → tenant-2EdATz2Y.mjs} +1 -1
  197. package/dist/{tenant-custom-nameservers-CGcqESj5.mjs → tenant-custom-nameservers-DhEpJNST.mjs} +1 -1
  198. package/dist/{tunnels-ff1a_ucB.mjs → tunnels-CMAmH4Vh.mjs} +3 -3
  199. package/dist/{turnstile-BmJeENqH.mjs → turnstile-DTJjDMFp.mjs} +1 -1
  200. package/dist/ui-7zujR-O7.mjs +2 -0
  201. package/dist/{update-check-imcniBzu.mjs → update-check-BkCdHK-3.mjs} +1 -1
  202. package/dist/{update-check-BjlU_02g.mjs → update-check-DDGKWkmi.mjs} +1 -1
  203. package/dist/update-check-worker.mjs +1 -1
  204. package/dist/{url-normalization-DPqqTNzy.mjs → url-normalization-BbWOra1u.mjs} +1 -1
  205. package/dist/{url-scanner-SmzhVLS-.mjs → url-scanner-Bj-eS_3C.mjs} +2 -2
  206. package/dist/{user-LDJcWt0X.mjs → user-CMzTHHVX.mjs} +1 -1
  207. package/dist/{vectorize-D57FE9YT.mjs → vectorize-D4H7_KPs.mjs} +1 -1
  208. package/dist/version-DIIJ2ixL.mjs +2 -0
  209. package/dist/{waiting-rooms-Bp5glzYE.mjs → waiting-rooms-CqMbVu9s.mjs} +1 -1
  210. package/dist/{web-assets-BzSBU057.mjs → web-assets-BgfzyF8t.mjs} +5 -5
  211. package/dist/{web3-DmeS2XCY.mjs → web3-ByCe47FI.mjs} +1 -1
  212. package/dist/{workers-BUmSAYvI.mjs → workers-BiLsPkYD.mjs} +2 -2
  213. package/dist/{workers-builds-BRRyYyDr.mjs → workers-builds-2N71_8MZ.mjs} +1 -1
  214. package/dist/{workers-for-platforms-Bq5hpU-X.mjs → workers-for-platforms-BMN4QXgT.mjs} +1 -1
  215. package/dist/{workers-vpc-Dn83sJ0S.mjs → workers-vpc-3o7dMg7-.mjs} +1 -1
  216. package/dist/{workflows-BI1Oqr1y.mjs → workflows-COiyqt-B.mjs} +1 -1
  217. package/dist/{wrangler-migration-DHfxfsd8.mjs → wrangler-migration-CqSg8IDj.mjs} +5 -5
  218. package/dist/{zaraz-eWdwn_FV.mjs → zaraz-DjwhCH8A.mjs} +2 -2
  219. package/dist/{zero-trust-Dj_s_8u8.mjs → zero-trust-BmpuDOmH.mjs} +68 -62
  220. package/dist/{zones-D7J5AMUO.mjs → zones-XYQiz5kF.mjs} +2 -2
  221. package/package.json +12 -12
  222. package/dist/auth-0yg8UHy1.mjs +0 -2
  223. package/dist/auth-DCnxMUAZ.mjs +0 -2
  224. package/dist/build-DHPdqjpj.mjs +0 -2
  225. package/dist/cf-CInFH4Ng.mjs +0 -18
  226. package/dist/dev-2hNwTy0s.mjs +0 -4
  227. package/dist/local-CxTyXQlK.mjs +0 -2
  228. package/dist/local-runtime-Crs0aOFO.mjs +0 -2
  229. package/dist/login-C_gOc9pk.mjs +0 -2
  230. package/dist/oauth-scopes-B1n8hUMj.mjs +0 -4
  231. package/dist/organizations-DdQAC66Z.mjs +0 -4
  232. package/dist/package-C4H_6MHV.mjs +0 -2
  233. package/dist/radar-BCxOSIwx.mjs +0 -300
  234. package/dist/registry-DpNVjLuS.mjs +0 -2
  235. package/dist/run-C9r-Beel.mjs +0 -2
  236. package/dist/schema-flags-DHP8ll5_.mjs +0 -5
  237. package/dist/shared-Z4B68uro.mjs +0 -2
  238. package/dist/spawn-DdvGNWEs.mjs +0 -5
  239. package/dist/src-BZtxQa8v.mjs +0 -131
  240. package/dist/startup-profile-zt6cFnBn.mjs +0 -2
  241. package/dist/state-C5mQ9At8.mjs +0 -2
  242. package/dist/telemetry-Q7QghPwV.mjs +0 -2
  243. package/dist/ui-C1y5cXUM.mjs +0 -2
  244. package/dist/version-CbBZJTiB.mjs +0 -2
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{K as e}from"./dist-D5YYi2LO.mjs";import{t}from"./version-CbBZJTiB.mjs";import{o as n}from"./blocks-hVx18MUM.mjs";import"./api-X3wKppsT.mjs";import{t as r}from"./path-DRw6Y-nd.mjs";import{t as i}from"./hand-written-dry-run-B82fRl2N.mjs";import{t as a}from"./local-Y4rIAAtA.mjs";import{n as o}from"./auth-DkPhAgZv.mjs";import{a as s,n as c,t as l}from"./context-DoGlohS-.mjs";import{t as u}from"./auth-token-C-ushV4K.mjs";import{E as d,S as ee,T as f,_ as p,b as te,f as m,h as ne,p as re,s as h,t as g,u as ie,v as ae}from"./deploy-context-CCahKKFs.mjs";import{n as _}from"./request-headers-_yTB3kAw.mjs";import{t as v}from"./output-BJEgbI0G.mjs";import{t as y}from"./dry-run-gy0Hl9xo.mjs";import{t as b}from"./progress-D2_AF54c.mjs";import{n as x,t as S}from"./run-C2-1SFrS.mjs";import"./telemetry-Q7QghPwV.mjs";import{a as C,n as w,t as T}from"./body-parser-BKcZS9iJ.mjs";import{n as E}from"./input-validation-D7z60HJH.mjs";import{a as D,i as O,n as k}from"./prompt-BBR19lgj.mjs";var A={method:`POST`,path:e=>r`/accounts/${e.account_id}/containers/applications`,body:`json`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,500:`InternalServerError`}};function oe(e){return e.usage('$0 containers applications create\n\nCreate a Containers application. Use `scheduling_policy: "default"` for a scheduler-backed application. The Containers scheduler maintains the requested instance count and manages deployment configuration, placement, scaling, versions, and rollouts. Use `scheduling_policy: "durable_object"` for a Durable Object-managed application. Each Durable Object creates and manages the lifecycle of its container instance. Supply `name`, `scheduling_policy`, and `durable_objects`, with optional `configuration` and optional top-level `observability` settings. Deployment configuration, scaling, constraints, versions, and rollouts do not apply.').option(`configuration-authorized-keys`,{type:`string`,description:`The configuration.authorized_keys field. Provide as a JSON array of objects or @path/to/file.json.`}).option(`configuration-command`,{type:`string`,array:!0,description:`The command that runs when the container starts, passed to the entrypoint.
2
+ import{K as e}from"./dist-ataVE8ob.mjs";import{t}from"./version-DIIJ2ixL.mjs";import{o as n}from"./blocks-D2tE8dp2.mjs";import"./api-X3wKppsT.mjs";import{t as r}from"./path-DRw6Y-nd.mjs";import{t as i}from"./hand-written-dry-run-B82fRl2N.mjs";import{t as a}from"./local-BNmz58v4.mjs";import{n as o}from"./auth-CB9wjyad.mjs";import{a as s,n as c,t as l}from"./context-DCon1tRZ.mjs";import{t as u}from"./auth-token-BAgw7kYP.mjs";import{E as d,S as ee,T as f,_ as p,b as te,f as m,h as ne,p as re,s as h,t as g,u as ie,v as ae}from"./deploy-context-CO8ZSRwx.mjs";import{n as _}from"./request-headers-Cn01EsbI.mjs";import{t as v}from"./output-BJEgbI0G.mjs";import{t as y}from"./dry-run-gy0Hl9xo.mjs";import{t as b}from"./progress-_Jux05O5.mjs";import{n as x,t as S}from"./run-Br8sYjNF.mjs";import"./telemetry-kjElc1zT.mjs";import{a as C,n as w,t as T}from"./body-parser-BKcZS9iJ.mjs";import{n as E}from"./input-validation-D7z60HJH.mjs";import{a as D,i as O,n as k}from"./prompt-SNVLBS1b.mjs";var A={method:`POST`,path:e=>r`/accounts/${e.account_id}/containers/applications`,body:`json`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,500:`InternalServerError`}};function oe(e){return e.usage('$0 containers applications create\n\nCreate a Containers application. Use `scheduling_policy: "default"` for a scheduler-backed application. The Containers scheduler maintains the requested instance count and manages deployment configuration, placement, scaling, versions, and rollouts. Use `scheduling_policy: "durable_object"` for a Durable Object-managed application. Each Durable Object creates and manages the lifecycle of its container instance. Supply `name`, `scheduling_policy`, and `durable_objects`, with optional `configuration` and optional top-level `observability` settings. Deployment configuration, scaling, constraints, versions, and rollouts do not apply.').option(`configuration-authorized-keys`,{type:`string`,description:`The configuration.authorized_keys field. Provide as a JSON array of objects or @path/to/file.json.`}).option(`configuration-command`,{type:`string`,array:!0,description:`The command that runs when the container starts, passed to the entrypoint.
3
3
  You can override this at run-time. If you override only the command,
4
4
  it gets passed to the default entrypoint specified in the image.
5
5
  `}).option(`configuration-entrypoint`,{type:`string`,array:!0,description:`The entry point for the container, specifying the executable to run when the container starts.
@@ -72,4 +72,4 @@ Generates credentials for accessing a configured container image registry.`).pos
72
72
 
73
73
  Delete a registry from the account, this will prevent Containers from pulling images from the registry.`).positional(`domain`,{type:`string`,description:`The domain to delete.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const Pe={command:`delete <domain>`,describe:`Delete a registry from the account`,builder:Ne,handler:async e=>S({command:`containers registries delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){let t=await s();y({command:`cf containers registries delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/containers/registries/${e.domain==null?`<domain>`:encodeURIComponent(String(e.domain))}`,pathParams:{domain:String(e.domain??``)},bodyKind:`none`});return}let t=await o(e),n=e.local?a:await l();if(e.accountId=n,!await k({force:!!e.force,message:`This operation deletes the registry configuration. Containers will no longer be able to pull images from it.`}))return;let r=await b(`Deleting`,async()=>t.send(Me,{account_id:n,domain:e.domain}));v(r,{successLabel:`Deleted`})})};var Fe={method:`GET`,path:e=>r`/accounts/${e.account_id}/containers/registries`,errors:{401:`UnauthorizedError`,500:`InternalServerError`}};function Ie(e){return e.usage(`$0 containers registries list
74
74
 
75
- Get the list of configured registries in the account.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const Z={command:`list`,describe:`Get the list of configured registries in the account`,builder:Ie,handler:async e=>S({command:`containers registries list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let e=await s();y({command:`cf containers registries list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/containers/registries`,pathParams:{},bodyKind:`none`});return}let t=await o(e),n=e.local?a:await l();e.accountId=n;let r=await b(`Loading`,async()=>t.send(Fe,{account_id:n}));v(r,{successLabel:`Loaded`})})},Le={command:`registries`,describe:`Manage Containers image registries`,builder:e=>e.command(Oe).command(Pe).command(Z).command(je).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function Re(e){return e.positional(`path`,{type:`string`,demandOption:!0,description:`Directory containing the Dockerfile to build`}).option(`tag`,{alias:`t`,type:`string`,demandOption:!0,description:`Name and optional tag for the built image`}).option(`push`,{alias:`p`,type:`boolean`,default:!1,description:`Push the built image to Cloudflare's managed registry`}).option(`path-to-docker`,{type:`string`,description:`Path to the Docker binary if it is not on PATH`})}var ze=x({command:`build <path>`,describe:`Build a Container image`,builder:Re,handler:async t=>{if(t.local)throw Error("--local is not supported with `cf containers build`.");let n={compliance_region:t.push?await c():`public`},r=t.push?await u():``,i=g(r);p({logger:i.logger,fetchResult:i.fetchResult,fetchPagedListResult:i.fetchPagedListResult}),t.push&&m(await l(),r,e(n)),await ie({PATH:t.path,tag:t.tag,push:t.push,pathToDocker:t[`path-to-docker`]},n)}},{command:`containers build`,classification:{safeFlags:[`push`],shortFlagAliases:{p:{canonical:`push`,type:`boolean`},t:{canonical:`tag`,type:`value`}}}});function Be(e){return e.option(`tag`,{alias:`t`,type:`string`,demandOption:!0,description:`Tag of the local image to push`}).option(`path-to-docker`,{type:`string`,description:`Path to the Docker binary if it is not on PATH`})}var Ve=x({command:`push`,describe:`Push a local image to the Cloudflare managed registry`,builder:Be,handler:async t=>{if(t.local)throw Error("--local is not supported with `cf containers push`.");let n=await u(),r=await l(),i={compliance_region:await c()},a=g(n);p({logger:a.logger,fetchResult:a.fetchResult,fetchPagedListResult:a.fetchPagedListResult}),m(r,n,e(i)),await ee({TAG:t.tag,pathToDocker:t[`path-to-docker`]},r,i)}},{command:`containers push`,classification:{safeFlags:[],shortFlagAliases:{t:{canonical:`tag`,type:`value`}}}});function He(e){return e.positional(`id`,{type:`string`,demandOption:!0,description:`ID of the container instance`}).positional(`ssh-command`,{type:`string`,array:!0,description:`Command and arguments to run in the container`}).options(re).middleware(e=>{f(e)&&(e.quiet=!0)},!0).parserConfiguration({"populate--":!0,"unknown-options-as-args":!0,"parse-positional-numbers":!1})}const Q={command:`ssh <id> [ssh-command..]`,describe:`SSH into a container`,builder:He,handler:async n=>{if(n.local)throw Error("--local is not supported with `cf containers ssh`.");let r=await u(),i=await l(),a={compliance_region:await c()},o=g(r);p({logger:o.logger,fetchResult:o.fetchResult}),h.HEADERS=_(),m(i,r,e(a)),await d({...n,id:n.id,command:[...n[`ssh-command`]??[],...Array.isArray(n[`--`])?n[`--`].map(String):[]]},t)}},$=x(Q,{command:`containers ssh`,recordArgs:!1});var Ue={...$,handler:async e=>{if(f(e)){let{markCommandReported:t}=await import(`./telemetry-Da9TmAgm.mjs`);return t(),Q.handler(e)}return $.handler(e)}};const We={command:`containers`,describe:`Deploy and manage Containers applications on Cloudflare's global network`,builder:e=>e.command(i(ze,`preview`)).command(i(Ve,`preview`)).command(i(Ue,`preview`)).command(ye).command(Ee).command(Le).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{We as default};
75
+ Get the list of configured registries in the account.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const Z={command:`list`,describe:`Get the list of configured registries in the account`,builder:Ie,handler:async e=>S({command:`containers registries list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let e=await s();y({command:`cf containers registries list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/containers/registries`,pathParams:{},bodyKind:`none`});return}let t=await o(e),n=e.local?a:await l();e.accountId=n;let r=await b(`Loading`,async()=>t.send(Fe,{account_id:n}));v(r,{successLabel:`Loaded`})})},Le={command:`registries`,describe:`Manage Containers image registries`,builder:e=>e.command(Oe).command(Pe).command(Z).command(je).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function Re(e){return e.positional(`path`,{type:`string`,demandOption:!0,description:`Directory containing the Dockerfile to build`}).option(`tag`,{alias:`t`,type:`string`,demandOption:!0,description:`Name and optional tag for the built image`}).option(`push`,{alias:`p`,type:`boolean`,default:!1,description:`Push the built image to Cloudflare's managed registry`}).option(`path-to-docker`,{type:`string`,description:`Path to the Docker binary if it is not on PATH`})}var ze=x({command:`build <path>`,describe:`Build a Container image`,builder:Re,handler:async t=>{if(t.local)throw Error("--local is not supported with `cf containers build`.");let n={compliance_region:t.push?await c():`public`},r=t.push?await u():``,i=g(r);p({logger:i.logger,fetchResult:i.fetchResult,fetchPagedListResult:i.fetchPagedListResult}),t.push&&m(await l(),r,e(n)),await ie({PATH:t.path,tag:t.tag,push:t.push,pathToDocker:t[`path-to-docker`]},n)}},{command:`containers build`,classification:{safeFlags:[`push`],shortFlagAliases:{p:{canonical:`push`,type:`boolean`},t:{canonical:`tag`,type:`value`}}}});function Be(e){return e.option(`tag`,{alias:`t`,type:`string`,demandOption:!0,description:`Tag of the local image to push`}).option(`path-to-docker`,{type:`string`,description:`Path to the Docker binary if it is not on PATH`})}var Ve=x({command:`push`,describe:`Push a local image to the Cloudflare managed registry`,builder:Be,handler:async t=>{if(t.local)throw Error("--local is not supported with `cf containers push`.");let n=await u(),r=await l(),i={compliance_region:await c()},a=g(n);p({logger:a.logger,fetchResult:a.fetchResult,fetchPagedListResult:a.fetchPagedListResult}),m(r,n,e(i)),await ee({TAG:t.tag,pathToDocker:t[`path-to-docker`]},r,i)}},{command:`containers push`,classification:{safeFlags:[],shortFlagAliases:{t:{canonical:`tag`,type:`value`}}}});function He(e){return e.positional(`id`,{type:`string`,demandOption:!0,description:`ID of the container instance`}).positional(`ssh-command`,{type:`string`,array:!0,description:`Command and arguments to run in the container`}).options(re).middleware(e=>{f(e)&&(e.quiet=!0)},!0).parserConfiguration({"populate--":!0,"unknown-options-as-args":!0,"parse-positional-numbers":!1})}const Q={command:`ssh <id> [ssh-command..]`,describe:`SSH into a container`,builder:He,handler:async n=>{if(n.local)throw Error("--local is not supported with `cf containers ssh`.");let r=await u(),i=await l(),a={compliance_region:await c()},o=g(r);p({logger:o.logger,fetchResult:o.fetchResult}),h.HEADERS=_(),m(i,r,e(a)),await d({...n,id:n.id,command:[...n[`ssh-command`]??[],...Array.isArray(n[`--`])?n[`--`].map(String):[]]},t)}},$=x(Q,{command:`containers ssh`,recordArgs:!1});var Ue={...$,handler:async e=>{if(f(e)){let{markCommandReported:t}=await import(`./telemetry-DJ8-Q2pU.mjs`);return t(),Q.handler(e)}return $.handler(e)}};const We={command:`containers`,describe:`Deploy and manage Containers applications on Cloudflare's global network`,builder:e=>e.command(i(ze,`preview`)).command(i(Ve,`preview`)).command(i(Ue,`preview`)).command(ye).command(Ee).command(Le).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{We as default};
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-X3wKppsT.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-DkPhAgZv.mjs";import{i as n}from"./context-DoGlohS-.mjs";import{t as r}from"./output-BJEgbI0G.mjs";import{t as i}from"./dry-run-gy0Hl9xo.mjs";import{t as a}from"./progress-D2_AF54c.mjs";import{t as o}from"./run-C2-1SFrS.mjs";import"./telemetry-Q7QghPwV.mjs";import{n as s,t as c}from"./body-parser-BKcZS9iJ.mjs";import{n as l}from"./input-validation-D7z60HJH.mjs";import{a as u,i as d,n as f}from"./prompt-BBR19lgj.mjs";var p={method:`POST`,path:t=>e`/zones/${t.zone_id}/content-upload-scan/payloads`,body:`json`};function m(e){return e.usage(`$0 content-scan expressions create
2
+ import"./api-X3wKppsT.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-CB9wjyad.mjs";import{i as n}from"./context-DCon1tRZ.mjs";import{t as r}from"./output-BJEgbI0G.mjs";import{t as i}from"./dry-run-gy0Hl9xo.mjs";import{t as a}from"./progress-_Jux05O5.mjs";import{t as o}from"./run-Br8sYjNF.mjs";import"./telemetry-kjElc1zT.mjs";import{n as s,t as c}from"./body-parser-BKcZS9iJ.mjs";import{n as l}from"./input-validation-D7z60HJH.mjs";import{a as u,i as d,n as f}from"./prompt-SNVLBS1b.mjs";var p={method:`POST`,path:t=>e`/zones/${t.zone_id}/content-upload-scan/payloads`,body:`json`};function m(e){return e.usage(`$0 content-scan expressions create
3
3
 
4
4
  Create one or more Content Scanning custom expressions, appending them to the existing list of the zone, and return the updated list. Each expression reaches content objects the scanner cannot find automatically, for example \`lookup_json_string(http.request.body.raw, "file")\`.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Array of Content Scanning custom expressions to create.`})}const h={command:`create`,describe:`Create Content Scanning custom expressions for a zone.`,builder:m,handler:async e=>o({command:`content-scan expressions create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf content-scan expressions create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/content-upload-scan/payloads`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?void 0:s(e.body)});return}let o=await t(e),c=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=c,e.body){let t=s(e.body),n=await a(`Creating`,async()=>o.send(p,{body:t,zone_id:c}));r(n,{successLabel:`Created`})}else if(e.body===void 0)throw Error(`--body is required for this command. Pass --body '<json>' or --body @path/to/file.json.`)})};var g={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/content-upload-scan/payloads/${t.expression_id}`};function _(e){return e.usage(`$0 content-scan expressions delete <expression-id>
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{i as e,r as t}from"./project-settings-nBMEx1f-.mjs";import{n}from"./resolve-C3FmNlSO.mjs";function r(e,t){if(t)return{value:t,source:`flag`};let n=process.env[e];if(n)return{value:n,source:`env`}}async function i(n={}){let r=process.env.CLOUDFLARE_ACCOUNT_ID;if(r)return{value:r,source:`env`};if(n.skipProjectSettings)return;let i=t(void 0,n),a=i===void 0?await e(void 0,n):i;if(a?.settings?.accountId)return{value:a.settings.accountId,source:`settings`,path:a.path}}async function a(){let{getActiveAccountId:e,isTemporaryAccountRequested:t}=await import(`./oauth-BX5dMp7e.mjs`);if(t())return;let n=await i();if(n)return n.value;try{return e()}catch{return}}async function o(e){let{getOrSelectAccountId:t,isTemporaryAccountRequested:n,requireTemporaryAccount:r}=await import(`./oauth-BX5dMp7e.mjs`);if(n())return(await r(e)).accountId;let a=await i(e);return a&&s(a.value,h(a,`accountId`)),t(a?.value,e)}function s(e,t){if(!process.env.DEBUG)return;let n=e.length>12?e.slice(0,12)+`…`:e;process.stderr.write(`Using account: ${n} (${t})\n`)}async function c(e,t,n){if(e?.zoneId)return l(e.zoneId,t);let i=r(`CLOUDFLARE_ZONE_ID`,e?.zone);if(i){if(!n?.quiet&&i.source!==`flag`){let e=h(i);console.error(`Using zone: ${i.value} (from ${e})`)}return l(i.value,t)}throw Error(`No zone specified.
2
+ import{i as e,r as t}from"./project-settings-nBMEx1f-.mjs";import{n}from"./resolve-C3FmNlSO.mjs";function r(e,t){if(t)return{value:t,source:`flag`};let n=process.env[e];if(n)return{value:n,source:`env`}}async function i(n={}){let r=process.env.CLOUDFLARE_ACCOUNT_ID;if(r)return{value:r,source:`env`};if(n.skipProjectSettings)return;let i=t(void 0,n),a=i===void 0?await e(void 0,n):i;if(a?.settings?.accountId)return{value:a.settings.accountId,source:`settings`,path:a.path}}async function a(){let{getActiveAccountId:e,isTemporaryAccountRequested:t}=await import(`./oauth-CuM12iNb.mjs`);if(t())return;let n=await i();if(n)return n.value;try{return e()}catch{return}}async function o(e){let{getOrSelectAccountId:t,isTemporaryAccountRequested:n,requireTemporaryAccount:r}=await import(`./oauth-CuM12iNb.mjs`);if(n())return(await r(e)).accountId;let a=await i(e);return a&&s(a.value,h(a,`accountId`)),t(a?.value,e)}function s(e,t){if(!process.env.DEBUG)return;let n=e.length>12?e.slice(0,12)+`…`:e;process.stderr.write(`Using account: ${n} (${t})\n`)}async function c(e,t,n){if(e?.zoneId)return l(e.zoneId,t);let i=r(`CLOUDFLARE_ZONE_ID`,e?.zone);if(i){if(!n?.quiet&&i.source!==`flag`){let e=h(i);console.error(`Using zone: ${i.value} (from ${e})`)}return l(i.value,t)}throw Error(`No zone specified.
3
3
 
4
4
  Please provide one of the following:
5
5
  1. Zone as a positional argument: cf dns records list <zone>
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{n as e}from"./auth-DkPhAgZv.mjs";import{t}from"./output-BJEgbI0G.mjs";import{t as n}from"./dry-run-gy0Hl9xo.mjs";import{t as r}from"./progress-D2_AF54c.mjs";import{t as i}from"./run-C2-1SFrS.mjs";import"./telemetry-Q7QghPwV.mjs";import{n as a,r as o,t as s}from"./body-parser-BKcZS9iJ.mjs";import{n as c}from"./input-validation-D7z60HJH.mjs";var l={method:`GET`,path:()=>`/user/communication_preferences`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,404:`NotFoundError`,500:`InternalServerError`}};function u(e){return e.usage(`$0 cps get
2
+ import{n as e}from"./auth-CB9wjyad.mjs";import{t}from"./output-BJEgbI0G.mjs";import{t as n}from"./dry-run-gy0Hl9xo.mjs";import{t as r}from"./progress-_Jux05O5.mjs";import{t as i}from"./run-Br8sYjNF.mjs";import"./telemetry-kjElc1zT.mjs";import{n as a,r as o,t as s}from"./body-parser-BKcZS9iJ.mjs";import{n as c}from"./input-validation-D7z60HJH.mjs";var l={method:`GET`,path:()=>`/user/communication_preferences`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,404:`NotFoundError`,500:`InternalServerError`}};function u(e){return e.usage(`$0 cps get
3
3
 
4
4
  Retrieve the communication preferences for the authenticated user, including email verification status, marketing subscription opt-in/opt-out state, and language locale. Callers authenticate with standard Cloudflare API tokens or keys.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const d={command:`get`,describe:`Get communication preferences`,builder:u,handler:async a=>i({command:`cps get`,classification:{safeFlags:[`dry-run`]}},a,async()=>{if(a.dryRun){n({command:`cf cps get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/user/communication_preferences`,pathParams:{},bodyKind:`none`});return}let i=await e(a),o=await r(`Loading`,async()=>i.send(l));t(o,{successLabel:`Loaded`})})};var f={method:`PUT`,path:()=>`/user/communication_preferences`,body:`json`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,404:`NotFoundError`,500:`InternalServerError`}};function p(e){return e.usage(`$0 cps update
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-X3wKppsT.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-DkPhAgZv.mjs";import{i as n}from"./context-DoGlohS-.mjs";import{t as r}from"./output-BJEgbI0G.mjs";import{t as i}from"./dry-run-gy0Hl9xo.mjs";import{t as a}from"./progress-D2_AF54c.mjs";import{t as o}from"./run-C2-1SFrS.mjs";import"./telemetry-Q7QghPwV.mjs";import{n as s,r as c,t as l}from"./body-parser-BKcZS9iJ.mjs";import{n as u}from"./input-validation-D7z60HJH.mjs";var d={method:`PATCH`,path:t=>e`/zones/${t.zone_id}/settings/csam_scanner_third_party`,body:`json`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,404:`NotFoundError`,500:`InternalServerError`}};function f(e){return e.usage(`$0 csam-scanner edit
2
+ import"./api-X3wKppsT.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-CB9wjyad.mjs";import{i as n}from"./context-DCon1tRZ.mjs";import{t as r}from"./output-BJEgbI0G.mjs";import{t as i}from"./dry-run-gy0Hl9xo.mjs";import{t as a}from"./progress-_Jux05O5.mjs";import{t as o}from"./run-Br8sYjNF.mjs";import"./telemetry-kjElc1zT.mjs";import{n as s,r as c,t as l}from"./body-parser-BKcZS9iJ.mjs";import{n as u}from"./input-validation-D7z60HJH.mjs";var d={method:`PATCH`,path:t=>e`/zones/${t.zone_id}/settings/csam_scanner_third_party`,body:`json`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,404:`NotFoundError`,500:`InternalServerError`}};function f(e){return e.usage(`$0 csam-scanner edit
3
3
 
4
4
  Update the CSAM Scanner configuration for a zone. Allows enabling or disabling CSAM scanning, updating the notification email, and configuring scanning sources. When a new email is provided, email verification is triggered automatically. The \`enabled\` field is a toggle; the server may adjust it based on whether the notification email is verified. Returns 403 if the zone or account is locked by Trust & Safety.`).option(`id`,{type:`string`,description:`The feature identifier.`,choices:[`csam_scanner`]}).coerce(`id`,e=>u(e,`id`,`text`)).option(`value-email`,{type:`string`,description:`Notification email address for CSAM scan results. When changed,
5
5
  email verification is triggered automatically.
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-X3wKppsT.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-Y4rIAAtA.mjs";import{n}from"./auth-DkPhAgZv.mjs";import{a as r,i,t as a}from"./context-DoGlohS-.mjs";import{t as o}from"./output-BJEgbI0G.mjs";import{t as s}from"./dry-run-gy0Hl9xo.mjs";import{t as c}from"./progress-D2_AF54c.mjs";import{t as l}from"./run-C2-1SFrS.mjs";import"./telemetry-Q7QghPwV.mjs";import{n as u,t as d}from"./body-parser-BKcZS9iJ.mjs";import{n as f}from"./input-validation-D7z60HJH.mjs";import{a as p,n as m}from"./prompt-BBR19lgj.mjs";var h={method:`POST`,path:t=>e`/${t.account_or_zone}/${t.account_or_zone_id}/custom_csrs`,body:`json`};function g(e){return e.usage(`$0 custom-csrs create
2
+ import"./api-X3wKppsT.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-BNmz58v4.mjs";import{n}from"./auth-CB9wjyad.mjs";import{a as r,i,t as a}from"./context-DCon1tRZ.mjs";import{t as o}from"./output-BJEgbI0G.mjs";import{t as s}from"./dry-run-gy0Hl9xo.mjs";import{t as c}from"./progress-_Jux05O5.mjs";import{t as l}from"./run-Br8sYjNF.mjs";import"./telemetry-kjElc1zT.mjs";import{n as u,t as d}from"./body-parser-BKcZS9iJ.mjs";import{n as f}from"./input-validation-D7z60HJH.mjs";import{a as p,n as m}from"./prompt-SNVLBS1b.mjs";var h={method:`POST`,path:t=>e`/${t.account_or_zone}/${t.account_or_zone_id}/custom_csrs`,body:`json`};function g(e){return e.usage(`$0 custom-csrs create
3
3
 
4
4
  Generate a new custom Certificate Signing Request (CSR) for an account or zone. Cloudflare generates and securely stores the private key associated with the CSR.`).option(`common-name`,{type:`string`,description:`The common name (domain) for the CSR. Must be at most 64 characters.`}).option(`country`,{type:`string`,description:`Two-letter ISO 3166-1 alpha-2 country code.`}).option(`description`,{type:`string`,description:`Optional description for the CSR.`}).option(`key-type`,{type:`string`,description:`Key algorithm to use for the CSR. Defaults to rsa2048 if not specified.`,choices:[`rsa2048`,`p256v1`],default:`rsa2048`}).coerce(`key-type`,e=>f(e,`key-type`,`text`)).option(`locality`,{type:`string`,description:`City or locality name.`}).option(`name`,{type:`string`,description:`Human-readable name for the CSR.`}).option(`organization`,{type:`string`,description:`Organization name.`}).option(`organizational-unit`,{type:`string`,description:`Organizational unit name.`}).option(`sans`,{type:`string`,array:!0,description:`Subject Alternative Names for the CSR. At least one SAN is required.`}).option(`state`,{type:`string`,description:`State or province name.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Request body for creating a custom CSR.`})}const _={command:`create`,describe:`Create Custom CSR`,builder:g,handler:async e=>l({command:`custom-csrs create`,classification:{safeFlags:[`key-type`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=e.zone===void 0?await r():void 0,n=e.zone===void 0?`accounts`:`zones`,i=e.zone??t??`<account-id>`;s({command:`cf custom-csrs create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/${n}/${i}/custom_csrs`,pathParams:{"account-or-zone":String(n),"account-or-zone-id":String(i)},bodyKind:`json`,body:e.body===void 0?d({common_name:f(e[`common-name`],`common-name`,`text`),country:f(e.country,`country`,`text`),description:f(e.description,`description`,`text`),key_type:e[`key-type`],locality:f(e.locality,`locality`,`text`),name:f(e.name,`name`,`text`),organization:f(e.organization,`organization`,`text`),organizational_unit:f(e[`organizational-unit`],`organizational-unit`,`text`),sans:e.sans,state:f(e.state,`state`,`text`)}):u(e.body)});return}let l=await n(e),m=e.zone===void 0?`accounts`:`zones`,g=m===`zones`?await i({zone:e.zone},l,{quiet:e.quiet}):e.local?t:await a();if(m===`zones`?e.zoneId=g:e.accountId=g,e.body){let t=u(e.body),n=await c(`Creating`,async()=>l.send(h,{body:t,account_or_zone:m,account_or_zone_id:g}));o(n,{successLabel:`Created`});return}if(e[`common-name`]===void 0&&(e[`common-name`]=await p(`common-name`,`The common name (domain) for the CSR. Must be at most 64 characters.`)),e.country===void 0&&(e.country=await p(`country`,`Two-letter ISO 3166-1 alpha-2 country code.`)),e.locality===void 0&&(e.locality=await p(`locality`,`City or locality name.`)),e.organization===void 0&&(e.organization=await p(`organization`,`Organization name.`)),e.sans===void 0)throw Error(`--sans is required (or pass --body with this field set).`);e.state===void 0&&(e.state=await p(`state`,`State or province name.`));let _=d({common_name:f(e[`common-name`],`common-name`,`text`),country:f(e.country,`country`,`text`),description:f(e.description,`description`,`text`),key_type:e[`key-type`],locality:f(e.locality,`locality`,`text`),name:f(e.name,`name`,`text`),organization:f(e.organization,`organization`,`text`),organizational_unit:f(e[`organizational-unit`],`organizational-unit`,`text`),sans:e.sans,state:f(e.state,`state`,`text`)}),v=await c(`Creating`,async()=>l.send(h,{body:_,account_or_zone:m,account_or_zone_id:g}));o(v,{successLabel:`Created`})})};var v={method:`DELETE`,path:t=>e`/${t.account_or_zone}/${t.account_or_zone_id}/custom_csrs/${t.custom_csr_id}`};function y(e){return e.usage(`$0 custom-csrs delete <custom-csr-id>
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-X3wKppsT.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-DkPhAgZv.mjs";import{i as n}from"./context-DoGlohS-.mjs";import{t as r}from"./output-BJEgbI0G.mjs";import{t as i}from"./dry-run-gy0Hl9xo.mjs";import{t as a}from"./progress-D2_AF54c.mjs";import{t as o}from"./run-C2-1SFrS.mjs";import"./telemetry-Q7QghPwV.mjs";import{a as s,n as c,r as l,t as u}from"./body-parser-BKcZS9iJ.mjs";import{n as d}from"./input-validation-D7z60HJH.mjs";import{a as f,n as p}from"./prompt-BBR19lgj.mjs";var m={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/custom_hostnames/${t.custom_hostname_id}/certificate_pack/${t.certificate_pack_id}/certificates/${t.certificate_id}`};function h(e){return e.usage(`$0 custom-hostnames certificate-pack certificates delete <certificate-id>
2
+ import"./api-X3wKppsT.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-CB9wjyad.mjs";import{i as n}from"./context-DCon1tRZ.mjs";import{t as r}from"./output-BJEgbI0G.mjs";import{t as i}from"./dry-run-gy0Hl9xo.mjs";import{t as a}from"./progress-_Jux05O5.mjs";import{t as o}from"./run-Br8sYjNF.mjs";import"./telemetry-kjElc1zT.mjs";import{a as s,n as c,r as l,t as u}from"./body-parser-BKcZS9iJ.mjs";import{n as d}from"./input-validation-D7z60HJH.mjs";import{a as f,n as p}from"./prompt-SNVLBS1b.mjs";var m={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/custom_hostnames/${t.custom_hostname_id}/certificate_pack/${t.certificate_pack_id}/certificates/${t.certificate_id}`};function h(e){return e.usage(`$0 custom-hostnames certificate-pack certificates delete <certificate-id>
3
3
 
4
4
  Delete a single custom certificate from a certificate pack that contains two bundled certificates. Deletion is subject to the following constraints. You cannot delete a certificate if it is the only remaining certificate in the pack. At least one certificate must remain in the pack.`).positional(`certificate-id`,{type:`string`,description:`Custom hostname identifier tag.`,demandOption:!0}).option(`custom-hostname-id`,{type:`string`,description:`Custom hostname identifier tag.`,demandOption:!0}).option(`certificate-pack-id`,{type:`string`,description:`Custom hostname identifier tag.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const g={command:`delete <certificate-id>`,describe:`Delete Single Certificate And Key For Custom Hostname`,builder:h,handler:async e=>o({command:`custom-hostnames certificate-pack certificates delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){i({command:`cf custom-hostnames certificate-pack certificates delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/custom_hostnames/${e[`custom-hostname-id`]==null?`<custom-hostname-id>`:encodeURIComponent(String(e[`custom-hostname-id`]))}/certificate_pack/${e[`certificate-pack-id`]==null?`<certificate-pack-id>`:encodeURIComponent(String(e[`certificate-pack-id`]))}/certificates/${e[`certificate-id`]==null?`<certificate-id>`:encodeURIComponent(String(e[`certificate-id`]))}`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``),"custom-hostname-id":String(e[`custom-hostname-id`]??``),"certificate-pack-id":String(e[`certificate-pack-id`]??``),"certificate-id":String(e[`certificate-id`]??``)},bodyKind:`none`});return}let o=await t(e),s=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=s,!await p({force:!!e.force}))return;let c=await a(`Deleting`,async()=>o.send(m,{zone_id:s,custom_hostname_id:e[`custom-hostname-id`],certificate_pack_id:e[`certificate-pack-id`],certificate_id:e[`certificate-id`]}));r(c,{successLabel:`Deleted`})})};var _={method:`PUT`,path:t=>e`/zones/${t.zone_id}/custom_hostnames/${t.custom_hostname_id}/certificate_pack/${t.certificate_pack_id}/certificates/${t.certificate_id}`,body:`json`};function v(e){return e.usage(`$0 custom-hostnames certificate-pack certificates update <certificate-id>
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-X3wKppsT.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-Y4rIAAtA.mjs";import{n}from"./auth-DkPhAgZv.mjs";import{a as r,i,t as a}from"./context-DoGlohS-.mjs";import{t as o}from"./output-BJEgbI0G.mjs";import{t as s}from"./dry-run-gy0Hl9xo.mjs";import{t as c}from"./progress-D2_AF54c.mjs";import{t as l}from"./run-C2-1SFrS.mjs";import"./telemetry-Q7QghPwV.mjs";import{n as u,t as d}from"./body-parser-BKcZS9iJ.mjs";import{n as f}from"./input-validation-D7z60HJH.mjs";import{a as p,n as m}from"./prompt-BBR19lgj.mjs";var h={method:`POST`,path:t=>e`/${t.account_or_zone}/${t.account_or_zone_id}/custom_ns`,body:`json`};function g(e){return e.usage(`$0 custom-nameservers create
2
+ import"./api-X3wKppsT.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-BNmz58v4.mjs";import{n}from"./auth-CB9wjyad.mjs";import{a as r,i,t as a}from"./context-DCon1tRZ.mjs";import{t as o}from"./output-BJEgbI0G.mjs";import{t as s}from"./dry-run-gy0Hl9xo.mjs";import{t as c}from"./progress-_Jux05O5.mjs";import{t as l}from"./run-Br8sYjNF.mjs";import"./telemetry-kjElc1zT.mjs";import{n as u,t as d}from"./body-parser-BKcZS9iJ.mjs";import{n as f}from"./input-validation-D7z60HJH.mjs";import{a as p,n as m}from"./prompt-SNVLBS1b.mjs";var h={method:`POST`,path:t=>e`/${t.account_or_zone}/${t.account_or_zone_id}/custom_ns`,body:`json`};function g(e){return e.usage(`$0 custom-nameservers create
3
3
 
4
4
  Adds a custom nameserver to the account or zone for use as a vanity nameserver on zones.`).option(`ns-name`,{type:`string`,description:`The FQDN of the name server.`}).option(`ns-set`,{type:`number`,description:`The number of the set that this name server belongs to.`,default:1}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const _={command:`create`,describe:`Add account or zone Custom Nameserver`,builder:g,handler:async e=>l({command:`custom-nameservers create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=e.zone===void 0?await r():void 0,n=e.zone===void 0?`accounts`:`zones`,i=e.zone??t??`<account-id>`;s({command:`cf custom-nameservers create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/${n}/${i}/custom_ns`,pathParams:{"account-or-zone":String(n),"account-or-zone-id":String(i)},bodyKind:`json`,body:e.body===void 0?d({ns_name:f(e[`ns-name`],`ns-name`,`text`),ns_set:e[`ns-set`]}):u(e.body)});return}let l=await n(e),m=e.zone===void 0?`accounts`:`zones`,g=m===`zones`?await i({zone:e.zone},l,{quiet:e.quiet}):e.local?t:await a();if(m===`zones`?e.zoneId=g:e.accountId=g,e.body){let t=u(e.body),n=await c(`Creating`,async()=>l.send(h,{body:t,account_or_zone:m,account_or_zone_id:g}));o(n,{successLabel:`Created`});return}e[`ns-name`]===void 0&&(e[`ns-name`]=await p(`ns-name`,`The FQDN of the name server.`));let _=d({ns_name:f(e[`ns-name`],`ns-name`,`text`),ns_set:e[`ns-set`]}),v=await c(`Creating`,async()=>l.send(h,{body:_,account_or_zone:m,account_or_zone_id:g}));o(v,{successLabel:`Created`})})};var v={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/custom_ns/${t.custom_ns_id}`};function y(e){return e.usage(`$0 custom-nameservers delete <custom-ns-id>
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-X3wKppsT.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-Y4rIAAtA.mjs";import{n}from"./auth-DkPhAgZv.mjs";import{a as r,i,t as a}from"./context-DoGlohS-.mjs";import{t as o}from"./output-BJEgbI0G.mjs";import{t as s}from"./dry-run-gy0Hl9xo.mjs";import{t as c}from"./progress-D2_AF54c.mjs";import{t as l}from"./run-C2-1SFrS.mjs";import"./telemetry-Q7QghPwV.mjs";import{n as u,t as d}from"./body-parser-BKcZS9iJ.mjs";import{n as f}from"./input-validation-D7z60HJH.mjs";import{a as p,i as m,n as h}from"./prompt-BBR19lgj.mjs";var g={method:`POST`,path:t=>e`/${t.account_or_zone}/${t.account_or_zone_id}/custom_pages/assets`,body:`json`};function _(e){return e.usage(`$0 custom-pages account-assets create
2
+ import"./api-X3wKppsT.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-BNmz58v4.mjs";import{n}from"./auth-CB9wjyad.mjs";import{a as r,i,t as a}from"./context-DCon1tRZ.mjs";import{t as o}from"./output-BJEgbI0G.mjs";import{t as s}from"./dry-run-gy0Hl9xo.mjs";import{t as c}from"./progress-_Jux05O5.mjs";import{t as l}from"./run-Br8sYjNF.mjs";import"./telemetry-kjElc1zT.mjs";import{n as u,t as d}from"./body-parser-BKcZS9iJ.mjs";import{n as f}from"./input-validation-D7z60HJH.mjs";import{a as p,i as m,n as h}from"./prompt-SNVLBS1b.mjs";var g={method:`POST`,path:t=>e`/${t.account_or_zone}/${t.account_or_zone_id}/custom_pages/assets`,body:`json`};function _(e){return e.usage(`$0 custom-pages account-assets create
3
3
 
4
4
  Creates a custom asset for an account or zone.`).option(`description`,{type:`string`,description:`A short description of the custom asset.`}).option(`name`,{type:`string`,description:`The unique name of the custom asset. Can only contain letters (A-Z, a-z), numbers (0-9), and underscores (_).`}).option(`url`,{type:`string`,description:`The URL where the asset content is fetched from.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const v={command:`create`,describe:`Create a custom asset`,builder:_,handler:async e=>l({command:`custom-pages account-assets create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=e.zone===void 0?await r():void 0,n=e.zone===void 0?`accounts`:`zones`,i=e.zone??t??`<account-id>`;s({command:`cf custom-pages account-assets create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/${n}/${i}/custom_pages/assets`,pathParams:{"account-or-zone":String(n),"account-or-zone-id":String(i)},bodyKind:`json`,body:e.body===void 0?d({description:f(e.description,`description`,`text`),name:f(e.name,`name`,`text`),url:f(e.url,`url`,`text`)}):u(e.body)});return}let l=await n(e),m=e.zone===void 0?`accounts`:`zones`,h=m===`zones`?await i({zone:e.zone},l,{quiet:e.quiet}):e.local?t:await a();if(m===`zones`?e.zoneId=h:e.accountId=h,e.body){let t=u(e.body),n=await c(`Creating`,async()=>l.send(g,{body:t,account_or_zone:m,account_or_zone_id:h}));o(n,{successLabel:`Created`});return}e.description===void 0&&(e.description=await p(`description`,`A short description of the custom asset.`)),e.name===void 0&&(e.name=await p(`name`,`The unique name of the custom asset. Can only contain letters (A-Z, a-z), numbers (0-9), and underscores (_).`)),e.url===void 0&&(e.url=await p(`url`,`The URL where the asset content is fetched from.`));let _=d({description:f(e.description,`description`,`text`),name:f(e.name,`name`,`text`),url:f(e.url,`url`,`text`)}),v=await c(`Creating`,async()=>l.send(g,{body:_,account_or_zone:m,account_or_zone_id:h}));o(v,{successLabel:`Created`})})};var y={method:`DELETE`,path:t=>e`/${t.account_or_zone}/${t.account_or_zone_id}/custom_pages/assets/${t.asset_name}`,response:!1};function b(e){return e.usage(`$0 custom-pages account-assets delete <asset-name>
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-X3wKppsT.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./hand-written-dry-run-B82fRl2N.mjs";import{t as n}from"./local-Y4rIAAtA.mjs";import{n as r}from"./auth-DkPhAgZv.mjs";import{n as i}from"./resolve-C3FmNlSO.mjs";import{a,t as o}from"./context-DoGlohS-.mjs";import{t as s}from"./output-BJEgbI0G.mjs";import{t as c}from"./dry-run-gy0Hl9xo.mjs";import{t as l}from"./progress-D2_AF54c.mjs";import{n as u,t as d}from"./run-C2-1SFrS.mjs";import"./telemetry-Q7QghPwV.mjs";import{a as f,n as p,t as m}from"./body-parser-BKcZS9iJ.mjs";import{n as h}from"./input-validation-D7z60HJH.mjs";import{a as g,i as _,n as v,t as y}from"./prompt-BBR19lgj.mjs";import b from"node:fs";import x from"node:path";var ee={method:`POST`,path:t=>e`/accounts/${t.account_id}/d1/database`,body:`json`};function te(e){return e.usage(`$0 d1 create
2
+ import"./api-X3wKppsT.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./hand-written-dry-run-B82fRl2N.mjs";import{t as n}from"./local-BNmz58v4.mjs";import{n as r}from"./auth-CB9wjyad.mjs";import{n as i}from"./resolve-C3FmNlSO.mjs";import{a,t as o}from"./context-DCon1tRZ.mjs";import{t as s}from"./output-BJEgbI0G.mjs";import{t as c}from"./dry-run-gy0Hl9xo.mjs";import{t as l}from"./progress-_Jux05O5.mjs";import{n as u,t as d}from"./run-Br8sYjNF.mjs";import"./telemetry-kjElc1zT.mjs";import{a as f,n as p,t as m}from"./body-parser-BKcZS9iJ.mjs";import{n as h}from"./input-validation-D7z60HJH.mjs";import{a as g,i as _,n as v,t as y}from"./prompt-SNVLBS1b.mjs";import b from"node:fs";import x from"node:path";var ee={method:`POST`,path:t=>e`/accounts/${t.account_id}/d1/database`,body:`json`};function te(e){return e.usage(`$0 d1 create
3
3
 
4
4
  Create a new D1 database in your account.`).option(`jurisdiction`,{type:`string`,description:`Specify the location to restrict the D1 database to run and store data. If this option is present, the location hint is ignored.`,choices:[`eu`,`fedramp`,`us`]}).coerce(`jurisdiction`,e=>h(e,`jurisdiction`,`text`)).option(`name`,{type:`string`,description:`D1 database name.`}).option(`primary-location-hint`,{type:`string`,description:`Specify the region to create the D1 primary, if available. If this option is omitted, the D1 will be created as close as possible to the current user.`,choices:[`wnam`,`enam`,`weur`,`eeur`,`apac`,`oc`]}).coerce(`primary-location-hint`,e=>h(e,`primary-location-hint`,`text`)).option(`read-replication-mode`,{type:`string`,description:`The read replication mode for the database. Use 'auto' to create replicas and allow D1 automatically place them around the world, or 'disabled' to not use any database replicas (it can take a few hours for all replicas to be deleted).`,choices:[`auto`,`disabled`]}).coerce(`read-replication-mode`,e=>h(e,`read-replication-mode`,`text`)).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`}).check(e=>{if([`read-replication-mode`].some(t=>e[t]!==void 0)){let t=[`read-replication-mode`].filter(t=>e[t]===void 0);if(t.length>0)throw Error(`${t.map(e=>`--`+e).join(`, `)} ${t.length===1?`is`:`are`} required when any --read_replication-* flag is set`)}return!0})}const ne={command:`create`,describe:`Create D1 Database`,builder:te,handler:async e=>d({command:`d1 create`,classification:{safeFlags:[`jurisdiction`,`primary-location-hint`,`read-replication-mode`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=await a();c({command:`cf d1 create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/d1/database`,pathParams:{},bodyKind:`json`,body:e.body===void 0?m({jurisdiction:e.jurisdiction,name:h(e.name,`name`,`text`),primary_location_hint:e[`primary-location-hint`],read_replication:{mode:e[`read-replication-mode`]}}):p(e.body)});return}let t=await r(e),i=e.local?n:await o();if(e.accountId=i,e.body){let n=p(e.body),r=await l(`Creating`,async()=>t.send(ee,{body:n,account_id:i}));s(r,{successLabel:`Created`});return}e.name===void 0&&(e.name=await g(`name`,`D1 database name.`));let u=m({jurisdiction:e.jurisdiction,name:h(e.name,`name`,`text`),primary_location_hint:e[`primary-location-hint`],read_replication:{mode:e[`read-replication-mode`]}}),d=await l(`Creating`,async()=>t.send(ee,{body:u,account_id:i}));s(d,{successLabel:`Created`})})};var re={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/d1/database/${t.database_id}`};function ie(e){return e.usage(`$0 d1 delete <database-id>
5
5
 
@@ -7,7 +7,7 @@ Delete a D1 database.`).positional(`database-id`,{type:`string`,description:`D1
7
7
 
8
8
  Partially update a D1 database's configuration.`).positional(`database-id`,{type:`string`,description:`D1 database identifier (UUID).`,demandOption:!0}).option(`read-replication-mode`,{type:`string`,description:`The read replication mode for the database. Use 'auto' to create replicas and allow D1 automatically place them around the world, or 'disabled' to not use any database replicas (it can take a few hours for all replicas to be deleted).`,choices:[`auto`,`disabled`]}).coerce(`read-replication-mode`,e=>h(e,`read-replication-mode`,`text`)).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`}).check(e=>{if([`read-replication-mode`].some(t=>e[t]!==void 0)){let t=[`read-replication-mode`].filter(t=>e[t]===void 0);if(t.length>0)throw Error(`${t.map(e=>`--`+e).join(`, `)} ${t.length===1?`is`:`are`} required when any --read_replication-* flag is set`)}return!0})}const ce={command:`edit <database-id>`,describe:`Update D1 Database partially`,builder:se,handler:async e=>d({command:`d1 edit`,classification:{safeFlags:[`read-replication-mode`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=await a();c({command:`cf d1 edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/d1/database/${e[`database-id`]==null?`<database-id>`:encodeURIComponent(String(e[`database-id`]))}`,pathParams:{"database-id":String(e[`database-id`]??``)},bodyKind:`json`,body:e.body===void 0?m({read_replication:{mode:e[`read-replication-mode`]}}):p(e.body)});return}let t=await r(e),i=e.local?n:await o();if(e.accountId=i,e.body){let n=p(e.body),r=await l(`Updating`,async()=>t.send(oe,{body:n,account_id:i,database_id:e[`database-id`]}));s(r,{successLabel:`Updated`});return}let u=m({read_replication:{mode:e[`read-replication-mode`]}}),d=await l(`Updating`,async()=>t.send(oe,{body:u,account_id:i,database_id:e[`database-id`]}));s(d,{successLabel:`Updated`})})};var le={method:`GET`,path:t=>e`/accounts/${t.account_id}/d1/database/${t.database_id}`,query:[`fields`],joined:[`fields`]};function ue(e){return e.usage(`$0 d1 get <database-id>
9
9
 
10
- Get details for a specific D1 database.`).positional(`database-id`,{type:`string`,description:`Database ID`,demandOption:!0}).option(`fields`,{type:`string`,description:`Comma-separated list of fields to include in the response. When omitted,
10
+ Get details for a specific D1 database.`).positional(`database-id`,{type:`string`,description:`Database ID`,demandOption:!0}).option(`fields`,{type:`string`,array:!0,description:`Comma-separated list of fields to include in the response. When omitted,
11
11
  all fields are returned.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const de={command:`get <database-id>`,describe:`Get D1 Database`,builder:ue,handler:async e=>d({command:`d1 get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{let t={fields:e.fields};if(e.dryRun){let n=await a();c({command:`cf d1 get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${n??`<account-id>`}/d1/database/${e[`database-id`]==null?`<database-id>`:encodeURIComponent(String(e[`database-id`]))}`,pathParams:{"database-id":String(e[`database-id`]??``)},query:t,bodyKind:`none`});return}let i=await r(e),u=e.local?n:await o();e.accountId=u;let d=await l(`Loading`,async()=>i.send(le,{account_id:u,database_id:e[`database-id`],...t}));s(d,{successLabel:`Loaded`})})};var fe={method:`GET`,path:t=>e`/accounts/${t.account_id}/d1/database`,query:[`name`,`page`,`per_page`]};function pe(e){return e.usage(`$0 d1 list
12
12
 
13
13
  List D1 databases in your account.`).option(`name`,{type:`string`,description:`a database name to search for.`}).option(`page`,{type:`number`,description:`Page number of paginated results.`}).option(`per-page`,{type:`number`,description:`Number of items per page.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const me={command:`list`,describe:`List D1 Databases`,builder:pe,handler:async e=>d({command:`d1 list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{let t={name:e.name,page:e.page,per_page:e[`per-page`]};if(e.dryRun){let e=await a();c({command:`cf d1 list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/d1/database`,pathParams:{},query:t,bodyKind:`none`});return}let i=await r(e),u=e.local?n:await o();e.accountId=u;let d=await l(`Loading`,async()=>i.send(fe,{account_id:u,...t}));s(d,{successLabel:`Loaded`})})};var S={method:`POST`,path:t=>e`/accounts/${t.account_id}/d1/database/${t.database_id}/query`,body:`json`};function he(e){return e.usage(`$0 d1 query <database-id>
@@ -1,2 +1,2 @@
1
1
  #!/usr/bin/env node
2
- import{t as e}from"./package-C4H_6MHV.mjs";import{createRequire as t}from"node:module";import{existsSync as n,readFileSync as r,realpathSync as i}from"node:fs";import{dirname as a,resolve as o}from"node:path";import{fileURLToPath as s}from"node:url";import{constants as c}from"node:os";import{spawn as l}from"node:child_process";const u=`CF_DELEGATION`,d=`CF_DELEGATING_CLI_VERSION`,f=`CF_DELEGATION_PID`;function p(e){if(e.env.CF_DELEGATION||b(e.ownPackageJsonPath))return null;let i;try{i=t(o(e.cwd,`package.json`)).resolve(`cf/package.json`)}catch{return null}if(e.ownPackageJsonPath&&y(i,e.ownPackageJsonPath))return null;let s;try{s=JSON.parse(r(i,`utf-8`))}catch{return null}let c=v(s.bin);if(!c)return null;let l=o(a(i),c);return n(l)?{packageJsonPath:i,binPath:l,version:typeof s.version==`string`?s.version:`unknown`}:null}async function m(e={}){let t=e.cwd??process.cwd(),n=e.argv??process.argv.slice(2),r=e.env??process.env,i=p({cwd:t,ownPackageJsonPath:e.ownPackageJsonPath===void 0?S():e.ownPackageJsonPath,env:r});return i?{delegated:!0,exitCode:await _(i.binPath,n,r)}:{delegated:!1}}async function h(){let e=process.argv.slice(2);return g(e)?{delegated:!1}:m({argv:e})}function g(e){return e.find(e=>!e.startsWith(`-`))===`complete`}function _(t,n,r){return new Promise((i,a)=>{let o=l(process.execPath,[t,...n],{stdio:[`inherit`,`inherit`,`inherit`,`ipc`],env:{...r,[u]:`1`,[d]:e,[f]:String(process.pid)}});o.on(`message`,e=>{process.send&&process.send(e)});let s=e=>()=>{o.kill(e)},p=s(`SIGINT`),m=s(`SIGTERM`);process.on(`SIGINT`,p),process.on(`SIGTERM`,m);let h=()=>{process.off(`SIGINT`,p),process.off(`SIGTERM`,m)};o.once(`exit`,(e,t)=>{h(),i(e===null?t?128+(c.signals[t]??1):0:e)}),o.once(`error`,e=>{h(),a(e)})})}function v(e){if(typeof e==`string`)return e;if(e&&typeof e==`object`){let t=e,n=t.cf;if(typeof n==`string`)return n;for(let e of Object.values(t))if(typeof e==`string`)return e}return null}function y(e,t){try{return i(e)===i(t)}catch{return o(e)===o(t)}}function b(e){return e?e.split(/[\\/]/).some(e=>e===`_npx`||e===`dlx`||e.startsWith(`dlx-`)):!1}function x(){return b(S())}function S(){let e=a(s(import.meta.url));for(;;){let t=o(e,`package.json`);if(n(t))return t;let r=a(e);if(r===e)return null;e=r}}export{h as a,x as i,d as n,m as o,u as r,p as s,f as t};
2
+ import{t as e}from"./package-DK3JX4I3.mjs";import{createRequire as t}from"node:module";import{existsSync as n,readFileSync as r,realpathSync as i}from"node:fs";import{dirname as a,resolve as o}from"node:path";import{fileURLToPath as s}from"node:url";import{constants as c}from"node:os";import{spawn as l}from"node:child_process";const u=`CF_DELEGATION`,d=`CF_DELEGATING_CLI_VERSION`,f=`CF_DELEGATION_PID`;function p(e){if(e.env.CF_DELEGATION||b(e.ownPackageJsonPath))return null;let i;try{i=t(o(e.cwd,`package.json`)).resolve(`cf/package.json`)}catch{return null}if(e.ownPackageJsonPath&&y(i,e.ownPackageJsonPath))return null;let s;try{s=JSON.parse(r(i,`utf-8`))}catch{return null}let c=v(s.bin);if(!c)return null;let l=o(a(i),c);return n(l)?{packageJsonPath:i,binPath:l,version:typeof s.version==`string`?s.version:`unknown`}:null}async function m(e={}){let t=e.cwd??process.cwd(),n=e.argv??process.argv.slice(2),r=e.env??process.env,i=p({cwd:t,ownPackageJsonPath:e.ownPackageJsonPath===void 0?S():e.ownPackageJsonPath,env:r});return i?{delegated:!0,exitCode:await _(i.binPath,n,r)}:{delegated:!1}}async function h(){let e=process.argv.slice(2);return g(e)?{delegated:!1}:m({argv:e})}function g(e){return e.find(e=>!e.startsWith(`-`))===`complete`}function _(t,n,r){return new Promise((i,a)=>{let o=l(process.execPath,[t,...n],{stdio:[`inherit`,`inherit`,`inherit`,`ipc`],env:{...r,[u]:`1`,[d]:e,[f]:String(process.pid)}});o.on(`message`,e=>{process.send&&process.send(e)});let s=e=>()=>{o.kill(e)},p=s(`SIGINT`),m=s(`SIGTERM`);process.on(`SIGINT`,p),process.on(`SIGTERM`,m);let h=()=>{process.off(`SIGINT`,p),process.off(`SIGTERM`,m)};o.once(`exit`,(e,t)=>{h(),i(e===null?t?128+(c.signals[t]??1):0:e)}),o.once(`error`,e=>{h(),a(e)})})}function v(e){if(typeof e==`string`)return e;if(e&&typeof e==`object`){let t=e,n=t.cf;if(typeof n==`string`)return n;for(let e of Object.values(t))if(typeof e==`string`)return e}return null}function y(e,t){try{return i(e)===i(t)}catch{return o(e)===o(t)}}function b(e){return e?e.split(/[\\/]/).some(e=>e===`_npx`||e===`dlx`||e.startsWith(`dlx-`)):!1}function x(){return b(S())}function S(){let e=a(s(import.meta.url));for(;;){let t=o(e,`package.json`);if(n(t))return t;let r=a(e);if(r===e)return null;e=r}}export{h as a,x as i,d as n,m as o,u as r,p as s,f as t};
package/dist/delegate.mjs CHANGED
@@ -1,2 +1,2 @@
1
1
  #!/usr/bin/env node
2
- export{t as DELEGATING_PID_ENV,n as DELEGATING_VERSION_ENV,r as DELEGATION_SENTINEL,i as isEphemeralExecRun,a as maybeDelegateFromProcess,o as maybeDelegateToLocalInstall,s as resolveDelegateTarget}from"./delegate-3IgxBeFH.mjs";
2
+ export{t as DELEGATING_PID_ENV,n as DELEGATING_VERSION_ENV,r as DELEGATION_SENTINEL,i as isEphemeralExecRun,a as maybeDelegateFromProcess,o as maybeDelegateToLocalInstall,s as resolveDelegateTarget}from"./delegate-CTj0dYET.mjs";
@@ -1,2 +1,2 @@
1
1
  #!/usr/bin/env node
2
- import{n as e,t}from"./shared-Z4B68uro.mjs";function n(t){return e(t).option(`provision`,{type:`boolean`,description:`Automatically provision resources for bindings that need them`,default:!0}).option(`dispatch-namespace`,{type:`string`,description:`Name of a dispatch namespace to deploy the Worker to (Workers for Platforms)`,requiresArg:!0}).option(`containers-rollout`,{description:`Rollout strategy for Container changes. Immediate rolls out to all instances in one step; none leaves deployed Containers unchanged.`,choices:[`immediate`,`gradual`,`none`]})}const r={command:`deploy`,describe:`Deploy a worker to Cloudflare`,builder:n,handler:async e=>{await t(e,{command:`Deploy`})}};export{r as default};
2
+ import{n as e,t}from"./shared-CBMFY1VY.mjs";function n(t){return e(t).option(`provision`,{type:`boolean`,description:`Automatically provision resources for bindings that need them`,default:!0}).option(`dispatch-namespace`,{type:`string`,description:`Name of a dispatch namespace to deploy the Worker to (Workers for Platforms)`,requiresArg:!0}).option(`containers-rollout`,{description:`Rollout strategy for Container changes. Immediate rolls out to all instances in one step; none leaves deployed Containers unchanged.`,choices:[`immediate`,`gradual`,`none`]})}const r={command:`deploy`,describe:`Deploy a worker to Cloudflare`,builder:n,handler:async e=>{await t(e,{command:`Deploy`})}};export{r as default};
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{O as e,U as t,X as n,Y as r,_ as i,g as a,rt as o,tt as s,v as c}from"./dist-D5YYi2LO.mjs";import{M as l,N as u,d,g as f,k as p,v as m}from"./chunk-2HLTAS5V-B92NbX1j.mjs";import{t as h}from"./version-CbBZJTiB.mjs";import{t as g}from"./log-BWdaOGOW.mjs";import{n as _,r as v,t as y}from"./dialog-D5lus4M4.mjs";import{S as b,T as x,b as S,c as C,f as ee,g as te,h as ne,i as re,o as ie,p as ae,u as w,w as oe,x as T}from"./interactive-DOWEcR6_.mjs";import{createRequire as se}from"node:module";import{setTimeout as E}from"node:timers/promises";import{existsSync as ce,readFileSync as D}from"node:fs";import O,{join as le}from"node:path";import k from"node:process";import{release as A}from"node:os";import ue from"node:assert";import{createServer as de}from"node:net";import{once as fe}from"node:events";import j,{createHash as pe,randomUUID as me}from"node:crypto";import{execFile as he,execFileSync as ge,spawn as M}from"node:child_process";import{cleanBuildOutputDir as _e,normalizeDirectoryName as ve,writeContainerConfig as N}from"@cloudflare/build-output-utils";function ye(e,t=k.stderr){t.isTTY&&(e?t.write(`\x1B[?25h`):t.write(`\x1B[?25l`))}const P=se(import.meta.url||(typeof __filename==`string`?__filename:`/`));var be=Object.create,xe=Object.defineProperty,Se=Object.getOwnPropertyDescriptor,Ce=Object.getOwnPropertyNames,we=Object.getPrototypeOf,Te=Object.prototype.hasOwnProperty,F=(e,t)=>xe(e,`name`,{value:t,configurable:!0}),I=/* @__PURE__ */ (e=>P===void 0?typeof Proxy<`u`?new Proxy(e,{get:(e,t)=>(P===void 0?e:P)[t]}):e:P)(function(e){if(P!==void 0)return P.apply(this,arguments);throw Error(`Dynamic require of "`+e+`" is not supported`)}),L=(e,t)=>function(){return t||(0,e[Ce(e)[0]])((t={exports:{}}).exports,t),t.exports},Ee=(e,t,n,r)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let i of Ce(t))!Te.call(e,i)&&i!==n&&xe(e,i,{get:()=>t[i],enumerable:!(r=Se(t,i))||r.enumerable});return e},R=(e,t,n)=>(n=e==null?{}:be(we(e)),Ee(xe(n,`default`,{value:e,enumerable:!0}),e)),z=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/constants.js"(e,t){var n=[`nodebuffer`,`arraybuffer`,`fragments`],r=typeof Blob<`u`;r&&n.push(`blob`),t.exports={BINARY_TYPES:n,CLOSE_TIMEOUT:3e4,EMPTY_BUFFER:Buffer.alloc(0),GUID:`258EAFA5-E914-47DA-95CA-C5AB0DC85B11`,hasBlob:r,kForOnEventAttribute:Symbol(`kIsForOnEventAttribute`),kListener:Symbol(`kListener`),kStatusCode:Symbol(`status-code`),kWebSocket:Symbol(`websocket`),NOOP:/* @__PURE__ */ F(()=>{},`NOOP`)}}}),De=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/buffer-util.js"(e,t){var{EMPTY_BUFFER:n}=z(),r=Buffer[Symbol.species];function i(e,t){if(e.length===0)return n;if(e.length===1)return e[0];let i=Buffer.allocUnsafe(t),a=0;for(let t=0;t<e.length;t++){let n=e[t];i.set(n,a),a+=n.length}return a<t?new r(i.buffer,i.byteOffset,a):i}F(i,`concat`);function a(e,t,n,r,i){for(let a=0;a<i;a++)n[r+a]=e[a]^t[a&3]}F(a,`_mask`);function o(e,t){for(let n=0;n<e.length;n++)e[n]^=t[n&3]}F(o,`_unmask`);function s(e){return e.length===e.buffer.byteLength?e.buffer:e.buffer.slice(e.byteOffset,e.byteOffset+e.length)}F(s,`toArrayBuffer`);function c(e){if(c.readOnly=!0,Buffer.isBuffer(e))return e;let t;return e instanceof ArrayBuffer?t=new r(e):ArrayBuffer.isView(e)?t=new r(e.buffer,e.byteOffset,e.byteLength):(t=Buffer.from(e),c.readOnly=!1),t}if(F(c,`toBuffer`),t.exports={concat:i,mask:a,toArrayBuffer:s,toBuffer:c,unmask:o},!process.env.WS_NO_BUFFER_UTIL)try{let e=I(`bufferutil`);t.exports.mask=function(t,n,r,i,o){o<48?a(t,n,r,i,o):e.mask(t,n,r,i,o)},t.exports.unmask=function(t,n){t.length<32?o(t,n):e.unmask(t,n)}}catch{}}}),Oe=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/limiter.js"(e,t){var n=Symbol(`kDone`),r=Symbol(`kRun`);t.exports=class{static{F(this,`Limiter`)}constructor(e){this[n]=()=>{this.pending--,this[r]()},this.concurrency=e||1/0,this.jobs=[],this.pending=0}add(e){this.jobs.push(e),this[r]()}[r](){if(this.pending!==this.concurrency&&this.jobs.length){let e=this.jobs.shift();this.pending++,e(this[n])}}}}}),B=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/permessage-deflate.js"(e,t){var n=I(`zlib`),r=De(),i=Oe(),{kStatusCode:a}=z(),o=Buffer[Symbol.species],s=Buffer.from([0,0,255,255]),c=Symbol(`permessage-deflate`),l=Symbol(`total-length`),u=Symbol(`callback`),d=Symbol(`buffers`),f=Symbol(`error`),p;t.exports=class{static{F(this,`PerMessageDeflate`)}constructor(e){this._options=e||{},this._threshold=this._options.threshold===void 0?1024:this._options.threshold,this._maxPayload=this._options.maxPayload|0,this._isServer=!!this._options.isServer,this._deflate=null,this._inflate=null,this.params=null,p||=new i(this._options.concurrencyLimit===void 0?10:this._options.concurrencyLimit)}static get extensionName(){return`permessage-deflate`}offer(){let e={};return this._options.serverNoContextTakeover&&(e.server_no_context_takeover=!0),this._options.clientNoContextTakeover&&(e.client_no_context_takeover=!0),this._options.serverMaxWindowBits&&(e.server_max_window_bits=this._options.serverMaxWindowBits),this._options.clientMaxWindowBits?e.client_max_window_bits=this._options.clientMaxWindowBits:this._options.clientMaxWindowBits??(e.client_max_window_bits=!0),e}accept(e){return e=this.normalizeParams(e),this.params=this._isServer?this.acceptAsServer(e):this.acceptAsClient(e),this.params}cleanup(){if(this._inflate&&=(this._inflate.close(),null),this._deflate){let e=this._deflate[u];this._deflate.close(),this._deflate=null,e&&e(/* @__PURE__ */ Error(`The deflate stream was closed while data was being processed`))}}acceptAsServer(e){let t=this._options,n=e.find(e=>!(t.serverNoContextTakeover===!1&&e.server_no_context_takeover||e.server_max_window_bits&&(t.serverMaxWindowBits===!1||typeof t.serverMaxWindowBits==`number`&&t.serverMaxWindowBits>e.server_max_window_bits)||typeof t.clientMaxWindowBits==`number`&&!e.client_max_window_bits));if(!n)throw Error(`None of the extension offers can be accepted`);return t.serverNoContextTakeover&&(n.server_no_context_takeover=!0),t.clientNoContextTakeover&&(n.client_no_context_takeover=!0),typeof t.serverMaxWindowBits==`number`&&(n.server_max_window_bits=t.serverMaxWindowBits),typeof t.clientMaxWindowBits==`number`?n.client_max_window_bits=t.clientMaxWindowBits:(n.client_max_window_bits===!0||t.clientMaxWindowBits===!1)&&delete n.client_max_window_bits,n}acceptAsClient(e){let t=e[0];if(this._options.clientNoContextTakeover===!1&&t.client_no_context_takeover)throw Error(`Unexpected parameter "client_no_context_takeover"`);if(!t.client_max_window_bits)typeof this._options.clientMaxWindowBits==`number`&&(t.client_max_window_bits=this._options.clientMaxWindowBits);else if(this._options.clientMaxWindowBits===!1||typeof this._options.clientMaxWindowBits==`number`&&t.client_max_window_bits>this._options.clientMaxWindowBits)throw Error(`Unexpected or invalid parameter "client_max_window_bits"`);return t}normalizeParams(e){return e.forEach(e=>{Object.keys(e).forEach(t=>{let n=e[t];if(n.length>1)throw Error(`Parameter "${t}" must have only a single value`);if(n=n[0],t===`client_max_window_bits`){if(n!==!0){let e=+n;if(!Number.isInteger(e)||e<8||e>15)throw TypeError(`Invalid value for parameter "${t}": ${n}`);n=e}else if(!this._isServer)throw TypeError(`Invalid value for parameter "${t}": ${n}`)}else if(t===`server_max_window_bits`){let e=+n;if(!Number.isInteger(e)||e<8||e>15)throw TypeError(`Invalid value for parameter "${t}": ${n}`);n=e}else if(t===`client_no_context_takeover`||t===`server_no_context_takeover`){if(n!==!0)throw TypeError(`Invalid value for parameter "${t}": ${n}`)}else throw Error(`Unknown parameter "${t}"`);e[t]=n})}),e}decompress(e,t,n){p.add(r=>{this._decompress(e,t,(e,t)=>{r(),n(e,t)})})}compress(e,t,n){p.add(r=>{this._compress(e,t,(e,t)=>{r(),n(e,t)})})}_decompress(e,t,i){let a=this._isServer?`client`:`server`;if(!this._inflate){let e=`${a}_max_window_bits`,t=typeof this.params[e]==`number`?this.params[e]:n.Z_DEFAULT_WINDOWBITS;this._inflate=n.createInflateRaw({...this._options.zlibInflateOptions,windowBits:t}),this._inflate[c]=this,this._inflate[l]=0,this._inflate[d]=[],this._inflate.on(`error`,g),this._inflate.on(`data`,h)}this._inflate[u]=i,this._inflate.write(e),t&&this._inflate.write(s),this._inflate.flush(()=>{let e=this._inflate[f];if(e){this._inflate.close(),this._inflate=null,i(e);return}let n=r.concat(this._inflate[d],this._inflate[l]);this._inflate._readableState.endEmitted?(this._inflate.close(),this._inflate=null):(this._inflate[l]=0,this._inflate[d]=[],t&&this.params[`${a}_no_context_takeover`]&&this._inflate.reset()),i(null,n)})}_compress(e,t,i){let a=this._isServer?`server`:`client`;if(!this._deflate){let e=`${a}_max_window_bits`,t=typeof this.params[e]==`number`?this.params[e]:n.Z_DEFAULT_WINDOWBITS;this._deflate=n.createDeflateRaw({...this._options.zlibDeflateOptions,windowBits:t}),this._deflate[l]=0,this._deflate[d]=[],this._deflate.on(`data`,m)}this._deflate[u]=i,this._deflate.write(e),this._deflate.flush(n.Z_SYNC_FLUSH,()=>{if(!this._deflate)return;let e=r.concat(this._deflate[d],this._deflate[l]);t&&(e=new o(e.buffer,e.byteOffset,e.length-4)),this._deflate[u]=null,this._deflate[l]=0,this._deflate[d]=[],t&&this.params[`${a}_no_context_takeover`]&&this._deflate.reset(),i(null,e)})}};function m(e){this[d].push(e),this[l]+=e.length}F(m,`deflateOnData`);function h(e){this[l]+=e.length,this[c]._maxPayload<1||this[l]<=this[c]._maxPayload?this[d].push(e):(this[f]=/* @__PURE__ */ RangeError(`Max payload size exceeded`),this[f].code=`WS_ERR_UNSUPPORTED_MESSAGE_LENGTH`,this[f][a]=1009,this.removeListener(`data`,h),this.reset())}F(h,`inflateOnData`);function g(e){this[c]._inflate=null,this[f]?this[u](this[f]):(e[a]=1007,this[u](e))}F(g,`inflateOnError`)}}),ke=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/validation.js"(e,t){var{isUtf8:n}=I(`buffer`),{hasBlob:r}=z(),i=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,1,1,1,1,0,0,1,1,0,1,1,0,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,1,0,1,0];function a(e){return e>=1e3&&e<=1014&&e!==1004&&e!==1005&&e!==1006||e>=3e3&&e<=4999}F(a,`isValidStatusCode`);function o(e){let t=e.length,n=0;for(;n<t;)if(!(e[n]&128))n++;else if((e[n]&224)==192){if(n+1===t||(e[n+1]&192)!=128||(e[n]&254)==192)return!1;n+=2}else if((e[n]&240)==224){if(n+2>=t||(e[n+1]&192)!=128||(e[n+2]&192)!=128||e[n]===224&&(e[n+1]&224)==128||e[n]===237&&(e[n+1]&224)==160)return!1;n+=3}else if((e[n]&248)==240){if(n+3>=t||(e[n+1]&192)!=128||(e[n+2]&192)!=128||(e[n+3]&192)!=128||e[n]===240&&(e[n+1]&240)==128||e[n]===244&&e[n+1]>143||e[n]>244)return!1;n+=4}else return!1;return!0}F(o,`_isValidUTF8`);function s(e){return r&&typeof e==`object`&&typeof e.arrayBuffer==`function`&&typeof e.type==`string`&&typeof e.stream==`function`&&(e[Symbol.toStringTag]===`Blob`||e[Symbol.toStringTag]===`File`)}if(F(s,`isBlob`),t.exports={isBlob:s,isValidStatusCode:a,isValidUTF8:o,tokenChars:i},n)t.exports.isValidUTF8=function(e){return e.length<24?o(e):n(e)};else if(!process.env.WS_NO_UTF_8_VALIDATE)try{let e=I(`utf-8-validate`);t.exports.isValidUTF8=function(t){return t.length<32?o(t):e(t)}}catch{}}}),Ae=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/receiver.js"(e,t){var{Writable:n}=I(`stream`),r=B(),{BINARY_TYPES:i,EMPTY_BUFFER:a,kStatusCode:o,kWebSocket:s}=z(),{concat:c,toArrayBuffer:l,unmask:u}=De(),{isValidStatusCode:d,isValidUTF8:f}=ke(),p=Buffer[Symbol.species],m=0,h=1,g=2,_=3,v=4,y=5,b=6;t.exports=class extends n{static{F(this,`Receiver`)}constructor(e={}){super(),this._allowSynchronousEvents=e.allowSynchronousEvents===void 0||e.allowSynchronousEvents,this._binaryType=e.binaryType||i[0],this._extensions=e.extensions||{},this._isServer=!!e.isServer,this._maxBufferedChunks=e.maxBufferedChunks|0,this._maxFragments=e.maxFragments|0,this._maxPayload=e.maxPayload|0,this._skipUTF8Validation=!!e.skipUTF8Validation,this[s]=void 0,this._bufferedBytes=0,this._buffers=[],this._compressed=!1,this._payloadLength=0,this._mask=void 0,this._fragmented=0,this._masked=!1,this._fin=!1,this._opcode=0,this._totalPayloadLength=0,this._messageLength=0,this._fragments=[],this._errored=!1,this._loop=!1,this._state=m}_write(e,t,n){if(this._opcode===8&&this._state==m)return n();this._maxBufferedChunks>0&&this._buffers.length>=this._maxBufferedChunks?n(this.createError(RangeError,`Too many buffered chunks`,!1,1008,`WS_ERR_TOO_MANY_BUFFERED_PARTS`)):(this._bufferedBytes+=e.length,this._buffers.push(e),this.startLoop(n))}consume(e){if(this._bufferedBytes-=e,e===this._buffers[0].length)return this._buffers.shift();if(e<this._buffers[0].length){let t=this._buffers[0];return this._buffers[0]=new p(t.buffer,t.byteOffset+e,t.length-e),new p(t.buffer,t.byteOffset,e)}let t=Buffer.allocUnsafe(e);do{let n=this._buffers[0],r=t.length-e;e>=n.length?t.set(this._buffers.shift(),r):(t.set(new Uint8Array(n.buffer,n.byteOffset,e),r),this._buffers[0]=new p(n.buffer,n.byteOffset+e,n.length-e)),e-=n.length}while(e>0);return t}startLoop(e){this._loop=!0;do switch(this._state){case m:this.getInfo(e);break;case h:this.getPayloadLength16(e);break;case g:this.getPayloadLength64(e);break;case _:this.getMask();break;case v:this.getData(e);break;case y:case b:this._loop=!1;return}while(this._loop);this._errored||e()}getInfo(e){if(this._bufferedBytes<2){this._loop=!1;return}let t=this.consume(2);if(t[0]&48){e(this.createError(RangeError,`RSV2 and RSV3 must be clear`,!0,1002,`WS_ERR_UNEXPECTED_RSV_2_3`));return}let n=(t[0]&64)==64;if(n&&!this._extensions[r.extensionName])e(this.createError(RangeError,`RSV1 must be clear`,!0,1002,`WS_ERR_UNEXPECTED_RSV_1`));else{if(this._fin=(t[0]&128)==128,this._opcode=t[0]&15,this._payloadLength=t[1]&127,this._opcode===0){if(n){e(this.createError(RangeError,`RSV1 must be clear`,!0,1002,`WS_ERR_UNEXPECTED_RSV_1`));return}if(!this._fragmented){e(this.createError(RangeError,`invalid opcode 0`,!0,1002,`WS_ERR_INVALID_OPCODE`));return}this._opcode=this._fragmented}else if(this._opcode===1||this._opcode===2){if(this._fragmented){e(this.createError(RangeError,`invalid opcode ${this._opcode}`,!0,1002,`WS_ERR_INVALID_OPCODE`));return}this._compressed=n}else if(this._opcode>7&&this._opcode<11){if(!this._fin){e(this.createError(RangeError,`FIN must be set`,!0,1002,`WS_ERR_EXPECTED_FIN`));return}if(n){e(this.createError(RangeError,`RSV1 must be clear`,!0,1002,`WS_ERR_UNEXPECTED_RSV_1`));return}if(this._payloadLength>125||this._opcode===8&&this._payloadLength===1){e(this.createError(RangeError,`invalid payload length ${this._payloadLength}`,!0,1002,`WS_ERR_INVALID_CONTROL_PAYLOAD_LENGTH`));return}}else{e(this.createError(RangeError,`invalid opcode ${this._opcode}`,!0,1002,`WS_ERR_INVALID_OPCODE`));return}if(!this._fin&&!this._fragmented&&(this._fragmented=this._opcode),this._masked=(t[1]&128)==128,this._isServer){if(!this._masked){e(this.createError(RangeError,`MASK must be set`,!0,1002,`WS_ERR_EXPECTED_MASK`));return}}else if(this._masked){e(this.createError(RangeError,`MASK must be clear`,!0,1002,`WS_ERR_UNEXPECTED_MASK`));return}this._payloadLength===126?this._state=h:this._payloadLength===127?this._state=g:this.haveLength(e)}}getPayloadLength16(e){this._bufferedBytes<2?this._loop=!1:(this._payloadLength=this.consume(2).readUInt16BE(0),this.haveLength(e))}getPayloadLength64(e){if(this._bufferedBytes<8){this._loop=!1;return}let t=this.consume(8),n=t.readUInt32BE(0);n>2**21-1?e(this.createError(RangeError,`Unsupported WebSocket frame: payload length > 2^53 - 1`,!1,1009,`WS_ERR_UNSUPPORTED_DATA_PAYLOAD_LENGTH`)):(this._payloadLength=n*2**32+t.readUInt32BE(4),this.haveLength(e))}haveLength(e){this._payloadLength&&this._opcode<8&&(this._totalPayloadLength+=this._payloadLength,this._totalPayloadLength>this._maxPayload&&this._maxPayload>0)?e(this.createError(RangeError,`Max payload size exceeded`,!1,1009,`WS_ERR_UNSUPPORTED_MESSAGE_LENGTH`)):this._state=this._masked?_:v}getMask(){this._bufferedBytes<4?this._loop=!1:(this._mask=this.consume(4),this._state=v)}getData(e){let t=a;if(this._payloadLength){if(this._bufferedBytes<this._payloadLength){this._loop=!1;return}t=this.consume(this._payloadLength),this._masked&&(this._mask[0]|this._mask[1]|this._mask[2]|this._mask[3])!==0&&u(t,this._mask)}if(this._opcode>7)this.controlMessage(t,e);else if(this._compressed)this._state=y,this.decompress(t,e);else{if(t.length){if(this._maxFragments>0&&this._fragments.length>=this._maxFragments){e(this.createError(RangeError,`Too many message fragments`,!1,1008,`WS_ERR_TOO_MANY_BUFFERED_PARTS`));return}this._messageLength=this._totalPayloadLength,this._fragments.push(t)}this.dataMessage(e)}}decompress(e,t){this._extensions[r.extensionName].decompress(e,this._fin,(e,n)=>{if(e)return t(e);if(n.length){if(this._messageLength+=n.length,this._messageLength>this._maxPayload&&this._maxPayload>0){t(this.createError(RangeError,`Max payload size exceeded`,!1,1009,`WS_ERR_UNSUPPORTED_MESSAGE_LENGTH`));return}if(this._maxFragments>0&&this._fragments.length>=this._maxFragments){t(this.createError(RangeError,`Too many message fragments`,!1,1008,`WS_ERR_TOO_MANY_BUFFERED_PARTS`));return}this._fragments.push(n)}this.dataMessage(t),this._state===m&&this.startLoop(t)})}dataMessage(e){if(!this._fin){this._state=m;return}let t=this._messageLength,n=this._fragments;if(this._totalPayloadLength=0,this._messageLength=0,this._fragmented=0,this._fragments=[],this._opcode===2){let r;r=this._binaryType===`nodebuffer`?c(n,t):this._binaryType===`arraybuffer`?l(c(n,t)):this._binaryType===`blob`?new Blob(n):n,this._allowSynchronousEvents?(this.emit(`message`,r,!0),this._state=m):(this._state=b,setImmediate(()=>{this.emit(`message`,r,!0),this._state=m,this.startLoop(e)}))}else{let r=c(n,t);if(!this._skipUTF8Validation&&!f(r)){e(this.createError(Error,`invalid UTF-8 sequence`,!0,1007,`WS_ERR_INVALID_UTF8`));return}this._state===y||this._allowSynchronousEvents?(this.emit(`message`,r,!1),this._state=m):(this._state=b,setImmediate(()=>{this.emit(`message`,r,!1),this._state=m,this.startLoop(e)}))}}controlMessage(e,t){if(this._opcode===8){if(e.length===0)this._loop=!1,this.emit(`conclude`,1005,a),this.end();else{let n=e.readUInt16BE(0);if(!d(n)){t(this.createError(RangeError,`invalid status code ${n}`,!0,1002,`WS_ERR_INVALID_CLOSE_CODE`));return}let r=new p(e.buffer,e.byteOffset+2,e.length-2);if(!this._skipUTF8Validation&&!f(r)){t(this.createError(Error,`invalid UTF-8 sequence`,!0,1007,`WS_ERR_INVALID_UTF8`));return}this._loop=!1,this.emit(`conclude`,n,r),this.end()}this._state=m}else this._allowSynchronousEvents?(this.emit(this._opcode===9?`ping`:`pong`,e),this._state=m):(this._state=b,setImmediate(()=>{this.emit(this._opcode===9?`ping`:`pong`,e),this._state=m,this.startLoop(t)}))}createError(e,t,n,r,i){this._loop=!1,this._errored=!0;let a=new e(n?`Invalid WebSocket frame: ${t}`:t);return Error.captureStackTrace(a,this.createError),a.code=i,a[o]=r,a}}}}),je=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/sender.js"(e,t){var{Duplex:n}=I(`stream`),{randomFillSync:r}=I(`crypto`),{types:{isUint8Array:i}}=I(`util`),a=B(),{EMPTY_BUFFER:o,kWebSocket:s,NOOP:c}=z(),{isBlob:l,isValidStatusCode:u}=ke(),{mask:d,toBuffer:f}=De(),p=Symbol(`kByteLength`),m=Buffer.alloc(4),h=8192,g,_=h,v=0,y=1,b=2;t.exports=class e{static{F(this,`Sender`)}constructor(e,t,n){this._extensions=t||{},n&&(this._generateMask=n,this._maskBuffer=Buffer.alloc(4)),this._socket=e,this._firstFragment=!0,this._compress=!1,this._bufferedBytes=0,this._queue=[],this._state=v,this.onerror=c,this[s]=void 0}static frame(e,t){let n,i=!1,a=2,o=!1;t.mask&&(n=t.maskBuffer||m,t.generateMask?t.generateMask(n):(_===h&&(g===void 0&&(g=Buffer.alloc(h)),r(g,0,h),_=0),n[0]=g[_++],n[1]=g[_++],n[2]=g[_++],n[3]=g[_++]),o=(n[0]|n[1]|n[2]|n[3])===0,a=6);let s;typeof e==`string`?(!t.mask||o)&&t[p]!==void 0?s=t[p]:(e=Buffer.from(e),s=e.length):(s=e.length,i=t.mask&&t.readOnly&&!o);let c=s;s>=65536?(a+=8,c=127):s>125&&(a+=2,c=126);let l=Buffer.allocUnsafe(i?s+a:a);return l[0]=t.fin?t.opcode|128:t.opcode,t.rsv1&&(l[0]|=64),l[1]=c,c===126?l.writeUInt16BE(s,2):c===127&&(l[2]=l[3]=0,l.writeUIntBE(s,4,6)),!t.mask||(l[1]|=128,l[a-4]=n[0],l[a-3]=n[1],l[a-2]=n[2],l[a-1]=n[3],o)?[l,e]:i?(d(e,n,l,a,s),[l]):(d(e,n,e,0,s),[l,e])}close(t,n,r,a){let s;if(t===void 0)s=o;else if(typeof t!=`number`||!u(t))throw TypeError(`First argument must be a valid error code number`);else if(n===void 0||!n.length)s=Buffer.allocUnsafe(2),s.writeUInt16BE(t,0);else{let e=Buffer.byteLength(n);if(e>123)throw RangeError(`The message must not be greater than 123 bytes`);if(s=Buffer.allocUnsafe(2+e),s.writeUInt16BE(t,0),typeof n==`string`)s.write(n,2);else if(i(n))s.set(n,2);else throw TypeError(`Second argument must be a string or a Uint8Array`)}let c={[p]:s.length,fin:!0,generateMask:this._generateMask,mask:r,maskBuffer:this._maskBuffer,opcode:8,readOnly:!1,rsv1:!1};this._state===v?this.sendFrame(e.frame(s,c),a):this.enqueue([this.dispatch,s,!1,c,a])}ping(t,n,r){let i,a;if(typeof t==`string`?(i=Buffer.byteLength(t),a=!1):l(t)?(i=t.size,a=!1):(t=f(t),i=t.length,a=f.readOnly),i>125)throw RangeError(`The data size must not be greater than 125 bytes`);let o={[p]:i,fin:!0,generateMask:this._generateMask,mask:n,maskBuffer:this._maskBuffer,opcode:9,readOnly:a,rsv1:!1};l(t)?this._state===v?this.getBlobData(t,!1,o,r):this.enqueue([this.getBlobData,t,!1,o,r]):this._state===v?this.sendFrame(e.frame(t,o),r):this.enqueue([this.dispatch,t,!1,o,r])}pong(t,n,r){let i,a;if(typeof t==`string`?(i=Buffer.byteLength(t),a=!1):l(t)?(i=t.size,a=!1):(t=f(t),i=t.length,a=f.readOnly),i>125)throw RangeError(`The data size must not be greater than 125 bytes`);let o={[p]:i,fin:!0,generateMask:this._generateMask,mask:n,maskBuffer:this._maskBuffer,opcode:10,readOnly:a,rsv1:!1};l(t)?this._state===v?this.getBlobData(t,!1,o,r):this.enqueue([this.getBlobData,t,!1,o,r]):this._state===v?this.sendFrame(e.frame(t,o),r):this.enqueue([this.dispatch,t,!1,o,r])}send(e,t,n){let r=this._extensions[a.extensionName],i=t.binary?2:1,o=t.compress,s,c;typeof e==`string`?(s=Buffer.byteLength(e),c=!1):l(e)?(s=e.size,c=!1):(e=f(e),s=e.length,c=f.readOnly),this._firstFragment?(this._firstFragment=!1,o&&r&&r.params[r._isServer?`server_no_context_takeover`:`client_no_context_takeover`]&&(o=s>=r._threshold),this._compress=o):(o=!1,i=0),t.fin&&(this._firstFragment=!0);let u={[p]:s,fin:t.fin,generateMask:this._generateMask,mask:t.mask,maskBuffer:this._maskBuffer,opcode:i,readOnly:c,rsv1:o};l(e)?this._state===v?this.getBlobData(e,this._compress,u,n):this.enqueue([this.getBlobData,e,this._compress,u,n]):this._state===v?this.dispatch(e,this._compress,u,n):this.enqueue([this.dispatch,e,this._compress,u,n])}getBlobData(t,n,r,i){this._bufferedBytes+=r[p],this._state=b,t.arrayBuffer().then(t=>{if(this._socket.destroyed){let e=/* @__PURE__ */ Error(`The socket was closed while the blob was being read`);process.nextTick(x,this,e,i);return}this._bufferedBytes-=r[p];let a=f(t);n?this.dispatch(a,n,r,i):(this._state=v,this.sendFrame(e.frame(a,r),i),this.dequeue())}).catch(e=>{process.nextTick(S,this,e,i)})}dispatch(t,n,r,i){if(!n){this.sendFrame(e.frame(t,r),i);return}let o=this._extensions[a.extensionName];this._bufferedBytes+=r[p],this._state=y,o.compress(t,r.fin,(t,n)=>{if(this._socket.destroyed){let e=/* @__PURE__ */ Error(`The socket was closed while data was being compressed`);x(this,e,i)}else this._bufferedBytes-=r[p],this._state=v,r.readOnly=!1,this.sendFrame(e.frame(n,r),i),this.dequeue()})}dequeue(){for(;this._state===v&&this._queue.length;){let e=this._queue.shift();this._bufferedBytes-=e[3][p],Reflect.apply(e[0],this,e.slice(1))}}enqueue(e){this._bufferedBytes+=e[3][p],this._queue.push(e)}sendFrame(e,t){e.length===2?(this._socket.cork(),this._socket.write(e[0]),this._socket.write(e[1],t),this._socket.uncork()):this._socket.write(e[0],t)}};function x(e,t,n){typeof n==`function`&&n(t);for(let n=0;n<e._queue.length;n++){let r=e._queue[n],i=r[r.length-1];typeof i==`function`&&i(t)}}F(x,`callCallbacks`);function S(e,t,n){x(e,t,n),e.onerror(t)}F(S,`onError`)}}),Me=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/event-target.js"(e,t){var{kForOnEventAttribute:n,kListener:r}=z(),i=Symbol(`kCode`),a=Symbol(`kData`),o=Symbol(`kError`),s=Symbol(`kMessage`),c=Symbol(`kReason`),l=Symbol(`kTarget`),u=Symbol(`kType`),d=Symbol(`kWasClean`),f=class{static{F(this,`Event`)}constructor(e){this[l]=null,this[u]=e}get target(){return this[l]}get type(){return this[u]}};Object.defineProperty(f.prototype,"target",{enumerable:!0}),Object.defineProperty(f.prototype,"type",{enumerable:!0});var p=class extends f{static{F(this,`CloseEvent`)}constructor(e,t={}){super(e),this[i]=t.code===void 0?0:t.code,this[c]=t.reason===void 0?``:t.reason,this[d]=t.wasClean!==void 0&&t.wasClean}get code(){return this[i]}get reason(){return this[c]}get wasClean(){return this[d]}};Object.defineProperty(p.prototype,"code",{enumerable:!0}),Object.defineProperty(p.prototype,"reason",{enumerable:!0}),Object.defineProperty(p.prototype,"wasClean",{enumerable:!0});var m=class extends f{static{F(this,`ErrorEvent`)}constructor(e,t={}){super(e),this[o]=t.error===void 0?null:t.error,this[s]=t.message===void 0?``:t.message}get error(){return this[o]}get message(){return this[s]}};Object.defineProperty(m.prototype,"error",{enumerable:!0}),Object.defineProperty(m.prototype,"message",{enumerable:!0});var h=class extends f{static{F(this,`MessageEvent`)}constructor(e,t={}){super(e),this[a]=t.data===void 0?null:t.data}get data(){return this[a]}};Object.defineProperty(h.prototype,"data",{enumerable:!0}),t.exports={CloseEvent:p,ErrorEvent:m,Event:f,EventTarget:{addEventListener(e,t,i={}){for(let a of this.listeners(e))if(!i[n]&&a[r]===t&&!a[n])return;let a;if(e===`message`)a=/* @__PURE__ */ F(function(e,n){let r=new h(`message`,{data:n?e:e.toString()});r[l]=this,g(t,this,r)},`onMessage`);else if(e===`close`)a=/* @__PURE__ */ F(function(e,n){let r=new p(`close`,{code:e,reason:n.toString(),wasClean:this._closeFrameReceived&&this._closeFrameSent});r[l]=this,g(t,this,r)},`onClose`);else if(e===`error`)a=/* @__PURE__ */ F(function(e){let n=new m(`error`,{error:e,message:e.message});n[l]=this,g(t,this,n)},`onError`);else if(e===`open`)a=/* @__PURE__ */ F(function(){let e=new f(`open`);e[l]=this,g(t,this,e)},`onOpen`);else return;a[n]=!!i[n],a[r]=t,i.once?this.once(e,a):this.on(e,a)},removeEventListener(e,t){for(let i of this.listeners(e))if(i[r]===t&&!i[n]){this.removeListener(e,i);break}}},MessageEvent:h};function g(e,t,n){typeof e==`object`&&e.handleEvent?e.handleEvent.call(e,n):e.call(t,n)}F(g,`callListener`)}}),Ne=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/extension.js"(e,t){var{tokenChars:n}=ke();function r(e,t,n){e[t]===void 0?e[t]=[n]:e[t].push(n)}F(r,`push`);function i(e){let t=/* @__PURE__ */ Object.create(null),i=/* @__PURE__ */ Object.create(null),a=!1,o=!1,s=!1,c,l,u=-1,d=-1,f=-1,p=0;for(;p<e.length;p++)if(d=e.charCodeAt(p),c===void 0){if(f===-1&&n[d]===1)u===-1&&(u=p);else if(p!==0&&(d===32||d===9))f===-1&&u!==-1&&(f=p);else if(d===59||d===44){if(u===-1)throw SyntaxError(`Unexpected character at index ${p}`);f===-1&&(f=p);let n=e.slice(u,f);d===44?(r(t,n,i),i=/* @__PURE__ */ Object.create(null)):c=n,u=f=-1}else throw SyntaxError(`Unexpected character at index ${p}`)}else if(l===void 0){if(f===-1&&n[d]===1)u===-1&&(u=p);else if(d===32||d===9)f===-1&&u!==-1&&(f=p);else if(d===59||d===44){if(u===-1)throw SyntaxError(`Unexpected character at index ${p}`);f===-1&&(f=p),r(i,e.slice(u,f),!0),d===44&&(r(t,c,i),i=/* @__PURE__ */ Object.create(null),c=void 0),u=f=-1}else if(d===61&&u!==-1&&f===-1)l=e.slice(u,p),u=f=-1;else throw SyntaxError(`Unexpected character at index ${p}`)}else if(o){if(n[d]!==1)throw SyntaxError(`Unexpected character at index ${p}`);u===-1?u=p:a||=!0,o=!1}else if(s){if(n[d]===1)u===-1&&(u=p);else if(d===34&&u!==-1)s=!1,f=p;else if(d===92)o=!0;else throw SyntaxError(`Unexpected character at index ${p}`)}else if(d===34&&e.charCodeAt(p-1)===61)s=!0;else if(f===-1&&n[d]===1)u===-1&&(u=p);else if(u!==-1&&(d===32||d===9))f===-1&&(f=p);else if(d===59||d===44){if(u===-1)throw SyntaxError(`Unexpected character at index ${p}`);f===-1&&(f=p);let n=e.slice(u,f);a&&=(n=n.replace(/\\/g,``),!1),r(i,l,n),d===44&&(r(t,c,i),i=/* @__PURE__ */ Object.create(null),c=void 0),l=void 0,u=f=-1}else throw SyntaxError(`Unexpected character at index ${p}`);if(u===-1||s||d===32||d===9)throw SyntaxError(`Unexpected end of input`);f===-1&&(f=p);let m=e.slice(u,f);return c===void 0?r(t,m,i):(l===void 0?r(i,m,!0):a?r(i,l,m.replace(/\\/g,``)):r(i,l,m),r(t,c,i)),t}F(i,`parse`);function a(e){return Object.keys(e).map(t=>{let n=e[t];return Array.isArray(n)||(n=[n]),n.map(e=>[t].concat(Object.keys(e).map(t=>{let n=e[t];return Array.isArray(n)||(n=[n]),n.map(e=>e===!0?t:`${t}=${e}`).join(`; `)})).join(`; `)).join(`, `)}).join(`, `)}F(a,`format`),t.exports={format:a,parse:i}}}),Pe=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/websocket.js"(e,t){var n=I(`events`),r=I(`https`),i=I(`http`),a=I(`net`),o=I(`tls`),{randomBytes:s,createHash:c}=I(`crypto`),{Duplex:l,Readable:u}=I(`stream`),{URL:d}=I(`url`),f=B(),p=Ae(),m=je(),{isBlob:h}=ke(),{BINARY_TYPES:g,CLOSE_TIMEOUT:_,EMPTY_BUFFER:v,GUID:y,kForOnEventAttribute:b,kListener:x,kStatusCode:S,kWebSocket:C,NOOP:ee}=z(),{EventTarget:{addEventListener:te,removeEventListener:ne}}=Me(),{format:re,parse:ie}=Ne(),{toBuffer:ae}=De(),w=Symbol(`kAborted`),oe=[8,13],T=[`CONNECTING`,`OPEN`,`CLOSING`,`CLOSED`],se=/^[!#$%&'*+\-.0-9A-Z^_`|a-z~]+$/,E=class e extends n{static{F(this,`WebSocket`)}constructor(t,n,r){super(),this._binaryType=g[0],this._closeCode=1006,this._closeFrameReceived=!1,this._closeFrameSent=!1,this._closeMessage=v,this._closeTimer=null,this._errorEmitted=!1,this._extensions={},this._paused=!1,this._protocol=``,this._readyState=e.CONNECTING,this._receiver=null,this._sender=null,this._socket=null,t===null?(this._autoPong=r.autoPong,this._closeTimeout=r.closeTimeout,this._isServer=!0):(this._bufferedAmount=0,this._isServer=!1,this._redirects=0,n===void 0?n=[]:Array.isArray(n)||(typeof n==`object`&&n?(r=n,n=[]):n=[n]),ce(this,t,n,r))}get binaryType(){return this._binaryType}set binaryType(e){g.includes(e)&&(this._binaryType=e,this._receiver&&(this._receiver._binaryType=e))}get bufferedAmount(){return this._socket?this._socket._writableState.length+this._sender._bufferedBytes:this._bufferedAmount}get extensions(){return Object.keys(this._extensions).join()}get isPaused(){return this._paused}
2
+ import{O as e,U as t,X as n,Y as r,_ as i,g as a,rt as o,tt as s,v as c}from"./dist-ataVE8ob.mjs";import{M as l,N as u,d,g as f,k as p,v as m}from"./chunk-2HLTAS5V-B92NbX1j.mjs";import{t as h}from"./version-DIIJ2ixL.mjs";import{t as g}from"./log-BWdaOGOW.mjs";import{n as _,r as v,t as y}from"./dialog-D5lus4M4.mjs";import{S as b,T as x,b as S,c as C,f as ee,g as te,h as ne,i as re,o as ie,p as ae,u as w,w as oe,x as T}from"./interactive-1g0dnrA8.mjs";import{createRequire as se}from"node:module";import{setTimeout as E}from"node:timers/promises";import{existsSync as ce,readFileSync as D}from"node:fs";import O,{join as le}from"node:path";import k from"node:process";import{release as A}from"node:os";import ue from"node:assert";import{createServer as de}from"node:net";import{once as fe}from"node:events";import j,{createHash as pe,randomUUID as me}from"node:crypto";import{execFile as he,execFileSync as ge,spawn as M}from"node:child_process";import{cleanBuildOutputDir as _e,normalizeDirectoryName as ve,writeContainerConfig as N}from"@cloudflare/build-output-utils";function ye(e,t=k.stderr){t.isTTY&&(e?t.write(`\x1B[?25h`):t.write(`\x1B[?25l`))}const P=se(import.meta.url||(typeof __filename==`string`?__filename:`/`));var be=Object.create,xe=Object.defineProperty,Se=Object.getOwnPropertyDescriptor,Ce=Object.getOwnPropertyNames,we=Object.getPrototypeOf,Te=Object.prototype.hasOwnProperty,F=(e,t)=>xe(e,`name`,{value:t,configurable:!0}),I=/* @__PURE__ */ (e=>P===void 0?typeof Proxy<`u`?new Proxy(e,{get:(e,t)=>(P===void 0?e:P)[t]}):e:P)(function(e){if(P!==void 0)return P.apply(this,arguments);throw Error(`Dynamic require of "`+e+`" is not supported`)}),L=(e,t)=>function(){return t||(0,e[Ce(e)[0]])((t={exports:{}}).exports,t),t.exports},Ee=(e,t,n,r)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let i of Ce(t))!Te.call(e,i)&&i!==n&&xe(e,i,{get:()=>t[i],enumerable:!(r=Se(t,i))||r.enumerable});return e},R=(e,t,n)=>(n=e==null?{}:be(we(e)),Ee(xe(n,`default`,{value:e,enumerable:!0}),e)),z=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/constants.js"(e,t){var n=[`nodebuffer`,`arraybuffer`,`fragments`],r=typeof Blob<`u`;r&&n.push(`blob`),t.exports={BINARY_TYPES:n,CLOSE_TIMEOUT:3e4,EMPTY_BUFFER:Buffer.alloc(0),GUID:`258EAFA5-E914-47DA-95CA-C5AB0DC85B11`,hasBlob:r,kForOnEventAttribute:Symbol(`kIsForOnEventAttribute`),kListener:Symbol(`kListener`),kStatusCode:Symbol(`status-code`),kWebSocket:Symbol(`websocket`),NOOP:/* @__PURE__ */ F(()=>{},`NOOP`)}}}),De=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/buffer-util.js"(e,t){var{EMPTY_BUFFER:n}=z(),r=Buffer[Symbol.species];function i(e,t){if(e.length===0)return n;if(e.length===1)return e[0];let i=Buffer.allocUnsafe(t),a=0;for(let t=0;t<e.length;t++){let n=e[t];i.set(n,a),a+=n.length}return a<t?new r(i.buffer,i.byteOffset,a):i}F(i,`concat`);function a(e,t,n,r,i){for(let a=0;a<i;a++)n[r+a]=e[a]^t[a&3]}F(a,`_mask`);function o(e,t){for(let n=0;n<e.length;n++)e[n]^=t[n&3]}F(o,`_unmask`);function s(e){return e.length===e.buffer.byteLength?e.buffer:e.buffer.slice(e.byteOffset,e.byteOffset+e.length)}F(s,`toArrayBuffer`);function c(e){if(c.readOnly=!0,Buffer.isBuffer(e))return e;let t;return e instanceof ArrayBuffer?t=new r(e):ArrayBuffer.isView(e)?t=new r(e.buffer,e.byteOffset,e.byteLength):(t=Buffer.from(e),c.readOnly=!1),t}if(F(c,`toBuffer`),t.exports={concat:i,mask:a,toArrayBuffer:s,toBuffer:c,unmask:o},!process.env.WS_NO_BUFFER_UTIL)try{let e=I(`bufferutil`);t.exports.mask=function(t,n,r,i,o){o<48?a(t,n,r,i,o):e.mask(t,n,r,i,o)},t.exports.unmask=function(t,n){t.length<32?o(t,n):e.unmask(t,n)}}catch{}}}),Oe=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/limiter.js"(e,t){var n=Symbol(`kDone`),r=Symbol(`kRun`);t.exports=class{static{F(this,`Limiter`)}constructor(e){this[n]=()=>{this.pending--,this[r]()},this.concurrency=e||1/0,this.jobs=[],this.pending=0}add(e){this.jobs.push(e),this[r]()}[r](){if(this.pending!==this.concurrency&&this.jobs.length){let e=this.jobs.shift();this.pending++,e(this[n])}}}}}),B=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/permessage-deflate.js"(e,t){var n=I(`zlib`),r=De(),i=Oe(),{kStatusCode:a}=z(),o=Buffer[Symbol.species],s=Buffer.from([0,0,255,255]),c=Symbol(`permessage-deflate`),l=Symbol(`total-length`),u=Symbol(`callback`),d=Symbol(`buffers`),f=Symbol(`error`),p;t.exports=class{static{F(this,`PerMessageDeflate`)}constructor(e){this._options=e||{},this._threshold=this._options.threshold===void 0?1024:this._options.threshold,this._maxPayload=this._options.maxPayload|0,this._isServer=!!this._options.isServer,this._deflate=null,this._inflate=null,this.params=null,p||=new i(this._options.concurrencyLimit===void 0?10:this._options.concurrencyLimit)}static get extensionName(){return`permessage-deflate`}offer(){let e={};return this._options.serverNoContextTakeover&&(e.server_no_context_takeover=!0),this._options.clientNoContextTakeover&&(e.client_no_context_takeover=!0),this._options.serverMaxWindowBits&&(e.server_max_window_bits=this._options.serverMaxWindowBits),this._options.clientMaxWindowBits?e.client_max_window_bits=this._options.clientMaxWindowBits:this._options.clientMaxWindowBits??(e.client_max_window_bits=!0),e}accept(e){return e=this.normalizeParams(e),this.params=this._isServer?this.acceptAsServer(e):this.acceptAsClient(e),this.params}cleanup(){if(this._inflate&&=(this._inflate.close(),null),this._deflate){let e=this._deflate[u];this._deflate.close(),this._deflate=null,e&&e(/* @__PURE__ */ Error(`The deflate stream was closed while data was being processed`))}}acceptAsServer(e){let t=this._options,n=e.find(e=>!(t.serverNoContextTakeover===!1&&e.server_no_context_takeover||e.server_max_window_bits&&(t.serverMaxWindowBits===!1||typeof t.serverMaxWindowBits==`number`&&t.serverMaxWindowBits>e.server_max_window_bits)||typeof t.clientMaxWindowBits==`number`&&!e.client_max_window_bits));if(!n)throw Error(`None of the extension offers can be accepted`);return t.serverNoContextTakeover&&(n.server_no_context_takeover=!0),t.clientNoContextTakeover&&(n.client_no_context_takeover=!0),typeof t.serverMaxWindowBits==`number`&&(n.server_max_window_bits=t.serverMaxWindowBits),typeof t.clientMaxWindowBits==`number`?n.client_max_window_bits=t.clientMaxWindowBits:(n.client_max_window_bits===!0||t.clientMaxWindowBits===!1)&&delete n.client_max_window_bits,n}acceptAsClient(e){let t=e[0];if(this._options.clientNoContextTakeover===!1&&t.client_no_context_takeover)throw Error(`Unexpected parameter "client_no_context_takeover"`);if(!t.client_max_window_bits)typeof this._options.clientMaxWindowBits==`number`&&(t.client_max_window_bits=this._options.clientMaxWindowBits);else if(this._options.clientMaxWindowBits===!1||typeof this._options.clientMaxWindowBits==`number`&&t.client_max_window_bits>this._options.clientMaxWindowBits)throw Error(`Unexpected or invalid parameter "client_max_window_bits"`);return t}normalizeParams(e){return e.forEach(e=>{Object.keys(e).forEach(t=>{let n=e[t];if(n.length>1)throw Error(`Parameter "${t}" must have only a single value`);if(n=n[0],t===`client_max_window_bits`){if(n!==!0){let e=+n;if(!Number.isInteger(e)||e<8||e>15)throw TypeError(`Invalid value for parameter "${t}": ${n}`);n=e}else if(!this._isServer)throw TypeError(`Invalid value for parameter "${t}": ${n}`)}else if(t===`server_max_window_bits`){let e=+n;if(!Number.isInteger(e)||e<8||e>15)throw TypeError(`Invalid value for parameter "${t}": ${n}`);n=e}else if(t===`client_no_context_takeover`||t===`server_no_context_takeover`){if(n!==!0)throw TypeError(`Invalid value for parameter "${t}": ${n}`)}else throw Error(`Unknown parameter "${t}"`);e[t]=n})}),e}decompress(e,t,n){p.add(r=>{this._decompress(e,t,(e,t)=>{r(),n(e,t)})})}compress(e,t,n){p.add(r=>{this._compress(e,t,(e,t)=>{r(),n(e,t)})})}_decompress(e,t,i){let a=this._isServer?`client`:`server`;if(!this._inflate){let e=`${a}_max_window_bits`,t=typeof this.params[e]==`number`?this.params[e]:n.Z_DEFAULT_WINDOWBITS;this._inflate=n.createInflateRaw({...this._options.zlibInflateOptions,windowBits:t}),this._inflate[c]=this,this._inflate[l]=0,this._inflate[d]=[],this._inflate.on(`error`,g),this._inflate.on(`data`,h)}this._inflate[u]=i,this._inflate.write(e),t&&this._inflate.write(s),this._inflate.flush(()=>{let e=this._inflate[f];if(e){this._inflate.close(),this._inflate=null,i(e);return}let n=r.concat(this._inflate[d],this._inflate[l]);this._inflate._readableState.endEmitted?(this._inflate.close(),this._inflate=null):(this._inflate[l]=0,this._inflate[d]=[],t&&this.params[`${a}_no_context_takeover`]&&this._inflate.reset()),i(null,n)})}_compress(e,t,i){let a=this._isServer?`server`:`client`;if(!this._deflate){let e=`${a}_max_window_bits`,t=typeof this.params[e]==`number`?this.params[e]:n.Z_DEFAULT_WINDOWBITS;this._deflate=n.createDeflateRaw({...this._options.zlibDeflateOptions,windowBits:t}),this._deflate[l]=0,this._deflate[d]=[],this._deflate.on(`data`,m)}this._deflate[u]=i,this._deflate.write(e),this._deflate.flush(n.Z_SYNC_FLUSH,()=>{if(!this._deflate)return;let e=r.concat(this._deflate[d],this._deflate[l]);t&&(e=new o(e.buffer,e.byteOffset,e.length-4)),this._deflate[u]=null,this._deflate[l]=0,this._deflate[d]=[],t&&this.params[`${a}_no_context_takeover`]&&this._deflate.reset(),i(null,e)})}};function m(e){this[d].push(e),this[l]+=e.length}F(m,`deflateOnData`);function h(e){this[l]+=e.length,this[c]._maxPayload<1||this[l]<=this[c]._maxPayload?this[d].push(e):(this[f]=/* @__PURE__ */ RangeError(`Max payload size exceeded`),this[f].code=`WS_ERR_UNSUPPORTED_MESSAGE_LENGTH`,this[f][a]=1009,this.removeListener(`data`,h),this.reset())}F(h,`inflateOnData`);function g(e){this[c]._inflate=null,this[f]?this[u](this[f]):(e[a]=1007,this[u](e))}F(g,`inflateOnError`)}}),ke=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/validation.js"(e,t){var{isUtf8:n}=I(`buffer`),{hasBlob:r}=z(),i=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,1,1,1,1,0,0,1,1,0,1,1,0,1,1,1,1,1,1,1,1,1,1,0,0,0,0,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,0,0,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,0,1,0,1,0];function a(e){return e>=1e3&&e<=1014&&e!==1004&&e!==1005&&e!==1006||e>=3e3&&e<=4999}F(a,`isValidStatusCode`);function o(e){let t=e.length,n=0;for(;n<t;)if(!(e[n]&128))n++;else if((e[n]&224)==192){if(n+1===t||(e[n+1]&192)!=128||(e[n]&254)==192)return!1;n+=2}else if((e[n]&240)==224){if(n+2>=t||(e[n+1]&192)!=128||(e[n+2]&192)!=128||e[n]===224&&(e[n+1]&224)==128||e[n]===237&&(e[n+1]&224)==160)return!1;n+=3}else if((e[n]&248)==240){if(n+3>=t||(e[n+1]&192)!=128||(e[n+2]&192)!=128||(e[n+3]&192)!=128||e[n]===240&&(e[n+1]&240)==128||e[n]===244&&e[n+1]>143||e[n]>244)return!1;n+=4}else return!1;return!0}F(o,`_isValidUTF8`);function s(e){return r&&typeof e==`object`&&typeof e.arrayBuffer==`function`&&typeof e.type==`string`&&typeof e.stream==`function`&&(e[Symbol.toStringTag]===`Blob`||e[Symbol.toStringTag]===`File`)}if(F(s,`isBlob`),t.exports={isBlob:s,isValidStatusCode:a,isValidUTF8:o,tokenChars:i},n)t.exports.isValidUTF8=function(e){return e.length<24?o(e):n(e)};else if(!process.env.WS_NO_UTF_8_VALIDATE)try{let e=I(`utf-8-validate`);t.exports.isValidUTF8=function(t){return t.length<32?o(t):e(t)}}catch{}}}),Ae=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/receiver.js"(e,t){var{Writable:n}=I(`stream`),r=B(),{BINARY_TYPES:i,EMPTY_BUFFER:a,kStatusCode:o,kWebSocket:s}=z(),{concat:c,toArrayBuffer:l,unmask:u}=De(),{isValidStatusCode:d,isValidUTF8:f}=ke(),p=Buffer[Symbol.species],m=0,h=1,g=2,_=3,v=4,y=5,b=6;t.exports=class extends n{static{F(this,`Receiver`)}constructor(e={}){super(),this._allowSynchronousEvents=e.allowSynchronousEvents===void 0||e.allowSynchronousEvents,this._binaryType=e.binaryType||i[0],this._extensions=e.extensions||{},this._isServer=!!e.isServer,this._maxBufferedChunks=e.maxBufferedChunks|0,this._maxFragments=e.maxFragments|0,this._maxPayload=e.maxPayload|0,this._skipUTF8Validation=!!e.skipUTF8Validation,this[s]=void 0,this._bufferedBytes=0,this._buffers=[],this._compressed=!1,this._payloadLength=0,this._mask=void 0,this._fragmented=0,this._masked=!1,this._fin=!1,this._opcode=0,this._totalPayloadLength=0,this._messageLength=0,this._fragments=[],this._errored=!1,this._loop=!1,this._state=m}_write(e,t,n){if(this._opcode===8&&this._state==m)return n();this._maxBufferedChunks>0&&this._buffers.length>=this._maxBufferedChunks?n(this.createError(RangeError,`Too many buffered chunks`,!1,1008,`WS_ERR_TOO_MANY_BUFFERED_PARTS`)):(this._bufferedBytes+=e.length,this._buffers.push(e),this.startLoop(n))}consume(e){if(this._bufferedBytes-=e,e===this._buffers[0].length)return this._buffers.shift();if(e<this._buffers[0].length){let t=this._buffers[0];return this._buffers[0]=new p(t.buffer,t.byteOffset+e,t.length-e),new p(t.buffer,t.byteOffset,e)}let t=Buffer.allocUnsafe(e);do{let n=this._buffers[0],r=t.length-e;e>=n.length?t.set(this._buffers.shift(),r):(t.set(new Uint8Array(n.buffer,n.byteOffset,e),r),this._buffers[0]=new p(n.buffer,n.byteOffset+e,n.length-e)),e-=n.length}while(e>0);return t}startLoop(e){this._loop=!0;do switch(this._state){case m:this.getInfo(e);break;case h:this.getPayloadLength16(e);break;case g:this.getPayloadLength64(e);break;case _:this.getMask();break;case v:this.getData(e);break;case y:case b:this._loop=!1;return}while(this._loop);this._errored||e()}getInfo(e){if(this._bufferedBytes<2){this._loop=!1;return}let t=this.consume(2);if(t[0]&48){e(this.createError(RangeError,`RSV2 and RSV3 must be clear`,!0,1002,`WS_ERR_UNEXPECTED_RSV_2_3`));return}let n=(t[0]&64)==64;if(n&&!this._extensions[r.extensionName])e(this.createError(RangeError,`RSV1 must be clear`,!0,1002,`WS_ERR_UNEXPECTED_RSV_1`));else{if(this._fin=(t[0]&128)==128,this._opcode=t[0]&15,this._payloadLength=t[1]&127,this._opcode===0){if(n){e(this.createError(RangeError,`RSV1 must be clear`,!0,1002,`WS_ERR_UNEXPECTED_RSV_1`));return}if(!this._fragmented){e(this.createError(RangeError,`invalid opcode 0`,!0,1002,`WS_ERR_INVALID_OPCODE`));return}this._opcode=this._fragmented}else if(this._opcode===1||this._opcode===2){if(this._fragmented){e(this.createError(RangeError,`invalid opcode ${this._opcode}`,!0,1002,`WS_ERR_INVALID_OPCODE`));return}this._compressed=n}else if(this._opcode>7&&this._opcode<11){if(!this._fin){e(this.createError(RangeError,`FIN must be set`,!0,1002,`WS_ERR_EXPECTED_FIN`));return}if(n){e(this.createError(RangeError,`RSV1 must be clear`,!0,1002,`WS_ERR_UNEXPECTED_RSV_1`));return}if(this._payloadLength>125||this._opcode===8&&this._payloadLength===1){e(this.createError(RangeError,`invalid payload length ${this._payloadLength}`,!0,1002,`WS_ERR_INVALID_CONTROL_PAYLOAD_LENGTH`));return}}else{e(this.createError(RangeError,`invalid opcode ${this._opcode}`,!0,1002,`WS_ERR_INVALID_OPCODE`));return}if(!this._fin&&!this._fragmented&&(this._fragmented=this._opcode),this._masked=(t[1]&128)==128,this._isServer){if(!this._masked){e(this.createError(RangeError,`MASK must be set`,!0,1002,`WS_ERR_EXPECTED_MASK`));return}}else if(this._masked){e(this.createError(RangeError,`MASK must be clear`,!0,1002,`WS_ERR_UNEXPECTED_MASK`));return}this._payloadLength===126?this._state=h:this._payloadLength===127?this._state=g:this.haveLength(e)}}getPayloadLength16(e){this._bufferedBytes<2?this._loop=!1:(this._payloadLength=this.consume(2).readUInt16BE(0),this.haveLength(e))}getPayloadLength64(e){if(this._bufferedBytes<8){this._loop=!1;return}let t=this.consume(8),n=t.readUInt32BE(0);n>2**21-1?e(this.createError(RangeError,`Unsupported WebSocket frame: payload length > 2^53 - 1`,!1,1009,`WS_ERR_UNSUPPORTED_DATA_PAYLOAD_LENGTH`)):(this._payloadLength=n*2**32+t.readUInt32BE(4),this.haveLength(e))}haveLength(e){this._payloadLength&&this._opcode<8&&(this._totalPayloadLength+=this._payloadLength,this._totalPayloadLength>this._maxPayload&&this._maxPayload>0)?e(this.createError(RangeError,`Max payload size exceeded`,!1,1009,`WS_ERR_UNSUPPORTED_MESSAGE_LENGTH`)):this._state=this._masked?_:v}getMask(){this._bufferedBytes<4?this._loop=!1:(this._mask=this.consume(4),this._state=v)}getData(e){let t=a;if(this._payloadLength){if(this._bufferedBytes<this._payloadLength){this._loop=!1;return}t=this.consume(this._payloadLength),this._masked&&(this._mask[0]|this._mask[1]|this._mask[2]|this._mask[3])!==0&&u(t,this._mask)}if(this._opcode>7)this.controlMessage(t,e);else if(this._compressed)this._state=y,this.decompress(t,e);else{if(t.length){if(this._maxFragments>0&&this._fragments.length>=this._maxFragments){e(this.createError(RangeError,`Too many message fragments`,!1,1008,`WS_ERR_TOO_MANY_BUFFERED_PARTS`));return}this._messageLength=this._totalPayloadLength,this._fragments.push(t)}this.dataMessage(e)}}decompress(e,t){this._extensions[r.extensionName].decompress(e,this._fin,(e,n)=>{if(e)return t(e);if(n.length){if(this._messageLength+=n.length,this._messageLength>this._maxPayload&&this._maxPayload>0){t(this.createError(RangeError,`Max payload size exceeded`,!1,1009,`WS_ERR_UNSUPPORTED_MESSAGE_LENGTH`));return}if(this._maxFragments>0&&this._fragments.length>=this._maxFragments){t(this.createError(RangeError,`Too many message fragments`,!1,1008,`WS_ERR_TOO_MANY_BUFFERED_PARTS`));return}this._fragments.push(n)}this.dataMessage(t),this._state===m&&this.startLoop(t)})}dataMessage(e){if(!this._fin){this._state=m;return}let t=this._messageLength,n=this._fragments;if(this._totalPayloadLength=0,this._messageLength=0,this._fragmented=0,this._fragments=[],this._opcode===2){let r;r=this._binaryType===`nodebuffer`?c(n,t):this._binaryType===`arraybuffer`?l(c(n,t)):this._binaryType===`blob`?new Blob(n):n,this._allowSynchronousEvents?(this.emit(`message`,r,!0),this._state=m):(this._state=b,setImmediate(()=>{this.emit(`message`,r,!0),this._state=m,this.startLoop(e)}))}else{let r=c(n,t);if(!this._skipUTF8Validation&&!f(r)){e(this.createError(Error,`invalid UTF-8 sequence`,!0,1007,`WS_ERR_INVALID_UTF8`));return}this._state===y||this._allowSynchronousEvents?(this.emit(`message`,r,!1),this._state=m):(this._state=b,setImmediate(()=>{this.emit(`message`,r,!1),this._state=m,this.startLoop(e)}))}}controlMessage(e,t){if(this._opcode===8){if(e.length===0)this._loop=!1,this.emit(`conclude`,1005,a),this.end();else{let n=e.readUInt16BE(0);if(!d(n)){t(this.createError(RangeError,`invalid status code ${n}`,!0,1002,`WS_ERR_INVALID_CLOSE_CODE`));return}let r=new p(e.buffer,e.byteOffset+2,e.length-2);if(!this._skipUTF8Validation&&!f(r)){t(this.createError(Error,`invalid UTF-8 sequence`,!0,1007,`WS_ERR_INVALID_UTF8`));return}this._loop=!1,this.emit(`conclude`,n,r),this.end()}this._state=m}else this._allowSynchronousEvents?(this.emit(this._opcode===9?`ping`:`pong`,e),this._state=m):(this._state=b,setImmediate(()=>{this.emit(this._opcode===9?`ping`:`pong`,e),this._state=m,this.startLoop(t)}))}createError(e,t,n,r,i){this._loop=!1,this._errored=!0;let a=new e(n?`Invalid WebSocket frame: ${t}`:t);return Error.captureStackTrace(a,this.createError),a.code=i,a[o]=r,a}}}}),je=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/sender.js"(e,t){var{Duplex:n}=I(`stream`),{randomFillSync:r}=I(`crypto`),{types:{isUint8Array:i}}=I(`util`),a=B(),{EMPTY_BUFFER:o,kWebSocket:s,NOOP:c}=z(),{isBlob:l,isValidStatusCode:u}=ke(),{mask:d,toBuffer:f}=De(),p=Symbol(`kByteLength`),m=Buffer.alloc(4),h=8192,g,_=h,v=0,y=1,b=2;t.exports=class e{static{F(this,`Sender`)}constructor(e,t,n){this._extensions=t||{},n&&(this._generateMask=n,this._maskBuffer=Buffer.alloc(4)),this._socket=e,this._firstFragment=!0,this._compress=!1,this._bufferedBytes=0,this._queue=[],this._state=v,this.onerror=c,this[s]=void 0}static frame(e,t){let n,i=!1,a=2,o=!1;t.mask&&(n=t.maskBuffer||m,t.generateMask?t.generateMask(n):(_===h&&(g===void 0&&(g=Buffer.alloc(h)),r(g,0,h),_=0),n[0]=g[_++],n[1]=g[_++],n[2]=g[_++],n[3]=g[_++]),o=(n[0]|n[1]|n[2]|n[3])===0,a=6);let s;typeof e==`string`?(!t.mask||o)&&t[p]!==void 0?s=t[p]:(e=Buffer.from(e),s=e.length):(s=e.length,i=t.mask&&t.readOnly&&!o);let c=s;s>=65536?(a+=8,c=127):s>125&&(a+=2,c=126);let l=Buffer.allocUnsafe(i?s+a:a);return l[0]=t.fin?t.opcode|128:t.opcode,t.rsv1&&(l[0]|=64),l[1]=c,c===126?l.writeUInt16BE(s,2):c===127&&(l[2]=l[3]=0,l.writeUIntBE(s,4,6)),!t.mask||(l[1]|=128,l[a-4]=n[0],l[a-3]=n[1],l[a-2]=n[2],l[a-1]=n[3],o)?[l,e]:i?(d(e,n,l,a,s),[l]):(d(e,n,e,0,s),[l,e])}close(t,n,r,a){let s;if(t===void 0)s=o;else if(typeof t!=`number`||!u(t))throw TypeError(`First argument must be a valid error code number`);else if(n===void 0||!n.length)s=Buffer.allocUnsafe(2),s.writeUInt16BE(t,0);else{let e=Buffer.byteLength(n);if(e>123)throw RangeError(`The message must not be greater than 123 bytes`);if(s=Buffer.allocUnsafe(2+e),s.writeUInt16BE(t,0),typeof n==`string`)s.write(n,2);else if(i(n))s.set(n,2);else throw TypeError(`Second argument must be a string or a Uint8Array`)}let c={[p]:s.length,fin:!0,generateMask:this._generateMask,mask:r,maskBuffer:this._maskBuffer,opcode:8,readOnly:!1,rsv1:!1};this._state===v?this.sendFrame(e.frame(s,c),a):this.enqueue([this.dispatch,s,!1,c,a])}ping(t,n,r){let i,a;if(typeof t==`string`?(i=Buffer.byteLength(t),a=!1):l(t)?(i=t.size,a=!1):(t=f(t),i=t.length,a=f.readOnly),i>125)throw RangeError(`The data size must not be greater than 125 bytes`);let o={[p]:i,fin:!0,generateMask:this._generateMask,mask:n,maskBuffer:this._maskBuffer,opcode:9,readOnly:a,rsv1:!1};l(t)?this._state===v?this.getBlobData(t,!1,o,r):this.enqueue([this.getBlobData,t,!1,o,r]):this._state===v?this.sendFrame(e.frame(t,o),r):this.enqueue([this.dispatch,t,!1,o,r])}pong(t,n,r){let i,a;if(typeof t==`string`?(i=Buffer.byteLength(t),a=!1):l(t)?(i=t.size,a=!1):(t=f(t),i=t.length,a=f.readOnly),i>125)throw RangeError(`The data size must not be greater than 125 bytes`);let o={[p]:i,fin:!0,generateMask:this._generateMask,mask:n,maskBuffer:this._maskBuffer,opcode:10,readOnly:a,rsv1:!1};l(t)?this._state===v?this.getBlobData(t,!1,o,r):this.enqueue([this.getBlobData,t,!1,o,r]):this._state===v?this.sendFrame(e.frame(t,o),r):this.enqueue([this.dispatch,t,!1,o,r])}send(e,t,n){let r=this._extensions[a.extensionName],i=t.binary?2:1,o=t.compress,s,c;typeof e==`string`?(s=Buffer.byteLength(e),c=!1):l(e)?(s=e.size,c=!1):(e=f(e),s=e.length,c=f.readOnly),this._firstFragment?(this._firstFragment=!1,o&&r&&r.params[r._isServer?`server_no_context_takeover`:`client_no_context_takeover`]&&(o=s>=r._threshold),this._compress=o):(o=!1,i=0),t.fin&&(this._firstFragment=!0);let u={[p]:s,fin:t.fin,generateMask:this._generateMask,mask:t.mask,maskBuffer:this._maskBuffer,opcode:i,readOnly:c,rsv1:o};l(e)?this._state===v?this.getBlobData(e,this._compress,u,n):this.enqueue([this.getBlobData,e,this._compress,u,n]):this._state===v?this.dispatch(e,this._compress,u,n):this.enqueue([this.dispatch,e,this._compress,u,n])}getBlobData(t,n,r,i){this._bufferedBytes+=r[p],this._state=b,t.arrayBuffer().then(t=>{if(this._socket.destroyed){let e=/* @__PURE__ */ Error(`The socket was closed while the blob was being read`);process.nextTick(x,this,e,i);return}this._bufferedBytes-=r[p];let a=f(t);n?this.dispatch(a,n,r,i):(this._state=v,this.sendFrame(e.frame(a,r),i),this.dequeue())}).catch(e=>{process.nextTick(S,this,e,i)})}dispatch(t,n,r,i){if(!n){this.sendFrame(e.frame(t,r),i);return}let o=this._extensions[a.extensionName];this._bufferedBytes+=r[p],this._state=y,o.compress(t,r.fin,(t,n)=>{if(this._socket.destroyed){let e=/* @__PURE__ */ Error(`The socket was closed while data was being compressed`);x(this,e,i)}else this._bufferedBytes-=r[p],this._state=v,r.readOnly=!1,this.sendFrame(e.frame(n,r),i),this.dequeue()})}dequeue(){for(;this._state===v&&this._queue.length;){let e=this._queue.shift();this._bufferedBytes-=e[3][p],Reflect.apply(e[0],this,e.slice(1))}}enqueue(e){this._bufferedBytes+=e[3][p],this._queue.push(e)}sendFrame(e,t){e.length===2?(this._socket.cork(),this._socket.write(e[0]),this._socket.write(e[1],t),this._socket.uncork()):this._socket.write(e[0],t)}};function x(e,t,n){typeof n==`function`&&n(t);for(let n=0;n<e._queue.length;n++){let r=e._queue[n],i=r[r.length-1];typeof i==`function`&&i(t)}}F(x,`callCallbacks`);function S(e,t,n){x(e,t,n),e.onerror(t)}F(S,`onError`)}}),Me=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/event-target.js"(e,t){var{kForOnEventAttribute:n,kListener:r}=z(),i=Symbol(`kCode`),a=Symbol(`kData`),o=Symbol(`kError`),s=Symbol(`kMessage`),c=Symbol(`kReason`),l=Symbol(`kTarget`),u=Symbol(`kType`),d=Symbol(`kWasClean`),f=class{static{F(this,`Event`)}constructor(e){this[l]=null,this[u]=e}get target(){return this[l]}get type(){return this[u]}};Object.defineProperty(f.prototype,"target",{enumerable:!0}),Object.defineProperty(f.prototype,"type",{enumerable:!0});var p=class extends f{static{F(this,`CloseEvent`)}constructor(e,t={}){super(e),this[i]=t.code===void 0?0:t.code,this[c]=t.reason===void 0?``:t.reason,this[d]=t.wasClean!==void 0&&t.wasClean}get code(){return this[i]}get reason(){return this[c]}get wasClean(){return this[d]}};Object.defineProperty(p.prototype,"code",{enumerable:!0}),Object.defineProperty(p.prototype,"reason",{enumerable:!0}),Object.defineProperty(p.prototype,"wasClean",{enumerable:!0});var m=class extends f{static{F(this,`ErrorEvent`)}constructor(e,t={}){super(e),this[o]=t.error===void 0?null:t.error,this[s]=t.message===void 0?``:t.message}get error(){return this[o]}get message(){return this[s]}};Object.defineProperty(m.prototype,"error",{enumerable:!0}),Object.defineProperty(m.prototype,"message",{enumerable:!0});var h=class extends f{static{F(this,`MessageEvent`)}constructor(e,t={}){super(e),this[a]=t.data===void 0?null:t.data}get data(){return this[a]}};Object.defineProperty(h.prototype,"data",{enumerable:!0}),t.exports={CloseEvent:p,ErrorEvent:m,Event:f,EventTarget:{addEventListener(e,t,i={}){for(let a of this.listeners(e))if(!i[n]&&a[r]===t&&!a[n])return;let a;if(e===`message`)a=/* @__PURE__ */ F(function(e,n){let r=new h(`message`,{data:n?e:e.toString()});r[l]=this,g(t,this,r)},`onMessage`);else if(e===`close`)a=/* @__PURE__ */ F(function(e,n){let r=new p(`close`,{code:e,reason:n.toString(),wasClean:this._closeFrameReceived&&this._closeFrameSent});r[l]=this,g(t,this,r)},`onClose`);else if(e===`error`)a=/* @__PURE__ */ F(function(e){let n=new m(`error`,{error:e,message:e.message});n[l]=this,g(t,this,n)},`onError`);else if(e===`open`)a=/* @__PURE__ */ F(function(){let e=new f(`open`);e[l]=this,g(t,this,e)},`onOpen`);else return;a[n]=!!i[n],a[r]=t,i.once?this.once(e,a):this.on(e,a)},removeEventListener(e,t){for(let i of this.listeners(e))if(i[r]===t&&!i[n]){this.removeListener(e,i);break}}},MessageEvent:h};function g(e,t,n){typeof e==`object`&&e.handleEvent?e.handleEvent.call(e,n):e.call(t,n)}F(g,`callListener`)}}),Ne=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/extension.js"(e,t){var{tokenChars:n}=ke();function r(e,t,n){e[t]===void 0?e[t]=[n]:e[t].push(n)}F(r,`push`);function i(e){let t=/* @__PURE__ */ Object.create(null),i=/* @__PURE__ */ Object.create(null),a=!1,o=!1,s=!1,c,l,u=-1,d=-1,f=-1,p=0;for(;p<e.length;p++)if(d=e.charCodeAt(p),c===void 0){if(f===-1&&n[d]===1)u===-1&&(u=p);else if(p!==0&&(d===32||d===9))f===-1&&u!==-1&&(f=p);else if(d===59||d===44){if(u===-1)throw SyntaxError(`Unexpected character at index ${p}`);f===-1&&(f=p);let n=e.slice(u,f);d===44?(r(t,n,i),i=/* @__PURE__ */ Object.create(null)):c=n,u=f=-1}else throw SyntaxError(`Unexpected character at index ${p}`)}else if(l===void 0){if(f===-1&&n[d]===1)u===-1&&(u=p);else if(d===32||d===9)f===-1&&u!==-1&&(f=p);else if(d===59||d===44){if(u===-1)throw SyntaxError(`Unexpected character at index ${p}`);f===-1&&(f=p),r(i,e.slice(u,f),!0),d===44&&(r(t,c,i),i=/* @__PURE__ */ Object.create(null),c=void 0),u=f=-1}else if(d===61&&u!==-1&&f===-1)l=e.slice(u,p),u=f=-1;else throw SyntaxError(`Unexpected character at index ${p}`)}else if(o){if(n[d]!==1)throw SyntaxError(`Unexpected character at index ${p}`);u===-1?u=p:a||=!0,o=!1}else if(s){if(n[d]===1)u===-1&&(u=p);else if(d===34&&u!==-1)s=!1,f=p;else if(d===92)o=!0;else throw SyntaxError(`Unexpected character at index ${p}`)}else if(d===34&&e.charCodeAt(p-1)===61)s=!0;else if(f===-1&&n[d]===1)u===-1&&(u=p);else if(u!==-1&&(d===32||d===9))f===-1&&(f=p);else if(d===59||d===44){if(u===-1)throw SyntaxError(`Unexpected character at index ${p}`);f===-1&&(f=p);let n=e.slice(u,f);a&&=(n=n.replace(/\\/g,``),!1),r(i,l,n),d===44&&(r(t,c,i),i=/* @__PURE__ */ Object.create(null),c=void 0),l=void 0,u=f=-1}else throw SyntaxError(`Unexpected character at index ${p}`);if(u===-1||s||d===32||d===9)throw SyntaxError(`Unexpected end of input`);f===-1&&(f=p);let m=e.slice(u,f);return c===void 0?r(t,m,i):(l===void 0?r(i,m,!0):a?r(i,l,m.replace(/\\/g,``)):r(i,l,m),r(t,c,i)),t}F(i,`parse`);function a(e){return Object.keys(e).map(t=>{let n=e[t];return Array.isArray(n)||(n=[n]),n.map(e=>[t].concat(Object.keys(e).map(t=>{let n=e[t];return Array.isArray(n)||(n=[n]),n.map(e=>e===!0?t:`${t}=${e}`).join(`; `)})).join(`; `)).join(`, `)}).join(`, `)}F(a,`format`),t.exports={format:a,parse:i}}}),Pe=L({"../../node_modules/.pnpm/ws@8.21.0/node_modules/ws/lib/websocket.js"(e,t){var n=I(`events`),r=I(`https`),i=I(`http`),a=I(`net`),o=I(`tls`),{randomBytes:s,createHash:c}=I(`crypto`),{Duplex:l,Readable:u}=I(`stream`),{URL:d}=I(`url`),f=B(),p=Ae(),m=je(),{isBlob:h}=ke(),{BINARY_TYPES:g,CLOSE_TIMEOUT:_,EMPTY_BUFFER:v,GUID:y,kForOnEventAttribute:b,kListener:x,kStatusCode:S,kWebSocket:C,NOOP:ee}=z(),{EventTarget:{addEventListener:te,removeEventListener:ne}}=Me(),{format:re,parse:ie}=Ne(),{toBuffer:ae}=De(),w=Symbol(`kAborted`),oe=[8,13],T=[`CONNECTING`,`OPEN`,`CLOSING`,`CLOSED`],se=/^[!#$%&'*+\-.0-9A-Z^_`|a-z~]+$/,E=class e extends n{static{F(this,`WebSocket`)}constructor(t,n,r){super(),this._binaryType=g[0],this._closeCode=1006,this._closeFrameReceived=!1,this._closeFrameSent=!1,this._closeMessage=v,this._closeTimer=null,this._errorEmitted=!1,this._extensions={},this._paused=!1,this._protocol=``,this._readyState=e.CONNECTING,this._receiver=null,this._sender=null,this._socket=null,t===null?(this._autoPong=r.autoPong,this._closeTimeout=r.closeTimeout,this._isServer=!0):(this._bufferedAmount=0,this._isServer=!1,this._redirects=0,n===void 0?n=[]:Array.isArray(n)||(typeof n==`object`&&n?(r=n,n=[]):n=[n]),ce(this,t,n,r))}get binaryType(){return this._binaryType}set binaryType(e){g.includes(e)&&(this._binaryType=e,this._receiver&&(this._receiver._binaryType=e))}get bufferedAmount(){return this._socket?this._socket._writableState.length+this._sender._bufferedBytes:this._bufferedAmount}get extensions(){return Object.keys(this._extensions).join()}get isPaused(){return this._paused}
3
3
  /* istanbul ignore next */
4
4
  get onclose(){return null}
5
5
  /* istanbul ignore next */
@@ -1,2 +1,2 @@
1
1
  #!/usr/bin/env node
2
- import{c as e}from"./build-Yf5bvUk2.mjs";import{existsSync as t,readFileSync as n,statSync as r}from"node:fs";import{dirname as i,join as a,sep as o}from"node:path";const s={esm:`esm`,cjs:`commonjs`,python:`python`,"python-requirement":`python-requirement`,wasm:`compiled-wasm`,text:`text`,data:`buffer`,json:`text`};function c(e,t,n,r,a){let o=process.cwd(),s=t.main??``;return{entry:{file:s,projectRoot:o,configPath:e.configPath,format:`modules`,moduleRoot:s?i(s):e.bundleDir??``,exports:[]},name:e.config.name,compatibilityDate:t.compatibility_date,compatibilityFlags:t.compatibility_flags??[],assetsDir:p(e,t),main:t.main??void 0,keepVars:t.keep_vars??!1,dryRun:r[`dry-run`],env:void 0,outfile:void 0,tag:r.tag,message:r.message,secretsFile:r[`secrets-file`],experimentalAutoCreate:!0,accountId:n,sendMetrics:!1,resourcesProvision:!0,skipProvisioningConfigWriteback:!0,skipLastDeployedFromApiCheck:!1,containers:a,cliVars:{},isWorkersSite:!1,useServiceEnvApiPath:!1}}function l(e,t,n,r,i){return{...c(e,t,n,r,i),command:`deploy`,resourcesProvision:r.provision??!0,containersRollout:r[`containers-rollout`],triggers:t.triggers?.crons,routes:f(t),logpush:t.logpush,dispatchNamespace:r[`dispatch-namespace`],strict:!0,legacyAssetPaths:void 0,oldAssetTtl:void 0}}function u(e,t,n,r,i){return{...c(e,t,n,r,i),command:`versions upload`,strict:!0,previewAlias:r[`preview-alias`]}}function d(e,t,n,r){return{config:t,accountId:n,scriptName:t.name??e.config.name,crons:t.triggers?.crons,routes:f(t),firstDeploy:!1,dryRun:r[`dry-run`],validated:!1}}function f(e){return e.routes?e.routes:e.route?[e.route]:[]}function p(t,n){let r=t.assetsDir;if(!r)return;let i=!!n.main,a=n.assets?.run_worker_first;if(!i&&a)throw new e(`assets.run_worker_first requires a Worker entrypoint, but no main module is configured.`);return{directory:r,binding:n.assets?.binding,directoryExists:!0}}function m(i,o){if(!o.manifest||!i.bundleDir)return{modules:[],sourceMaps:void 0,dependencies:{},resolvedEntryPointPath:``,bundleType:`esm`,content:``};let{mainModule:c,modules:l}=o.manifest;h(c,i.bundleDir);let u=a(i.bundleDir,c);if(!t(u))throw new e(`Main module not found: ${u}`);let d=l?.[c]?.type??`esm`;if(d===`sourcemap`)throw new e(`Main module "${c}" cannot be a sourcemap.`);let f=n(u,`utf8`),p=s[d],m=[],g=[],_={};if(_[u]={bytesInOutput:r(u).size},l)for(let[o,u]of Object.entries(l)){if(o===c)continue;h(o,i.bundleDir);let l=a(i.bundleDir,o);if(u.type===`sourcemap`){if(!t(l))throw new e(`Module not found: ${l}`);g.push({name:o,content:n(l,`utf8`)});continue}if(!t(l))throw new e(`Module not found: ${l}`);let d=u.type===`wasm`||u.type===`data`?n(l):n(l,`utf8`);m.push({name:o,filePath:l,content:d,type:s[u.type]}),_[l]={bytesInOutput:r(l).size}}return{modules:m,sourceMaps:g.length>0?g:void 0,dependencies:_,resolvedEntryPointPath:u,bundleType:p,content:f}}function h(t,n){let r=a(n,t);if(r!==n&&!r.startsWith(n+o))throw new e(`Module path "${t}" escapes the bundle directory.`)}export{u as i,l as n,d as r,m as t};
2
+ import{c as e}from"./build-BfkzV5_c.mjs";import{existsSync as t,readFileSync as n,statSync as r}from"node:fs";import{dirname as i,join as a,sep as o}from"node:path";const s={esm:`esm`,cjs:`commonjs`,python:`python`,"python-requirement":`python-requirement`,wasm:`compiled-wasm`,text:`text`,data:`buffer`,json:`text`};function c(e,t,n,r,a){let o=process.cwd(),s=t.main??``;return{entry:{file:s,projectRoot:o,configPath:e.configPath,format:`modules`,moduleRoot:s?i(s):e.bundleDir??``,exports:[]},name:e.config.name,compatibilityDate:t.compatibility_date,compatibilityFlags:t.compatibility_flags??[],assetsDir:p(e,t),main:t.main??void 0,keepVars:t.keep_vars??!1,dryRun:r[`dry-run`],env:void 0,outfile:void 0,tag:r.tag,message:r.message,secretsFile:r[`secrets-file`],experimentalAutoCreate:!0,accountId:n,sendMetrics:!1,resourcesProvision:!0,skipProvisioningConfigWriteback:!0,skipLastDeployedFromApiCheck:!1,containers:a,cliVars:{},isWorkersSite:!1,useServiceEnvApiPath:!1}}function l(e,t,n,r,i){return{...c(e,t,n,r,i),command:`deploy`,resourcesProvision:r.provision??!0,containersRollout:r[`containers-rollout`],triggers:t.triggers?.crons,routes:f(t),logpush:t.logpush,dispatchNamespace:r[`dispatch-namespace`],strict:!0,legacyAssetPaths:void 0,oldAssetTtl:void 0}}function u(e,t,n,r,i){return{...c(e,t,n,r,i),command:`versions upload`,strict:!0,previewAlias:r[`preview-alias`]}}function d(e,t,n,r){return{config:t,accountId:n,scriptName:t.name??e.config.name,crons:t.triggers?.crons,routes:f(t),firstDeploy:!1,dryRun:r[`dry-run`],validated:!1}}function f(e){return e.routes?e.routes:e.route?[e.route]:[]}function p(t,n){let r=t.assetsDir;if(!r)return;let i=!!n.main,a=n.assets?.run_worker_first;if(!i&&a)throw new e(`assets.run_worker_first requires a Worker entrypoint, but no main module is configured.`);return{directory:r,binding:n.assets?.binding,directoryExists:!0}}function m(i,o){if(!o.manifest||!i.bundleDir)return{modules:[],sourceMaps:void 0,dependencies:{},resolvedEntryPointPath:``,bundleType:`esm`,content:``};let{mainModule:c,modules:l}=o.manifest;h(c,i.bundleDir);let u=a(i.bundleDir,c);if(!t(u))throw new e(`Main module not found: ${u}`);let d=l?.[c]?.type??`esm`;if(d===`sourcemap`)throw new e(`Main module "${c}" cannot be a sourcemap.`);let f=n(u,`utf8`),p=s[d],m=[],g=[],_={};if(_[u]={bytesInOutput:r(u).size},l)for(let[o,u]of Object.entries(l)){if(o===c)continue;h(o,i.bundleDir);let l=a(i.bundleDir,o);if(u.type===`sourcemap`){if(!t(l))throw new e(`Module not found: ${l}`);g.push({name:o,content:n(l,`utf8`)});continue}if(!t(l))throw new e(`Module not found: ${l}`);let d=u.type===`wasm`||u.type===`data`?n(l):n(l,`utf8`);m.push({name:o,filePath:l,content:d,type:s[u.type]}),_[l]={bytesInOutput:r(l).size}}return{modules:m,sourceMaps:g.length>0?g:void 0,dependencies:_,resolvedEntryPointPath:u,bundleType:p,content:f}}function h(t,n){let r=a(n,t);if(r!==n&&!r.startsWith(n+o))throw new e(`Module path "${t}" escapes the bundle directory.`)}export{u as i,l as n,d as r,m as t};
@@ -0,0 +1,4 @@
1
+ #!/usr/bin/env node
2
+ import{r as e}from"./theme-BGHWSKCw.mjs";import{t}from"./cli-exit-CstFZ1eJ.mjs";import{i as n,r}from"./autoconfig-CajkMb3B.mjs";import"./ui-7zujR-O7.mjs";import{n as i,t as a}from"./spawn-9sE67p7c.mjs";const o={command:`dev [implArgs..]`,describe:`Run the project's Cloudflare dev server`,builder:t=>t.positional(`implArgs`,{type:`string`,array:!0,describe:`Arguments forwarded to the dev-server implementation`}).parserConfiguration({"unknown-options-as-args":!0,"camel-case-expansion":!1}).epilogue(`cf dev starts the appropriate development server for your project. It runs your framework's dev command when available, falling back to an installed Cloudflare dev server.
3
+
4
+ Only ${e.brand(`--mode`)} is forwarded to supported framework development servers. Other arguments are forwarded only to Cloudflare dev-server implementations.`),handler:async e=>{let o=process.cwd(),{details:s}=await r(o),c=(e.implArgs??[]).map(String),l=e.mode?[`--mode`,e.mode]:[];if(s?.devCommand){if(c.length>0)throw Error(`Arguments cannot currently be forwarded to the detected dev command \`${s.devCommand}\`. Run that command directly with the required arguments.`);if(e.mode&&!s.framework?.supportsMode)throw Error(`The detected command \`${s.devCommand}\` does not currently support \`--mode\`.`);let r=await n(s.devCommand,o,{env:s.env,args:l,output:`inherit`});throw new t(r.exitCode,{signal:r.signal})}let u=i(o),d=await a(u,`dev`,[...l,...c],{output:`inherit`});throw new t(d.exitCode,{signal:d.signal})}};export{o as default};
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-X3wKppsT.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-Y4rIAAtA.mjs";import{n}from"./auth-DkPhAgZv.mjs";import{a as r,t as i}from"./context-DoGlohS-.mjs";import{t as a}from"./output-BJEgbI0G.mjs";import{t as o}from"./dry-run-gy0Hl9xo.mjs";import{t as s}from"./progress-D2_AF54c.mjs";import{t as c}from"./run-C2-1SFrS.mjs";import"./telemetry-Q7QghPwV.mjs";import{n as l,t as u}from"./body-parser-BKcZS9iJ.mjs";import{n as d}from"./input-validation-D7z60HJH.mjs";import{a as f,i as p,n as m}from"./prompt-BBR19lgj.mjs";var h={method:`POST`,path:t=>e`/accounts/${t.account_id}/diagnostics/endpoint-healthchecks`,body:`json`,constants:{check_type:`icmp`}};function g(e){return e.usage(`$0 diagnostics endpoint-healthchecks create
2
+ import"./api-X3wKppsT.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-BNmz58v4.mjs";import{n}from"./auth-CB9wjyad.mjs";import{a as r,t as i}from"./context-DCon1tRZ.mjs";import{t as a}from"./output-BJEgbI0G.mjs";import{t as o}from"./dry-run-gy0Hl9xo.mjs";import{t as s}from"./progress-_Jux05O5.mjs";import{t as c}from"./run-Br8sYjNF.mjs";import"./telemetry-kjElc1zT.mjs";import{n as l,t as u}from"./body-parser-BKcZS9iJ.mjs";import{n as d}from"./input-validation-D7z60HJH.mjs";import{a as f,i as p,n as m}from"./prompt-SNVLBS1b.mjs";var h={method:`POST`,path:t=>e`/accounts/${t.account_id}/diagnostics/endpoint-healthchecks`,body:`json`,constants:{check_type:`icmp`}};function g(e){return e.usage(`$0 diagnostics endpoint-healthchecks create
3
3
 
4
4
  Create Endpoint Health Check.`).option(`check-type`,{type:`string`,description:`type of check to perform`,choices:[`icmp`],default:`icmp`}).coerce(`check-type`,e=>d(e,`check-type`,`text`)).option(`endpoint`,{type:`string`,description:`the IP address of the host to perform checks against`}).option(`name`,{type:`string`,description:`Optional name associated with this check`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const _={command:`create`,describe:`Endpoint Health Check`,builder:g,handler:async e=>c({command:`diagnostics endpoint-healthchecks create`,classification:{safeFlags:[`check-type`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=await r();o({command:`cf diagnostics endpoint-healthchecks create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/diagnostics/endpoint-healthchecks`,pathParams:{},bodyKind:`json`,body:e.body===void 0?u({check_type:e[`check-type`],endpoint:d(e.endpoint,`endpoint`,`text`),name:d(e.name,`name`,`text`)}):l(e.body)});return}let c=await n(e),m=e.local?t:await i();if(e.accountId=m,e.body){let t=l(e.body),n=await s(`Creating`,async()=>c.send(h,{body:t,account_id:m}));a(n,{successLabel:`Created`});return}e[`check-type`]===void 0&&(e[`check-type`]=await p(`check-type`,`type of check to perform`,[`icmp`])),e.endpoint===void 0&&(e.endpoint=await f(`endpoint`,`the IP address of the host to perform checks against`));let g=u({check_type:e[`check-type`],endpoint:d(e.endpoint,`endpoint`,`text`),name:d(e.name,`name`,`text`)}),_=await s(`Creating`,async()=>c.send(h,{body:g,account_id:m}));a(_,{successLabel:`Created`})})};var v={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/diagnostics/endpoint-healthchecks/${t.id}`};function y(e){return e.usage(`$0 diagnostics endpoint-healthchecks delete <id>
5
5