cf 0.9.0 → 0.10.0

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 (262) hide show
  1. package/README.md +5 -0
  2. package/dist/_meta/agent-context.json +34 -35
  3. package/dist/_meta/commands.json +6834 -10044
  4. package/dist/_meta/schemas.json +11228 -12752
  5. package/dist/{abuse-reports-DnNvw2gG.mjs → abuse-reports-CGF4zcKf.mjs} +2 -2
  6. package/dist/{access-RbqBFrSC.mjs → access-lhLJo1v2.mjs} +1 -1
  7. package/dist/{account-D7xvYqDx.mjs → account-CYRm3yoN.mjs} +1 -1
  8. package/dist/account-tags-B88TotoH.mjs +9 -0
  9. package/dist/accounts-BSIAT_iP.mjs +28 -0
  10. package/dist/{acm-Szq4CoQN.mjs → acm-VULm1djv.mjs} +1 -1
  11. package/dist/{addressing-CgTTbuCF.mjs → addressing-BHPBIkRY.mjs} +1 -1
  12. package/dist/{agent-context-Bu6yvDqA.mjs → agent-context-KBy48G1b.mjs} +1 -1
  13. package/dist/{agent-memory-C8pT01pR.mjs → agent-memory-DDv_Gxr7.mjs} +2 -2
  14. package/dist/{ai-audit-CCygMmsh.mjs → ai-audit-BWZGvbca.mjs} +1 -1
  15. package/dist/{ai-gateway-D4tATNRV.mjs → ai-gateway-jeB-sAgP.mjs} +1 -1
  16. package/dist/ai-search-BmdskMjR.mjs +7 -0
  17. package/dist/{ai-security-AUfzagSE.mjs → ai-security-CsmfcaUx.mjs} +1 -1
  18. package/dist/{ai-Cn0BniR4.mjs → ai-viHB1tgI.mjs} +1 -1
  19. package/dist/{alerting-DbXVpGv3.mjs → alerting-Bl8OqViR.mjs} +4 -4
  20. package/dist/analytics-vOxw8Hy0.mjs +3 -0
  21. package/dist/{analytics_engine-B_bMbfxW.mjs → analytics_engine-DO4-C0wD.mjs} +1 -1
  22. package/dist/{api-security-pSJdgmtK.mjs → api-security-4FVrD4n8.mjs} +1 -1
  23. package/dist/argo-CQfCgazW.mjs +2 -0
  24. package/dist/args-DlUhyGU0.mjs +2 -0
  25. package/dist/artifacts-CVDGnr2V.mjs +4 -0
  26. package/dist/{audit-logs-BIHP5-rk.mjs → audit-logs-CzpwvQ6A.mjs} +1 -1
  27. package/dist/{auth-MeSu8lFz.mjs → auth-D0xZxAEa.mjs} +1 -1
  28. package/dist/{auth-C6MhC9EZ.mjs → auth-MQEamPN9.mjs} +2 -2
  29. package/dist/{billing-0RNCYBJM.mjs → billing-aJgapeRm.mjs} +2 -2
  30. package/dist/{bot-management-uhBRnSPl.mjs → bot-management-Y2q5d-pi.mjs} +1 -1
  31. package/dist/{botnet-feed-DEbMknrE.mjs → botnet-feed-DANJqfmE.mjs} +1 -1
  32. package/dist/{brand-protection-DY2qPL8d.mjs → brand-protection-CjpZWBjp.mjs} +1 -1
  33. package/dist/{browser-extension-DBsmLCUj.mjs → browser-extension-BtpCbh-2.mjs} +1 -1
  34. package/dist/browser-run-BFn9h2Tz.mjs +4 -0
  35. package/dist/{build-Nivzj54_.mjs → build-DcflwvqN.mjs} +1 -1
  36. package/dist/{cache-BgRIDcFJ.mjs → cache-VyWK1SjY.mjs} +1 -1
  37. package/dist/{calls-JrRne0U0.mjs → calls-BxoRYxs4.mjs} +1 -1
  38. package/dist/{certificate-authorities-BJ7W8GGQ.mjs → certificate-authorities-D7OAFxF_.mjs} +1 -1
  39. package/dist/{cf-BUKsENG5.mjs → cf-C7DU4819.mjs} +2 -2
  40. package/dist/{chunk-LQW53VED-Xakf_rUn.mjs → chunk-LQW53VED-DLrXV-hE.mjs} +2 -2
  41. package/dist/{client-certificates-6xxvcOgI.mjs → client-certificates-DDUv8K0a.mjs} +1 -1
  42. package/dist/{client-side-security-cU0Z1tql.mjs → client-side-security-D4ysjwWT.mjs} +1 -1
  43. package/dist/{cloud-connector-DFooSAcn.mjs → cloud-connector-Bhec6z2P.mjs} +1 -1
  44. package/dist/cloudforce-one-J_hn9ss9.mjs +36 -0
  45. package/dist/config.mjs +1 -1
  46. package/dist/connector-interrupts-Dycx8zFx.mjs +2 -0
  47. package/dist/{connector-telemetry-events-CTMmX2BA.mjs → connector-telemetry-events-BmxOSNtN.mjs} +1 -1
  48. package/dist/connector-telemetry-events-latest-BY2556uL.mjs +2 -0
  49. package/dist/{connector-telemetry-snapshots-5Y7m8Cw8.mjs → connector-telemetry-snapshots-CdcqfKnH.mjs} +1 -1
  50. package/dist/connector-telemetry-snapshots-latest-BHYdxUEF.mjs +2 -0
  51. package/dist/{connectors-BRCQSsos.mjs → connectors-BqxYMMtQ.mjs} +1 -1
  52. package/dist/{containers-CfKOM_f5.mjs → containers-CKW081JA.mjs} +8 -8
  53. package/dist/{content-scan-CB4xHGv1.mjs → content-scan-Dgd7A8KF.mjs} +1 -1
  54. package/dist/{csamScanner-AQo_QTlq.mjs → csamScanner-DYL37wLc.mjs} +1 -1
  55. package/dist/{ct-alerting-Bai-1Z3k.mjs → ct-alerting-CkhSbfAs.mjs} +1 -1
  56. package/dist/{custom-certificates-D6aQIGu2.mjs → custom-certificates-BzAOnEoT.mjs} +1 -1
  57. package/dist/custom-csrs-CgzG3pd3.mjs +3 -0
  58. package/dist/{custom-hostnames-BiOVGwnR.mjs → custom-hostnames-q_nsnlye.mjs} +4 -4
  59. package/dist/custom-nameservers-BUBmfhUe.mjs +3 -0
  60. package/dist/custom-pages-M7jA2Hit.mjs +3 -0
  61. package/dist/{d1-FmAh7T7l.mjs → d1-BFvMd6-S.mjs} +1 -1
  62. package/dist/{data-security-2fmzF_Me.mjs → data-security-Bji4Or_j.mjs} +2 -2
  63. package/dist/{dcv-delegation-Cmxxgi9V.mjs → dcv-delegation-BuoRQ1Yh.mjs} +1 -1
  64. package/dist/{deploy-BzFbjH6a.mjs → deploy-CZ7bgNDu.mjs} +1 -1
  65. package/dist/{deploy-input-BRMQehgs.mjs → deploy-input-CrvuoDGJ.mjs} +1 -1
  66. package/dist/{dev-CWaf-qW4.mjs → dev-V10MG-Bg.mjs} +1 -1
  67. package/dist/{diagnostics-Ca6r_972.mjs → diagnostics-BTH-8nJH.mjs} +2 -2
  68. package/dist/{directory-CGNWfVQc.mjs → directory-BlH6N6Qy.mjs} +1 -1
  69. package/dist/{dispatch-namespaces-CBo5kuf7.mjs → dispatch-namespaces-BCjH1JzB.mjs} +1 -1
  70. package/dist/{dist-COfwjT96.mjs → dist-CgrMkXFx.mjs} +1 -1
  71. package/dist/{dls-CobKlH4N.mjs → dls-BF5iN78p.mjs} +1 -1
  72. package/dist/{dns-OfJXNYkK.mjs → dns-CeCTNqRk.mjs} +11 -11
  73. package/dist/{dns-firewall-DZ2ij-nX.mjs → dns-firewall-B54MaLGm.mjs} +1 -1
  74. package/dist/{dot-prop-6SRZBKHT-C_xd7eTS.mjs → dot-prop-6SRZBKHT-wIVDg_fl.mjs} +1 -1
  75. package/dist/{durable-objects-Cw_y37WB.mjs → durable-objects-D8FQORrL.mjs} +1 -1
  76. package/dist/{email-auth-DuJHdiwN.mjs → email-auth-DJK0Eb30.mjs} +1 -1
  77. package/dist/email-routing-NpmiKIrl.mjs +6 -0
  78. package/dist/{email-security-D-P8ln2L.mjs → email-security-BLZ7WZ9Z.mjs} +2 -2
  79. package/dist/email-sending-dn-353Nx.mjs +7 -0
  80. package/dist/fieldExtractors-ahysj57J.mjs +3 -0
  81. package/dist/firewall-CBPGJ43p.mjs +11 -0
  82. package/dist/{flagship-CPkQMist.mjs → flagship-BusjRNIb.mjs} +3 -3
  83. package/dist/{fraud-BhX0QNUl.mjs → fraud-BIhS8pLf.mjs} +1 -1
  84. package/dist/{google-tag-gateway-CDtRxao4.mjs → google-tag-gateway-TZZ3F1tV.mjs} +1 -1
  85. package/dist/{healthchecks-D2WwALvQ.mjs → healthchecks-FiXIk-KP.mjs} +2 -2
  86. package/dist/{hostnames-CGAFkYT1.mjs → hostnames-Bx0mykMR.mjs} +1 -1
  87. package/dist/{hyperdrive-zLFPWFQj.mjs → hyperdrive-C8qCabBF.mjs} +1 -1
  88. package/dist/{iam-Su_hpatD.mjs → iam-Cj63Kjc6.mjs} +1 -1
  89. package/dist/{images-D2ZflvBi.mjs → images-CBWXCDhy.mjs} +1 -1
  90. package/dist/index.mjs +1 -1
  91. package/dist/{intel-DPGzVovJ.mjs → intel-B-9Z_sJs.mjs} +2 -2
  92. package/dist/{interactive-CM2G03lr.mjs → interactive-DtsCYfrK.mjs} +1 -1
  93. package/dist/{ips-C5-NH1b0.mjs → ips-qs9eGJnI.mjs} +1 -1
  94. package/dist/{keyless-certificates-Xx-oAN3Z.mjs → keyless-certificates-THHvoXX3.mjs} +1 -1
  95. package/dist/{keys-B0FBtlOD.mjs → keys-D7N0j4-x.mjs} +1 -1
  96. package/dist/{kv-BbZ9st5o.mjs → kv-BFDUCnft.mjs} +1 -1
  97. package/dist/{leaked-credential-checks-Vonw4inx.mjs → leaked-credential-checks-DUlUCOoJ.mjs} +1 -1
  98. package/dist/load-balancers-D2zbQ8fT.mjs +6 -0
  99. package/dist/{local-eEF0NF51.mjs → local-D-aVNu6A.mjs} +1 -1
  100. package/dist/{local-runtime-BNCCOZ8s.mjs → local-runtime-Dh3keC5v.mjs} +1 -1
  101. package/dist/logexplorer-CUsfZ_bS.mjs +13 -0
  102. package/dist/{logo-matches-oHYc8Xaz.mjs → logo-matches-CJcthPHf.mjs} +1 -1
  103. package/dist/{logos-DS0krPAz.mjs → logos-BS65zN8q.mjs} +1 -1
  104. package/dist/logpush-BK34mMQs.mjs +4 -0
  105. package/dist/{logs-C07M9zn-.mjs → logs-CLAqX9h2.mjs} +1 -1
  106. package/dist/{magic-cloud-networking-ZPEK7O5I.mjs → magic-cloud-networking-h_ozrC5S.mjs} +1 -1
  107. package/dist/magic-network-monitoring-C7tAPNKP.mjs +4 -0
  108. package/dist/{magic-transit-CgPZ8iMn.mjs → magic-transit-BtsFePMx.mjs} +5 -5
  109. package/dist/{managed-transforms-2XyQ14s3.mjs → managed-transforms-Cm_KVCMB.mjs} +1 -1
  110. package/dist/{matches-CIaCrdrs.mjs → matches-InA1hwII.mjs} +1 -1
  111. package/dist/{mcp-D2afM8MD.mjs → mcp-mJ7bekNJ.mjs} +1 -1
  112. package/dist/mesh-BK4S1Ezy.mjs +4 -0
  113. package/dist/{moq-BBQVNGo1.mjs → moq-qmuVPAO0.mjs} +1 -1
  114. package/dist/{mtls-certificates-C5j0Gn65.mjs → mtls-certificates-CU4OAAXY.mjs} +1 -1
  115. package/dist/{network-CmuJqtFJ.mjs → network-D74cSy3t.mjs} +1 -1
  116. package/dist/{network-interconnects-BlajBQqs.mjs → network-interconnects-BJ0Nc48J.mjs} +1 -1
  117. package/dist/{oauth-BjHjJtnn.mjs → oauth-B0ETkNcX.mjs} +2 -2
  118. package/dist/{oauth-clients-BSthfZP-.mjs → oauth-clients-Br-smLxQ.mjs} +1 -1
  119. package/dist/{oauth-scopes-ByUp5bLU.mjs → oauth-scopes-D5bF11ju.mjs} +1 -1
  120. package/dist/observability-BWE0Gg3V.mjs +4 -0
  121. package/dist/{open-PBXRGS4R-C46yIm3u.mjs → open-PBXRGS4R-R-qesf18.mjs} +1 -1
  122. package/dist/{organization-DQIfNVCT.mjs → organization-NX7yCZrq.mjs} +1 -1
  123. package/dist/{organizations-L_ycAy6r.mjs → organizations-DLhiRt8g.mjs} +1 -1
  124. package/dist/{origin-ca-certificates-opIcs3_Q.mjs → origin-ca-certificates-Ff4McZRQ.mjs} +1 -1
  125. package/dist/{origin-post-quantum-encryption-TSMXzoEL.mjs → origin-post-quantum-encryption-UuTr4_SW.mjs} +1 -1
  126. package/dist/{origin-tls-client-auth-5CtcPUR6.mjs → origin-tls-client-auth-DOJ1zlH3.mjs} +1 -1
  127. package/dist/{output-DgW1hQGX.mjs → output-DrpYYfnB.mjs} +1 -1
  128. package/dist/{page-rules-DPd1Y3IL.mjs → page-rules-BSz1gO-_.mjs} +1 -1
  129. package/dist/{pages-CskAn5mR.mjs → pages-DVDogxPs.mjs} +4 -4
  130. package/dist/{pay-per-crawl-BMa_V40s.mjs → pay-per-crawl-BrLXK7gT.mjs} +1 -1
  131. package/dist/{pipelines-BbJjj1ZQ.mjs → pipelines-BszRk4sM.mjs} +2 -2
  132. package/dist/{precursor-DgRWBN9_.mjs → precursor-BPNjQr76.mjs} +1 -1
  133. package/dist/progress-CsHIt3Tp.mjs +2 -0
  134. package/dist/{prompt-DM4z101s.mjs → prompt-DdegNPpg.mjs} +1 -1
  135. package/dist/{queries-DrqcK0ZX.mjs → queries-JL1H1Biz.mjs} +1 -1
  136. package/dist/{queues-CutvMZcc.mjs → queues-DpkYdRUE.mjs} +1 -1
  137. package/dist/{r2-sFI62vhq.mjs → r2-CKozthw_.mjs} +4 -4
  138. package/dist/{r2-data-catalog-3vzU6FE1.mjs → r2-data-catalog-Du7hN9jA.mjs} +1 -1
  139. package/dist/radar-C-92vggG.mjs +2 -0
  140. package/dist/{rate-limits-HRZ8zMSl.mjs → rate-limits-yBF3qoYD.mjs} +1 -1
  141. package/dist/{raw-fetch-25gXED6c.mjs → raw-fetch-CteyTOM2.mjs} +1 -1
  142. package/dist/realtimekit-CIP7lP-a.mjs +7 -0
  143. package/dist/{registrar-C0EsXf83.mjs → registrar-DKKN0M29.mjs} +3 -3
  144. package/dist/{registrar-sandbox-CR9Rr7jV.mjs → registrar-sandbox-DiXg8p_1.mjs} +3 -3
  145. package/dist/{registry-CJvn75Bq.mjs → registry-Bck_zFkz.mjs} +1 -1
  146. package/dist/{reporting-BB6sqe6r.mjs → reporting-fg_GKXe1.mjs} +1 -1
  147. package/dist/{request-tracers-BrsM3zXZ.mjs → request-tracers-CkMya96z.mjs} +1 -1
  148. package/dist/{resource-sharing-CusU3kiy.mjs → resource-sharing-D1pSDvtf.mjs} +1 -1
  149. package/dist/{resource-tagging-wXAcblmz.mjs → resource-tagging-z48JGHCq.mjs} +1 -1
  150. package/dist/{rules-C2BxykEe.mjs → rules-BTmNjDN-.mjs} +1 -1
  151. package/dist/rulesets-CsoSM-17.mjs +5 -0
  152. package/dist/{rum-Dyno5zj3.mjs → rum-DB4iO2q5.mjs} +1 -1
  153. package/dist/{schema-BeXPWeK9.mjs → schema-B34Q9tLF.mjs} +1 -1
  154. package/dist/{schema-flags-C1BRprT2.mjs → schema-flags-iGoOriJt.mjs} +1 -1
  155. package/dist/{scim-Bb2xHpIz.mjs → scim-CcSyfKCH.mjs} +1 -1
  156. package/dist/sdk-ZctLa5jW.mjs +3 -0
  157. package/dist/{secrets-store-BMhjbceW.mjs → secrets-store-DFmvtphu.mjs} +1 -1
  158. package/dist/security-center-DFKeHq5c.mjs +2 -0
  159. package/dist/{security-txt-Bh_2gymk.mjs → security-txt-DqnFpjMI.mjs} +1 -1
  160. package/dist/{session-Br-q_UIW.mjs → session-D6KHthHf.mjs} +1 -1
  161. package/dist/{share-DfTpOxhk.mjs → share-BuwYUzOL.mjs} +1 -1
  162. package/dist/{shared-BNjZc02w.mjs → shared-VppSAQf4.mjs} +1 -1
  163. package/dist/{smart-shield-rHn-Lckq.mjs → smart-shield-D6X8L7p8.mjs} +2 -2
  164. package/dist/{snippets-nSLwH8uJ.mjs → snippets-DIpc9pb_.mjs} +1 -1
  165. package/dist/{spawn-Bj8QRFJ5.mjs → spawn-O1RS01vr.mjs} +2 -2
  166. package/dist/{spectrum-DuhSUTZI.mjs → spectrum-b7N1ZRAm.mjs} +1 -1
  167. package/dist/{speed-Dgby_e1J.mjs → speed-cw31yFva.mjs} +1 -1
  168. package/dist/src-D_HETJNy.mjs +108 -0
  169. package/dist/{ssl-BsxTHasY.mjs → ssl-CsEhRVTO.mjs} +1 -1
  170. package/dist/{state-C1m9nwUm.mjs → state-Bb5Cbc_L.mjs} +1 -1
  171. package/dist/{stream-CkEOX5Ko.mjs → stream-DFOao6Gu.mjs} +3 -3
  172. package/dist/{submit-BjdywxTq.mjs → submit--xTzyNPy.mjs} +1 -1
  173. package/dist/{tags-CFAw_Sce.mjs → tags-efICDkah.mjs} +1 -1
  174. package/dist/{tenant-C66iOy5O.mjs → tenant-CerHuToJ.mjs} +1 -1
  175. package/dist/{tenant-custom-nameservers-CyJZ_AB0.mjs → tenant-custom-nameservers-C4otMBm2.mjs} +1 -1
  176. package/dist/{tools-D2Xxfkrc.mjs → tools-BHfBOZOU.mjs} +1 -1
  177. package/dist/{triggers-Dv22ZXM4.mjs → triggers-BEsiiKAf.mjs} +1 -1
  178. package/dist/{tunnel-BatkLdds.mjs → tunnel-DkMiNtVY.mjs} +1 -1
  179. package/dist/{tunnels-CstoXOoq.mjs → tunnels-D0J8lJoI.mjs} +1 -1
  180. package/dist/{turnstile-IoRtama4.mjs → turnstile-CFmtY5bn.mjs} +2 -2
  181. package/dist/{ui-DjQ4AQww.mjs → ui-DE8CNn6c.mjs} +1 -1
  182. package/dist/{url-info-Hjhwr2la.mjs → url-info-DBCeRWwb.mjs} +1 -1
  183. package/dist/{url-normalization-C2BP_Kl0.mjs → url-normalization-ClfFiruK.mjs} +1 -1
  184. package/dist/{url-scanner-DmYVTdAE.mjs → url-scanner-CNyvg65L.mjs} +1 -1
  185. package/dist/{user-CVHm-cnB.mjs → user-bifVEQq5.mjs} +2 -2
  186. package/dist/{values-Cmlw5wGZ.mjs → values-OxkdP1tV.mjs} +1 -1
  187. package/dist/{vectorize-BQtIqiNO.mjs → vectorize-CVKu7lEt.mjs} +1 -1
  188. package/dist/{versions-CU6Av1vh.mjs → versions-BVL-Ludh.mjs} +1 -1
  189. package/dist/waiting-rooms-CmRAl51T.mjs +11 -0
  190. package/dist/{web-assets-DmSKaxzf.mjs → web-assets-C2s9kzWf.mjs} +1 -1
  191. package/dist/{web3-DVv4jNul.mjs → web3-y_cY91V_.mjs} +1 -1
  192. package/dist/{workers-builds-DgrejrUc.mjs → workers-builds-B55-oXOa.mjs} +4 -4
  193. package/dist/{workers-D8czeT64.mjs → workers-jDcq14GH.mjs} +6 -6
  194. package/dist/{workflows-BOi5MTEN.mjs → workflows-B-kGHxFu.mjs} +2 -2
  195. package/dist/{zaraz-CGSSFJng.mjs → zaraz-27zwjLvv.mjs} +1 -1
  196. package/dist/zero-trust-DV3sIOvu.mjs +92 -0
  197. package/dist/{zone-Bx5ElO9U.mjs → zone-BJix2KQ9.mjs} +1 -1
  198. package/dist/{zones-_SnlZMiM.mjs → zones-Bkj5i92c.mjs} +1 -1
  199. package/package.json +2 -2
  200. package/dist/account-tags-CKRh1jra.mjs +0 -9
  201. package/dist/accounts-2pGhN4s8.mjs +0 -28
  202. package/dist/ai-search-2xP8FP_W.mjs +0 -7
  203. package/dist/analytics-UQrIx99t.mjs +0 -3
  204. package/dist/argo-Br60zF3y.mjs +0 -2
  205. package/dist/artifacts-D8HMRQmb.mjs +0 -4
  206. package/dist/browser-run-C5pYOwtf.mjs +0 -4
  207. package/dist/cloudforce-one-Cp4bQmrG.mjs +0 -30
  208. package/dist/connector-interrupts-BR47snkh.mjs +0 -2
  209. package/dist/custom-csrs-D0zBkQT5.mjs +0 -4
  210. package/dist/custom-nameservers-G2MWpRwY.mjs +0 -3
  211. package/dist/custom-pages-BINNZTds.mjs +0 -4
  212. package/dist/email-CGOC_evd.mjs +0 -2
  213. package/dist/email-routing-CRvIUSFm.mjs +0 -6
  214. package/dist/email-sending-BwRN8PMW.mjs +0 -7
  215. package/dist/filters-DczM8qpH.mjs +0 -4
  216. package/dist/firewall-BMiETRmM.mjs +0 -11
  217. package/dist/load-balancers-Ct5cyyF9.mjs +0 -7
  218. package/dist/logexplorer-BhsAWxCr.mjs +0 -24
  219. package/dist/logpush-CFQBi88z.mjs +0 -5
  220. package/dist/magic-network-monitoring-CY3CHSpX.mjs +0 -4
  221. package/dist/media-CnxgOViL.mjs +0 -2
  222. package/dist/mesh-DLNLi3UT.mjs +0 -4
  223. package/dist/observability-B5p3iwrq.mjs +0 -4
  224. package/dist/progress-C-oFUtvC.mjs +0 -2
  225. package/dist/radar-Cu9rsTw_.mjs +0 -2
  226. package/dist/realtimekit-msnGHBbf.mjs +0 -7
  227. package/dist/rulesets-BHvhAeG_.mjs +0 -8
  228. package/dist/sdk-m4xeaua4.mjs +0 -3
  229. package/dist/security-center-DRC4Mf3R.mjs +0 -2
  230. package/dist/src-CgAVPA4I.mjs +0 -108
  231. package/dist/waiting-rooms-ku9UsAr9.mjs +0 -11
  232. package/dist/zero-trust-BmA0VkgF.mjs +0 -102
  233. package/dist/zone-tags-izd3WWmy.mjs +0 -9
  234. /package/dist/{Page-C-JHZnIy.mjs → Page-9ry_XAVC.mjs} +0 -0
  235. /package/dist/{alerts-B85uj2Vx.mjs → alerts-CRmjqOZi.mjs} +0 -0
  236. /package/dist/{autorag-Do9l_LyY.mjs → autorag-BD7cu5NU.mjs} +0 -0
  237. /package/dist/{body-parser-CYD7PKFC.mjs → body-parser-C-c9gfH1.mjs} +0 -0
  238. /package/dist/{brands-DateHCdd.mjs → brands-BhALBkX2.mjs} +0 -0
  239. /package/dist/{chunk-6EUZQHAF-l8tR2Qyj.mjs → chunk-6EUZQHAF-B7bSMYLe.mjs} +0 -0
  240. /package/dist/{chunk-Q72B4Q5Z-CPy_WJKU.mjs → chunk-Q72B4Q5Z-DVMMVVEs.mjs} +0 -0
  241. /package/dist/{clear-CB2kgcEB.mjs → clear-BgF8No7D.mjs} +0 -0
  242. /package/dist/{cli-types-BWdZbsFE.mjs → cli-types-BsTty22w.mjs} +0 -0
  243. /package/dist/{domain-info-DJHEt8JJ.mjs → domain-info-C50W5GhA.mjs} +0 -0
  244. /package/dist/{health-buY5f5pp.mjs → health-BFNZqiAm.mjs} +0 -0
  245. /package/dist/{input-validation-BBKJRoRB.mjs → input-validation-Bav2M9F-.mjs} +0 -0
  246. /package/dist/{internal-CwyoJUHh.mjs → internal-BTeSewwB.mjs} +0 -0
  247. /package/dist/{live-wEpA5V_n.mjs → live-Dkiyu30_.mjs} +0 -0
  248. /package/dist/{public-BwQqexwo-DbWj8rrr.mjs → public-BwQqexwo-CNW_dPly.mjs} +0 -0
  249. /package/dist/{rate-limit-analytics-Bf1uT0lT.mjs → rate-limit-analytics-Dz-Wv1T0.mjs} +0 -0
  250. /package/dist/{ready-CBSCPiHE.mjs → ready-TKOkKeRg.mjs} +0 -0
  251. /package/dist/{recent-submissions-Dpmq1f7z.mjs → recent-submissions-3Asm6eIi.mjs} +0 -0
  252. /package/dist/{refute-u7ZPQJZy.mjs → refute-BVz9nMyd.mjs} +0 -0
  253. /package/dist/{resolve-XgxRJ-Ys.mjs → resolve-CeBbH6Pq.mjs} +0 -0
  254. /package/dist/{scan-logo-Ba8WZAyp.mjs → scan-logo-ZteA-PUV.mjs} +0 -0
  255. /package/dist/{scan-page-Bcq3Ei86.mjs → scan-page-DWDSyzQ7.mjs} +0 -0
  256. /package/dist/{search-D9WDwnV4.mjs → search-DGNc37HK.mjs} +0 -0
  257. /package/dist/{signed-url-CjPbG5zV.mjs → signed-url-B5Qpn2mn.mjs} +0 -0
  258. /package/dist/{submission-info-Z9hhp9Rq.mjs → submission-info-FjUolE6A.mjs} +0 -0
  259. /package/dist/{theme-BePJemMn.mjs → theme-CeVf-5qG.mjs} +0 -0
  260. /package/dist/{total-queries-aKAYX1iX.mjs → total-queries-NHJj1HGq.mjs} +0 -0
  261. /package/dist/{tracked-domains-Ck7Jm4Kn.mjs → tracked-domains-CniKVHIp.mjs} +0 -0
  262. /package/dist/{verify-2yi0H93r.mjs → verify-DS1PWAJe.mjs} +0 -0
@@ -1,8 +0,0 @@
1
- #!/usr/bin/env node
2
- import{t as e}from"./local-eEF0NF51.mjs";import{f as t,g as n,h as r}from"./oauth-BjHjJtnn.mjs";import{r as i}from"./auth-C6MhC9EZ.mjs";import{t as a}from"./output-DgW1hQGX.mjs";import{n as o,t as s}from"./progress-C-oFUtvC.mjs";import{n as c,t as l}from"./body-parser-CYD7PKFC.mjs";import{n as u}from"./input-validation-BBKJRoRB.mjs";import{a as d,i as f,n as p}from"./prompt-DM4z101s.mjs";function m(e){return e.option(`dry-run`,{type:`boolean`,description:"Validates the request without persisting changes when set to `true`. Responses that normally return 200 return `result: null`; endpoints that normally return 204 continue to return 204."}).option(`description`,{type:`string`,description:`An informative description of the ruleset.`,default:``}).option(`name`,{type:`string`,description:`The human-readable name of the ruleset.`}).option(`kind`,{type:`string`,description:`The kind of the ruleset.`,choices:[`managed`,`custom`,`root`,`zone`]}).option(`phase`,{type:`string`,description:`The phase of the ruleset.`,choices:[`ddos_l4`,`ddos_l7`,`http_config_settings`,`http_custom_errors`,`http_log_custom_fields`,`http_ratelimit`,`http_request_cache_settings`,`http_request_dynamic_redirect`,`http_request_firewall_custom`,`http_request_firewall_managed`,`http_request_late_transform`,`http_request_origin`,`http_request_redirect`,`http_request_sanitize`,`http_request_sbfm`,`http_request_transform`,`http_response_cache_settings`,`http_response_compression`,`http_response_firewall_managed`,`http_response_headers_transform`,`magic_transit`,`magic_transit_ids_managed`,`magic_transit_managed`,`magic_transit_ratelimit`]}).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 h={command:`create`,describe:`Creates a ruleset at the account level.`,builder:m,handler:async r=>{let p={dry_run:r[`dry-run`]};if(r.dryRun){o({command:`cf rulesets account-rulesets create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/rulesets`,pathParams:{},query:p,bodyKind:`json`,body:r.body===void 0?l({description:u(r.description,`description`,`text`),name:u(r.name,`name`,`text`),kind:u(r.kind,`kind`,`text`),phase:u(r.phase,`phase`,`text`)}):c(r.body)});return}let m=await i(r),h=r.local?e:await t();if(r.accountId=h,r.body){let e=c(r.body);new URLSearchParams(Object.entries(p).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Creating`,async()=>m.rulesets.accountRulesets.create({...e,account_id:h,...p})),{successLabel:`Created`});return}r.name===void 0&&(r.name=await d(`name`,`The human-readable name of the ruleset.`)),r.kind===void 0&&(r.kind=await f(`kind`,`The kind of the ruleset.`,[`managed`,`custom`,`root`,`zone`])),r.phase===void 0&&(r.phase=await f(`phase`,`The phase of the ruleset.`,[`ddos_l4`,`ddos_l7`,`http_config_settings`,`http_custom_errors`,`http_log_custom_fields`,`http_ratelimit`,`http_request_cache_settings`,`http_request_dynamic_redirect`,`http_request_firewall_custom`,`http_request_firewall_managed`,`http_request_late_transform`,`http_request_origin`,`http_request_redirect`,`http_request_sanitize`,`http_request_sbfm`,`http_request_transform`,`http_response_cache_settings`,`http_response_compression`,`http_response_firewall_managed`,`http_response_headers_transform`,`magic_transit`,`magic_transit_ids_managed`,`magic_transit_managed`,`magic_transit_ratelimit`]));let g=l({description:u(r.description,`description`,`text`),name:u(r.name,`name`,`text`),kind:u(r.kind,`kind`,`text`),phase:u(r.phase,`phase`,`text`)});new URLSearchParams(Object.entries(p).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Creating`,async()=>m.rulesets.accountRulesets.create({...g,account_id:h,...p})),{successLabel:`Created`})}};function g(e){return e.positional(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:"Validates the request without persisting changes when set to `true`. Responses that normally return 200 return `result: null`; endpoints that normally return 204 continue to return 204."}).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 ee={command:`delete <ruleset-id>`,describe:`Deletes all versions of an existing account ruleset.`,builder:g,handler:async r=>{let c={dry_run:r[`dry-run`]};if(r.dryRun){o({command:`cf rulesets account-rulesets delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/rulesets/${r[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(r[`ruleset-id`]))}`,pathParams:{"ruleset-id":String(r[`ruleset-id`]??``)},query:c,bodyKind:`none`});return}let l=await i(r),u=r.local?e:await t();if(r.accountId=u,!await p({force:!!r.force})){process.stderr.write(`Aborted.
3
- `);return}a(await s(`Deleting`,async()=>l.rulesets.accountRulesets.delete({account_id:u,ruleset_id:r[`ruleset-id`],...c})),{successLabel:`Deleted`})}};function te(e){return e.positional(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const _={command:`get <ruleset-id>`,describe:`Fetches the latest version of an account ruleset.`,builder:te,handler:async r=>{if(r.dryRun){o({command:`cf rulesets account-rulesets get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/rulesets/${r[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(r[`ruleset-id`]))}`,pathParams:{"ruleset-id":String(r[`ruleset-id`]??``)},bodyKind:`none`});return}let c=await i(r),l=r.local?e:await t();r.accountId=l,a(await s(`Loading`,async()=>c.rulesets.accountRulesets.get({account_id:l,ruleset_id:r[`ruleset-id`]})),{successLabel:`Loaded`})}};function v(e){return e.option(`cursor`,{type:`string`,description:`The cursor to use for the next page.`}).option(`per-page`,{type:`number`,description:`The number of rulesets to return per page.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const y={command:`list`,describe:`Fetches all rulesets at the account level.`,builder:v,handler:async r=>{let c={cursor:r.cursor,per_page:r[`per-page`]};if(r.dryRun){o({command:`cf rulesets account-rulesets list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/rulesets`,pathParams:{},query:c,bodyKind:`none`});return}let l=await i(r),u=r.local?e:await t();r.accountId=u,a(await s(`Loading`,async()=>l.rulesets.accountRulesets.list({account_id:u,...c})),{successLabel:`Loaded`})}};function b(e){return e.positional(`ruleset-phase`,{type:`string`,description:`The phase of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const x={command:`get <ruleset-phase>`,describe:`Fetches the latest version of the account entry point ruleset for a given phase.`,builder:b,handler:async r=>{if(r.dryRun){o({command:`cf rulesets account-rulesets phases get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/rulesets/phases/${r[`ruleset-phase`]==null?`<ruleset-phase>`:encodeURIComponent(String(r[`ruleset-phase`]))}/entrypoint`,pathParams:{"ruleset-phase":String(r[`ruleset-phase`]??``)},bodyKind:`none`});return}let c=await i(r),l=r.local?e:await t();r.accountId=l,a(await s(`Loading`,async()=>c.rulesets.accountRulesets.phases.get({account_id:l,ruleset_phase:r[`ruleset-phase`]})),{successLabel:`Loaded`})}};function S(e){return e.positional(`ruleset-phase`,{type:`string`,description:`The phase of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:"Validates the request without persisting changes when set to `true`. Responses that normally return 200 return `result: null`; endpoints that normally return 204 continue to return 204."}).option(`description`,{type:`string`,description:`An informative description of the ruleset.`}).option(`name`,{type:`string`,description:`The human-readable name of the ruleset.`}).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 C={command:`update <ruleset-phase>`,describe:`Updates an account entry point ruleset, creating a new version.`,builder:S,handler:async r=>{let d={dry_run:r[`dry-run`]};if(r.dryRun){o({command:`cf rulesets account-rulesets phases update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/rulesets/phases/${r[`ruleset-phase`]==null?`<ruleset-phase>`:encodeURIComponent(String(r[`ruleset-phase`]))}/entrypoint`,pathParams:{"ruleset-phase":String(r[`ruleset-phase`]??``)},query:d,bodyKind:`json`,body:r.body===void 0?l({description:u(r.description,`description`,`text`),name:u(r.name,`name`,`text`)}):c(r.body)});return}let f=await i(r),p=r.local?e:await t();if(r.accountId=p,r.body){let e=c(r.body);new URLSearchParams(Object.entries(d).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Updating`,async()=>f.rulesets.accountRulesets.phases.update({...e,account_id:p,ruleset_phase:r[`ruleset-phase`],...d})),{successLabel:`Updated`});return}let m=l({description:u(r.description,`description`,`text`),name:u(r.name,`name`,`text`)});new URLSearchParams(Object.entries(d).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Updating`,async()=>f.rulesets.accountRulesets.phases.update({...m,account_id:p,ruleset_phase:r[`ruleset-phase`],...d})),{successLabel:`Updated`})}};function w(e){return e.positional(`ruleset-version`,{type:`string`,description:`The version of the ruleset.`,demandOption:!0}).option(`ruleset-phase`,{type:`string`,description:`The phase of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const T={command:`get <ruleset-version>`,describe:`Fetches a specific version of an account entry point ruleset.`,builder:w,handler:async r=>{if(r.dryRun){o({command:`cf rulesets account-rulesets phases versions get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/rulesets/phases/${r[`ruleset-phase`]==null?`<ruleset-phase>`:encodeURIComponent(String(r[`ruleset-phase`]))}/entrypoint/versions/${r[`ruleset-version`]==null?`<ruleset-version>`:encodeURIComponent(String(r[`ruleset-version`]))}`,pathParams:{"ruleset-version":String(r[`ruleset-version`]??``),"ruleset-phase":String(r[`ruleset-phase`]??``)},bodyKind:`none`});return}let c=await i(r),l=r.local?e:await t();r.accountId=l,a(await s(`Loading`,async()=>c.rulesets.accountRulesets.phases.versions.get({account_id:l,ruleset_phase:r[`ruleset-phase`],ruleset_version:r[`ruleset-version`]})),{successLabel:`Loaded`})}};function E(e){return e.option(`ruleset-phase`,{type:`string`,description:`The phase of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const D={command:`list`,describe:`Fetches the versions of an account entry point ruleset.`,builder:E,handler:async r=>{if(r.dryRun){o({command:`cf rulesets account-rulesets phases versions list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/rulesets/phases/${r[`ruleset-phase`]==null?`<ruleset-phase>`:encodeURIComponent(String(r[`ruleset-phase`]))}/entrypoint/versions`,pathParams:{"ruleset-phase":String(r[`ruleset-phase`]??``)},bodyKind:`none`});return}let c=await i(r),l=r.local?e:await t();r.accountId=l,a(await s(`Loading`,async()=>c.rulesets.accountRulesets.phases.versions.list({account_id:l,ruleset_phase:r[`ruleset-phase`]})),{successLabel:`Loaded`})}},O={command:`versions`,describe:`Operations for account-rulesets.phases.versions`,builder:e=>e.command(T).command(D).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},k={command:`phases`,describe:`Operations for account-rulesets.phases`,builder:e=>e.command(x).command(C).command(O).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function A(e){return e.positional(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:"Validates the request without persisting changes when set to `true`. Responses that normally return 200 return `result: null`; endpoints that normally return 204 continue to return 204."}).option(`position-before`,{type:`string`,description:`The ID of another rule to place the rule before. An empty value causes the rule to be placed at the top.`}).option(`position-after`,{type:`string`,description:`The ID of another rule to place the rule after. An empty value causes the rule to be placed at the bottom.`}).option(`position-index`,{type:`number`,description:`An index at which to place the rule, where index 1 is the first rule.`}).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)`}).conflicts(`position-before`,[`position-after`,`position-index`]).conflicts(`position-after`,[`position-before`,`position-index`]).conflicts(`position-index`,[`position-before`,`position-after`])}const j={command:`create <ruleset-id>`,describe:`Adds a new rule to an account ruleset. The rule will be added to the end of the existing list of rules in the ruleset by default.`,builder:A,handler:async r=>{let d={dry_run:r[`dry-run`]};if(r.dryRun){o({command:`cf rulesets account-rulesets rules create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/rulesets/${r[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(r[`ruleset-id`]))}/rules`,pathParams:{"ruleset-id":String(r[`ruleset-id`]??``)},query:d,bodyKind:`json`,body:r.body===void 0?l({position:{before:u(r[`position-before`],`position-before`,`text`),after:u(r[`position-after`],`position-after`,`text`),index:r[`position-index`]}}):c(r.body)});return}let f=await i(r),p=r.local?e:await t();if(r.accountId=p,r.body){let e=c(r.body);new URLSearchParams(Object.entries(d).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Creating`,async()=>f.rulesets.accountRulesets.rules.create({...e,account_id:p,ruleset_id:r[`ruleset-id`],...d})),{successLabel:`Created`});return}let m=l({position:{before:u(r[`position-before`],`position-before`,`text`),after:u(r[`position-after`],`position-after`,`text`),index:r[`position-index`]}});new URLSearchParams(Object.entries(d).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Creating`,async()=>f.rulesets.accountRulesets.rules.create({...m,account_id:p,ruleset_id:r[`ruleset-id`],...d})),{successLabel:`Created`})}};function M(e){return e.positional(`rule-id`,{type:`string`,description:`The unique ID of the rule.`,demandOption:!0}).option(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:"Validates the request without persisting changes when set to `true`. Responses that normally return 200 return `result: null`; endpoints that normally return 204 continue to return 204."}).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 N={command:`delete <rule-id>`,describe:`Deletes an existing rule from an account ruleset.`,builder:M,handler:async r=>{let c={dry_run:r[`dry-run`]};if(r.dryRun){o({command:`cf rulesets account-rulesets rules delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/rulesets/${r[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(r[`ruleset-id`]))}/rules/${r[`rule-id`]==null?`<rule-id>`:encodeURIComponent(String(r[`rule-id`]))}`,pathParams:{"rule-id":String(r[`rule-id`]??``),"ruleset-id":String(r[`ruleset-id`]??``)},query:c,bodyKind:`none`});return}let l=await i(r),u=r.local?e:await t();if(r.accountId=u,!await p({force:!!r.force})){process.stderr.write(`Aborted.
4
- `);return}a(await s(`Deleting`,async()=>l.rulesets.accountRulesets.rules.delete({account_id:u,ruleset_id:r[`ruleset-id`],rule_id:r[`rule-id`],...c})),{successLabel:`Deleted`})}};function P(e){return e.positional(`rule-id`,{type:`string`,description:`The unique ID of the rule.`,demandOption:!0}).option(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:"Validates the request without persisting changes when set to `true`. Responses that normally return 200 return `result: null`; endpoints that normally return 204 continue to return 204."}).option(`position-before`,{type:`string`,description:`The ID of another rule to place the rule before. An empty value causes the rule to be placed at the top.`}).option(`position-after`,{type:`string`,description:`The ID of another rule to place the rule after. An empty value causes the rule to be placed at the bottom.`}).option(`position-index`,{type:`number`,description:`An index at which to place the rule, where index 1 is the first rule.`}).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)`}).conflicts(`position-before`,[`position-after`,`position-index`]).conflicts(`position-after`,[`position-before`,`position-index`]).conflicts(`position-index`,[`position-before`,`position-after`])}const F={command:`update <rule-id>`,describe:`Updates an existing rule in an account ruleset.`,builder:P,handler:async r=>{let d={dry_run:r[`dry-run`]};if(r.dryRun){o({command:`cf rulesets account-rulesets rules update`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/rulesets/${r[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(r[`ruleset-id`]))}/rules/${r[`rule-id`]==null?`<rule-id>`:encodeURIComponent(String(r[`rule-id`]))}`,pathParams:{"rule-id":String(r[`rule-id`]??``),"ruleset-id":String(r[`ruleset-id`]??``)},query:d,bodyKind:`json`,body:r.body===void 0?l({position:{before:u(r[`position-before`],`position-before`,`text`),after:u(r[`position-after`],`position-after`,`text`),index:r[`position-index`]}}):c(r.body)});return}let f=await i(r),p=r.local?e:await t();if(r.accountId=p,r.body){let e=c(r.body);new URLSearchParams(Object.entries(d).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Updating`,async()=>f.rulesets.accountRulesets.rules.update({...e,account_id:p,ruleset_id:r[`ruleset-id`],rule_id:r[`rule-id`],...d})),{successLabel:`Updated`});return}let m=l({position:{before:u(r[`position-before`],`position-before`,`text`),after:u(r[`position-after`],`position-after`,`text`),index:r[`position-index`]}});new URLSearchParams(Object.entries(d).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Updating`,async()=>f.rulesets.accountRulesets.rules.update({...m,account_id:p,ruleset_id:r[`ruleset-id`],rule_id:r[`rule-id`],...d})),{successLabel:`Updated`})}},I={command:`rules`,describe:`Operations for account-rulesets.rules`,builder:e=>e.command(j).command(N).command(F).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function L(e){return e.positional(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:"Validates the request without persisting changes when set to `true`. Responses that normally return 200 return `result: null`; endpoints that normally return 204 continue to return 204."}).option(`description`,{type:`string`,description:`An informative description of the ruleset.`}).option(`name`,{type:`string`,description:`The human-readable name of the ruleset.`}).option(`kind`,{type:`string`,description:`The kind of the ruleset.`,choices:[`managed`,`custom`,`root`,`zone`]}).option(`phase`,{type:`string`,description:`The phase of the ruleset.`,choices:[`ddos_l4`,`ddos_l7`,`http_config_settings`,`http_custom_errors`,`http_log_custom_fields`,`http_ratelimit`,`http_request_cache_settings`,`http_request_dynamic_redirect`,`http_request_firewall_custom`,`http_request_firewall_managed`,`http_request_late_transform`,`http_request_origin`,`http_request_redirect`,`http_request_sanitize`,`http_request_sbfm`,`http_request_transform`,`http_response_cache_settings`,`http_response_compression`,`http_response_firewall_managed`,`http_response_headers_transform`,`magic_transit`,`magic_transit_ids_managed`,`magic_transit_managed`,`magic_transit_ratelimit`]}).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 R={command:`update <ruleset-id>`,describe:`Updates an account ruleset, creating a new version.`,builder:L,handler:async r=>{let d={dry_run:r[`dry-run`]};if(r.dryRun){o({command:`cf rulesets account-rulesets update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/rulesets/${r[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(r[`ruleset-id`]))}`,pathParams:{"ruleset-id":String(r[`ruleset-id`]??``)},query:d,bodyKind:`json`,body:r.body===void 0?l({description:u(r.description,`description`,`text`),name:u(r.name,`name`,`text`),kind:u(r.kind,`kind`,`text`),phase:u(r.phase,`phase`,`text`)}):c(r.body)});return}let f=await i(r),p=r.local?e:await t();if(r.accountId=p,r.body){let e=c(r.body);new URLSearchParams(Object.entries(d).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Updating`,async()=>f.rulesets.accountRulesets.update({...e,account_id:p,ruleset_id:r[`ruleset-id`],...d})),{successLabel:`Updated`});return}let m=l({description:u(r.description,`description`,`text`),name:u(r.name,`name`,`text`),kind:u(r.kind,`kind`,`text`),phase:u(r.phase,`phase`,`text`)});new URLSearchParams(Object.entries(d).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Updating`,async()=>f.rulesets.accountRulesets.update({...m,account_id:p,ruleset_id:r[`ruleset-id`],...d})),{successLabel:`Updated`})}};function z(e){return e.option(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`ruleset-version`,{type:`string`,description:`The version of the ruleset.`,demandOption:!0}).option(`rule-tag`,{type:`string`,description:`The category of a rule.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const B={command:`list`,describe:`Fetches the rules of a managed account ruleset version for a given tag.`,builder:z,handler:async r=>{if(r.dryRun){o({command:`cf rulesets account-rulesets versions by-tag list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/rulesets/${r[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(r[`ruleset-id`]))}/versions/${r[`ruleset-version`]==null?`<ruleset-version>`:encodeURIComponent(String(r[`ruleset-version`]))}/by_tag/${r[`rule-tag`]==null?`<rule-tag>`:encodeURIComponent(String(r[`rule-tag`]))}`,pathParams:{"rule-tag":String(r[`rule-tag`]??``),"ruleset-version":String(r[`ruleset-version`]??``),"ruleset-id":String(r[`ruleset-id`]??``)},bodyKind:`none`});return}let c=await i(r),l=r.local?e:await t();r.accountId=l,a(await s(`Loading`,async()=>c.rulesets.accountRulesets.versions.byTag.list({account_id:l,ruleset_id:r[`ruleset-id`],ruleset_version:r[`ruleset-version`],rule_tag:r[`rule-tag`]})),{successLabel:`Loaded`})}},V={command:`by-tag`,describe:`Operations for account-rulesets.versions.by-tag`,builder:e=>e.command(B).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function H(e){return e.positional(`ruleset-version`,{type:`string`,description:`The version of the ruleset.`,demandOption:!0}).option(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:"Validates the request without persisting changes when set to `true`. Responses that normally return 200 return `result: null`; endpoints that normally return 204 continue to return 204."}).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 U={command:`delete <ruleset-version>`,describe:`Deletes an existing version of an account ruleset.`,builder:H,handler:async r=>{let c={dry_run:r[`dry-run`]};if(r.dryRun){o({command:`cf rulesets account-rulesets versions delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/rulesets/${r[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(r[`ruleset-id`]))}/versions/${r[`ruleset-version`]==null?`<ruleset-version>`:encodeURIComponent(String(r[`ruleset-version`]))}`,pathParams:{"ruleset-version":String(r[`ruleset-version`]??``),"ruleset-id":String(r[`ruleset-id`]??``)},query:c,bodyKind:`none`});return}let l=await i(r),u=r.local?e:await t();if(r.accountId=u,!await p({force:!!r.force})){process.stderr.write(`Aborted.
5
- `);return}a(await s(`Deleting`,async()=>l.rulesets.accountRulesets.versions.delete({account_id:u,ruleset_id:r[`ruleset-id`],ruleset_version:r[`ruleset-version`],...c})),{successLabel:`Deleted`})}};function W(e){return e.positional(`ruleset-version`,{type:`string`,description:`The version of the ruleset.`,demandOption:!0}).option(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const G={command:`get <ruleset-version>`,describe:`Fetches a specific version of an account ruleset.`,builder:W,handler:async r=>{if(r.dryRun){o({command:`cf rulesets account-rulesets versions get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/rulesets/${r[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(r[`ruleset-id`]))}/versions/${r[`ruleset-version`]==null?`<ruleset-version>`:encodeURIComponent(String(r[`ruleset-version`]))}`,pathParams:{"ruleset-version":String(r[`ruleset-version`]??``),"ruleset-id":String(r[`ruleset-id`]??``)},bodyKind:`none`});return}let c=await i(r),l=r.local?e:await t();r.accountId=l,a(await s(`Loading`,async()=>c.rulesets.accountRulesets.versions.get({account_id:l,ruleset_id:r[`ruleset-id`],ruleset_version:r[`ruleset-version`]})),{successLabel:`Loaded`})}};function K(e){return e.option(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const q={command:`list`,describe:`Fetches the versions of an account ruleset.`,builder:K,handler:async r=>{if(r.dryRun){o({command:`cf rulesets account-rulesets versions list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/rulesets/${r[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(r[`ruleset-id`]))}/versions`,pathParams:{"ruleset-id":String(r[`ruleset-id`]??``)},bodyKind:`none`});return}let c=await i(r),l=r.local?e:await t();r.accountId=l,a(await s(`Loading`,async()=>c.rulesets.accountRulesets.versions.list({account_id:l,ruleset_id:r[`ruleset-id`]})),{successLabel:`Loaded`})}};function J(e){return e.positional(`rule-tag`,{type:`string`,description:`The category of a rule.`,demandOption:!0}).option(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`ruleset-version`,{type:`string`,description:`The version of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const Y={command:`tag <rule-tag>`,describe:`Fetches the rules of a managed zone ruleset version for a given tag.`,builder:J,handler:async e=>{if(e.dryRun){o({command:`cf rulesets account-rulesets versions zone-by-tag tag`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/rulesets/${e[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(e[`ruleset-id`]))}/versions/${e[`ruleset-version`]==null?`<ruleset-version>`:encodeURIComponent(String(e[`ruleset-version`]))}/by_tag/${e[`rule-tag`]==null?`<rule-tag>`:encodeURIComponent(String(e[`rule-tag`]))}`,pathParams:{"rule-tag":String(e[`rule-tag`]??``),"ruleset-version":String(e[`ruleset-version`]??``),"ruleset-id":String(e[`ruleset-id`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await i(e),n=await r({zone:e.zone},t,{quiet:e.quiet});e.zoneId=n,a(await s(`Loading`,async()=>t.rulesets.accountRulesets.versions.zoneByTag.tag({zone_id:n,ruleset_id:e[`ruleset-id`],ruleset_version:e[`ruleset-version`],rule_tag:e[`rule-tag`]})),{successLabel:`Loaded`})}},X={command:`zone-by-tag`,describe:`Operations for account-rulesets.versions.zone-by-tag`,builder:e=>e.command(Y).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},Z={command:`versions`,describe:`Operations for account-rulesets.versions`,builder:e=>e.command(U).command(G).command(q).command(V).command(X).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},Q={command:`account-rulesets`,describe:`Operations for account-rulesets`,builder:e=>e.command(h).command(ee).command(_).command(y).command(R).command(k).command(I).command(Z).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function ne(e){return e.option(`dry-run`,{type:`boolean`,description:"Validates the request without persisting changes when set to `true`. Responses that normally return 200 return `result: null`; endpoints that normally return 204 continue to return 204."}).option(`description`,{type:`string`,description:`An informative description of the ruleset.`,default:``}).option(`name`,{type:`string`,description:`The human-readable name of the ruleset.`}).option(`kind`,{type:`string`,description:`The kind of the ruleset.`,choices:[`managed`,`custom`,`root`,`zone`]}).option(`phase`,{type:`string`,description:`The phase of the ruleset.`,choices:[`ddos_l4`,`ddos_l7`,`http_config_settings`,`http_custom_errors`,`http_log_custom_fields`,`http_ratelimit`,`http_request_cache_settings`,`http_request_dynamic_redirect`,`http_request_firewall_custom`,`http_request_firewall_managed`,`http_request_late_transform`,`http_request_origin`,`http_request_redirect`,`http_request_sanitize`,`http_request_sbfm`,`http_request_transform`,`http_response_cache_settings`,`http_response_compression`,`http_response_firewall_managed`,`http_response_headers_transform`,`magic_transit`,`magic_transit_ids_managed`,`magic_transit_managed`,`magic_transit_ratelimit`]}).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 re={command:`create`,describe:`Creates a ruleset at the zone level.`,builder:ne,handler:async e=>{let t={dry_run:e[`dry-run`]};if(e.dryRun){o({command:`cf rulesets create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/rulesets`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},query:t,bodyKind:`json`,body:e.body===void 0?l({description:u(e.description,`description`,`text`),name:u(e.name,`name`,`text`),kind:u(e.kind,`kind`,`text`),phase:u(e.phase,`phase`,`text`)}):c(e.body)});return}let n=await i(e),p=await r({zone:e.zone},n,{quiet:e.quiet});if(e.zoneId=p,e.body){let r=c(e.body);new URLSearchParams(Object.entries(t).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Creating`,async()=>n.rulesets.create({...r,zone_id:p,...t})),{successLabel:`Created`});return}e.name===void 0&&(e.name=await d(`name`,`The human-readable name of the ruleset.`)),e.kind===void 0&&(e.kind=await f(`kind`,`The kind of the ruleset.`,[`managed`,`custom`,`root`,`zone`])),e.phase===void 0&&(e.phase=await f(`phase`,`The phase of the ruleset.`,[`ddos_l4`,`ddos_l7`,`http_config_settings`,`http_custom_errors`,`http_log_custom_fields`,`http_ratelimit`,`http_request_cache_settings`,`http_request_dynamic_redirect`,`http_request_firewall_custom`,`http_request_firewall_managed`,`http_request_late_transform`,`http_request_origin`,`http_request_redirect`,`http_request_sanitize`,`http_request_sbfm`,`http_request_transform`,`http_response_cache_settings`,`http_response_compression`,`http_response_firewall_managed`,`http_response_headers_transform`,`magic_transit`,`magic_transit_ids_managed`,`magic_transit_managed`,`magic_transit_ratelimit`]));let m=l({description:u(e.description,`description`,`text`),name:u(e.name,`name`,`text`),kind:u(e.kind,`kind`,`text`),phase:u(e.phase,`phase`,`text`)});new URLSearchParams(Object.entries(t).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Creating`,async()=>n.rulesets.create({...m,zone_id:p,...t})),{successLabel:`Created`})}};function ie(e){return e.positional(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:"Validates the request without persisting changes when set to `true`. Responses that normally return 200 return `result: null`; endpoints that normally return 204 continue to return 204."}).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 ae={command:`delete <ruleset-id>`,describe:`Deletes all versions of an existing zone ruleset.`,builder:ie,handler:async e=>{let t={dry_run:e[`dry-run`]};if(e.dryRun){o({command:`cf rulesets delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/rulesets/${e[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(e[`ruleset-id`]))}`,pathParams:{"ruleset-id":String(e[`ruleset-id`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},query:t,bodyKind:`none`});return}let n=await i(e),c=await r({zone:e.zone},n,{quiet:e.quiet});if(e.zoneId=c,!await p({force:!!e.force})){process.stderr.write(`Aborted.
6
- `);return}a(await s(`Deleting`,async()=>n.rulesets.delete({zone_id:c,ruleset_id:e[`ruleset-id`],...t})),{successLabel:`Deleted`})}};function oe(e){return e.positional(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const se={command:`get <ruleset-id>`,describe:`Fetches the latest version of a zone ruleset.`,builder:oe,handler:async e=>{if(e.dryRun){o({command:`cf rulesets get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/rulesets/${e[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(e[`ruleset-id`]))}`,pathParams:{"ruleset-id":String(e[`ruleset-id`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await i(e),n=await r({zone:e.zone},t,{quiet:e.quiet});e.zoneId=n,a(await s(`Loading`,async()=>t.rulesets.get({zone_id:n,ruleset_id:e[`ruleset-id`]})),{successLabel:`Loaded`})}};function ce(e){return e.option(`cursor`,{type:`string`,description:`The cursor to use for the next page.`}).option(`per-page`,{type:`number`,description:`The number of rulesets to return per page.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const le={command:`list`,describe:`Fetches all rulesets at the zone level.`,builder:ce,handler:async e=>{let t={cursor:e.cursor,per_page:e[`per-page`]};if(e.dryRun){o({command:`cf rulesets list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/rulesets`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},query:t,bodyKind:`none`});return}let n=await i(e),c=await r({zone:e.zone},n,{quiet:e.quiet});e.zoneId=c,a(await s(`Loading`,async()=>n.rulesets.list({zone_id:c,...t})),{successLabel:`Loaded`})}};function ue(e){return e.positional(`ruleset-phase`,{type:`string`,description:`The phase of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const de={command:`get <ruleset-phase>`,describe:`Fetches the latest version of the zone entry point ruleset for a given phase.`,builder:ue,handler:async e=>{if(e.dryRun){o({command:`cf rulesets phases get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/rulesets/phases/${e[`ruleset-phase`]==null?`<ruleset-phase>`:encodeURIComponent(String(e[`ruleset-phase`]))}/entrypoint`,pathParams:{"ruleset-phase":String(e[`ruleset-phase`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await i(e),n=await r({zone:e.zone},t,{quiet:e.quiet});e.zoneId=n,a(await s(`Loading`,async()=>t.rulesets.phases.get({zone_id:n,ruleset_phase:e[`ruleset-phase`]})),{successLabel:`Loaded`})}};function fe(e){return e.positional(`ruleset-phase`,{type:`string`,description:`The phase of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:"Validates the request without persisting changes when set to `true`. Responses that normally return 200 return `result: null`; endpoints that normally return 204 continue to return 204."}).option(`description`,{type:`string`,description:`An informative description of the ruleset.`}).option(`name`,{type:`string`,description:`The human-readable name of the ruleset.`}).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 pe={command:`update <ruleset-phase>`,describe:`Updates a zone entry point ruleset, creating a new version.`,builder:fe,handler:async e=>{let t={dry_run:e[`dry-run`]};if(e.dryRun){o({command:`cf rulesets phases update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/rulesets/phases/${e[`ruleset-phase`]==null?`<ruleset-phase>`:encodeURIComponent(String(e[`ruleset-phase`]))}/entrypoint`,pathParams:{"ruleset-phase":String(e[`ruleset-phase`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},query:t,bodyKind:`json`,body:e.body===void 0?l({description:u(e.description,`description`,`text`),name:u(e.name,`name`,`text`)}):c(e.body)});return}let n=await i(e),d=await r({zone:e.zone},n,{quiet:e.quiet});if(e.zoneId=d,e.body){let r=c(e.body);new URLSearchParams(Object.entries(t).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Updating`,async()=>n.rulesets.phases.update({...r,zone_id:d,ruleset_phase:e[`ruleset-phase`],...t})),{successLabel:`Updated`});return}let f=l({description:u(e.description,`description`,`text`),name:u(e.name,`name`,`text`)});new URLSearchParams(Object.entries(t).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Updating`,async()=>n.rulesets.phases.update({...f,zone_id:d,ruleset_phase:e[`ruleset-phase`],...t})),{successLabel:`Updated`})}};function me(e){return e.positional(`ruleset-version`,{type:`string`,description:`The version of the ruleset.`,demandOption:!0}).option(`ruleset-phase`,{type:`string`,description:`The phase of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const he={command:`get <ruleset-version>`,describe:`Fetches a specific version of a zone entry point ruleset.`,builder:me,handler:async e=>{if(e.dryRun){o({command:`cf rulesets phases versions get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/rulesets/phases/${e[`ruleset-phase`]==null?`<ruleset-phase>`:encodeURIComponent(String(e[`ruleset-phase`]))}/entrypoint/versions/${e[`ruleset-version`]==null?`<ruleset-version>`:encodeURIComponent(String(e[`ruleset-version`]))}`,pathParams:{"ruleset-version":String(e[`ruleset-version`]??``),"ruleset-phase":String(e[`ruleset-phase`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await i(e),n=await r({zone:e.zone},t,{quiet:e.quiet});e.zoneId=n,a(await s(`Loading`,async()=>t.rulesets.phases.versions.get({zone_id:n,ruleset_phase:e[`ruleset-phase`],ruleset_version:e[`ruleset-version`]})),{successLabel:`Loaded`})}};function ge(e){return e.option(`ruleset-phase`,{type:`string`,description:`The phase of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const _e={command:`list`,describe:`Fetches the versions of a zone entry point ruleset.`,builder:ge,handler:async e=>{if(e.dryRun){o({command:`cf rulesets phases versions list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/rulesets/phases/${e[`ruleset-phase`]==null?`<ruleset-phase>`:encodeURIComponent(String(e[`ruleset-phase`]))}/entrypoint/versions`,pathParams:{"ruleset-phase":String(e[`ruleset-phase`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await i(e),n=await r({zone:e.zone},t,{quiet:e.quiet});e.zoneId=n,a(await s(`Loading`,async()=>t.rulesets.phases.versions.list({zone_id:n,ruleset_phase:e[`ruleset-phase`]})),{successLabel:`Loaded`})}},ve={command:`versions`,describe:`Operations for phases.versions`,builder:e=>e.command(he).command(_e).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},ye={command:`phases`,describe:`Operations for phases`,builder:e=>e.command(de).command(pe).command(ve).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function be(e){return e.positional(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:"Validates the request without persisting changes when set to `true`. Responses that normally return 200 return `result: null`; endpoints that normally return 204 continue to return 204."}).option(`position-before`,{type:`string`,description:`The ID of another rule to place the rule before. An empty value causes the rule to be placed at the top.`}).option(`position-after`,{type:`string`,description:`The ID of another rule to place the rule after. An empty value causes the rule to be placed at the bottom.`}).option(`position-index`,{type:`number`,description:`An index at which to place the rule, where index 1 is the first rule.`}).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)`}).conflicts(`position-before`,[`position-after`,`position-index`]).conflicts(`position-after`,[`position-before`,`position-index`]).conflicts(`position-index`,[`position-before`,`position-after`])}const xe={command:`create <ruleset-id>`,describe:`Adds a new rule to a zone ruleset. The rule will be added to the end of the existing list of rules in the ruleset by default.`,builder:be,handler:async e=>{let t={dry_run:e[`dry-run`]};if(e.dryRun){o({command:`cf rulesets rules create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/rulesets/${e[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(e[`ruleset-id`]))}/rules`,pathParams:{"ruleset-id":String(e[`ruleset-id`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},query:t,bodyKind:`json`,body:e.body===void 0?l({position:{before:u(e[`position-before`],`position-before`,`text`),after:u(e[`position-after`],`position-after`,`text`),index:e[`position-index`]}}):c(e.body)});return}let n=await i(e),d=await r({zone:e.zone},n,{quiet:e.quiet});if(e.zoneId=d,e.body){let r=c(e.body);new URLSearchParams(Object.entries(t).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Creating`,async()=>n.rulesets.rules.create({...r,zone_id:d,ruleset_id:e[`ruleset-id`],...t})),{successLabel:`Created`});return}let f=l({position:{before:u(e[`position-before`],`position-before`,`text`),after:u(e[`position-after`],`position-after`,`text`),index:e[`position-index`]}});new URLSearchParams(Object.entries(t).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Creating`,async()=>n.rulesets.rules.create({...f,zone_id:d,ruleset_id:e[`ruleset-id`],...t})),{successLabel:`Created`})}};function Se(e){return e.positional(`rule-id`,{type:`string`,description:`The unique ID of the rule.`,demandOption:!0}).option(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:"Validates the request without persisting changes when set to `true`. Responses that normally return 200 return `result: null`; endpoints that normally return 204 continue to return 204."}).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 Ce={command:`delete <rule-id>`,describe:`Deletes an existing rule from a zone ruleset.`,builder:Se,handler:async e=>{let t={dry_run:e[`dry-run`]};if(e.dryRun){o({command:`cf rulesets rules delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/rulesets/${e[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(e[`ruleset-id`]))}/rules/${e[`rule-id`]==null?`<rule-id>`:encodeURIComponent(String(e[`rule-id`]))}`,pathParams:{"rule-id":String(e[`rule-id`]??``),"ruleset-id":String(e[`ruleset-id`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},query:t,bodyKind:`none`});return}let n=await i(e),c=await r({zone:e.zone},n,{quiet:e.quiet});if(e.zoneId=c,!await p({force:!!e.force})){process.stderr.write(`Aborted.
7
- `);return}a(await s(`Deleting`,async()=>n.rulesets.rules.delete({zone_id:c,ruleset_id:e[`ruleset-id`],rule_id:e[`rule-id`],...t})),{successLabel:`Deleted`})}};function we(e){return e.positional(`rule-id`,{type:`string`,description:`The unique ID of the rule.`,demandOption:!0}).option(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:"Validates the request without persisting changes when set to `true`. Responses that normally return 200 return `result: null`; endpoints that normally return 204 continue to return 204."}).option(`position-before`,{type:`string`,description:`The ID of another rule to place the rule before. An empty value causes the rule to be placed at the top.`}).option(`position-after`,{type:`string`,description:`The ID of another rule to place the rule after. An empty value causes the rule to be placed at the bottom.`}).option(`position-index`,{type:`number`,description:`An index at which to place the rule, where index 1 is the first rule.`}).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)`}).conflicts(`position-before`,[`position-after`,`position-index`]).conflicts(`position-after`,[`position-before`,`position-index`]).conflicts(`position-index`,[`position-before`,`position-after`])}const Te={command:`update <rule-id>`,describe:`Updates an existing rule in a zone ruleset.`,builder:we,handler:async e=>{let t={dry_run:e[`dry-run`]};if(e.dryRun){o({command:`cf rulesets rules update`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/rulesets/${e[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(e[`ruleset-id`]))}/rules/${e[`rule-id`]==null?`<rule-id>`:encodeURIComponent(String(e[`rule-id`]))}`,pathParams:{"rule-id":String(e[`rule-id`]??``),"ruleset-id":String(e[`ruleset-id`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},query:t,bodyKind:`json`,body:e.body===void 0?l({position:{before:u(e[`position-before`],`position-before`,`text`),after:u(e[`position-after`],`position-after`,`text`),index:e[`position-index`]}}):c(e.body)});return}let n=await i(e),d=await r({zone:e.zone},n,{quiet:e.quiet});if(e.zoneId=d,e.body){let r=c(e.body);new URLSearchParams(Object.entries(t).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Updating`,async()=>n.rulesets.rules.update({...r,zone_id:d,ruleset_id:e[`ruleset-id`],rule_id:e[`rule-id`],...t})),{successLabel:`Updated`});return}let f=l({position:{before:u(e[`position-before`],`position-before`,`text`),after:u(e[`position-after`],`position-after`,`text`),index:e[`position-index`]}});new URLSearchParams(Object.entries(t).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Updating`,async()=>n.rulesets.rules.update({...f,zone_id:d,ruleset_id:e[`ruleset-id`],rule_id:e[`rule-id`],...t})),{successLabel:`Updated`})}},Ee={command:`rules`,describe:`Operations for rules`,builder:e=>e.command(xe).command(Ce).command(Te).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function De(e){return e.positional(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:"Validates the request without persisting changes when set to `true`. Responses that normally return 200 return `result: null`; endpoints that normally return 204 continue to return 204."}).option(`description`,{type:`string`,description:`An informative description of the ruleset.`}).option(`name`,{type:`string`,description:`The human-readable name of the ruleset.`}).option(`kind`,{type:`string`,description:`The kind of the ruleset.`,choices:[`managed`,`custom`,`root`,`zone`]}).option(`phase`,{type:`string`,description:`The phase of the ruleset.`,choices:[`ddos_l4`,`ddos_l7`,`http_config_settings`,`http_custom_errors`,`http_log_custom_fields`,`http_ratelimit`,`http_request_cache_settings`,`http_request_dynamic_redirect`,`http_request_firewall_custom`,`http_request_firewall_managed`,`http_request_late_transform`,`http_request_origin`,`http_request_redirect`,`http_request_sanitize`,`http_request_sbfm`,`http_request_transform`,`http_response_cache_settings`,`http_response_compression`,`http_response_firewall_managed`,`http_response_headers_transform`,`magic_transit`,`magic_transit_ids_managed`,`magic_transit_managed`,`magic_transit_ratelimit`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const $={command:`update <ruleset-id>`,describe:`Updates a zone ruleset, creating a new version.`,builder:De,handler:async e=>{let t={dry_run:e[`dry-run`]};if(e.dryRun){o({command:`cf rulesets update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/rulesets/${e[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(e[`ruleset-id`]))}`,pathParams:{"ruleset-id":String(e[`ruleset-id`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},query:t,bodyKind:`json`,body:e.body===void 0?l({description:u(e.description,`description`,`text`),name:u(e.name,`name`,`text`),kind:u(e.kind,`kind`,`text`),phase:u(e.phase,`phase`,`text`)}):c(e.body)});return}let n=await i(e),d=await r({zone:e.zone},n,{quiet:e.quiet});if(e.zoneId=d,e.body){let r=c(e.body);new URLSearchParams(Object.entries(t).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Updating`,async()=>n.rulesets.update({...r,zone_id:d,ruleset_id:e[`ruleset-id`],...t})),{successLabel:`Updated`});return}let f=l({description:u(e.description,`description`,`text`),name:u(e.name,`name`,`text`),kind:u(e.kind,`kind`,`text`),phase:u(e.phase,`phase`,`text`)});new URLSearchParams(Object.entries(t).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),a(await s(`Updating`,async()=>n.rulesets.update({...f,zone_id:d,ruleset_id:e[`ruleset-id`],...t})),{successLabel:`Updated`})}};function Oe(e){return e.positional(`ruleset-version`,{type:`string`,description:`The version of the ruleset.`,demandOption:!0}).option(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:"Validates the request without persisting changes when set to `true`. Responses that normally return 200 return `result: null`; endpoints that normally return 204 continue to return 204."}).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 ke={command:`delete <ruleset-version>`,describe:`Deletes an existing version of a zone ruleset.`,builder:Oe,handler:async e=>{let t={dry_run:e[`dry-run`]};if(e.dryRun){o({command:`cf rulesets versions delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/rulesets/${e[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(e[`ruleset-id`]))}/versions/${e[`ruleset-version`]==null?`<ruleset-version>`:encodeURIComponent(String(e[`ruleset-version`]))}`,pathParams:{"ruleset-version":String(e[`ruleset-version`]??``),"ruleset-id":String(e[`ruleset-id`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},query:t,bodyKind:`none`});return}let n=await i(e),c=await r({zone:e.zone},n,{quiet:e.quiet});if(e.zoneId=c,!await p({force:!!e.force})){process.stderr.write(`Aborted.
8
- `);return}a(await s(`Deleting`,async()=>n.rulesets.versions.delete({zone_id:c,ruleset_id:e[`ruleset-id`],ruleset_version:e[`ruleset-version`],...t})),{successLabel:`Deleted`})}};function Ae(e){return e.positional(`ruleset-version`,{type:`string`,description:`The version of the ruleset.`,demandOption:!0}).option(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const je={command:`get <ruleset-version>`,describe:`Fetches a specific version of a zone ruleset.`,builder:Ae,handler:async e=>{if(e.dryRun){o({command:`cf rulesets versions get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/rulesets/${e[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(e[`ruleset-id`]))}/versions/${e[`ruleset-version`]==null?`<ruleset-version>`:encodeURIComponent(String(e[`ruleset-version`]))}`,pathParams:{"ruleset-version":String(e[`ruleset-version`]??``),"ruleset-id":String(e[`ruleset-id`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await i(e),n=await r({zone:e.zone},t,{quiet:e.quiet});e.zoneId=n,a(await s(`Loading`,async()=>t.rulesets.versions.get({zone_id:n,ruleset_id:e[`ruleset-id`],ruleset_version:e[`ruleset-version`]})),{successLabel:`Loaded`})}};function Me(e){return e.option(`ruleset-id`,{type:`string`,description:`The unique ID of the ruleset.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const Ne={command:`list`,describe:`Fetches the versions of a zone ruleset.`,builder:Me,handler:async e=>{if(e.dryRun){o({command:`cf rulesets versions list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/rulesets/${e[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(e[`ruleset-id`]))}/versions`,pathParams:{"ruleset-id":String(e[`ruleset-id`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await i(e),n=await r({zone:e.zone},t,{quiet:e.quiet});e.zoneId=n,a(await s(`Loading`,async()=>t.rulesets.versions.list({zone_id:n,ruleset_id:e[`ruleset-id`]})),{successLabel:`Loaded`})}},Pe={command:`versions`,describe:`Operations for versions`,builder:e=>e.command(ke).command(je).command(Ne).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},Fe={command:`rulesets`,describe:`rulesets`,builder:e=>e.command(re).command(ae).command(se).command(le).command($).command(Q).command(ye).command(Ee).command(Pe).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{Fe as default};