cf 1.0.0-beta.3 → 1.0.0-beta.4

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 (235) hide show
  1. package/dist/_meta/commands.json +118 -0
  2. package/dist/_meta/schemas.json +77 -0
  3. package/dist/{abuse-reports-CWX7WKhe.mjs → abuse-reports-L4L7sC0F.mjs} +1 -1
  4. package/dist/{access-2aKv_Dya.mjs → access-DUQisFsH.mjs} +1 -1
  5. package/dist/{account-CnZO9-bl.mjs → account-J7N4Ukse.mjs} +1 -1
  6. package/dist/{account-tags-ClLZOfTA.mjs → account-tags-DMmTopgx.mjs} +1 -1
  7. package/dist/{accounts-Cbj9aFyY.mjs → accounts-DbZdpH5e.mjs} +1 -1
  8. package/dist/{acm-wGJ9cnzE.mjs → acm-BtXPdUqH.mjs} +1 -1
  9. package/dist/{addressing-YvHX2dAb.mjs → addressing-Bc_ZSmrK.mjs} +1 -1
  10. package/dist/{agent-memory-B4N-lmLb.mjs → agent-memory-CEUI1wKI.mjs} +1 -1
  11. package/dist/{ai-lziiVEGR.mjs → ai-CFHaVQcc.mjs} +1 -1
  12. package/dist/{ai-audit-CG_DG6N7.mjs → ai-audit-guygqmOl.mjs} +1 -1
  13. package/dist/{ai-gateway-DUttjxrN.mjs → ai-gateway-BcKOL4WQ.mjs} +1 -1
  14. package/dist/{ai-search-k63uopiK.mjs → ai-search-DJvNkX2o.mjs} +1 -1
  15. package/dist/{ai-security-D10lzYTn.mjs → ai-security-CVaHbGzn.mjs} +1 -1
  16. package/dist/{alerting-c4ICS8KO.mjs → alerting-wy4IuGs7.mjs} +1 -1
  17. package/dist/{analytics-CEQ0EVTq.mjs → analytics-Do4VMrPX.mjs} +2 -2
  18. package/dist/{analytics_engine-B9kiAPbY.mjs → analytics_engine-Cv7IF8ex.mjs} +1 -1
  19. package/dist/{api-security-6LlxeiOi.mjs → api-security-fuzV322d.mjs} +1 -1
  20. package/dist/{argo-BCcp1ybr.mjs → argo-BBf-Jw0O.mjs} +1 -1
  21. package/dist/{artifacts-PoO3rAvo.mjs → artifacts-B7_OhBxW.mjs} +1 -1
  22. package/dist/{audit-logs-Vt3NbAA1.mjs → audit-logs-DyARgcxN.mjs} +1 -1
  23. package/dist/{auth-3bFlHTVl.mjs → auth-BYFcxn1F.mjs} +2 -2
  24. package/dist/{auth-BfYtTyXo.mjs → auth-CiOv7s9F.mjs} +1 -1
  25. package/dist/{autoconfig-DqgOi1kW.mjs → autoconfig-DbL_FL5k.mjs} +77 -77
  26. package/dist/{billing-DVrpin2a.mjs → billing-07_VIO4X.mjs} +1 -1
  27. package/dist/{bot-management-Bw-GZWoT.mjs → bot-management-CmkPUu2I.mjs} +1 -1
  28. package/dist/{botnet-feed-ov970cZf.mjs → botnet-feed-Bn5pE_rx.mjs} +1 -1
  29. package/dist/{brand-protection-C7WOvdx6.mjs → brand-protection-CWDqPOXe.mjs} +1 -1
  30. package/dist/{browser-run-DhnKUXVv.mjs → browser-run-CfEIfpnQ.mjs} +1 -1
  31. package/dist/build-BmLpTw4w.mjs +2 -0
  32. package/dist/build-DEbkHHVh.mjs +2 -0
  33. package/dist/{builds-BIqfNXEE.mjs → builds-mgouQLUs.mjs} +1 -1
  34. package/dist/{cache-Dzl3kth1.mjs → cache-DXLofz5T.mjs} +1 -1
  35. package/dist/{certificate-authorities-CQinLiq_.mjs → certificate-authorities-BfW-rEpf.mjs} +1 -1
  36. package/dist/{cli-ZXrxm369.mjs → cli-Dgk9bd8j.mjs} +1 -1
  37. package/dist/{client-certificates--vw-4vvy.mjs → client-certificates-By2A46a2.mjs} +1 -1
  38. package/dist/{client-side-security-YCsdeK3e.mjs → client-side-security-Bo6ZwJOS.mjs} +1 -1
  39. package/dist/{cloud-connector-CwSi4zZI.mjs → cloud-connector-DYb_3u-M.mjs} +1 -1
  40. package/dist/{cloudforce-one-hEykJeqy.mjs → cloudforce-one-D8l0I5PL.mjs} +1 -1
  41. package/dist/{command-Axp5Wfpj.mjs → command-BPfW-yE4.mjs} +1 -1
  42. package/dist/{command-CIZDQPmS.mjs → command-BgBsFEYv.mjs} +1 -1
  43. package/dist/{command-CeL8kQCM.mjs → command-C3Qhz4kU.mjs} +1 -1
  44. package/dist/{command-ChDtawgh.mjs → command-C7cOrHdI.mjs} +1 -1
  45. package/dist/{command-L0y09SE5.mjs → command-CGD1oByJ.mjs} +1 -1
  46. package/dist/{command-DBCoI1fN.mjs → command-CJR1CUK_.mjs} +1 -1
  47. package/dist/{command-C1CwuI4O.mjs → command-C_lQtSPg.mjs} +1 -1
  48. package/dist/{command-D5nZoVE1.mjs → command-DH67hNLj.mjs} +1 -1
  49. package/dist/{command-DrQKTf1O.mjs → command-DJJN9xaA.mjs} +1 -1
  50. package/dist/{command-BH-TMJWp.mjs → command-DRlUj6lW.mjs} +1 -1
  51. package/dist/{command-jJKEah9i.mjs → command-DYeBZ5mA.mjs} +1 -1
  52. package/dist/command-DaAGN9uP.mjs +2 -0
  53. package/dist/{command-IuYNIUk9.mjs → command-DjNcY4cf.mjs} +1 -1
  54. package/dist/{command-egPOyKbx.mjs → command-gSmdvn_d.mjs} +1 -1
  55. package/dist/{completions-DNisLHie.mjs → completions-DUDx3DwX.mjs} +1 -1
  56. package/dist/{connector-interrupts-uIHLde10.mjs → connector-interrupts-DIMvaZhN.mjs} +1 -1
  57. package/dist/{connector-telemetry-events-D2MH0OSs.mjs → connector-telemetry-events-TWQvm-cj.mjs} +1 -1
  58. package/dist/{connector-telemetry-snapshots-CQICQaGf.mjs → connector-telemetry-snapshots-Dyoe-_R3.mjs} +1 -1
  59. package/dist/{connectors-BXwvP7SF.mjs → connectors-D7ZFg3hB.mjs} +1 -1
  60. package/dist/{containers-DOyOrVV9.mjs → containers-Bu3tLjU1.mjs} +1 -1
  61. package/dist/{containers-ClK7HGfx.mjs → containers-CduXjFBJ.mjs} +1 -1
  62. package/dist/{content-scan-B71JZ7G6.mjs → content-scan-CVBD6mUI.mjs} +1 -1
  63. package/dist/{context-5JRcefHh.mjs → context-BsGrhAqB.mjs} +1 -1
  64. package/dist/{cps-CzNfFv-5.mjs → cps-CgiRKmTe.mjs} +1 -1
  65. package/dist/{csamScanner-BfZcrcjk.mjs → csamScanner-BlXIOFFe.mjs} +1 -1
  66. package/dist/{ct-alerting-Cm8YLmXE.mjs → ct-alerting-CJZK0uSQ.mjs} +1 -1
  67. package/dist/{custom-certificates-DFMRe9_D.mjs → custom-certificates-DFaj_czg.mjs} +1 -1
  68. package/dist/{custom-csrs-B5njuvdd.mjs → custom-csrs-BnFQpjOo.mjs} +1 -1
  69. package/dist/{custom-hostnames-D06jQfNs.mjs → custom-hostnames-DSnE6xOT.mjs} +1 -1
  70. package/dist/{custom-nameservers-CKwKLqbF.mjs → custom-nameservers-CdQOt_qU.mjs} +1 -1
  71. package/dist/{custom-pages-D339_r6I.mjs → custom-pages-TWGlS6Ms.mjs} +1 -1
  72. package/dist/{d1-CHXmF-Ga.mjs → d1-Cbqx2kAz.mjs} +1 -1
  73. package/dist/{dcv-delegation-BAnTwW8J.mjs → dcv-delegation-DM3oGGio.mjs} +1 -1
  74. package/dist/{deploy-CsQbufsL.mjs → deploy-BZUWZ888.mjs} +1 -1
  75. package/dist/{deploy-input-dwBe8pSi.mjs → deploy-input-ChEbf2Kp.mjs} +1 -1
  76. package/dist/dev-OsbQIdD8.mjs +4 -0
  77. package/dist/{diagnostics-BEUAWeLH.mjs → diagnostics-8bbleTmW.mjs} +1 -1
  78. package/dist/discover-DgHRf-qo.mjs +2 -0
  79. package/dist/{dist-CpufWpsP.mjs → dist-DTN-pqSs.mjs} +1 -1
  80. package/dist/{dls-CXS7bPlj.mjs → dls-TzQpry2j.mjs} +1 -1
  81. package/dist/{dns-Dx7oPdtH.mjs → dns-Bzv4YLeg.mjs} +1 -1
  82. package/dist/{dns-firewall-wcP1fgB-.mjs → dns-firewall-BjWwOmDR.mjs} +1 -1
  83. package/dist/{durable-objects-DmieQflu.mjs → durable-objects-CRhSGkpc.mjs} +1 -1
  84. package/dist/{email-auth-DiO-k5wt.mjs → email-auth-Bth4_FHy.mjs} +1 -1
  85. package/dist/{email-routing-CycPV4UR.mjs → email-routing-CkTh4F5j.mjs} +1 -1
  86. package/dist/{email-security-DhtBU1X_.mjs → email-security-C-2jADxE.mjs} +1 -1
  87. package/dist/{email-sending-BjgiwUht.mjs → email-sending-B_sd4ouE.mjs} +1 -1
  88. package/dist/{fieldExtractors-BOBRZ8gw.mjs → fieldExtractors-z92V55-Y.mjs} +1 -1
  89. package/dist/{firewall-Dc0Xm26N.mjs → firewall-0yKpxdjj.mjs} +1 -1
  90. package/dist/{flagship-BRqR3ioN.mjs → flagship-IRVq23te.mjs} +1 -1
  91. package/dist/{fraud-Czu1ed5n.mjs → fraud-BpJ_aoIE.mjs} +1 -1
  92. package/dist/generate-qMU-2MgC.mjs +2 -0
  93. package/dist/{google-tag-gateway-DsZA0a1r.mjs → google-tag-gateway-DA_7SCC3.mjs} +1 -1
  94. package/dist/{healthchecks-CFH5bIAG.mjs → healthchecks-C-GthoQz.mjs} +1 -1
  95. package/dist/{hostnames-CKDSQsXT.mjs → hostnames-CH6utzVv.mjs} +1 -1
  96. package/dist/{hyperdrive-BLiI7eoy.mjs → hyperdrive-_rIC33bB.mjs} +1 -1
  97. package/dist/{iam-B5mdfq5e.mjs → iam-sseKl99z.mjs} +1 -1
  98. package/dist/{images-IVRjrB4_.mjs → images-CvIOwtg0.mjs} +1 -1
  99. package/dist/index.mjs +1 -1
  100. package/dist/{init-C6pA2OKl.mjs → init-DEIhItNF.mjs} +2 -2
  101. package/dist/{intel-CvesITo3.mjs → intel-Da84oZMO.mjs} +1 -1
  102. package/dist/{ips-DT9GaimG.mjs → ips-zTTd_3jg.mjs} +1 -1
  103. package/dist/{keyless-certificates-B0Xe5WqA.mjs → keyless-certificates-BGOUKdJc.mjs} +1 -1
  104. package/dist/{keys-BfcwaSGe.mjs → keys-CDnrfmiS.mjs} +1 -1
  105. package/dist/{kv-BAKDr9h1.mjs → kv-C5jR7vjM.mjs} +1 -1
  106. package/dist/{lazy-command-BR3u8SQ2.mjs → lazy-command-DZtpMsVB.mjs} +1 -1
  107. package/dist/{leaked-credential-checks-gRpF7J9-.mjs → leaked-credential-checks-B7WSzVG3.mjs} +1 -1
  108. package/dist/{load-balancers-CLVWIN9d.mjs → load-balancers-DG9wMQUM.mjs} +1 -1
  109. package/dist/{local-CxYne8s2.mjs → local-B3OyWKkW.mjs} +1 -1
  110. package/dist/local-qOpZjDed.mjs +2 -0
  111. package/dist/{local-runtime-C_fR3pz4.mjs → local-runtime-Co5vVDlI.mjs} +1 -1
  112. package/dist/{login-B2IW-LZC.mjs → login-k3QLVysD.mjs} +1 -1
  113. package/dist/{login-BKQI53YQ.mjs → login-rJanUgdL.mjs} +1 -1
  114. package/dist/{logo-matches-CmCWQC_j.mjs → logo-matches-5nijgkg7.mjs} +1 -1
  115. package/dist/{logos-DoGIvvML.mjs → logos-BRRqg8_2.mjs} +1 -1
  116. package/dist/{logpush-C2fS4mz8.mjs → logpush-Br7H8sRD.mjs} +1 -1
  117. package/dist/{logs-DOchrxC9.mjs → logs-CBU44LT8.mjs} +1 -1
  118. package/dist/{magic-cloud-networking-BTWKttlB.mjs → magic-cloud-networking-Bu7O7wKz.mjs} +1 -1
  119. package/dist/{magic-network-monitoring-C_6hCn_f.mjs → magic-network-monitoring-Bnc--4Jr.mjs} +1 -1
  120. package/dist/{magic-transit-B-Rmmg-Z.mjs → magic-transit-Dxr86HKN.mjs} +1 -1
  121. package/dist/{managed-defense-BPSLbGgV.mjs → managed-defense-Bm_jKFTN.mjs} +1 -1
  122. package/dist/{managed-transforms-BqiDVQD6.mjs → managed-transforms-D5mvHv_N.mjs} +1 -1
  123. package/dist/{matches-wLc335So.mjs → matches-Dhc1eSWw.mjs} +1 -1
  124. package/dist/{mcp-CmQOrkzP.mjs → mcp-B-PBoBl5.mjs} +1 -1
  125. package/dist/{mesh-DRuFq2pw.mjs → mesh-CW8B4naI.mjs} +1 -1
  126. package/dist/migrate-B4kBnkpV.mjs +2 -0
  127. package/dist/{mtls-certificates-BUcQwJGQ.mjs → mtls-certificates-swvfPqA2.mjs} +1 -1
  128. package/dist/{network-interconnects-BzfPaxkW.mjs → network-interconnects-CjXYZC4g.mjs} +1 -1
  129. package/dist/{network-BuXy0ysq.mjs → network-iwRBn0i7.mjs} +1 -1
  130. package/dist/{oauth-BlFK0DPZ.mjs → oauth-CrTr-mRe.mjs} +1 -1
  131. package/dist/oauth-DJW_HyaL.mjs +9 -0
  132. package/dist/{oauth-clients-CnABE4xT.mjs → oauth-clients-DGUJzFFu.mjs} +1 -1
  133. package/dist/{oauth-scopes-BFy1Hw7K.mjs → oauth-scopes-Bl0YUOHt.mjs} +1 -1
  134. package/dist/{observability-B1IkzeE0.mjs → observability-DRHiMrLy.mjs} +1 -1
  135. package/dist/{organization-DeIzTyFr.mjs → organization-BoMJzks7.mjs} +1 -1
  136. package/dist/{organizations-dpNO5XaQ.mjs → organizations-UGtCHzSq.mjs} +1 -1
  137. package/dist/{origin-ca-certificates-B-1YtC61.mjs → origin-ca-certificates-CdByaOCe.mjs} +1 -1
  138. package/dist/{origin-post-quantum-encryption-DdvwucsG.mjs → origin-post-quantum-encryption-GjmifGkF.mjs} +1 -1
  139. package/dist/{origin-tls-client-auth-CzfpVmTE.mjs → origin-tls-client-auth-CCIqSj_C.mjs} +1 -1
  140. package/dist/{page-rules--wnIp30C.mjs → page-rules-Btn-r3QF.mjs} +1 -1
  141. package/dist/{pages-DvhJZv5S.mjs → pages-iil93G96.mjs} +1 -1
  142. package/dist/{pay-per-crawl-lqX3Rwt9.mjs → pay-per-crawl-DcAZuk9T.mjs} +1 -1
  143. package/dist/{pay-per-use-BRKnBlz2.mjs → pay-per-use-z0Iwy9rN.mjs} +1 -1
  144. package/dist/{pipelines-CvePummb.mjs → pipelines-YRPwntqo.mjs} +1 -1
  145. package/dist/{precursor-DgotmHQd.mjs → precursor-Bcww14RH.mjs} +1 -1
  146. package/dist/previews-BBn-IiQu.mjs +4 -0
  147. package/dist/{progress-DUeNqM-j.mjs → progress-5nsUpQL6.mjs} +1 -1
  148. package/dist/{prompt-DV6YTdoa.mjs → prompt-Ba_bys2F.mjs} +1 -1
  149. package/dist/{queries-CLqy4AM6.mjs → queries-lxdncISw.mjs} +1 -1
  150. package/dist/{queues-D0Y4LNP1.mjs → queues-Egb0KXYK.mjs} +1 -1
  151. package/dist/{r2-D_FuuTGm.mjs → r2-BD4NOkR7.mjs} +1 -1
  152. package/dist/{r2-data-catalog-D5Fvpr3C.mjs → r2-data-catalog-CI-oHtKe.mjs} +1 -1
  153. package/dist/{radar-B6bYFNVn.mjs → radar-B4dtfeBP.mjs} +1 -1
  154. package/dist/{raw-fetch-Cp3EaTcj.mjs → raw-fetch-AX_Gz3c3.mjs} +1 -1
  155. package/dist/{realtime-BTBZoZNW.mjs → realtime-CtLXkW8l.mjs} +1 -1
  156. package/dist/{registrar-CFh4TCkC.mjs → registrar-I9XClUOe.mjs} +1 -1
  157. package/dist/{registrar-sandbox-By6ukXxf.mjs → registrar-sandbox-DAqK58QS.mjs} +1 -1
  158. package/dist/{reporting-Cf3q4cuO.mjs → reporting-BYsEUCIE.mjs} +1 -1
  159. package/dist/{request-headers-jdUlF-_S.mjs → request-headers-sc4CaZX0.mjs} +1 -1
  160. package/dist/{request-tracers-CqNmb-dS.mjs → request-tracers-DXr9Dr2z.mjs} +1 -1
  161. package/dist/{resource-sharing-vDvq5J5a.mjs → resource-sharing-DgbnNgCQ.mjs} +1 -1
  162. package/dist/{resource-tagging-DRCkpRmf.mjs → resource-tagging-CjPU8PpX.mjs} +1 -1
  163. package/dist/{rules-D-IfU82u.mjs → rules-BrshTdy1.mjs} +1 -1
  164. package/dist/{rulesets-ezJUnXm7.mjs → rulesets-BZulblVp.mjs} +1 -1
  165. package/dist/{rum-G42H7AXu.mjs → rum-B4IRlWgy.mjs} +1 -1
  166. package/dist/run-BQGVl3vg.mjs +2 -0
  167. package/dist/{run-BhfDNWCI.mjs → run-UHTbUldP.mjs} +1 -1
  168. package/dist/{schema-flags-yDMur8UR.mjs → schema-flags-C4KmiKur.mjs} +1 -1
  169. package/dist/{scim-DgRlqTtE.mjs → scim-BL2TVEZM.mjs} +1 -1
  170. package/dist/{secrets-store-DcNmMGG2.mjs → secrets-store-BcyhU7Kj.mjs} +1 -1
  171. package/dist/{security-center-CZwVaL7t.mjs → security-center-D1LSkhL_.mjs} +1 -1
  172. package/dist/{security-txt-CD0RAEsU.mjs → security-txt-BGIj4nU3.mjs} +1 -1
  173. package/dist/shared-jqlTaG5K.mjs +2 -0
  174. package/dist/{smart-shield-C72SYuAe.mjs → smart-shield-C8mGSzyE.mjs} +1 -1
  175. package/dist/{snippets-Bl4Rfvdf.mjs → snippets-BmHMaKEZ.mjs} +1 -1
  176. package/dist/{spawn-PBhhCQdl.mjs → spawn-IM_tQldH.mjs} +1 -1
  177. package/dist/{spectrum-BgOMd04u.mjs → spectrum-CrGKTMx-.mjs} +1 -1
  178. package/dist/{speed-dahwVmv-.mjs → speed-yyPLwj5X.mjs} +1 -1
  179. package/dist/{src-npcmT3gh.mjs → src-DFnlH5Tg.mjs} +5 -5
  180. package/dist/{ssl-BMZZPgJx.mjs → ssl-DZ6G7pP_.mjs} +1 -1
  181. package/dist/{stream-CsQ8wMMF.mjs → stream-hoBmKs9X.mjs} +1 -1
  182. package/dist/{submit-DdoTeeRt.mjs → submit-Lfebq3yj.mjs} +1 -1
  183. package/dist/{tags-BESTUjkv.mjs → tags-CnHv__u_.mjs} +1 -1
  184. package/dist/telemetry-C3hmM9Q9.mjs +2 -0
  185. package/dist/{telemetry-CVjp5qaj.mjs → telemetry-DbAo3nvk.mjs} +1 -1
  186. package/dist/{tenant-COyp8x56.mjs → tenant-7CL844dh.mjs} +1 -1
  187. package/dist/{tenant-custom-nameservers-BdrnvyTk.mjs → tenant-custom-nameservers-CZL9_D8w.mjs} +1 -1
  188. package/dist/{tunnels-CjDCYR0_.mjs → tunnels-DuO8F5_h.mjs} +1 -1
  189. package/dist/{turnstile-crX-kMig.mjs → turnstile-B-6k-bKa.mjs} +1 -1
  190. package/dist/update-check-BDMPumcv.mjs +2 -0
  191. package/dist/{update-check-BpLdkJeA.mjs → update-check-g9Jcn6YJ.mjs} +1 -1
  192. package/dist/update-check-worker.mjs +1 -1
  193. package/dist/{url-info-CSU3TaVe.mjs → url-info-C6-jj9nl.mjs} +1 -1
  194. package/dist/{url-normalization-DKZYH3Tv.mjs → url-normalization-BRSTQe20.mjs} +1 -1
  195. package/dist/{url-scanner-mtiMlSyE.mjs → url-scanner-DER5YAdW.mjs} +1 -1
  196. package/dist/{user-DuDnsFvs.mjs → user-foSeF-0m.mjs} +1 -1
  197. package/dist/{values-B4gL0UvN.mjs → values-DgBNckq9.mjs} +1 -1
  198. package/dist/{vectorize-CEC7tpRJ.mjs → vectorize-9AZMN3fN.mjs} +1 -1
  199. package/dist/version-DLvRzH-I.mjs +2 -0
  200. package/dist/{waiting-rooms-CosskYpi.mjs → waiting-rooms-CUc0Xqp0.mjs} +1 -1
  201. package/dist/{web-assets-Do2JEl4p.mjs → web-assets-D5LUB5UO.mjs} +1 -1
  202. package/dist/{web3-C3sb4DR8.mjs → web3-BvOpojFR.mjs} +1 -1
  203. package/dist/workers-Cko7OnFE.mjs +40 -0
  204. package/dist/{workers-builds-CDE-wcw-.mjs → workers-builds-BFqiT0GR.mjs} +1 -1
  205. package/dist/{workers-for-platforms-CvZI2B1d.mjs → workers-for-platforms-EVE01qsM.mjs} +1 -1
  206. package/dist/{workers-vpc-WbwBVV_L.mjs → workers-vpc-9xBzFjiF.mjs} +1 -1
  207. package/dist/{workflows-Ch7cNhhq.mjs → workflows-BS0EGixd.mjs} +1 -1
  208. package/dist/wrangler-migration-BDkh1_IV.mjs +2 -0
  209. package/dist/{zaraz-BO7WT_U7.mjs → zaraz-DBccJ-ZM.mjs} +1 -1
  210. package/dist/{zero-trust-CTKtzxxW.mjs → zero-trust-DGagti-V.mjs} +4 -4
  211. package/dist/{zone-DSHj2Vv2.mjs → zone-B4OniptR.mjs} +1 -1
  212. package/dist/{zones-CeFb9USG.mjs → zones-DYuGVoTH.mjs} +1 -1
  213. package/package.json +1 -1
  214. package/dist/build-CVvo9BvP.mjs +0 -2
  215. package/dist/build-vfD1txJe.mjs +0 -2
  216. package/dist/command-ZSxcR8-J.mjs +0 -2
  217. package/dist/dev-BpvWl6pG.mjs +0 -4
  218. package/dist/generate-BAHK895m.mjs +0 -2
  219. package/dist/local-22UA5g9y.mjs +0 -2
  220. package/dist/migrate-DBwOnU6B.mjs +0 -2
  221. package/dist/oauth-BYmfy7l7.mjs +0 -9
  222. package/dist/previews-Brsuhzmk.mjs +0 -4
  223. package/dist/run-djd1-6kN.mjs +0 -2
  224. package/dist/shared-Cfuwhk19.mjs +0 -2
  225. package/dist/telemetry-iBZ-f6og.mjs +0 -2
  226. package/dist/update-check-CtmTFJ-O.mjs +0 -2
  227. package/dist/version-CPwqVR_p.mjs +0 -2
  228. package/dist/workers-ByA4Nddg.mjs +0 -36
  229. /package/dist/{cloudflared-CH8rOneA.mjs → cloudflared-91JvyShh.mjs} +0 -0
  230. /package/dist/{command-DBpr6U4L.mjs → command-C72KLHMc.mjs} +0 -0
  231. /package/dist/{discover-DmIsaE54.mjs → discover-VRFBjse7.mjs} +0 -0
  232. /package/dist/{generate-DWW1YPjv.mjs → generate-iV6OVNin.mjs} +0 -0
  233. /package/dist/{registry-kYRASukx.mjs → registry-DBMUTYqf.mjs} +0 -0
  234. /package/dist/{schema-s22s29sJ.mjs → schema-CueLBLXC.mjs} +0 -0
  235. /package/dist/{tools-LlzHD_86.mjs → tools-BJbI_f35.mjs} +0 -0
@@ -131588,6 +131588,48 @@
131588
131588
  "operationId": "worker-script-search-workers",
131589
131589
  "hideCommand": false
131590
131590
  },
131591
+ {
131592
+ "command": "cf workers secrets bulk",
131593
+ "name": "bulk",
131594
+ "fullPath": ["workers", "secrets", "bulk"],
131595
+ "description": "Create, update, or delete multiple secrets on a Worker script in a single operation using JSON Merge Patch (RFC 7396). This operation creates a single version with all changes included. Prefer this API instead of changing many secrets individually. Usage: - To create or update a secret, set its value to a secret object. - To delete a secret, set its value to `null`. - Secrets not included in the request are left unchanged.",
131596
+ "summary": "Patch multiple Worker script secrets",
131597
+ "usage": "cf workers secrets bulk [options]",
131598
+ "arguments": [],
131599
+ "options": [
131600
+ {
131601
+ "name": "worker",
131602
+ "type": "string",
131603
+ "required": true,
131604
+ "description": "Name of the script, used in URLs and route configuration."
131605
+ },
131606
+ {
131607
+ "name": "dry-run",
131608
+ "type": "boolean",
131609
+ "required": false,
131610
+ "description": "Validate and show what would happen without executing",
131611
+ "default": false
131612
+ },
131613
+ {
131614
+ "name": "body",
131615
+ "type": "string",
131616
+ "required": false,
131617
+ "description": "Raw JSON request body (bypasses individual flags)"
131618
+ },
131619
+ {
131620
+ "name": "file",
131621
+ "type": "string",
131622
+ "required": false,
131623
+ "description": "Path to a file to upload as the request body"
131624
+ }
131625
+ ],
131626
+ "category": "action",
131627
+ "hasRequestBody": true,
131628
+ "httpMethod": "PATCH",
131629
+ "apiPath": "/accounts/{account_id}/workers/scripts/{script_name}/secrets-bulk",
131630
+ "operationId": "worker-patch-script-secrets-bulk",
131631
+ "hideCommand": false
131632
+ },
131591
131633
  {
131592
131634
  "command": "cf workers secrets delete",
131593
131635
  "name": "delete",
@@ -131706,6 +131748,82 @@
131706
131748
  "operationId": "worker-list-script-secrets",
131707
131749
  "hideCommand": false
131708
131750
  },
131751
+ {
131752
+ "command": "cf workers secrets update",
131753
+ "name": "update",
131754
+ "fullPath": ["workers", "secrets", "update"],
131755
+ "description": "Add a secret to a Worker script by creating a new version with that secret. When changing more than one secret at a time, prefer the \"Patch multiple script secrets\" API instead of changing many secrets individually.",
131756
+ "summary": "Add a secret to a Worker script",
131757
+ "usage": "cf workers secrets update <name> [options]",
131758
+ "arguments": [
131759
+ {
131760
+ "name": "name",
131761
+ "position": 0,
131762
+ "type": "string",
131763
+ "required": true,
131764
+ "description": "A JavaScript variable name for the binding."
131765
+ }
131766
+ ],
131767
+ "options": [
131768
+ {
131769
+ "name": "worker",
131770
+ "type": "string",
131771
+ "required": true,
131772
+ "description": "Name of the script, used in URLs and route configuration."
131773
+ },
131774
+ {
131775
+ "name": "text",
131776
+ "type": "string",
131777
+ "required": false,
131778
+ "description": "The secret value to use."
131779
+ },
131780
+ {
131781
+ "name": "type",
131782
+ "type": "string",
131783
+ "required": true,
131784
+ "description": "The kind of resource that the binding provides.",
131785
+ "enum": ["secret_text", "secret_key"]
131786
+ },
131787
+ {
131788
+ "name": "format",
131789
+ "type": "string",
131790
+ "required": false,
131791
+ "description": "Data format of the key. [Learn more](https://developer.mozilla.org/en-US/docs/Web/API/SubtleCrypto/importKey#format).",
131792
+ "enum": ["raw", "pkcs8", "spki", "jwk"]
131793
+ },
131794
+ {
131795
+ "name": "key-base64",
131796
+ "type": "string",
131797
+ "required": false,
131798
+ "description": "Base64-encoded key data. Required if `format` is \"raw\", \"pkcs8\", or \"spki\"."
131799
+ },
131800
+ {
131801
+ "name": "usages",
131802
+ "type": "string",
131803
+ "required": false,
131804
+ "description": "Allowed operations with the key. [Learn more](https://developer.mozilla.org/en-US/docs/Web/API/SubtleCrypto/importKey#keyUsages)."
131805
+ },
131806
+ {
131807
+ "name": "dry-run",
131808
+ "type": "boolean",
131809
+ "required": false,
131810
+ "description": "Validate and show what would happen without executing",
131811
+ "default": false
131812
+ },
131813
+ {
131814
+ "name": "body",
131815
+ "type": "string",
131816
+ "required": false,
131817
+ "description": "Raw JSON request body (bypasses individual flags)"
131818
+ }
131819
+ ],
131820
+ "category": "update",
131821
+ "hasRequestBody": true,
131822
+ "httpMethod": "PUT",
131823
+ "apiPath": "/accounts/{account_id}/workers/scripts/{script_name}/secrets",
131824
+ "operationId": "worker-put-script-secret",
131825
+ "hideCommand": false
131826
+ },
131709
131827
  {
131710
131828
  "command": "cf workers triggers deploy",
131711
131829
  "name": "deploy",
@@ -91428,6 +91428,26 @@
91428
91428
  "hasRequestBody": false,
91429
91429
  "requestBodyFields": []
91430
91430
  },
91431
+ "workers secrets bulk": {
91432
+ "operationId": "worker-patch-script-secrets-bulk",
91433
+ "httpMethod": "PATCH",
91434
+ "path": "/accounts/{account_id}/workers/scripts/{script_name}/secrets-bulk",
91435
+ "pathParams": [
91436
+ {
91437
+ "name": "account_id",
91438
+ "type": "string",
91439
+ "required": true
91440
+ },
91441
+ {
91442
+ "name": "script_name",
91443
+ "type": "string",
91444
+ "required": true
91445
+ }
91446
+ ],
91447
+ "queryParams": [],
91448
+ "hasRequestBody": true,
91449
+ "requestBodyFields": []
91450
+ },
91431
91451
  "workers secrets delete": {
91432
91452
  "operationId": "worker-delete-script-secret",
91433
91453
  "httpMethod": "DELETE",
@@ -91510,6 +91530,63 @@
91510
91530
  "hasRequestBody": false,
91511
91531
  "requestBodyFields": []
91512
91532
  },
91533
+ "workers secrets update": {
91534
+ "operationId": "worker-put-script-secret",
91535
+ "httpMethod": "PUT",
91536
+ "path": "/accounts/{account_id}/workers/scripts/{script_name}/secrets",
91537
+ "pathParams": [
91538
+ {
91539
+ "name": "account_id",
91540
+ "type": "string",
91541
+ "required": true
91542
+ },
91543
+ {
91544
+ "name": "script_name",
91545
+ "type": "string",
91546
+ "required": true
91547
+ }
91548
+ ],
91549
+ "queryParams": [],
91550
+ "hasRequestBody": true,
91551
+ "requestBodyFields": [
91552
+ {
91553
+ "name": "name",
91554
+ "type": "string",
91555
+ "required": true,
91556
+ "description": "A JavaScript variable name for the binding."
91557
+ },
91558
+ {
91559
+ "name": "text",
91560
+ "type": "string",
91561
+ "required": false,
91562
+ "description": "The secret value to use."
91563
+ },
91564
+ {
91565
+ "name": "type",
91566
+ "type": "string",
91567
+ "required": true,
91568
+ "description": "The kind of resource that the binding provides."
91569
+ },
91570
+ {
91571
+ "name": "format",
91572
+ "type": "string",
91573
+ "required": false,
91574
+ "description": "Data format of the key. [Learn more](https://developer.mozilla.org/en-US/docs/Web/API/SubtleCrypto/importKey#format)."
91575
+ },
91576
+ {
91577
+ "name": "key-base64",
91578
+ "type": "string",
91579
+ "required": false,
91580
+ "description": "Base64-encoded key data. Required if `format` is \"raw\", \"pkcs8\", or \"spki\"."
91581
+ },
91582
+ {
91583
+ "name": "usages",
91584
+ "type": "string",
91585
+ "required": false,
91586
+ "description": "Allowed operations with the key. [Learn more](https://developer.mozilla.org/en-US/docs/Web/API/SubtleCrypto/importKey#keyUsages)."
91587
+ }
91588
+ ]
91589
+ },
91513
91590
  "workers versions delete": {
91514
91591
  "operationId": "deleteWorkerVersion",
91515
91592
  "httpMethod": "DELETE",
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{t as e}from"./local-CxYne8s2.mjs";import{a as t,t as n}from"./context-5JRcefHh.mjs";import{r}from"./auth-3bFlHTVl.mjs";import{t as i}from"./output-CvQFJkvi.mjs";import{t as a}from"./dry-run-Bq0JAsbX.mjs";import{t as o}from"./progress-DUeNqM-j.mjs";import{t as s}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{n as c,r as l,t as u}from"./body-parser-hh2avzkz.mjs";import{n as d}from"./input-validation-Dk52b0me.mjs";import{a as f,i as p}from"./prompt-DV6YTdoa.mjs";import{t as m}from"./cli-types-DoVT5q_M.mjs";function h(e){return e.usage(`$0 abuse-reports appeals eligibility <report-id>
2
+ import{t as e}from"./local-B3OyWKkW.mjs";import{a as t,t as n}from"./context-BsGrhAqB.mjs";import{r}from"./auth-BYFcxn1F.mjs";import{t as i}from"./output-CvQFJkvi.mjs";import{t as a}from"./dry-run-Bq0JAsbX.mjs";import{t as o}from"./progress-5nsUpQL6.mjs";import{t as s}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{n as c,r as l,t as u}from"./body-parser-hh2avzkz.mjs";import{n as d}from"./input-validation-Dk52b0me.mjs";import{a as f,i as p}from"./prompt-Ba_bys2F.mjs";import{t as m}from"./cli-types-DoVT5q_M.mjs";function h(e){return e.usage(`$0 abuse-reports appeals eligibility <report-id>
3
3
 
4
4
  Returns whether the report is currently appealable, along with the signals behind that decision: whether it already has an open appeal, how many appeals have been submitted against it, and whether it has at least one mitigation that an appeal could reverse.`).positional(`report-id`,{type:`string`,description:`Abuse Report ID`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const g={command:`eligibility <report-id>`,describe:`Check whether a report can be appealed`,builder:h,handler:async c=>s({command:`abuse-reports appeals eligibility`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){a({command:`cf abuse-reports appeals eligibility`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await t()??`<account-id>`}/abuse-reports/${c[`report-id`]==null?`<report-id>`:encodeURIComponent(String(c[`report-id`]))}/appeals/eligibility`,pathParams:{"report-id":String(c[`report-id`]??``)},bodyKind:`none`});return}let s=await r(c),l=c.local?e:await n();c.accountId=l,i(await o(`Loading`,async()=>s.abuseReports.appeals.eligibility({account_id:l,report_id:c[`report-id`]})),{successLabel:`Loaded`})})},_={command:`appeals`,describe:`Operations for appeals`,builder:e=>e.command(g).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function v(e){return e.usage("$0 abuse-reports create <report-param>\n\nSubmit an abuse report of a particular type. Requires the abuse-reports entitlement on the account (Enterprise accounts have it by default; other accounts must request access) and an API token with the `Account > Abuse Reports > Edit` permission. If the account is not entitled, the request is rejected with an HTTP `401` response (see below).").positional(`report-param`,{type:`string`,description:`The report type to be submitted. Example: abuse_general`,demandOption:!0}).option(`act`,{type:`string`,description:`The act field`,choices:[`abuse_dmca`,`abuse_trademark`,`abuse_general`,`abuse_phishing`,`abuse_children`,`abuse_threat`,`abuse_registrar_whois`,`abuse_ncsei`]}).option(`comments`,{type:`string`,description:`Any additional comments about the infringement not exceeding 2000 characters`}).option(`company`,{type:`string`,description:`Text not exceeding 100 characters. This field may be released by Cloudflare to third parties such as the Lumen Database (https://lumendatabase.org/).`}).option(`email`,{type:`string`,description:`A valid email of the abuse reporter. This field may be released by Cloudflare to third parties such as the Lumen Database (https://lumendatabase.org/).`}).option(`email2`,{type:`string`,description:"Should match the value provided in `email`"}).option(`name`,{type:`string`,description:`Text not exceeding 255 characters. This field may be released by Cloudflare to third parties such as the Lumen Database (https://lumendatabase.org/).`}).option(`reported-country`,{type:`string`,description:`Text containing 2 characters`}).option(`reported-user-agent`,{type:`string`,description:`Text not exceeding 255 characters`}).option(`tele`,{type:`string`,description:`Text not exceeding 20 characters. This field may be released by Cloudflare to third parties such as the Lumen Database (https://lumendatabase.org/).`}).option(`title`,{type:`string`,description:`Text not exceeding 255 characters`}).option(`urls`,{type:`string`,description:`A list of valid URLs separated by ‘\\n’ (new line character). The list of the URLs should not exceed 250 URLs. All URLs should have the same hostname. Each URL should be unique. This field may be released by Cloudflare to third parties such as the Lumen Database (https://lumendatabase.org/).`}).option(`address1`,{type:`string`,description:`Text not exceeding 100 characters. This field may be released by Cloudflare to third parties such as the Lumen Database (https://lumendatabase.org/).`}).option(`agent-name`,{type:`string`,description:`The name of the copyright holder. Text not exceeding 60 characters. This field may be released by Cloudflare to third parties such as the Lumen Database (https://lumendatabase.org/).`}).option(`agree`,{type:`number`,description:"Can be `0` for false or `1` for true. Must be value: 1 for DMCA reports"}).option(`city`,{type:`string`,description:`Text not exceeding 255 characters. This field may be released by Cloudflare to third parties such as the Lumen Database (https://lumendatabase.org/).`}).option(`country`,{type:`string`,description:`Text not exceeding 255 characters. This field may be released by Cloudflare to third parties such as the Lumen Database (https://lumendatabase.org/).
5
5
  `}).option(`host-notification`,{type:`string`,description:`Notification type based on the abuse type. NOTE: Copyright (DMCA) and Trademark reports cannot be anonymous.
@@ -1,2 +1,2 @@
1
1
  #!/usr/bin/env node
2
- import{t as e}from"./lazy-command-BR3u8SQ2.mjs";var t=e(`curl <url>`,`Run curl against an Access-protected application with its JWT injected by cloudflared.`,()=>import(`./command-Axp5Wfpj.mjs`),{command:`access curl`,recordArgs:!1}),n=e(`login <url>`,`Authenticate with an Access application and store its JWT through cloudflared.`,()=>import(`./command-jJKEah9i.mjs`),{command:`access login`,recordArgs:!1}),r=e(`ssh-config`,`Print an example SSH configuration for an Access application.`,()=>import(`./command-DBCoI1fN.mjs`),{command:`access ssh-config`,recordArgs:!1}),i=e(`ssh-gen`,`Generate a short-lived certificate for an Access SSH application.`,()=>import(`./command-egPOyKbx.mjs`),{command:`access ssh-gen`,recordArgs:!1}),a={...e(`tcp`,`Proxy a TCP connection through Access. The command is also available as ssh, rdp, and smb.`,()=>import(`./command-BH-TMJWp.mjs`),{command:`access tcp`,recordArgs:!1}),aliases:[`ssh`,`rdp`,`smb`]},o=e(`token <url>`,`Print a JWT for authenticating with an Access application.`,()=>import(`./command-DrQKTf1O.mjs`),{command:`access token`,recordArgs:!1});const s={command:`access`,describe:`Access protected applications and services`,builder:e=>e.command(t).command(n).command(r).command(i).command(a).command(o).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{s as default};
2
+ import{t as e}from"./lazy-command-DZtpMsVB.mjs";var t=e(`curl <url>`,`Run curl against an Access-protected application with its JWT injected by cloudflared.`,()=>import(`./command-BPfW-yE4.mjs`),{command:`access curl`,recordArgs:!1}),n=e(`login <url>`,`Authenticate with an Access application and store its JWT through cloudflared.`,()=>import(`./command-DYeBZ5mA.mjs`),{command:`access login`,recordArgs:!1}),r=e(`ssh-config`,`Print an example SSH configuration for an Access application.`,()=>import(`./command-CJR1CUK_.mjs`),{command:`access ssh-config`,recordArgs:!1}),i=e(`ssh-gen`,`Generate a short-lived certificate for an Access SSH application.`,()=>import(`./command-gSmdvn_d.mjs`),{command:`access ssh-gen`,recordArgs:!1}),a={...e(`tcp`,`Proxy a TCP connection through Access. The command is also available as ssh, rdp, and smb.`,()=>import(`./command-DRlUj6lW.mjs`),{command:`access tcp`,recordArgs:!1}),aliases:[`ssh`,`rdp`,`smb`]},o=e(`token <url>`,`Print a JWT for authenticating with an Access application.`,()=>import(`./command-DJJN9xaA.mjs`),{command:`access token`,recordArgs:!1});const s={command:`access`,describe:`Access protected applications and services`,builder:e=>e.command(t).command(n).command(r).command(i).command(a).command(o).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{s as default};
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{t as e}from"./local-CxYne8s2.mjs";import{a as t,t as n}from"./context-5JRcefHh.mjs";import{r}from"./auth-3bFlHTVl.mjs";import{t as i}from"./output-CvQFJkvi.mjs";import{t as a}from"./dry-run-Bq0JAsbX.mjs";import{t as o}from"./progress-DUeNqM-j.mjs";import{t as s}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{n as c,t as l}from"./body-parser-hh2avzkz.mjs";import{n as u}from"./input-validation-Dk52b0me.mjs";import{a as d}from"./prompt-DV6YTdoa.mjs";function f(e){return e.usage(`$0 account batch move
2
+ import{t as e}from"./local-B3OyWKkW.mjs";import{a as t,t as n}from"./context-BsGrhAqB.mjs";import{r}from"./auth-BYFcxn1F.mjs";import{t as i}from"./output-CvQFJkvi.mjs";import{t as a}from"./dry-run-Bq0JAsbX.mjs";import{t as o}from"./progress-5nsUpQL6.mjs";import{t as s}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{n as c,t as l}from"./body-parser-hh2avzkz.mjs";import{n as u}from"./input-validation-Dk52b0me.mjs";import{a as d}from"./prompt-Ba_bys2F.mjs";function f(e){return e.usage(`$0 account batch move
3
3
 
4
4
  Batch move a collection of accounts to a specific organization. ⚠️ Not implemented.`).option(`account-ids`,{type:`string`,array:!0,description:`Move these accounts to the destination organization.`}).option(`destination-organization-id`,{type:`string`,description:`Move accounts to this organization ID.`}).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 p={command:`move`,describe:`Batch move accounts`,builder:f,handler:async e=>s({command:`account batch move`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf account batch move`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/move`,pathParams:{},bodyKind:`json`,body:e.body===void 0?l({account_ids:e[`account-ids`],destination_organization_id:u(e[`destination-organization-id`],`destination-organization-id`,`text`)}):c(e.body)});return}let t=await r(e);if(e.body){let n=c(e.body);i(await o(`Creating`,async()=>t.account.batch.move({...n})),{successLabel:`Created`});return}if(e[`account-ids`]===void 0)throw Error(`--account-ids is required (or pass --body with this field set).`);e[`destination-organization-id`]===void 0&&(e[`destination-organization-id`]=await d(`destination-organization-id`,`Move accounts to this organization ID.`));let n=l({account_ids:e[`account-ids`],destination_organization_id:u(e[`destination-organization-id`],`destination-organization-id`,`text`)});i(await o(`Creating`,async()=>t.account.batch.move({...n})),{successLabel:`Created`})})},m={command:`batch`,describe:`Operations for batch`,builder:e=>e.command(p).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function h(e){return e.usage(`$0 account move
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{t as e}from"./local-CxYne8s2.mjs";import{a as t,i as n,t as r}from"./context-5JRcefHh.mjs";import{a as i,r as a}from"./auth-3bFlHTVl.mjs";import{t as o}from"./output-CvQFJkvi.mjs";import{t as s}from"./dry-run-Bq0JAsbX.mjs";import{t as c}from"./progress-DUeNqM-j.mjs";import{t as l}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{i as u,n as d,t as f}from"./body-parser-hh2avzkz.mjs";import{n as p}from"./input-validation-Dk52b0me.mjs";import{a as m,i as h,n as g}from"./prompt-DV6YTdoa.mjs";import{t as _}from"./cli-types-DoVT5q_M.mjs";function v(e){return e.usage(`$0 account-tags delete
2
+ import{t as e}from"./local-B3OyWKkW.mjs";import{a as t,i as n,t as r}from"./context-BsGrhAqB.mjs";import{a as i,r as a}from"./auth-BYFcxn1F.mjs";import{t as o}from"./output-CvQFJkvi.mjs";import{t as s}from"./dry-run-Bq0JAsbX.mjs";import{t as c}from"./progress-5nsUpQL6.mjs";import{t as l}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{i as u,n as d,t as f}from"./body-parser-hh2avzkz.mjs";import{n as p}from"./input-validation-Dk52b0me.mjs";import{a as m,i as h,n as g}from"./prompt-Ba_bys2F.mjs";import{t as _}from"./cli-types-DoVT5q_M.mjs";function v(e){return e.usage(`$0 account-tags delete
3
3
 
4
4
  Removes all tags from a specific account or zone-level resource.`).option(`if-match`,{type:`string`,description:`ETag value for optimistic concurrency control. When provided, the server will
5
5
  verify the current resource ETag matches before applying the write. Returns
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{t as e}from"./local-CxYne8s2.mjs";import{a as t,i as n,t as r}from"./context-5JRcefHh.mjs";import{a as i,r as a}from"./auth-3bFlHTVl.mjs";import{t as o}from"./output-CvQFJkvi.mjs";import{t as s}from"./dry-run-Bq0JAsbX.mjs";import{t as c}from"./progress-DUeNqM-j.mjs";import{t as l}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{i as u,n as d,r as f,t as p}from"./body-parser-hh2avzkz.mjs";import{n as m}from"./input-validation-Dk52b0me.mjs";import{a as h,i as g,n as _}from"./prompt-DV6YTdoa.mjs";import{t as v}from"./cli-types-DoVT5q_M.mjs";import{n as ee,t as te}from"./raw-fetch-Cp3EaTcj.mjs";function y(e){return e.usage(`$0 accounts applications create
2
+ import{t as e}from"./local-B3OyWKkW.mjs";import{a as t,i as n,t as r}from"./context-BsGrhAqB.mjs";import{a as i,r as a}from"./auth-BYFcxn1F.mjs";import{t as o}from"./output-CvQFJkvi.mjs";import{t as s}from"./dry-run-Bq0JAsbX.mjs";import{t as c}from"./progress-5nsUpQL6.mjs";import{t as l}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{i as u,n as d,r as f,t as p}from"./body-parser-hh2avzkz.mjs";import{n as m}from"./input-validation-Dk52b0me.mjs";import{a as h,i as g,n as _}from"./prompt-Ba_bys2F.mjs";import{t as v}from"./cli-types-DoVT5q_M.mjs";import{n as ee,t as te}from"./raw-fetch-AX_Gz3c3.mjs";function y(e){return e.usage(`$0 accounts applications create
3
3
 
4
4
  Create a custom application for an account.`).option(`category-id`,{type:`number`,description:`Returns the category ID.`}).option(`hostnames`,{type:`string`,array:!0,description:`Hostnames matched by the application.`}).option(`human-id`,{type:`string`,description:`Returns the human readable ID.`}).option(`ip-subnets`,{type:`string`,array:!0,description:`IP subnets for this application. Custom application create and update requests accept IPv4 prefix lengths /8 through /32 and IPv6 prefix lengths /32 through /128.`}).option(`name`,{type:`string`,description:`Returns the application name.`}).option(`port-protocols`,{type:`string`,array:!0,description:`Port and protocol pairs matched by the application.`}).option(`support-domains`,{type:`string`,array:!0,description:`Support domains matched by the application.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Defines a custom application. At least one hostname or IP subnet is required. Support domains and port/protocol pairs do not satisfy this requirement. `})}const b={command:`create`,describe:`Create application`,builder:y,handler:async n=>l({command:`accounts applications create`,classification:{safeFlags:[`dry-run`]}},n,async()=>{if(n.dryRun){s({command:`cf accounts applications create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${await t()??`<account-id>`}/resource-library/applications`,pathParams:{},bodyKind:`json`,body:n.body===void 0?p({category_id:n[`category-id`],hostnames:n.hostnames,human_id:m(n[`human-id`],`human-id`,`text`),ip_subnets:n[`ip-subnets`],name:m(n.name,`name`,`text`),port_protocols:n[`port-protocols`],support_domains:n[`support-domains`]}):d(n.body)});return}let i=await a(n),l=n.local?e:await r();if(n.accountId=l,n.body){let e=d(n.body);o(await c(`Creating`,async()=>i.accounts.applications.create({body:e,account_id:l})),{successLabel:`Created`});return}if(n[`category-id`]===void 0)throw Error(`--category-id is required (or pass --body with this field set).`);n[`human-id`]===void 0&&(n[`human-id`]=await h(`human-id`,`Returns the human readable ID.`)),n.name===void 0&&(n.name=await h(`name`,`Returns the application name.`));let u=p({category_id:n[`category-id`],hostnames:n.hostnames,human_id:m(n[`human-id`],`human-id`,`text`),ip_subnets:n[`ip-subnets`],name:m(n.name,`name`,`text`),port_protocols:n[`port-protocols`],support_domains:n[`support-domains`]});o(await c(`Creating`,async()=>i.accounts.applications.create({body:u,account_id:l})),{successLabel:`Created`})})};function x(e){return e.usage(`$0 accounts applications delete <id>
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{i as e}from"./context-5JRcefHh.mjs";import{r as t}from"./auth-3bFlHTVl.mjs";import{t as n}from"./output-CvQFJkvi.mjs";import{t as r}from"./dry-run-Bq0JAsbX.mjs";import{t as i}from"./progress-DUeNqM-j.mjs";import{t as a}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{n as o,t as s}from"./body-parser-hh2avzkz.mjs";import{n as c}from"./input-validation-Dk52b0me.mjs";import{a as l,n as u}from"./prompt-DV6YTdoa.mjs";function d(e){return e.usage(`$0 acm custom-trust-store create
2
+ import{i as e}from"./context-BsGrhAqB.mjs";import{r as t}from"./auth-BYFcxn1F.mjs";import{t as n}from"./output-CvQFJkvi.mjs";import{t as r}from"./dry-run-Bq0JAsbX.mjs";import{t as i}from"./progress-5nsUpQL6.mjs";import{t as a}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{n as o,t as s}from"./body-parser-hh2avzkz.mjs";import{n as c}from"./input-validation-Dk52b0me.mjs";import{a as l,n as u}from"./prompt-Ba_bys2F.mjs";function d(e){return e.usage(`$0 acm custom-trust-store create
3
3
 
4
4
  Upload a root CA certificate to the Custom Origin Trust Store for a Zone. Only root CA certificates are accepted.`).option(`certificate`,{type:`string`,description:`The root CA certificate in PEM format. Only root CA certificates are accepted; intermediate and leaf certificates are not supported.`}).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 f={command:`create`,describe:`Upload Custom Origin Trust Store`,builder:d,handler:async u=>a({command:`acm custom-trust-store create`,classification:{safeFlags:[`dry-run`]}},u,async()=>{if(u.dryRun){r({command:`cf acm custom-trust-store create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${u.zone??u.zoneId??`<zone>`}/acm/custom_trust_store`,pathParams:{"zone-id":String(u.zone??u[`zone-id`]??``)},bodyKind:`json`,body:u.body===void 0?s({certificate:c(u.certificate,`certificate`,`text`)}):o(u.body)});return}let a=await t(u),d=await e({zone:u.zone},a,{quiet:u.quiet});if(u.zoneId=d,u.body){let e=o(u.body);n(await i(`Creating`,async()=>a.acm.customTrustStore.create({...e,zone_id:d})),{successLabel:`Created`});return}u.certificate===void 0&&(u.certificate=await l(`certificate`,`The root CA certificate in PEM format. Only root CA certificates are accepted; intermediate and leaf certificates are not supported.`));let f=s({certificate:c(u.certificate,`certificate`,`text`)});n(await i(`Creating`,async()=>a.acm.customTrustStore.create({...f,zone_id:d})),{successLabel:`Created`})})};function p(e){return e.usage(`$0 acm custom-trust-store delete <custom-origin-trust-store-id>
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{t as e}from"./local-CxYne8s2.mjs";import{a as t,i as n,t as r}from"./context-5JRcefHh.mjs";import{a as i,r as a}from"./auth-3bFlHTVl.mjs";import{t as o}from"./output-CvQFJkvi.mjs";import{t as s}from"./dry-run-Bq0JAsbX.mjs";import{t as c}from"./progress-DUeNqM-j.mjs";import{t as l}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{n as u,r as d,t as f}from"./body-parser-hh2avzkz.mjs";import{n as p,t as m}from"./input-validation-Dk52b0me.mjs";import{a as h,n as g}from"./prompt-DV6YTdoa.mjs";import{n as ee,t as te}from"./raw-fetch-Cp3EaTcj.mjs";function _(e){return e.usage(`$0 addressing address-maps accounts delete <member-account-id>
2
+ import{t as e}from"./local-B3OyWKkW.mjs";import{a as t,i as n,t as r}from"./context-BsGrhAqB.mjs";import{a as i,r as a}from"./auth-BYFcxn1F.mjs";import{t as o}from"./output-CvQFJkvi.mjs";import{t as s}from"./dry-run-Bq0JAsbX.mjs";import{t as c}from"./progress-5nsUpQL6.mjs";import{t as l}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{n as u,r as d,t as f}from"./body-parser-hh2avzkz.mjs";import{n as p,t as m}from"./input-validation-Dk52b0me.mjs";import{a as h,n as g}from"./prompt-Ba_bys2F.mjs";import{n as ee,t as te}from"./raw-fetch-AX_Gz3c3.mjs";function _(e){return e.usage(`$0 addressing address-maps accounts delete <member-account-id>
3
3
 
4
4
  Remove an account as a member of a particular address map.`).positional(`member-account-id`,{type:`string`,description:`Identifier of a Cloudflare account.`,demandOption:!0}).option(`address-map-id`,{type:`string`,description:`Identifier of an Address Map.`,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 v={command:`delete <member-account-id>`,describe:`Remove an account membership from an Address Map`,builder:_,handler:async n=>l({command:`addressing address-maps accounts delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},n,async()=>{if(n.dryRun){s({command:`cf addressing address-maps accounts delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${await t()??`<account-id>`}/addressing/address_maps/${n[`address-map-id`]==null?`<address-map-id>`:encodeURIComponent(String(n[`address-map-id`]))}/accounts/${n[`member-account-id`]==null?`<member-account-id>`:encodeURIComponent(String(n[`member-account-id`]))}`,pathParams:{"address-map-id":String(n[`address-map-id`]??``),"member-account-id":String(n[`member-account-id`]??``)},bodyKind:`none`});return}let i=await a(n),l=n.local?e:await r();if(n.accountId=l,!await g({force:!!n.force})){process.stderr.write(`Aborted.
5
5
  `);return}o(await c(`Deleting`,async()=>i.addressing.addressMaps.accounts.delete({account_id:l,address_map_id:n[`address-map-id`],member_account_id:n[`member-account-id`]})),{successLabel:`Deleted`})})};function y(e){return e.usage(`$0 addressing address-maps accounts update <member-account-id>
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{t as e}from"./local-CxYne8s2.mjs";import{a as t,t as n}from"./context-5JRcefHh.mjs";import{r}from"./auth-3bFlHTVl.mjs";import{t as i}from"./output-CvQFJkvi.mjs";import{t as a}from"./dry-run-Bq0JAsbX.mjs";import{t as o}from"./progress-DUeNqM-j.mjs";import{t as s}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{n as c,r as l,t as u}from"./body-parser-hh2avzkz.mjs";import{n as d}from"./input-validation-Dk52b0me.mjs";import{a as f,n as p}from"./prompt-DV6YTdoa.mjs";import{t as m}from"./cli-types-DoVT5q_M.mjs";function h(e){return e.usage(`$0 agent-memory create-namespace
2
+ import{t as e}from"./local-B3OyWKkW.mjs";import{a as t,t as n}from"./context-BsGrhAqB.mjs";import{r}from"./auth-BYFcxn1F.mjs";import{t as i}from"./output-CvQFJkvi.mjs";import{t as a}from"./dry-run-Bq0JAsbX.mjs";import{t as o}from"./progress-5nsUpQL6.mjs";import{t as s}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{n as c,r as l,t as u}from"./body-parser-hh2avzkz.mjs";import{n as d}from"./input-validation-Dk52b0me.mjs";import{a as f,n as p}from"./prompt-Ba_bys2F.mjs";import{t as m}from"./cli-types-DoVT5q_M.mjs";function h(e){return e.usage(`$0 agent-memory create-namespace
3
3
 
4
4
  Creates a new memory namespace owned by the account.`).option(`name`,{type:`string`,description:`Namespace name.`}).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 g={command:`create-namespace`,describe:`Create a namespace`,builder:h,handler:async l=>s({command:`agent-memory create-namespace`,classification:{safeFlags:[`dry-run`]}},l,async()=>{if(l.dryRun){a({command:`cf agent-memory create-namespace`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${await t()??`<account-id>`}/agent-memory/namespaces`,pathParams:{},bodyKind:`json`,body:l.body===void 0?u({name:d(l.name,`name`,`text`)}):c(l.body)});return}let s=await r(l),p=l.local?e:await n();if(l.accountId=p,l.body){let e=c(l.body);i(await o(`Creating`,async()=>s.agentMemory.createNamespace({...e,account_id:p})),{successLabel:`Created`});return}l.name===void 0&&(l.name=await f(`name`,`Namespace name.`));let m=u({name:d(l.name,`name`,`text`)});i(await o(`Creating`,async()=>s.agentMemory.createNamespace({...m,account_id:p})),{successLabel:`Created`})})};function _(e){return e.usage(`$0 agent-memory delete-memory <memory-id>
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{r as e}from"./theme-BIWQFmZ0.mjs";import{n as t,t as n}from"./local-CxYne8s2.mjs";import{a as r,t as i}from"./context-5JRcefHh.mjs";import{a,o,r as s}from"./auth-3bFlHTVl.mjs";import{t as c}from"./output-CvQFJkvi.mjs";import{t as l}from"./dry-run-Bq0JAsbX.mjs";import{t as u}from"./progress-DUeNqM-j.mjs";import{n as d,t as f}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{n as p,t as m}from"./body-parser-hh2avzkz.mjs";import{n as h,t as g}from"./input-validation-Dk52b0me.mjs";import{a as _,i as v,n as y}from"./prompt-DV6YTdoa.mjs";import{t as b}from"./cli-types-DoVT5q_M.mjs";import{n as x}from"./raw-fetch-Cp3EaTcj.mjs";import{_ as S,c as C,d as w,f as T,g as ee,h as E,i as D,l as O,m as k,n as A,o as j,p as M,r as N,s as P,t as F}from"./schema-flags-yDMur8UR.mjs";const I=`ai-model-schema`;async function L(e,t,n,r){let i=ee(I,[t,e]);if(i)return{ok:!0,schema:i};let a;try{let i=await n();if(r===void 0)a=await i.ai.getModelSchema({account_id:t,model:e});else{let n=r-Date.now();if(n<=0)return{ok:!1,reason:`the request timed out`};a=await i.ai.getModelSchema({account_id:t,model:e},{timeoutInSeconds:n/1e3,maxRetries:0})}}catch(e){return{ok:!1,reason:k(e)}}let o=E(a,`input`);return o?(S(I,[t,e],o),{ok:!0,schema:o}):{ok:!1,reason:`the API returned no input schema`}}const R="Run `cf ai models list` to see the models you can run.",z=[`model-name`,`modelName`];let B;function V(e){return B=e,e.positional(`model-name`,{type:`string`,description:`Model ID, e.g. @cf/meta/llama-3.1-8b-instruct`}).option(`body`,{type:`string`,description:`Raw JSON request body, or @path to a JSON file`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).strictOptions(!1).help(!1).option(`help`,{type:`boolean`,alias:`h`,description:`Show help, including this model's input flags`}).epilogue(`Input flags depend on the model: run \`cf ai run <model> --help\`.\n${R}`)}async function H(n){n.local&&console.log(`${t}\n`),B?.showHelp(`log`);let r=n[`model-name`];if(!r||n.local)return;let i=Date.now()+M,a=await o(i);if(!a){console.log(`\n${e.muted(`Set \`CLOUDFLARE_ACCOUNT_ID\` or sign in with \`cf auth login\` to see the input flags for ${r}.`)}`);return}let c=await L(r,a,()=>s(n),i);console.log(c.ok?`\n${j(C(c.schema),`Input flags for ${r}`)}`:`\n${e.muted(`Could not load the input flags for ${r}: ${c.reason}.`)}`)}var U=d({command:`run [model-name]`,describe:"Run inference on a Workers AI model. Input flags are model-specific — see `cf ai run <model> --help`",builder:V,handler:async e=>{if(e.help){await H(e);return}if(e.local)throw Error(t);let n=e[`model-name`];if(!n)throw Error(`A model is required: cf ai run <model>. ${R}`);let o=e.dryRun?await r()??`<account-id>`:await i(),d=n.split(`/`).map(encodeURIComponent).join(`/`),f;if(e.body!==void 0){if(O(e,z).length>0)throw Error(`--body cannot be combined with model input flags. Pass one or the other.`);f=p(e.body)}else{let t=await L(n,o,()=>s(e));if(!t.ok)throw Error(`Could not load the input schema for ${n}: ${t.reason}.\nPass the request body directly instead: cf ai run ${n} --body '{…}'`);let r=C(t.schema),i=O(e,[...z,...A(r)]);if(i.length>0)throw Error(`${i.map(e=>`Unknown flag --${e}`).join(`
2
+ import{r as e}from"./theme-BIWQFmZ0.mjs";import{n as t,t as n}from"./local-B3OyWKkW.mjs";import{a as r,t as i}from"./context-BsGrhAqB.mjs";import{a,o,r as s}from"./auth-BYFcxn1F.mjs";import{t as c}from"./output-CvQFJkvi.mjs";import{t as l}from"./dry-run-Bq0JAsbX.mjs";import{t as u}from"./progress-5nsUpQL6.mjs";import{n as d,t as f}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{n as p,t as m}from"./body-parser-hh2avzkz.mjs";import{n as h,t as g}from"./input-validation-Dk52b0me.mjs";import{a as _,i as v,n as y}from"./prompt-Ba_bys2F.mjs";import{t as b}from"./cli-types-DoVT5q_M.mjs";import{n as x}from"./raw-fetch-AX_Gz3c3.mjs";import{_ as S,c as C,d as w,f as T,g as ee,h as E,i as D,l as O,m as k,n as A,o as j,p as M,r as N,s as P,t as F}from"./schema-flags-C4KmiKur.mjs";const I=`ai-model-schema`;async function L(e,t,n,r){let i=ee(I,[t,e]);if(i)return{ok:!0,schema:i};let a;try{let i=await n();if(r===void 0)a=await i.ai.getModelSchema({account_id:t,model:e});else{let n=r-Date.now();if(n<=0)return{ok:!1,reason:`the request timed out`};a=await i.ai.getModelSchema({account_id:t,model:e},{timeoutInSeconds:n/1e3,maxRetries:0})}}catch(e){return{ok:!1,reason:k(e)}}let o=E(a,`input`);return o?(S(I,[t,e],o),{ok:!0,schema:o}):{ok:!1,reason:`the API returned no input schema`}}const R="Run `cf ai models list` to see the models you can run.",z=[`model-name`,`modelName`];let B;function V(e){return B=e,e.positional(`model-name`,{type:`string`,description:`Model ID, e.g. @cf/meta/llama-3.1-8b-instruct`}).option(`body`,{type:`string`,description:`Raw JSON request body, or @path to a JSON file`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).strictOptions(!1).help(!1).option(`help`,{type:`boolean`,alias:`h`,description:`Show help, including this model's input flags`}).epilogue(`Input flags depend on the model: run \`cf ai run <model> --help\`.\n${R}`)}async function H(n){n.local&&console.log(`${t}\n`),B?.showHelp(`log`);let r=n[`model-name`];if(!r||n.local)return;let i=Date.now()+M,a=await o(i);if(!a){console.log(`\n${e.muted(`Set \`CLOUDFLARE_ACCOUNT_ID\` or sign in with \`cf auth login\` to see the input flags for ${r}.`)}`);return}let c=await L(r,a,()=>s(n),i);console.log(c.ok?`\n${j(C(c.schema),`Input flags for ${r}`)}`:`\n${e.muted(`Could not load the input flags for ${r}: ${c.reason}.`)}`)}var U=d({command:`run [model-name]`,describe:"Run inference on a Workers AI model. Input flags are model-specific — see `cf ai run <model> --help`",builder:V,handler:async e=>{if(e.help){await H(e);return}if(e.local)throw Error(t);let n=e[`model-name`];if(!n)throw Error(`A model is required: cf ai run <model>. ${R}`);let o=e.dryRun?await r()??`<account-id>`:await i(),d=n.split(`/`).map(encodeURIComponent).join(`/`),f;if(e.body!==void 0){if(O(e,z).length>0)throw Error(`--body cannot be combined with model input flags. Pass one or the other.`);f=p(e.body)}else{let t=await L(n,o,()=>s(e));if(!t.ok)throw Error(`Could not load the input schema for ${n}: ${t.reason}.\nPass the request body directly instead: cf ai run ${n} --body '{…}'`);let r=C(t.schema),i=O(e,[...z,...A(r)]);if(i.length>0)throw Error(`${i.map(e=>`Unknown flag --${e}`).join(`
3
3
  `)}\n\nRun \`cf ai run ${n} --help\` for this model's input flags.`);let a=new Set;for(;;){let t=D(r,e).find(e=>!a.has(e.name)&&(e.choices!==void 0||e.type===`string`));if(!t)break;a.add(t.name),t.choices?e[t.name]=await v(t.name,P(t),t.choices,t.choiceLabels):e[t.name]=await _(t.name,P(t))}let c=N(t.schema),l=F(r,e,{reserved:z}),u=l.errors.length===0?c?w(t.schema,l.body):T(t.schema,l.body):l.errors;if(u.length>0)throw Error(`${u.join(`
4
4
  `)}\n\nRun \`cf ai run ${n} --help\` for this model's input flags.`);f=l.body}if(e.dryRun){l({command:`cf ai run`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${o}/ai/run/${d}`,pathParams:{"model-name":n},bodyKind:`json`,body:f});return}let m=await s(e);e.accountId=o;let h=await u(`Running`,async()=>a(m,`POST`,`/accounts/${o}/ai/run/${d}`,{body:f,preserveNonJsonBytes:!0}));if(Buffer.isBuffer(h)){x(h);return}c(h,{successLabel:`Ran`})}},{command:`ai run`,recordArgs:!1});function W(e){return e.usage(`$0 ai authors list
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{i as e}from"./context-5JRcefHh.mjs";import{a as t,r as n}from"./auth-3bFlHTVl.mjs";import{t as r}from"./output-CvQFJkvi.mjs";import{t as i}from"./dry-run-Bq0JAsbX.mjs";import{t as a}from"./progress-DUeNqM-j.mjs";import{t as o}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{n as s}from"./body-parser-hh2avzkz.mjs";function c(e){return e.usage(`$0 ai-audit robots bulk-get
2
+ import{i as e}from"./context-BsGrhAqB.mjs";import{a as t,r as n}from"./auth-BYFcxn1F.mjs";import{t as r}from"./output-CvQFJkvi.mjs";import{t as i}from"./dry-run-Bq0JAsbX.mjs";import{t as a}from"./progress-5nsUpQL6.mjs";import{t as o}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{n as s}from"./body-parser-hh2avzkz.mjs";function c(e){return e.usage(`$0 ai-audit robots bulk-get
3
3
 
4
4
  Fetches and parses robots.txt files for multiple domains within a zone in a single request. Each domain must belong to the specified zone. Results are keyed by hostname.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Array of domain hostnames to fetch robots.txt for. Each domain must end with the zone name. Maximum 25 domains per request.`})}const l={command:`bulk-get`,describe:`Bulk get robots.txt rules`,builder:c,handler:async c=>o({command:`ai-audit robots bulk-get`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){i({command:`cf ai-audit robots bulk-get`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${c.zone??c.zoneId??`<zone>`}/ai-audit/robots/bulk`,pathParams:{"zone-id":String(c.zone??c[`zone-id`]??``)},bodyKind:`json`,body:c.body===void 0?void 0:s(c.body)});return}let o=await n(c);if(c.zoneId=await e({zone:c.zone},o,{quiet:c.quiet}),c.body){let e=s(c.body);if(Array.isArray(e)&&e.length>25){let n=Math.ceil(e.length/25),i=null;for(let r=0;r<e.length;r+=25){let s=e.slice(r,r+25);i=await a(`Loading: batch ${Math.floor(r/25)+1}/${n}`,async()=>t(o,`POST`,`/zones/${c.zoneId}/ai-audit/robots/bulk`,{body:s}))}r(i,{successLabel:`Loaded`});return}r(await a(`Loading`,async()=>t(o,`POST`,`/zones/${c.zoneId}/ai-audit/robots/bulk`,{body:e})),{successLabel:`Loaded`});return}if(c.body===void 0)throw Error(`--body is required for this command. Pass --body '<json>' or --body @path/to/file.json.`)})};function u(e){return e.usage(`$0 ai-audit robots get
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{t as e}from"./local-CxYne8s2.mjs";import{a as t,t as n}from"./context-5JRcefHh.mjs";import{a as r,r as i}from"./auth-3bFlHTVl.mjs";import{t as a}from"./output-CvQFJkvi.mjs";import{t as o}from"./dry-run-Bq0JAsbX.mjs";import{t as s}from"./progress-DUeNqM-j.mjs";import{t as c}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{i as l,n as u,r as d,t as f}from"./body-parser-hh2avzkz.mjs";import{n as p}from"./input-validation-Dk52b0me.mjs";import{a as m,n as h}from"./prompt-DV6YTdoa.mjs";import{t as g}from"./cli-types-DoVT5q_M.mjs";function ee(e){return e.usage(`$0 ai-gateway custom-domains create <gateway-id>
2
+ import{t as e}from"./local-B3OyWKkW.mjs";import{a as t,t as n}from"./context-BsGrhAqB.mjs";import{a as r,r as i}from"./auth-BYFcxn1F.mjs";import{t as a}from"./output-CvQFJkvi.mjs";import{t as o}from"./dry-run-Bq0JAsbX.mjs";import{t as s}from"./progress-5nsUpQL6.mjs";import{t as c}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{i as l,n as u,r as d,t as f}from"./body-parser-hh2avzkz.mjs";import{n as p}from"./input-validation-Dk52b0me.mjs";import{a as m,n as h}from"./prompt-Ba_bys2F.mjs";import{t as g}from"./cli-types-DoVT5q_M.mjs";function ee(e){return e.usage(`$0 ai-gateway custom-domains create <gateway-id>
3
3
 
4
4
  Provisions a Cloudflare-for-SaaS custom hostname and returns the CNAME target to point DNS at.`).positional(`gateway-id`,{type:`string`,description:`Unique identifier of the AI Gateway within the account.`,demandOption:!0}).option(`domain`,{type:`string`,description:"Custom hostname that you own, such as `ai.example.com`."}).option(`min-tls`,{type:`string`,description:`The minTLS field`,choices:[`1.0`,`1.1`,`1.2`,`1.3`]}).option(`zone-id`,{type:`string`,description:`ID of the Cloudflare zone that contains the custom hostname.`}).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 te={command:`create <gateway-id>`,describe:`Create a custom domain for a gateway`,builder:ee,handler:async r=>c({command:`ai-gateway custom-domains create`,classification:{safeFlags:[`min-tls`,`dry-run`]}},r,async()=>{if(r.dryRun){o({command:`cf ai-gateway custom-domains create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${await t()??`<account-id>`}/ai-gateway/gateways/${r[`gateway-id`]==null?`<gateway-id>`:encodeURIComponent(String(r[`gateway-id`]))}/custom-domains`,pathParams:{"gateway-id":String(r[`gateway-id`]??``)},bodyKind:`json`,body:r.body===void 0?f({domain:p(r.domain,`domain`,`text`),minTLS:p(r[`min-tls`],`min-tls`,`text`),zone_id:p(r[`zone-id`],`zone-id`,`text`)}):u(r.body)});return}let c=await i(r),l=r.local?e:await n();if(r.accountId=l,r.body){let e=u(r.body);a(await s(`Creating`,async()=>c.aiGateway.customDomains.create({...e,account_id:l,gateway_id:r[`gateway-id`]})),{successLabel:`Created`});return}r.domain===void 0&&(r.domain=await m(`domain`,"Custom hostname that you own, such as `ai.example.com`.")),r[`zone-id`]===void 0&&(r[`zone-id`]=await m(`zone-id`,`ID of the Cloudflare zone that contains the custom hostname.`));let d=f({domain:p(r.domain,`domain`,`text`),minTLS:p(r[`min-tls`],`min-tls`,`text`),zone_id:p(r[`zone-id`],`zone-id`,`text`)});a(await s(`Creating`,async()=>c.aiGateway.customDomains.create({...d,account_id:l,gateway_id:r[`gateway-id`]})),{successLabel:`Created`})})};function _(e){return e.usage(`$0 ai-gateway custom-domains delete <hostname>
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{t as e}from"./local-CxYne8s2.mjs";import{a as t,t as n}from"./context-5JRcefHh.mjs";import{a as r,r as i}from"./auth-3bFlHTVl.mjs";import{t as a}from"./output-CvQFJkvi.mjs";import{t as o}from"./dry-run-Bq0JAsbX.mjs";import{t as s}from"./progress-DUeNqM-j.mjs";import{t as c}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{n as l,r as u,t as d}from"./body-parser-hh2avzkz.mjs";import{n as f,t as p}from"./input-validation-Dk52b0me.mjs";import{a as m,i as h,n as g}from"./prompt-DV6YTdoa.mjs";import{t as _}from"./cli-types-DoVT5q_M.mjs";import{n as ee,t as te}from"./raw-fetch-Cp3EaTcj.mjs";function v(e){return e.usage(`$0 ai-search chat-completions <id>
2
+ import{t as e}from"./local-B3OyWKkW.mjs";import{a as t,t as n}from"./context-BsGrhAqB.mjs";import{a as r,r as i}from"./auth-BYFcxn1F.mjs";import{t as a}from"./output-CvQFJkvi.mjs";import{t as o}from"./dry-run-Bq0JAsbX.mjs";import{t as s}from"./progress-5nsUpQL6.mjs";import{t as c}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{n as l,r as u,t as d}from"./body-parser-hh2avzkz.mjs";import{n as f,t as p}from"./input-validation-Dk52b0me.mjs";import{a as m,i as h,n as g}from"./prompt-Ba_bys2F.mjs";import{t as _}from"./cli-types-DoVT5q_M.mjs";import{n as ee,t as te}from"./raw-fetch-AX_Gz3c3.mjs";function v(e){return e.usage(`$0 ai-search chat-completions <id>
3
3
 
4
4
  Performs a chat completion request against an AI Search instance, using indexed content as context for generating responses.`).positional(`id`,{type:`string`,description:`AI Search instance ID.`,demandOption:!0}).option(`name`,{type:`string`,description:`Namespace to use for this operation.`,demandOption:!0}).option(`ai-search-options-cache-cache-threshold`,{type:`string`,description:`The ai_search_options.cache.cache_threshold field`,choices:[`super_strict_match`,`close_enough`,`flexible_friend`,`anything_goes`]}).option(`ai-search-options-cache-enabled`,{type:`boolean`,description:`The ai_search_options.cache.enabled field`}).option(`ai-search-options-query-rewrite-enabled`,{type:`boolean`,description:`The ai_search_options.query_rewrite.enabled field`}).option(`ai-search-options-query-rewrite-model`,{type:`string`,description:`A Workers AI model ID or an AI Gateway model ID compatible with the OpenAI Chat Completions API. An empty string uses the configured or default model.`}).option(`ai-search-options-query-rewrite-rewrite-prompt`,{type:`string`,description:`The ai_search_options.query_rewrite.rewrite_prompt field`}).option(`ai-search-options-reranking-enabled`,{type:`boolean`,description:`The ai_search_options.reranking.enabled field`}).option(`ai-search-options-reranking-match-threshold`,{type:`number`,description:`The ai_search_options.reranking.match_threshold field`}).option(`ai-search-options-reranking-model`,{type:`string`,description:`The ai_search_options.reranking.model field`}).option(`ai-search-options-retrieval-context-expansion`,{type:`number`,description:`The ai_search_options.retrieval.context_expansion field`}).option(`ai-search-options-retrieval-fusion-method`,{type:`string`,description:`The ai_search_options.retrieval.fusion_method field`,choices:[`max`,`rrf`]}).option(`ai-search-options-retrieval-keyword-match-mode`,{type:`string`,description:`Controls which documents are candidates for BM25 scoring. 'and' restricts candidates to documents containing all query terms; 'or' includes any document containing at least one term, ranked by BM25 relevance. When omitted, falls back to the instance-level retrieval_options.keyword_match_mode, then to 'and'.`,choices:[`and`,`or`]}).option(`ai-search-options-retrieval-match-threshold`,{type:`number`,description:`The ai_search_options.retrieval.match_threshold field`}).option(`ai-search-options-retrieval-max-num-results`,{type:`number`,description:`The ai_search_options.retrieval.max_num_results field`}).option(`ai-search-options-retrieval-retrieval-type`,{type:`string`,description:`The ai_search_options.retrieval.retrieval_type field`,choices:[`vector`,`keyword`,`hybrid`]}).option(`ai-search-options-retrieval-return-on-failure`,{type:`boolean`,description:`The ai_search_options.retrieval.return_on_failure field`}).option(`messages`,{type:`string`,description:`The messages field. Provide as a JSON array of objects or @path/to/file.json.`}).option(`model`,{type:`string`,description:`A Workers AI model ID or an AI Gateway model ID compatible with the OpenAI Chat Completions API. An empty string uses the configured or default model.`}).option(`stream`,{type:`boolean`,description:`The stream field`}).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 y={command:`chat-completions <id>`,describe:`Chat Completions`,builder:v,handler:async r=>c({command:`ai-search chat-completions`,classification:{safeFlags:[`ai-search-options-cache-cache-threshold`,`ai-search-options-cache-enabled`,`ai-search-options-query-rewrite-enabled`,`ai-search-options-reranking-enabled`,`ai-search-options-retrieval-fusion-method`,`ai-search-options-retrieval-keyword-match-mode`,`ai-search-options-retrieval-retrieval-type`,`ai-search-options-retrieval-return-on-failure`,`stream`,`dry-run`]}},r,async()=>{if(r.dryRun){o({command:`cf ai-search chat-completions`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${await t()??`<account-id>`}/ai-search/namespaces/${r.name==null?`<name>`:encodeURIComponent(String(r.name))}/instances/${r.id==null?`<id>`:encodeURIComponent(String(r.id))}/chat/completions`,pathParams:{id:String(r.id??``),name:String(r.name??``)},bodyKind:`json`,body:r.body===void 0?d({ai_search_options:{cache:{cache_threshold:f(r[`ai-search-options-cache-cache-threshold`],`ai-search-options-cache-cache-threshold`,`text`),enabled:r[`ai-search-options-cache-enabled`]},query_rewrite:{enabled:r[`ai-search-options-query-rewrite-enabled`],model:f(r[`ai-search-options-query-rewrite-model`],`ai-search-options-query-rewrite-model`,`text`),rewrite_prompt:f(r[`ai-search-options-query-rewrite-rewrite-prompt`],`ai-search-options-query-rewrite-rewrite-prompt`,`text`)},reranking:{enabled:r[`ai-search-options-reranking-enabled`],match_threshold:r[`ai-search-options-reranking-match-threshold`],model:f(r[`ai-search-options-reranking-model`],`ai-search-options-reranking-model`,`text`)},retrieval:{context_expansion:r[`ai-search-options-retrieval-context-expansion`],fusion_method:f(r[`ai-search-options-retrieval-fusion-method`],`ai-search-options-retrieval-fusion-method`,`text`),keyword_match_mode:f(r[`ai-search-options-retrieval-keyword-match-mode`],`ai-search-options-retrieval-keyword-match-mode`,`text`),match_threshold:r[`ai-search-options-retrieval-match-threshold`],max_num_results:r[`ai-search-options-retrieval-max-num-results`],retrieval_type:f(r[`ai-search-options-retrieval-retrieval-type`],`ai-search-options-retrieval-retrieval-type`,`text`),return_on_failure:r[`ai-search-options-retrieval-return-on-failure`]}},messages:u(r.messages,`messages`),model:f(r.model,`model`,`text`),stream:r.stream}):l(r.body)});return}let c=await i(r),p=r.local?e:await n();if(r.accountId=p,r.body){let e=l(r.body);a(await s(`Creating`,async()=>c.aiSearch.chatCompletions({...e,account_id:p,name:r.name,id:r.id})),{successLabel:`Created`});return}if(r.messages===void 0)throw Error(`--messages is required (or pass --body with this field set).`);let m=d({ai_search_options:{cache:{cache_threshold:f(r[`ai-search-options-cache-cache-threshold`],`ai-search-options-cache-cache-threshold`,`text`),enabled:r[`ai-search-options-cache-enabled`]},query_rewrite:{enabled:r[`ai-search-options-query-rewrite-enabled`],model:f(r[`ai-search-options-query-rewrite-model`],`ai-search-options-query-rewrite-model`,`text`),rewrite_prompt:f(r[`ai-search-options-query-rewrite-rewrite-prompt`],`ai-search-options-query-rewrite-rewrite-prompt`,`text`)},reranking:{enabled:r[`ai-search-options-reranking-enabled`],match_threshold:r[`ai-search-options-reranking-match-threshold`],model:f(r[`ai-search-options-reranking-model`],`ai-search-options-reranking-model`,`text`)},retrieval:{context_expansion:r[`ai-search-options-retrieval-context-expansion`],fusion_method:f(r[`ai-search-options-retrieval-fusion-method`],`ai-search-options-retrieval-fusion-method`,`text`),keyword_match_mode:f(r[`ai-search-options-retrieval-keyword-match-mode`],`ai-search-options-retrieval-keyword-match-mode`,`text`),match_threshold:r[`ai-search-options-retrieval-match-threshold`],max_num_results:r[`ai-search-options-retrieval-max-num-results`],retrieval_type:f(r[`ai-search-options-retrieval-retrieval-type`],`ai-search-options-retrieval-retrieval-type`,`text`),return_on_failure:r[`ai-search-options-retrieval-return-on-failure`]}},messages:u(r.messages,`messages`),model:f(r.model,`model`,`text`),stream:r.stream});a(await s(`Creating`,async()=>c.aiSearch.chatCompletions({...m,account_id:p,name:r.name,id:r.id})),{successLabel:`Created`})})};function b(e){return e.usage(`$0 ai-search create <name> <id>
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{i as e}from"./context-5JRcefHh.mjs";import{r as t}from"./auth-3bFlHTVl.mjs";import{t as n}from"./output-CvQFJkvi.mjs";import{t as r}from"./dry-run-Bq0JAsbX.mjs";import{t as i}from"./progress-DUeNqM-j.mjs";import{t as a}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{n as o,r as s,t as c}from"./body-parser-hh2avzkz.mjs";import{n as l}from"./prompt-DV6YTdoa.mjs";function u(e){return e.usage(`$0 ai-security custom-topics get
2
+ import{i as e}from"./context-BsGrhAqB.mjs";import{r as t}from"./auth-BYFcxn1F.mjs";import{t as n}from"./output-CvQFJkvi.mjs";import{t as r}from"./dry-run-Bq0JAsbX.mjs";import{t as i}from"./progress-5nsUpQL6.mjs";import{t as a}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{n as o,r as s,t as c}from"./body-parser-hh2avzkz.mjs";import{n as l}from"./prompt-Ba_bys2F.mjs";function u(e){return e.usage(`$0 ai-security custom-topics get
3
3
 
4
4
  Get the custom topic categories defined for the zone. While AI Security for Apps is enabled, it scores every incoming prompt against these topics and writes the scores to the \`cf.llm.prompt.custom_topic_categories\` field, keyed by topic label. Topics can be configured while the detection is disabled, but no prompt is scored until you enable it.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const d={command:`get`,describe:`Get the AI Security for Apps custom topics of a zone.`,builder:u,handler:async o=>a({command:`ai-security custom-topics get`,classification:{safeFlags:[`dry-run`]}},o,async()=>{if(o.dryRun){r({command:`cf ai-security custom-topics get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${o.zone??o.zoneId??`<zone>`}/ai-security/custom-topics`,pathParams:{"zone-id":String(o.zone??o[`zone-id`]??``)},bodyKind:`none`});return}let a=await t(o),s=await e({zone:o.zone},a,{quiet:o.quiet});o.zoneId=s,n(await i(`Loading`,async()=>a.aiSecurity.customTopics.get({zone_id:s})),{successLabel:`Loaded`})})};function f(e){return e.usage("$0 ai-security custom-topics update\n\nUpdate the custom topic list of the zone, overwriting it entirely with the topics in the request, so include every topic you want to keep. Changes can take up to a minute to propagate. Each entry has a `label`, used to reference the topic in rule expressions and analytics, and a `topic` description, which the classifier scores prompts against while AI Security for Apps is enabled. The following rules apply: - A zone can hold at most 20 topics. - `label` must be 2–20 characters, using only lowercase letters (a–z), digits (0–9), and hyphens. - `topic` must be 2–50 printable ASCII characters. - Labels must be unique within the zone, and so must topic descriptions.").option(`topics`,{type:`string`,description:`Custom topic categories for AI Security for Apps content detection. Provide as a JSON array of objects or @path/to/file.json.`}).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}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const p={command:`update`,describe:`Update the AI Security for Apps custom topics of a zone.`,builder:f,handler:async u=>a({command:`ai-security custom-topics update`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},u,async()=>{if(u.dryRun){r({command:`cf ai-security custom-topics update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${u.zone??u.zoneId??`<zone>`}/ai-security/custom-topics`,pathParams:{"zone-id":String(u.zone??u[`zone-id`]??``)},bodyKind:`json`,body:u.body===void 0?c({topics:s(u.topics,`topics`)}):o(u.body)});return}let a=await t(u),d=await e({zone:u.zone},a,{quiet:u.quiet});if(u.zoneId=d,!await l({force:!!u.force,message:`This operation overwrites the AI Security for Apps custom topics for a zone.`})){process.stderr.write(`Aborted.
5
5
  `);return}if(u.body){let e=o(u.body);n(await i(`Deleting`,async()=>a.aiSecurity.customTopics.update({body:e,zone_id:d})),{successLabel:`Deleted`});return}let f=c({topics:s(u.topics,`topics`)});n(await i(`Deleting`,async()=>a.aiSecurity.customTopics.update({body:f,zone_id:d})),{successLabel:`Deleted`})})},m={command:`custom-topics`,describe:`Organization-specific topic categories used by AI Security for Apps content detection`,builder:e=>e.command(d).command(p).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function h(e){return e.usage(`$0 ai-security get
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{t as e}from"./local-CxYne8s2.mjs";import{a as t,t as n}from"./context-5JRcefHh.mjs";import{r}from"./auth-3bFlHTVl.mjs";import{t as i}from"./output-CvQFJkvi.mjs";import{t as a}from"./dry-run-Bq0JAsbX.mjs";import{t as o}from"./progress-DUeNqM-j.mjs";import{t as s}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{n as c,t as l}from"./body-parser-hh2avzkz.mjs";import{n as u}from"./input-validation-Dk52b0me.mjs";import{a as d,i as f,n as p}from"./prompt-DV6YTdoa.mjs";import{n as m,t as h}from"./raw-fetch-Cp3EaTcj.mjs";function ee(e){return e.usage(`$0 alerting available-alerts list
2
+ import{t as e}from"./local-B3OyWKkW.mjs";import{a as t,t as n}from"./context-BsGrhAqB.mjs";import{r}from"./auth-BYFcxn1F.mjs";import{t as i}from"./output-CvQFJkvi.mjs";import{t as a}from"./dry-run-Bq0JAsbX.mjs";import{t as o}from"./progress-5nsUpQL6.mjs";import{t as s}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{n as c,t as l}from"./body-parser-hh2avzkz.mjs";import{n as u}from"./input-validation-Dk52b0me.mjs";import{a as d,i as f,n as p}from"./prompt-Ba_bys2F.mjs";import{n as m,t as h}from"./raw-fetch-AX_Gz3c3.mjs";function ee(e){return e.usage(`$0 alerting available-alerts list
3
3
 
4
4
  Gets a list of all alert types for which an account is eligible.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const g={command:`list`,describe:`Get Alert Types`,builder:ee,handler:async c=>s({command:`alerting available-alerts list`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){a({command:`cf alerting available-alerts list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await t()??`<account-id>`}/alerting/v3/available_alerts`,pathParams:{},bodyKind:`none`});return}let s=await r(c),l=c.local?e:await n();c.accountId=l,i(await o(`Loading`,async()=>s.alerting.availableAlerts.list({account_id:l})),{successLabel:`Loaded`})})},_={command:`available-alerts`,describe:`Operations for available-alerts`,builder:e=>e.command(g).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function v(e){return e.usage(`$0 alerting destinations eligible get
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{t as e}from"./local-CxYne8s2.mjs";import{a as t,i as n,t as r}from"./context-5JRcefHh.mjs";import{a as i,r as a}from"./auth-3bFlHTVl.mjs";import{t as o}from"./output-CvQFJkvi.mjs";import{t as s}from"./dry-run-Bq0JAsbX.mjs";import{t as c}from"./progress-DUeNqM-j.mjs";import{t as l}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{i as u,n as d,r as f,t as p}from"./body-parser-hh2avzkz.mjs";import{n as m,t as h}from"./input-validation-Dk52b0me.mjs";import{a as g}from"./prompt-DV6YTdoa.mjs";function _(e){return e.usage(`$0 analytics latency colos get
2
+ import{t as e}from"./local-B3OyWKkW.mjs";import{a as t,i as n,t as r}from"./context-BsGrhAqB.mjs";import{a as i,r as a}from"./auth-BYFcxn1F.mjs";import{t as o}from"./output-CvQFJkvi.mjs";import{t as s}from"./dry-run-Bq0JAsbX.mjs";import{t as c}from"./progress-5nsUpQL6.mjs";import{t as l}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{i as u,n as d,r as f,t as p}from"./body-parser-hh2avzkz.mjs";import{n as m,t as h}from"./input-validation-Dk52b0me.mjs";import{a as g}from"./prompt-Ba_bys2F.mjs";function _(e){return e.usage(`$0 analytics latency colos get
3
3
 
4
4
  Retrieves Argo Smart Routing analytics broken down by geographic points of presence (PoPs). Shows latency improvements and routing efficiency per location.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const v={command:`get`,describe:`Argo Analytics for a zone at different PoPs`,builder:_,handler:async e=>l({command:`analytics latency colos get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){s({command:`cf analytics latency colos get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/analytics/latency/colos`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await a(e),r=await n({zone:e.zone},t,{quiet:e.quiet});e.zoneId=r,o(await c(`Loading`,async()=>t.analytics.latency.colos.get({zone_id:r})),{successLabel:`Loaded`})})},y={command:`colos`,describe:`Operations for latency.colos`,builder:e=>e.command(v).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function b(e){return e.usage(`$0 analytics latency get
5
5
 
@@ -18,4 +18,4 @@ Returns the top N results for a dataset by a specified stat. Includes an array o
18
18
 
19
19
  Executes a SQL query against the analytics datasets available to the caller. Send either raw SQL or a JSON object containing the query and optional positional or named parameters, time range, and account or zone scope. Raw SQL placeholders can also be bound with query parameters named \`param_<name>\`.`).option(`query`,{type:`string`,description:`SQL query to execute.`}).option(`scope-account-tag`,{type:`string`,description:`Account tag used to authorize and scope the query. Must be a 32-character lowercase hex string.
20
20
  `}).option(`scope-zone-tag`,{type:`string`,description:`Zone tag used to authorize and scope the query. Must be a 32-character lowercase hex string.
21
- `}).option(`time-range-end`,{type:`string`,description:`Inclusive upper bound for the dataset's timestamp column.`}).option(`time-range-start`,{type:`string`,description:`Inclusive lower bound for the dataset's timestamp column.`}).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)`}).option(`file`,{type:`string`,description:`Path to a file to upload as the request body`}).conflicts(`scope-account-tag`,[`scope-zone-tag`]).conflicts(`scope-zone-tag`,[`scope-account-tag`]).check(e=>{if([`time-range-end`,`time-range-start`].some(t=>e[t]!==void 0)){let t=[`time-range-start`].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 --time_range-* flag is set`)}return!0})}const G={command:`post`,describe:`Query analytics datasets`,builder:W,handler:async e=>l({command:`analytics sql post`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){s({command:`cf analytics sql post`,method:`POST`,url:`https://api.cloudflare.com/client/v4/analytics/sql`,pathParams:{},bodyKind:`json`,body:e.body===void 0?p({query:m(e.query,`query`,`text`),scope:{accountTag:m(e[`scope-account-tag`],`scope-account-tag`,`text`),zoneTag:m(e[`scope-zone-tag`],`scope-zone-tag`,`text`)},time_range:{end:m(e[`time-range-end`],`time-range-end`,`text`),start:m(e[`time-range-start`],`time-range-start`,`text`)}}):d(e.body)});return}let t=await a(e);if(e.file){let n=h(e.file);o(await c(`Creating`,async()=>i(t,`POST`,`/analytics/sql`,{body:n,headers:{"Content-Type":`text/plain`}})),{successLabel:`Created`});return}if(e.body){let n=d(e.body);o(await c(`Creating`,async()=>i(t,`POST`,`/analytics/sql`,{body:n})),{successLabel:`Created`});return}e.query===void 0&&(e.query=await g(`query`,`SQL query to execute.`));let n={};e.query!==void 0&&u(n,[`query`],m(e.query,`query`,`text`)),e[`scope-account-tag`]!==void 0&&u(n,[`scope`,`accountTag`],m(e[`scope-account-tag`],`scope-account-tag`,`text`)),e[`scope-zone-tag`]!==void 0&&u(n,[`scope`,`zoneTag`],m(e[`scope-zone-tag`],`scope-zone-tag`,`text`)),e[`time-range-end`]!==void 0&&u(n,[`time_range`,`end`],m(e[`time-range-end`],`time-range-end`,`text`)),e[`time-range-start`]!==void 0&&u(n,[`time_range`,`start`],m(e[`time-range-start`],`time-range-start`,`text`)),o(await c(`Creating`,async()=>i(t,`POST`,`/analytics/sql`,{body:Object.keys(n).length>0?n:void 0})),{successLabel:`Created`})})},K={command:`sql`,describe:`Operations for sql`,builder:e=>e.command(B).command(G).command(U).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},q={command:`analytics`,describe:`Zone-level traffic analytics — dashboard summaries, per-colo breakdowns, and Argo latency metrics`,builder:e=>e.command(S).command(R).command(K).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{q as default};
21
+ `}).option(`time-range-end`,{type:`string`,description:`Inclusive upper bound for the dataset's timestamp column.`}).option(`time-range-start`,{type:`string`,description:`Inclusive lower bound for the dataset's timestamp column.`}).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)`}).option(`file`,{type:`string`,description:`Path to a file to upload as the request body`}).conflicts(`scope-account-tag`,[`scope-zone-tag`]).conflicts(`scope-zone-tag`,[`scope-account-tag`]).check(e=>{if([`time-range-end`,`time-range-start`].some(t=>e[t]!==void 0)){let t=[`time-range-start`].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 --time_range-* flag is set`)}return!0})}const G={command:`post`,describe:`Query analytics datasets`,builder:W,handler:async e=>l({command:`analytics sql post`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){s({command:`cf analytics sql post`,method:`POST`,url:`https://api.cloudflare.com/client/v4/analytics/sql`,pathParams:{},bodyKind:e.file===void 0?`json`:`octet-stream`,body:e.file===void 0?e.body===void 0?p({query:m(e.query,`query`,`text`),scope:{accountTag:m(e[`scope-account-tag`],`scope-account-tag`,`text`),zoneTag:m(e[`scope-zone-tag`],`scope-zone-tag`,`text`)},time_range:{end:m(e[`time-range-end`],`time-range-end`,`text`),start:m(e[`time-range-start`],`time-range-start`,`text`)}}):d(e.body):{file:e.file}});return}let t=await a(e);if(e.file){let n=h(e.file);o(await c(`Creating`,async()=>i(t,`POST`,`/analytics/sql`,{body:n,headers:{"Content-Type":`text/plain`}})),{successLabel:`Created`});return}if(e.body){let n=d(e.body);o(await c(`Creating`,async()=>i(t,`POST`,`/analytics/sql`,{body:n})),{successLabel:`Created`});return}e.query===void 0&&(e.query=await g(`query`,`SQL query to execute.`));let n={};e.query!==void 0&&u(n,[`query`],m(e.query,`query`,`text`)),e[`scope-account-tag`]!==void 0&&u(n,[`scope`,`accountTag`],m(e[`scope-account-tag`],`scope-account-tag`,`text`)),e[`scope-zone-tag`]!==void 0&&u(n,[`scope`,`zoneTag`],m(e[`scope-zone-tag`],`scope-zone-tag`,`text`)),e[`time-range-end`]!==void 0&&u(n,[`time_range`,`end`],m(e[`time-range-end`],`time-range-end`,`text`)),e[`time-range-start`]!==void 0&&u(n,[`time_range`,`start`],m(e[`time-range-start`],`time-range-start`,`text`)),o(await c(`Creating`,async()=>i(t,`POST`,`/analytics/sql`,{body:Object.keys(n).length>0?n:void 0})),{successLabel:`Created`})})},K={command:`sql`,describe:`Operations for sql`,builder:e=>e.command(B).command(G).command(U).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},q={command:`analytics`,describe:`Zone-level traffic analytics — dashboard summaries, per-colo breakdowns, and Argo latency metrics`,builder:e=>e.command(S).command(R).command(K).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{q as default};
@@ -1,4 +1,4 @@
1
1
  #!/usr/bin/env node
2
- import{t as e}from"./local-CxYne8s2.mjs";import{a as t,t as n}from"./context-5JRcefHh.mjs";import{a as r,r as i}from"./auth-3bFlHTVl.mjs";import{t as a}from"./output-CvQFJkvi.mjs";import{t as o}from"./dry-run-Bq0JAsbX.mjs";import{t as s}from"./progress-DUeNqM-j.mjs";import{t as c}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{n as l,t as u}from"./input-validation-Dk52b0me.mjs";function d(e){return e.usage(`$0 analytics_engine sql query
2
+ import{t as e}from"./local-B3OyWKkW.mjs";import{a as t,t as n}from"./context-BsGrhAqB.mjs";import{a as r,r as i}from"./auth-BYFcxn1F.mjs";import{t as a}from"./output-CvQFJkvi.mjs";import{t as o}from"./dry-run-Bq0JAsbX.mjs";import{t as s}from"./progress-5nsUpQL6.mjs";import{t as c}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{n as l,t as u}from"./input-validation-Dk52b0me.mjs";function d(e){return e.usage(`$0 analytics_engine sql query
3
3
 
4
4
  Executes a SQL query against Workers Analytics Engine data. Pass the SQL query in the request body as plain text. The response uses newline-delimited JSON (NDJSON) by default, or a single JSON object when the query includes a FORMAT JSON clause. Prefer this method for longer queries that may exceed URL length limits.`).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)`}).option(`file`,{type:`string`,description:`Path to a file to upload as the request body`})}const f={command:`query`,describe:`Execute an Analytics Engine SQL query via request body`,builder:d,handler:async d=>c({command:`analytics_engine sql query`,classification:{safeFlags:[`dry-run`]}},d,async()=>{if(d.dryRun){o({command:`cf analytics_engine sql query`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${await t()??`<account-id>`}/analytics_engine/sql`,pathParams:{},bodyKind:`octet-stream`,body:d.body});return}let c=await i(d),f=d.local?e:await n();if(d.accountId=f,d.file){let e=u(d.file);a(await s(`Loading`,async()=>r(c,`POST`,`/accounts/${f}/analytics_engine/sql`,{body:e,headers:{"Content-Type":`text/plain`}})),{successLabel:`Loaded`});return}if(d.body){let e=l(d.body,`body`,`binary`);a(await s(`Loading`,async()=>r(c,`POST`,`/accounts/${f}/analytics_engine/sql`,{body:e,headers:{"Content-Type":`text/plain`}})),{successLabel:`Loaded`});return}a(await s(`Loading`,async()=>c.analyticsEngine.sql.query({account_id:f})),{successLabel:`Loaded`})})},p={command:`sql`,describe:`Operations for sql`,builder:e=>e.command(f).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},m={command:`analytics_engine`,describe:`analytics_engine`,builder:e=>e.command(p).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{m as default};
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{t as e}from"./local-CxYne8s2.mjs";import{a as t,i as n,t as r}from"./context-5JRcefHh.mjs";import{a as i,r as a}from"./auth-3bFlHTVl.mjs";import{t as o}from"./output-CvQFJkvi.mjs";import{t as s}from"./dry-run-Bq0JAsbX.mjs";import{t as c}from"./progress-DUeNqM-j.mjs";import{t as l}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{n as u,r as d,t as f}from"./body-parser-hh2avzkz.mjs";import{n as p}from"./input-validation-Dk52b0me.mjs";import{a as m,i as h,n as g}from"./prompt-DV6YTdoa.mjs";import{t as _}from"./cli-types-DoVT5q_M.mjs";function ee(e){return e.usage(`$0 api-security schema-validation schemas create
2
+ import{t as e}from"./local-B3OyWKkW.mjs";import{a as t,i as n,t as r}from"./context-BsGrhAqB.mjs";import{a as i,r as a}from"./auth-BYFcxn1F.mjs";import{t as o}from"./output-CvQFJkvi.mjs";import{t as s}from"./dry-run-Bq0JAsbX.mjs";import{t as c}from"./progress-5nsUpQL6.mjs";import{t as l}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{n as u,r as d,t as f}from"./body-parser-hh2avzkz.mjs";import{n as p}from"./input-validation-Dk52b0me.mjs";import{a as m,i as h,n as g}from"./prompt-Ba_bys2F.mjs";import{t as _}from"./cli-types-DoVT5q_M.mjs";function ee(e){return e.usage(`$0 api-security schema-validation schemas create
3
3
 
4
4
  Uploads an OpenAPI schema that defines expected request formats for API operations.`).option(`kind`,{type:`string`,description:`The kind of the schema`,choices:[`openapi_v3`]}).option(`name`,{type:`string`,description:`A human-readable name for the schema`}).option(`source`,{type:`string`,description:`The raw schema, e.g., the OpenAPI schema, either as JSON or YAML`}).option(`validation-enabled`,{type:`boolean`,description:`An indicator if this schema is enabled`}).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 te={command:`create`,describe:`Upload a schema`,builder:ee,handler:async e=>l({command:`api-security schema-validation schemas create`,classification:{safeFlags:[`kind`,`validation-enabled`,`dry-run`]}},e,async()=>{if(e.dryRun){s({command:`cf api-security schema-validation schemas create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/schema_validation/schemas`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?f({kind:p(e.kind,`kind`,`text`),name:p(e.name,`name`,`text`),source:p(e.source,`source`,`text`),validation_enabled:e[`validation-enabled`]}):u(e.body)});return}let t=await a(e),r=await n({zone:e.zone},t,{quiet:e.quiet});if(e.zoneId=r,e.body){let n=u(e.body);o(await c(`Creating`,async()=>t.apiSecurity.schemaValidation.schemas.create({...n,zone_id:r})),{successLabel:`Created`});return}if(e.kind===void 0&&(e.kind=await h(`kind`,`The kind of the schema`,[`openapi_v3`])),e.name===void 0&&(e.name=await m(`name`,`A human-readable name for the schema`)),e.source===void 0&&(e.source=await m(`source`,`The raw schema, e.g., the OpenAPI schema, either as JSON or YAML`)),e[`validation-enabled`]===void 0)throw Error(`--validation-enabled is required (or pass --body with this field set).`);let i=f({kind:p(e.kind,`kind`,`text`),name:p(e.name,`name`,`text`),source:p(e.source,`source`,`text`),validation_enabled:e[`validation-enabled`]});o(await c(`Creating`,async()=>t.apiSecurity.schemaValidation.schemas.create({...i,zone_id:r})),{successLabel:`Created`})})};function v(e){return e.usage(`$0 api-security schema-validation schemas delete <schema-id>
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{i as e}from"./context-5JRcefHh.mjs";import{r as t}from"./auth-3bFlHTVl.mjs";import{t as n}from"./output-CvQFJkvi.mjs";import{t as r}from"./dry-run-Bq0JAsbX.mjs";import{t as i}from"./progress-DUeNqM-j.mjs";import{t as a}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{n as o,t as s}from"./body-parser-hh2avzkz.mjs";import{n as c}from"./input-validation-Dk52b0me.mjs";import{i as l}from"./prompt-DV6YTdoa.mjs";function u(e){return e.usage(`$0 argo smart-routing edit
2
+ import{i as e}from"./context-BsGrhAqB.mjs";import{r as t}from"./auth-BYFcxn1F.mjs";import{t as n}from"./output-CvQFJkvi.mjs";import{t as r}from"./dry-run-Bq0JAsbX.mjs";import{t as i}from"./progress-5nsUpQL6.mjs";import{t as a}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{n as o,t as s}from"./body-parser-hh2avzkz.mjs";import{n as c}from"./input-validation-Dk52b0me.mjs";import{i as l}from"./prompt-Ba_bys2F.mjs";function u(e){return e.usage(`$0 argo smart-routing edit
3
3
 
4
4
  Configures the value of the Argo Smart Routing enablement setting.`).option(`value`,{type:`string`,description:`Specifies the enablement value of Argo Smart Routing.`,choices:[`on`,`off`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Configures the enablement of Argo Smart Routing.`})}const d={command:`edit`,describe:`Patch Argo Smart Routing setting`,builder:u,handler:async u=>a({command:`argo smart-routing edit`,classification:{safeFlags:[`value`,`dry-run`]}},u,async()=>{if(u.dryRun){r({command:`cf argo smart-routing edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/zones/${u.zone??u.zoneId??`<zone>`}/argo/smart_routing`,pathParams:{"zone-id":String(u.zone??u[`zone-id`]??``)},bodyKind:`json`,body:u.body===void 0?s({value:c(u.value,`value`,`text`)}):o(u.body)});return}let a=await t(u),d=await e({zone:u.zone},a,{quiet:u.quiet});if(u.zoneId=d,u.body){let e=o(u.body);n(await i(`Updating`,async()=>a.argo.smartRouting.edit({...e,zone_id:d})),{successLabel:`Updated`});return}u.value===void 0&&(u.value=await l(`value`,`Specifies the enablement value of Argo Smart Routing.`,[`on`,`off`]));let f=s({value:c(u.value,`value`,`text`)});n(await i(`Updating`,async()=>a.argo.smartRouting.edit({...f,zone_id:d})),{successLabel:`Updated`})})};function f(e){return e.usage(`$0 argo smart-routing get
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{t as e}from"./local-CxYne8s2.mjs";import{a as t,t as n}from"./context-5JRcefHh.mjs";import{r}from"./auth-3bFlHTVl.mjs";import{t as i}from"./output-CvQFJkvi.mjs";import{t as a}from"./dry-run-Bq0JAsbX.mjs";import{t as o}from"./progress-DUeNqM-j.mjs";import{t as s}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{n as c,t as l}from"./body-parser-hh2avzkz.mjs";import{n as u}from"./input-validation-Dk52b0me.mjs";import{a as d,n as f}from"./prompt-DV6YTdoa.mjs";import{t as p}from"./cli-types-DoVT5q_M.mjs";import{n as m,t as h}from"./raw-fetch-Cp3EaTcj.mjs";function ee(e){return e.usage(`$0 artifacts namespaces create
2
+ import{t as e}from"./local-B3OyWKkW.mjs";import{a as t,t as n}from"./context-BsGrhAqB.mjs";import{r}from"./auth-BYFcxn1F.mjs";import{t as i}from"./output-CvQFJkvi.mjs";import{t as a}from"./dry-run-Bq0JAsbX.mjs";import{t as o}from"./progress-5nsUpQL6.mjs";import{t as s}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{n as c,t as l}from"./body-parser-hh2avzkz.mjs";import{n as u}from"./input-validation-Dk52b0me.mjs";import{a as d,n as f}from"./prompt-Ba_bys2F.mjs";import{t as p}from"./cli-types-DoVT5q_M.mjs";import{n as m,t as h}from"./raw-fetch-AX_Gz3c3.mjs";function ee(e){return e.usage(`$0 artifacts namespaces create
3
3
 
4
4
  Creates an empty Artifacts namespace for an account.`).option(`jurisdiction`,{type:`string`,description:`The jurisdiction field`,choices:[`unrestricted`,`us`,`eu`,`fedramp`],default:`unrestricted`}).option(`namespace`,{type:`string`,description:`The namespace field`}).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 g={command:`create`,describe:`Create a namespace`,builder:ee,handler:async f=>s({command:`artifacts namespaces create`,classification:{safeFlags:[`jurisdiction`,`dry-run`]}},f,async()=>{if(f.dryRun){a({command:`cf artifacts namespaces create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${await t()??`<account-id>`}/artifacts/namespaces`,pathParams:{},bodyKind:`json`,body:f.body===void 0?l({jurisdiction:u(f.jurisdiction,`jurisdiction`,`text`),namespace:u(f.namespace,`namespace`,`text`)}):c(f.body)});return}let s=await r(f),p=f.local?e:await n();if(f.accountId=p,f.body){let e=c(f.body);i(await o(`Creating`,async()=>s.artifacts.namespaces.create({...e,account_id:p})),{successLabel:`Created`});return}f.namespace===void 0&&(f.namespace=await d(`namespace`,`The namespace field`));let m=l({jurisdiction:u(f.jurisdiction,`jurisdiction`,`text`),namespace:u(f.namespace,`namespace`,`text`)});i(await o(`Creating`,async()=>s.artifacts.namespaces.create({...m,account_id:p})),{successLabel:`Created`})})};function _(e){return e.usage(`$0 artifacts namespaces delete <namespace>
5
5
 
@@ -1,4 +1,4 @@
1
1
  #!/usr/bin/env node
2
- import{t as e}from"./local-CxYne8s2.mjs";import{a as t,t as n}from"./context-5JRcefHh.mjs";import{r}from"./auth-3bFlHTVl.mjs";import{t as i}from"./output-CvQFJkvi.mjs";import{t as a}from"./dry-run-Bq0JAsbX.mjs";import{t as o}from"./progress-DUeNqM-j.mjs";import{t as s}from"./run-BhfDNWCI.mjs";import"./telemetry-iBZ-f6og.mjs";import{t as c}from"./cli-types-DoVT5q_M.mjs";function l(e){return e.usage(`$0 audit-logs list
2
+ import{t as e}from"./local-B3OyWKkW.mjs";import{a as t,t as n}from"./context-BsGrhAqB.mjs";import{r}from"./auth-BYFcxn1F.mjs";import{t as i}from"./output-CvQFJkvi.mjs";import{t as a}from"./dry-run-Bq0JAsbX.mjs";import{t as o}from"./progress-5nsUpQL6.mjs";import{t as s}from"./run-UHTbUldP.mjs";import"./telemetry-C3hmM9Q9.mjs";import{t as c}from"./cli-types-DoVT5q_M.mjs";function l(e){return e.usage(`$0 audit-logs list
3
3
 
4
4
  Gets a list of audit logs for an account. Can be filtered by who made the change, on which zone, and the timeframe of the change.`).option(`id`,{type:`string`,description:`Finds a specific log by its ID.`}).option(`export`,{type:`boolean`,description:`Indicates that this request is an export of logs in CSV format.`}).option(`action-type`,{type:`string`,description:`Filters by the action type.`}).option(`actor-ip`,{type:`string`,description:`Filters by the IP address of the request that made the change by specific IP address or valid CIDR Range.`}).option(`actor-email`,{type:`string`,description:`Filters by the email address of the actor that made the change.`}).option(`since`,{type:`string`,description:"Limits the returned results to logs newer than the specified date. A `full-date` that conforms to RFC3339."}).option(`before`,{type:`string`,description:"Limits the returned results to logs older than the specified date. A `full-date` that conforms to RFC3339."}).option(`zone-name`,{type:`string`,description:`Filters by the name of the zone associated to the change.`}).option(`direction`,{type:`string`,description:`Changes the direction of the chronological sorting.`,choices:[`desc`,`asc`]}).option(`per-page`,{type:`number`,description:`Sets the number of results to return per page.`}).option(`page`,{type:`number`,description:`Defines which page of results to return.`}).option(`hide-user-logs`,{type:`boolean`,description:`Indicates whether or not to hide user level audit logs.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const u={command:`list`,describe:`Get account audit logs`,builder:c(l),handler:async c=>s({command:`audit-logs list`,classification:{safeFlags:[`export`,`direction`,`hide-user-logs`,`dry-run`]}},c,async()=>{let s={id:c.id,export:c.export,"action.type":c[`action-type`],"actor.ip":c[`actor-ip`],"actor.email":c[`actor-email`],since:c.since,before:c.before,"zone.name":c[`zone-name`],direction:c.direction,per_page:c[`per-page`],page:c.page,hide_user_logs:c[`hide-user-logs`]};if(c.dryRun){a({command:`cf audit-logs list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await t()??`<account-id>`}/audit_logs`,pathParams:{},query:s,bodyKind:`none`});return}let l=await r(c),u=c.local?e:await n();c.accountId=u,i(await o(`Loading`,async()=>l.auditLogs.list({account_id:u,...s})),{successLabel:`Loaded`})})},d={command:`audit-logs`,describe:`audit-logs`,builder:e=>e.command(u).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{d as default};
@@ -1,8 +1,8 @@
1
1
  #!/usr/bin/env node
2
- import{n as e,r as t,t as n}from"./sdk-Bx29ZKK3.mjs";import{G as r}from"./dist-DfMipWKR.mjs";import{o as i}from"./chunk-RV27PEH3-Cws_30ln.mjs";import{a,n as o}from"./context-5JRcefHh.mjs";import{s}from"./oauth-BYmfy7l7.mjs";import{n as c}from"./request-headers-jdUlF-_S.mjs";const l=3e4,u=e.Default;function d(e){return e instanceof FormData||e instanceof Blob||e instanceof ArrayBuffer||ArrayBuffer.isView(e)||e instanceof ReadableStream||e instanceof URLSearchParams}function f(e){return Object.keys(e).some(e=>e.toLowerCase()===`content-type`)}async function p(e){let t=e.headers.get(`content-type`)??``;try{return t.includes(`application/json`)?await e.json():await e.text()}catch{return null}}function m(e,t,n){if(!(n==null||n===``)){if(Array.isArray(n)){for(let r of n)m(e,t,r);return}e.append(t,String(n))}}function h(e){let t=new URLSearchParams;for(let[n,r]of Object.entries(e))m(t,n,r);return t.toString()}function g(e,t,n){let r=new URL(t.endsWith(`/`)?t:`${t}/`),i=new URL(e.startsWith(`/`)?e.slice(1):e,r);if(i.origin!==r.origin)throw Error(`Refusing to send an authenticated request to ${i.origin} (expected ${r.origin})`);let a=h(n??{});return a&&(i.search=a),i.toString()}const _=new WeakMap;async function v(e,n,r,i={}){let a=g(r,_.get(e)??u,i.query),o={...i.headers},s;i.body!==void 0&&(d(i.body)||typeof i.body==`string`&&f(o)?s=i.body:(o[`Content-Type`]??=`application/json`,s=JSON.stringify(i.body)));let c;try{c=await e.fetch(a,{method:n,headers:o,body:s,signal:i.signal},{timeoutInSeconds:i.timeout?i.timeout/1e3:void 0,abortSignal:i.signal})}catch(e){throw i.signal?.aborted?Error(`Request aborted`):e instanceof Error&&e.name===`AbortError`?Error(`Request timed out after ${i.timeout??3e4}ms`):e instanceof Error?Error(`Request failed: ${e.message}`):e}if(!c.ok)throw new t({statusCode:c.status,body:await p(c),rawResponse:{status:c.status,statusText:c.statusText,url:c.url||a,headers:c.headers,redirected:c.redirected,type:c.type}});if(c.status===204)return null;let l=c.headers.get(`content-type`)??``;if(!l.includes(`application/json`)&&i.preserveNonJsonBytes)return Buffer.from(await c.arrayBuffer());let m=await c.text();if(m===``)return null;if(!l.includes(`application/json`))return m;let h=JSON.parse(m);if(h.success===!1)throw new t({message:`API error: ${h.errors?.map(e=>e.message).filter(Boolean).join(`, `)||`unknown error`}`,statusCode:c.status,body:h});return`result`in h?h.result:h}function y(e){let t=e.baseURL??u,r=new n({baseUrl:t,auth:async()=>({headers:{Authorization:`Bearer ${e.apiToken}`}}),headers:e.defaultHeaders,timeoutInSeconds:(e.timeout??3e4)/1e3,maxRetries:0,fetch:e.fetch??globalThis.fetch});return _.set(r,t),r}async function b(){let e=i({allowGlobalAuthKey:!1});if(e&&`apiToken`in e)return e.apiToken;let t=await s();if(t)return t;throw Error(`No authentication token found.
2
+ import{n as e,r as t,t as n}from"./sdk-Bx29ZKK3.mjs";import{G as r}from"./dist-DfMipWKR.mjs";import{o as i}from"./chunk-RV27PEH3-Cws_30ln.mjs";import{a,n as o}from"./context-BsGrhAqB.mjs";import{s}from"./oauth-DJW_HyaL.mjs";import{n as c}from"./request-headers-sc4CaZX0.mjs";const l=3e4,u=e.Default;function d(e){return e instanceof FormData||e instanceof Blob||e instanceof ArrayBuffer||ArrayBuffer.isView(e)||e instanceof ReadableStream||e instanceof URLSearchParams}function f(e){return Object.keys(e).some(e=>e.toLowerCase()===`content-type`)}async function p(e){let t=e.headers.get(`content-type`)??``;try{return t.includes(`application/json`)?await e.json():await e.text()}catch{return null}}function m(e,t,n){if(!(n==null||n===``)){if(Array.isArray(n)){for(let r of n)m(e,t,r);return}e.append(t,String(n))}}function h(e){let t=new URLSearchParams;for(let[n,r]of Object.entries(e))m(t,n,r);return t.toString()}function g(e,t,n){let r=new URL(t.endsWith(`/`)?t:`${t}/`),i=new URL(e.startsWith(`/`)?e.slice(1):e,r);if(i.origin!==r.origin)throw Error(`Refusing to send an authenticated request to ${i.origin} (expected ${r.origin})`);let a=h(n??{});return a&&(i.search=a),i.toString()}const _=new WeakMap;async function v(e,n,r,i={}){let a=g(r,_.get(e)??u,i.query),o={...i.headers},s;i.body!==void 0&&(d(i.body)||typeof i.body==`string`&&f(o)?s=i.body:(o[`Content-Type`]??=`application/json`,s=JSON.stringify(i.body)));let c;try{c=await e.fetch(a,{method:n,headers:o,body:s,signal:i.signal},{timeoutInSeconds:i.timeout?i.timeout/1e3:void 0,abortSignal:i.signal})}catch(e){throw i.signal?.aborted?Error(`Request aborted`):e instanceof Error&&e.name===`AbortError`?Error(`Request timed out after ${i.timeout??3e4}ms`):e instanceof Error?Error(`Request failed: ${e.message}`):e}if(!c.ok)throw new t({statusCode:c.status,body:await p(c),rawResponse:{status:c.status,statusText:c.statusText,url:c.url||a,headers:c.headers,redirected:c.redirected,type:c.type}});if(c.status===204)return null;let l=c.headers.get(`content-type`)??``;if(!l.includes(`application/json`)&&i.preserveNonJsonBytes)return Buffer.from(await c.arrayBuffer());let m=await c.text();if(m===``)return null;if(!l.includes(`application/json`))return m;let h=JSON.parse(m);if(h.success===!1)throw new t({message:`API error: ${h.errors?.map(e=>e.message).filter(Boolean).join(`, `)||`unknown error`}`,statusCode:c.status,body:h});return`result`in h?h.result:h}function y(e){let t=e.baseURL??u,r=new n({baseUrl:t,auth:async()=>({headers:{Authorization:`Bearer ${e.apiToken}`}}),headers:e.defaultHeaders,timeoutInSeconds:(e.timeout??3e4)/1e3,maxRetries:0,fetch:e.fetch??globalThis.fetch});return _.set(r,t),r}async function b(){let e=i({allowGlobalAuthKey:!1});if(e&&`apiToken`in e)return e.apiToken;let t=await s();if(t)return t;throw Error(`No authentication token found.
3
3
 
4
4
  Please set one of the following:
5
5
  1. Set the CLOUDFLARE_API_TOKEN environment variable
6
6
  2. Run 'cf auth login' to authenticate via OAuth
7
7
 
8
- For API tokens, visit: https://dash.cloudflare.com/profile/api-tokens`)}async function x(e){let t=await a();if(t)return t;try{let t=await b(),n=r({compliance_region:await o()}),i=e-Date.now();if(i<=0)return;let a=y({apiToken:t,baseURL:n,defaultHeaders:c()}),s={timeoutInSeconds:i/1e3,maxRetries:0},[l,u]=await Promise.allSettled([a.accounts.list({per_page:50},s),a.user.memberships.list({per_page:50},s)]);if(l.status===`rejected`)return;let d=l.value;if((d.result_info?.total_count??d.result.length)>d.result.length)return;let f=d.result;if(u.status===`fulfilled`){let e=u.value.result??[];if((u.value.result_info?.total_count??e.length)>e.length)return;let t=new Set(e.map(e=>e.account?.id).filter(e=>e!==void 0));f=f.filter(e=>t.has(e.id))}return f.length===1?f[0]?.id:void 0}catch{return}}async function S(e){let t=r({compliance_region:await o()});if(e.local){let{createLocalFetch:n}=await import(`./local-22UA5g9y.mjs`);return y({apiToken:`cf-local-mode-no-auth`,baseURL:t,defaultHeaders:c(),fetch:n({persistTo:e.persistTo,apiBaseUrl:t})})}return y({apiToken:await b(),baseURL:t,defaultHeaders:c()})}export{v as a,b as i,y as n,x as o,S as r,l as t};
8
+ For API tokens, visit: https://dash.cloudflare.com/profile/api-tokens`)}async function x(e){let t=await a();if(t)return t;try{let t=await b(),n=r({compliance_region:await o()}),i=e-Date.now();if(i<=0)return;let a=y({apiToken:t,baseURL:n,defaultHeaders:c()}),s={timeoutInSeconds:i/1e3,maxRetries:0},[l,u]=await Promise.allSettled([a.accounts.list({per_page:50},s),a.user.memberships.list({per_page:50},s)]);if(l.status===`rejected`)return;let d=l.value;if((d.result_info?.total_count??d.result.length)>d.result.length)return;let f=d.result;if(u.status===`fulfilled`){let e=u.value.result??[];if((u.value.result_info?.total_count??e.length)>e.length)return;let t=new Set(e.map(e=>e.account?.id).filter(e=>e!==void 0));f=f.filter(e=>t.has(e.id))}return f.length===1?f[0]?.id:void 0}catch{return}}async function S(e){let t=r({compliance_region:await o()});if(e.local){let{createLocalFetch:n}=await import(`./local-qOpZjDed.mjs`);return y({apiToken:`cf-local-mode-no-auth`,baseURL:t,defaultHeaders:c(),fetch:n({persistTo:e.persistTo,apiBaseUrl:t})})}return y({apiToken:await b(),baseURL:t,defaultHeaders:c()})}export{v as a,b as i,y as n,x as o,S as r,l as t};