cf 1.0.0-beta.30 → 1.0.0-beta.31

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 (214) hide show
  1. package/README.md +1 -1
  2. package/dist/_meta/commands.json +1029 -1113
  3. package/dist/_meta/schemas.json +672 -702
  4. package/dist/{abuse-reports-Dzop8iDe.mjs → abuse-reports-B8vD22yf.mjs} +1 -1
  5. package/dist/{access-2NeD3Gu8.mjs → access-BkZlZPER.mjs} +1 -1
  6. package/dist/{accounts-CeJbhhX4.mjs → accounts-CG6_1Bfa.mjs} +3 -3
  7. package/dist/{acm-Dub0B14J.mjs → acm-B5VvmBfE.mjs} +1 -1
  8. package/dist/{addressing-BzWJU8m6.mjs → addressing-Db9Z1P-r.mjs} +1 -1
  9. package/dist/{agent-memory-2l9zyQFA.mjs → agent-memory-nzAUPSmC.mjs} +1 -1
  10. package/dist/{ai-laLv3daG.mjs → ai-RTQ-iZFq.mjs} +1 -1
  11. package/dist/{ai-audit-rgNePq5W.mjs → ai-audit-BGipueRC.mjs} +1 -1
  12. package/dist/{ai-gateway-e9b8CcL6.mjs → ai-gateway-F2pW8d5j.mjs} +1 -1
  13. package/dist/{ai-search-DZ0AqoPe.mjs → ai-search-CKM-K1Hm.mjs} +1 -1
  14. package/dist/{ai-security-CQuBTtmw.mjs → ai-security-CS2VJd4V.mjs} +1 -1
  15. package/dist/{alerting-_4ra-f_v.mjs → alerting-DNqXDY_7.mjs} +1 -1
  16. package/dist/{analytics-DLNn4bJ4.mjs → analytics-DM85HHka.mjs} +1 -1
  17. package/dist/{analytics-engine-CY45yWuL.mjs → analytics-engine-CxnuZwEx.mjs} +1 -1
  18. package/dist/{api-security-BSvJAjJV.mjs → api-security-BwLSP_5v.mjs} +1 -1
  19. package/dist/{argo-xzl0p--1.mjs → argo-DZM2SJFd.mjs} +1 -1
  20. package/dist/{artifacts-DAS14gcM.mjs → artifacts-CKbQsn4H.mjs} +1 -1
  21. package/dist/{audit-logs-3nYyCGQA.mjs → audit-logs-CG76HATH.mjs} +1 -1
  22. package/dist/auth-BBUZyJJx.mjs +2 -0
  23. package/dist/{auth-B0mFB6nU.mjs → auth-DBM4EcdJ.mjs} +1 -1
  24. package/dist/{auth-cj71dGxS.mjs → auth-NIRm11Ab.mjs} +1 -1
  25. package/dist/{auth-token-D9MnaZ-L.mjs → auth-token-Cp_u44cF.mjs} +1 -1
  26. package/dist/{autoconfig-DoLQ5ct8.mjs → autoconfig-CQjvJ8Rp.mjs} +386 -120
  27. package/dist/{basin-catalog-BbCsAKyZ.mjs → basin-catalog-BMKr8hFw.mjs} +1 -1
  28. package/dist/{billing-BsiLsjWJ.mjs → billing-LiyUCn9n.mjs} +1 -1
  29. package/dist/{blocks-DK5qAzLe.mjs → blocks-DdIA5quB.mjs} +1 -1
  30. package/dist/{bot-management-DkErOsIO.mjs → bot-management-ATqDTT08.mjs} +1 -1
  31. package/dist/{botnet-feed-CK4_PKrf.mjs → botnet-feed-Dk3eMSZo.mjs} +1 -1
  32. package/dist/{brand-protection-Czt-2Ei5.mjs → brand-protection-B82xx9X5.mjs} +2 -2
  33. package/dist/{browser-run-DLMdEaSJ.mjs → browser-run-DEVs2X54.mjs} +1 -1
  34. package/dist/build-CjqOmQjC.mjs +2 -0
  35. package/dist/{build-DiEXOgHH.mjs → build-D18S0p87.mjs} +1 -1
  36. package/dist/{builds-D--zUbR2.mjs → builds-kZaYZiQn.mjs} +1 -1
  37. package/dist/{cache-C8PQmkjD.mjs → cache-BSkT4mhb.mjs} +1 -1
  38. package/dist/{cli-BBv5YMan.mjs → cli-dk6sJFtN.mjs} +1 -1
  39. package/dist/{client-side-security-CFxePUL9.mjs → client-side-security-90cX3xFX.mjs} +1 -1
  40. package/dist/{cloud-connector-BitfLQ3s.mjs → cloud-connector-CtJhvxoD.mjs} +1 -1
  41. package/dist/{cloudforce-one-D2dzA7VD.mjs → cloudforce-one-DOf-Y51V.mjs} +2 -2
  42. package/dist/{command-iwrZ2Sb1.mjs → command-B2dfzTXs.mjs} +1 -1
  43. package/dist/{command-Xqidhyr_.mjs → command-BAzptjLF.mjs} +1 -1
  44. package/dist/{command-n7QausoH.mjs → command-BUYlzx4J.mjs} +1 -1
  45. package/dist/{command-BwcAuPBr.mjs → command-BUbUtS1f.mjs} +1 -1
  46. package/dist/{command-CQhD3Q1t.mjs → command-CTpn87uz.mjs} +1 -1
  47. package/dist/{command-BC_nezLE.mjs → command-DPo7r1PT.mjs} +1 -1
  48. package/dist/command-DuCT0YaL.mjs +2 -0
  49. package/dist/{command-DoXuskBZ.mjs → command-MWbvYsQH.mjs} +1 -1
  50. package/dist/{command-D5FrTb2N.mjs → command-QInwUVT5.mjs} +1 -1
  51. package/dist/{command-s15KaL-x.mjs → command-V0dODmT-.mjs} +1 -1
  52. package/dist/{completions-BAUSggys.mjs → completions-4aAl8vcF.mjs} +1 -1
  53. package/dist/{connector-interrupts-D9tI84Fk.mjs → connector-interrupts-qEMhlWeV.mjs} +1 -1
  54. package/dist/{connector-telemetry-events-Bs9wLYwc.mjs → connector-telemetry-events-CdqnrxRp.mjs} +1 -1
  55. package/dist/{connector-telemetry-snapshots-CbwE4lrE.mjs → connector-telemetry-snapshots-BRvmHAEM.mjs} +1 -1
  56. package/dist/{connectors-LyJN1htu.mjs → connectors-BqShaonQ.mjs} +1 -1
  57. package/dist/{containers-CKs7ZyZq.mjs → containers-BNuGwLRK.mjs} +2 -2
  58. package/dist/{content-scan-BQRz7C7Z.mjs → content-scan-02SOIW_1.mjs} +1 -1
  59. package/dist/{context-DlFhI9cN.mjs → context-CroqTqbk.mjs} +1 -1
  60. package/dist/{cps-DYlXx89C.mjs → cps-DvEG2eZl.mjs} +1 -1
  61. package/dist/{csam-scanner-BFANxGD-.mjs → csam-scanner-Bvklah8m.mjs} +1 -1
  62. package/dist/{custom-csrs-BX4aCeof.mjs → custom-csrs-BVcDWpY-.mjs} +1 -1
  63. package/dist/{custom-hostnames-BRYABKN3.mjs → custom-hostnames-IgjZmeJc.mjs} +1 -1
  64. package/dist/{custom-nameservers-CP1Vf1TD.mjs → custom-nameservers-0EYFPBz2.mjs} +1 -1
  65. package/dist/{custom-pages-BNL69ToU.mjs → custom-pages-W2weASNg.mjs} +1 -1
  66. package/dist/{d1-D4AZsUKn.mjs → d1-Df4t1noM.mjs} +1 -1
  67. package/dist/{delegate-BKlomUk6.mjs → delegate-CEaYc4br.mjs} +1 -1
  68. package/dist/delegate.mjs +1 -1
  69. package/dist/{deploy-LbXgSfAd.mjs → deploy-CGx9aUuj.mjs} +1 -1
  70. package/dist/{deploy-context-BYw6gbl-.mjs → deploy-context-DzSmuU32.mjs} +1 -1
  71. package/dist/deploy-input-DA70GC4o.mjs +2 -0
  72. package/dist/{dev-DaFSd8WC.mjs → dev-BDls_bK6.mjs} +1 -1
  73. package/dist/{diagnostics-Dk3pyWx_.mjs → diagnostics-C8V1G64d.mjs} +1 -1
  74. package/dist/{discover-DGsMj9ZN.mjs → discover-DtcZCeSh.mjs} +1 -1
  75. package/dist/discover-Dxb5yh9L.mjs +2 -0
  76. package/dist/{disk-cache-nbuwH1Dh.mjs → disk-cache-D6xHBTAA.mjs} +1 -1
  77. package/dist/{dls-DU6EdhQK.mjs → dls-BpU_jtuh.mjs} +1 -1
  78. package/dist/{dns-3QDtCu6f.mjs → dns-BlgfnRkG.mjs} +25 -25
  79. package/dist/{dns-firewall-Bbrr_0_a.mjs → dns-firewall-DtkcaFQ0.mjs} +1 -1
  80. package/dist/{docs-lLLKcLr_.mjs → docs-BI2ZoYmm.mjs} +1 -1
  81. package/dist/{durable-objects-DPf1DMeq.mjs → durable-objects-BPTzK6Xh.mjs} +1 -1
  82. package/dist/{email-auth-DOlEoi8q.mjs → email-auth-BSoYwLs1.mjs} +1 -1
  83. package/dist/{email-routing-D56SPGty.mjs → email-routing-3AIhCb7w.mjs} +1 -1
  84. package/dist/{email-security-CSawx0kD.mjs → email-security-INhnV4tT.mjs} +1 -1
  85. package/dist/{email-sending-CgFi0cLA.mjs → email-sending-BJ3OLfN3.mjs} +1 -1
  86. package/dist/{errors-CilNjDVk.mjs → errors-CBngn9n1.mjs} +1 -1
  87. package/dist/{field-extractors-FvIgySB4.mjs → field-extractors-lSqk5ySb.mjs} +1 -1
  88. package/dist/{firewall-BrTvywhW.mjs → firewall-CdXsS4Cc.mjs} +1 -1
  89. package/dist/{flagship-BGFN1Epo.mjs → flagship-CtnQ4Emf.mjs} +1 -1
  90. package/dist/{fraud-DzK6OIO3.mjs → fraud-CAZdLc_4.mjs} +1 -1
  91. package/dist/{google-tag-gateway-Cd9v8A7Z.mjs → google-tag-gateway-CBMNbgeM.mjs} +1 -1
  92. package/dist/{healthchecks-Cm7EHaBA.mjs → healthchecks-DdPEo0GC.mjs} +1 -1
  93. package/dist/{hyperdrive-CVaSt0qX.mjs → hyperdrive-DxHbVnyO.mjs} +1 -1
  94. package/dist/{iam-CWN62Mi4.mjs → iam-CISZzLLr.mjs} +1 -1
  95. package/dist/{images-Bo_pdvQC.mjs → images-DeMHqQHl.mjs} +1 -1
  96. package/dist/index.mjs +1 -1
  97. package/dist/{init-Dwmpc_S-.mjs → init-DKADNnPy.mjs} +1 -1
  98. package/dist/{intel-CQFYeGEA.mjs → intel-BYvnwlXr.mjs} +1 -1
  99. package/dist/{ips-jTSzoqMU.mjs → ips-CS5SkxUL.mjs} +1 -1
  100. package/dist/{k2-utE2lCYd.mjs → k2-isJz0-93.mjs} +1 -1
  101. package/dist/{kv-Cdh5hHte.mjs → kv-Beih-nj_.mjs} +1 -1
  102. package/dist/{lazy-command-QoHlmXHW.mjs → lazy-command-Dfv2jIGz.mjs} +1 -1
  103. package/dist/{leaked-credential-checks-CqApscD3.mjs → leaked-credential-checks-CP_8DWAX.mjs} +1 -1
  104. package/dist/{load-balancers-w_4Uz9Gi.mjs → load-balancers-fhAs7LaH.mjs} +1 -1
  105. package/dist/{login-CS3KxVbk.mjs → login-BdTYP5Xw.mjs} +1 -1
  106. package/dist/login-Bux329zM.mjs +2 -0
  107. package/dist/{logpush-C76I5dgN.mjs → logpush-fHQiJ9eI.mjs} +1 -1
  108. package/dist/{logs-B5aCYVCv.mjs → logs-Bquc4oxR.mjs} +1 -1
  109. package/dist/{magic-network-monitoring-CGf7cVQ9.mjs → magic-network-monitoring-DqQUEtPW.mjs} +1 -1
  110. package/dist/{magic-transit-CN5noqOR.mjs → magic-transit-py-CXbOl.mjs} +1 -1
  111. package/dist/{managed-defense-DAGr0UGm.mjs → managed-defense-nFm4rVCR.mjs} +1 -1
  112. package/dist/{managed-transforms-_SuwzZ-5.mjs → managed-transforms-2k6tV3U-.mjs} +1 -1
  113. package/dist/{mcp-CzedsjOf.mjs → mcp-BCtJ76cJ.mjs} +1 -1
  114. package/dist/{mesh-DXX1S3pX.mjs → mesh-D2V3ITA7.mjs} +1 -1
  115. package/dist/{migrate-CvRQ4x3_.mjs → migrate-CqUzEP9-.mjs} +1 -1
  116. package/dist/{monetization-8nt9PYln.mjs → monetization-CQL4WEtz.mjs} +1 -1
  117. package/dist/{network-CaiRDY2e.mjs → network-1oR1_5Ak.mjs} +1 -1
  118. package/dist/{network-interconnects-Ad6JbAVd.mjs → network-interconnects-BKRa6OaY.mjs} +1 -1
  119. package/dist/{o11y-DD2Hfnzi.mjs → o11y-B2hny1eT.mjs} +4 -4
  120. package/dist/{oauth-BUcV_xbm.mjs → oauth-CQiiWvag.mjs} +1 -1
  121. package/dist/{oauth-CQRlNgt5.mjs → oauth-Dp9VNyOf.mjs} +1 -1
  122. package/dist/{observability-BzKBUUSf.mjs → observability-ByzMkD8L.mjs} +1 -1
  123. package/dist/{ohttp-gateway-Sej9-GCm.mjs → ohttp-gateway-B67P-f_M.mjs} +1 -1
  124. package/dist/{organizations-DwYsCbYD.mjs → organizations-Dk5cbMB5.mjs} +1 -1
  125. package/dist/package-CcmyQJFT.mjs +2 -0
  126. package/dist/{page-rules-CjufEmIt.mjs → page-rules-hRzoq6WZ.mjs} +1 -1
  127. package/dist/{pages-Dj0Cdf3G.mjs → pages-D_0y5Pbg.mjs} +1 -1
  128. package/dist/{pay-per-crawl-DPVlluRA.mjs → pay-per-crawl-C0ZDkVH8.mjs} +1 -1
  129. package/dist/{pay-per-use-DhuLjaoo.mjs → pay-per-use-Z_LlZyxh.mjs} +1 -1
  130. package/dist/{pipelines-D2pM69oq.mjs → pipelines-B8-zUXTD.mjs} +1 -1
  131. package/dist/{precursor-DzuA1m8D.mjs → precursor-vlW9-fma.mjs} +1 -1
  132. package/dist/{previews-CHHd5Rx7.mjs → previews-DZX0vwDU.mjs} +3 -3
  133. package/dist/{progress-AML-AVs4.mjs → progress-DQfZZwit.mjs} +1 -1
  134. package/dist/{prompt-Bnon9lfK.mjs → prompt-e6K5lhdE.mjs} +1 -1
  135. package/dist/{queues-GDwznw0o.mjs → queues-6WHCb5qi.mjs} +1 -1
  136. package/dist/{r2-B3Xkb0S4.mjs → r2-C9xL1Rcg.mjs} +2 -2
  137. package/dist/{radar-fBT7VIO2.mjs → radar-DN1PIWRf.mjs} +150 -150
  138. package/dist/{raw-fetch-0T1SwPa1.mjs → raw-fetch-DXSBORQI.mjs} +1 -1
  139. package/dist/{realtime-B7mR3XtY.mjs → realtime-CcOSBEFJ.mjs} +1 -1
  140. package/dist/{registrar-DOoxlZc7.mjs → registrar-BjBA2lbF.mjs} +1 -1
  141. package/dist/{registrar-sandbox-DC7xAqqc.mjs → registrar-sandbox-DVeWO8gt.mjs} +1 -1
  142. package/dist/{reporting-DlD7J6Pq.mjs → reporting-cOY97XSy.mjs} +1 -1
  143. package/dist/{request-headers-BEYXy4JN.mjs → request-headers-xtY5gOlq.mjs} +1 -1
  144. package/dist/{request-tracers-DYCGkszp.mjs → request-tracers-bHnQoIpS.mjs} +1 -1
  145. package/dist/{resource-sharing-D_bUv7E8.mjs → resource-sharing-CQMP1o3F.mjs} +1 -1
  146. package/dist/{rules-C4cu3_jr.mjs → rules-CrevxzXm.mjs} +1 -1
  147. package/dist/{rulesets-Bl4mLnXA.mjs → rulesets-DzGcmiGs.mjs} +1 -1
  148. package/dist/{rum-DE_uJb09.mjs → rum-edoW7i0P.mjs} +1 -1
  149. package/dist/run-B6k0nZU4.mjs +2 -0
  150. package/dist/{run-DAg7dfIW.mjs → run-DhU17ztU.mjs} +1 -1
  151. package/dist/{schema-cache-CTVUtkAl.mjs → schema-cache-BFMBra5w.mjs} +1 -1
  152. package/dist/{scim-Dz4r0fnH.mjs → scim-BC31cTiV.mjs} +1 -1
  153. package/dist/{secrets-store-C2GwCUKs.mjs → secrets-store-DJlRawQ0.mjs} +1 -1
  154. package/dist/{security-insights-DZCm5D3U.mjs → security-insights-jHGuq15c.mjs} +1 -1
  155. package/dist/{security-txt-Dbi9KxNc.mjs → security-txt-D1vV2ySL.mjs} +1 -1
  156. package/dist/{session-BEsQIuwP.mjs → session-Py5R3Tdx.mjs} +1 -1
  157. package/dist/shared-C50J5uEm.mjs +2 -0
  158. package/dist/{smart-shield-C2uSFcGN.mjs → smart-shield-YI9Y6xhz.mjs} +1 -1
  159. package/dist/{snippets-BoaGEAC6.mjs → snippets-SKlEbP3W.mjs} +1 -1
  160. package/dist/{spawn-B4y5Urjv.mjs → spawn-BXaiweDp.mjs} +1 -1
  161. package/dist/{spectrum-Bb0KXA8R.mjs → spectrum-CFl8kTtP.mjs} +1 -1
  162. package/dist/{speed-zKYgLTHA.mjs → speed-DekTJTgw.mjs} +1 -1
  163. package/dist/{sql-pjWozuvl.mjs → sql-tkIoPSbE.mjs} +1 -1
  164. package/dist/{src-B8i6_XGg.mjs → src-COKSSJwa.mjs} +5 -5
  165. package/dist/{ssl-C5bg1X0i.mjs → ssl-DRGNVUlP.mjs} +1 -1
  166. package/dist/{static-assets-CTv7XwIQ.mjs → static-assets-pAj1uSDU.mjs} +1 -1
  167. package/dist/{stream-C_FiNrLV.mjs → stream-WHdFw1o1.mjs} +1 -1
  168. package/dist/{tags-CXlivF3y.mjs → tags-CNEWjoac.mjs} +1 -1
  169. package/dist/{telemetry-CtQWhsmy.mjs → telemetry-BCQMv5dO.mjs} +1 -1
  170. package/dist/telemetry-CruYXv5e.mjs +2 -0
  171. package/dist/{tenant-custom-nameservers-DBg9Hzvn.mjs → tenant-custom-nameservers-BCJoh-yz.mjs} +1 -1
  172. package/dist/{tenants-89Q0u5_Q.mjs → tenants-Coo3-wTg.mjs} +1 -1
  173. package/dist/{tunnels-CL2fIINH.mjs → tunnels-Cy3byznJ.mjs} +2 -2
  174. package/dist/{turnstile-D6GtQULo.mjs → turnstile-DvkuMuTq.mjs} +1 -1
  175. package/dist/ui-CA_2sliN.mjs +2 -0
  176. package/dist/{update-check-0kpbTLvy.mjs → update-check-Buyg_Zyb.mjs} +1 -1
  177. package/dist/{update-check-D3axIoUi.mjs → update-check-CV30Z3FO.mjs} +1 -1
  178. package/dist/update-check-worker.mjs +1 -1
  179. package/dist/{url-normalization--iS57OT_.mjs → url-normalization-DJzp3oJN.mjs} +1 -1
  180. package/dist/{url-scanner-C6AtXGc2.mjs → url-scanner-C28ADWWB.mjs} +1 -1
  181. package/dist/{user-C5vRYIta.mjs → user-CiFGo-51.mjs} +1 -1
  182. package/dist/{vectorize-C1Kxb1Ou.mjs → vectorize-DZ-VBQjl.mjs} +1 -1
  183. package/dist/version--BAAeBma.mjs +2 -0
  184. package/dist/{waiting-rooms-BCVZY9vI.mjs → waiting-rooms-mLG31NWt.mjs} +1 -1
  185. package/dist/{web-assets-D2gXqKZS.mjs → web-assets-Caubyaqz.mjs} +1 -1
  186. package/dist/{web3-CJDZQCOk.mjs → web3-Ctcb6rxj.mjs} +1 -1
  187. package/dist/{whoami-BEad9QUB.mjs → whoami-DBZfITBb.mjs} +3 -3
  188. package/dist/whoami-rfo2jx0r.mjs +2 -0
  189. package/dist/{workers-DzXSJMv9.mjs → workers-ClK3WFQg.mjs} +18 -18
  190. package/dist/{workers-for-platforms-CvazgrqD.mjs → workers-for-platforms-D6fknsnw.mjs} +1 -1
  191. package/dist/{workers-vpc-DP4QC6UC.mjs → workers-vpc-B7wRAn-K.mjs} +1 -1
  192. package/dist/{workflows-BSOj56io.mjs → workflows-B0UzguVf.mjs} +1 -1
  193. package/dist/{wrangler-migration-DZ9Oelof.mjs → wrangler-migration-u2oXOk-L.mjs} +2 -2
  194. package/dist/{zaraz-BnQvKXFy.mjs → zaraz-p9rNptt3.mjs} +1 -1
  195. package/dist/{zero-trust-DsslXRub.mjs → zero-trust-Dw5CvLQD.mjs} +1 -1
  196. package/dist/{zones-DQ3SjGsZ.mjs → zones-DzPc0thm.mjs} +1 -1
  197. package/package.json +6 -6
  198. package/dist/auth-CXR2vsII.mjs +0 -2
  199. package/dist/build-ByjJ6yIB.mjs +0 -2
  200. package/dist/command-ycXauMSv.mjs +0 -2
  201. package/dist/deploy-input-BFWpjDVr.mjs +0 -2
  202. package/dist/discover-D9FNaCDK.mjs +0 -2
  203. package/dist/internal-CYrPZ9IX.mjs +0 -4
  204. package/dist/live-hZgMkXJf.mjs +0 -4
  205. package/dist/login-BBSJytOt.mjs +0 -2
  206. package/dist/package-DXaRIx2f.mjs +0 -2
  207. package/dist/ready-BkXNDNTd.mjs +0 -4
  208. package/dist/run-Cg9utScS.mjs +0 -2
  209. package/dist/shared-DqW2vICA.mjs +0 -2
  210. package/dist/signed-url-BhHSAUam.mjs +0 -4
  211. package/dist/telemetry-DDs3zhdw.mjs +0 -2
  212. package/dist/ui-CY75N4Tm.mjs +0 -2
  213. package/dist/version-pcpa_kv3.mjs +0 -2
  214. package/dist/whoami-2eFTt0-Y.mjs +0 -2
@@ -1,2 +1,2 @@
1
1
  #!/usr/bin/env node
2
- import{a as e}from"./cf-QIG83e0V.mjs";import{n as t}from"./version-pcpa_kv3.mjs";import{mkdirSync as n,readFileSync as r,writeFileSync as i}from"node:fs";import{dirname as a,join as o}from"node:path";import{createHash as s}from"node:crypto";function c(n,r){let i=s(`sha256`).update([t,...r].join(` `)).digest(`hex`).slice(0,32);return o(e(),`cache`,n,`${i}.json`)}function l(e,t,n,i){try{let a=JSON.parse(r(c(e,t),`utf-8`));return typeof a?.fetchedAt==`number`&&Date.now()-a.fetchedAt<=n?i(a.value):void 0}catch{return}}function u(e,t,r){try{let o=c(e,t);n(a(o),{recursive:!0}),i(o,JSON.stringify({fetchedAt:Date.now(),value:r}),`utf-8`)}catch{}}export{u as n,l as t};
2
+ import{a as e}from"./cf-QIG83e0V.mjs";import{n as t}from"./version--BAAeBma.mjs";import{mkdirSync as n,readFileSync as r,writeFileSync as i}from"node:fs";import{dirname as a,join as o}from"node:path";import{createHash as s}from"node:crypto";function c(n,r){let i=s(`sha256`).update([t,...r].join(` `)).digest(`hex`).slice(0,32);return o(e(),`cache`,n,`${i}.json`)}function l(e,t,n,i){try{let a=JSON.parse(r(c(e,t),`utf-8`));return typeof a?.fetchedAt==`number`&&Date.now()-a.fetchedAt<=n?i(a.value):void 0}catch{return}}function u(e,t,r){try{let o=c(e,t);n(a(o),{recursive:!0}),i(o,JSON.stringify({fetchedAt:Date.now(),value:r}),`utf-8`)}catch{}}export{u as n,l as t};
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{r as n,t as r}from"./body-parser-HN91kAf0.mjs";import{a as i,t as a}from"./context-DlFhI9cN.mjs";import{t as o}from"./dry-run-mrA7FFLR.mjs";import{n as s}from"./input-validation-D7z60HJH.mjs";import{t as c}from"./local-B3zt9PXR.mjs";import{t as l}from"./run-DAg7dfIW.mjs";import{t as u}from"./output-PRKYaJuo.mjs";import{t as d}from"./progress-AML-AVs4.mjs";import{a as f,n as p}from"./prompt-Bnon9lfK.mjs";import"./telemetry-DDs3zhdw.mjs";var m={method:`POST`,path:t=>e`/accounts/${t.account_id}/dls/regional_services/prefix_bindings`,body:`json`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,409:`ConflictError`,500:`InternalServerError`}};function h(e){return e.usage(`$0 dls regional-services prefix-bindings create
2
+ import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-NIRm11Ab.mjs";import{r as n,t as r}from"./body-parser-HN91kAf0.mjs";import{a as i,t as a}from"./context-CroqTqbk.mjs";import{t as o}from"./dry-run-mrA7FFLR.mjs";import{n as s}from"./input-validation-D7z60HJH.mjs";import{t as c}from"./local-B3zt9PXR.mjs";import{t as l}from"./run-DhU17ztU.mjs";import{t as u}from"./output-PRKYaJuo.mjs";import{t as d}from"./progress-DQfZZwit.mjs";import{a as f,n as p}from"./prompt-e6K5lhdE.mjs";import"./telemetry-CruYXv5e.mjs";var m={method:`POST`,path:t=>e`/accounts/${t.account_id}/dls/regional_services/prefix_bindings`,body:`json`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,409:`ConflictError`,500:`InternalServerError`}};function h(e){return e.usage(`$0 dls regional-services prefix-bindings create
3
3
 
4
4
  Bind a CIDR from a BYOIP prefix to a region. This requires the **IP Prefixes Write** permission in addition to **DLS Write**, because the binding is created against a BYOIP prefix in Addressing.`).option(`cidr`,{type:`string`,description:`IP prefix in CIDR notation to bind.`}).option(`prefix-id`,{type:`string`,description:`The ID of the parent IP prefix that contains the CIDR.`}).option(`region-key`,{type:`string`,description:`Region key from managed regions (e.g., "us", "eu").`}).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 DLS prefix binding`,builder:h,handler:async e=>l({command:`dls regional-services prefix-bindings create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();o({command:`cf dls regional-services prefix-bindings create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/dls/regional_services/prefix_bindings`,pathParams:{},bodyKind:`json`,body:e.body===void 0?r({cidr:s(e.cidr,`cidr`,`text`),prefix_id:s(e[`prefix-id`],`prefix-id`,`text`),region_key:s(e[`region-key`],`region-key`,`text`)}):n(e.body)});return}let l=e.body===void 0?void 0:n(e.body),p=await t(e),h=e.local?c:await a();if(e.accountId=h,e.body!==void 0){let e=l,t=await d(`Creating`,async()=>p.send(m,{body:e,account_id:h}));u(t,{successLabel:`Created`});return}e.cidr===void 0&&(e.cidr=await f(`cidr`,`IP prefix in CIDR notation to bind.`)),e[`prefix-id`]===void 0&&(e[`prefix-id`]=await f(`prefix-id`,`The ID of the parent IP prefix that contains the CIDR.`)),e[`region-key`]===void 0&&(e[`region-key`]=await f(`region-key`,`Region key from managed regions (e.g., "us", "eu").`));let g=r({cidr:s(e.cidr,`cidr`,`text`),prefix_id:s(e[`prefix-id`],`prefix-id`,`text`),region_key:s(e[`region-key`],`region-key`,`text`)}),_=await d(`Creating`,async()=>p.send(m,{body:g,account_id:h}));u(_,{successLabel:`Created`})})};var _={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/dls/regional_services/prefix_bindings/${t.binding_id}`,errors:{401:`UnauthorizedError`,403:`ForbiddenError`,404:`NotFoundError`,500:`InternalServerError`}};function v(e){return e.usage(`$0 dls regional-services prefix-bindings delete <binding-id>
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{i as t,n}from"./auth-cj71dGxS.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{a as i,i as a,t as o}from"./context-DlFhI9cN.mjs";import{t as s}from"./output-PRKYaJuo.mjs";import{t as c}from"./progress-AML-AVs4.mjs";import{a as l,n as u}from"./prompt-Bnon9lfK.mjs";import{t as d}from"./run-DAg7dfIW.mjs";import"./telemetry-DDs3zhdw.mjs";import{o as f,r as p,t as m}from"./body-parser-HN91kAf0.mjs";import{n as h,t as g}from"./input-validation-D7z60HJH.mjs";import{n as ee,t as te}from"./raw-fetch-0T1SwPa1.mjs";import{t as _}from"./local-B3zt9PXR.mjs";var ne={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/dnssec`};function re(e){return e.usage(`$0 dns dnssec delete
2
+ import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{i as t,n}from"./auth-NIRm11Ab.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{a as i,i as a,t as o}from"./context-CroqTqbk.mjs";import{t as s}from"./output-PRKYaJuo.mjs";import{t as c}from"./progress-DQfZZwit.mjs";import{a as l,n as u}from"./prompt-e6K5lhdE.mjs";import{t as d}from"./run-DhU17ztU.mjs";import"./telemetry-CruYXv5e.mjs";import{o as f,r as p,t as m}from"./body-parser-HN91kAf0.mjs";import{n as h,t as g}from"./input-validation-D7z60HJH.mjs";import{n as ee,t as te}from"./raw-fetch-DXSBORQI.mjs";import{t as _}from"./local-B3zt9PXR.mjs";var ne={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/dnssec`};function re(e){return e.usage(`$0 dns dnssec delete
3
3
 
4
4
  Delete DNSSEC.`).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 ie={command:`delete`,describe:`Delete DNSSEC records`,builder:re,handler:async e=>d({command:`dns dnssec delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){r({command:`cf dns dnssec delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/dnssec`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});if(e.zoneId=i,!await u({force:!!e.force}))return;let o=await c(`Deleting`,async()=>t.send(ne,{zone_id:i}));s(o,{successLabel:`Deleted`})})};var v={method:`PATCH`,path:t=>e`/zones/${t.zone_id}/dnssec`,body:`json`};function ae(e){return e.usage(`$0 dns dnssec edit
5
5
 
@@ -91,52 +91,52 @@ Get ACL.`).positional(`acl-id`,{type:`string`,description:`Acl ID`,demandOption:
91
91
 
92
92
  List ACLs.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const At={command:`list`,describe:`List ACLs`,builder:kt,handler:async e=>d({command:`dns zone-transfers acls list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let e=await i();r({command:`cf dns zone-transfers acls list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/secondary_dns/acls`,pathParams:{},bodyKind:`none`});return}let t=await n(e),a=e.local?_:await o();e.accountId=a;let l=await c(`Loading`,async()=>t.send(Ot,{account_id:a}));s(l,{successLabel:`Loaded`})})};var W={method:`PUT`,path:t=>e`/accounts/${t.account_id}/secondary_dns/acls/${t.acl_id}`,body:`json`};function jt(e){return e.usage(`$0 dns zone-transfers acls update <acl-id>
93
93
 
94
- Modify ACL.`).positional(`acl-id`,{type:`string`,description:`Acl ID`,demandOption:!0}).option(`ip-range`,{type:`string`,description:`Allowed IPv4/IPv6 address range of primary or secondary nameservers. This will be applied for the entire account. The IP range is used to allow additional NOTIFY IPs for secondary zones and IPs Cloudflare allows AXFR/IXFR requests from for primary zones. CIDRs are limited to a maximum of /24 for IPv4 and /64 for IPv6 respectively.`}).option(`name`,{type:`string`,description:`The name of the acl.`}).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 Mt={command:`update <acl-id>`,describe:`Update ACL`,builder:jt,handler:async e=>d({command:`dns zone-transfers acls update`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf dns zone-transfers acls update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/secondary_dns/acls/${e[`acl-id`]==null?`<acl-id>`:encodeURIComponent(String(e[`acl-id`]))}`,pathParams:{"acl-id":String(e[`acl-id`]??``)},bodyKind:`json`,body:e.body===void 0?m({ip_range:h(e[`ip-range`],`ip-range`,`text`),name:h(e.name,`name`,`text`)}):p(e.body)});return}let t=e.body===void 0?void 0:p(e.body),a=await n(e),u=e.local?_:await o();if(e.accountId=u,e.body!==void 0){let n=t,r=await c(`Updating`,async()=>a.send(W,{body:n,account_id:u,acl_id:e[`acl-id`]}));s(r,{successLabel:`Updated`});return}e[`ip-range`]===void 0&&(e[`ip-range`]=await l(`ip-range`,`Allowed IPv4/IPv6 address range of primary or secondary nameservers. This will be applied for the entire account. The IP range is used to allow additional NOTIFY IPs for secondary zones and IPs Cloudflare allows AXFR/IXFR requests from for primary zones. CIDRs are limited to a maximum of /24 for IPv4 and /64 for IPv6 respectively.`)),e.name===void 0&&(e.name=await l(`name`,`The name of the acl.`));let d=m({ip_range:h(e[`ip-range`],`ip-range`,`text`),name:h(e.name,`name`,`text`)}),f=await c(`Updating`,async()=>a.send(W,{body:d,account_id:u,acl_id:e[`acl-id`]}));s(f,{successLabel:`Updated`})})},Nt={command:`acls`,describe:`Operations for zone-transfers.acls`,builder:e=>e.command(xt).command(wt).command(Dt).command(At).command(Mt).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var Pt={method:`POST`,path:t=>e`/zones/${t.zone_id}/secondary_dns/force_axfr`};function Ft(e){return e.usage(`$0 dns zone-transfers force-axfr create
94
+ Modify ACL.`).positional(`acl-id`,{type:`string`,description:`Acl ID`,demandOption:!0}).option(`ip-range`,{type:`string`,description:`Allowed IPv4/IPv6 address range of primary or secondary nameservers. This will be applied for the entire account. The IP range is used to allow additional NOTIFY IPs for secondary zones and IPs Cloudflare allows AXFR/IXFR requests from for primary zones. CIDRs are limited to a maximum of /24 for IPv4 and /64 for IPv6 respectively.`}).option(`name`,{type:`string`,description:`The name of the acl.`}).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 Mt={command:`update <acl-id>`,describe:`Update ACL`,builder:jt,handler:async e=>d({command:`dns zone-transfers acls update`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf dns zone-transfers acls update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/secondary_dns/acls/${e[`acl-id`]==null?`<acl-id>`:encodeURIComponent(String(e[`acl-id`]))}`,pathParams:{"acl-id":String(e[`acl-id`]??``)},bodyKind:`json`,body:e.body===void 0?m({ip_range:h(e[`ip-range`],`ip-range`,`text`),name:h(e.name,`name`,`text`)}):p(e.body)});return}let t=e.body===void 0?void 0:p(e.body),a=await n(e),u=e.local?_:await o();if(e.accountId=u,e.body!==void 0){let n=t,r=await c(`Updating`,async()=>a.send(W,{body:n,account_id:u,acl_id:e[`acl-id`]}));s(r,{successLabel:`Updated`});return}e[`ip-range`]===void 0&&(e[`ip-range`]=await l(`ip-range`,`Allowed IPv4/IPv6 address range of primary or secondary nameservers. This will be applied for the entire account. The IP range is used to allow additional NOTIFY IPs for secondary zones and IPs Cloudflare allows AXFR/IXFR requests from for primary zones. CIDRs are limited to a maximum of /24 for IPv4 and /64 for IPv6 respectively.`)),e.name===void 0&&(e.name=await l(`name`,`The name of the acl.`));let d=m({ip_range:h(e[`ip-range`],`ip-range`,`text`),name:h(e.name,`name`,`text`)}),f=await c(`Updating`,async()=>a.send(W,{body:d,account_id:u,acl_id:e[`acl-id`]}));s(f,{successLabel:`Updated`})})},Nt={command:`acls`,describe:`Operations for zone-transfers.acls`,builder:e=>e.command(xt).command(wt).command(Dt).command(At).command(Mt).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var Pt={method:`POST`,path:t=>e`/zones/${t.zone_id}/secondary_dns/force_axfr`};function Ft(e){return e.usage(`$0 dns zone-transfers force-axfr
95
95
 
96
- Sends AXFR zone transfer request to primary nameserver(s).`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const It={command:`create`,describe:`Force AXFR`,builder:Ft,handler:async e=>d({command:`dns zone-transfers force-axfr create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers force-axfr create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/force_axfr`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});e.zoneId=i;let o=await c(`Creating`,async()=>t.send(Pt,{zone_id:i}));s(o,{successLabel:`Created`})})},Lt={command:`force-axfr`,describe:`Operations for zone-transfers.force-axfr`,builder:e=>e.command(It).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var G={method:`POST`,path:t=>e`/zones/${t.zone_id}/secondary_dns/incoming`,body:`json`};function Rt(e){return e.usage(`$0 dns zone-transfers incoming create
96
+ Sends AXFR zone transfer request to primary nameserver(s).`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const It={command:`force-axfr`,describe:`Force AXFR`,builder:Ft,handler:async e=>d({command:`dns zone-transfers force-axfr`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers force-axfr`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/force_axfr`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});e.zoneId=i;let o=await c(`Creating`,async()=>t.send(Pt,{zone_id:i}));s(o,{successLabel:`Created`})})};var G={method:`POST`,path:t=>e`/zones/${t.zone_id}/secondary_dns/incoming`,body:`json`};function Lt(e){return e.usage(`$0 dns zone-transfers incoming create
97
97
 
98
98
  Create secondary zone configuration for incoming zone transfers.`).option(`auto-refresh-seconds`,{type:`number`,description:`How often should a secondary zone auto refresh regardless of DNS NOTIFY.
99
- Not applicable for primary zones.`,default:86400}).option(`name`,{type:`string`,description:`Zone name.`}).option(`peers`,{type:`string`,array:!0,description:`A list of peer tags.`}).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 zt={command:`create`,describe:`Create Secondary Zone Configuration`,builder:Rt,handler:async e=>d({command:`dns zone-transfers incoming create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers incoming create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/incoming`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?m({auto_refresh_seconds:e[`auto-refresh-seconds`],name:h(e.name,`name`,`text`),peers:e.peers}):p(e.body)});return}let t=e.body===void 0?void 0:p(e.body),i=await n(e),o=await a({zone:e.zone},i,{quiet:e.quiet});if(e.zoneId=o,e.body!==void 0){let e=t,n=await c(`Creating`,async()=>i.send(G,{body:e,zone_id:o}));s(n,{successLabel:`Created`});return}if(e[`auto-refresh-seconds`]===void 0)throw Error(`--auto-refresh-seconds is required (or pass --body with this field set).`);if(e.name===void 0&&(e.name=await l(`name`,`Zone name.`)),e.peers===void 0)throw Error(`--peers is required (or pass --body with this field set).`);let u=m({auto_refresh_seconds:e[`auto-refresh-seconds`],name:h(e.name,`name`,`text`),peers:e.peers}),d=await c(`Creating`,async()=>i.send(G,{body:u,zone_id:o}));s(d,{successLabel:`Created`})})};var Bt={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/secondary_dns/incoming`};function Vt(e){return e.usage(`$0 dns zone-transfers incoming delete
99
+ Not applicable for primary zones.`,default:86400}).option(`name`,{type:`string`,description:`Zone name.`}).option(`peers`,{type:`string`,array:!0,description:`A list of peer tags.`}).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 Rt={command:`create`,describe:`Create Secondary Zone Configuration`,builder:Lt,handler:async e=>d({command:`dns zone-transfers incoming create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers incoming create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/incoming`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?m({auto_refresh_seconds:e[`auto-refresh-seconds`],name:h(e.name,`name`,`text`),peers:e.peers}):p(e.body)});return}let t=e.body===void 0?void 0:p(e.body),i=await n(e),o=await a({zone:e.zone},i,{quiet:e.quiet});if(e.zoneId=o,e.body!==void 0){let e=t,n=await c(`Creating`,async()=>i.send(G,{body:e,zone_id:o}));s(n,{successLabel:`Created`});return}if(e[`auto-refresh-seconds`]===void 0)throw Error(`--auto-refresh-seconds is required (or pass --body with this field set).`);if(e.name===void 0&&(e.name=await l(`name`,`Zone name.`)),e.peers===void 0)throw Error(`--peers is required (or pass --body with this field set).`);let u=m({auto_refresh_seconds:e[`auto-refresh-seconds`],name:h(e.name,`name`,`text`),peers:e.peers}),d=await c(`Creating`,async()=>i.send(G,{body:u,zone_id:o}));s(d,{successLabel:`Created`})})};var zt={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/secondary_dns/incoming`};function Bt(e){return e.usage(`$0 dns zone-transfers incoming delete
100
100
 
101
- Delete secondary zone configuration for incoming zone transfers.`).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 Ht={command:`delete`,describe:`Delete Secondary Zone Configuration`,builder:Vt,handler:async e=>d({command:`dns zone-transfers incoming delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers incoming delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/incoming`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});if(e.zoneId=i,!await u({force:!!e.force}))return;let o=await c(`Deleting`,async()=>t.send(Bt,{zone_id:i}));s(o,{successLabel:`Deleted`})})};var Ut={method:`GET`,path:t=>e`/zones/${t.zone_id}/secondary_dns/incoming`};function Wt(e){return e.usage(`$0 dns zone-transfers incoming get
101
+ Delete secondary zone configuration for incoming zone transfers.`).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 Vt={command:`delete`,describe:`Delete Secondary Zone Configuration`,builder:Bt,handler:async e=>d({command:`dns zone-transfers incoming delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers incoming delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/incoming`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});if(e.zoneId=i,!await u({force:!!e.force}))return;let o=await c(`Deleting`,async()=>t.send(zt,{zone_id:i}));s(o,{successLabel:`Deleted`})})};var Ht={method:`GET`,path:t=>e`/zones/${t.zone_id}/secondary_dns/incoming`};function Ut(e){return e.usage(`$0 dns zone-transfers incoming get
102
102
 
103
- Get secondary zone configuration for incoming zone transfers.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const Gt={command:`get`,describe:`Secondary Zone Configuration Details`,builder:Wt,handler:async e=>d({command:`dns zone-transfers incoming get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers incoming get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/incoming`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});e.zoneId=i;let o=await c(`Loading`,async()=>t.send(Ut,{zone_id:i}));s(o,{successLabel:`Loaded`})})};var K={method:`PUT`,path:t=>e`/zones/${t.zone_id}/secondary_dns/incoming`,body:`json`};function Kt(e){return e.usage(`$0 dns zone-transfers incoming update
103
+ Get secondary zone configuration for incoming zone transfers.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const Wt={command:`get`,describe:`Secondary Zone Configuration Details`,builder:Ut,handler:async e=>d({command:`dns zone-transfers incoming get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers incoming get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/incoming`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});e.zoneId=i;let o=await c(`Loading`,async()=>t.send(Ht,{zone_id:i}));s(o,{successLabel:`Loaded`})})};var K={method:`PUT`,path:t=>e`/zones/${t.zone_id}/secondary_dns/incoming`,body:`json`};function Gt(e){return e.usage(`$0 dns zone-transfers incoming update
104
104
 
105
105
  Update secondary zone configuration for incoming zone transfers.`).option(`auto-refresh-seconds`,{type:`number`,description:`How often should a secondary zone auto refresh regardless of DNS NOTIFY.
106
- Not applicable for primary zones.`}).option(`name`,{type:`string`,description:`Zone name.`}).option(`peers`,{type:`string`,array:!0,description:`A list of peer tags.`}).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 qt={command:`update`,describe:`Update Secondary Zone Configuration`,builder:Kt,handler:async e=>d({command:`dns zone-transfers incoming update`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers incoming update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/incoming`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?m({auto_refresh_seconds:e[`auto-refresh-seconds`],name:h(e.name,`name`,`text`),peers:e.peers}):p(e.body)});return}let t=e.body===void 0?void 0:p(e.body),i=await n(e),o=await a({zone:e.zone},i,{quiet:e.quiet});if(e.zoneId=o,e.body!==void 0){let e=t,n=await c(`Updating`,async()=>i.send(K,{body:e,zone_id:o}));s(n,{successLabel:`Updated`});return}if(e[`auto-refresh-seconds`]===void 0)throw Error(`--auto-refresh-seconds is required (or pass --body with this field set).`);if(e.name===void 0&&(e.name=await l(`name`,`Zone name.`)),e.peers===void 0)throw Error(`--peers is required (or pass --body with this field set).`);let u=m({auto_refresh_seconds:e[`auto-refresh-seconds`],name:h(e.name,`name`,`text`),peers:e.peers}),d=await c(`Updating`,async()=>i.send(K,{body:u,zone_id:o}));s(d,{successLabel:`Updated`})})},Jt={command:`incoming`,describe:`Operations for zone-transfers.incoming`,builder:e=>e.command(zt).command(Ht).command(Gt).command(qt).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var q={method:`POST`,path:t=>e`/zones/${t.zone_id}/secondary_dns/outgoing`,body:`json`};function Yt(e){return e.usage(`$0 dns zone-transfers outgoing create
106
+ Not applicable for primary zones.`}).option(`name`,{type:`string`,description:`Zone name.`}).option(`peers`,{type:`string`,array:!0,description:`A list of peer tags.`}).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 Kt={command:`update`,describe:`Update Secondary Zone Configuration`,builder:Gt,handler:async e=>d({command:`dns zone-transfers incoming update`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers incoming update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/incoming`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?m({auto_refresh_seconds:e[`auto-refresh-seconds`],name:h(e.name,`name`,`text`),peers:e.peers}):p(e.body)});return}let t=e.body===void 0?void 0:p(e.body),i=await n(e),o=await a({zone:e.zone},i,{quiet:e.quiet});if(e.zoneId=o,e.body!==void 0){let e=t,n=await c(`Updating`,async()=>i.send(K,{body:e,zone_id:o}));s(n,{successLabel:`Updated`});return}if(e[`auto-refresh-seconds`]===void 0)throw Error(`--auto-refresh-seconds is required (or pass --body with this field set).`);if(e.name===void 0&&(e.name=await l(`name`,`Zone name.`)),e.peers===void 0)throw Error(`--peers is required (or pass --body with this field set).`);let u=m({auto_refresh_seconds:e[`auto-refresh-seconds`],name:h(e.name,`name`,`text`),peers:e.peers}),d=await c(`Updating`,async()=>i.send(K,{body:u,zone_id:o}));s(d,{successLabel:`Updated`})})},qt={command:`incoming`,describe:`Operations for zone-transfers.incoming`,builder:e=>e.command(Rt).command(Vt).command(Wt).command(Kt).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var q={method:`POST`,path:t=>e`/zones/${t.zone_id}/secondary_dns/outgoing`,body:`json`};function Jt(e){return e.usage(`$0 dns zone-transfers outgoing create
107
107
 
108
- Create primary zone configuration for outgoing zone transfers.`).option(`name`,{type:`string`,description:`Zone name.`}).option(`peers`,{type:`string`,array:!0,description:`A list of peer tags.`}).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 Xt={command:`create`,describe:`Create Primary Zone Configuration`,builder:Yt,handler:async e=>d({command:`dns zone-transfers outgoing create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers outgoing create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/outgoing`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?m({name:h(e.name,`name`,`text`),peers:e.peers}):p(e.body)});return}let t=e.body===void 0?void 0:p(e.body),i=await n(e),o=await a({zone:e.zone},i,{quiet:e.quiet});if(e.zoneId=o,e.body!==void 0){let e=t,n=await c(`Creating`,async()=>i.send(q,{body:e,zone_id:o}));s(n,{successLabel:`Created`});return}if(e.name===void 0&&(e.name=await l(`name`,`Zone name.`)),e.peers===void 0)throw Error(`--peers is required (or pass --body with this field set).`);let u=m({name:h(e.name,`name`,`text`),peers:e.peers}),d=await c(`Creating`,async()=>i.send(q,{body:u,zone_id:o}));s(d,{successLabel:`Created`})})};var Zt={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/secondary_dns/outgoing`};function Qt(e){return e.usage(`$0 dns zone-transfers outgoing delete
108
+ Create primary zone configuration for outgoing zone transfers.`).option(`name`,{type:`string`,description:`Zone name.`}).option(`peers`,{type:`string`,array:!0,description:`A list of peer tags.`}).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 Yt={command:`create`,describe:`Create Primary Zone Configuration`,builder:Jt,handler:async e=>d({command:`dns zone-transfers outgoing create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers outgoing create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/outgoing`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?m({name:h(e.name,`name`,`text`),peers:e.peers}):p(e.body)});return}let t=e.body===void 0?void 0:p(e.body),i=await n(e),o=await a({zone:e.zone},i,{quiet:e.quiet});if(e.zoneId=o,e.body!==void 0){let e=t,n=await c(`Creating`,async()=>i.send(q,{body:e,zone_id:o}));s(n,{successLabel:`Created`});return}if(e.name===void 0&&(e.name=await l(`name`,`Zone name.`)),e.peers===void 0)throw Error(`--peers is required (or pass --body with this field set).`);let u=m({name:h(e.name,`name`,`text`),peers:e.peers}),d=await c(`Creating`,async()=>i.send(q,{body:u,zone_id:o}));s(d,{successLabel:`Created`})})};var Xt={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/secondary_dns/outgoing`};function Zt(e){return e.usage(`$0 dns zone-transfers outgoing delete
109
109
 
110
- Delete primary zone configuration for outgoing zone transfers.`).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 $t={command:`delete`,describe:`Delete Primary Zone Configuration`,builder:Qt,handler:async e=>d({command:`dns zone-transfers outgoing delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers outgoing delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/outgoing`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});if(e.zoneId=i,!await u({force:!!e.force}))return;let o=await c(`Deleting`,async()=>t.send(Zt,{zone_id:i}));s(o,{successLabel:`Deleted`})})};var en={method:`POST`,path:t=>e`/zones/${t.zone_id}/secondary_dns/outgoing/disable`};function tn(e){return e.usage(`$0 dns zone-transfers outgoing disable
110
+ Delete primary zone configuration for outgoing zone transfers.`).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 Qt={command:`delete`,describe:`Delete Primary Zone Configuration`,builder:Zt,handler:async e=>d({command:`dns zone-transfers outgoing delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers outgoing delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/outgoing`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});if(e.zoneId=i,!await u({force:!!e.force}))return;let o=await c(`Deleting`,async()=>t.send(Xt,{zone_id:i}));s(o,{successLabel:`Deleted`})})};var $t={method:`POST`,path:t=>e`/zones/${t.zone_id}/secondary_dns/outgoing/disable`};function en(e){return e.usage(`$0 dns zone-transfers outgoing disable
111
111
 
112
- Disable outgoing zone transfers for primary zone and clears IXFR backlog of primary zone.`).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 nn={command:`disable`,describe:`Disable Outgoing Zone Transfers`,builder:tn,handler:async e=>d({command:`dns zone-transfers outgoing disable`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers outgoing disable`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/outgoing/disable`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});if(e.zoneId=i,!await u({force:!!e.force,message:`This operation turns off outgoing zone transfers for the primary zone, which means secondary zones will stop receiving updates.`}))return;let o=await c(`Processing`,async()=>t.send(en,{zone_id:i}));s(o,{successLabel:`Done`})})};var rn={method:`POST`,path:t=>e`/zones/${t.zone_id}/secondary_dns/outgoing/enable`};function an(e){return e.usage(`$0 dns zone-transfers outgoing enable
112
+ Disable outgoing zone transfers for primary zone and clears IXFR backlog of primary zone.`).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 tn={command:`disable`,describe:`Disable Outgoing Zone Transfers`,builder:en,handler:async e=>d({command:`dns zone-transfers outgoing disable`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers outgoing disable`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/outgoing/disable`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});if(e.zoneId=i,!await u({force:!!e.force,message:`This operation turns off outgoing zone transfers for the primary zone, which means secondary zones will stop receiving updates.`}))return;let o=await c(`Processing`,async()=>t.send($t,{zone_id:i}));s(o,{successLabel:`Done`})})};var nn={method:`POST`,path:t=>e`/zones/${t.zone_id}/secondary_dns/outgoing/enable`};function rn(e){return e.usage(`$0 dns zone-transfers outgoing enable
113
113
 
114
- Enable outgoing zone transfers for primary zone.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const on={command:`enable`,describe:`Enable Outgoing Zone Transfers`,builder:an,handler:async e=>d({command:`dns zone-transfers outgoing enable`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers outgoing enable`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/outgoing/enable`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});e.zoneId=i;let o=await c(`Creating`,async()=>t.send(rn,{zone_id:i}));s(o,{successLabel:`Created`})})};var sn={method:`POST`,path:t=>e`/zones/${t.zone_id}/secondary_dns/outgoing/force_notify`};function cn(e){return e.usage(`$0 dns zone-transfers outgoing force-notify
114
+ Enable outgoing zone transfers for primary zone.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const an={command:`enable`,describe:`Enable Outgoing Zone Transfers`,builder:rn,handler:async e=>d({command:`dns zone-transfers outgoing enable`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers outgoing enable`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/outgoing/enable`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});e.zoneId=i;let o=await c(`Creating`,async()=>t.send(nn,{zone_id:i}));s(o,{successLabel:`Created`})})};var on={method:`POST`,path:t=>e`/zones/${t.zone_id}/secondary_dns/outgoing/force_notify`};function sn(e){return e.usage(`$0 dns zone-transfers outgoing force-notify
115
115
 
116
- Notifies the secondary nameserver(s) and clears IXFR backlog of primary zone.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const ln={command:`force-notify`,describe:`Force DNS NOTIFY`,builder:cn,handler:async e=>d({command:`dns zone-transfers outgoing force-notify`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers outgoing force-notify`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/outgoing/force_notify`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});e.zoneId=i;let o=await c(`Creating`,async()=>t.send(sn,{zone_id:i}));s(o,{successLabel:`Created`})})};var un={method:`GET`,path:t=>e`/zones/${t.zone_id}/secondary_dns/outgoing`};function dn(e){return e.usage(`$0 dns zone-transfers outgoing get
116
+ Notifies the secondary nameserver(s) and clears IXFR backlog of primary zone.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const cn={command:`force-notify`,describe:`Force DNS NOTIFY`,builder:sn,handler:async e=>d({command:`dns zone-transfers outgoing force-notify`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers outgoing force-notify`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/outgoing/force_notify`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});e.zoneId=i;let o=await c(`Creating`,async()=>t.send(on,{zone_id:i}));s(o,{successLabel:`Created`})})};var ln={method:`GET`,path:t=>e`/zones/${t.zone_id}/secondary_dns/outgoing`};function un(e){return e.usage(`$0 dns zone-transfers outgoing get
117
117
 
118
- Get primary zone configuration for outgoing zone transfers.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const fn={command:`get`,describe:`Primary Zone Configuration Details`,builder:dn,handler:async e=>d({command:`dns zone-transfers outgoing get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers outgoing get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/outgoing`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});e.zoneId=i;let o=await c(`Loading`,async()=>t.send(un,{zone_id:i}));s(o,{successLabel:`Loaded`})})};var pn={method:`GET`,path:t=>e`/zones/${t.zone_id}/secondary_dns/outgoing/status`};function mn(e){return e.usage(`$0 dns zone-transfers outgoing status get
118
+ Get primary zone configuration for outgoing zone transfers.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const dn={command:`get`,describe:`Primary Zone Configuration Details`,builder:un,handler:async e=>d({command:`dns zone-transfers outgoing get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers outgoing get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/outgoing`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});e.zoneId=i;let o=await c(`Loading`,async()=>t.send(ln,{zone_id:i}));s(o,{successLabel:`Loaded`})})};var fn={method:`GET`,path:t=>e`/zones/${t.zone_id}/secondary_dns/outgoing/status`};function pn(e){return e.usage(`$0 dns zone-transfers outgoing status
119
119
 
120
- Get primary zone transfer status.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const hn={command:`get`,describe:`Get Outgoing Zone Transfer Status`,builder:mn,handler:async e=>d({command:`dns zone-transfers outgoing status get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers outgoing status get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/outgoing/status`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});e.zoneId=i;let o=await c(`Loading`,async()=>t.send(pn,{zone_id:i}));s(o,{successLabel:`Loaded`})})},gn={command:`status`,describe:`Operations for zone-transfers.outgoing.status`,builder:e=>e.command(hn).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var J={method:`PUT`,path:t=>e`/zones/${t.zone_id}/secondary_dns/outgoing`,body:`json`};function _n(e){return e.usage(`$0 dns zone-transfers outgoing update
120
+ Get primary zone transfer status.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const mn={command:`status`,describe:`Get Outgoing Zone Transfer Status`,builder:pn,handler:async e=>d({command:`dns zone-transfers outgoing status`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers outgoing status`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/outgoing/status`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let t=await n(e),i=await a({zone:e.zone},t,{quiet:e.quiet});e.zoneId=i;let o=await c(`Loading`,async()=>t.send(fn,{zone_id:i}));s(o,{successLabel:`Loaded`})})};var J={method:`PUT`,path:t=>e`/zones/${t.zone_id}/secondary_dns/outgoing`,body:`json`};function hn(e){return e.usage(`$0 dns zone-transfers outgoing update
121
121
 
122
- Update primary zone configuration for outgoing zone transfers.`).option(`name`,{type:`string`,description:`Zone name.`}).option(`peers`,{type:`string`,array:!0,description:`A list of peer tags.`}).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 vn={command:`update`,describe:`Update Primary Zone Configuration`,builder:_n,handler:async e=>d({command:`dns zone-transfers outgoing update`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers outgoing update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/outgoing`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?m({name:h(e.name,`name`,`text`),peers:e.peers}):p(e.body)});return}let t=e.body===void 0?void 0:p(e.body),i=await n(e),o=await a({zone:e.zone},i,{quiet:e.quiet});if(e.zoneId=o,e.body!==void 0){let e=t,n=await c(`Updating`,async()=>i.send(J,{body:e,zone_id:o}));s(n,{successLabel:`Updated`});return}if(e.name===void 0&&(e.name=await l(`name`,`Zone name.`)),e.peers===void 0)throw Error(`--peers is required (or pass --body with this field set).`);let u=m({name:h(e.name,`name`,`text`),peers:e.peers}),d=await c(`Updating`,async()=>i.send(J,{body:u,zone_id:o}));s(d,{successLabel:`Updated`})})},yn={command:`outgoing`,describe:`Operations for zone-transfers.outgoing`,builder:e=>e.command(Xt).command($t).command(nn).command(on).command(ln).command(fn).command(vn).command(gn).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var Y={method:`POST`,path:t=>e`/accounts/${t.account_id}/secondary_dns/peers`,body:`json`};function bn(e){return e.usage(`$0 dns zone-transfers peers create
122
+ Update primary zone configuration for outgoing zone transfers.`).option(`name`,{type:`string`,description:`Zone name.`}).option(`peers`,{type:`string`,array:!0,description:`A list of peer tags.`}).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 gn={command:`update`,describe:`Update Primary Zone Configuration`,builder:hn,handler:async e=>d({command:`dns zone-transfers outgoing update`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf dns zone-transfers outgoing update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/secondary_dns/outgoing`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?m({name:h(e.name,`name`,`text`),peers:e.peers}):p(e.body)});return}let t=e.body===void 0?void 0:p(e.body),i=await n(e),o=await a({zone:e.zone},i,{quiet:e.quiet});if(e.zoneId=o,e.body!==void 0){let e=t,n=await c(`Updating`,async()=>i.send(J,{body:e,zone_id:o}));s(n,{successLabel:`Updated`});return}if(e.name===void 0&&(e.name=await l(`name`,`Zone name.`)),e.peers===void 0)throw Error(`--peers is required (or pass --body with this field set).`);let u=m({name:h(e.name,`name`,`text`),peers:e.peers}),d=await c(`Updating`,async()=>i.send(J,{body:u,zone_id:o}));s(d,{successLabel:`Updated`})})},_n={command:`outgoing`,describe:`Operations for zone-transfers.outgoing`,builder:e=>e.command(Yt).command(Qt).command(tn).command(an).command(cn).command(dn).command(mn).command(gn).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var Y={method:`POST`,path:t=>e`/accounts/${t.account_id}/secondary_dns/peers`,body:`json`};function vn(e){return e.usage(`$0 dns zone-transfers peers create
123
123
 
124
- Create Peer.`).option(`name`,{type:`string`,description:`The name of the peer.`}).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 xn={command:`create`,describe:`Create Peer`,builder:bn,handler:async e=>d({command:`dns zone-transfers peers create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf dns zone-transfers peers create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/secondary_dns/peers`,pathParams:{},bodyKind:`json`,body:e.body===void 0?m({name:h(e.name,`name`,`text`)}):p(e.body)});return}let t=e.body===void 0?void 0:p(e.body),a=await n(e),u=e.local?_:await o();if(e.accountId=u,e.body!==void 0){let e=t,n=await c(`Creating`,async()=>a.send(Y,{body:e,account_id:u}));s(n,{successLabel:`Created`});return}e.name===void 0&&(e.name=await l(`name`,`The name of the peer.`));let d=m({name:h(e.name,`name`,`text`)}),f=await c(`Creating`,async()=>a.send(Y,{body:d,account_id:u}));s(f,{successLabel:`Created`})})};var Sn={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/secondary_dns/peers/${t.peer_id}`};function Cn(e){return e.usage(`$0 dns zone-transfers peers delete <peer-id>
124
+ Create Peer.`).option(`name`,{type:`string`,description:`The name of the peer.`}).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 yn={command:`create`,describe:`Create Peer`,builder:vn,handler:async e=>d({command:`dns zone-transfers peers create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf dns zone-transfers peers create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/secondary_dns/peers`,pathParams:{},bodyKind:`json`,body:e.body===void 0?m({name:h(e.name,`name`,`text`)}):p(e.body)});return}let t=e.body===void 0?void 0:p(e.body),a=await n(e),u=e.local?_:await o();if(e.accountId=u,e.body!==void 0){let e=t,n=await c(`Creating`,async()=>a.send(Y,{body:e,account_id:u}));s(n,{successLabel:`Created`});return}e.name===void 0&&(e.name=await l(`name`,`The name of the peer.`));let d=m({name:h(e.name,`name`,`text`)}),f=await c(`Creating`,async()=>a.send(Y,{body:d,account_id:u}));s(f,{successLabel:`Created`})})};var bn={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/secondary_dns/peers/${t.peer_id}`};function xn(e){return e.usage(`$0 dns zone-transfers peers delete <peer-id>
125
125
 
126
- Delete Peer.`).positional(`peer-id`,{type:`string`,description:`Peer ID`,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 wn={command:`delete <peer-id>`,describe:`Delete Peer`,builder:Cn,handler:async e=>d({command:`dns zone-transfers peers delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf dns zone-transfers peers delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/secondary_dns/peers/${e[`peer-id`]==null?`<peer-id>`:encodeURIComponent(String(e[`peer-id`]))}`,pathParams:{"peer-id":String(e[`peer-id`]??``)},bodyKind:`none`});return}let t=await n(e),a=e.local?_:await o();if(e.accountId=a,!await u({force:!!e.force}))return;let l=await c(`Deleting`,async()=>t.send(Sn,{account_id:a,peer_id:e[`peer-id`]}));s(l,{successLabel:`Deleted`})})};var Tn={method:`GET`,path:t=>e`/accounts/${t.account_id}/secondary_dns/peers/${t.peer_id}`};function En(e){return e.usage(`$0 dns zone-transfers peers get <peer-id>
126
+ Delete Peer.`).positional(`peer-id`,{type:`string`,description:`Peer ID`,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 Sn={command:`delete <peer-id>`,describe:`Delete Peer`,builder:xn,handler:async e=>d({command:`dns zone-transfers peers delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf dns zone-transfers peers delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/secondary_dns/peers/${e[`peer-id`]==null?`<peer-id>`:encodeURIComponent(String(e[`peer-id`]))}`,pathParams:{"peer-id":String(e[`peer-id`]??``)},bodyKind:`none`});return}let t=await n(e),a=e.local?_:await o();if(e.accountId=a,!await u({force:!!e.force}))return;let l=await c(`Deleting`,async()=>t.send(bn,{account_id:a,peer_id:e[`peer-id`]}));s(l,{successLabel:`Deleted`})})};var Cn={method:`GET`,path:t=>e`/accounts/${t.account_id}/secondary_dns/peers/${t.peer_id}`};function wn(e){return e.usage(`$0 dns zone-transfers peers get <peer-id>
127
127
 
128
- Get Peer.`).positional(`peer-id`,{type:`string`,description:`Peer ID`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const Dn={command:`get <peer-id>`,describe:`Peer Details`,builder:En,handler:async e=>d({command:`dns zone-transfers peers get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf dns zone-transfers peers get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/secondary_dns/peers/${e[`peer-id`]==null?`<peer-id>`:encodeURIComponent(String(e[`peer-id`]))}`,pathParams:{"peer-id":String(e[`peer-id`]??``)},bodyKind:`none`});return}let t=await n(e),a=e.local?_:await o();e.accountId=a;let l=await c(`Loading`,async()=>t.send(Tn,{account_id:a,peer_id:e[`peer-id`]}));s(l,{successLabel:`Loaded`})})};var On={method:`GET`,path:t=>e`/accounts/${t.account_id}/secondary_dns/peers`};function kn(e){return e.usage(`$0 dns zone-transfers peers list
128
+ Get Peer.`).positional(`peer-id`,{type:`string`,description:`Peer ID`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const Tn={command:`get <peer-id>`,describe:`Peer Details`,builder:wn,handler:async e=>d({command:`dns zone-transfers peers get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf dns zone-transfers peers get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/secondary_dns/peers/${e[`peer-id`]==null?`<peer-id>`:encodeURIComponent(String(e[`peer-id`]))}`,pathParams:{"peer-id":String(e[`peer-id`]??``)},bodyKind:`none`});return}let t=await n(e),a=e.local?_:await o();e.accountId=a;let l=await c(`Loading`,async()=>t.send(Cn,{account_id:a,peer_id:e[`peer-id`]}));s(l,{successLabel:`Loaded`})})};var En={method:`GET`,path:t=>e`/accounts/${t.account_id}/secondary_dns/peers`};function Dn(e){return e.usage(`$0 dns zone-transfers peers list
129
129
 
130
- List Peers.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const An={command:`list`,describe:`List Peers`,builder:kn,handler:async e=>d({command:`dns zone-transfers peers list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let e=await i();r({command:`cf dns zone-transfers peers list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/secondary_dns/peers`,pathParams:{},bodyKind:`none`});return}let t=await n(e),a=e.local?_:await o();e.accountId=a;let l=await c(`Loading`,async()=>t.send(On,{account_id:a}));s(l,{successLabel:`Loaded`})})};var X={method:`PUT`,path:t=>e`/accounts/${t.account_id}/secondary_dns/peers/${t.peer_id}`,body:`json`};function jn(e){return e.usage(`$0 dns zone-transfers peers update <peer-id>
130
+ List Peers.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const On={command:`list`,describe:`List Peers`,builder:Dn,handler:async e=>d({command:`dns zone-transfers peers list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let e=await i();r({command:`cf dns zone-transfers peers list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/secondary_dns/peers`,pathParams:{},bodyKind:`none`});return}let t=await n(e),a=e.local?_:await o();e.accountId=a;let l=await c(`Loading`,async()=>t.send(En,{account_id:a}));s(l,{successLabel:`Loaded`})})};var X={method:`PUT`,path:t=>e`/accounts/${t.account_id}/secondary_dns/peers/${t.peer_id}`,body:`json`};function kn(e){return e.usage(`$0 dns zone-transfers peers update <peer-id>
131
131
 
132
- Modify Peer.`).positional(`peer-id`,{type:`string`,description:`Peer ID`,demandOption:!0}).option(`ip`,{type:`string`,description:`IPv4/IPv6 address of primary or secondary nameserver, depending on what zone this peer is linked to. For primary zones this IP defines the IP of the secondary nameserver Cloudflare will NOTIFY upon zone changes. For secondary zones this IP defines the IP of the primary nameserver Cloudflare will send AXFR/IXFR requests to.`}).option(`ixfr-enable`,{type:`boolean`,description:`Enable IXFR transfer protocol, default is AXFR. Only applicable to secondary zones.`}).option(`name`,{type:`string`,description:`The name of the peer.`}).option(`port`,{type:`number`,description:`DNS port of primary or secondary nameserver, depending on what zone this peer is linked to.`}).option(`tsig-id`,{type:`string`,description:`TSIG authentication will be used for zone transfer if configured.`}).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 Mn={command:`update <peer-id>`,describe:`Update Peer`,builder:jn,handler:async e=>d({command:`dns zone-transfers peers update`,classification:{safeFlags:[`ixfr-enable`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf dns zone-transfers peers update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/secondary_dns/peers/${e[`peer-id`]==null?`<peer-id>`:encodeURIComponent(String(e[`peer-id`]))}`,pathParams:{"peer-id":String(e[`peer-id`]??``)},bodyKind:`json`,body:e.body===void 0?m({ip:h(e.ip,`ip`,`text`),ixfr_enable:e[`ixfr-enable`],name:h(e.name,`name`,`text`),port:e.port,tsig_id:h(e[`tsig-id`],`tsig-id`,`text`)}):p(e.body)});return}let t=e.body===void 0?void 0:p(e.body),a=await n(e),u=e.local?_:await o();if(e.accountId=u,e.body!==void 0){let n=t,r=await c(`Updating`,async()=>a.send(X,{body:n,account_id:u,peer_id:e[`peer-id`]}));s(r,{successLabel:`Updated`});return}e.name===void 0&&(e.name=await l(`name`,`The name of the peer.`));let d=m({ip:h(e.ip,`ip`,`text`),ixfr_enable:e[`ixfr-enable`],name:h(e.name,`name`,`text`),port:e.port,tsig_id:h(e[`tsig-id`],`tsig-id`,`text`)}),f=await c(`Updating`,async()=>a.send(X,{body:d,account_id:u,peer_id:e[`peer-id`]}));s(f,{successLabel:`Updated`})})},Nn={command:`peers`,describe:`Operations for zone-transfers.peers`,builder:e=>e.command(xn).command(wn).command(Dn).command(An).command(Mn).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var Z={method:`POST`,path:t=>e`/accounts/${t.account_id}/secondary_dns/tsigs`,body:`json`};function Pn(e){return e.usage(`$0 dns zone-transfers tsigs create
132
+ Modify Peer.`).positional(`peer-id`,{type:`string`,description:`Peer ID`,demandOption:!0}).option(`ip`,{type:`string`,description:`IPv4/IPv6 address of primary or secondary nameserver, depending on what zone this peer is linked to. For primary zones this IP defines the IP of the secondary nameserver Cloudflare will NOTIFY upon zone changes. For secondary zones this IP defines the IP of the primary nameserver Cloudflare will send AXFR/IXFR requests to.`}).option(`ixfr-enable`,{type:`boolean`,description:`Enable IXFR transfer protocol, default is AXFR. Only applicable to secondary zones.`}).option(`name`,{type:`string`,description:`The name of the peer.`}).option(`port`,{type:`number`,description:`DNS port of primary or secondary nameserver, depending on what zone this peer is linked to.`}).option(`tsig-id`,{type:`string`,description:`TSIG authentication will be used for zone transfer if configured.`}).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 An={command:`update <peer-id>`,describe:`Update Peer`,builder:kn,handler:async e=>d({command:`dns zone-transfers peers update`,classification:{safeFlags:[`ixfr-enable`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf dns zone-transfers peers update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/secondary_dns/peers/${e[`peer-id`]==null?`<peer-id>`:encodeURIComponent(String(e[`peer-id`]))}`,pathParams:{"peer-id":String(e[`peer-id`]??``)},bodyKind:`json`,body:e.body===void 0?m({ip:h(e.ip,`ip`,`text`),ixfr_enable:e[`ixfr-enable`],name:h(e.name,`name`,`text`),port:e.port,tsig_id:h(e[`tsig-id`],`tsig-id`,`text`)}):p(e.body)});return}let t=e.body===void 0?void 0:p(e.body),a=await n(e),u=e.local?_:await o();if(e.accountId=u,e.body!==void 0){let n=t,r=await c(`Updating`,async()=>a.send(X,{body:n,account_id:u,peer_id:e[`peer-id`]}));s(r,{successLabel:`Updated`});return}e.name===void 0&&(e.name=await l(`name`,`The name of the peer.`));let d=m({ip:h(e.ip,`ip`,`text`),ixfr_enable:e[`ixfr-enable`],name:h(e.name,`name`,`text`),port:e.port,tsig_id:h(e[`tsig-id`],`tsig-id`,`text`)}),f=await c(`Updating`,async()=>a.send(X,{body:d,account_id:u,peer_id:e[`peer-id`]}));s(f,{successLabel:`Updated`})})},jn={command:`peers`,describe:`Operations for zone-transfers.peers`,builder:e=>e.command(yn).command(Sn).command(Tn).command(On).command(An).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var Z={method:`POST`,path:t=>e`/accounts/${t.account_id}/secondary_dns/tsigs`,body:`json`};function Mn(e){return e.usage(`$0 dns zone-transfers tsigs create
133
133
 
134
- Create TSIG.`).option(`algo`,{type:`string`,description:`TSIG algorithm.`}).option(`name`,{type:`string`,description:`TSIG key name.`}).option(`secret`,{type:`string`,description:`TSIG secret.`}).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 Q={command:`create`,describe:`Create TSIG`,builder:Pn,handler:async e=>d({command:`dns zone-transfers tsigs create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf dns zone-transfers tsigs create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/secondary_dns/tsigs`,pathParams:{},bodyKind:`json`,body:e.body===void 0?m({algo:h(e.algo,`algo`,`text`),name:h(e.name,`name`,`text`),secret:h(e.secret,`secret`,`text`)}):p(e.body),sensitiveBodyPaths:[[`secret`]]});return}let t=e.body===void 0?void 0:p(e.body),a=await n(e),u=e.local?_:await o();if(e.accountId=u,e.body!==void 0){let e=t,n=await c(`Creating`,async()=>a.send(Z,{body:e,account_id:u}));s(n,{successLabel:`Created`});return}e.algo===void 0&&(e.algo=await l(`algo`,`TSIG algorithm.`)),e.name===void 0&&(e.name=await l(`name`,`TSIG key name.`)),e.secret===void 0&&(e.secret=await l(`secret`,`TSIG secret.`,{kind:`secret`}));let d=m({algo:h(e.algo,`algo`,`text`),name:h(e.name,`name`,`text`),secret:h(e.secret,`secret`,`text`)}),f=await c(`Creating`,async()=>a.send(Z,{body:d,account_id:u}));s(f,{successLabel:`Created`})})};var Fn={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/secondary_dns/tsigs/${t.tsig_id}`};function In(e){return e.usage(`$0 dns zone-transfers tsigs delete <tsig-id>
134
+ Create TSIG.`).option(`algo`,{type:`string`,description:`TSIG algorithm.`}).option(`name`,{type:`string`,description:`TSIG key name.`}).option(`secret`,{type:`string`,description:`TSIG secret.`}).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 Nn={command:`create`,describe:`Create TSIG`,builder:Mn,handler:async e=>d({command:`dns zone-transfers tsigs create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf dns zone-transfers tsigs create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/secondary_dns/tsigs`,pathParams:{},bodyKind:`json`,body:e.body===void 0?m({algo:h(e.algo,`algo`,`text`),name:h(e.name,`name`,`text`),secret:h(e.secret,`secret`,`text`)}):p(e.body),sensitiveBodyPaths:[[`secret`]]});return}let t=e.body===void 0?void 0:p(e.body),a=await n(e),u=e.local?_:await o();if(e.accountId=u,e.body!==void 0){let e=t,n=await c(`Creating`,async()=>a.send(Z,{body:e,account_id:u}));s(n,{successLabel:`Created`});return}e.algo===void 0&&(e.algo=await l(`algo`,`TSIG algorithm.`)),e.name===void 0&&(e.name=await l(`name`,`TSIG key name.`)),e.secret===void 0&&(e.secret=await l(`secret`,`TSIG secret.`,{kind:`secret`}));let d=m({algo:h(e.algo,`algo`,`text`),name:h(e.name,`name`,`text`),secret:h(e.secret,`secret`,`text`)}),f=await c(`Creating`,async()=>a.send(Z,{body:d,account_id:u}));s(f,{successLabel:`Created`})})};var Pn={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/secondary_dns/tsigs/${t.tsig_id}`};function Q(e){return e.usage(`$0 dns zone-transfers tsigs delete <tsig-id>
135
135
 
136
- Delete TSIG.`).positional(`tsig-id`,{type:`string`,description:`Tsig ID`,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 Ln={command:`delete <tsig-id>`,describe:`Delete TSIG`,builder:In,handler:async e=>d({command:`dns zone-transfers tsigs delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf dns zone-transfers tsigs delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/secondary_dns/tsigs/${e[`tsig-id`]==null?`<tsig-id>`:encodeURIComponent(String(e[`tsig-id`]))}`,pathParams:{"tsig-id":String(e[`tsig-id`]??``)},bodyKind:`none`});return}let t=await n(e),a=e.local?_:await o();if(e.accountId=a,!await u({force:!!e.force}))return;let l=await c(`Deleting`,async()=>t.send(Fn,{account_id:a,tsig_id:e[`tsig-id`]}));s(l,{successLabel:`Deleted`})})};var Rn={method:`GET`,path:t=>e`/accounts/${t.account_id}/secondary_dns/tsigs/${t.tsig_id}`};function zn(e){return e.usage(`$0 dns zone-transfers tsigs get <tsig-id>
136
+ Delete TSIG.`).positional(`tsig-id`,{type:`string`,description:`Tsig ID`,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 Fn={command:`delete <tsig-id>`,describe:`Delete TSIG`,builder:Q,handler:async e=>d({command:`dns zone-transfers tsigs delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf dns zone-transfers tsigs delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/secondary_dns/tsigs/${e[`tsig-id`]==null?`<tsig-id>`:encodeURIComponent(String(e[`tsig-id`]))}`,pathParams:{"tsig-id":String(e[`tsig-id`]??``)},bodyKind:`none`});return}let t=await n(e),a=e.local?_:await o();if(e.accountId=a,!await u({force:!!e.force}))return;let l=await c(`Deleting`,async()=>t.send(Pn,{account_id:a,tsig_id:e[`tsig-id`]}));s(l,{successLabel:`Deleted`})})};var In={method:`GET`,path:t=>e`/accounts/${t.account_id}/secondary_dns/tsigs/${t.tsig_id}`};function Ln(e){return e.usage(`$0 dns zone-transfers tsigs get <tsig-id>
137
137
 
138
- Get TSIG.`).positional(`tsig-id`,{type:`string`,description:`Tsig ID`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const Bn={command:`get <tsig-id>`,describe:`TSIG Details`,builder:zn,handler:async e=>d({command:`dns zone-transfers tsigs get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf dns zone-transfers tsigs get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/secondary_dns/tsigs/${e[`tsig-id`]==null?`<tsig-id>`:encodeURIComponent(String(e[`tsig-id`]))}`,pathParams:{"tsig-id":String(e[`tsig-id`]??``)},bodyKind:`none`});return}let t=await n(e),a=e.local?_:await o();e.accountId=a;let l=await c(`Loading`,async()=>t.send(Rn,{account_id:a,tsig_id:e[`tsig-id`]}));s(l,{successLabel:`Loaded`})})};var Vn={method:`GET`,path:t=>e`/accounts/${t.account_id}/secondary_dns/tsigs`};function Hn(e){return e.usage(`$0 dns zone-transfers tsigs list
138
+ Get TSIG.`).positional(`tsig-id`,{type:`string`,description:`Tsig ID`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const Rn={command:`get <tsig-id>`,describe:`TSIG Details`,builder:Ln,handler:async e=>d({command:`dns zone-transfers tsigs get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf dns zone-transfers tsigs get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/secondary_dns/tsigs/${e[`tsig-id`]==null?`<tsig-id>`:encodeURIComponent(String(e[`tsig-id`]))}`,pathParams:{"tsig-id":String(e[`tsig-id`]??``)},bodyKind:`none`});return}let t=await n(e),a=e.local?_:await o();e.accountId=a;let l=await c(`Loading`,async()=>t.send(In,{account_id:a,tsig_id:e[`tsig-id`]}));s(l,{successLabel:`Loaded`})})};var zn={method:`GET`,path:t=>e`/accounts/${t.account_id}/secondary_dns/tsigs`};function Bn(e){return e.usage(`$0 dns zone-transfers tsigs list
139
139
 
140
- List TSIGs.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const Un={command:`list`,describe:`List TSIGs`,builder:Hn,handler:async e=>d({command:`dns zone-transfers tsigs list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let e=await i();r({command:`cf dns zone-transfers tsigs list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/secondary_dns/tsigs`,pathParams:{},bodyKind:`none`});return}let t=await n(e),a=e.local?_:await o();e.accountId=a;let l=await c(`Loading`,async()=>t.send(Vn,{account_id:a}));s(l,{successLabel:`Loaded`})})};var $={method:`PUT`,path:t=>e`/accounts/${t.account_id}/secondary_dns/tsigs/${t.tsig_id}`,body:`json`};function Wn(e){return e.usage(`$0 dns zone-transfers tsigs update <tsig-id>
140
+ List TSIGs.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const Vn={command:`list`,describe:`List TSIGs`,builder:Bn,handler:async e=>d({command:`dns zone-transfers tsigs list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let e=await i();r({command:`cf dns zone-transfers tsigs list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/secondary_dns/tsigs`,pathParams:{},bodyKind:`none`});return}let t=await n(e),a=e.local?_:await o();e.accountId=a;let l=await c(`Loading`,async()=>t.send(zn,{account_id:a}));s(l,{successLabel:`Loaded`})})};var $={method:`PUT`,path:t=>e`/accounts/${t.account_id}/secondary_dns/tsigs/${t.tsig_id}`,body:`json`};function Hn(e){return e.usage(`$0 dns zone-transfers tsigs update <tsig-id>
141
141
 
142
- Modify TSIG.`).positional(`tsig-id`,{type:`string`,description:`Tsig ID`,demandOption:!0}).option(`algo`,{type:`string`,description:`TSIG algorithm.`}).option(`name`,{type:`string`,description:`TSIG key name.`}).option(`secret`,{type:`string`,description:`TSIG secret.`}).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 Gn={command:`update <tsig-id>`,describe:`Update TSIG`,builder:Wn,handler:async e=>d({command:`dns zone-transfers tsigs update`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf dns zone-transfers tsigs update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/secondary_dns/tsigs/${e[`tsig-id`]==null?`<tsig-id>`:encodeURIComponent(String(e[`tsig-id`]))}`,pathParams:{"tsig-id":String(e[`tsig-id`]??``)},bodyKind:`json`,body:e.body===void 0?m({algo:h(e.algo,`algo`,`text`),name:h(e.name,`name`,`text`),secret:h(e.secret,`secret`,`text`)}):p(e.body),sensitiveBodyPaths:[[`secret`]]});return}let t=e.body===void 0?void 0:p(e.body),a=await n(e),u=e.local?_:await o();if(e.accountId=u,e.body!==void 0){let n=t,r=await c(`Updating`,async()=>a.send($,{body:n,account_id:u,tsig_id:e[`tsig-id`]}));s(r,{successLabel:`Updated`});return}e.algo===void 0&&(e.algo=await l(`algo`,`TSIG algorithm.`)),e.name===void 0&&(e.name=await l(`name`,`TSIG key name.`)),e.secret===void 0&&(e.secret=await l(`secret`,`TSIG secret.`,{kind:`secret`}));let d=m({algo:h(e.algo,`algo`,`text`),name:h(e.name,`name`,`text`),secret:h(e.secret,`secret`,`text`)}),f=await c(`Updating`,async()=>a.send($,{body:d,account_id:u,tsig_id:e[`tsig-id`]}));s(f,{successLabel:`Updated`})})},Kn={command:`tsigs`,describe:`Operations for zone-transfers.tsigs`,builder:e=>e.command(Q).command(Ln).command(Bn).command(Un).command(Gn).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},qn={command:`zone-transfers`,describe:`Operations for zone-transfers`,builder:e=>e.command(Nt).command(Lt).command(Jt).command(yn).command(Nn).command(Kn).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},Jn={command:`dns`,describe:`dns`,builder:e=>e.command(me).command(Ne).command(mt).command(yt).command(qn).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{Jn as default};
142
+ Modify TSIG.`).positional(`tsig-id`,{type:`string`,description:`Tsig ID`,demandOption:!0}).option(`algo`,{type:`string`,description:`TSIG algorithm.`}).option(`name`,{type:`string`,description:`TSIG key name.`}).option(`secret`,{type:`string`,description:`TSIG secret.`}).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 Un={command:`update <tsig-id>`,describe:`Update TSIG`,builder:Hn,handler:async e=>d({command:`dns zone-transfers tsigs update`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf dns zone-transfers tsigs update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/secondary_dns/tsigs/${e[`tsig-id`]==null?`<tsig-id>`:encodeURIComponent(String(e[`tsig-id`]))}`,pathParams:{"tsig-id":String(e[`tsig-id`]??``)},bodyKind:`json`,body:e.body===void 0?m({algo:h(e.algo,`algo`,`text`),name:h(e.name,`name`,`text`),secret:h(e.secret,`secret`,`text`)}):p(e.body),sensitiveBodyPaths:[[`secret`]]});return}let t=e.body===void 0?void 0:p(e.body),a=await n(e),u=e.local?_:await o();if(e.accountId=u,e.body!==void 0){let n=t,r=await c(`Updating`,async()=>a.send($,{body:n,account_id:u,tsig_id:e[`tsig-id`]}));s(r,{successLabel:`Updated`});return}e.algo===void 0&&(e.algo=await l(`algo`,`TSIG algorithm.`)),e.name===void 0&&(e.name=await l(`name`,`TSIG key name.`)),e.secret===void 0&&(e.secret=await l(`secret`,`TSIG secret.`,{kind:`secret`}));let d=m({algo:h(e.algo,`algo`,`text`),name:h(e.name,`name`,`text`),secret:h(e.secret,`secret`,`text`)}),f=await c(`Updating`,async()=>a.send($,{body:d,account_id:u,tsig_id:e[`tsig-id`]}));s(f,{successLabel:`Updated`})})},Wn={command:`tsigs`,describe:`Operations for zone-transfers.tsigs`,builder:e=>e.command(Nn).command(Fn).command(Rn).command(Vn).command(Un).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},Gn={command:`zone-transfers`,describe:`Operations for zone-transfers`,builder:e=>e.command(It).command(Nt).command(qt).command(_n).command(jn).command(Wn).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},Kn={command:`dns`,describe:`dns`,builder:e=>e.command(me).command(Ne).command(mt).command(yt).command(Gn).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{Kn as default};
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{i as n,r,t as i}from"./body-parser-HN91kAf0.mjs";import{a,t as o}from"./context-DlFhI9cN.mjs";import{t as s}from"./dry-run-mrA7FFLR.mjs";import{n as c}from"./input-validation-D7z60HJH.mjs";import{t as l}from"./local-B3zt9PXR.mjs";import{t as u}from"./run-DAg7dfIW.mjs";import{t as d}from"./output-PRKYaJuo.mjs";import{t as f}from"./progress-AML-AVs4.mjs";import"./telemetry-DDs3zhdw.mjs";import{n as p}from"./prompt-Bnon9lfK.mjs";var m={method:`POST`,path:t=>e`/accounts/${t.account_id}/dns_firewall`,body:`json`};function h(e){return e.usage(`$0 dns-firewall create
2
+ import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-NIRm11Ab.mjs";import{i as n,r,t as i}from"./body-parser-HN91kAf0.mjs";import{a,t as o}from"./context-CroqTqbk.mjs";import{t as s}from"./dry-run-mrA7FFLR.mjs";import{n as c}from"./input-validation-D7z60HJH.mjs";import{t as l}from"./local-B3zt9PXR.mjs";import{t as u}from"./run-DhU17ztU.mjs";import{t as d}from"./output-PRKYaJuo.mjs";import{t as f}from"./progress-DQfZZwit.mjs";import"./telemetry-CruYXv5e.mjs";import{n as p}from"./prompt-e6K5lhdE.mjs";var m={method:`POST`,path:t=>e`/accounts/${t.account_id}/dns_firewall`,body:`json`};function h(e){return e.usage(`$0 dns-firewall create
3
3
 
4
4
  Create a DNS Firewall cluster`).option(`attack-mitigation-enabled`,{type:`boolean`,description:`When enabled, automatically mitigate random-prefix attacks to protect upstream DNS servers`}).option(`attack-mitigation-only-when-upstream-unhealthy`,{type:`boolean`,description:`Only mitigate attacks when upstream servers seem unhealthy`}).option(`deprecate-any-requests`,{type:`boolean`,description:`Whether to refuse to answer queries for the ANY type`}).option(`ecs-fallback`,{type:`boolean`,description:`Whether to forward client IP (resolver) subnet if no EDNS Client Subnet is sent`}).option(`maximum-cache-ttl`,{type:`number`,description:`By default, Cloudflare attempts to cache responses for as long as
5
5
  indicated by the TTL received from upstream nameservers. This setting
@@ -1,3 +1,3 @@
1
1
  #!/usr/bin/env node
2
- import{t as e}from"./output-PRKYaJuo.mjs";import{n as t}from"./request-headers-BEYXy4JN.mjs";import{t as n}from"./run-DAg7dfIW.mjs";const r=`https://developers.cloudflare.com`;function i(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function a(e){return i(e)?e.success===!1?e.error===void 0||typeof e.error==`string`:e.success===!0&&i(e.result)&&Array.isArray(e.result.chunks)&&e.result.chunks.every(e=>{if(!i(e)||!i(e.item)||typeof e.item.key!=`string`||e.item.key.length===0)return!1;let t=e.item.metadata;return t===void 0||i(t)&&(t.title===void 0||typeof t.title==`string`)&&(t.description===void 0||typeof t.description==`string`)}):!1}function o(e){let t;try{t=new URL(e,`${r}/`)}catch{throw Error(`Cloudflare docs search returned an invalid URL.`)}if(t.origin!==r||t.username||t.password)throw Error(`Cloudflare docs search returned an invalid URL.`);return t.href}async function s(e){let n=AbortSignal.timeout(3e4),r;try{r=await fetch(`https://ai-search.developers.cloudflare.com/api/ai-search/search`,{method:`POST`,headers:{...t(),"Content-Type":`application/json`,Accept:`application/json`},body:JSON.stringify({messages:[{role:`user`,content:e}],stream:!1,ai_search_options:{retrieval:{metadata_only:!0,max_num_results:5}}}),signal:n})}catch(e){throw Error(n.aborted?`Cloudflare docs search timed out. Try again.`:`Unable to reach Cloudflare docs search. Check your connection and try again.`,{cause:e})}if(!r.ok)throw Error(`Cloudflare docs search failed (HTTP ${r.status}).`);let i;try{i=await r.json()}catch(e){throw Error(n.aborted?`Cloudflare docs search timed out. Try again.`:`Cloudflare docs search returned an invalid JSON response.`,{cause:e})}if(!a(i))throw Error(`Cloudflare docs search returned an invalid response.`);if(!i.success)throw Error(`Cloudflare docs search failed: ${i.error??`Unknown error`}`);return i.result.chunks.slice(0,5).map(({item:e})=>({title:e.metadata?.title??`Untitled`,description:e.metadata?.description??``,url:o(e.key)}))}const c={command:`search <query>`,describe:`Search live Cloudflare documentation, guides, tutorials, and examples`,builder:e=>e.positional(`query`,{describe:`Search terms or a question about Cloudflare`,type:`string`,demandOption:!0,coerce:e=>{let t=e.trim();if(!t)throw Error(`query must not be empty.`);return t}}).example(`cf docs search "schedule a worker"`,`Find guides and examples`).epilogue(`Returns up to five ranked JSON results with title, description, and url. No Cloudflare login is required.
2
+ import{t as e}from"./output-PRKYaJuo.mjs";import{n as t}from"./request-headers-xtY5gOlq.mjs";import{t as n}from"./run-DhU17ztU.mjs";const r=`https://developers.cloudflare.com`;function i(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function a(e){return i(e)?e.success===!1?e.error===void 0||typeof e.error==`string`:e.success===!0&&i(e.result)&&Array.isArray(e.result.chunks)&&e.result.chunks.every(e=>{if(!i(e)||!i(e.item)||typeof e.item.key!=`string`||e.item.key.length===0)return!1;let t=e.item.metadata;return t===void 0||i(t)&&(t.title===void 0||typeof t.title==`string`)&&(t.description===void 0||typeof t.description==`string`)}):!1}function o(e){let t;try{t=new URL(e,`${r}/`)}catch{throw Error(`Cloudflare docs search returned an invalid URL.`)}if(t.origin!==r||t.username||t.password)throw Error(`Cloudflare docs search returned an invalid URL.`);return t.href}async function s(e){let n=AbortSignal.timeout(3e4),r;try{r=await fetch(`https://ai-search.developers.cloudflare.com/api/ai-search/search`,{method:`POST`,headers:{...t(),"Content-Type":`application/json`,Accept:`application/json`},body:JSON.stringify({messages:[{role:`user`,content:e}],stream:!1,ai_search_options:{retrieval:{metadata_only:!0,max_num_results:5}}}),signal:n})}catch(e){throw Error(n.aborted?`Cloudflare docs search timed out. Try again.`:`Unable to reach Cloudflare docs search. Check your connection and try again.`,{cause:e})}if(!r.ok)throw Error(`Cloudflare docs search failed (HTTP ${r.status}).`);let i;try{i=await r.json()}catch(e){throw Error(n.aborted?`Cloudflare docs search timed out. Try again.`:`Cloudflare docs search returned an invalid JSON response.`,{cause:e})}if(!a(i))throw Error(`Cloudflare docs search returned an invalid response.`);if(!i.success)throw Error(`Cloudflare docs search failed: ${i.error??`Unknown error`}`);return i.result.chunks.slice(0,5).map(({item:e})=>({title:e.metadata?.title??`Untitled`,description:e.metadata?.description??``,url:o(e.key)}))}const c={command:`search <query>`,describe:`Search live Cloudflare documentation, guides, tutorials, and examples`,builder:e=>e.positional(`query`,{describe:`Search terms or a question about Cloudflare`,type:`string`,demandOption:!0,coerce:e=>{let t=e.trim();if(!t)throw Error(`query must not be empty.`);return t}}).example(`cf docs search "schedule a worker"`,`Find guides and examples`).epilogue(`Returns up to five ranked JSON results with title, description, and url. No Cloudflare login is required.
3
3
  Fetch a result's URL with Accept: text/markdown to read the full page as Markdown.`),handler:t=>n({command:`docs search`,recordArgs:!1,searchQuery:t.query},t,async()=>{e(await s(t.query))})},l={command:`docs`,describe:`Search live Cloudflare documentation`,builder:e=>e.command(c).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{l as default};
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{t as n}from"./dry-run-mrA7FFLR.mjs";import{a as r,t as i}from"./context-DlFhI9cN.mjs";import{t as a}from"./local-B3zt9PXR.mjs";import{t as o}from"./output-PRKYaJuo.mjs";import{t as s}from"./progress-AML-AVs4.mjs";import{t as c}from"./run-DAg7dfIW.mjs";import"./telemetry-DDs3zhdw.mjs";var l={method:`GET`,path:t=>e`/accounts/${t.account_id}/workers/durable_objects/namespaces`,query:[`page`,`per_page`]};function u(e){return e.usage(`$0 durable-objects namespaces list
2
+ import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-NIRm11Ab.mjs";import{t as n}from"./dry-run-mrA7FFLR.mjs";import{a as r,t as i}from"./context-CroqTqbk.mjs";import{t as a}from"./local-B3zt9PXR.mjs";import{t as o}from"./output-PRKYaJuo.mjs";import{t as s}from"./progress-DQfZZwit.mjs";import{t as c}from"./run-DhU17ztU.mjs";import"./telemetry-CruYXv5e.mjs";var l={method:`GET`,path:t=>e`/accounts/${t.account_id}/workers/durable_objects/namespaces`,query:[`page`,`per_page`]};function u(e){return e.usage(`$0 durable-objects namespaces list
3
3
 
4
4
  Returns the Durable Object namespaces owned by an account.`).option(`page`,{type:`number`,description:`Current page.`}).option(`per-page`,{type:`number`,description:`Items per-page.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const d={command:`list`,describe:`List Durable Object Namespaces`,builder:u,handler:async e=>c({command:`durable-objects namespaces list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{let c={page:e.page,per_page:e[`per-page`]};if(e.dryRun){let e=await r();n({command:`cf durable-objects namespaces list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/workers/durable_objects/namespaces`,pathParams:{},query:c,bodyKind:`none`});return}let u=await t(e),d=e.local?a:await i();e.accountId=d;let f=await s(`Loading`,async()=>u.send(l,{account_id:d,...c}));o(f,{successLabel:`Loaded`})})};var f={method:`GET`,path:t=>e`/accounts/${t.account_id}/workers/durable_objects/namespaces/${t.id}/objects`,query:[`limit`,`cursor`]};function p(e){return e.usage(`$0 durable-objects namespaces objects list
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{i as n}from"./context-DlFhI9cN.mjs";import{r,t as i}from"./body-parser-HN91kAf0.mjs";import{t as a}from"./dry-run-mrA7FFLR.mjs";import{t as o}from"./output-PRKYaJuo.mjs";import{t as s}from"./run-DAg7dfIW.mjs";import{t as c}from"./progress-AML-AVs4.mjs";import"./telemetry-DDs3zhdw.mjs";var l={method:`PATCH`,path:t=>e`/zones/${t.zone_id}/email/auth/dmarc-reports`,body:`json`};function u(e){return e.usage("$0 email-auth dmarc-reports edit\n\nUpdates the DMARC report configuration for a zone. At least one of `enabled` or `skip_wizard` must be provided. When enabling, the handler will ensure the DMARC RUA record exists in DNS.").option(`enabled`,{type:`boolean`,description:`Enable or disable DMARC reports for this zone`}).option(`skip-wizard`,{type:`boolean`,description:`Skip the DMARC setup wizard`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Request body for PATCH /dmarc-reports`})}const d={command:`edit`,describe:`Configure DMARC Reports`,builder:u,handler:async e=>s({command:`email-auth dmarc-reports edit`,classification:{safeFlags:[`enabled`,`skip-wizard`,`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf email-auth dmarc-reports edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/auth/dmarc-reports`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?i({enabled:e.enabled,skip_wizard:e[`skip-wizard`]}):r(e.body)});return}let s=e.body===void 0?void 0:r(e.body),u=await t(e),d=await n({zone:e.zone},u,{quiet:e.quiet});if(e.zoneId=d,e.body!==void 0){let e=s,t=await c(`Updating`,async()=>u.send(l,{body:e,zone_id:d}));o(t,{successLabel:`Updated`});return}let f=i({enabled:e.enabled,skip_wizard:e[`skip-wizard`]}),p=await c(`Updating`,async()=>u.send(l,{body:f,zone_id:d}));o(p,{successLabel:`Updated`})})};var f={method:`GET`,path:t=>e`/zones/${t.zone_id}/email/auth/dmarc-reports`};function p(e){return e.usage(`$0 email-auth dmarc-reports get
2
+ import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-NIRm11Ab.mjs";import{i as n}from"./context-CroqTqbk.mjs";import{r,t as i}from"./body-parser-HN91kAf0.mjs";import{t as a}from"./dry-run-mrA7FFLR.mjs";import{t as o}from"./output-PRKYaJuo.mjs";import{t as s}from"./run-DhU17ztU.mjs";import{t as c}from"./progress-DQfZZwit.mjs";import"./telemetry-CruYXv5e.mjs";var l={method:`PATCH`,path:t=>e`/zones/${t.zone_id}/email/auth/dmarc-reports`,body:`json`};function u(e){return e.usage("$0 email-auth dmarc-reports edit\n\nUpdates the DMARC report configuration for a zone. At least one of `enabled` or `skip_wizard` must be provided. When enabling, the handler will ensure the DMARC RUA record exists in DNS.").option(`enabled`,{type:`boolean`,description:`Enable or disable DMARC reports for this zone`}).option(`skip-wizard`,{type:`boolean`,description:`Skip the DMARC setup wizard`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Request body for PATCH /dmarc-reports`})}const d={command:`edit`,describe:`Configure DMARC Reports`,builder:u,handler:async e=>s({command:`email-auth dmarc-reports edit`,classification:{safeFlags:[`enabled`,`skip-wizard`,`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf email-auth dmarc-reports edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/auth/dmarc-reports`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?i({enabled:e.enabled,skip_wizard:e[`skip-wizard`]}):r(e.body)});return}let s=e.body===void 0?void 0:r(e.body),u=await t(e),d=await n({zone:e.zone},u,{quiet:e.quiet});if(e.zoneId=d,e.body!==void 0){let e=s,t=await c(`Updating`,async()=>u.send(l,{body:e,zone_id:d}));o(t,{successLabel:`Updated`});return}let f=i({enabled:e.enabled,skip_wizard:e[`skip-wizard`]}),p=await c(`Updating`,async()=>u.send(l,{body:f,zone_id:d}));o(p,{successLabel:`Updated`})})};var f={method:`GET`,path:t=>e`/zones/${t.zone_id}/email/auth/dmarc-reports`};function p(e){return e.usage(`$0 email-auth dmarc-reports get
3
3
 
4
4
  Retrieves the current DMARC report configuration and status for a zone. Returns the RUA prefix, enabled status, approved sources, and DNS records.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const m={command:`get`,describe:`Get DMARC Report Status`,builder:p,handler:async e=>s({command:`email-auth dmarc-reports get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf email-auth dmarc-reports get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/auth/dmarc-reports`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let r=await t(e),i=await n({zone:e.zone},r,{quiet:e.quiet});e.zoneId=i;let s=await c(`Loading`,async()=>r.send(f,{zone_id:i}));o(s,{successLabel:`Loaded`})})},h={command:`dmarc-reports`,describe:`Operations for dmarc-reports`,builder:e=>e.command(d).command(m).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var g={method:`GET`,path:t=>e`/zones/${t.zone_id}/email/auth/spf/inspect`,query:[`id`]};function _(e){return e.usage(`$0 email-auth spf inspect
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{o as n,r,t as i}from"./body-parser-HN91kAf0.mjs";import{a,i as o,t as s}from"./context-DlFhI9cN.mjs";import{t as c}from"./dry-run-mrA7FFLR.mjs";import{n as l}from"./input-validation-D7z60HJH.mjs";import{t as u}from"./local-B3zt9PXR.mjs";import{t as d}from"./run-DAg7dfIW.mjs";import{t as f}from"./output-PRKYaJuo.mjs";import{t as p}from"./progress-AML-AVs4.mjs";import{a as m,i as h,n as g}from"./prompt-Bnon9lfK.mjs";import"./telemetry-DDs3zhdw.mjs";var _={method:`POST`,path:t=>e`/accounts/${t.account_id}/email/routing/addresses`,body:`json`,errors:{422:`UnprocessableEntityError`}};function v(e){return e.usage(`$0 email-routing addresses create
2
+ import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-NIRm11Ab.mjs";import{o as n,r,t as i}from"./body-parser-HN91kAf0.mjs";import{a,i as o,t as s}from"./context-CroqTqbk.mjs";import{t as c}from"./dry-run-mrA7FFLR.mjs";import{n as l}from"./input-validation-D7z60HJH.mjs";import{t as u}from"./local-B3zt9PXR.mjs";import{t as d}from"./run-DhU17ztU.mjs";import{t as f}from"./output-PRKYaJuo.mjs";import{t as p}from"./progress-DQfZZwit.mjs";import{a as m,i as h,n as g}from"./prompt-e6K5lhdE.mjs";import"./telemetry-CruYXv5e.mjs";var _={method:`POST`,path:t=>e`/accounts/${t.account_id}/email/routing/addresses`,body:`json`,errors:{422:`UnprocessableEntityError`}};function v(e){return e.usage(`$0 email-routing addresses create
3
3
 
4
4
  Create a destination address to forward your emails to. Destination addresses need to be verified before they can be used.`).option(`email`,{type:`string`,description:`The contact email address of the user.`}).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:`create`,describe:`Create a destination address`,builder:v,handler:async e=>d({command:`email-routing addresses create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await a();c({command:`cf email-routing addresses create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/email/routing/addresses`,pathParams:{},bodyKind:`json`,body:e.body===void 0?i({email:l(e.email,`email`,`text`)}):r(e.body)});return}let n=e.body===void 0?void 0:r(e.body),o=await t(e),d=e.local?u:await s();if(e.accountId=d,e.body!==void 0){let e=n,t=await p(`Creating`,async()=>o.send(_,{body:e,account_id:d}));f(t,{successLabel:`Created`});return}e.email===void 0&&(e.email=await m(`email`,`The contact email address of the user.`));let h=i({email:l(e.email,`email`,`text`)}),g=await p(`Creating`,async()=>o.send(_,{body:h,account_id:d}));f(g,{successLabel:`Created`})})};var b={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/email/routing/addresses/${t.destination_address_identifier}`,errors:{404:`NotFoundError`}};function x(e){return e.usage(`$0 email-routing addresses delete <destination-address-identifier>
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{o as n,r,t as i}from"./body-parser-HN91kAf0.mjs";import{a,t as o}from"./context-DlFhI9cN.mjs";import{t as s}from"./dry-run-mrA7FFLR.mjs";import{t as c}from"./local-B3zt9PXR.mjs";import{t as l}from"./output-PRKYaJuo.mjs";import{t as u}from"./run-DAg7dfIW.mjs";import{t as d}from"./progress-AML-AVs4.mjs";import{a as f,i as p,n as m}from"./prompt-Bnon9lfK.mjs";import"./telemetry-DDs3zhdw.mjs";import{n as h}from"./input-validation-D7z60HJH.mjs";var g={method:`POST`,path:t=>e`/accounts/${t.account_id}/email-security/settings/allow_policies/batch`,body:`json`};function _(e){return e.usage(`$0 email-security allow-policies batch
2
+ import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-NIRm11Ab.mjs";import{o as n,r,t as i}from"./body-parser-HN91kAf0.mjs";import{a,t as o}from"./context-CroqTqbk.mjs";import{t as s}from"./dry-run-mrA7FFLR.mjs";import{t as c}from"./local-B3zt9PXR.mjs";import{t as l}from"./output-PRKYaJuo.mjs";import{t as u}from"./run-DhU17ztU.mjs";import{t as d}from"./progress-DQfZZwit.mjs";import{a as f,i as p,n as m}from"./prompt-e6K5lhdE.mjs";import"./telemetry-CruYXv5e.mjs";import{n as h}from"./input-validation-D7z60HJH.mjs";var g={method:`POST`,path:t=>e`/accounts/${t.account_id}/email-security/settings/allow_policies/batch`,body:`json`};function _(e){return e.usage(`$0 email-security allow-policies batch
3
3
 
4
4
  Executes multiple allow policy operations atomically: delete, partially update, replace, and create allow policies in a single request. All four operation arrays (deletes, patches, puts, posts) are required and executed in order. Send empty arrays for unused operations.`).option(`deletes`,{type:`string`,description:`IDs of the allow policies to delete. Provide as a JSON array of objects or @path/to/file.json. Shape: [{"id": string}].`}).option(`patches`,{type:`string`,description:`Partial updates to apply — each entry carries the policy's ID and only the fields to change. Provide as a JSON array of objects or @path/to/file.json. Shape: [({"comments"?: (string | null), "expires_at"?: (string | null), "is_acceptable_sender"?: boolean, "is_exempt_recipient"?: boolean, "is_recipient"?: boolean, ...more} & {"id": string})]. ? marks optional keys.`}).option(`posts`,{type:`string`,description:`Allow policies to create. Provide as a JSON array of objects or @path/to/file.json. Shape: [{"is_acceptable_sender": boolean, "is_exempt_recipient": boolean, "is_regex": boolean, "is_trusted_sender": boolean, "pattern": string, ...more}].`}).option(`puts`,{type:`string`,description:`Full replacements to apply — each entry carries the policy's ID and every field of its new value. Provide as a JSON array of objects or @path/to/file.json. Shape: [({"is_acceptable_sender": boolean, "is_exempt_recipient": boolean, "is_regex": boolean, "is_trusted_sender": boolean, "pattern": string, ...more} & {"id": string})].`}).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 ee={command:`batch`,describe:`Batch allow policy operations`,builder:_,handler:async e=>u({command:`email-security allow-policies batch`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){let t=await a();s({command:`cf email-security allow-policies batch`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/email-security/settings/allow_policies/batch`,pathParams:{},bodyKind:`json`,body:e.body===void 0?i({deletes:n(e.deletes,`deletes`),patches:n(e.patches,`patches`),posts:n(e.posts,`posts`),puts:n(e.puts,`puts`)}):r(e.body)});return}let u=e.body===void 0?void 0:r(e.body),f=await t(e),p=e.local?c:await o();if(e.accountId=p,!await m({force:!!e.force,message:`This operation may delete the selected allow policies and restore normal security scanning and disposition actions for matching emails.`}))return;if(e.body!==void 0){let e=u,t=await d(`Processing`,async()=>f.send(g,{body:e,account_id:p}));l(t,{successLabel:`Done`});return}if(e.deletes===void 0)throw Error(`--deletes is required (or pass --body with this field set).`);if(e.patches===void 0)throw Error(`--patches is required (or pass --body with this field set).`);if(e.posts===void 0)throw Error(`--posts is required (or pass --body with this field set).`);if(e.puts===void 0)throw Error(`--puts is required (or pass --body with this field set).`);let h=i({deletes:n(e.deletes,`deletes`),patches:n(e.patches,`patches`),posts:n(e.posts,`posts`),puts:n(e.puts,`puts`)}),_=await d(`Processing`,async()=>f.send(g,{body:h,account_id:p}));l(_,{successLabel:`Done`})})};var v={method:`POST`,path:t=>e`/accounts/${t.account_id}/email-security/settings/allow_policies`,body:`json`};function te(e){return e.usage(`$0 email-security allow-policies create
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{t as n}from"./dry-run-mrA7FFLR.mjs";import{a as r,i,t as a}from"./context-DlFhI9cN.mjs";import{t as o}from"./local-B3zt9PXR.mjs";import{t as s}from"./output-PRKYaJuo.mjs";import{t as c}from"./progress-AML-AVs4.mjs";import{t as l}from"./run-DAg7dfIW.mjs";import"./telemetry-DDs3zhdw.mjs";import{i as u,o as d,r as f,t as p}from"./body-parser-HN91kAf0.mjs";import{n as m}from"./input-validation-D7z60HJH.mjs";import{a as h,n as g}from"./prompt-Bnon9lfK.mjs";import{t as _}from"./body-unions-QFGGUlIr.mjs";var v={method:`GET`,path:t=>e`/accounts/${t.account_id}/email/sending/messages/${t.message_id}`,response:`binary-response`,errors:{404:`NotFoundError`,500:`InternalServerError`}};function ee(e){return e.usage(`$0 email-sending get <message-id>
2
+ import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-NIRm11Ab.mjs";import{t as n}from"./dry-run-mrA7FFLR.mjs";import{a as r,i,t as a}from"./context-CroqTqbk.mjs";import{t as o}from"./local-B3zt9PXR.mjs";import{t as s}from"./output-PRKYaJuo.mjs";import{t as c}from"./progress-DQfZZwit.mjs";import{t as l}from"./run-DhU17ztU.mjs";import"./telemetry-CruYXv5e.mjs";import{i as u,o as d,r as f,t as p}from"./body-parser-HN91kAf0.mjs";import{n as m}from"./input-validation-D7z60HJH.mjs";import{a as h,n as g}from"./prompt-e6K5lhdE.mjs";import{t as _}from"./body-unions-QFGGUlIr.mjs";var v={method:`GET`,path:t=>e`/accounts/${t.account_id}/email/sending/messages/${t.message_id}`,response:`binary-response`,errors:{404:`NotFoundError`,500:`InternalServerError`}};function ee(e){return e.usage(`$0 email-sending get <message-id>
3
3
 
4
4
  Returns the raw RFC 5322 MIME message for the given account and message id.`).positional(`message-id`,{type:`string`,description:`Message ID`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const y={command:`get <message-id>`,describe:`Fetch an email message`,builder:ee,handler:async e=>l({command:`email-sending get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await r();n({command:`cf email-sending get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/email/sending/messages/${e[`message-id`]==null?`<message-id>`:encodeURIComponent(String(e[`message-id`]))}`,pathParams:{"message-id":String(e[`message-id`]??``)},bodyKind:`none`});return}let i=await t(e),l=e.local?o:await a();e.accountId=l;let u=await c(`Loading`,async()=>i.send(v,{account_id:l,message_id:e[`message-id`]}));s(u,{successLabel:`Loaded`})})};var b={method:`GET`,path:t=>e`/accounts/${t.account_id}/email/sending/limits`,errors:{403:`ForbiddenError`}};function te(e){return e.usage(`$0 email-sending limits get
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{t as e}from"./chunk-AAQI36FL-e6E5HW1g.mjs";import{n as t}from"./version-pcpa_kv3.mjs";import{t as n}from"./session-BEsQIuwP.mjs";import{i as r,t as i}from"./blocks-DK5qAzLe.mjs";import{r as a}from"./theme-BGHWSKCw.mjs";import{i as o}from"./api-Dnt6lRJG.mjs";var s=class extends Error{};function c(e){return e instanceof s||`telemetryMessage`in e&&e.telemetryMessage===`cfetch auth login required`&&`reason`in e&&e.reason===`no-credentials-non-interactive`}function l(e){try{let t=new URL(e);return`${t.pathname.replace(/^\/client\/v\d+/,``)}${t.search}`}catch{return e}}function u(e){return Array.isArray(e)?e.flatMap(e=>{if(typeof e==`string`)return[{message:e}];if(typeof e!=`object`||!e)return[];let t=e,n=typeof t.code==`number`?t.code:void 0,r=typeof t.message==`string`?t.message:void 0;return n!==void 0||r!==void 0?[{code:n,message:r}]:[]}):[]}function d(s){if(n(t),s instanceof o){let e=s.statusCode,t=s.body,n=e===void 0?`Envelope Error`:p(e),o=typeof t==`object`&&t?t:void 0,c=[...u(o?.errors).map(e=>({...e,isError:!0})),...u(o?.messages).map(e=>({...e,isError:!1}))],d=s.rawResponse?.url?`HTTP ${l(s.rawResponse.url)}`:void 0,f=e===void 0?n:`${e} ${n}`,m=d?`${f} · ${d}`:f,h=a.muted(m),g=``;return c.length>0?g=c.map((e,t)=>{let n=typeof e.code==`number`?a.error(a.bold(`[${e.code}]`)):e.isError?a.error(a.bold(`[error]`)):void 0,r=a.bold(e.message??``),i=n?`${n} ${r}`:r;return t===c.length-1?`${i}\n${h}`:i}).join(`
2
+ import{t as e}from"./chunk-AAQI36FL-e6E5HW1g.mjs";import{n as t}from"./version--BAAeBma.mjs";import{t as n}from"./session-Py5R3Tdx.mjs";import{i as r,t as i}from"./blocks-DdIA5quB.mjs";import{r as a}from"./theme-BGHWSKCw.mjs";import{i as o}from"./api-Dnt6lRJG.mjs";var s=class extends Error{};function c(e){return e instanceof s||`telemetryMessage`in e&&e.telemetryMessage===`cfetch auth login required`&&`reason`in e&&e.reason===`no-credentials-non-interactive`}function l(e){try{let t=new URL(e);return`${t.pathname.replace(/^\/client\/v\d+/,``)}${t.search}`}catch{return e}}function u(e){return Array.isArray(e)?e.flatMap(e=>{if(typeof e==`string`)return[{message:e}];if(typeof e!=`object`||!e)return[];let t=e,n=typeof t.code==`number`?t.code:void 0,r=typeof t.message==`string`?t.message:void 0;return n!==void 0||r!==void 0?[{code:n,message:r}]:[]}):[]}function d(s){if(n(t),s instanceof o){let e=s.statusCode,t=s.body,n=e===void 0?`Envelope Error`:p(e),o=typeof t==`object`&&t?t:void 0,c=[...u(o?.errors).map(e=>({...e,isError:!0})),...u(o?.messages).map(e=>({...e,isError:!1}))],d=s.rawResponse?.url?`HTTP ${l(s.rawResponse.url)}`:void 0,f=e===void 0?n:`${e} ${n}`,m=d?`${f} · ${d}`:f,h=a.muted(m),g=``;return c.length>0?g=c.map((e,t)=>{let n=typeof e.code==`number`?a.error(a.bold(`[${e.code}]`)):e.isError?a.error(a.bold(`[error]`)):void 0,r=a.bold(e.message??``),i=n?`${n} ${r}`:r;return t===c.length-1?`${i}\n${h}`:i}).join(`
3
3
 
4
4
  `):(g=a.error(a.bold(s.message||m)),s.message&&m&&(g+=`\n${h}`)),console.error(i(g,void 0,{title:`APIError`,rawMessage:!0})),e===401?console.error(`
5
5
  `+r(`Try running: cf auth login`)):e===403&&console.error(`
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{t as n}from"./dry-run-mrA7FFLR.mjs";import{a as r,t as i}from"./context-DlFhI9cN.mjs";import{t as a}from"./local-B3zt9PXR.mjs";import{t as o}from"./output-PRKYaJuo.mjs";import{t as s}from"./progress-AML-AVs4.mjs";import{t as c}from"./run-DAg7dfIW.mjs";import{n as l}from"./prompt-Bnon9lfK.mjs";import"./telemetry-DDs3zhdw.mjs";import{o as u,r as d,t as f}from"./body-parser-HN91kAf0.mjs";var p={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/field_extractors/${t.extractor}`,errors:{404:`NotFoundError`}};function m(e){return e.usage(`$0 field-extractors delete <extractor>
2
+ import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-NIRm11Ab.mjs";import{t as n}from"./dry-run-mrA7FFLR.mjs";import{a as r,t as i}from"./context-CroqTqbk.mjs";import{t as a}from"./local-B3zt9PXR.mjs";import{t as o}from"./output-PRKYaJuo.mjs";import{t as s}from"./progress-DQfZZwit.mjs";import{t as c}from"./run-DhU17ztU.mjs";import{n as l}from"./prompt-e6K5lhdE.mjs";import"./telemetry-CruYXv5e.mjs";import{o as u,r as d,t as f}from"./body-parser-HN91kAf0.mjs";var p={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/field_extractors/${t.extractor}`,errors:{404:`NotFoundError`}};function m(e){return e.usage(`$0 field-extractors delete <extractor>
3
3
 
4
4
  Deletes all custom extraction rules for an extractor type.`).positional(`extractor`,{type:`string`,description:`Extractor type.`,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 h={command:`delete <extractor>`,describe:`Delete Field Extractor`,builder:m,handler:async e=>c({command:`field-extractors delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){let t=await r();n({command:`cf field-extractors delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/field_extractors/${e.extractor==null?`<extractor>`:encodeURIComponent(String(e.extractor))}`,pathParams:{extractor:String(e.extractor??``)},bodyKind:`none`});return}let c=await t(e),u=e.local?a:await i();if(e.accountId=u,!await l({force:!!e.force}))return;let d=await s(`Deleting`,async()=>c.send(p,{account_id:u,extractor:e.extractor}));o(d,{successLabel:`Deleted`})})};var g={method:`GET`,path:t=>e`/accounts/${t.account_id}/field_extractors/${t.extractor}`,errors:{404:`NotFoundError`}};function _(e){return e.usage(`$0 field-extractors get <extractor>
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{o as n,r,t as i}from"./body-parser-HN91kAf0.mjs";import{a,i as o,t as s}from"./context-DlFhI9cN.mjs";import{t as c}from"./dry-run-mrA7FFLR.mjs";import{n as l}from"./input-validation-D7z60HJH.mjs";import{t as u}from"./local-B3zt9PXR.mjs";import{t as d}from"./run-DAg7dfIW.mjs";import{t as f}from"./output-PRKYaJuo.mjs";import{t as p}from"./progress-AML-AVs4.mjs";import{a as m,i as h,n as g}from"./prompt-Bnon9lfK.mjs";import"./telemetry-DDs3zhdw.mjs";var _={method:`POST`,path:t=>e`/${t.account_or_zone}/${t.account_or_zone_id}/firewall/access_rules/rules`,body:`json`};function v(e){return e.usage(`$0 firewall access-rules create
2
+ import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-NIRm11Ab.mjs";import{o as n,r,t as i}from"./body-parser-HN91kAf0.mjs";import{a,i as o,t as s}from"./context-CroqTqbk.mjs";import{t as c}from"./dry-run-mrA7FFLR.mjs";import{n as l}from"./input-validation-D7z60HJH.mjs";import{t as u}from"./local-B3zt9PXR.mjs";import{t as d}from"./run-DhU17ztU.mjs";import{t as f}from"./output-PRKYaJuo.mjs";import{t as p}from"./progress-DQfZZwit.mjs";import{a as m,i as h,n as g}from"./prompt-e6K5lhdE.mjs";import"./telemetry-CruYXv5e.mjs";var _={method:`POST`,path:t=>e`/${t.account_or_zone}/${t.account_or_zone_id}/firewall/access_rules/rules`,body:`json`};function v(e){return e.usage(`$0 firewall access-rules create
3
3
 
4
4
  Creates a new IP Access rule for an account or zone. The rule will apply to all zones in the account or zone. Note: To create an IP Access rule that applies to a single zone, refer to the [IP Access rules for a zone](#ip-access-rules-for-a-zone) endpoints.
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{i as t,n}from"./auth-cj71dGxS.mjs";import{i as r,o as i,r as a,t as o}from"./body-parser-HN91kAf0.mjs";import{a as s,t as c}from"./context-DlFhI9cN.mjs";import{t as l}from"./dry-run-mrA7FFLR.mjs";import{n as u}from"./input-validation-D7z60HJH.mjs";import{t as d}from"./local-B3zt9PXR.mjs";import{t as f}from"./run-DAg7dfIW.mjs";import{t as p}from"./output-PRKYaJuo.mjs";import{t as m}from"./progress-AML-AVs4.mjs";import{a as h,n as g}from"./prompt-Bnon9lfK.mjs";import"./telemetry-DDs3zhdw.mjs";var _={method:`POST`,path:t=>e`/accounts/${t.account_id}/flagship/apps`,body:`json`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,404:`NotFoundError`,429:`TooManyRequestsError`,500:`InternalServerError`}};function v(e){return e.usage(`$0 flagship apps create
2
+ import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{i as t,n}from"./auth-NIRm11Ab.mjs";import{i as r,o as i,r as a,t as o}from"./body-parser-HN91kAf0.mjs";import{a as s,t as c}from"./context-CroqTqbk.mjs";import{t as l}from"./dry-run-mrA7FFLR.mjs";import{n as u}from"./input-validation-D7z60HJH.mjs";import{t as d}from"./local-B3zt9PXR.mjs";import{t as f}from"./run-DhU17ztU.mjs";import{t as p}from"./output-PRKYaJuo.mjs";import{t as m}from"./progress-DQfZZwit.mjs";import{a as h,n as g}from"./prompt-e6K5lhdE.mjs";import"./telemetry-CruYXv5e.mjs";var _={method:`POST`,path:t=>e`/accounts/${t.account_id}/flagship/apps`,body:`json`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,404:`NotFoundError`,429:`TooManyRequestsError`,500:`InternalServerError`}};function v(e){return e.usage(`$0 flagship apps create
3
3
 
4
4
  Creates an app. The returned \`id\` is used in all subsequent flag, changelog, and evaluation requests.`).option(`name`,{type:`string`,description:`Name of the Flagship app (1–64 letters, numbers, hyphens, or underscores).`}).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:`create`,describe:`Create app`,builder:v,handler:async e=>f({command:`flagship apps create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await s();l({command:`cf flagship apps create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/flagship/apps`,pathParams:{},bodyKind:`json`,body:e.body===void 0?o({name:u(e.name,`name`,`text`)}):a(e.body)});return}let t=e.body===void 0?void 0:a(e.body),r=await n(e),i=e.local?d:await c();if(e.accountId=i,e.body!==void 0){let e=t,n=await m(`Creating`,async()=>r.send(_,{body:e,account_id:i}));p(n,{successLabel:`Created`});return}e.name===void 0&&(e.name=await h(`name`,`Name of the Flagship app (1–64 letters, numbers, hyphens, or underscores).`));let f=o({name:u(e.name,`name`,`text`)}),g=await m(`Creating`,async()=>r.send(_,{body:f,account_id:i}));p(g,{successLabel:`Created`})})};function b(e){return e.usage("$0 flagship apps definitions get <app-id>\n\nReturns an app's evaluation-only flag definitions for SDKs that evaluate locally. Send the returned `ETag` in `If-None-Match` to avoid downloading unchanged definitions.").positional(`app-id`,{type:`string`,description:`Flagship app ID returned when the app was created.`,demandOption:!0}).option(`if-none-match`,{type:`string`,description:"Previously returned ETag, or `*`."}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const x={command:`get <app-id>`,describe:`Get flag definitions`,builder:b,handler:async e=>f({command:`flagship apps definitions get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{let r={};if(e[`if-none-match`]!==void 0&&(r[`If-None-Match`]=String(e[`if-none-match`])),e.dryRun){let t=await s();l({command:`cf flagship apps definitions get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/flagship/apps/${e[`app-id`]==null?`<app-id>`:encodeURIComponent(String(e[`app-id`]))}/definitions`,pathParams:{"app-id":String(e[`app-id`]??``)},bodyKind:`none`});return}let i=await n(e),a=e.local?d:await c();e.accountId=a;let o=await m(`Loading`,async()=>t(i,`GET`,`/accounts/${a}/flagship/apps/${encodeURIComponent(String(e[`app-id`]))}/definitions`,{headers:Object.keys(r).length>0?r:void 0}));p(o,{successLabel:`Loaded`})})},S={command:`definitions`,describe:`Operations for apps.definitions`,builder:e=>e.command(x).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var ee={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/flagship/apps/${t.app_id}`,errors:{400:`BadRequestError`,401:`UnauthorizedError`,403:`ForbiddenError`,404:`NotFoundError`,409:`ConflictError`,429:`TooManyRequestsError`,500:`InternalServerError`}};function te(e){return e.usage(`$0 flagship apps delete <app-id>
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{i as n}from"./context-DlFhI9cN.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{t as i}from"./output-PRKYaJuo.mjs";import{t as a}from"./progress-AML-AVs4.mjs";import{t as o}from"./run-DAg7dfIW.mjs";import"./telemetry-DDs3zhdw.mjs";import{r as s,t as c}from"./body-parser-HN91kAf0.mjs";import{n as l}from"./input-validation-D7z60HJH.mjs";var u={method:`GET`,path:t=>e`/zones/${t.zone_id}/fraud_detection/settings`};function d(e){return e.usage(`$0 fraud get
2
+ import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-NIRm11Ab.mjs";import{i as n}from"./context-CroqTqbk.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{t as i}from"./output-PRKYaJuo.mjs";import{t as a}from"./progress-DQfZZwit.mjs";import{t as o}from"./run-DhU17ztU.mjs";import"./telemetry-CruYXv5e.mjs";import{r as s,t as c}from"./body-parser-HN91kAf0.mjs";import{n as l}from"./input-validation-D7z60HJH.mjs";var u={method:`GET`,path:t=>e`/zones/${t.zone_id}/fraud_detection/settings`};function d(e){return e.usage(`$0 fraud get
3
3
 
4
4
  Retrieve Fraud Detection settings for a zone.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const f={command:`get`,describe:`Get Fraud Detection Settings`,builder:d,handler:async e=>o({command:`fraud get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf fraud get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/fraud_detection/settings`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let o=await t(e),s=await n({zone:e.zone},o,{quiet:e.quiet});e.zoneId=s;let c=await a(`Loading`,async()=>o.send(u,{zone_id:s}));i(c,{successLabel:`Loaded`})})};var p={method:`PUT`,path:t=>e`/zones/${t.zone_id}/fraud_detection/settings`,body:`json`};function m(e){return e.usage("$0 fraud update\n\nUpdate Fraud Detection settings for a zone. Notes on `username_expressions` behavior: - If omitted or set to null, expressions are not modified. - If provided as an empty array `[]`, all expressions will be cleared.").option(`authentication-settings-failure-criteria-kind`,{type:`string`,description:"The type of criterion. Currently only `status_code` is supported.",choices:[`status_code`]}).coerce(`authentication-settings-failure-criteria-kind`,e=>l(e,`authentication-settings-failure-criteria-kind`,`text`)).option(`authentication-settings-failure-criteria-status-codes`,{type:`string`,array:!0,description:`HTTP status codes to match against the origin response.
5
5
  - Maximum of 10 codes per criterion.
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{i as n}from"./context-DlFhI9cN.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{t as i}from"./output-PRKYaJuo.mjs";import{t as a}from"./progress-AML-AVs4.mjs";import{t as o}from"./run-DAg7dfIW.mjs";import"./telemetry-DDs3zhdw.mjs";import{r as s,t as c}from"./body-parser-HN91kAf0.mjs";import{n as l}from"./input-validation-D7z60HJH.mjs";import{a as u}from"./prompt-Bnon9lfK.mjs";var d={method:`GET`,path:t=>e`/zones/${t.zone_id}/settings/google-tag-gateway/config`};function f(e){return e.usage(`$0 google-tag-gateway config get
2
+ import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-NIRm11Ab.mjs";import{i as n}from"./context-CroqTqbk.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{t as i}from"./output-PRKYaJuo.mjs";import{t as a}from"./progress-DQfZZwit.mjs";import{t as o}from"./run-DhU17ztU.mjs";import"./telemetry-CruYXv5e.mjs";import{r as s,t as c}from"./body-parser-HN91kAf0.mjs";import{n as l}from"./input-validation-D7z60HJH.mjs";import{a as u}from"./prompt-e6K5lhdE.mjs";var d={method:`GET`,path:t=>e`/zones/${t.zone_id}/settings/google-tag-gateway/config`};function f(e){return e.usage(`$0 google-tag-gateway config get
3
3
 
4
4
  Gets the Google Tag Gateway configuration for a zone.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const p={command:`get`,describe:`Get Google Tag Gateway configuration`,builder:f,handler:async e=>o({command:`google-tag-gateway config get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf google-tag-gateway config get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/settings/google-tag-gateway/config`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let o=await t(e),s=await n({zone:e.zone},o,{quiet:e.quiet});e.zoneId=s;let c=await a(`Loading`,async()=>o.send(d,{zone_id:s}));i(c,{successLabel:`Loaded`})})};var m={method:`PUT`,path:t=>e`/zones/${t.zone_id}/settings/google-tag-gateway/config`,body:`json`};function h(e){return e.usage(`$0 google-tag-gateway config update
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{i as n}from"./context-DlFhI9cN.mjs";import{i as r,r as i,t as a}from"./body-parser-HN91kAf0.mjs";import{t as o}from"./dry-run-mrA7FFLR.mjs";import{n as s}from"./input-validation-D7z60HJH.mjs";import{t as c}from"./run-DAg7dfIW.mjs";import{t as l}from"./output-PRKYaJuo.mjs";import{t as u}from"./progress-AML-AVs4.mjs";import{a as d,n as f}from"./prompt-Bnon9lfK.mjs";import"./telemetry-DDs3zhdw.mjs";var p={method:`POST`,path:t=>e`/zones/${t.zone_id}/healthchecks`,body:`json`};function m(e){return e.usage(`$0 healthchecks create
2
+ import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-NIRm11Ab.mjs";import{i as n}from"./context-CroqTqbk.mjs";import{i as r,r as i,t as a}from"./body-parser-HN91kAf0.mjs";import{t as o}from"./dry-run-mrA7FFLR.mjs";import{n as s}from"./input-validation-D7z60HJH.mjs";import{t as c}from"./run-DhU17ztU.mjs";import{t as l}from"./output-PRKYaJuo.mjs";import{t as u}from"./progress-DQfZZwit.mjs";import{a as d,n as f}from"./prompt-e6K5lhdE.mjs";import"./telemetry-CruYXv5e.mjs";var p={method:`POST`,path:t=>e`/zones/${t.zone_id}/healthchecks`,body:`json`};function m(e){return e.usage(`$0 healthchecks create
3
3
 
4
4
  Create a new health check.`).option(`address`,{type:`string`,description:`The hostname or IP address of the origin server to run health checks on.`}).option(`check-regions`,{type:`string`,array:!0,description:`A list of regions from which to run health checks. Null means Cloudflare will pick a default region.`}).option(`consecutive-fails`,{type:`number`,description:`The number of consecutive fails required from a health check before changing the health to unhealthy.`,default:1}).option(`consecutive-successes`,{type:`number`,description:`The number of consecutive successes required from a health check before changing the health to healthy.`,default:1}).option(`description`,{type:`string`,description:`A human-readable description of the health check.`}).option(`http-config-allow-insecure`,{type:`boolean`,description:`Do not validate the certificate when the health check uses HTTPS.`}).option(`http-config-expected-body`,{type:`string`,description:`A case-insensitive sub-string to look for in the response body. If this string is not found, the origin will be marked as unhealthy.`}).option(`http-config-expected-codes`,{type:`string`,array:!0,description:`The expected HTTP response codes (e.g. "200") or code ranges (e.g. "2xx" for all codes starting with 2) of the health check.`}).option(`http-config-follow-redirects`,{type:`boolean`,description:`Follow redirects if the origin returns a 3xx status code.`}).option(`http-config-header`,{type:`string`,description:`The HTTP request headers to send in the health check. It is recommended you set a Host header by default. The User-Agent header cannot be overridden. Provide as a JSON object or @path/to/file.json. Shape: {"<key>": [string]}.`}).option(`http-config-method`,{type:`string`,description:`The HTTP method to use for the health check.`,choices:[`GET`,`HEAD`]}).coerce(`http-config-method`,e=>s(e,`http-config-method`,`text`)).option(`http-config-path`,{type:`string`,description:`The endpoint path to health check against.`}).option(`http-config-port`,{type:`number`,description:`Port number to connect to for the health check. Defaults to 80 if type is HTTP or 443 if type is HTTPS.`}).option(`interval`,{type:`number`,description:`The interval between each health check. Shorter intervals may give quicker notifications if the origin status changes, but will increase load on the origin as we check from multiple locations.`,default:60}).option(`name`,{type:`string`,description:`A short name to identify the health check. Only alphanumeric characters, hyphens and underscores are allowed.`}).option(`retries`,{type:`number`,description:`The number of retries to attempt in case of a timeout before marking the origin as unhealthy. Retries are attempted immediately.`,default:2}).option(`suspended`,{type:`boolean`,description:`If suspended, no health checks are sent to the origin.`,default:!1}).option(`tcp-config-method`,{type:`string`,description:`The TCP connection method to use for the health check.`,choices:[`connection_established`]}).coerce(`tcp-config-method`,e=>s(e,`tcp-config-method`,`text`)).option(`tcp-config-port`,{type:`number`,description:`Port number to connect to for the health check. Defaults to 80.`}).option(`timeout`,{type:`number`,description:`The timeout (in seconds) before marking the health check as failed.`,default:5}).option(`type`,{type:`string`,description:`The protocol to use for the health check. Currently supported protocols are 'HTTP', 'HTTPS' and 'TCP'.`,default:`HTTP`}).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:`Create Health Check`,builder:m,handler:async e=>c({command:`healthchecks create`,classification:{safeFlags:[`http-config-allow-insecure`,`http-config-follow-redirects`,`http-config-method`,`suspended`,`tcp-config-method`,`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf healthchecks create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/healthchecks`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?a({address:s(e.address,`address`,`text`),check_regions:e[`check-regions`],consecutive_fails:e[`consecutive-fails`],consecutive_successes:e[`consecutive-successes`],description:s(e.description,`description`,`text`),http_config:{allow_insecure:e[`http-config-allow-insecure`],expected_body:s(e[`http-config-expected-body`],`http-config-expected-body`,`text`),expected_codes:e[`http-config-expected-codes`],follow_redirects:e[`http-config-follow-redirects`],header:r(e[`http-config-header`],`http-config-header`),method:e[`http-config-method`],path:s(e[`http-config-path`],`http-config-path`,`text`),port:e[`http-config-port`]},interval:e.interval,name:s(e.name,`name`,`text`),retries:e.retries,suspended:e.suspended,tcp_config:{method:e[`tcp-config-method`],port:e[`tcp-config-port`]},timeout:e.timeout,type:s(e.type,`type`,`text`)},[[`http_config`,`header`]]):i(e.body)});return}let c=e.body===void 0?void 0:i(e.body),f=await t(e),m=await n({zone:e.zone},f,{quiet:e.quiet});if(e.zoneId=m,e.body!==void 0){let e=c,t=await u(`Creating`,async()=>f.send(p,{body:e,zone_id:m}));l(t,{successLabel:`Created`});return}e.address===void 0&&(e.address=await d(`address`,`The hostname or IP address of the origin server to run health checks on.`)),e.name===void 0&&(e.name=await d(`name`,`A short name to identify the health check. Only alphanumeric characters, hyphens and underscores are allowed.`));let h=a({address:s(e.address,`address`,`text`),check_regions:e[`check-regions`],consecutive_fails:e[`consecutive-fails`],consecutive_successes:e[`consecutive-successes`],description:s(e.description,`description`,`text`),http_config:{allow_insecure:e[`http-config-allow-insecure`],expected_body:s(e[`http-config-expected-body`],`http-config-expected-body`,`text`),expected_codes:e[`http-config-expected-codes`],follow_redirects:e[`http-config-follow-redirects`],header:r(e[`http-config-header`],`http-config-header`),method:e[`http-config-method`],path:s(e[`http-config-path`],`http-config-path`,`text`),port:e[`http-config-port`]},interval:e.interval,name:s(e.name,`name`,`text`),retries:e.retries,suspended:e.suspended,tcp_config:{method:e[`tcp-config-method`],port:e[`tcp-config-port`]},timeout:e.timeout,type:s(e.type,`type`,`text`)},[[`http_config`,`header`]]),g=await u(`Creating`,async()=>f.send(p,{body:h,zone_id:m}));l(g,{successLabel:`Created`})})};var g={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/healthchecks/${t.healthcheck_id}`};function _(e){return e.usage(`$0 healthchecks delete <healthcheck-id>
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{r as n,t as r}from"./body-parser-HN91kAf0.mjs";import{a as i,t as a}from"./context-DlFhI9cN.mjs";import{t as o}from"./dry-run-mrA7FFLR.mjs";import{n as s}from"./input-validation-D7z60HJH.mjs";import{t as c}from"./local-B3zt9PXR.mjs";import{t as l}from"./run-DAg7dfIW.mjs";import{t as u}from"./output-PRKYaJuo.mjs";import{t as d}from"./progress-AML-AVs4.mjs";import{a as f,i as p,n as m}from"./prompt-Bnon9lfK.mjs";import"./telemetry-DDs3zhdw.mjs";var h={method:`POST`,path:t=>e`/accounts/${t.account_id}/hyperdrive/configs`,body:`json`};function g(e){return e.usage(`$0 hyperdrive create
2
+ import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-NIRm11Ab.mjs";import{r as n,t as r}from"./body-parser-HN91kAf0.mjs";import{a as i,t as a}from"./context-CroqTqbk.mjs";import{t as o}from"./dry-run-mrA7FFLR.mjs";import{n as s}from"./input-validation-D7z60HJH.mjs";import{t as c}from"./local-B3zt9PXR.mjs";import{t as l}from"./run-DhU17ztU.mjs";import{t as u}from"./output-PRKYaJuo.mjs";import{t as d}from"./progress-DQfZZwit.mjs";import{a as f,i as p,n as m}from"./prompt-e6K5lhdE.mjs";import"./telemetry-CruYXv5e.mjs";var h={method:`POST`,path:t=>e`/accounts/${t.account_id}/hyperdrive/configs`,body:`json`};function g(e){return e.usage(`$0 hyperdrive create
3
3
 
4
4
  Creates and returns a new Hyperdrive configuration. For a PlanetScale integration, the Cloudflare account must already be linked to PlanetScale in the Hyperdrive dashboard.`).option(`mtls-ca-certificate-id`,{type:`string`,description:`Define CA certificate ID obtained after uploading CA cert.`}).option(`mtls-certificate-id`,{type:`string`,description:`Define mTLS certificate ID obtained after uploading client cert.`}).option(`mtls-sslmode`,{type:`string`,description:"PostgreSQL accepts `require`, `verify-ca`, and `verify-full`. MySQL accepts `REQUIRED`, `VERIFY_CA`, and `VERIFY_IDENTITY`. The verify modes require a CA certificate; the require modes cannot be used with a CA certificate.",choices:[`require`,`verify-ca`,`verify-full`,`REQUIRED`,`VERIFY_CA`,`VERIFY_IDENTITY`]}).coerce(`mtls-sslmode`,e=>s(e,`mtls-sslmode`,`text`)).option(`name`,{type:`string`,description:`The name of the Hyperdrive configuration. Used to identify the configuration in the Cloudflare dashboard and API.`}).option(`origin-connection-limit`,{type:`number`,description:`The (soft) maximum number of connections the Hyperdrive is allowed to make to the origin database.
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{o as n,r,t as i}from"./body-parser-HN91kAf0.mjs";import{t as a}from"./dry-run-mrA7FFLR.mjs";import{a as o,t as s}from"./context-DlFhI9cN.mjs";import{n as c}from"./input-validation-D7z60HJH.mjs";import{t as l}from"./local-B3zt9PXR.mjs";import{t as u}from"./output-PRKYaJuo.mjs";import{t as d}from"./run-DAg7dfIW.mjs";import{t as f}from"./progress-AML-AVs4.mjs";import{a as p,i as m,n as h}from"./prompt-Bnon9lfK.mjs";import"./telemetry-DDs3zhdw.mjs";import{t as g}from"./list-ByCv9-Fl.mjs";var _={method:`POST`,path:t=>e`/accounts/${t.account_id}/oauth_clients`,body:`json`};function v(e){return e.usage(`$0 iam oauth-clients create
2
+ import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-NIRm11Ab.mjs";import{o as n,r,t as i}from"./body-parser-HN91kAf0.mjs";import{t as a}from"./dry-run-mrA7FFLR.mjs";import{a as o,t as s}from"./context-CroqTqbk.mjs";import{n as c}from"./input-validation-D7z60HJH.mjs";import{t as l}from"./local-B3zt9PXR.mjs";import{t as u}from"./output-PRKYaJuo.mjs";import{t as d}from"./run-DhU17ztU.mjs";import{t as f}from"./progress-DQfZZwit.mjs";import{a as p,i as m,n as h}from"./prompt-e6K5lhdE.mjs";import"./telemetry-CruYXv5e.mjs";import{t as g}from"./list-ByCv9-Fl.mjs";var _={method:`POST`,path:t=>e`/accounts/${t.account_id}/oauth_clients`,body:`json`};function v(e){return e.usage(`$0 iam oauth-clients create
3
3
 
4
4
  Create a new OAuth client for an account.`).option(`allowed-cors-origins`,{type:`string`,array:!0,description:`Array of allowed CORS origins.`}).option(`client-name`,{type:`string`,description:`Human-readable name of the OAuth client.`}).option(`client-uri`,{type:`string`,description:`URL of the home page of the client.`}).option(`grant-types`,{type:`string`,array:!0,description:"Array of OAuth grant types the client is allowed to use. `authorization_code` is required; `refresh_token` may be included optionally."}).option(`logo-uri`,{type:`string`,description:`URL of the client's logo.`}).option(`optional-scopes`,{type:`string`,array:!0,description:"Scopes that the authorizing user may decline during consent. Each value must also appear in `scopes`. The scopes `openid`, `offline`, and `offline_access` cannot be optional."}).option(`policy-uri`,{type:`string`,description:`URL that points to a privacy policy document.`}).option(`post-logout-redirect-uris`,{type:`string`,array:!0,description:`Array of allowed post-logout redirect URIs.`}).option(`redirect-uris`,{type:`string`,array:!0,description:`Array of allowed redirect URIs for the client.`}).option(`response-types`,{type:`string`,array:!0,description:`Array of OAuth response types the client is allowed to use.`}).option(`scopes`,{type:`string`,array:!0,description:"Array of OAuth scopes the client is allowed to request. Colon-delimited scopes are not accepted. Dot-delimited scopes are validated against available OAuth API scopes; simple identity scopes are allowed. Protocol scopes `offline_access` and `openid` are added or removed automatically based on `grant_types` and `response_types`."}).option(`token-endpoint-auth-method`,{type:`string`,description:`The authentication method the client uses at the token endpoint.`,choices:[`none`,`client_secret_basic`,`client_secret_post`]}).coerce(`token-endpoint-auth-method`,e=>c(e,`token-endpoint-auth-method`,`text`)).option(`tos-uri`,{type:`string`,description:`URL that points to a terms of service document.`}).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:`create`,describe:`Create OAuth Client`,builder:v,handler:async e=>d({command:`iam oauth-clients create`,classification:{safeFlags:[`token-endpoint-auth-method`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=await o();a({command:`cf iam oauth-clients create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/oauth_clients`,pathParams:{},bodyKind:`json`,body:e.body===void 0?i({allowed_cors_origins:e[`allowed-cors-origins`],client_name:c(e[`client-name`],`client-name`,`text`),client_uri:c(e[`client-uri`],`client-uri`,`text`),grant_types:e[`grant-types`],logo_uri:c(e[`logo-uri`],`logo-uri`,`text`),optional_scopes:e[`optional-scopes`],policy_uri:c(e[`policy-uri`],`policy-uri`,`text`),post_logout_redirect_uris:e[`post-logout-redirect-uris`],redirect_uris:e[`redirect-uris`],response_types:e[`response-types`],scopes:e.scopes,token_endpoint_auth_method:e[`token-endpoint-auth-method`],tos_uri:c(e[`tos-uri`],`tos-uri`,`text`)}):r(e.body)});return}let n=e.body===void 0?void 0:r(e.body),d=await t(e),h=e.local?l:await s();if(e.accountId=h,e.body!==void 0){let e=n,t=await f(`Creating`,async()=>d.send(_,{body:e,account_id:h}));u(t,{successLabel:`Created`});return}if(e[`client-name`]===void 0&&(e[`client-name`]=await p(`client-name`,`Human-readable name of the OAuth client.`)),e[`grant-types`]===void 0)throw Error(`--grant-types is required (or pass --body with this field set).`);if(e[`redirect-uris`]===void 0)throw Error(`--redirect-uris is required (or pass --body with this field set).`);if(e[`response-types`]===void 0)throw Error(`--response-types is required (or pass --body with this field set).`);if(e.scopes===void 0)throw Error(`--scopes is required (or pass --body with this field set).`);e[`token-endpoint-auth-method`]===void 0&&(e[`token-endpoint-auth-method`]=await m(`token-endpoint-auth-method`,`The authentication method the client uses at the token endpoint.`,[`none`,`client_secret_basic`,`client_secret_post`]));let g=i({allowed_cors_origins:e[`allowed-cors-origins`],client_name:c(e[`client-name`],`client-name`,`text`),client_uri:c(e[`client-uri`],`client-uri`,`text`),grant_types:e[`grant-types`],logo_uri:c(e[`logo-uri`],`logo-uri`,`text`),optional_scopes:e[`optional-scopes`],policy_uri:c(e[`policy-uri`],`policy-uri`,`text`),post_logout_redirect_uris:e[`post-logout-redirect-uris`],redirect_uris:e[`redirect-uris`],response_types:e[`response-types`],scopes:e.scopes,token_endpoint_auth_method:e[`token-endpoint-auth-method`],tos_uri:c(e[`tos-uri`],`tos-uri`,`text`)}),v=await f(`Creating`,async()=>d.send(_,{body:g,account_id:h}));u(v,{successLabel:`Created`})})};var b={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/oauth_clients/${t.oauth_client_id}/rotate_secret`};function ee(e){return e.usage(`$0 iam oauth-clients delete-rotated-secret <oauth-client-id>
5
5
 
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{i as t,n}from"./auth-cj71dGxS.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{a as i,i as a,t as o}from"./context-DlFhI9cN.mjs";import{n as s,t as c}from"./input-validation-D7z60HJH.mjs";import{t as l}from"./local-B3zt9PXR.mjs";import{t as u}from"./output-PRKYaJuo.mjs";import{t as d}from"./run-DAg7dfIW.mjs";import{t as f}from"./progress-AML-AVs4.mjs";import"./telemetry-DDs3zhdw.mjs";import{a as p,i as m,n as h}from"./prompt-Bnon9lfK.mjs";import{i as g,o as _,r as v,t as y}from"./body-parser-HN91kAf0.mjs";import{n as b,t as x}from"./raw-fetch-0T1SwPa1.mjs";var S={method:`POST`,path:t=>e`/accounts/${t.account_id}/images/v1`,pathParams:[`account_id`],body:`form`};function ee(e){return e.usage(`$0 images create
2
+ import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{i as t,n}from"./auth-NIRm11Ab.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{a as i,i as a,t as o}from"./context-CroqTqbk.mjs";import{n as s,t as c}from"./input-validation-D7z60HJH.mjs";import{t as l}from"./local-B3zt9PXR.mjs";import{t as u}from"./output-PRKYaJuo.mjs";import{t as d}from"./run-DhU17ztU.mjs";import{t as f}from"./progress-DQfZZwit.mjs";import"./telemetry-CruYXv5e.mjs";import{a as p,i as m,n as h}from"./prompt-e6K5lhdE.mjs";import{i as g,o as _,r as v,t as y}from"./body-parser-HN91kAf0.mjs";import{n as b,t as x}from"./raw-fetch-DXSBORQI.mjs";var S={method:`POST`,path:t=>e`/accounts/${t.account_id}/images/v1`,pathParams:[`account_id`],body:`form`};function ee(e){return e.usage(`$0 images create
3
3
 
4
4
  Upload an image to CF Images. Images up to 10 Megabytes can be uploaded using a single HTTP POST (multipart/form-data) request by sending an image file or passing a URL accessible to the API.`).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`}).option(`creator`,{type:`string`,description:`Can set the creator field with an internal user ID.`}).option(`id`,{type:`string`,description:`An optional custom unique identifier for your image.`}).option(`metadata`,{type:`string`,description:`User modifiable key-value store. Can use used for keeping references to another system of record for managing images.`}).option(`require-signed-urls`,{type:`boolean`,description:`Indicates whether the image requires a signature token for the access.`}).option(`url`,{type:`string`,description:`A URL to fetch an image from origin. Only needed when type is uploading from a URL.`})}const te={command:`create`,describe:`Upload an image`,builder:ee,handler:async e=>d({command:`images create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf images create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/images/v1`,pathParams:{},bodyKind:`multipart`,body:{body:e.body,file:e.file,creator:e.creator,id:e.id,metadata:e.metadata,"require-signed-urls":e[`require-signed-urls`],url:e.url}});return}let a=await n(e),d=e.local?l:await o();if(e.accountId=d,e.file!==void 0||e.body!==void 0||e.creator!==void 0||e.id!==void 0||e.metadata!==void 0||e[`require-signed-urls`]!==void 0||e.url!==void 0){let n=new FormData;if(e.file!==void 0){let t=c(e.file);n.append(`file`,new Blob([t]),e.file.split(/[\\/]/).filter(Boolean).pop())}else e.body!==void 0&&n.append(`file`,e.body);if(e.creator!==void 0&&n.append(`creator`,String(s(e.creator,`creator`,`text`)??``)),e.id!==void 0&&n.append(`id`,String(s(e.id,`id`,`text`)??``)),e.metadata!==void 0){let t=typeof e.metadata==`string`?s(e.metadata,`metadata`,`text`):e.metadata;n.append(`metadata`,typeof t==`string`?t:JSON.stringify(t))}e[`require-signed-urls`]!==void 0&&n.append(`requireSignedURLs`,String(e[`require-signed-urls`])),e.url!==void 0&&n.append(`url`,String(s(e.url,`url`,`text`)??``));let r=await f(`Creating`,async()=>t(a,`POST`,`/accounts/${d}/images/v1`,{body:n}));u(r,{successLabel:`Created`});return}if(e.body!==void 0){let n=s(e.body,`body`,`binary`),r=await f(`Creating`,async()=>t(a,`POST`,`/accounts/${d}/images/v1`,{body:n,headers:{"Content-Type":`multipart/form-data`}}));u(r,{successLabel:`Created`});return}let p=await f(`Creating`,async()=>a.send(S,{account_id:d}));u(p,{successLabel:`Created`})})};var ne={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/images/v1/${t.image_id}`};function re(e){return e.usage(`$0 images delete <image-id>
5
5
 
package/dist/index.mjs CHANGED
@@ -1,2 +1,2 @@
1
1
  #!/usr/bin/env node
2
- import{n as e,r as t,t as n}from"./src-B8i6_XGg.mjs";import{t as r}from"./cli-exit-CstFZ1eJ.mjs";export{r as CliExit,n as buildCli,e as main,t as runMain};
2
+ import{n as e,r as t,t as n}from"./src-COKSSJwa.mjs";import{t as r}from"./cli-exit-CstFZ1eJ.mjs";export{r as CliExit,n as buildCli,e as main,t as runMain};