cf 1.0.0-beta.13 → 1.0.0-beta.15

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 (443) hide show
  1. package/README.md +10 -0
  2. package/dist/_meta/commands.json +5039 -2465
  3. package/dist/_meta/hand-written-commands.json +375 -22
  4. package/dist/_meta/schemas.json +2607 -1038
  5. package/dist/abuse-reports-CnQBtN1G.mjs +24 -0
  6. package/dist/access-BzmXSwzj.mjs +2 -0
  7. package/dist/account-tags-2qPWbW17.mjs +15 -0
  8. package/dist/accounts-B0Byg-AV.mjs +132 -0
  9. package/dist/acm-DgAu0cnk.mjs +15 -0
  10. package/dist/addressing-J1oa0ML2.mjs +105 -0
  11. package/dist/agent-memory-4KGou-tm.mjs +34 -0
  12. package/dist/ai-WY7wVQfA.mjs +31 -0
  13. package/dist/ai-audit-D38HaEoZ.mjs +6 -0
  14. package/dist/ai-gateway-C0gIipT8.mjs +80 -0
  15. package/dist/ai-search-ClwnPU-9.mjs +79 -0
  16. package/dist/ai-security-BIsvFPYV.mjs +10 -0
  17. package/dist/alerting-MHhv28oO.mjs +56 -0
  18. package/dist/analytics-BfBz7bqB.mjs +17 -0
  19. package/dist/analytics_engine-CXVdBF1n.mjs +4 -0
  20. package/dist/api-eMuS5GI1.mjs +3 -0
  21. package/dist/api-security-DUCfcdC1.mjs +154 -0
  22. package/dist/argo-CUlzI4v3.mjs +14 -0
  23. package/dist/artifacts-BLfWGzBg.mjs +43 -0
  24. package/dist/audit-logs-CsfIm2QS.mjs +4 -0
  25. package/dist/auth-8Sm4uLGM.mjs +2 -0
  26. package/dist/auth-C6u9qIGO.mjs +2 -0
  27. package/dist/auth-CGRemu5W.mjs +2 -0
  28. package/dist/{auth-token-pNQrX_9O.mjs → auth-token-DkkYg4DP.mjs} +1 -1
  29. package/dist/{autoconfig-sD7Frryg.mjs → autoconfig-B0ESZ8DJ.mjs} +2 -2
  30. package/dist/basin-catalog-CrKRYJ0b.mjs +46 -0
  31. package/dist/billing-NxehgXrR.mjs +23 -0
  32. package/dist/blocks-Bat9A8V_.mjs +5 -0
  33. package/dist/bot-management-C993iQKL.mjs +9 -0
  34. package/dist/botnet-feed-CZ4vYk5y.mjs +11 -0
  35. package/dist/brand-protection-ADVgIi0l.mjs +27 -0
  36. package/dist/browser-run-CEptKZYl.mjs +42 -0
  37. package/dist/build-Bm6kGyzo.mjs +2 -0
  38. package/dist/{build-HmSXqjGn.mjs → build-sBpqm9ga.mjs} +1 -1
  39. package/dist/builds-DqtiTH7p.mjs +71 -0
  40. package/dist/cache-hX5QxmI0.mjs +45 -0
  41. package/dist/certificate-authorities-BOcybjc1.mjs +6 -0
  42. package/dist/cf-Bq4pA4n6.mjs +18 -0
  43. package/dist/{chunk-TAK63GWY-DdMktrgc.mjs → chunk-2HLTAS5V-D7COzUOd.mjs} +2 -2
  44. package/dist/chunk-2K52M2W5-CYxfQXUq.mjs +363 -0
  45. package/dist/{chunk-DSGVRFIS-C1_SEtRK.mjs → chunk-DSGVRFIS-C5SqiTOz.mjs} +1 -1
  46. package/dist/{cli-DeJc9U8z.mjs → cli-R8h3OKZI.mjs} +1 -1
  47. package/dist/client-certificates-Bez_ArKE.mjs +13 -0
  48. package/dist/client-side-security-CSmA50Bv.mjs +63 -0
  49. package/dist/cloud-connector-0Wivqi7S.mjs +6 -0
  50. package/dist/{cloudflared--1Ws1RJy.mjs → cloudflared-By8BzYXc.mjs} +1 -1
  51. package/dist/cloudforce-one-J-rU6k1U.mjs +405 -0
  52. package/dist/{command-Dh7RmjFu.mjs → command-0BOb1pgV.mjs} +1 -1
  53. package/dist/{command-DUhX8Dcr.mjs → command-BCJN-ZM2.mjs} +1 -1
  54. package/dist/{command-BvfKhMl7.mjs → command-BG-kLOnS.mjs} +1 -1
  55. package/dist/{command-Cu7dcaHT.mjs → command-BIsI-mMX.mjs} +1 -1
  56. package/dist/{command-83uVfXh9.mjs → command-BKDbbA-L.mjs} +1 -1
  57. package/dist/command-BWQIKu6I.mjs +2 -0
  58. package/dist/{command-D3fyhdy-.mjs → command-Bdy69UFU.mjs} +1 -1
  59. package/dist/{command-BDe67N_n.mjs → command-Bgb-3yPg.mjs} +1 -1
  60. package/dist/{command-_rqD0hXF.mjs → command-C6w1OdoC.mjs} +1 -1
  61. package/dist/{command-oNVwyjGB.mjs → command-CKW6UhTh.mjs} +1 -1
  62. package/dist/{command-Bpzp8Mz2.mjs → command-DCQgsd2U.mjs} +1 -1
  63. package/dist/{command-CcuLC6CJ.mjs → command-DIs-Nqtl.mjs} +1 -1
  64. package/dist/command-DPn5ANHs.mjs +2 -0
  65. package/dist/{command-CG6RvZs0.mjs → command-DZfKHiru.mjs} +1 -1
  66. package/dist/{command-BlIb6RR2.mjs → command-DppVezAB.mjs} +1 -1
  67. package/dist/{completions-D06AO7A8.mjs → completions-CpNGTlUX.mjs} +1 -1
  68. package/dist/config.mjs +0 -0
  69. package/dist/connector-interrupts-CH-DaLuo.mjs +6 -0
  70. package/dist/connector-telemetry-events-X3Fod9nl.mjs +6 -0
  71. package/dist/connector-telemetry-snapshots-D-WR4npQ.mjs +6 -0
  72. package/dist/connectors-CORKD31m.mjs +15 -0
  73. package/dist/containers-BboUbx3k.mjs +78 -0
  74. package/dist/containers-Di3_Vopq.mjs +376 -0
  75. package/dist/content-scan-DXGREAXa.mjs +14 -0
  76. package/dist/{context-q7UaYK69.mjs → context-A6T-NKPI.mjs} +2 -2
  77. package/dist/cps-1BoOLtTq.mjs +6 -0
  78. package/dist/create-OXylMu6m.mjs +2 -0
  79. package/dist/csamScanner-CHfbfeup.mjs +10 -0
  80. package/dist/ct-alerting-DlH4ILQo.mjs +5 -0
  81. package/dist/custom-certificates-zJqJZ2Th.mjs +17 -0
  82. package/dist/custom-csrs-DoLIGqYL.mjs +11 -0
  83. package/dist/custom-hostnames-YfV-aoAK.mjs +27 -0
  84. package/dist/custom-nameservers-BV43gmgt.mjs +9 -0
  85. package/dist/custom-pages-CoOU1Cdx.mjs +21 -0
  86. package/dist/d1-DujBmzLa.mjs +94 -0
  87. package/dist/dcv-delegation-CPLsVYOl.mjs +4 -0
  88. package/dist/delegate.mjs +0 -0
  89. package/dist/deploy-context-tEhwEXnA.mjs +56 -0
  90. package/dist/{deploy-input-Cc0_2QlW.mjs → deploy-input-BqJ7GVZ-.mjs} +1 -1
  91. package/dist/{deploy-CWNm1-5v.mjs → deploy-wNujfGUJ.mjs} +1 -1
  92. package/dist/{dev-ZA8itQE7.mjs → dev-EtnMYA7K.mjs} +1 -1
  93. package/dist/diagnostics-B3TYPVRi.mjs +15 -0
  94. package/dist/dist-DZRTPMMA.mjs +449 -0
  95. package/dist/dls-CWm1HRF0.mjs +17 -0
  96. package/dist/dns-CjAFU7Z9.mjs +144 -0
  97. package/dist/dns-firewall-BooBP9ap.mjs +71 -0
  98. package/dist/docs-C5XB7HdG.mjs +3 -0
  99. package/dist/{dotenv-DpXaxfho.mjs → dotenv-usOKkeW7.mjs} +3 -3
  100. package/dist/{dry-run-DRj2_uV3.mjs → dry-run-C2KjGX10.mjs} +1 -1
  101. package/dist/durable-objects-CSrMQDCE.mjs +6 -0
  102. package/dist/email-auth-Bp1Mui-n.mjs +6 -0
  103. package/dist/email-routing-CVF6SwQt.mjs +45 -0
  104. package/dist/email-security-mYZtazae.mjs +158 -0
  105. package/dist/email-sending-BqaKU_Xu.mjs +47 -0
  106. package/dist/error-sanitization-CIQOep3I.mjs +2 -0
  107. package/dist/error-sanitization-pOyzm2F1.mjs +2 -0
  108. package/dist/fieldExtractors-CAGZVmYg.mjs +9 -0
  109. package/dist/firewall-DgTDsYOt.mjs +36 -0
  110. package/dist/flagship-Db3PxxyZ.mjs +28 -0
  111. package/dist/fraud-BEOQczy8.mjs +22 -0
  112. package/dist/get-By1q8YlI.mjs +2 -0
  113. package/dist/get-CRKvqCu6.mjs +2 -0
  114. package/dist/get-iPUHxD1r.mjs +2 -0
  115. package/dist/google-tag-gateway-DjLQ9wo0.mjs +6 -0
  116. package/dist/hand-written-dry-run-B82fRl2N.mjs +2 -0
  117. package/dist/healthchecks-C3ScnKss.mjs +22 -0
  118. package/dist/{hostnames-sF999-6H.mjs → hostnames-DU0k-xO9.mjs} +6 -6
  119. package/dist/hyperdrive-IpCCLCRd.mjs +37 -0
  120. package/dist/iam-96CYM8Vw.mjs +52 -0
  121. package/dist/images-AB9EgZgT.mjs +71 -0
  122. package/dist/index.mjs +1 -1
  123. package/dist/{init-1w_mcgk3.mjs → init-D2nPoW4f.mjs} +2 -2
  124. package/dist/intel-BKb4RLvS.mjs +76 -0
  125. package/dist/ips-z9APCV_b.mjs +4 -0
  126. package/dist/k2-Bv-HiJ29.mjs +11 -0
  127. package/dist/keyless-certificates-ChgSGHq4.mjs +13 -0
  128. package/dist/keys-BhngDsDa.mjs +4 -0
  129. package/dist/kv-CB5MQVGP.mjs +15 -0
  130. package/dist/{lazy-command-BDiIwpss.mjs → lazy-command-CaZ1kdlW.mjs} +1 -1
  131. package/dist/leaked-credential-checks-Bsi2WpSU.mjs +18 -0
  132. package/dist/load-balancers-0gXZNCeI.mjs +76 -0
  133. package/dist/{local-DlT72Xpn.mjs → local-Dil4fTWX.mjs} +1 -1
  134. package/dist/local-DxWDQDnG.mjs +2 -0
  135. package/dist/{local-runtime-CokO6qaX.mjs → local-runtime-B7TKFu6E.mjs} +1 -1
  136. package/dist/login-CiQGR8ha.mjs +5 -0
  137. package/dist/login-Ik98G4K6.mjs +2 -0
  138. package/dist/logo-matches-DmoF5Otu.mjs +6 -0
  139. package/dist/logos-BL6ohIMH.mjs +7 -0
  140. package/dist/logpush-UVopW68t.mjs +46 -0
  141. package/dist/logs-BVfxiEiM.mjs +36 -0
  142. package/dist/magic-cloud-networking-B5S3aM6f.mjs +71 -0
  143. package/dist/magic-network-monitoring-CDSJPP47.mjs +36 -0
  144. package/dist/magic-transit-TcDTKM43.mjs +386 -0
  145. package/dist/managed-defense-C88HL0pg.mjs +18 -0
  146. package/dist/managed-transforms-Ja41Tahl.mjs +9 -0
  147. package/dist/matches-BL_Y-9Yq.mjs +6 -0
  148. package/dist/mcp-BWp5Q09R.mjs +32 -0
  149. package/dist/mesh-lFPLRWhV.mjs +26 -0
  150. package/dist/{migrate-CZNq63Uj.mjs → migrate-6e5mJ79R.mjs} +1 -1
  151. package/dist/monetization-BIc4Bwo2.mjs +20 -0
  152. package/dist/mtls-certificates-CVBw-Jli.mjs +13 -0
  153. package/dist/network-Wig0qbaC.mjs +50 -0
  154. package/dist/network-interconnects-C16z1HuQ.mjs +72 -0
  155. package/dist/o11y-Bhy4qDRm.mjs +93 -0
  156. package/dist/oauth-CfEedDZi.mjs +4 -0
  157. package/dist/oauth-clients-eXjmK5yf.mjs +16 -0
  158. package/dist/{oauth-mspHHU5U.mjs → oauth-oWaW7ICv.mjs} +1 -1
  159. package/dist/oauth-scopes-DZWn50EA.mjs +4 -0
  160. package/dist/organization-QdAQTrKa.mjs +71 -0
  161. package/dist/organizations-CgAQYdK5.mjs +4 -0
  162. package/dist/origin-ca-certificates-BklXqp8X.mjs +11 -0
  163. package/dist/origin-post-quantum-encryption-Dg16ueT4.mjs +6 -0
  164. package/dist/origin-tls-client-auth-d8bDU5zU.mjs +30 -0
  165. package/dist/output-Co4xdFf6.mjs +2 -0
  166. package/dist/page-rules-CgMkC6YR.mjs +39 -0
  167. package/dist/pages-CkBtOOf8.mjs +54 -0
  168. package/dist/path-DRw6Y-nd.mjs +2 -0
  169. package/dist/pay-per-crawl-CnGXOWyz.mjs +38 -0
  170. package/dist/pay-per-use-HbfxpATr.mjs +33 -0
  171. package/dist/pipelines-CnO9CCs0.mjs +44 -0
  172. package/dist/precursor-Bc55XJdQ.mjs +4 -0
  173. package/dist/previews-C7vZrajd.mjs +7 -0
  174. package/dist/progress-D5po7ScB.mjs +2 -0
  175. package/dist/prompt-BAJpE3jV.mjs +4 -0
  176. package/dist/queries-BJAH4B74.mjs +9 -0
  177. package/dist/queues-D4G8vvwi.mjs +57 -0
  178. package/dist/r2-CJ8rD6Jb.mjs +128 -0
  179. package/dist/{radar-DrQLcbkq.mjs → radar-DgaxOdcd.mjs} +150 -150
  180. package/dist/raw-fetch-yY-wX5Xx.mjs +2 -0
  181. package/dist/realtime-DU09m7L7.mjs +172 -0
  182. package/dist/registrar-Cj7OfvGs.mjs +43 -0
  183. package/dist/registrar-sandbox-CA0Mua-j.mjs +56 -0
  184. package/dist/{registry-CHowrQsZ.mjs → registry-CRnk93ur.mjs} +1 -1
  185. package/dist/reporting-3kDVF5c8.mjs +14 -0
  186. package/dist/{request-headers-DiJeDAn1.mjs → request-headers-D_eQn93b.mjs} +1 -1
  187. package/dist/request-tracers-VBD4R3s3.mjs +4 -0
  188. package/dist/resolve-BpgXeklt.mjs +2 -0
  189. package/dist/resolve-C3FmNlSO.mjs +2 -0
  190. package/dist/resource-sharing-BtUF3psS.mjs +40 -0
  191. package/dist/resource-tagging--90INP8_.mjs +4 -0
  192. package/dist/rules-CcwPngVo.mjs +18 -0
  193. package/dist/rulesets-CfdruY82.mjs +37 -0
  194. package/dist/rum-RLkdfSL7.mjs +30 -0
  195. package/dist/run-CUNhH5CQ.mjs +2 -0
  196. package/dist/{run-BvHwWWUX.mjs → run-DASYqJsY.mjs} +1 -1
  197. package/dist/{schema-elj12WOx.mjs → schema-S3pUZwpI.mjs} +1 -1
  198. package/dist/{schema-flags-BzoBGPWk.mjs → schema-flags-CShtn7ya.mjs} +1 -1
  199. package/dist/scim-BZYsTPIL.mjs +18 -0
  200. package/dist/secrets-store-C_-FkSH_.mjs +24 -0
  201. package/dist/security-insights-BVBEaZmD.mjs +40 -0
  202. package/dist/security-txt--IoHrHee.mjs +9 -0
  203. package/dist/session-Cq3YNLoI.mjs +2 -0
  204. package/dist/shared-zNQNv1im.mjs +2 -0
  205. package/dist/smart-shield-CByC4_60.mjs +24 -0
  206. package/dist/snippets-DB-jiZAV.mjs +20 -0
  207. package/dist/{spawn-IysxuTNW.mjs → spawn-DQttFH05.mjs} +1 -1
  208. package/dist/spectrum-Bs2g1BmK.mjs +83 -0
  209. package/dist/speed-Bq4evEnJ.mjs +24 -0
  210. package/dist/sql-XGci7hZC.mjs +4 -0
  211. package/dist/src-GiuwAT55.mjs +125 -0
  212. package/dist/ssl-KJTLW1NR.mjs +45 -0
  213. package/dist/{startup-profile-CdJWgNjd.mjs → startup-profile-BOaseXnO.mjs} +1 -1
  214. package/dist/startup-profile-BwEZFVGS.mjs +2 -0
  215. package/dist/{state-BDSvdSdP.mjs → state-Boubf1X6.mjs} +1 -1
  216. package/dist/state-CODDG9Nx.mjs +2 -0
  217. package/dist/stream-BotgYspF.mjs +102 -0
  218. package/dist/submit-C5VytaHP.mjs +4 -0
  219. package/dist/{tags-CA1xMM96.mjs → tags-3Hq-B9qp.mjs} +2 -2
  220. package/dist/{telemetry-Cm39QJ-M.mjs → telemetry-3FJOXl_C.mjs} +1 -1
  221. package/dist/telemetry-BhKfwxyh.mjs +2 -0
  222. package/dist/tenant-BgX5onPc.mjs +10 -0
  223. package/dist/tenant-custom-nameservers-BVG8v1Xo.mjs +9 -0
  224. package/dist/theme-BGHWSKCw.mjs +6 -0
  225. package/dist/{tools-CSc5DmFi.mjs → tools-BCCRUENY.mjs} +1 -1
  226. package/dist/tunnels-CThOI3qH.mjs +29 -0
  227. package/dist/turnstile-BgZaUx-g.mjs +33 -0
  228. package/dist/ui-BtIBQeaG.mjs +2 -0
  229. package/dist/update-check-Yy7Ivq2V.mjs +2 -0
  230. package/dist/{update-check-CMXSdres.mjs → update-check-jb89ih_g.mjs} +1 -1
  231. package/dist/update-check-worker.mjs +1 -1
  232. package/dist/url-info-DQERN0Xq.mjs +4 -0
  233. package/dist/url-normalization-Cb1hofqv.mjs +9 -0
  234. package/dist/url-scanner-gHgx1bW7.mjs +16 -0
  235. package/dist/user-CdKzIuSi.mjs +112 -0
  236. package/dist/values-EwA8Sx0w.mjs +4 -0
  237. package/dist/vectorize-DejgIJIv.mjs +32 -0
  238. package/dist/version-B6MnUIqV.mjs +2 -0
  239. package/dist/waiting-rooms-BNR1HvAP.mjs +53 -0
  240. package/dist/web-assets-iglnzkTV.mjs +64 -0
  241. package/dist/web3-JBUU6IVt.mjs +28 -0
  242. package/dist/workers-CDp4kLTJ.mjs +40 -0
  243. package/dist/workers-builds-CSb9Dglt.mjs +14 -0
  244. package/dist/workers-for-platforms-D4srNZvt.mjs +40 -0
  245. package/dist/workers-vpc-LPC8TadH.mjs +13 -0
  246. package/dist/workflows-DN_VqWJC.mjs +52 -0
  247. package/dist/{wrangler-migration-C6FKHER1.mjs → wrangler-migration-DxTB5yPT.mjs} +1 -1
  248. package/dist/zaraz-DDErl5yc.mjs +22 -0
  249. package/dist/zero-trust-M88XX3uD.mjs +957 -0
  250. package/dist/zone-BsGvedmN.mjs +4 -0
  251. package/dist/zones-l_sRKrVl.mjs +124 -0
  252. package/package.json +17 -20
  253. package/dist/Page-BShsqCXr.mjs +0 -2
  254. package/dist/abuse-reports-BjU1s8cf.mjs +0 -24
  255. package/dist/access-C_G2MZnA.mjs +0 -2
  256. package/dist/account-tags-CaXDDeZ4.mjs +0 -15
  257. package/dist/accounts-BALwxDQY.mjs +0 -131
  258. package/dist/acm-CP9EaXQN.mjs +0 -15
  259. package/dist/addressing-DRlaxqrI.mjs +0 -93
  260. package/dist/agent-memory-vGhlfZBx.mjs +0 -34
  261. package/dist/ai-CJtbWfB9.mjs +0 -31
  262. package/dist/ai-audit-C0BJNqZZ.mjs +0 -6
  263. package/dist/ai-gateway-BQtv3U3x.mjs +0 -80
  264. package/dist/ai-search-DGU1Y5By.mjs +0 -79
  265. package/dist/ai-security-CFTaYk_X.mjs +0 -10
  266. package/dist/alerting-1hun27JC.mjs +0 -56
  267. package/dist/analytics-DXUSjvzT.mjs +0 -17
  268. package/dist/analytics_engine-CQsnL09C.mjs +0 -4
  269. package/dist/api-security-BXhrfR6-.mjs +0 -154
  270. package/dist/argo-LPUCTnee.mjs +0 -14
  271. package/dist/args-CfbYkeXd.mjs +0 -2
  272. package/dist/artifacts-Dt6easua.mjs +0 -43
  273. package/dist/audit-logs-CVznAM2Z.mjs +0 -4
  274. package/dist/auth-CGLsxbc6.mjs +0 -2
  275. package/dist/auth-CrmVwfpJ.mjs +0 -2
  276. package/dist/auth-eQr-kQCH.mjs +0 -2
  277. package/dist/banner-D03JEqRs.mjs +0 -2
  278. package/dist/basin-catalog-ZQICw-zF.mjs +0 -46
  279. package/dist/billing-Dy1-dV_B.mjs +0 -23
  280. package/dist/bot-management-DTgPwL7O.mjs +0 -9
  281. package/dist/botnet-feed-xb98Cj3Y.mjs +0 -11
  282. package/dist/brand-protection-Ck3okE2k.mjs +0 -27
  283. package/dist/browser-run-DJGJSzFX.mjs +0 -42
  284. package/dist/build-B1L6xrgC.mjs +0 -2
  285. package/dist/builds-CYxcZtkG.mjs +0 -71
  286. package/dist/cache-D9tSfovH.mjs +0 -45
  287. package/dist/certificate-authorities-CpiveTFC.mjs +0 -6
  288. package/dist/cf-BxsXrVeh.mjs +0 -18
  289. package/dist/chunk-NDZDTP46-Bjx_wtJe.mjs +0 -361
  290. package/dist/cli-types-9oYmRTHJ.mjs +0 -2
  291. package/dist/client-certificates-CF6YZyvP.mjs +0 -13
  292. package/dist/client-side-security-BLoe9kS5.mjs +0 -63
  293. package/dist/cloud-connector-DXRUHsjt.mjs +0 -6
  294. package/dist/cloudforce-one-CBLxXi6v.mjs +0 -447
  295. package/dist/command-DwXiDOeH.mjs +0 -2
  296. package/dist/command-UiHLJ8Ji.mjs +0 -2
  297. package/dist/connector-interrupts-DelTmNyw.mjs +0 -6
  298. package/dist/connector-telemetry-events-BwxR3G8d.mjs +0 -6
  299. package/dist/connector-telemetry-snapshots-Bqq-hrpJ.mjs +0 -6
  300. package/dist/connectors-D-m3rEpk.mjs +0 -15
  301. package/dist/containers-CVNfEjJs.mjs +0 -78
  302. package/dist/containers-DeoZyeQe.mjs +0 -375
  303. package/dist/content-scan-W0BNzbQp.mjs +0 -14
  304. package/dist/cps-BZ6hqRb5.mjs +0 -6
  305. package/dist/csamScanner-Bo1t3CLh.mjs +0 -10
  306. package/dist/ct-alerting-E03faC7p.mjs +0 -5
  307. package/dist/custom-certificates-CUySSPzi.mjs +0 -17
  308. package/dist/custom-csrs-gNpWkJPQ.mjs +0 -11
  309. package/dist/custom-hostnames-abGBAbx7.mjs +0 -27
  310. package/dist/custom-nameservers-BgNXol1P.mjs +0 -9
  311. package/dist/custom-pages-DMKX3aoD.mjs +0 -21
  312. package/dist/d1-CE08YqYk.mjs +0 -93
  313. package/dist/dcv-delegation-B5YUEWu0.mjs +0 -4
  314. package/dist/deploy-context-Dr6bxNcB.mjs +0 -56
  315. package/dist/diagnostics-UMbG6m4n.mjs +0 -15
  316. package/dist/dist-BHEmAAHr.mjs +0 -487
  317. package/dist/dls-DIl16mLp.mjs +0 -17
  318. package/dist/dns-QUpgljRG.mjs +0 -144
  319. package/dist/dns-firewall-BZwJXHLj.mjs +0 -71
  320. package/dist/durable-objects-BCj4ykpU.mjs +0 -6
  321. package/dist/email-auth-DlHIYhCk.mjs +0 -6
  322. package/dist/email-routing-UKVS4DYy.mjs +0 -45
  323. package/dist/email-security-CZjfRIg0.mjs +0 -158
  324. package/dist/email-sending-Dquc880C.mjs +0 -47
  325. package/dist/error-sanitization-DE_zSrXw.mjs +0 -2
  326. package/dist/error-sanitization-DOCQ9Ykh.mjs +0 -2
  327. package/dist/errors-_sob7Ihu.mjs +0 -3
  328. package/dist/fieldExtractors-BbwDRquU.mjs +0 -9
  329. package/dist/firewall--mTfDnCJ.mjs +0 -36
  330. package/dist/flagship-cfoSwwM9.mjs +0 -28
  331. package/dist/fraud-Dcsq3EYK.mjs +0 -22
  332. package/dist/google-tag-gateway-DPKSkZQi.mjs +0 -6
  333. package/dist/healthchecks-D78hIIBC.mjs +0 -22
  334. package/dist/hyperdrive-qWACKfA4.mjs +0 -37
  335. package/dist/iam-Bvg_PayW.mjs +0 -52
  336. package/dist/images-DI_lEZ4L.mjs +0 -71
  337. package/dist/intel-BxElBUMP.mjs +0 -76
  338. package/dist/ips-DWoaKxi7.mjs +0 -4
  339. package/dist/k2-tFjaftl-.mjs +0 -11
  340. package/dist/keyless-certificates-BrvxHU4J.mjs +0 -13
  341. package/dist/keys-DcwTYKRf.mjs +0 -4
  342. package/dist/kv-htXS-7uP.mjs +0 -15
  343. package/dist/leaked-credential-checks-bvGrLOmQ.mjs +0 -18
  344. package/dist/load-balancers-BNTUt4yG.mjs +0 -76
  345. package/dist/local-DlDumOSC.mjs +0 -2
  346. package/dist/login-BGF_I_LT.mjs +0 -5
  347. package/dist/login-Ccw-mYwT.mjs +0 -2
  348. package/dist/logo-matches-tE8LTKgg.mjs +0 -6
  349. package/dist/logos-Bj845Mcw.mjs +0 -7
  350. package/dist/logpush-Cs8JdvKi.mjs +0 -46
  351. package/dist/logs-C92XZvNu.mjs +0 -36
  352. package/dist/magic-cloud-networking-hNp5MMw-.mjs +0 -71
  353. package/dist/magic-network-monitoring-68GuWAnv.mjs +0 -36
  354. package/dist/magic-transit-DNd7gu4j.mjs +0 -383
  355. package/dist/managed-defense-B_wCAuFD.mjs +0 -18
  356. package/dist/managed-transforms-DZdxHPOh.mjs +0 -9
  357. package/dist/matches-B65CkflD.mjs +0 -6
  358. package/dist/mcp-DrJW5ayK.mjs +0 -32
  359. package/dist/mesh-DfVzYTn1.mjs +0 -26
  360. package/dist/monetization-BGaI8CMO.mjs +0 -20
  361. package/dist/mtls-certificates-BsU2emDD.mjs +0 -13
  362. package/dist/network-BEMD8P0U.mjs +0 -50
  363. package/dist/network-interconnects-DMu_fcbo.mjs +0 -68
  364. package/dist/o11y-C1a4gDGF.mjs +0 -93
  365. package/dist/oauth-Bj5Ne1o8.mjs +0 -9
  366. package/dist/oauth-clients-p4Etdqy_.mjs +0 -16
  367. package/dist/oauth-scopes-B2IabFza.mjs +0 -4
  368. package/dist/organization-CdXt7AVZ.mjs +0 -75
  369. package/dist/organizations-5S6xEp7T.mjs +0 -4
  370. package/dist/origin-ca-certificates-_VJAoK1D.mjs +0 -11
  371. package/dist/origin-post-quantum-encryption-GcldDsT2.mjs +0 -6
  372. package/dist/origin-tls-client-auth-DZHld9fA.mjs +0 -30
  373. package/dist/output-BOe-3AQG.mjs +0 -2
  374. package/dist/page-rules-o1tAMMsD.mjs +0 -39
  375. package/dist/pages-CmiOhjSl.mjs +0 -54
  376. package/dist/pay-per-crawl-BsnOxGYU.mjs +0 -38
  377. package/dist/pay-per-use-BXWMCSyE.mjs +0 -33
  378. package/dist/pipelines-DWLQC0F6.mjs +0 -44
  379. package/dist/precursor-B6DjBib6.mjs +0 -4
  380. package/dist/previews-dUKEBGSM.mjs +0 -4
  381. package/dist/progress-BtkTVcHI.mjs +0 -2
  382. package/dist/prompt-RlgRrmbm.mjs +0 -3
  383. package/dist/queries-yLwoJRHV.mjs +0 -9
  384. package/dist/queues-CnJRaE1o.mjs +0 -57
  385. package/dist/r2-CuC6-zQX.mjs +0 -128
  386. package/dist/raw-fetch-B4NvWuZD.mjs +0 -2
  387. package/dist/realtime-CjsnzHxD.mjs +0 -172
  388. package/dist/registrar-BgOsxTnX.mjs +0 -43
  389. package/dist/registrar-sandbox-3ikBD9fB.mjs +0 -56
  390. package/dist/reporting-hE127s5r.mjs +0 -14
  391. package/dist/request-tracers-BCwLxmPN.mjs +0 -4
  392. package/dist/resolve-CaTBV-c6.mjs +0 -2
  393. package/dist/resolve-DCGSzUDQ.mjs +0 -2
  394. package/dist/resource-sharing-2qvWUuMa.mjs +0 -40
  395. package/dist/resource-tagging-Dwx7iL3v.mjs +0 -4
  396. package/dist/rules-DxVQ6jIg.mjs +0 -18
  397. package/dist/rulesets-Cdh8YjI9.mjs +0 -37
  398. package/dist/rum-a4CMq4Qu.mjs +0 -30
  399. package/dist/run-CkbrPJPx.mjs +0 -2
  400. package/dist/scim-B8XlXl8v.mjs +0 -18
  401. package/dist/secrets-store-Cqhedh_i.mjs +0 -24
  402. package/dist/security-insights-le2-DteL.mjs +0 -40
  403. package/dist/security-txt-cCArWXur.mjs +0 -9
  404. package/dist/session-C1BhT1ZJ.mjs +0 -2
  405. package/dist/shared-BPjcpXuA.mjs +0 -2
  406. package/dist/smart-shield-Csyh8hwB.mjs +0 -24
  407. package/dist/snippets-DUWx25q6.mjs +0 -20
  408. package/dist/spectrum-Da3UYSOR.mjs +0 -83
  409. package/dist/speed-NxlMnB2e.mjs +0 -24
  410. package/dist/sql-CNdHAlQ8.mjs +0 -4
  411. package/dist/src-JfLDUxFr.mjs +0 -125
  412. package/dist/ssl-BtaX2WEJ.mjs +0 -45
  413. package/dist/startup-profile-B2l0ChVu.mjs +0 -2
  414. package/dist/state-JB4_BU1o.mjs +0 -2
  415. package/dist/stream-C1Ijjzn4.mjs +0 -102
  416. package/dist/submit-MdkuU_Pt.mjs +0 -4
  417. package/dist/telemetry-BsYO3nxG.mjs +0 -2
  418. package/dist/tenant-BB6Oszcl.mjs +0 -10
  419. package/dist/tenant-custom-nameservers-BsbgYAEo.mjs +0 -9
  420. package/dist/theme-CQ_TYifs.mjs +0 -6
  421. package/dist/tunnels-CRFtyHWz.mjs +0 -29
  422. package/dist/turnstile-DBXWo_Xe.mjs +0 -33
  423. package/dist/ui-YmjF66Ct.mjs +0 -5
  424. package/dist/update-check-C2oVEbXx.mjs +0 -2
  425. package/dist/url-info-t-XAs0Mk.mjs +0 -4
  426. package/dist/url-normalization-Cs4F8e0a.mjs +0 -9
  427. package/dist/url-scanner-CBIoDbTx.mjs +0 -16
  428. package/dist/user-CevdOMoa.mjs +0 -112
  429. package/dist/values-CjNlkbIh.mjs +0 -4
  430. package/dist/vectorize-9d9tPmg5.mjs +0 -32
  431. package/dist/version-BdVUXLnK.mjs +0 -2
  432. package/dist/waiting-rooms--5WmrWb3.mjs +0 -53
  433. package/dist/web-assets-BHot_MU8.mjs +0 -64
  434. package/dist/web3-CYfWAF6b.mjs +0 -28
  435. package/dist/workers-S17M0n3h.mjs +0 -40
  436. package/dist/workers-builds-Dw7ho3So.mjs +0 -14
  437. package/dist/workers-for-platforms-A3yjyLh3.mjs +0 -40
  438. package/dist/workers-vpc-BZ2xXtC3.mjs +0 -13
  439. package/dist/workflows-BgGrVpSR.mjs +0 -43
  440. package/dist/zaraz-BsD2dMI3.mjs +0 -22
  441. package/dist/zero-trust-CA3iGQbG.mjs +0 -837
  442. package/dist/zone-D2M4EZD0.mjs +0 -4
  443. package/dist/zones-BoOC_JzC.mjs +0 -124
@@ -1,2 +0,0 @@
1
- #!/usr/bin/env node
2
- import{t as e}from"./auth-CGLsxbc6.mjs";import"./context-q7UaYK69.mjs";import"./oauth-Bj5Ne1o8.mjs";import"./auth-token-pNQrX_9O.mjs";export{e as createCloudflareClientWithToken};
@@ -1,2 +0,0 @@
1
- #!/usr/bin/env node
2
- import{r as e}from"./theme-CQ_TYifs.mjs";import{a as t,n,r}from"./banner-D03JEqRs.mjs";import"./ui-YmjF66Ct.mjs";import{c as i,d as a,i as o,p as s,r as c,t as l,u}from"./oauth-Bj5Ne1o8.mjs";import{t as d}from"./auth-token-pNQrX_9O.mjs";import{t as f}from"./output-BOe-3AQG.mjs";import{n as p}from"./run-BvHwWWUX.mjs";import"./telemetry-BsYO3nxG.mjs";import{a as m,c as h,i as g,n as _,o as v,r as y,s as b,t as x}from"./login-BGF_I_LT.mjs";const S={command:`logout`,describe:`Log out and remove stored credentials`,handler:async a=>{g(a,`logout`,"Run `cf auth delete <name>` to remove a named profile.");let l=c();l!=="default"&&console.log(t(`This directory has profile "${l}" active. \`cf auth logout\` removes the default profile's token, not "${l}".\nTo delete "${l}", run \`cf auth delete ${l}\`.`)),s(`default`);let d=i(),f=!!process.env.CLOUDFLARE_API_TOKEN;if(!d){f?(console.log(r(`No cf OAuth credentials found, but CLOUDFLARE_API_TOKEN environment variable is set.`)),console.log(r(`Unset it with: unset CLOUDFLARE_API_TOKEN`))):(console.log(r(`You are not currently logged in.`)),console.log(n(`Run ${e.code(`cf auth login`)} to authenticate.`)));return}console.log(r(`Logging out...`)),await u(`default`),console.log(`${e.info(`Removed:`)} OAuth tokens from ${e.muted(o())}`),f&&(console.log(``),console.log(t(`CLOUDFLARE_API_TOKEN environment variable is still set.`)),console.log(r(`You will remain authenticated via the env var. Unset it with: unset CLOUDFLARE_API_TOKEN`)))}},C={command:`whoami`,describe:`Show current user and authentication status`,builder:e=>e,handler:async e=>{let t=process.env.CLOUDFLARE_API_TOKEN,n=a(),r;r=t?`CLOUDFLARE_API_TOKEN environment variable`:n?.oauth_token?`OAuth token from ${o()}`:`none`;let i;try{i=await d()}catch{f({authenticated:!1,error:`Not logged in`});return}let{createCloudflareClientWithToken:s}=await import(`./auth-CrmVwfpJ.mjs`),c=s({apiToken:i}),u,p=[],[m,h]=await Promise.allSettled([c.user.get(),l()]);if(m.status===`fulfilled`){let e=m.value;e&&`email`in e&&typeof e.email==`string`&&(u=e.email)}else process.env.DEBUG&&console.error(`User lookup error:`,m.reason);h.status===`fulfilled`?p=h.value:process.env.DEBUG&&console.error(`Account lookup error:`,h.reason);let g=m.status===`fulfilled`||h.status===`fulfilled`,_={authenticated:!0,authSource:r,tokenValid:g,...u&&{email:u},accounts:p};n?.oauth_token&&(_.scopes=n.scopes,_.expiresAt=n.expiration_time),f(_)}},w={command:`auth`,describe:`Manage authentication and profiles`,builder:e=>e.command(p(x,{command:`auth login`,classification:_})).command(T(S,`auth logout`)).command(T(C,`auth whoami`)).command(T(m,`auth create`,[`browser`,`device`])).command(T(b,`auth delete`)).command(T(y,`auth activate`)).command(T(v,`auth deactivate`)).command(T(h,`auth list`)).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function T(e,t,n=[],r){return p(e,{command:t,classification:{safeFlags:n,shortFlagAliases:r}})}export{w as default};
@@ -1,2 +0,0 @@
1
- #!/usr/bin/env node
2
- import{n as e,r as t}from"./theme-CQ_TYifs.mjs";import"./delegate-Tgfxa-MZ.mjs";import{stripVTControlCharacters as n}from"node:util";function r(n){return`${t.success(e.success)} ${n}`}function i(n){return`${t.warning(e.warning)} ${n}`}function a(n){return`${t.info(e.info)} ${n}`}function o(n){return`${t.muted(e.arrow)} ${t.muted(n)}`}function s(e,r){let a=process.env.CF_DELEGATION?` ${t.muted(`·`)} ${t.muted(`delegated`)}`:``,o=r?` ${t.muted(`·`)} ${t.warning(`update available: v${r.latestVersion}`)}`:``,s=`🍊☁️ ${t.brand(t.bold(`cf`))} ${t.muted(`·`)} ${t.muted(`v${e}`)}${a}${o}`,c=n(s).length,l=`─`.repeat(c);return`${s}\n${t.brand(l)}${r?.isMajor?`\n${i(`A new major version of cf is available. Updating is recommended.`)}`:``}`}export{i as a,r as i,o as n,a as r,s as t};
@@ -1,46 +0,0 @@
1
- #!/usr/bin/env node
2
- import{t as e}from"./local-DlT72Xpn.mjs";import{n as t}from"./auth-CGLsxbc6.mjs";import{a as n,t as r}from"./context-q7UaYK69.mjs";import{t as i}from"./output-BOe-3AQG.mjs";import{t as a}from"./dry-run-DRj2_uV3.mjs";import{t as o}from"./progress-BtkTVcHI.mjs";import{t as s}from"./run-BvHwWWUX.mjs";import"./telemetry-BsYO3nxG.mjs";import{n as c,t as l}from"./body-parser-DkHKPkJ7.mjs";import{n as u}from"./input-validation-D7z60HJH.mjs";import{a as d,n as f}from"./prompt-RlgRrmbm.mjs";import{t as p}from"./cli-types-9oYmRTHJ.mjs";function m(e){return e.usage(`$0 basin-catalog credentials create <bucket-name>
3
-
4
- Store authentication credentials for a catalog. These credentials are used to authenticate with R2 storage when performing catalog operations.`).positional(`bucket-name`,{type:`string`,description:`Specifies the R2 bucket name.`,demandOption:!0}).option(`token`,{type:`string`,description:`Provides the Cloudflare API token for accessing R2.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Contains request to store catalog credentials.`})}const h={command:`create <bucket-name>`,describe:`Store catalog credentials`,builder:m,handler:async f=>s({command:`basin-catalog credentials create`,classification:{safeFlags:[`dry-run`]}},f,async()=>{if(f.dryRun){let e=await n();a({command:`cf basin-catalog credentials create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/basin-catalog/${f[`bucket-name`]==null?`<bucket-name>`:encodeURIComponent(String(f[`bucket-name`]))}/credential`,pathParams:{"bucket-name":String(f[`bucket-name`]??``)},bodyKind:`json`,body:f.body===void 0?l({token:u(f.token,`token`,`text`)}):c(f.body)});return}let s=await t(f),p=f.local?e:await r();if(f.accountId=p,f.body){let e=c(f.body),t=await o(`Creating`,async()=>s.basinCatalog.credentials.create({body:e,account_id:p,bucket_name:f[`bucket-name`]}));i(t,{successLabel:`Created`});return}f.token===void 0&&(f.token=await d(`token`,`Provides the Cloudflare API token for accessing R2.`));let m=l({token:u(f.token,`token`,`text`)}),h=await o(`Creating`,async()=>s.basinCatalog.credentials.create({body:m,account_id:p,bucket_name:f[`bucket-name`]}));i(h,{successLabel:`Created`})})};function g(e){return e.usage(`$0 basin-catalog credentials status <bucket-name>
5
-
6
- Check whether the configured catalog credentials are valid, invalid, or absent by probing authentication against the catalog.`).positional(`bucket-name`,{type:`string`,description:`Specifies the R2 bucket name.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const _={command:`status <bucket-name>`,describe:`Get Basin Catalog credential status`,builder:g,handler:async c=>s({command:`basin-catalog credentials status`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){let e=await n();a({command:`cf basin-catalog credentials status`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/basin-catalog/${c[`bucket-name`]==null?`<bucket-name>`:encodeURIComponent(String(c[`bucket-name`]))}/credential/status`,pathParams:{"bucket-name":String(c[`bucket-name`]??``)},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();c.accountId=l;let u=await o(`Loading`,async()=>s.basinCatalog.credentials.status({account_id:l,bucket_name:c[`bucket-name`]}));i(u,{successLabel:`Loaded`})})},v={command:`credentials`,describe:`Catalog access credentials for external query engines (Spark, Trino, etc.)`,builder:e=>e.command(h).command(_).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function y(e){return e.usage(`$0 basin-catalog delete <bucket-name>
7
-
8
- Removes the catalog from the control plane without deleting R2 bucket objects. Set force=true to remove catalog namespaces, tables, views, and maintenance metadata. Force deletion is limited to a configured catalog object count.`).positional(`bucket-name`,{type:`string`,description:`Specifies the R2 bucket name.`,demandOption:!0}).option(`cascade`,{type:`boolean`,description:`Remove child metadata before deleting the catalog.`}).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 b={command:`delete <bucket-name>`,describe:`Delete Basin Catalog metadata`,builder:y,handler:async c=>s({command:`basin-catalog delete`,classification:{safeFlags:[`cascade`,`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},c,async()=>{let s={force:c.cascade};if(c.dryRun){let e=await n();a({command:`cf basin-catalog delete`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/basin-catalog/${c[`bucket-name`]==null?`<bucket-name>`:encodeURIComponent(String(c[`bucket-name`]))}/delete`,pathParams:{"bucket-name":String(c[`bucket-name`]??``)},query:s,bodyKind:`none`});return}let l=await t(c),u=c.local?e:await r();if(c.accountId=u,!await f({force:!!c.force,message:`This removes catalog metadata. R2 bucket objects are retained.`})){process.stderr.write(`Aborted.
9
- `);return}let d=await o(`Deleting`,async()=>l.basinCatalog.delete({account_id:u,bucket_name:c[`bucket-name`],...s}));i(d,{successLabel:`Deleted`})})};function x(e){return e.usage(`$0 basin-catalog disable <bucket-name>
10
-
11
- Disable an R2 bucket as a catalog. This operation deactivates the catalog but preserves existing metadata and data files. The catalog can be re-enabled later.`).positional(`bucket-name`,{type:`string`,description:`Specifies the R2 bucket name to disable as catalog.`,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 S={command:`disable <bucket-name>`,describe:`Disable Basin Catalog`,builder:x,handler:async c=>s({command:`basin-catalog disable`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},c,async()=>{if(c.dryRun){let e=await n();a({command:`cf basin-catalog disable`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/basin-catalog/${c[`bucket-name`]==null?`<bucket-name>`:encodeURIComponent(String(c[`bucket-name`]))}/disable`,pathParams:{"bucket-name":String(c[`bucket-name`]??``)},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();if(c.accountId=l,!await f({force:!!c.force,message:`This operation turns off the data catalog for the bucket. Existing namespace or table state remains, but writes stop.`})){process.stderr.write(`Aborted.
12
- `);return}let u=await o(`Deleting`,async()=>s.basinCatalog.disable({account_id:l,bucket_name:c[`bucket-name`]}));i(u,{successLabel:`Deleted`})})};function C(e){return e.usage(`$0 basin-catalog enable <bucket-name>
13
-
14
- Enable an R2 bucket as an Apache Iceberg catalog. This operation creates the necessary catalog infrastructure and activates the bucket for storing Iceberg metadata and data files.`).positional(`bucket-name`,{type:`string`,description:`Specifies the R2 bucket name to enable as catalog.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const w={command:`enable <bucket-name>`,describe:`Enable R2 bucket as a catalog`,builder:C,handler:async c=>s({command:`basin-catalog enable`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){let e=await n();a({command:`cf basin-catalog enable`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/basin-catalog/${c[`bucket-name`]==null?`<bucket-name>`:encodeURIComponent(String(c[`bucket-name`]))}/enable`,pathParams:{"bucket-name":String(c[`bucket-name`]??``)},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();c.accountId=l;let u=await o(`Creating`,async()=>s.basinCatalog.enable({account_id:l,bucket_name:c[`bucket-name`]}));i(u,{successLabel:`Created`})})};function T(e){return e.usage(`$0 basin-catalog get <bucket-name>
15
-
16
- Retrieve detailed information about a specific Basin Catalog by bucket name. Returns catalog status, maintenance configuration, and credential status.`).positional(`bucket-name`,{type:`string`,description:`Specifies the R2 bucket name.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const E={command:`get <bucket-name>`,describe:`Get Basin Catalog details`,builder:T,handler:async c=>s({command:`basin-catalog get`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){let e=await n();a({command:`cf basin-catalog get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/basin-catalog/${c[`bucket-name`]==null?`<bucket-name>`:encodeURIComponent(String(c[`bucket-name`]))}`,pathParams:{"bucket-name":String(c[`bucket-name`]??``)},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();c.accountId=l;let u=await o(`Loading`,async()=>s.basinCatalog.get({account_id:l,bucket_name:c[`bucket-name`]}));i(u,{successLabel:`Loaded`})})};function D(e){return e.usage(`$0 basin-catalog list
17
-
18
- Returns a list of R2 buckets that have been enabled as Apache Iceberg catalogs for the specified account. Each catalog represents an R2 bucket configured to store Iceberg metadata and data files.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const O={command:`list`,describe:`List Basin Catalogs`,builder:D,handler:async c=>s({command:`basin-catalog list`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){let e=await n();a({command:`cf basin-catalog list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/basin-catalog`,pathParams:{},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();c.accountId=l;let u=await o(`Loading`,async()=>s.basinCatalog.list({account_id:l}));i(u,{successLabel:`Loaded`})})};function k(e){return e.usage(`$0 basin-catalog maintenance-configs get <bucket-name>
19
-
20
- Retrieve the maintenance configuration for a specific catalog, including compaction settings and credential status.`).positional(`bucket-name`,{type:`string`,description:`Specifies the R2 bucket name.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const A={command:`get <bucket-name>`,describe:`Get catalog maintenance configuration`,builder:k,handler:async c=>s({command:`basin-catalog maintenance-configs get`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){let e=await n();a({command:`cf basin-catalog maintenance-configs get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/basin-catalog/${c[`bucket-name`]==null?`<bucket-name>`:encodeURIComponent(String(c[`bucket-name`]))}/maintenance-configs`,pathParams:{"bucket-name":String(c[`bucket-name`]??``)},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();c.accountId=l;let u=await o(`Loading`,async()=>s.basinCatalog.maintenanceConfigs.get({account_id:l,bucket_name:c[`bucket-name`]}));i(u,{successLabel:`Loaded`})})};function j(e){return e.usage(`$0 basin-catalog maintenance-configs update <bucket-name>
21
-
22
- Update the maintenance configuration for a catalog. This allows you to enable or disable compaction and adjust target file sizes for optimization.`).positional(`bucket-name`,{type:`string`,description:`Specifies the R2 bucket name.`,demandOption:!0}).option(`compaction-state`,{type:`string`,description:`Specifies the state of maintenance operations.`,choices:[`enabled`,`disabled`]}).option(`compaction-target-size-mb`,{type:`string`,description:`Sets the target file size for compaction in megabytes. Defaults to "128".`,choices:[`64`,`128`,`256`,`512`]}).option(`snapshot-expiration-max-snapshot-age`,{type:`string`,description:`Updates the maximum age for snapshots optionally.`}).option(`snapshot-expiration-min-snapshots-to-keep`,{type:`number`,description:`Updates the minimum number of snapshots to retain optionally.`}).option(`snapshot-expiration-state`,{type:`string`,description:`Specifies the state of maintenance operations.`,choices:[`enabled`,`disabled`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Contains request to update catalog maintenance configuration.`})}const M={command:`update <bucket-name>`,describe:`Update catalog maintenance configuration`,builder:j,handler:async d=>s({command:`basin-catalog maintenance-configs update`,classification:{safeFlags:[`compaction-state`,`compaction-target-size-mb`,`snapshot-expiration-state`,`dry-run`]}},d,async()=>{if(d.dryRun){let e=await n();a({command:`cf basin-catalog maintenance-configs update`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/basin-catalog/${d[`bucket-name`]==null?`<bucket-name>`:encodeURIComponent(String(d[`bucket-name`]))}/maintenance-configs`,pathParams:{"bucket-name":String(d[`bucket-name`]??``)},bodyKind:`json`,body:d.body===void 0?l({compaction:{state:u(d[`compaction-state`],`compaction-state`,`text`),target_size_mb:u(d[`compaction-target-size-mb`],`compaction-target-size-mb`,`text`)},snapshot_expiration:{max_snapshot_age:u(d[`snapshot-expiration-max-snapshot-age`],`snapshot-expiration-max-snapshot-age`,`text`),min_snapshots_to_keep:d[`snapshot-expiration-min-snapshots-to-keep`],state:u(d[`snapshot-expiration-state`],`snapshot-expiration-state`,`text`)}}):c(d.body)});return}let s=await t(d),f=d.local?e:await r();if(d.accountId=f,d.body){let e=c(d.body),t=await o(`Creating`,async()=>s.basinCatalog.maintenanceConfigs.update({body:e,account_id:f,bucket_name:d[`bucket-name`]}));i(t,{successLabel:`Created`});return}let p=l({compaction:{state:u(d[`compaction-state`],`compaction-state`,`text`),target_size_mb:u(d[`compaction-target-size-mb`],`compaction-target-size-mb`,`text`)},snapshot_expiration:{max_snapshot_age:u(d[`snapshot-expiration-max-snapshot-age`],`snapshot-expiration-max-snapshot-age`,`text`),min_snapshots_to_keep:d[`snapshot-expiration-min-snapshots-to-keep`],state:u(d[`snapshot-expiration-state`],`snapshot-expiration-state`,`text`)}}),m=await o(`Creating`,async()=>s.basinCatalog.maintenanceConfigs.update({body:p,account_id:f,bucket_name:d[`bucket-name`]}));i(m,{successLabel:`Created`})})},N={command:`maintenance-configs`,describe:`Table maintenance settings — compaction schedules and snapshot expiration policies`,builder:e=>e.command(A).command(M).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function P(e){return e.usage(`$0 basin-catalog namespaces list
23
-
24
- Returns a list of namespaces in the specified Basin Catalog. Supports hierarchical filtering and pagination for efficient traversal of large namespace hierarchies.`).option(`bucket-name`,{type:`string`,description:`Specifies the R2 bucket name.`,demandOption:!0}).option(`page-token`,{type:`string`,description:`Opaque pagination token from a previous response.
25
- Use this to fetch the next page of results.`}).option(`page-size`,{type:`number`,description:`Maximum number of namespaces to return per page.
26
- Defaults to 100, maximum 1000.`}).option(`parent`,{type:`string`,description:`Parent namespace to filter by. Only returns direct children of this namespace.
27
- For nested namespaces, use %1F as separator (e.g., "bronze%1Fanalytics").
28
- Omit this parameter to list top-level namespaces.`}).option(`return-uuids`,{type:`boolean`,description:`Whether to include namespace UUIDs in the response.
29
- Set to true to receive the namespace_uuids array.`}).option(`return-details`,{type:`boolean`,description:`Whether to include additional metadata (timestamps).
30
- When true, response includes created_at and updated_at arrays.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const F={command:`list`,describe:`List namespaces in catalog`,builder:P,handler:async c=>s({command:`basin-catalog namespaces list`,classification:{safeFlags:[`return-uuids`,`return-details`,`dry-run`]}},c,async()=>{let s={page_token:c[`page-token`],page_size:c[`page-size`],parent:c.parent,return_uuids:c[`return-uuids`],return_details:c[`return-details`]};if(c.dryRun){let e=await n();a({command:`cf basin-catalog namespaces list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/basin-catalog/${c[`bucket-name`]==null?`<bucket-name>`:encodeURIComponent(String(c[`bucket-name`]))}/namespaces`,pathParams:{"bucket-name":String(c[`bucket-name`]??``)},query:s,bodyKind:`none`});return}let l=await t(c),u=c.local?e:await r();c.accountId=u;let d=await o(`Loading`,async()=>l.basinCatalog.namespaces.list({account_id:u,bucket_name:c[`bucket-name`],...s}));i(d,{successLabel:`Loaded`})})};function I(e){return e.usage("$0 basin-catalog namespaces tables get <table-name>\n\nReturns full Apache Iceberg metadata for a single table: schema, partition specs, sort orders, properties, and recent snapshot history. Designed for catalog introspection UIs that need per-table details without holding R2 credentials. The `metadata.snapshots`, `metadata.snapshot-log`, and `metadata.metadata-log` arrays are pruned to the most recent 10 entries by `timestamp-ms`. Use `total_snapshots` and `returned_snapshots` to surface the truncation to end users.").positional(`table-name`,{type:`string`,description:`The table name within the given namespace.`,demandOption:!0}).option(`bucket-name`,{type:`string`,description:`Specifies the R2 bucket name.`,demandOption:!0}).option(`namespace`,{type:`string`,description:`The namespace identifier.
31
- For nested namespaces, use %1F as separator (e.g., "bronze%1Fanalytics").`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const L={command:`get <table-name>`,describe:`Get table details`,builder:I,handler:async c=>s({command:`basin-catalog namespaces tables get`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){let e=await n();a({command:`cf basin-catalog namespaces tables get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/basin-catalog/${c[`bucket-name`]==null?`<bucket-name>`:encodeURIComponent(String(c[`bucket-name`]))}/namespaces/${c.namespace==null?`<namespace>`:encodeURIComponent(String(c.namespace))}/tables/${c[`table-name`]==null?`<table-name>`:encodeURIComponent(String(c[`table-name`]))}`,pathParams:{"bucket-name":String(c[`bucket-name`]??``),namespace:String(c.namespace??``),"table-name":String(c[`table-name`]??``)},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();c.accountId=l;let u=await o(`Loading`,async()=>s.basinCatalog.namespaces.tables.get({account_id:l,bucket_name:c[`bucket-name`],namespace:c.namespace,table_name:c[`table-name`]}));i(u,{successLabel:`Loaded`})})};function R(e){return e.usage(`$0 basin-catalog namespaces tables list
32
-
33
- Returns a list of tables in the specified namespace within a Basin Catalog. Supports pagination for efficient traversal of large table collections.`).option(`bucket-name`,{type:`string`,description:`Specifies the R2 bucket name.`,demandOption:!0}).option(`namespace`,{type:`string`,description:`The namespace identifier.
34
- For nested namespaces, use %1F as separator (e.g., "bronze%1Fanalytics").`,demandOption:!0}).option(`page-token`,{type:`string`,description:`Opaque pagination token from a previous response.
35
- Use this to fetch the next page of results.`}).option(`page-size`,{type:`number`,description:`Maximum number of tables to return per page.
36
- Defaults to 100, maximum 1000.`}).option(`return-uuids`,{type:`boolean`,description:`Whether to include table UUIDs in the response.
37
- Set to true to receive the table_uuids array.`}).option(`return-details`,{type:`boolean`,description:`Whether to include additional metadata (timestamps, locations).
38
- When true, response includes created_at, updated_at, metadata_locations, and locations arrays.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const z={command:`list`,describe:`List tables in namespace`,builder:R,handler:async c=>s({command:`basin-catalog namespaces tables list`,classification:{safeFlags:[`return-uuids`,`return-details`,`dry-run`]}},c,async()=>{let s={page_token:c[`page-token`],page_size:c[`page-size`],return_uuids:c[`return-uuids`],return_details:c[`return-details`]};if(c.dryRun){let e=await n();a({command:`cf basin-catalog namespaces tables list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/basin-catalog/${c[`bucket-name`]==null?`<bucket-name>`:encodeURIComponent(String(c[`bucket-name`]))}/namespaces/${c.namespace==null?`<namespace>`:encodeURIComponent(String(c.namespace))}/tables`,pathParams:{"bucket-name":String(c[`bucket-name`]??``),namespace:String(c.namespace??``)},query:s,bodyKind:`none`});return}let l=await t(c),u=c.local?e:await r();c.accountId=u;let d=await o(`Loading`,async()=>l.basinCatalog.namespaces.tables.list({account_id:u,bucket_name:c[`bucket-name`],namespace:c.namespace,...s}));i(d,{successLabel:`Loaded`})})};function B(e){return e.usage(`$0 basin-catalog namespaces tables maintenance-configs get <table-name>
39
-
40
- Retrieve the maintenance configuration for a specific table, including compaction settings.`).positional(`table-name`,{type:`string`,description:`The table name.`,demandOption:!0}).option(`bucket-name`,{type:`string`,description:`Specifies the R2 bucket name.`,demandOption:!0}).option(`namespace`,{type:`string`,description:`The namespace identifier (use %1F as separator for nested namespaces).`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const V={command:`get <table-name>`,describe:`Get table maintenance configuration`,builder:B,handler:async c=>s({command:`basin-catalog namespaces tables maintenance-configs get`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){let e=await n();a({command:`cf basin-catalog namespaces tables maintenance-configs get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/basin-catalog/${c[`bucket-name`]==null?`<bucket-name>`:encodeURIComponent(String(c[`bucket-name`]))}/namespaces/${c.namespace==null?`<namespace>`:encodeURIComponent(String(c.namespace))}/tables/${c[`table-name`]==null?`<table-name>`:encodeURIComponent(String(c[`table-name`]))}/maintenance-configs`,pathParams:{"bucket-name":String(c[`bucket-name`]??``),namespace:String(c.namespace??``),"table-name":String(c[`table-name`]??``)},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();c.accountId=l;let u=await o(`Loading`,async()=>s.basinCatalog.namespaces.tables.maintenanceConfigs.get({account_id:l,bucket_name:c[`bucket-name`],namespace:c.namespace,table_name:c[`table-name`]}));i(u,{successLabel:`Loaded`})})};function H(e){return e.usage(`$0 basin-catalog namespaces tables maintenance-configs queue <configuration-type>
41
-
42
- Queue maintenance for normal polling. This request does not start a run.`).positional(`configuration-type`,{type:`string`,description:`Configuration type`,demandOption:!0}).option(`bucket-name`,{type:`string`,description:`Specifies the R2 bucket name.`,demandOption:!0}).option(`namespace`,{type:`string`,description:`Namespace`,demandOption:!0}).option(`table-name`,{type:`string`,description:`Table name`,demandOption:!0}).option(`request-id`,{type:`string`,description:`The request_id field`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const U={command:`queue <configuration-type>`,describe:`Queue table maintenance`,builder:p(H),handler:async d=>s({command:`basin-catalog namespaces tables maintenance-configs queue`,classification:{safeFlags:[`dry-run`]}},d,async()=>{if(d.dryRun){let e=await n();a({command:`cf basin-catalog namespaces tables maintenance-configs queue`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/basin-catalog/${d[`bucket-name`]==null?`<bucket-name>`:encodeURIComponent(String(d[`bucket-name`]))}/namespaces/${d.namespace==null?`<namespace>`:encodeURIComponent(String(d.namespace))}/tables/${d[`table-name`]==null?`<table-name>`:encodeURIComponent(String(d[`table-name`]))}/maintenance-configs/${d[`configuration-type`]==null?`<configuration-type>`:encodeURIComponent(String(d[`configuration-type`]))}/queue`,pathParams:{"bucket-name":String(d[`bucket-name`]??``),namespace:String(d.namespace??``),"table-name":String(d[`table-name`]??``),"configuration-type":String(d[`configuration-type`]??``)},bodyKind:`json`,body:d.body===void 0?l({request_id:u(d[`request-id`],`request-id`,`text`)}):c(d.body)});return}let s=await t(d),f=d.local?e:await r();if(d.accountId=f,d.body){let e=c(d.body),t=await o(`Creating`,async()=>s.basinCatalog.namespaces.tables.maintenanceConfigs.queue({body:e,account_id:f,bucket_name:d[`bucket-name`],namespace:d.namespace,table_name:d[`table-name`],configuration_type:d[`configuration-type`]}));i(t,{successLabel:`Created`});return}let p=l({request_id:u(d[`request-id`],`request-id`,`text`)}),m=await o(`Creating`,async()=>s.basinCatalog.namespaces.tables.maintenanceConfigs.queue({body:p,account_id:f,bucket_name:d[`bucket-name`],namespace:d.namespace,table_name:d[`table-name`],configuration_type:d[`configuration-type`]}));i(m,{successLabel:`Created`})})};function W(e){return e.usage(`$0 basin-catalog namespaces tables maintenance-configs update <table-name>
43
-
44
- Update the maintenance configuration for a specific table. This allows you to enable or disable compaction and adjust target file sizes for optimization.`).positional(`table-name`,{type:`string`,description:`The table name.`,demandOption:!0}).option(`bucket-name`,{type:`string`,description:`Specifies the R2 bucket name.`,demandOption:!0}).option(`namespace`,{type:`string`,description:`The namespace identifier (use %1F as separator for nested namespaces).`,demandOption:!0}).option(`compaction-state`,{type:`string`,description:`Specifies the state of maintenance operations.`,choices:[`enabled`,`disabled`]}).option(`compaction-target-size-mb`,{type:`string`,description:`Sets the target file size for compaction in megabytes. Defaults to "128".`,choices:[`64`,`128`,`256`,`512`]}).option(`snapshot-expiration-max-snapshot-age`,{type:`string`,description:`Updates the maximum age for snapshots optionally.`}).option(`snapshot-expiration-min-snapshots-to-keep`,{type:`number`,description:`Updates the minimum number of snapshots to retain optionally.`}).option(`snapshot-expiration-state`,{type:`string`,description:`Specifies the state of maintenance operations.`,choices:[`enabled`,`disabled`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Contains request to update table maintenance configuration.`})}const G={command:`update <table-name>`,describe:`Update table maintenance configuration`,builder:W,handler:async d=>s({command:`basin-catalog namespaces tables maintenance-configs update`,classification:{safeFlags:[`compaction-state`,`compaction-target-size-mb`,`snapshot-expiration-state`,`dry-run`]}},d,async()=>{if(d.dryRun){let e=await n();a({command:`cf basin-catalog namespaces tables maintenance-configs update`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/basin-catalog/${d[`bucket-name`]==null?`<bucket-name>`:encodeURIComponent(String(d[`bucket-name`]))}/namespaces/${d.namespace==null?`<namespace>`:encodeURIComponent(String(d.namespace))}/tables/${d[`table-name`]==null?`<table-name>`:encodeURIComponent(String(d[`table-name`]))}/maintenance-configs`,pathParams:{"bucket-name":String(d[`bucket-name`]??``),namespace:String(d.namespace??``),"table-name":String(d[`table-name`]??``)},bodyKind:`json`,body:d.body===void 0?l({compaction:{state:u(d[`compaction-state`],`compaction-state`,`text`),target_size_mb:u(d[`compaction-target-size-mb`],`compaction-target-size-mb`,`text`)},snapshot_expiration:{max_snapshot_age:u(d[`snapshot-expiration-max-snapshot-age`],`snapshot-expiration-max-snapshot-age`,`text`),min_snapshots_to_keep:d[`snapshot-expiration-min-snapshots-to-keep`],state:u(d[`snapshot-expiration-state`],`snapshot-expiration-state`,`text`)}}):c(d.body)});return}let s=await t(d),f=d.local?e:await r();if(d.accountId=f,d.body){let e=c(d.body),t=await o(`Creating`,async()=>s.basinCatalog.namespaces.tables.maintenanceConfigs.update({body:e,account_id:f,bucket_name:d[`bucket-name`],namespace:d.namespace,table_name:d[`table-name`]}));i(t,{successLabel:`Created`});return}let p=l({compaction:{state:u(d[`compaction-state`],`compaction-state`,`text`),target_size_mb:u(d[`compaction-target-size-mb`],`compaction-target-size-mb`,`text`)},snapshot_expiration:{max_snapshot_age:u(d[`snapshot-expiration-max-snapshot-age`],`snapshot-expiration-max-snapshot-age`,`text`),min_snapshots_to_keep:d[`snapshot-expiration-min-snapshots-to-keep`],state:u(d[`snapshot-expiration-state`],`snapshot-expiration-state`,`text`)}}),m=await o(`Creating`,async()=>s.basinCatalog.namespaces.tables.maintenanceConfigs.update({body:p,account_id:f,bucket_name:d[`bucket-name`],namespace:d.namespace,table_name:d[`table-name`]}));i(m,{successLabel:`Created`})})},K={command:`maintenance-configs`,describe:`Table-level maintenance configurations and operations`,builder:e=>e.command(V).command(U).command(G).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function q(e){return e.usage(`$0 basin-catalog namespaces tables maintenance-runs list
45
-
46
- Retrieves recent table maintenance runs for the current table.`).option(`bucket-name`,{type:`string`,description:`Specifies the R2 bucket name.`,demandOption:!0}).option(`namespace`,{type:`string`,description:`Namespace`,demandOption:!0}).option(`table-name`,{type:`string`,description:`Table name`,demandOption:!0}).option(`page-size`,{type:`number`,description:`Page size`}).option(`page-token`,{type:`string`,description:`Page token`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const J={command:`list`,describe:`List table maintenance runs`,builder:q,handler:async c=>s({command:`basin-catalog namespaces tables maintenance-runs list`,classification:{safeFlags:[`dry-run`]}},c,async()=>{let s={page_size:c[`page-size`],page_token:c[`page-token`]};if(c.dryRun){let e=await n();a({command:`cf basin-catalog namespaces tables maintenance-runs list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/basin-catalog/${c[`bucket-name`]==null?`<bucket-name>`:encodeURIComponent(String(c[`bucket-name`]))}/namespaces/${c.namespace==null?`<namespace>`:encodeURIComponent(String(c.namespace))}/tables/${c[`table-name`]==null?`<table-name>`:encodeURIComponent(String(c[`table-name`]))}/maintenance-runs`,pathParams:{"bucket-name":String(c[`bucket-name`]??``),namespace:String(c.namespace??``),"table-name":String(c[`table-name`]??``)},query:s,bodyKind:`none`});return}let l=await t(c),u=c.local?e:await r();c.accountId=u;let d=await o(`Loading`,async()=>l.basinCatalog.namespaces.tables.maintenanceRuns.list({account_id:u,bucket_name:c[`bucket-name`],namespace:c.namespace,table_name:c[`table-name`],...s}));i(d,{successLabel:`Loaded`})})},Y={command:`maintenance-runs`,describe:`History of maintenance runs performed on tables`,builder:e=>e.command(J).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},X={command:`tables`,describe:`Tables within catalog namespaces`,builder:e=>e.command(L).command(z).command(K).command(Y).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},Z={command:`namespaces`,describe:`Logical namespaces that group related tables within the data catalog`,builder:e=>e.command(F).command(X).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},Q={command:`basin-catalog`,describe:`Iceberg-compatible data catalog for R2 — organize objects into tables and namespaces for SQL query engines`,builder:e=>e.command(b).command(S).command(w).command(E).command(O).command(v).command(N).command(Z).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{Q as default};
@@ -1,23 +0,0 @@
1
- #!/usr/bin/env node
2
- import{t as e}from"./local-DlT72Xpn.mjs";import{n as t}from"./auth-CGLsxbc6.mjs";import{a as n,t as r}from"./context-q7UaYK69.mjs";import{t as i}from"./output-BOe-3AQG.mjs";import{t as a}from"./dry-run-DRj2_uV3.mjs";import{t as o}from"./progress-BtkTVcHI.mjs";import{t as s}from"./run-BvHwWWUX.mjs";import"./telemetry-BsYO3nxG.mjs";import{n as c,r as l,t as u}from"./body-parser-DkHKPkJ7.mjs";import{n as d}from"./input-validation-D7z60HJH.mjs";import{n as f}from"./prompt-RlgRrmbm.mjs";function p(e){return e.usage(`$0 billing addresses validate
3
-
4
- Validates a billing address and returns validated address suggestions. Authentication is not enforced to support pre-signup address validation flows, so credentials are accepted but not required.`).option(`address`,{type:`string`,description:`Address line 1.`}).option(`address2`,{type:`string`,description:`Address line 2.`}).option(`city`,{type:`string`,description:`City.`}).option(`country`,{type:`string`,description:`Country code.`}).option(`state`,{type:`string`,description:`State or province.`}).option(`zipcode`,{type:`string`,description:`Postal or zip code.`}).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 m={command:`validate`,describe:`Validate Billing Address`,builder:p,handler:async e=>s({command:`billing addresses validate`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf billing addresses validate`,method:`POST`,url:`https://api.cloudflare.com/client/v4/billing/address-validation`,pathParams:{},bodyKind:`json`,body:e.body===void 0?u({address:d(e.address,`address`,`text`),address2:d(e.address2,`address2`,`text`),city:d(e.city,`city`,`text`),country:d(e.country,`country`,`text`),state:d(e.state,`state`,`text`),zipcode:d(e.zipcode,`zipcode`,`text`)}):c(e.body)});return}let n=await t(e);if(e.body){let t=c(e.body),r=await o(`Creating`,async()=>n.billing.addresses.validate({...t}));i(r,{successLabel:`Created`});return}let r=u({address:d(e.address,`address`,`text`),address2:d(e.address2,`address2`,`text`),city:d(e.city,`city`,`text`),country:d(e.country,`country`,`text`),state:d(e.state,`state`,`text`),zipcode:d(e.zipcode,`zipcode`,`text`)}),s=await o(`Creating`,async()=>n.billing.addresses.validate({...r}));i(s,{successLabel:`Created`})})},h={command:`addresses`,describe:`Operations for addresses`,builder:e=>e.command(m).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function g(e){return e.usage(`$0 billing profiles create
5
-
6
- Creates a billing profile for an account.`).option(`address`,{type:`string`,description:`Street address line 1.`}).option(`address2`,{type:`string`,description:`Street address line 2 (apt, suite, etc.).`}).option(`billing-email`,{type:`string`,description:`Primary billing email address.`}).option(`buying-rate-plan`,{type:`string`,description:`Rate plan being purchased right after profile setup.`}).option(`captcha-challenge-jwt`,{type:`string`,description:`Captcha challenge JWT issued during onboarding.`}).option(`cf-turnstile-response`,{type:`string`,description:`Cloudflare Turnstile response.`}).option(`city`,{type:`string`,description:`City on the billing profile.`}).option(`company`,{type:`string`,description:`Company name on the billing profile.`}).option(`country`,{type:`string`,description:`ISO 3166-1 alpha-2 country code.`}).option(`first-name`,{type:`string`,description:`First name on the billing profile.`}).option(`h-captcha-response`,{type:`string`,description:`hCaptcha response.`}).option(`last-name`,{type:`string`,description:`Last name on the billing profile.`}).option(`preferred-locale`,{type:`string`,description:`Preferred locale for invoice rendering (BCP 47).`}).option(`secondary-billing-email`,{type:`string`,description:`Secondary billing email address for CC on invoices.`}).option(`state`,{type:`string`,description:`State or region on the billing profile.`}).option(`tax-id-type`,{type:`string`,description:`Type of tax ID provided.`}).option(`telephone`,{type:`string`,description:`Contact phone number.`}).option(`vat`,{type:`string`,description:`VAT identifier.`}).option(`zipcode`,{type:`string`,description:`ZIP or postal code.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Request body for creating or updating a billing profile.`})}const _={command:`create`,describe:`Create Billing Profile`,builder:g,handler:async l=>s({command:`billing profiles create`,classification:{safeFlags:[`dry-run`]}},l,async()=>{if(l.dryRun){let e=await n();a({command:`cf billing profiles create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/billing/profile`,pathParams:{},bodyKind:`json`,body:l.body===void 0?u({address:d(l.address,`address`,`text`),address2:d(l.address2,`address2`,`text`),billing_email:d(l[`billing-email`],`billing-email`,`text`),buying_rate_plan:d(l[`buying-rate-plan`],`buying-rate-plan`,`text`),captcha_challenge_jwt:d(l[`captcha-challenge-jwt`],`captcha-challenge-jwt`,`text`),cf_turnstile_response:d(l[`cf-turnstile-response`],`cf-turnstile-response`,`text`),city:d(l.city,`city`,`text`),company:d(l.company,`company`,`text`),country:d(l.country,`country`,`text`),first_name:d(l[`first-name`],`first-name`,`text`),h_captcha_response:d(l[`h-captcha-response`],`h-captcha-response`,`text`),last_name:d(l[`last-name`],`last-name`,`text`),preferred_locale:d(l[`preferred-locale`],`preferred-locale`,`text`),secondary_billing_email:d(l[`secondary-billing-email`],`secondary-billing-email`,`text`),state:d(l.state,`state`,`text`),tax_id_type:d(l[`tax-id-type`],`tax-id-type`,`text`),telephone:d(l.telephone,`telephone`,`text`),vat:d(l.vat,`vat`,`text`),zipcode:d(l.zipcode,`zipcode`,`text`)}):c(l.body)});return}let s=await t(l),f=l.local?e:await r();if(l.accountId=f,l.body){let e=c(l.body),t=await o(`Creating`,async()=>s.billing.profiles.create({body:e,account_id:f}));i(t,{successLabel:`Created`});return}let p=u({address:d(l.address,`address`,`text`),address2:d(l.address2,`address2`,`text`),billing_email:d(l[`billing-email`],`billing-email`,`text`),buying_rate_plan:d(l[`buying-rate-plan`],`buying-rate-plan`,`text`),captcha_challenge_jwt:d(l[`captcha-challenge-jwt`],`captcha-challenge-jwt`,`text`),cf_turnstile_response:d(l[`cf-turnstile-response`],`cf-turnstile-response`,`text`),city:d(l.city,`city`,`text`),company:d(l.company,`company`,`text`),country:d(l.country,`country`,`text`),first_name:d(l[`first-name`],`first-name`,`text`),h_captcha_response:d(l[`h-captcha-response`],`h-captcha-response`,`text`),last_name:d(l[`last-name`],`last-name`,`text`),preferred_locale:d(l[`preferred-locale`],`preferred-locale`,`text`),secondary_billing_email:d(l[`secondary-billing-email`],`secondary-billing-email`,`text`),state:d(l.state,`state`,`text`),tax_id_type:d(l[`tax-id-type`],`tax-id-type`,`text`),telephone:d(l.telephone,`telephone`,`text`),vat:d(l.vat,`vat`,`text`),zipcode:d(l.zipcode,`zipcode`,`text`)}),m=await o(`Creating`,async()=>s.billing.profiles.create({body:p,account_id:f}));i(m,{successLabel:`Created`})})};function v(e){return e.usage(`$0 billing profiles createPaymentIntent
7
-
8
- Creates a Stripe payment intent for adding or updating a payment method on the account's billing profile. Returns a client secret for frontend payment method collection.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const y={command:`createPaymentIntent`,describe:`Create Payment Intent for Billing Profile`,builder:v,handler:async c=>s({command:`billing profiles createPaymentIntent`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){let e=await n();a({command:`cf billing profiles createPaymentIntent`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/billing/profile/payment-method`,pathParams:{},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();c.accountId=l;let u=await o(`Creating`,async()=>s.billing.profiles.createPaymentIntent({account_id:l}));i(u,{successLabel:`Created`})})};function b(e){return e.usage(`$0 billing profiles delete
9
-
10
- Deletes the billing profile for an account.`).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 x={command:`delete`,describe:`Delete Billing Profile`,builder:b,handler:async c=>s({command:`billing profiles delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},c,async()=>{if(c.dryRun){let e=await n();a({command:`cf billing profiles delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/billing/profile`,pathParams:{},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();if(c.accountId=l,!await f({force:!!c.force})){process.stderr.write(`Aborted.
11
- `);return}let u=await o(`Deleting`,async()=>s.billing.profiles.delete({account_id:l}));i(u,{successLabel:`Deleted`})})};function S(e){return e.usage(`$0 billing profiles get
12
-
13
- Gets the current billing profile for the account.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const C={command:`get`,describe:`Get Billing Profile`,builder:S,handler:async c=>s({command:`billing profiles get`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){let e=await n();a({command:`cf billing profiles get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/billing/profile`,pathParams:{},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();c.accountId=l;let u=await o(`Loading`,async()=>s.billing.profiles.get({account_id:l}));i(u,{successLabel:`Loaded`})})};function w(e){return e.usage(`$0 billing profiles update
14
-
15
- Updates the billing profile for an account.`).option(`address`,{type:`string`,description:`Street address line 1.`}).option(`address2`,{type:`string`,description:`Street address line 2 (apt, suite, etc.).`}).option(`billing-email`,{type:`string`,description:`Primary billing email address.`}).option(`buying-rate-plan`,{type:`string`,description:`Rate plan being purchased right after profile setup.`}).option(`captcha-challenge-jwt`,{type:`string`,description:`Captcha challenge JWT issued during onboarding.`}).option(`cf-turnstile-response`,{type:`string`,description:`Cloudflare Turnstile response.`}).option(`city`,{type:`string`,description:`City on the billing profile.`}).option(`company`,{type:`string`,description:`Company name on the billing profile.`}).option(`country`,{type:`string`,description:`ISO 3166-1 alpha-2 country code.`}).option(`first-name`,{type:`string`,description:`First name on the billing profile.`}).option(`h-captcha-response`,{type:`string`,description:`hCaptcha response.`}).option(`last-name`,{type:`string`,description:`Last name on the billing profile.`}).option(`preferred-locale`,{type:`string`,description:`Preferred locale for invoice rendering (BCP 47).`}).option(`secondary-billing-email`,{type:`string`,description:`Secondary billing email address for CC on invoices.`}).option(`state`,{type:`string`,description:`State or region on the billing profile.`}).option(`tax-id-type`,{type:`string`,description:`Type of tax ID provided.`}).option(`telephone`,{type:`string`,description:`Contact phone number.`}).option(`vat`,{type:`string`,description:`VAT identifier.`}).option(`zipcode`,{type:`string`,description:`ZIP or postal code.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Request body for creating or updating a billing profile.`})}const T={command:`update`,describe:`Update Billing Profile`,builder:w,handler:async l=>s({command:`billing profiles update`,classification:{safeFlags:[`dry-run`]}},l,async()=>{if(l.dryRun){let e=await n();a({command:`cf billing profiles update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/billing/profile`,pathParams:{},bodyKind:`json`,body:l.body===void 0?u({address:d(l.address,`address`,`text`),address2:d(l.address2,`address2`,`text`),billing_email:d(l[`billing-email`],`billing-email`,`text`),buying_rate_plan:d(l[`buying-rate-plan`],`buying-rate-plan`,`text`),captcha_challenge_jwt:d(l[`captcha-challenge-jwt`],`captcha-challenge-jwt`,`text`),cf_turnstile_response:d(l[`cf-turnstile-response`],`cf-turnstile-response`,`text`),city:d(l.city,`city`,`text`),company:d(l.company,`company`,`text`),country:d(l.country,`country`,`text`),first_name:d(l[`first-name`],`first-name`,`text`),h_captcha_response:d(l[`h-captcha-response`],`h-captcha-response`,`text`),last_name:d(l[`last-name`],`last-name`,`text`),preferred_locale:d(l[`preferred-locale`],`preferred-locale`,`text`),secondary_billing_email:d(l[`secondary-billing-email`],`secondary-billing-email`,`text`),state:d(l.state,`state`,`text`),tax_id_type:d(l[`tax-id-type`],`tax-id-type`,`text`),telephone:d(l.telephone,`telephone`,`text`),vat:d(l.vat,`vat`,`text`),zipcode:d(l.zipcode,`zipcode`,`text`)}):c(l.body)});return}let s=await t(l),f=l.local?e:await r();if(l.accountId=f,l.body){let e=c(l.body),t=await o(`Updating`,async()=>s.billing.profiles.update({body:e,account_id:f}));i(t,{successLabel:`Updated`});return}let p=u({address:d(l.address,`address`,`text`),address2:d(l.address2,`address2`,`text`),billing_email:d(l[`billing-email`],`billing-email`,`text`),buying_rate_plan:d(l[`buying-rate-plan`],`buying-rate-plan`,`text`),captcha_challenge_jwt:d(l[`captcha-challenge-jwt`],`captcha-challenge-jwt`,`text`),cf_turnstile_response:d(l[`cf-turnstile-response`],`cf-turnstile-response`,`text`),city:d(l.city,`city`,`text`),company:d(l.company,`company`,`text`),country:d(l.country,`country`,`text`),first_name:d(l[`first-name`],`first-name`,`text`),h_captcha_response:d(l[`h-captcha-response`],`h-captcha-response`,`text`),last_name:d(l[`last-name`],`last-name`,`text`),preferred_locale:d(l[`preferred-locale`],`preferred-locale`,`text`),secondary_billing_email:d(l[`secondary-billing-email`],`secondary-billing-email`,`text`),state:d(l.state,`state`,`text`),tax_id_type:d(l[`tax-id-type`],`tax-id-type`,`text`),telephone:d(l.telephone,`telephone`,`text`),vat:d(l.vat,`vat`,`text`),zipcode:d(l.zipcode,`zipcode`,`text`)}),m=await o(`Updating`,async()=>s.billing.profiles.update({body:p,account_id:f}));i(m,{successLabel:`Updated`})})};function E(e){return e.usage(`$0 billing profiles updateEmail
16
-
17
- Updates the billing email addresses and preferred locale for an account.`).option(`billing-email`,{type:`string`,description:`The billing_email field`}).option(`preferred-locale`,{type:`string`,description:`The preferred_locale field`}).option(`secondary-billing-email`,{type:`string`,description:`The secondary_billing_email field`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const D={command:`updateEmail`,describe:`Update Billing Email`,builder:E,handler:async l=>s({command:`billing profiles updateEmail`,classification:{safeFlags:[`dry-run`]}},l,async()=>{if(l.dryRun){let e=await n();a({command:`cf billing profiles updateEmail`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/billing/profile`,pathParams:{},bodyKind:`json`,body:l.body===void 0?u({billing_email:d(l[`billing-email`],`billing-email`,`text`),preferred_locale:d(l[`preferred-locale`],`preferred-locale`,`text`),secondary_billing_email:d(l[`secondary-billing-email`],`secondary-billing-email`,`text`)}):c(l.body)});return}let s=await t(l),f=l.local?e:await r();if(l.accountId=f,l.body){let e=c(l.body),t=await o(`Updating`,async()=>s.billing.profiles.updateEmail({...e,account_id:f}));i(t,{successLabel:`Updated`});return}let p=u({billing_email:d(l[`billing-email`],`billing-email`,`text`),preferred_locale:d(l[`preferred-locale`],`preferred-locale`,`text`),secondary_billing_email:d(l[`secondary-billing-email`],`secondary-billing-email`,`text`)}),m=await o(`Updating`,async()=>s.billing.profiles.updateEmail({...p,account_id:f}));i(m,{successLabel:`Updated`})})},O={command:`profiles`,describe:`Billing profile with payment method, address, and invoice preferences`,builder:e=>e.command(_).command(y).command(x).command(C).command(T).command(D).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function k(e){return e.usage(`$0 billing rate-plans get <public-key>
18
-
19
- Gets a rate plan's details by its public key (e.g., 'teams_free', 'cf_pro_20_20'). This is a public catalog endpoint, so authentication is not enforced and credentials are accepted but not required.`).positional(`public-key`,{type:`string`,description:`The public key identifier for the rate plan.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const A={command:`get <public-key>`,describe:`Get Rate Plan by Public Key`,builder:k,handler:async e=>s({command:`billing rate-plans get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf billing rate-plans get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/billing/rate_plans/${e[`public-key`]==null?`<public-key>`:encodeURIComponent(String(e[`public-key`]))}`,pathParams:{"public-key":String(e[`public-key`]??``)},bodyKind:`none`});return}let n=await t(e),r=await o(`Loading`,async()=>n.billing.ratePlans.get({public_key:e[`public-key`]}));i(r,{successLabel:`Loaded`})})},j={command:`rate-plans`,describe:`Operations for rate-plans`,builder:e=>e.command(A).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function M(e){return e.usage("$0 billing usage get-account-billable-metrics\n\nLists billable metrics available to the account through contracts and subscriptions that overlap the requested period. Results are deduplicated and ordered. If no qualifying contract exists, the result is an empty array. When `from` and `to` are omitted, the period defaults to the start of the current month through today. The maximum date range is 31 days.").option(`from`,{type:`string`,description:"Start date for the usage query (ISO 8601). Required if `to` is set. When omitted along with `to`, defaults to the start of the current month. Filters by charge period (when consumption happened), not billing period. The maximum date range is 31 days."}).option(`to`,{type:`string`,description:"End date for the usage query (ISO 8601). Required if `from` is set. When omitted along with `from`, defaults to today. Filters by charge period (when consumption happened), not billing period. The maximum date range is 31 days."}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const N={command:`get-account-billable-metrics`,describe:`List Account Billable Metrics (Version 2, Alpha, Restricted)`,builder:M,handler:async c=>s({command:`billing usage get-account-billable-metrics`,classification:{safeFlags:[`dry-run`]}},c,async()=>{let s={from:c.from,to:c.to};if(c.dryRun){let e=await n();a({command:`cf billing usage get-account-billable-metrics`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/billable/usage/billable-metrics`,pathParams:{},query:s,bodyKind:`none`});return}let l=await t(c),u=c.local?e:await r();c.accountId=u;let d=await o(`Loading`,async()=>l.billing.usage.getAccountBillableMetrics({account_id:u,...s}));i(d,{successLabel:`Loaded`})})};function P(e){return e.usage("$0 billing usage get-account-usage-v2\n\nReturns cost and usage data for a single Cloudflare account, aligned with the [FinOps FOCUS v1.3](https://focus.finops.org/focus-specification/v1-3/) Cost and Usage dataset specification. Each record represents one billable metric for one account on one day. This includes all metered usage, including usage that falls within free-tier allowances and may result in zero cost. **Note:** Cost and pricing fields are not yet populated and will be absent from responses until billing integration is complete. When `from` and `to` are omitted, defaults to the start of the current month through today. The maximum date range is 31 days.").option(`from`,{type:`string`,description:"Start date for the usage query (ISO 8601). Required if `to` is set. When omitted along with `to`, defaults to the start of the current month. Filters by charge period (when consumption happened), not billing period. The maximum date range is 31 days."}).option(`to`,{type:`string`,description:"End date for the usage query (ISO 8601). Required if `from` is set. When omitted along with `from`, defaults to today. Filters by charge period (when consumption happened), not billing period. The maximum date range is 31 days."}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const F={command:`get-account-usage-v2`,describe:`Get Account Usage (Version 2, Alpha, Restricted)`,builder:P,handler:async c=>s({command:`billing usage get-account-usage-v2`,classification:{safeFlags:[`dry-run`]}},c,async()=>{let s={from:c.from,to:c.to};if(c.dryRun){let e=await n();a({command:`cf billing usage get-account-usage-v2`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/billable/usage`,pathParams:{},query:s,bodyKind:`none`});return}let l=await t(c),u=c.local?e:await r();c.accountId=u;let d=await o(`Loading`,async()=>l.billing.usage.getAccountUsageV2({account_id:u,...s}));i(d,{successLabel:`Loaded`})})};function I(e){return e.usage(`$0 billing usage get-info-v1
20
-
21
- Returns high-level usage information for the account, including coverage, and subscription metadata.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const L={command:`get-info-v1`,describe:`Get Account Billable Usage Info (Version 1, Alpha)`,builder:I,handler:async c=>s({command:`billing usage get-info-v1`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){let e=await n();a({command:`cf billing usage get-info-v1`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/billable-usage/info`,pathParams:{},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();c.accountId=l;let u=await o(`Loading`,async()=>s.billing.usage.getInfoV1({account_id:l}));i(u,{successLabel:`Loaded`})})};function R(e){return e.usage(`$0 billing usage get-v1
22
-
23
- Returns billable usage data for the account. When no query parameters are provided, returns usage for the current billing period.`).option(`from`,{type:`string`,description:`Start date for the usage query (ISO 8601). The provided time range must include the subscription billing cycle anchor day, otherwise no usage data is returned. Use the info endpoint to retrieve the subscription anchor day.`}).option(`to`,{type:`string`,description:`End date for the usage query (ISO 8601).`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const z={command:`get-v1`,describe:`Get Account Billable Usage (Version 1, Alpha)`,builder:R,handler:async c=>s({command:`billing usage get-v1`,classification:{safeFlags:[`dry-run`]}},c,async()=>{let s={from:c.from,to:c.to};if(c.dryRun){let e=await n();a({command:`cf billing usage get-v1`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/billable-usage`,pathParams:{},query:s,bodyKind:`none`});return}let l=await t(c),u=c.local?e:await r();c.accountId=u;let d=await o(`Loading`,async()=>l.billing.usage.getV1({account_id:u,...s}));i(d,{successLabel:`Loaded`})})};function B(e){return e.usage("$0 billing usage query\n\nReturns cost and usage data for a single Cloudflare account, aligned with the [FinOps FOCUS v1.3](https://focus.finops.org/focus-specification/v1-3/) Cost and Usage dataset specification. This is the filterable counterpart to `GET` on the same path. It is a read-only operation and requires only the `#billing:read` permission; `POST` is used so that filter criteria can be supplied in a request body rather than in the query string. Each record represents one billable metric for one account on one day. This includes all metered usage, including usage that falls within free-tier allowances and may result in zero cost. **Note:** Cost and pricing fields are not yet populated and will be absent from responses until billing integration is complete. The request body is optional. When it is omitted, or when `TimePeriod` is omitted, the range defaults to the start of the current month through today. The maximum date range is 31 days. Filters of different kinds are combined with AND. Values within one tag filter are combined with OR. Filter values that do not match usage produce an empty result set. Results can be grouped by up to two groups, in any combination of dimension keys and resource-tag keys. Tag groups are returned in the `Tags` field. Usage without a requested tag remains in an untagged group, with that key omitted from `Tags`. Requests that use tag filtering or tag grouping return HTTP 400 when the underlying usage data source does not support tags. Requests that use dimension grouping return HTTP 400 when the underlying usage data source does not support dimensions.").option(`filter-by-billable-metric-ids`,{type:`string`,array:!0,description:"Restrict results to rows whose `x_BillableMetricId` matches one of these billable metric ids (e.g. `workers_standard_requests`). Values must be unique."}).option(`filter-by-product-family-ids`,{type:`string`,array:!0,description:`Restrict results to billable metrics belonging to these product families. Values must be unique UUIDs.`}).option(`group-by`,{type:`string`,description:`Grouping definitions used to split result rows. At most two unique keys may be supplied. Provide as a JSON array of objects or @path/to/file.json.`}).option(`metric`,{type:`string`,description:"Type of cost/usage records to retrieve. `usage` returns unrated usage quantities. Unrelated to `FilterBy.BillableMetricIds`. Defaults to `usage` when omitted.",choices:[`usage`],default:`usage`}).option(`time-period-from`,{type:`string`,description:"Start of the range (ISO 8601). Required if `To` is set."}).option(`time-period-to`,{type:`string`,description:"End of the range (ISO 8601). Required if `From` is set. Must be after `From` and no more than 31 days after it."}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Filter criteria for a usage query. Every field is optional; an empty object is equivalent to omitting the body entirely. Unknown fields are rejected.`})}const V={command:`query`,describe:`Query Account Usage (Version 2, Alpha, Restricted)`,builder:B,handler:async f=>s({command:`billing usage query`,classification:{safeFlags:[`metric`,`dry-run`]}},f,async()=>{if(f.dryRun){let e=await n();a({command:`cf billing usage query`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/billable/usage`,pathParams:{},bodyKind:`json`,body:f.body===void 0?u({FilterBy:{BillableMetricIds:f[`filter-by-billable-metric-ids`],ProductFamilyIds:f[`filter-by-product-family-ids`]},GroupBy:l(f[`group-by`],`group-by`),Metric:d(f.metric,`metric`,`text`),TimePeriod:{From:d(f[`time-period-from`],`time-period-from`,`text`),To:d(f[`time-period-to`],`time-period-to`,`text`)}}):c(f.body)});return}let s=await t(f),p=f.local?e:await r();if(f.accountId=p,f.body){let e=c(f.body),t=await o(`Loading`,async()=>s.billing.usage.query({...e,account_id:p}));i(t,{successLabel:`Loaded`});return}let m=u({FilterBy:{BillableMetricIds:f[`filter-by-billable-metric-ids`],ProductFamilyIds:f[`filter-by-product-family-ids`]},GroupBy:l(f[`group-by`],`group-by`),Metric:d(f.metric,`metric`,`text`),TimePeriod:{From:d(f[`time-period-from`],`time-period-from`,`text`),To:d(f[`time-period-to`],`time-period-to`,`text`)}}),h=await o(`Loading`,async()=>s.billing.usage.query({...m,account_id:p}));i(h,{successLabel:`Loaded`})})},H={command:`usage`,describe:`Metered usage data for billed services — requests, bandwidth, and feature consumption`,builder:e=>e.command(N).command(F).command(L).command(z).command(V).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},U={command:`billing`,describe:`Account billing profiles and usage data for Cloudflare subscriptions and add-on services`,builder:e=>e.command(h).command(O).command(j).command(H).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{U as default};
@@ -1,9 +0,0 @@
1
- #!/usr/bin/env node
2
- import{n as e}from"./auth-CGLsxbc6.mjs";import{i as t}from"./context-q7UaYK69.mjs";import{t as n}from"./output-BOe-3AQG.mjs";import{t as r}from"./dry-run-DRj2_uV3.mjs";import{t as i}from"./progress-BtkTVcHI.mjs";import{t as a}from"./run-BvHwWWUX.mjs";import"./telemetry-BsYO3nxG.mjs";import{n as o,t as s}from"./body-parser-DkHKPkJ7.mjs";import{n as c}from"./input-validation-D7z60HJH.mjs";import{a as l,i as u}from"./prompt-RlgRrmbm.mjs";function d(e){return e.usage("$0 bot-management feedback create\n\nSubmit a feedback report for the specified zone. Use `type` to indicate whether the report is a false positive (good traffic flagged as bot) or a false negative (bot traffic missed). Furthermore, you can also use `expression` as a wirefilter to identify the affected traffic sample. See more accepted API fields and expression types at https://developers.cloudflare.com/bots/concepts/feedback-loop/#api-fields and https://developers.cloudflare.com/bots/concepts/feedback-loop/#expression-fields, respectively.").option(`description`,{type:`string`,description:`The description field`}).option(`expression`,{type:`string`,description:`Wirefilter expression describing the traffic being reported.`}).option(`first-request-seen-at`,{type:`string`,description:`The first_request_seen_at field`}).option(`last-request-seen-at`,{type:`string`,description:`The last_request_seen_at field`}).option(`requests`,{type:`number`,description:`The requests field`}).option(`subtype`,{type:`string`,description:`The subtype field`}).option(`type`,{type:`string`,description:`Type of feedback report.`,choices:[`false_positive`,`false_negative`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const f={command:`create`,describe:`Submit a feedback report`,builder:d,handler:async d=>a({command:`bot-management feedback create`,classification:{safeFlags:[`type`,`dry-run`]}},d,async()=>{if(d.dryRun){r({command:`cf bot-management feedback create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${d.zone??d.zoneId??`<zone>`}/bot_management/feedback`,pathParams:{"zone-id":String(d.zone??d[`zone-id`]??``)},bodyKind:`json`,body:d.body===void 0?s({description:c(d.description,`description`,`text`),expression:c(d.expression,`expression`,`text`),first_request_seen_at:c(d[`first-request-seen-at`],`first-request-seen-at`,`text`),last_request_seen_at:c(d[`last-request-seen-at`],`last-request-seen-at`,`text`),requests:d.requests,subtype:c(d.subtype,`subtype`,`text`),type:c(d.type,`type`,`text`)}):o(d.body)});return}let a=await e(d),f=await t({zone:d.zone},a,{quiet:d.quiet});if(d.zoneId=f,d.body){let e=o(d.body),t=await i(`Creating`,async()=>a.botManagement.feedback.create({body:e,zone_id:f}));n(t,{successLabel:`Created`});return}if(d.description===void 0&&(d.description=await l(`description`,`The description field`)),d.expression===void 0&&(d.expression=await l(`expression`,`Wirefilter expression describing the traffic being reported.`)),d[`first-request-seen-at`]===void 0&&(d[`first-request-seen-at`]=await l(`first-request-seen-at`,`The first_request_seen_at field`)),d[`last-request-seen-at`]===void 0&&(d[`last-request-seen-at`]=await l(`last-request-seen-at`,`The last_request_seen_at field`)),d.requests===void 0)throw Error(`--requests is required (or pass --body with this field set).`);d.type===void 0&&(d.type=await u(`type`,`Type of feedback report.`,[`false_positive`,`false_negative`]));let p=s({description:c(d.description,`description`,`text`),expression:c(d.expression,`expression`,`text`),first_request_seen_at:c(d[`first-request-seen-at`],`first-request-seen-at`,`text`),last_request_seen_at:c(d[`last-request-seen-at`],`last-request-seen-at`,`text`),requests:d.requests,subtype:c(d.subtype,`subtype`,`text`),type:c(d.type,`type`,`text`)}),m=await i(`Creating`,async()=>a.botManagement.feedback.create({body:p,zone_id:f}));n(m,{successLabel:`Created`})})};function p(e){return e.usage(`$0 bot-management feedback list
3
-
4
- Returns all feedback reports previously submitted for the specified zone. Feedback reports help improve detection by sharing samples of traffic that were misclassified as bots or humans.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const m={command:`list`,describe:`List zone feedback reports`,builder:p,handler:async o=>a({command:`bot-management feedback list`,classification:{safeFlags:[`dry-run`]}},o,async()=>{if(o.dryRun){r({command:`cf bot-management feedback list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${o.zone??o.zoneId??`<zone>`}/bot_management/feedback`,pathParams:{"zone-id":String(o.zone??o[`zone-id`]??``)},bodyKind:`none`});return}let a=await e(o),s=await t({zone:o.zone},a,{quiet:o.quiet});o.zoneId=s;let c=await i(`Loading`,async()=>a.botManagement.feedback.list({zone_id:s}));n(c,{successLabel:`Loaded`})})},h={command:`feedback`,describe:`Operations for feedback`,builder:e=>e.command(f).command(m).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function g(e){return e.usage(`$0 bot-management get
5
-
6
- Retrieve a zone's Bot Management Config`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const _={command:`get`,describe:`Get Zone Bot Management Config`,builder:g,handler:async o=>a({command:`bot-management get`,classification:{safeFlags:[`dry-run`]}},o,async()=>{if(o.dryRun){r({command:`cf bot-management get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${o.zone??o.zoneId??`<zone>`}/bot_management`,pathParams:{"zone-id":String(o.zone??o[`zone-id`]??``)},bodyKind:`none`});return}let a=await e(o),s=await t({zone:o.zone},a,{quiet:o.quiet});o.zoneId=s;let c=await i(`Loading`,async()=>a.botManagement.get({zone_id:s}));n(c,{successLabel:`Loaded`})})};function v(e){return e.usage('$0 bot-management update\n\nUpdates the Bot Management configuration for a zone. This API is used to update: - **Bot Fight Mode** - **Super Bot Fight Mode** - **Bot Management for Enterprise** See [Bot Plans](https://developers.cloudflare.com/bots/plans/) for more information on the different plans \\ If you recently upgraded or downgraded your plan, refer to the following examples to clean up old configurations. Copy and paste the example body to remove old zone configurations based on your current plan. #### Clean up configuration for Bot Fight Mode plan ```json { "sbfm_likely_automated": "allow", "sbfm_definitely_automated": "allow", "sbfm_verified_bots": "allow", "sbfm_static_resource_protection": false, "optimize_wordpress": false, "suppress_session_score": false } ``` #### Clean up configuration for SBFM Pro plan ```json { "sbfm_likely_automated": "allow", "fight_mode": false } ``` #### Clean up configuration for SBFM Biz plan ```json { "fight_mode": false } ``` #### Clean up configuration for BM Enterprise Subscription plan It is strongly recommended that you ensure you have [custom rules](https://developers.cloudflare.com/waf/custom-rules/) in place to protect your zone before disabling the SBFM rules. Without these protections, your zone is vulnerable to attacks. ```json { "sbfm_likely_automated": "allow", "sbfm_definitely_automated": "allow", "sbfm_verified_bots": "allow", "sbfm_static_resource_protection": false, "optimize_wordpress": false, "fight_mode": false } ```').option(`ai-bots-migration-opt-out`,{type:`boolean`,description:`Temporary migration flag tracking zones opted out of AI bots managed-rule updates.`}).option(`ai-bots-protection`,{type:`string`,description:`Enable rule to block AI Scrapers and Crawlers.`,choices:[`block`,`disabled`,`only_on_ad_pages`]}).option(`ai-search`,{type:`string`,description:`Configure robots.txt policy for AI search bots.`,choices:[`disabled`,`block`,`only_on_ad_pages`]}).option(`ai-training`,{type:`string`,description:`Configure robots.txt policy for AI model training bots.`,choices:[`disabled`,`disallow`,`block`,`only_on_ad_pages`]}).option(`ai-user`,{type:`string`,description:`Configure robots.txt policy for AI assistant and agent bots.`,choices:[`disabled`,`block`,`only_on_ad_pages`]}).option(`bot-preference-sync-enabled`,{type:`boolean`,description:`Enable Bot Preference Sync for this zone. When enabled, Cloudflare can serve robots.txt content derived from the zone's AI Search, AI User, and AI Training preferences.`}).option(`cf-robots-variant`,{type:`string`,description:`Specifies the Robots Access Control License variant to use.`,choices:[`off`,`policy_only`]}).option(`content-bots-protection`,{type:`string`,description:`Enable rule to block content bots. When enabled, blocks automated traffic with low bot scores, excluding safe verified bot categories. Exceptions should be managed via skip rules.`,choices:[`block`,`disabled`]}).option(`crawler-protection`,{type:`string`,description:`Enable rule to punish AI Scrapers and Crawlers via a link maze.`,choices:[`enabled`,`disabled`]}).option(`enable-js`,{type:`boolean`,description:`Use lightweight, invisible JavaScript detections to improve Bot Management. [Learn more about JavaScript Detections](https://developers.cloudflare.com/bots/reference/javascript-detections/).`}).option(`is-robots-txt-managed`,{type:`boolean`,description:`Enable cloudflare managed robots.txt. If an existing robots.txt is detected, then managed robots.txt will be prepended to the existing robots.txt.`}).option(`jsd-api-results-enabled`,{type:`boolean`,description:`Whether to use JavaScript Detection results submitted through the API for this zone.`}).option(`fight-mode`,{type:`boolean`,description:`Whether to enable Bot Fight Mode.`}).option(`stale-zone-configuration-optimize-wordpress`,{type:`boolean`,description:`Indicates that the zone's wordpress optimization for SBFM is turned on.`}).option(`stale-zone-configuration-sbfm-definitely-automated`,{type:`string`,description:`Indicates that the zone's definitely automated requests are being blocked or challenged.`}).option(`stale-zone-configuration-sbfm-likely-automated`,{type:`string`,description:`Indicates that the zone's likely automated requests are being blocked or challenged.`}).option(`stale-zone-configuration-sbfm-static-resource-protection`,{type:`string`,description:`Indicates that the zone's static resource protection is turned on.`}).option(`stale-zone-configuration-sbfm-verified-bots`,{type:`string`,description:`Indicates that the zone's verified bot requests are being blocked.`}).option(`stale-zone-configuration-suppress-session-score`,{type:`boolean`,description:`Indicates that the zone's session score tracking is disabled.`}).option(`stale-zone-configuration-fight-mode`,{type:`boolean`,description:`Indicates that the zone's Bot Fight Mode is turned on.`}).option(`optimize-wordpress`,{type:`boolean`,description:`Whether to optimize Super Bot Fight Mode protections for Wordpress.`}).option(`sbfm-definitely-automated`,{type:`string`,description:`Super Bot Fight Mode (SBFM) action to take on definitely automated requests.`,choices:[`allow`,`block`,`managed_challenge`]}).option(`sbfm-static-resource-protection`,{type:`boolean`,description:`Super Bot Fight Mode (SBFM) to enable static resource protection.
7
- Enable if static resources on your application need bot protection.
8
- Note: Static resource protection can also result in legitimate traffic being blocked.
9
- `}).option(`sbfm-verified-bots`,{type:`string`,description:`Super Bot Fight Mode (SBFM) action to take on verified bots requests.`,choices:[`allow`,`block`]}).option(`sbfm-likely-automated`,{type:`string`,description:`Super Bot Fight Mode (SBFM) action to take on likely automated requests.`,choices:[`allow`,`block`,`managed_challenge`]}).option(`auto-update-model`,{type:`boolean`,description:`Automatically update to the newest bot detection models created by Cloudflare as they are released. [Learn more.](https://developers.cloudflare.com/bots/reference/machine-learning-models#model-versions-and-release-notes)`}).option(`bm-cookie-enabled`,{type:`boolean`,description:`Indicates that the bot management cookie can be placed on end user devices accessing the site. Defaults to true`}).option(`suppress-session-score`,{type:`boolean`,description:`Whether to disable tracking the highest bot score for a session in the Bot Management cookie.`}).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:`update`,describe:`Update Zone Bot Management Config`,builder:v,handler:async l=>a({command:`bot-management update`,classification:{safeFlags:[`ai-bots-migration-opt-out`,`ai-bots-protection`,`ai-search`,`ai-training`,`ai-user`,`bot-preference-sync-enabled`,`cf-robots-variant`,`content-bots-protection`,`crawler-protection`,`enable-js`,`is-robots-txt-managed`,`jsd-api-results-enabled`,`fight-mode`,`stale-zone-configuration-optimize-wordpress`,`stale-zone-configuration-suppress-session-score`,`stale-zone-configuration-fight-mode`,`optimize-wordpress`,`sbfm-definitely-automated`,`sbfm-static-resource-protection`,`sbfm-verified-bots`,`sbfm-likely-automated`,`auto-update-model`,`bm-cookie-enabled`,`suppress-session-score`,`dry-run`]}},l,async()=>{if(l.dryRun){r({command:`cf bot-management update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${l.zone??l.zoneId??`<zone>`}/bot_management`,pathParams:{"zone-id":String(l.zone??l[`zone-id`]??``)},bodyKind:`json`,body:l.body===void 0?s({ai_bots_migration_opt_out:l[`ai-bots-migration-opt-out`],ai_bots_protection:c(l[`ai-bots-protection`],`ai-bots-protection`,`text`),ai_search:c(l[`ai-search`],`ai-search`,`text`),ai_training:c(l[`ai-training`],`ai-training`,`text`),ai_user:c(l[`ai-user`],`ai-user`,`text`),bot_preference_sync_enabled:l[`bot-preference-sync-enabled`],cf_robots_variant:c(l[`cf-robots-variant`],`cf-robots-variant`,`text`),content_bots_protection:c(l[`content-bots-protection`],`content-bots-protection`,`text`),crawler_protection:c(l[`crawler-protection`],`crawler-protection`,`text`),enable_js:l[`enable-js`],is_robots_txt_managed:l[`is-robots-txt-managed`],jsd_api_results_enabled:l[`jsd-api-results-enabled`],fight_mode:l[`fight-mode`],stale_zone_configuration:{optimize_wordpress:l[`stale-zone-configuration-optimize-wordpress`],sbfm_definitely_automated:c(l[`stale-zone-configuration-sbfm-definitely-automated`],`stale-zone-configuration-sbfm-definitely-automated`,`text`),sbfm_likely_automated:c(l[`stale-zone-configuration-sbfm-likely-automated`],`stale-zone-configuration-sbfm-likely-automated`,`text`),sbfm_static_resource_protection:c(l[`stale-zone-configuration-sbfm-static-resource-protection`],`stale-zone-configuration-sbfm-static-resource-protection`,`text`),sbfm_verified_bots:c(l[`stale-zone-configuration-sbfm-verified-bots`],`stale-zone-configuration-sbfm-verified-bots`,`text`),suppress_session_score:l[`stale-zone-configuration-suppress-session-score`],fight_mode:l[`stale-zone-configuration-fight-mode`]},optimize_wordpress:l[`optimize-wordpress`],sbfm_definitely_automated:c(l[`sbfm-definitely-automated`],`sbfm-definitely-automated`,`text`),sbfm_static_resource_protection:l[`sbfm-static-resource-protection`],sbfm_verified_bots:c(l[`sbfm-verified-bots`],`sbfm-verified-bots`,`text`),sbfm_likely_automated:c(l[`sbfm-likely-automated`],`sbfm-likely-automated`,`text`),auto_update_model:l[`auto-update-model`],bm_cookie_enabled:l[`bm-cookie-enabled`],suppress_session_score:l[`suppress-session-score`]}):o(l.body)});return}let a=await e(l),u=await t({zone:l.zone},a,{quiet:l.quiet});if(l.zoneId=u,l.body){let e=o(l.body),t=await i(`Updating`,async()=>a.botManagement.update({body:e,zone_id:u}));n(t,{successLabel:`Updated`});return}let d=s({ai_bots_migration_opt_out:l[`ai-bots-migration-opt-out`],ai_bots_protection:c(l[`ai-bots-protection`],`ai-bots-protection`,`text`),ai_search:c(l[`ai-search`],`ai-search`,`text`),ai_training:c(l[`ai-training`],`ai-training`,`text`),ai_user:c(l[`ai-user`],`ai-user`,`text`),bot_preference_sync_enabled:l[`bot-preference-sync-enabled`],cf_robots_variant:c(l[`cf-robots-variant`],`cf-robots-variant`,`text`),content_bots_protection:c(l[`content-bots-protection`],`content-bots-protection`,`text`),crawler_protection:c(l[`crawler-protection`],`crawler-protection`,`text`),enable_js:l[`enable-js`],is_robots_txt_managed:l[`is-robots-txt-managed`],jsd_api_results_enabled:l[`jsd-api-results-enabled`],fight_mode:l[`fight-mode`],stale_zone_configuration:{optimize_wordpress:l[`stale-zone-configuration-optimize-wordpress`],sbfm_definitely_automated:c(l[`stale-zone-configuration-sbfm-definitely-automated`],`stale-zone-configuration-sbfm-definitely-automated`,`text`),sbfm_likely_automated:c(l[`stale-zone-configuration-sbfm-likely-automated`],`stale-zone-configuration-sbfm-likely-automated`,`text`),sbfm_static_resource_protection:c(l[`stale-zone-configuration-sbfm-static-resource-protection`],`stale-zone-configuration-sbfm-static-resource-protection`,`text`),sbfm_verified_bots:c(l[`stale-zone-configuration-sbfm-verified-bots`],`stale-zone-configuration-sbfm-verified-bots`,`text`),suppress_session_score:l[`stale-zone-configuration-suppress-session-score`],fight_mode:l[`stale-zone-configuration-fight-mode`]},optimize_wordpress:l[`optimize-wordpress`],sbfm_definitely_automated:c(l[`sbfm-definitely-automated`],`sbfm-definitely-automated`,`text`),sbfm_static_resource_protection:l[`sbfm-static-resource-protection`],sbfm_verified_bots:c(l[`sbfm-verified-bots`],`sbfm-verified-bots`,`text`),sbfm_likely_automated:c(l[`sbfm-likely-automated`],`sbfm-likely-automated`,`text`),auto_update_model:l[`auto-update-model`],bm_cookie_enabled:l[`bm-cookie-enabled`],suppress_session_score:l[`suppress-session-score`]}),f=await i(`Updating`,async()=>a.botManagement.update({body:d,zone_id:u}));n(f,{successLabel:`Updated`})})},b={command:`bot-management`,describe:`bot-management`,builder:e=>e.command(_).command(y).command(h).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{b as default};
@@ -1,11 +0,0 @@
1
- #!/usr/bin/env node
2
- import{t as e}from"./local-DlT72Xpn.mjs";import{n as t}from"./auth-CGLsxbc6.mjs";import{a as n,t as r}from"./context-q7UaYK69.mjs";import{t as i}from"./output-BOe-3AQG.mjs";import{t as a}from"./dry-run-DRj2_uV3.mjs";import{t as o}from"./progress-BtkTVcHI.mjs";import{t as s}from"./run-BvHwWWUX.mjs";import"./telemetry-BsYO3nxG.mjs";import{n as c}from"./prompt-RlgRrmbm.mjs";function l(e){return e.usage(`$0 botnet-feed asn day-report <asn-id>
3
-
4
- Gets all the data the botnet tracking database has for a given ASN registered to user account for given date. If no date is given, it will return results for the previous day.`).positional(`asn-id`,{type:`string`,description:`Asn ID`,demandOption:!0}).option(`date`,{type:`string`,description:`Date`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const u={command:`day-report <asn-id>`,describe:`Get daily report`,builder:l,handler:async c=>s({command:`botnet-feed asn day-report`,classification:{safeFlags:[`dry-run`]}},c,async()=>{let s={date:c.date};if(c.dryRun){let e=await n();a({command:`cf botnet-feed asn day-report`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/botnet_feed/asn/${c[`asn-id`]==null?`<asn-id>`:encodeURIComponent(String(c[`asn-id`]))}/day_report`,pathParams:{"asn-id":String(c[`asn-id`]??``)},query:s,bodyKind:`none`});return}let l=await t(c),u=c.local?e:await r();c.accountId=u;let d=await o(`Loading`,async()=>l.botnetFeed.asn.dayReport({account_id:u,asn_id:c[`asn-id`],...s}));i(d,{successLabel:`Loaded`})})};function d(e){return e.usage(`$0 botnet-feed asn full-report <asn-id>
5
-
6
- Gets all the data the botnet threat feed tracking database has for a given ASN registered to user account.`).positional(`asn-id`,{type:`string`,description:`Asn ID`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const f={command:`full-report <asn-id>`,describe:`Get full report`,builder:d,handler:async c=>s({command:`botnet-feed asn full-report`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){let e=await n();a({command:`cf botnet-feed asn full-report`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/botnet_feed/asn/${c[`asn-id`]==null?`<asn-id>`:encodeURIComponent(String(c[`asn-id`]))}/full_report`,pathParams:{"asn-id":String(c[`asn-id`]??``)},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();c.accountId=l;let u=await o(`Loading`,async()=>s.botnetFeed.asn.fullReport({account_id:l,asn_id:c[`asn-id`]}));i(u,{successLabel:`Loaded`})})},p={command:`asn`,describe:`ASN-level botnet activity data showing networks with known C2 infrastructure`,builder:e=>e.command(u).command(f).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function m(e){return e.usage(`$0 botnet-feed configs asn delete <asn-id>
7
-
8
- Delete an ASN from botnet threat feed for a given user.`).positional(`asn-id`,{type:`string`,description:`Asn 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 h={command:`delete <asn-id>`,describe:`Delete an ASN`,builder:m,handler:async l=>s({command:`botnet-feed configs asn delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},l,async()=>{if(l.dryRun){let e=await n();a({command:`cf botnet-feed configs asn delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/botnet_feed/configs/asn/${l[`asn-id`]==null?`<asn-id>`:encodeURIComponent(String(l[`asn-id`]))}`,pathParams:{"asn-id":String(l[`asn-id`]??``)},bodyKind:`none`});return}let s=await t(l),u=l.local?e:await r();if(l.accountId=u,!await c({force:!!l.force})){process.stderr.write(`Aborted.
9
- `);return}let d=await o(`Deleting`,async()=>s.botnetFeed.configs.asn.delete({account_id:u,asn_id:l[`asn-id`]}));i(d,{successLabel:`Deleted`})})};function g(e){return e.usage(`$0 botnet-feed configs asn get
10
-
11
- Gets a list of all ASNs registered for a user for the DDoS Botnet Feed API.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const _={command:`get`,describe:`Get list of ASNs`,builder:g,handler:async c=>s({command:`botnet-feed configs asn get`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){let e=await n();a({command:`cf botnet-feed configs asn get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/botnet_feed/configs/asn`,pathParams:{},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();c.accountId=l;let u=await o(`Loading`,async()=>s.botnetFeed.configs.asn.get({account_id:l}));i(u,{successLabel:`Loaded`})})},v={command:`asn`,describe:`Operations for configs.asn`,builder:e=>e.command(h).command(_).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},y={command:`configs`,describe:`Botnet feed subscription configuration and notification preferences`,builder:e=>e.command(v).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},b={command:`botnet-feed`,describe:`Botnet threat intelligence feeds — IP and ASN-level data on known command-and-control infrastructure`,builder:e=>e.command(p).command(y).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{b as default};
@@ -1,27 +0,0 @@
1
- #!/usr/bin/env node
2
- import{t as e}from"./local-DlT72Xpn.mjs";import{n as t}from"./auth-CGLsxbc6.mjs";import{a as n,t as r}from"./context-q7UaYK69.mjs";import{t as i}from"./output-BOe-3AQG.mjs";import{t as a}from"./dry-run-DRj2_uV3.mjs";import{t as o}from"./progress-BtkTVcHI.mjs";import{t as s}from"./run-BvHwWWUX.mjs";import"./telemetry-BsYO3nxG.mjs";import{n as c,r as l,t as u}from"./body-parser-DkHKPkJ7.mjs";import{n as d}from"./input-validation-D7z60HJH.mjs";import{a as f,i as p,n as m}from"./prompt-RlgRrmbm.mjs";import{t as h}from"./cli-types-9oYmRTHJ.mjs";function g(e){return e.usage(`$0 brand-protection logo-matches get
3
-
4
- Get paginated list of logo matches for a specific brand protection logo query`).option(`offset`,{type:`string`,description:`Offset`}).option(`limit`,{type:`string`,description:`Limit`}).option(`query-id`,{type:`string`,description:`Query ID`,demandOption:!0}).option(`download`,{type:`string`,description:`Download`}).option(`order-by`,{type:`string`,description:`Column to sort by. Options: 'matchedAt', 'domain', 'similarityScore', or 'registrar'`,choices:[`matchedAt`,`domain`,`similarityScore`,`registrar`]}).option(`order`,{type:`string`,description:`Sort order. Options: 'asc' (ascending) or 'desc' (descending)`,choices:[`asc`,`desc`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const _={command:`get`,describe:`List logo matches`,builder:h(g),handler:async c=>s({command:`brand-protection logo-matches get`,classification:{safeFlags:[`order-by`,`order`,`dry-run`]}},c,async()=>{let s={offset:c.offset,limit:c.limit,query_id:c[`query-id`],download:c.download,orderBy:c[`order-by`],order:c.order};if(c.dryRun){let e=await n();a({command:`cf brand-protection logo-matches get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/cloudforce-one/v2/brand-protection/logo/matches`,pathParams:{},query:s,bodyKind:`none`});return}let l=await t(c),u=c.local?e:await r();c.accountId=u;let d=await o(`Loading`,async()=>l.brandProtection.logoMatches.get({account_id:u,...s}));i(d,{successLabel:`Loaded`})})},v={command:`logo-matches`,describe:`Operations for logo-matches`,builder:e=>e.command(_).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function y(e){return e.usage(`$0 brand-protection logos create
5
-
6
- Create a new saved brand protection logo query for visual similarity matching`).option(`image-data`,{type:`string`,description:`Base64 encoded image data. Can include data URI prefix (e.g., 'data:image/png;base64,...') or just the base64 string.`}).option(`search-lookback`,{type:`boolean`,description:`If true, search historic scanned images for matches above the similarity threshold`,default:!0}).option(`similarity-threshold`,{type:`number`,description:`Minimum similarity score (0-1) required for visual matches`}).option(`tag`,{type:`string`,description:`Unique identifier for the logo query`}).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 b={command:`create`,describe:`Insert logo query`,builder:y,handler:async l=>s({command:`brand-protection logos create`,classification:{safeFlags:[`search-lookback`,`dry-run`]}},l,async()=>{if(l.dryRun){let e=await n();a({command:`cf brand-protection logos create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/cloudforce-one/v2/brand-protection/logo/queries`,pathParams:{},bodyKind:`json`,body:l.body===void 0?u({image_data:d(l[`image-data`],`image-data`,`text`),search_lookback:l[`search-lookback`],similarity_threshold:l[`similarity-threshold`],tag:d(l.tag,`tag`,`text`)}):c(l.body)});return}let s=await t(l),p=l.local?e:await r();if(l.accountId=p,l.body){let e=c(l.body),t=await o(`Creating`,async()=>s.brandProtection.logos.create({...e,account_id:p}));i(t,{successLabel:`Created`});return}if(l[`image-data`]===void 0&&(l[`image-data`]=await f(`image-data`,`Base64 encoded image data. Can include data URI prefix (e.g., 'data:image/png;base64,...') or just the base64 string.`)),l[`similarity-threshold`]===void 0)throw Error(`--similarity-threshold is required (or pass --body with this field set).`);l.tag===void 0&&(l.tag=await f(`tag`,`Unique identifier for the logo query`));let m=u({image_data:d(l[`image-data`],`image-data`,`text`),search_lookback:l[`search-lookback`],similarity_threshold:l[`similarity-threshold`],tag:d(l.tag,`tag`,`text`)}),h=await o(`Creating`,async()=>s.brandProtection.logos.create({...m,account_id:p}));i(h,{successLabel:`Created`})})};function x(e){return e.usage(`$0 brand-protection logos delete <query-id>
7
-
8
- Delete a saved brand protection logo query. Returns 404 if the query ID doesn't exist.`).positional(`query-id`,{type:`string`,description:`Query 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 S={command:`delete <query-id>`,describe:`Delete logo query`,builder:x,handler:async c=>s({command:`brand-protection logos delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},c,async()=>{if(c.dryRun){let e=await n();a({command:`cf brand-protection logos delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/cloudforce-one/v2/brand-protection/logo/queries/${c[`query-id`]==null?`<query-id>`:encodeURIComponent(String(c[`query-id`]))}`,pathParams:{"query-id":String(c[`query-id`]??``)},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();if(c.accountId=l,!await m({force:!!c.force})){process.stderr.write(`Aborted.
9
- `);return}let u=await o(`Deleting`,async()=>s.brandProtection.logos.delete({account_id:l,query_id:c[`query-id`]}));i(u,{successLabel:`Deleted`})})};function C(e){return e.usage(`$0 brand-protection logos get
10
-
11
- Get all saved brand protection logo queries for an account. Optionally specify id to get a single query. Set download=true to include base64-encoded image data.`).option(`id`,{type:`string`,description:`Optional query ID to retrieve a specific logo query`}).option(`download`,{type:`string`,description:`If true, include base64-encoded image data in the response`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const w={command:`get`,describe:`Get logo queries`,builder:C,handler:async c=>s({command:`brand-protection logos get`,classification:{safeFlags:[`dry-run`]}},c,async()=>{let s={id:c.id,download:c.download};if(c.dryRun){let e=await n();a({command:`cf brand-protection logos get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/cloudforce-one/v2/brand-protection/logo/queries`,pathParams:{},query:s,bodyKind:`none`});return}let l=await t(c),u=c.local?e:await r();c.accountId=u;let d=await o(`Loading`,async()=>l.brandProtection.logos.get({account_id:u,...s}));i(d,{successLabel:`Loaded`})})},T={command:`logos`,describe:`Operations for logos`,builder:e=>e.command(b).command(S).command(w).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function E(e){return e.usage(`$0 brand-protection matches bulk-dismiss
12
-
13
- Dismiss or undismiss multiple matches in a single request. Accepts either the new format (matches: [{query_id, domain_id}]) for per-query control, or the legacy format (match_ids: [number]) which dismisses for all queries sharing each match's hash. Returns per-item success/error results.`).option(`action`,{type:`string`,description:`The action field`,choices:[`dismiss`,`undismiss`]}).option(`match-ids`,{type:`string`,array:!0,description:`The match_ids field`}).option(`matches`,{type:`string`,description:`The matches field. Provide as a JSON array of objects or @path/to/file.json.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const D={command:`bulk-dismiss`,describe:`Bulk dismiss or undismiss matches`,builder:E,handler:async f=>s({command:`brand-protection matches bulk-dismiss`,classification:{safeFlags:[`action`,`dry-run`]}},f,async()=>{if(f.dryRun){let e=await n();a({command:`cf brand-protection matches bulk-dismiss`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/cloudforce-one/v2/brand-protection/domain/matches/bulk-dismiss`,pathParams:{},bodyKind:`json`,body:f.body===void 0?u({action:d(f.action,`action`,`text`),match_ids:f[`match-ids`],matches:l(f.matches,`matches`)}):c(f.body)});return}let s=await t(f),m=f.local?e:await r();if(f.accountId=m,f.body){let e=c(f.body),t=await o(`Creating`,async()=>s.brandProtection.matches.bulkDismiss({...e,account_id:m}));i(t,{successLabel:`Created`});return}f.action===void 0&&(f.action=await p(`action`,`The action field`,[`dismiss`,`undismiss`]));let h=u({action:d(f.action,`action`,`text`),match_ids:f[`match-ids`],matches:l(f.matches,`matches`)}),g=await o(`Creating`,async()=>s.brandProtection.matches.bulkDismiss({...h,account_id:m}));i(g,{successLabel:`Created`})})};function O(e){return e.usage(`$0 brand-protection matches get
14
-
15
- Get paginated list of domain matches for one or more brand protection queries. When multiple query_ids are provided (comma-separated), matches are deduplicated across queries and each match includes a match_details array with per-match query metadata and individual dismissed state.`).option(`offset`,{type:`string`,description:`Offset`}).option(`limit`,{type:`string`,description:`Limit`}).option(`query-id`,{type:`string`,description:`Query ID or comma-separated list of Query IDs. When multiple IDs are provided, matches are deduplicated across queries and each match includes a match_details array with per-match query metadata and dismissed state.`,demandOption:!0}).option(`include-domain-id`,{type:`string`,description:`Include domain ID`}).option(`include-dismissed`,{type:`string`,description:`Include dismissed`}).option(`domain-search`,{type:`string`,description:`Filter matches by domain name (substring match)`}).option(`order-by`,{type:`string`,description:`Column to sort by. Options: 'domain', 'first_seen', or 'registrar'`,choices:[`domain`,`first_seen`,`registrar`]}).option(`order`,{type:`string`,description:`Sort order. Options: 'asc' (ascending) or 'desc' (descending)`,choices:[`asc`,`desc`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const k={command:`get`,describe:`List saved query matches`,builder:h(O),handler:async c=>s({command:`brand-protection matches get`,classification:{safeFlags:[`order-by`,`order`,`dry-run`]}},c,async()=>{let s={offset:c.offset,limit:c.limit,query_id:c[`query-id`],include_domain_id:c[`include-domain-id`],include_dismissed:c[`include-dismissed`],domain_search:c[`domain-search`],orderBy:c[`order-by`],order:c.order};if(c.dryRun){let e=await n();a({command:`cf brand-protection matches get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/cloudforce-one/v2/brand-protection/domain/matches`,pathParams:{},query:s,bodyKind:`none`});return}let l=await t(c),u=c.local?e:await r();c.accountId=u;let d=await o(`Loading`,async()=>l.brandProtection.matches.get({account_id:u,...s}));i(d,{successLabel:`Loaded`})})},A={command:`matches`,describe:`Operations for matches`,builder:e=>e.command(D).command(k).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function j(e){return e.usage(`$0 brand-protection queries dismiss <domain-id>
16
-
17
- Mark a specific domain as dismissed for a given query. Dismissals are per-query — dismissing a domain in one query does not affect other queries.`).positional(`domain-id`,{type:`string`,description:`Domain ID`,demandOption:!0}).option(`query-id`,{type:`string`,description:`Query ID`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const M={command:`dismiss <domain-id>`,describe:`Dismiss a match`,builder:j,handler:async c=>s({command:`brand-protection queries dismiss`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){let e=await n();a({command:`cf brand-protection queries dismiss`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/cloudforce-one/v2/brand-protection/queries/${c[`query-id`]==null?`<query-id>`:encodeURIComponent(String(c[`query-id`]))}/matches/${c[`domain-id`]==null?`<domain-id>`:encodeURIComponent(String(c[`domain-id`]))}/dismiss`,pathParams:{"query-id":String(c[`query-id`]??``),"domain-id":String(c[`domain-id`]??``)},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();c.accountId=l;let u=await o(`Creating`,async()=>s.brandProtection.queries.dismiss({account_id:l,query_id:c[`query-id`],domain_id:c[`domain-id`]}));i(u,{successLabel:`Created`})})};function N(e){return e.usage(`$0 brand-protection queries get
18
-
19
- Get all saved brand protection queries for an account`).option(`id`,{type:`string`,description:`ID`}).option(`page`,{type:`number`,description:`Optional page number for paginated list requests. Defaults to 1 when only per_page is supplied. Omit page and per_page to preserve the legacy full-list response.`}).option(`per-page`,{type:`number`,description:`Optional number of queries per page for paginated list requests. Defaults to 100 when only page is supplied. Maximum 100. Omit page and per_page to preserve the legacy full-list response.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const P={command:`get`,describe:`Get queries`,builder:N,handler:async c=>s({command:`brand-protection queries get`,classification:{safeFlags:[`dry-run`]}},c,async()=>{let s={id:c.id,page:c.page,per_page:c[`per-page`]};if(c.dryRun){let e=await n();a({command:`cf brand-protection queries get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/cloudforce-one/v2/brand-protection/domain/queries`,pathParams:{},query:s,bodyKind:`none`});return}let l=await t(c),u=c.local?e:await r();c.accountId=u;let d=await o(`Loading`,async()=>l.brandProtection.queries.get({account_id:u,...s}));i(d,{successLabel:`Loaded`})})};function F(e){return e.usage(`$0 brand-protection queries undismiss <domain-id>
20
-
21
- Remove the dismissed status from a specific domain for a given query. Undismissals are per-query — undismissing a domain in one query does not affect other queries.`).positional(`domain-id`,{type:`string`,description:`Domain ID`,demandOption:!0}).option(`query-id`,{type:`string`,description:`Query ID`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const I={command:`undismiss <domain-id>`,describe:`Undismiss a match`,builder:F,handler:async c=>s({command:`brand-protection queries undismiss`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){let e=await n();a({command:`cf brand-protection queries undismiss`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/cloudforce-one/v2/brand-protection/queries/${c[`query-id`]==null?`<query-id>`:encodeURIComponent(String(c[`query-id`]))}/matches/${c[`domain-id`]==null?`<domain-id>`:encodeURIComponent(String(c[`domain-id`]))}/undismiss`,pathParams:{"query-id":String(c[`query-id`]??``),"domain-id":String(c[`domain-id`]??``)},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();c.accountId=l;let u=await o(`Creating`,async()=>s.brandProtection.queries.undismiss({account_id:l,query_id:c[`query-id`],domain_id:c[`domain-id`]}));i(u,{successLabel:`Created`})})},L={command:`queries`,describe:`Operations for queries`,builder:e=>e.command(M).command(P).command(I).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function R(e){return e.usage(`$0 brand-protection submit
22
-
23
- Submit an image and find the n closest matches from the scanned images index without creating any match records. Returns similarity scores and metadata for each match.`).option(`show-historic`,{type:`string`,description:`Include scanned images without domain metadata (historic data). Default: false (only show images with domain)`}).option(`download`,{type:`string`,description:`If true, include base64-encoded image data in the response`}).option(`image-data`,{type:`string`,description:`Base64 encoded image data. Can include data URI prefix (e.g., 'data:image/png;base64,...') or just the base64 string.`}).option(`score-threshold`,{type:`number`,description:`Minimum similarity score threshold for matches (0-1, default: 0)`,default:0}).option(`top-k`,{type:`number`,description:`Number of closest matches to return (1-100, default: 10)`,default:10}).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 z={command:`submit`,describe:`Search scanned images`,builder:R,handler:async l=>s({command:`brand-protection submit`,classification:{safeFlags:[`dry-run`]}},l,async()=>{let s={showHistoric:l[`show-historic`],download:l.download};if(l.dryRun){let e=await n();a({command:`cf brand-protection submit`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/cloudforce-one/v2/brand-protection/logo/search`,pathParams:{},query:s,bodyKind:`json`,body:l.body===void 0?u({image_data:d(l[`image-data`],`image-data`,`text`),score_threshold:l[`score-threshold`],top_k:l[`top-k`]}):c(l.body)});return}let p=await t(l),m=l.local?e:await r();if(l.accountId=m,l.body){let e=c(l.body);new URLSearchParams(Object.entries(s).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString();let t=await o(`Creating`,async()=>p.brandProtection.submit({...e,account_id:m,...s}));i(t,{successLabel:`Created`});return}l[`image-data`]===void 0&&(l[`image-data`]=await f(`image-data`,`Base64 encoded image data. Can include data URI prefix (e.g., 'data:image/png;base64,...') or just the base64 string.`));let h=u({image_data:d(l[`image-data`],`image-data`,`text`),score_threshold:l[`score-threshold`],top_k:l[`top-k`]});new URLSearchParams(Object.entries(s).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString();let g=await o(`Creating`,async()=>p.brandProtection.submit({...h,account_id:m,...s}));i(g,{successLabel:`Created`})})};function B(e){return e.usage(`$0 brand-protection trial create
24
-
25
- Uses AI to scan all domains in the lookback table and identify potential phishing or impersonation attempts against the given brand string.`).option(`brand`,{type:`string`,description:`The brand field`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const V={command:`create`,describe:`Analyze domains for brand impersonation`,builder:B,handler:async l=>s({command:`brand-protection trial create`,classification:{safeFlags:[`dry-run`]}},l,async()=>{if(l.dryRun){let e=await n();a({command:`cf brand-protection trial create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/cloudforce-one/v2/brand-protection/domain/trial`,pathParams:{},bodyKind:`json`,body:l.body===void 0?u({brand:d(l.brand,`brand`,`text`)}):c(l.body)});return}let s=await t(l),p=l.local?e:await r();if(l.accountId=p,l.body){let e=c(l.body),t=await o(`Creating`,async()=>s.brandProtection.trial.create({...e,account_id:p}));i(t,{successLabel:`Created`});return}l.brand===void 0&&(l.brand=await f(`brand`,`The brand field`));let m=u({brand:d(l.brand,`brand`,`text`)}),h=await o(`Creating`,async()=>s.brandProtection.trial.create({...m,account_id:p}));i(h,{successLabel:`Created`})})},H={command:`trial`,describe:`Operations for trial`,builder:e=>e.command(V).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function U(e){return e.usage(`$0 brand-protection url-info
26
-
27
- Get the total number of saved brand protection queries (domain + logo) for an account`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const W={command:`url-info`,describe:`Get total queries`,builder:U,handler:async c=>s({command:`brand-protection url-info`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){let e=await n();a({command:`cf brand-protection url-info`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/cloudforce-one/v2/brand-protection/total-queries`,pathParams:{},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();c.accountId=l;let u=await o(`Loading`,async()=>s.brandProtection.urlInfo({account_id:l}));i(u,{successLabel:`Loaded`})})},G={command:`brand-protection`,describe:`brand-protection`,builder:e=>e.command(z).command(W).command(v).command(T).command(A).command(L).command(H).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{G as default};