cf 0.1.0 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (248) hide show
  1. package/dist/_meta/agent-context.json +88 -88
  2. package/dist/_meta/commands.json +5268 -5350
  3. package/dist/_meta/schemas.json +33572 -1148
  4. package/dist/abuse-reports-KtfZhi6j.mjs +8 -0
  5. package/dist/accounts-BopMfODC.mjs +21 -0
  6. package/dist/acm-BT4vlnEJ.mjs +3 -0
  7. package/dist/addressing-B3uFxHst.mjs +13 -0
  8. package/dist/ai-DWHqwMap.mjs +2 -0
  9. package/dist/ai-gateway-CbKEO-3o.mjs +8 -0
  10. package/dist/ai-search-VnOQ5n--.mjs +7 -0
  11. package/dist/alerting-BmmgIlIO.mjs +6 -0
  12. package/dist/analytics-isY03taL.mjs +20 -0
  13. package/dist/api-gateway-DXurEbA-.mjs +33 -0
  14. package/dist/argo-B02BL_hp.mjs +2 -0
  15. package/dist/audit-logs-DcgR9xUc.mjs +2 -0
  16. package/dist/auth-CQcAgnOy.mjs +135 -0
  17. package/dist/{auth-DQ8miey6.mjs → auth-DenWm_X0.mjs} +3 -3
  18. package/dist/autorag-CmrwnGVj.mjs +2 -0
  19. package/dist/{billing-lwBHNTXC.mjs → billing-CaW1ZAB1.mjs} +1 -1
  20. package/dist/bot-management-CeBsFx68.mjs +5 -0
  21. package/dist/botnet-feed-B396vQeQ.mjs +3 -0
  22. package/dist/brand-protection-D4V1v5Kl.mjs +3 -0
  23. package/dist/browser-rendering-GF7rNtKI.mjs +4 -0
  24. package/dist/build-5jmmOZhm.mjs +1054 -0
  25. package/dist/cache-DmXizSMi.mjs +5 -0
  26. package/dist/calls-x4KQpTB4.mjs +4 -0
  27. package/dist/certificate-authorities-hC0SG-Ga.mjs +2 -0
  28. package/dist/client-certificates-BGVsDyeJ.mjs +3 -0
  29. package/dist/cloud-connector-BClQpEzI.mjs +2 -0
  30. package/dist/cloudforce-one-BfhFrO6M.mjs +21 -0
  31. package/dist/{config-BIfdEY0E.mjs → config-DYzlVxcB.mjs} +1 -1
  32. package/dist/connectivity-G0NP6LtW.mjs +3 -0
  33. package/dist/content-scanning-DEtPJ7aF.mjs +4 -0
  34. package/dist/context-CC0Rhkhy.mjs +2 -0
  35. package/dist/custom-certificates-rJXFpUWu.mjs +5 -0
  36. package/dist/custom-hostnames-Be5mgLeF.mjs +5 -0
  37. package/dist/custom-nameservers-CoFdy6hD.mjs +3 -0
  38. package/dist/custom-pages-D-oErw57.mjs +4 -0
  39. package/dist/d1-C95ckPKI.mjs +3 -0
  40. package/dist/dcv-delegation-CWSkbGuc.mjs +2 -0
  41. package/dist/delegate.mjs +1 -1
  42. package/dist/deploy-DbkiIzUr.mjs +2 -0
  43. package/dist/{dev-BfKYB-R_.mjs → dev-C6iSuQZm.mjs} +1 -1
  44. package/dist/diagnostics-DEEhPnXj.mjs +3 -0
  45. package/dist/dispatch-namespaces-BzXeV7PH.mjs +7 -0
  46. package/dist/{dist-C_bu5HwZ.mjs → dist-CnSubA1Z.mjs} +1 -1
  47. package/dist/dist-DNBSHor6.mjs +301 -0
  48. package/dist/dns-firewall-BQXD_NxG.mjs +57 -0
  49. package/dist/dns-qW-3TZOT.mjs +29 -0
  50. package/dist/durable-objects-CgWFYEJJ.mjs +2 -0
  51. package/dist/email-routing-tdNJaCpJ.mjs +10 -0
  52. package/dist/email-security-DTVHNr2h.mjs +60 -0
  53. package/dist/email-sending-DsFTvE31.mjs +3 -0
  54. package/dist/filters-DO1Is_tI.mjs +4 -0
  55. package/dist/firewall-DbUhVTCg.mjs +11 -0
  56. package/dist/fraud-Bzr4njYb.mjs +8 -0
  57. package/dist/google-tag-gateway-BQxkA90M.mjs +2 -0
  58. package/dist/healthchecks-BBAs-lS_.mjs +4 -0
  59. package/dist/hostnames-Dz9PEUKS.mjs +3 -0
  60. package/dist/hyperdrive-B1iUJddG.mjs +18 -0
  61. package/dist/iam-CJM8gHpG.mjs +6 -0
  62. package/dist/images-DEoBmtFS.mjs +5 -0
  63. package/dist/index.mjs +1 -1
  64. package/dist/intel-BM6xkZ0C.mjs +3 -0
  65. package/dist/{ips-B0cK7D0_.mjs → ips-B8fwxKZD.mjs} +1 -1
  66. package/dist/keyless-certificates-DffYnd4b.mjs +3 -0
  67. package/dist/kv-BTceLtWZ.mjs +5 -0
  68. package/dist/leaked-credential-checks-CALfvoCo.mjs +3 -0
  69. package/dist/load-balancers-C1Ho1gCF.mjs +6 -0
  70. package/dist/logpush-CSYhgevA.mjs +4 -0
  71. package/dist/logs-DlIwmMpt.mjs +3 -0
  72. package/dist/magic-cloud-networking-Czu0pZ0a.mjs +5 -0
  73. package/dist/magic-network-monitoring-d7GJE5Yt.mjs +4 -0
  74. package/dist/magic-transit-qQmA-981.mjs +89 -0
  75. package/dist/managed-transforms-Dd6AnbWE.mjs +3 -0
  76. package/dist/mtls-certificates-C0rlCRGs.mjs +3 -0
  77. package/dist/network-interconnects-CxG2deY0.mjs +36 -0
  78. package/dist/organizations-DyEAiGiR.mjs +41 -0
  79. package/dist/origin-ca-certificates-S8RcoMF6.mjs +3 -0
  80. package/dist/origin-post-quantum-encryption-B8ZcpLu5.mjs +2 -0
  81. package/dist/origin-tls-client-auth-BlxMmQrE.mjs +5 -0
  82. package/dist/page-rules-DP-w6TAm.mjs +18 -0
  83. package/dist/page-shield-Bf7kFp8c.mjs +37 -0
  84. package/dist/pages-D0Y_XRqW.mjs +10 -0
  85. package/dist/pipelines-C-SPESAk.mjs +6 -0
  86. package/dist/{progress-DZfTxbrx.mjs → progress-CjcQ6ato.mjs} +1 -1
  87. package/dist/queues-wv6CZsi8.mjs +6 -0
  88. package/dist/r2-DuXjp9n5.mjs +21 -0
  89. package/dist/r2-data-catalog-DQCMrmNO.mjs +14 -0
  90. package/dist/radar-BW_ZHP8X.mjs +2 -0
  91. package/dist/rate-limits-DLTkIvwr.mjs +5 -0
  92. package/dist/raw-fetch-hRv-6P3D.mjs +2 -0
  93. package/dist/realtime-kit-Ch7Vg3vj.mjs +6 -0
  94. package/dist/{registrar-7Qy50zbW.mjs → registrar-DIIv6fWd.mjs} +6 -6
  95. package/dist/request-tracers-DMej0Drs.mjs +2 -0
  96. package/dist/resource-sharing-CYJ7cMWq.mjs +5 -0
  97. package/dist/resource-tagging-Dnz65MgH.mjs +16 -0
  98. package/dist/rules-DLJpOYbC.mjs +4 -0
  99. package/dist/rulesets-D9nqEJT5.mjs +8 -0
  100. package/dist/rum-DBVmdPkp.mjs +4 -0
  101. package/dist/schema-validation-MCd3xdtX.mjs +4 -0
  102. package/dist/scim-DZA3VXog.mjs +3 -0
  103. package/dist/secrets-store-BrvcZSOM.mjs +21 -0
  104. package/dist/security-center-BU6f3Cm1.mjs +2 -0
  105. package/dist/security-txt-BPIbP3dG.mjs +3 -0
  106. package/dist/{session-mW-s8ghP.mjs → session-H7IV2BrM.mjs} +1 -1
  107. package/dist/shared-DEzmTsEC.mjs +2 -0
  108. package/dist/smart-shield-e8XFBkiF.mjs +3 -0
  109. package/dist/snippets-B4M3MMb8.mjs +4 -0
  110. package/dist/{spawn-D_cjG87Z.mjs → spawn-13QQ0IwO.mjs} +1 -1
  111. package/dist/spectrum-B0adfSRI.mjs +59 -0
  112. package/dist/speed-BVcUtkAz.mjs +4 -0
  113. package/dist/{src-C5qivNKH.mjs → src-B9cKsgsg.mjs} +8 -8
  114. package/dist/ssl-BAa91gsc.mjs +15 -0
  115. package/dist/stream-D53sxKb3.mjs +14 -0
  116. package/dist/tenants-bH5pt3dJ.mjs +2 -0
  117. package/dist/token-validation-M61Vx_Tw.mjs +4 -0
  118. package/dist/turnstile-wAU0Gc2Z.mjs +23 -0
  119. package/dist/{ui-mP_arYIg.mjs → ui-BXjU1dX1.mjs} +1 -1
  120. package/dist/url-normalization-DZrWDgB5.mjs +3 -0
  121. package/dist/url-scanner-Zo49edNp.mjs +2 -0
  122. package/dist/user-DbXlVReB.mjs +10 -0
  123. package/dist/vectorize-CUnTM0DT.mjs +4 -0
  124. package/dist/versions-DzyrlUAi.mjs +2 -0
  125. package/dist/waiting-rooms-BZW0X69-.mjs +11 -0
  126. package/dist/web3-DueyOQtx.mjs +4 -0
  127. package/dist/workers-builds-BM_aoeUR.mjs +7 -0
  128. package/dist/workers-nV_vBCfV.mjs +16 -0
  129. package/dist/workflows-CQITmo-s.mjs +4 -0
  130. package/dist/zaraz-DIbpF5Op.mjs +2 -0
  131. package/dist/zero-trust-CKp8j512.mjs +119 -0
  132. package/dist/zones-BZ5tZDbH.mjs +28 -0
  133. package/package.json +4 -4
  134. package/dist/abuse-reports-ChV_yD7f.mjs +0 -8
  135. package/dist/accounts-BCYecXFh.mjs +0 -21
  136. package/dist/acm-DD8zSds2.mjs +0 -3
  137. package/dist/addressing-D4Eqw5Bi.mjs +0 -13
  138. package/dist/ai-DfXMOMx_.mjs +0 -2
  139. package/dist/ai-gateway-DdRFthMo.mjs +0 -8
  140. package/dist/ai-search-C_68CDj1.mjs +0 -7
  141. package/dist/alerting-DbhqhVCp.mjs +0 -6
  142. package/dist/analytics-BSBBc7ep.mjs +0 -20
  143. package/dist/api-gateway-CZ4swbkQ.mjs +0 -33
  144. package/dist/argo-tms9ZwHO.mjs +0 -2
  145. package/dist/audit-logs-24qyW8cl.mjs +0 -2
  146. package/dist/auth-BlSmtIKd.mjs +0 -112
  147. package/dist/autorag-kgNt06GD.mjs +0 -2
  148. package/dist/bot-management-LKf7BqUr.mjs +0 -5
  149. package/dist/botnet-feed-nQ-gErTS.mjs +0 -3
  150. package/dist/brand-protection-DOKv9GRr.mjs +0 -3
  151. package/dist/browser-rendering-CBExtgGt.mjs +0 -4
  152. package/dist/build-C_48VvoK.mjs +0 -1056
  153. package/dist/cache-BBiiNZHP.mjs +0 -5
  154. package/dist/calls-DA5Xzwev.mjs +0 -4
  155. package/dist/certificate-authorities-sXyR_yGp.mjs +0 -2
  156. package/dist/client-certificates-tV0aCLQJ.mjs +0 -3
  157. package/dist/cloud-connector-DZfHcSso.mjs +0 -2
  158. package/dist/cloudforce-one-y1PgQmI9.mjs +0 -21
  159. package/dist/connectivity-8SOqaFDn.mjs +0 -3
  160. package/dist/content-scanning-B9y6K_G5.mjs +0 -4
  161. package/dist/context-DTIbtQn5.mjs +0 -2
  162. package/dist/custom-certificates-sWksR8Ys.mjs +0 -5
  163. package/dist/custom-hostnames-91QZkdqN.mjs +0 -5
  164. package/dist/custom-nameservers-DajZaZvE.mjs +0 -3
  165. package/dist/custom-pages-Cu7gmwzT.mjs +0 -4
  166. package/dist/d1-H_VRsVmF.mjs +0 -3
  167. package/dist/dcv-delegation-C-qhEYEZ.mjs +0 -2
  168. package/dist/deploy--9wYOkHg.mjs +0 -2
  169. package/dist/diagnostics-D2B2LPZZ.mjs +0 -3
  170. package/dist/dispatch-namespaces-CyrXBU_w.mjs +0 -7
  171. package/dist/dist-DvKjT2TT.mjs +0 -303
  172. package/dist/dns-Bn9Uz_Nj.mjs +0 -29
  173. package/dist/dns-firewall-BslP4p-j.mjs +0 -57
  174. package/dist/durable-objects-BN1ZnHhm.mjs +0 -2
  175. package/dist/email-routing-n2TnTaRR.mjs +0 -10
  176. package/dist/email-security-C9SEx0kh.mjs +0 -60
  177. package/dist/email-sending-DayZ7u3I.mjs +0 -3
  178. package/dist/filters-CI_XTgfQ.mjs +0 -4
  179. package/dist/firewall-CcaayGig.mjs +0 -11
  180. package/dist/fraud-Cr7aPCV8.mjs +0 -8
  181. package/dist/google-tag-gateway-B3GpYgQ4.mjs +0 -2
  182. package/dist/healthchecks-CVTsR_OC.mjs +0 -4
  183. package/dist/hostnames-Bd_Wa5l6.mjs +0 -3
  184. package/dist/hyperdrive-BBJhEDZd.mjs +0 -18
  185. package/dist/iam-D_FN0pDF.mjs +0 -6
  186. package/dist/images-CAP2hAlZ.mjs +0 -5
  187. package/dist/intel-CkxfzqmJ.mjs +0 -3
  188. package/dist/keyless-certificates-LcLmHZsX.mjs +0 -3
  189. package/dist/kv-_TkUQ6fs.mjs +0 -5
  190. package/dist/leaked-credential-checks-Dhvaen22.mjs +0 -3
  191. package/dist/load-balancers-Ckr0UIpk.mjs +0 -6
  192. package/dist/logpush-Cj946hxT.mjs +0 -4
  193. package/dist/logs-DgC9hjvJ.mjs +0 -3
  194. package/dist/magic-cloud-networking-WbDvPzuG.mjs +0 -5
  195. package/dist/magic-network-monitoring-BcHShvGQ.mjs +0 -4
  196. package/dist/magic-transit-B8sCOkt_.mjs +0 -89
  197. package/dist/managed-transforms-BpOr-8HY.mjs +0 -3
  198. package/dist/mtls-certificates-fOul8D5g.mjs +0 -3
  199. package/dist/network-interconnects-BSW65xlh.mjs +0 -36
  200. package/dist/organizations-T4vKGFAb.mjs +0 -41
  201. package/dist/origin-ca-certificates-ChM0lZ64.mjs +0 -3
  202. package/dist/origin-post-quantum-encryption-C7o26ARh.mjs +0 -2
  203. package/dist/origin-tls-client-auth-D32dpZk_.mjs +0 -5
  204. package/dist/page-rules-RFoj8CjN.mjs +0 -18
  205. package/dist/page-shield-VTktzKDN.mjs +0 -37
  206. package/dist/pages-L1ITjXDZ.mjs +0 -10
  207. package/dist/pipelines-BPO0Lnil.mjs +0 -6
  208. package/dist/queues-B0C06L9r.mjs +0 -6
  209. package/dist/r2-DP020Tmq.mjs +0 -21
  210. package/dist/r2-data-catalog-Dmipvz5F.mjs +0 -14
  211. package/dist/radar-DR3VMknH.mjs +0 -2
  212. package/dist/rate-limits-DnHPBPgU.mjs +0 -5
  213. package/dist/raw-fetch-DlXYwVA8.mjs +0 -2
  214. package/dist/realtime-kit-C430aq2d.mjs +0 -6
  215. package/dist/request-tracers-sv99NDIl.mjs +0 -2
  216. package/dist/resource-sharing-uEjC7lnQ.mjs +0 -5
  217. package/dist/resource-tagging-CiODdP3N.mjs +0 -16
  218. package/dist/rules-FXAyTrwk.mjs +0 -4
  219. package/dist/rulesets-B6aUsFFB.mjs +0 -8
  220. package/dist/rum-CyyGJhp5.mjs +0 -4
  221. package/dist/schema-validation-ByU49h--.mjs +0 -4
  222. package/dist/scim-DdTS65_C.mjs +0 -3
  223. package/dist/secrets-store-ClOUVhBJ.mjs +0 -18
  224. package/dist/security-center-4iSBqTrf.mjs +0 -2
  225. package/dist/security-txt-kGxdkDY6.mjs +0 -3
  226. package/dist/smart-shield-B-SQd2Qp.mjs +0 -3
  227. package/dist/snippets-Aq58ojqw.mjs +0 -4
  228. package/dist/spectrum-0gFvGI6y.mjs +0 -59
  229. package/dist/speed-DAZU8w3T.mjs +0 -4
  230. package/dist/ssl-BRlXa-5w.mjs +0 -15
  231. package/dist/stream-BAxsVeBX.mjs +0 -14
  232. package/dist/tenants-Df6xDqoA.mjs +0 -2
  233. package/dist/token-validation-pO4dCjCy.mjs +0 -4
  234. package/dist/turnstile-B1dmO8wE.mjs +0 -23
  235. package/dist/url-normalization-sUDVmrUt.mjs +0 -3
  236. package/dist/url-scanner-CwOKRkYo.mjs +0 -2
  237. package/dist/user-D_UrIdNq.mjs +0 -10
  238. package/dist/vectorize-BEbBn9G9.mjs +0 -4
  239. package/dist/waiting-rooms-BQC-urV4.mjs +0 -11
  240. package/dist/web3-CIH2iQeX.mjs +0 -4
  241. package/dist/workers-B9EvrpH3.mjs +0 -16
  242. package/dist/workers-builds-DzWSiRd2.mjs +0 -7
  243. package/dist/workflows-aD81gA4k.mjs +0 -4
  244. package/dist/zaraz-Cg1dsvrZ.mjs +0 -2
  245. package/dist/zero-trust-D-xQXWcy.mjs +0 -119
  246. package/dist/zones-DQzucJDd.mjs +0 -28
  247. /package/dist/{schema-D0_cbcDt.mjs → schema-CHBfkARI.mjs} +0 -0
  248. /package/dist/{tools-CtKbk6VS.mjs → tools-B7QiNu-d.mjs} +0 -0
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import{o as e,t}from"./chunk-DH-VkVmc.mjs";import{a as n,n as r,o as i,r as a,s as o,t as s}from"./session-mW-s8ghP.mjs";import{O as c}from"./dist-DvKjT2TT.mjs";import{a as l,n as u,t as d}from"./theme-BklJDrb2.mjs";import{a as f,t as p}from"./ui-mP_arYIg.mjs";import{createRequire as m}from"node:module";import{notStrictEqual as h,strictEqual as g}from"assert";import{basename as ee,dirname as _,extname as te,join as v,normalize as ne,relative as re,resolve as y}from"path";import{readFileSync as b,readdirSync as x,statSync as S,writeFile as ie}from"fs";import{format as C,inspect as ae}from"util";import{fileURLToPath as oe}from"url";import{readFileSync as se,readdirSync as ce}from"node:fs";const le={right:me,center:w};var ue=class{constructor(e){this.width=e.width,this.wrap=e.wrap??!0,this.rows=[]}span(...e){let t=this.div(...e);t.span=!0}resetOutput(){this.rows=[]}div(...e){if(e.length===0&&this.div(``),this.wrap&&this.shouldApplyLayoutDSL(...e)&&typeof e[0]==`string`)return this.applyLayoutDSL(e[0]);let t=e.map(e=>typeof e==`string`?this.colFromString(e):e);return this.rows.push(t),t}shouldApplyLayoutDSL(...e){return e.length===1&&typeof e[0]==`string`&&/[\t\n]/.test(e[0])}applyLayoutDSL(e){let t=e.split(`
2
+ import{o as e,t}from"./chunk-DH-VkVmc.mjs";import{a as n,n as r,o as i,r as a,s as o,t as s}from"./session-H7IV2BrM.mjs";import{j as c}from"./dist-DNBSHor6.mjs";import{a as l,n as u,t as d}from"./theme-BklJDrb2.mjs";import{a as f,t as p}from"./ui-BXjU1dX1.mjs";import{createRequire as m}from"node:module";import{notStrictEqual as h,strictEqual as g}from"assert";import{basename as ee,dirname as _,extname as te,join as v,normalize as ne,relative as re,resolve as y}from"path";import{readFileSync as b,readdirSync as x,statSync as S,writeFile as ie}from"fs";import{format as C,inspect as ae}from"util";import{fileURLToPath as oe}from"url";import{readFileSync as se,readdirSync as ce}from"node:fs";const le={right:me,center:w};var ue=class{constructor(e){this.width=e.width,this.wrap=e.wrap??!0,this.rows=[]}span(...e){let t=this.div(...e);t.span=!0}resetOutput(){this.rows=[]}div(...e){if(e.length===0&&this.div(``),this.wrap&&this.shouldApplyLayoutDSL(...e)&&typeof e[0]==`string`)return this.applyLayoutDSL(e[0]);let t=e.map(e=>typeof e==`string`?this.colFromString(e):e);return this.rows.push(t),t}shouldApplyLayoutDSL(...e){return e.length===1&&typeof e[0]==`string`&&/[\t\n]/.test(e[0])}applyLayoutDSL(e){let t=e.split(`
3
3
  `).map(e=>e.split(` `)),n=0;return t.forEach(e=>{e.length>1&&T.stringWidth(e[0])>n&&(n=Math.min(Math.floor(this.width*.5),T.stringWidth(e[0])))}),t.forEach(e=>{this.div(...e.map((t,r)=>({text:t.trim(),padding:this.measurePadding(t),width:r===0&&e.length>1?n:void 0})))}),this.rows[this.rows.length-1]}colFromString(e){return{text:e,padding:this.measurePadding(e)}}measurePadding(e){let t=T.stripAnsi(e);return[0,t.match(/\s*$/)[0].length,0,t.match(/^\s*/)[0].length]}toString(){let e=[];return this.rows.forEach(t=>{this.rowToString(t,e)}),e.filter(e=>!e.hidden).map(e=>e.text).join(`
4
4
  `)}rowToString(e,t){return this.rasterize(e).forEach((n,r)=>{let i=``;n.forEach((n,a)=>{let{width:o}=e[a],s=this.negatePadding(e[a]),c=n;if(s>T.stringWidth(n)&&(c+=` `.repeat(s-T.stringWidth(n))),e[a].align&&e[a].align!==`left`&&this.wrap){let t=le[e[a].align];c=t(c,s),T.stringWidth(c)<s&&(c+=` `.repeat((o||0)-T.stringWidth(c)-1))}let l=e[a].padding||[0,0,0,0];l[3]&&(i+=` `.repeat(l[3])),i+=de(e[a],c,`| `),i+=c,i+=de(e[a],c,` |`),l[1]&&(i+=` `.repeat(l[1])),r===0&&t.length>0&&(i=this.renderInline(i,t[t.length-1]))}),t.push({text:i.replace(/ +$/,``),span:e.span})}),t}renderInline(e,t){let n=e.match(/^ */),r=n?n[0].length:0,i=t.text,a=T.stringWidth(i.trimRight());return t.span?this.wrap?r<a?e:(t.hidden=!0,i.trimRight()+` `.repeat(r-a)+e.trimLeft()):(t.hidden=!0,i+e):e}rasterize(e){let t=[],n=this.columnWidths(e),r;return e.forEach((e,i)=>{e.width=n[i],r=this.wrap?T.wrap(e.text,this.negatePadding(e),{hard:!0}).split(`
5
5
  `):e.text.split(`
@@ -92,10 +92,10 @@ _{{app_name}}_yargs_completions()
92
92
  complete -o bashdefault -o default -F _{{app_name}}_yargs_completions {{app_name}}
93
93
  ###-end-{{app_name}}-completions-###
94
94
  `,r=this.shim.path.basename(e);return e.match(/\.js$/)&&(e=`./${e}`),n=n.replace(/{{app_name}}/g,r),n=n.replace(/{{completion_command}}/g,t),n.replace(/{{app_path}}/g,e)}registerFunction(e){this.customCompletionFunction=e}setParsed(e){this.aliases=e.aliases}};function Gt(e,t,n,r){return new Wt(e,t,n,r)}function Kt(e){return e.length<3}function qt(e){return e.length>3}function Jt(e,t){if(e.length===0)return t.length;if(t.length===0)return e.length;let n=[],r;for(r=0;r<=t.length;r++)n[r]=[r];let i;for(i=0;i<=e.length;i++)n[0][i]=i;for(r=1;r<=t.length;r++)for(i=1;i<=e.length;i++)t.charAt(r-1)===e.charAt(i-1)?n[r][i]=n[r-1][i-1]:r>1&&i>1&&t.charAt(r-2)===e.charAt(i-1)&&t.charAt(r-1)===e.charAt(i-2)?n[r][i]=n[r-2][i-2]+1:n[r][i]=Math.min(n[r-1][i-1]+1,Math.min(n[r][i-1]+1,n[r-1][i]+1));return n[t.length][e.length]}const Yt=[`$0`,`--`,`_`];function Xt(e,t,n){let r=n.y18n.__,i=n.y18n.__n,a={};a.nonOptionCount=function(n){let r=e.getDemandedCommands(),a=n._.length+(n[`--`]?n[`--`].length:0)-e.getInternalMethods().getContext().commands.length;r._&&(a<r._.min||a>r._.max)&&(a<r._.min?r._.minMsg===void 0?t.fail(i(`Not enough non-option arguments: got %s, need at least %s`,`Not enough non-option arguments: got %s, need at least %s`,a,a.toString(),r._.min.toString())):t.fail(r._.minMsg?r._.minMsg.replace(/\$0/g,a.toString()).replace(/\$1/,r._.min.toString()):null):a>r._.max&&(r._.maxMsg===void 0?t.fail(i(`Too many non-option arguments: got %s, maximum of %s`,`Too many non-option arguments: got %s, maximum of %s`,a,a.toString(),r._.max.toString())):t.fail(r._.maxMsg?r._.maxMsg.replace(/\$0/g,a.toString()).replace(/\$1/,r._.max.toString()):null)))},a.positionalCount=function(e,n){n<e&&t.fail(i(`Not enough non-option arguments: got %s, need at least %s`,`Not enough non-option arguments: got %s, need at least %s`,n,n+``,e+``))},a.requiredArguments=function(e,n){let r=null;for(let t of Object.keys(n))(!Object.prototype.hasOwnProperty.call(e,t)||e[t]===void 0)&&(r||={},r[t]=n[t]);if(r){let e=[];for(let t of Object.keys(r)){let n=r[t];n&&e.indexOf(n)<0&&e.push(n)}let n=e.length?`\n${e.join(`
95
- `)}`:``;t.fail(i(`Missing required argument: %s`,`Missing required arguments: %s`,Object.keys(r).length,Object.keys(r).join(`, `)+n))}},a.unknownArguments=function(n,r,o,s,c=!0){let l=e.getInternalMethods().getCommandInstance().getCommands(),u=[],d=e.getInternalMethods().getContext();if(Object.keys(n).forEach(t=>{!Yt.includes(t)&&!Object.prototype.hasOwnProperty.call(o,t)&&!Object.prototype.hasOwnProperty.call(e.getInternalMethods().getParseContext(),t)&&!a.isValidAndSomeAliasIsNotNew(t,r)&&u.push(t)}),c&&(d.commands.length>0||l.length>0||s)&&n._.slice(d.commands.length).forEach(e=>{l.includes(``+e)||u.push(``+e)}),c){let t=e.getDemandedCommands()._?.max||0,r=d.commands.length+t;r<n._.length&&n._.slice(r).forEach(e=>{e=String(e),!d.commands.includes(e)&&!u.includes(e)&&u.push(e)})}u.length&&t.fail(i(`Unknown argument: %s`,`Unknown arguments: %s`,u.length,u.map(e=>e.trim()?e:`"${e}"`).join(`, `)))},a.unknownCommands=function(n){let r=e.getInternalMethods().getCommandInstance().getCommands(),a=[],o=e.getInternalMethods().getContext();return(o.commands.length>0||r.length>0)&&n._.slice(o.commands.length).forEach(e=>{r.includes(``+e)||a.push(``+e)}),a.length>0?(t.fail(i(`Unknown command: %s`,`Unknown commands: %s`,a.length,a.join(`, `))),!0):!1},a.isValidAndSomeAliasIsNotNew=function(t,n){if(!Object.prototype.hasOwnProperty.call(n,t))return!1;let r=e.parsed.newAliases;return[t,...n[t]].some(e=>!Object.prototype.hasOwnProperty.call(r,e)||!r[t])},a.limitedChoices=function(n){let i=e.getOptions(),a={};if(!Object.keys(i.choices).length)return;Object.keys(n).forEach(e=>{Yt.indexOf(e)===-1&&Object.prototype.hasOwnProperty.call(i.choices,e)&&[].concat(n[e]).forEach(t=>{i.choices[e].indexOf(t)===-1&&t!==void 0&&(a[e]=(a[e]||[]).concat(t))})});let o=Object.keys(a);if(!o.length)return;let s=r(`Invalid values:`);o.forEach(e=>{s+=`\n ${r(`Argument: %s, Given: %s, Choices: %s`,e,t.stringifiedValues(a[e]),t.stringifiedValues(i.choices[e]))}`}),t.fail(s)};let o={};a.implies=function(t,r){P(`<string|object> [array|number|string]`,[t,r],arguments.length),typeof t==`object`?Object.keys(t).forEach(e=>{a.implies(e,t[e])}):(e.global(t),o[t]||(o[t]=[]),Array.isArray(r)?r.forEach(e=>a.implies(t,e)):(j(r,void 0,n),o[t].push(r)))},a.getImplied=function(){return o};function s(e,t){let n=Number(t);return t=isNaN(n)?t:n,typeof t==`number`?t=e._.length>=t:t.match(/^--no-.+/)?(t=t.match(/^--no-(.+)/)[1],t=!Object.prototype.hasOwnProperty.call(e,t)):t=Object.prototype.hasOwnProperty.call(e,t),t}a.implications=function(e){let n=[];if(Object.keys(o).forEach(t=>{let r=t;(o[t]||[]).forEach(t=>{let i=r,a=t;i=s(e,i),t=s(e,t),i&&!t&&n.push(` ${r} -> ${a}`)})}),n.length){let e=`${r(`Implications failed:`)}\n`;n.forEach(t=>{e+=t}),t.fail(e)}};let c={};a.conflicts=function(t,n){P(`<string|object> [array|string]`,[t,n],arguments.length),typeof t==`object`?Object.keys(t).forEach(e=>{a.conflicts(e,t[e])}):(e.global(t),c[t]||(c[t]=[]),Array.isArray(n)?n.forEach(e=>a.conflicts(t,e)):c[t].push(n))},a.getConflicting=()=>c,a.conflicting=function(i){Object.keys(i).forEach(e=>{c[e]&&c[e].forEach(n=>{n&&i[e]!==void 0&&i[n]!==void 0&&t.fail(r(`Arguments %s and %s are mutually exclusive`,e,n))})}),e.getInternalMethods().getParserConfiguration()[`strip-dashed`]&&Object.keys(c).forEach(e=>{c[e].forEach(a=>{a&&i[n.Parser.camelCase(e)]!==void 0&&i[n.Parser.camelCase(a)]!==void 0&&t.fail(r(`Arguments %s and %s are mutually exclusive`,e,a))})})},a.recommendCommands=function(e,n){n=n.sort((e,t)=>t.length-e.length);let i=null,a=1/0;for(let t=0,r;(r=n[t])!==void 0;t++){let t=Jt(e,r);t<=3&&t<a&&(a=t,i=r)}i&&t.fail(r(`Did you mean %s?`,i))},a.reset=function(e){return o=It(o,t=>!e[t]),c=It(c,t=>!e[t]),a};let l=[];return a.freeze=function(){l.push({implied:o,conflicting:c})},a.unfreeze=function(){let e=l.pop();j(e,void 0,n),{implied:o,conflicting:c}=e},a}let Zt=[],Qt;function $t(e,t,n,r){Qt=r;let i={};if(Object.prototype.hasOwnProperty.call(e,`extends`)){if(typeof e.extends!=`string`)return i;let a=/\.json|\..*rc$/.test(e.extends),o=null;if(a)o=tn(t,e.extends);else try{o=import.meta.resolve(e.extends)}catch{return e}en(o),Zt.push(o),i=a?JSON.parse(Qt.readFileSync(o,`utf8`)):r.require(e.extends),delete e.extends,i=$t(i,Qt.path.dirname(o),n,Qt)}return Zt=[],n?nn(i,e):Object.assign({},i,e)}function en(e){if(Zt.indexOf(e)>-1)throw new N(`Circular extended configurations: '${e}'.`)}function tn(e,t){return Qt.path.resolve(e,t)}function nn(e,t){let n={};function r(e){return e&&typeof e==`object`&&!Array.isArray(e)}Object.assign(n,e);for(let i of Object.keys(t))r(t[i])&&r(n[i])?n[i]=nn(e[i],t[i]):n[i]=t[i];return n}var F=function(e,t,n,r,i){if(r===`m`)throw TypeError(`Private method is not writable`);if(r===`a`&&!i)throw TypeError(`Private accessor was defined without a setter`);if(typeof t==`function`?e!==t||!i:!t.has(e))throw TypeError(`Cannot write private member to an object whose class did not declare it`);return r===`a`?i.call(e,n):i?i.value=n:t.set(e,n),n},I=function(e,t,n,r){if(n===`a`&&!r)throw TypeError(`Private accessor was defined without a getter`);if(typeof t==`function`?e!==t||!r:!t.has(e))throw TypeError(`Cannot read private member from an object whose class did not declare it`);return n===`m`?r:n===`a`?r.call(e):r?r.value:t.get(e)},L,rn,an,R,z,on,sn,cn,ln,B,un,V,H,U,W,dn,fn,G,K,pn,mn,q,hn,gn,_n,vn,yn,J,bn,xn,Sn,Y,Cn,X,Z;function wn(e){return(t=[],n=e.process.cwd(),r)=>{let i=new or(t,n,r,e);return Object.defineProperty(i,`argv`,{get:()=>i.parse(),enumerable:!0}),i.help(),i.version(),i}}const Tn=Symbol(`copyDoubleDash`),En=Symbol(`copyDoubleDash`),Dn=Symbol(`deleteFromParserHintObject`),On=Symbol(`emitWarning`),kn=Symbol(`freeze`),An=Symbol(`getDollarZero`),jn=Symbol(`getParserConfiguration`),Mn=Symbol(`getUsageConfiguration`),Nn=Symbol(`guessLocale`),Pn=Symbol(`guessVersion`),Fn=Symbol(`parsePositionalNumbers`),In=Symbol(`pkgUp`),Q=Symbol(`populateParserHintArray`),Ln=Symbol(`populateParserHintSingleValueDictionary`),Rn=Symbol(`populateParserHintArrayDictionary`),zn=Symbol(`populateParserHintDictionary`),Bn=Symbol(`sanitizeKey`),Vn=Symbol(`setKey`),Hn=Symbol(`unfreeze`),Un=Symbol(`validateAsync`),Wn=Symbol(`getCommandInstance`),Gn=Symbol(`getContext`),Kn=Symbol(`getHasOutput`),qn=Symbol(`getLoggerInstance`),Jn=Symbol(`getParseContext`),Yn=Symbol(`getUsageInstance`),Xn=Symbol(`getValidationInstance`),Zn=Symbol(`hasParseCallback`),Qn=Symbol(`isGlobalContext`),$n=Symbol(`postProcess`),er=Symbol(`rebase`),tr=Symbol(`reset`),nr=Symbol(`runYargsParserAndExecuteCommands`),rr=Symbol(`runValidation`),ir=Symbol(`setHasOutput`),ar=Symbol(`kTrackManuallySetKeys`);var or=class{constructor(e=[],t,n,r){this.customScriptName=!1,this.parsed=!1,L.set(this,void 0),rn.set(this,void 0),an.set(this,{commands:[],fullCommands:[]}),R.set(this,null),z.set(this,null),on.set(this,`show-hidden`),sn.set(this,null),cn.set(this,!0),ln.set(this,{}),B.set(this,!0),un.set(this,[]),V.set(this,void 0),H.set(this,{}),U.set(this,!1),W.set(this,null),dn.set(this,!0),fn.set(this,void 0),G.set(this,``),K.set(this,void 0),pn.set(this,void 0),mn.set(this,{}),q.set(this,null),hn.set(this,null),gn.set(this,{}),_n.set(this,{}),vn.set(this,void 0),yn.set(this,!1),J.set(this,void 0),bn.set(this,!1),xn.set(this,!1),Sn.set(this,!1),Y.set(this,void 0),Cn.set(this,{}),X.set(this,null),Z.set(this,void 0),F(this,J,r,`f`),F(this,vn,e,`f`),F(this,rn,t,`f`),F(this,pn,n,`f`),F(this,V,new Ct(this),`f`),this.$0=this[An](),this[tr](),F(this,L,I(this,L,`f`),`f`),F(this,Y,I(this,Y,`f`),`f`),F(this,Z,I(this,Z,`f`),`f`),F(this,K,I(this,K,`f`),`f`),I(this,K,`f`).showHiddenOpt=I(this,on,`f`),F(this,fn,this[En](),`f`),I(this,J,`f`).y18n.setLocale(`en_US`)}addHelpOpt(e,t){return P(`[string|boolean] [string]`,[e,t],arguments.length),I(this,W,`f`)&&(this[Dn](I(this,W,`f`)),F(this,W,null,`f`)),e===!1&&t===void 0?this:(F(this,W,typeof e==`string`?e:`help`,`f`),this.boolean(I(this,W,`f`)),this.describe(I(this,W,`f`),t||I(this,Y,`f`).deferY18nLookup(`Show help`)),this)}help(e,t){return this.addHelpOpt(e,t)}addShowHiddenOpt(e,t){if(P(`[string|boolean] [string]`,[e,t],arguments.length),e===!1&&t===void 0)return this;let n=typeof e==`string`?e:I(this,on,`f`);return this.boolean(n),this.describe(n,t||I(this,Y,`f`).deferY18nLookup(`Show hidden options`)),I(this,K,`f`).showHiddenOpt=n,this}showHidden(e,t){return this.addShowHiddenOpt(e,t)}alias(e,t){return P(`<object|string|array> [string|array]`,[e,t],arguments.length),this[Rn](this.alias.bind(this),`alias`,e,t),this}array(e){return P(`<array|string>`,[e],arguments.length),this[Q](`array`,e),this[ar](e),this}boolean(e){return P(`<array|string>`,[e],arguments.length),this[Q](`boolean`,e),this[ar](e),this}check(e,t){return P(`<function> [boolean]`,[e,t],arguments.length),this.middleware((t,n)=>Et(()=>e(t,n.getOptions()),n=>(n?(typeof n==`string`||n instanceof Error)&&I(this,Y,`f`).fail(n.toString(),n):I(this,Y,`f`).fail(I(this,J,`f`).y18n.__(`Argument check failed: %s`,e.toString())),t),e=>(I(this,Y,`f`).fail(e.message?e.message:e.toString(),e),t)),!1,t),this}choices(e,t){return P(`<object|string|array> [string|array]`,[e,t],arguments.length),this[Rn](this.choices.bind(this),`choices`,e,t),this}coerce(e,t){if(P(`<object|string|array> [function]`,[e,t],arguments.length),Array.isArray(e)){if(!t)throw new N(`coerce callback must be provided`);for(let n of e)this.coerce(n,t);return this}else if(typeof e==`object`){for(let t of Object.keys(e))this.coerce(t,e[t]);return this}if(!t)throw new N(`coerce callback must be provided`);let n=e;return I(this,K,`f`).key[n]=!0,I(this,V,`f`).addCoerceMiddleware((e,r)=>{let i=[n,...r.getAliases()[n]??[]].filter(t=>Object.prototype.hasOwnProperty.call(e,t));return i.length===0?e:Et(()=>t(e[i[0]]),t=>(i.forEach(n=>{e[n]=t}),e),e=>{throw new N(e.message)})},n),this}conflicts(e,t){return P(`<string|object> [string|array]`,[e,t],arguments.length),I(this,Z,`f`).conflicts(e,t),this}config(e=`config`,t,n){return P(`[object|string] [string|function] [function]`,[e,t,n],arguments.length),typeof e==`object`&&!Array.isArray(e)?(e=$t(e,I(this,rn,`f`),this[jn]()[`deep-merge-config`]||!1,I(this,J,`f`)),I(this,K,`f`).configObjects=(I(this,K,`f`).configObjects||[]).concat(e),this):(typeof t==`function`&&(n=t,t=void 0),this.describe(e,t||I(this,Y,`f`).deferY18nLookup(`Path to JSON config file`)),(Array.isArray(e)?e:[e]).forEach(e=>{I(this,K,`f`).config[e]=n||!0}),this)}completion(e,t,n){return P(`[string] [string|boolean|function] [function]`,[e,t,n],arguments.length),typeof t==`function`&&(n=t,t=void 0),F(this,z,e||I(this,z,`f`)||`completion`,`f`),!t&&t!==!1&&(t=`generate completion script`),this.command(I(this,z,`f`),t),n&&I(this,R,`f`).registerFunction(n),this}command(e,t,n,r,i,a){return P(`<string|array|object> [string|boolean] [function|object] [function] [array] [boolean|string]`,[e,t,n,r,i,a],arguments.length),I(this,L,`f`).addHandler(e,t,n,r,i,a),this}commands(e,t,n,r,i,a){return this.command(e,t,n,r,i,a)}commandDir(e,t){P(`<string> [object]`,[e,t],arguments.length);let n=I(this,pn,`f`)||I(this,J,`f`).require;return I(this,L,`f`).addDirectory(e,n,I(this,J,`f`).getCallerFile(),t),this}count(e){return P(`<array|string>`,[e],arguments.length),this[Q](`count`,e),this[ar](e),this}default(e,t,n){return P(`<object|string|array> [*] [string]`,[e,t,n],arguments.length),n&&(_t(e,I(this,J,`f`)),I(this,K,`f`).defaultDescription[e]=n),typeof t==`function`&&(_t(e,I(this,J,`f`)),I(this,K,`f`).defaultDescription[e]||(I(this,K,`f`).defaultDescription[e]=I(this,Y,`f`).functionDescription(t)),t=t.call()),this[Ln](this.default.bind(this),`default`,e,t),this}defaults(e,t,n){return this.default(e,t,n)}demandCommand(e=1,t,n,r){return P(`[number] [number|string] [string|null|undefined] [string|null|undefined]`,[e,t,n,r],arguments.length),typeof t!=`number`&&(n=t,t=1/0),this.global(`_`,!1),I(this,K,`f`).demandedCommands._={min:e,max:t,minMsg:n,maxMsg:r},this}demand(e,t,n){return Array.isArray(t)?(t.forEach(e=>{j(n,!0,I(this,J,`f`)),this.demandOption(e,n)}),t=1/0):typeof t!=`number`&&(n=t,t=1/0),typeof e==`number`?(j(n,!0,I(this,J,`f`)),this.demandCommand(e,t,n,n)):Array.isArray(e)?e.forEach(e=>{j(n,!0,I(this,J,`f`)),this.demandOption(e,n)}):typeof n==`string`?this.demandOption(e,n):(n===!0||n===void 0)&&this.demandOption(e),this}demandOption(e,t){return P(`<object|string|array> [string]`,[e,t],arguments.length),this[Ln](this.demandOption.bind(this),`demandedOptions`,e,t),this}deprecateOption(e,t){return P(`<string> [string|boolean]`,[e,t],arguments.length),I(this,K,`f`).deprecatedOptions[e]=t,this}describe(e,t){return P(`<object|string|array> [string]`,[e,t],arguments.length),this[Vn](e,!0),I(this,Y,`f`).describe(e,t),this}detectLocale(e){return P(`<boolean>`,[e],arguments.length),F(this,cn,e,`f`),this}env(e){return P(`[string|boolean]`,[e],arguments.length),e===!1?delete I(this,K,`f`).envPrefix:I(this,K,`f`).envPrefix=e||``,this}epilogue(e){return P(`<string>`,[e],arguments.length),I(this,Y,`f`).epilog(e),this}epilog(e){return this.epilogue(e)}example(e,t){return P(`<string|array> [string]`,[e,t],arguments.length),Array.isArray(e)?e.forEach(e=>this.example(...e)):I(this,Y,`f`).example(e,t),this}exit(e,t){F(this,U,!0,`f`),F(this,sn,t,`f`),I(this,B,`f`)&&I(this,J,`f`).process.exit(e)}exitProcess(e=!0){return P(`[boolean]`,[e],arguments.length),F(this,B,e,`f`),this}fail(e){if(P(`<function|boolean>`,[e],arguments.length),typeof e==`boolean`&&e!==!1)throw new N(`Invalid first argument. Expected function or boolean 'false'`);return I(this,Y,`f`).failFn(e),this}getAliases(){return this.parsed?this.parsed.aliases:{}}async getCompletion(e,t){return P(`<array> [function]`,[e,t],arguments.length),t?I(this,R,`f`).getCompletion(e,t):new Promise((t,n)=>{I(this,R,`f`).getCompletion(e,(e,r)=>{e?n(e):t(r)})})}getDemandedOptions(){return P([],0),I(this,K,`f`).demandedOptions}getDemandedCommands(){return P([],0),I(this,K,`f`).demandedCommands}getDeprecatedOptions(){return P([],0),I(this,K,`f`).deprecatedOptions}getDetectLocale(){return I(this,cn,`f`)}getExitProcess(){return I(this,B,`f`)}getGroups(){return Object.assign({},I(this,H,`f`),I(this,_n,`f`))}getHelp(){if(F(this,U,!0,`f`),!I(this,Y,`f`).hasCachedHelpMessage()){if(!this.parsed){let e=this[nr](I(this,vn,`f`),void 0,void 0,0,!0);if(M(e))return e.then(()=>I(this,Y,`f`).help())}let e=I(this,L,`f`).runDefaultBuilderOn(this);if(M(e))return e.then(()=>I(this,Y,`f`).help())}return Promise.resolve(I(this,Y,`f`).help())}getOptions(){return I(this,K,`f`)}getStrict(){return I(this,bn,`f`)}getStrictCommands(){return I(this,xn,`f`)}getStrictOptions(){return I(this,Sn,`f`)}global(e,t){return P(`<string|array> [boolean]`,[e,t],arguments.length),e=[].concat(e),t===!1?e.forEach(e=>{I(this,K,`f`).local.includes(e)||I(this,K,`f`).local.push(e)}):I(this,K,`f`).local=I(this,K,`f`).local.filter(t=>e.indexOf(t)===-1),this}group(e,t){P(`<string|array> <string>`,[e,t],arguments.length);let n=I(this,_n,`f`)[t]||I(this,H,`f`)[t];I(this,_n,`f`)[t]&&delete I(this,_n,`f`)[t];let r={};return I(this,H,`f`)[t]=(n||[]).concat(e).filter(e=>r[e]?!1:r[e]=!0),this}hide(e){return P(`<string>`,[e],arguments.length),I(this,K,`f`).hiddenOptions.push(e),this}implies(e,t){return P(`<string|object> [number|string|array]`,[e,t],arguments.length),I(this,Z,`f`).implies(e,t),this}locale(e){return P(`[string]`,[e],arguments.length),e===void 0?(this[Nn](),I(this,J,`f`).y18n.getLocale()):(F(this,cn,!1,`f`),I(this,J,`f`).y18n.setLocale(e),this)}middleware(e,t,n){return I(this,V,`f`).addMiddleware(e,!!t,n)}nargs(e,t){return P(`<string|object|array> [number]`,[e,t],arguments.length),this[Ln](this.nargs.bind(this),`narg`,e,t),this}normalize(e){return P(`<array|string>`,[e],arguments.length),this[Q](`normalize`,e),this}number(e){return P(`<array|string>`,[e],arguments.length),this[Q](`number`,e),this[ar](e),this}option(e,t){if(P(`<string|object> [object]`,[e,t],arguments.length),typeof e==`object`)Object.keys(e).forEach(t=>{this.options(t,e[t])});else{typeof t!=`object`&&(t={}),this[ar](e),I(this,X,`f`)&&(e===`version`||t?.alias===`version`)&&this[On]([`"version" is a reserved word.`,`Please do one of the following:`,'- Disable version with `yargs.version(false)` if using "version" as an option',"- Use the built-in `yargs.version` method instead (if applicable)",`- Use a different option key`,`https://yargs.js.org/docs/#api-reference-version`].join(`
96
- `),void 0,`versionWarning`),I(this,K,`f`).key[e]=!0,t.alias&&this.alias(e,t.alias);let n=t.deprecate||t.deprecated;n&&this.deprecateOption(e,n);let r=t.demand||t.required||t.require;r&&this.demand(e,r),t.demandOption&&this.demandOption(e,typeof t.demandOption==`string`?t.demandOption:void 0),t.conflicts&&this.conflicts(e,t.conflicts),`default`in t&&this.default(e,t.default),t.implies!==void 0&&this.implies(e,t.implies),t.nargs!==void 0&&this.nargs(e,t.nargs),t.config&&this.config(e,t.configParser),t.normalize&&this.normalize(e),t.choices&&this.choices(e,t.choices),t.coerce&&this.coerce(e,t.coerce),t.group&&this.group(e,t.group),(t.boolean||t.type===`boolean`)&&(this.boolean(e),t.alias&&this.boolean(t.alias)),(t.array||t.type===`array`)&&(this.array(e),t.alias&&this.array(t.alias)),(t.number||t.type===`number`)&&(this.number(e),t.alias&&this.number(t.alias)),(t.string||t.type===`string`)&&(this.string(e),t.alias&&this.string(t.alias)),(t.count||t.type===`count`)&&this.count(e),typeof t.global==`boolean`&&this.global(e,t.global),t.defaultDescription&&(I(this,K,`f`).defaultDescription[e]=t.defaultDescription),t.skipValidation&&this.skipValidation(e);let i=t.describe||t.description||t.desc,a=I(this,Y,`f`).getDescriptions();(!Object.prototype.hasOwnProperty.call(a,e)||typeof i==`string`)&&this.describe(e,i),t.hidden&&this.hide(e),t.requiresArg&&this.requiresArg(e)}return this}options(e,t){return this.option(e,t)}parse(e,t,n){P(`[string|array] [function|boolean|object] [function]`,[e,t,n],arguments.length),this[kn](),e===void 0&&(e=I(this,vn,`f`)),typeof t==`object`&&(F(this,hn,t,`f`),t=n),typeof t==`function`&&(F(this,q,t,`f`),t=!1),t||F(this,vn,e,`f`),I(this,q,`f`)&&F(this,B,!1,`f`);let r=this[nr](e,!!t),i=this.parsed;return I(this,R,`f`).setParsed(this.parsed),M(r)?r.then(e=>(I(this,q,`f`)&&I(this,q,`f`).call(this,I(this,sn,`f`),e,I(this,G,`f`)),e)).catch(e=>{throw I(this,q,`f`)&&I(this,q,`f`)(e,this.parsed.argv,I(this,G,`f`)),e}).finally(()=>{this[Hn](),this.parsed=i}):(I(this,q,`f`)&&I(this,q,`f`).call(this,I(this,sn,`f`),r,I(this,G,`f`)),this[Hn](),this.parsed=i,r)}parseAsync(e,t,n){let r=this.parse(e,t,n);return M(r)?r:Promise.resolve(r)}parseSync(e,t,n){let r=this.parse(e,t,n);if(M(r))throw new N(`.parseSync() must not be used with asynchronous builders, handlers, or middleware`);return r}parserConfiguration(e){return P(`<object>`,[e],arguments.length),F(this,mn,e,`f`),this}pkgConf(e,t){P(`<string> [string]`,[e,t],arguments.length);let n=null,r=this[In](t||I(this,rn,`f`));return r[e]&&typeof r[e]==`object`&&(n=$t(r[e],t||I(this,rn,`f`),this[jn]()[`deep-merge-config`]||!1,I(this,J,`f`)),I(this,K,`f`).configObjects=(I(this,K,`f`).configObjects||[]).concat(n)),this}positional(e,t){P(`<string> <object>`,[e,t],arguments.length);let n=[`default`,`defaultDescription`,`implies`,`normalize`,`choices`,`conflicts`,`coerce`,`type`,`describe`,`desc`,`description`,`alias`];t=It(t,(e,t)=>e===`type`&&![`string`,`number`,`boolean`].includes(t)?!1:n.includes(e));let r=I(this,an,`f`).fullCommands[I(this,an,`f`).fullCommands.length-1],i=r?I(this,L,`f`).cmdToParseOptions(r):{array:[],alias:{},default:{},demand:{}};return vt(i).forEach(n=>{let r=i[n];Array.isArray(r)?r.indexOf(e)!==-1&&(t[n]=!0):r[e]&&!(n in t)&&(t[n]=r[e])}),this.group(e,I(this,Y,`f`).getPositionalGroupName()),this.option(e,t)}recommendCommands(e=!0){return P(`[boolean]`,[e],arguments.length),F(this,yn,e,`f`),this}required(e,t,n){return this.demand(e,t,n)}require(e,t,n){return this.demand(e,t,n)}requiresArg(e){return P(`<array|string|object> [number]`,[e],arguments.length),typeof e==`string`&&I(this,K,`f`).narg[e]||this[Ln](this.requiresArg.bind(this),`narg`,e,NaN),this}showCompletionScript(e,t){return P(`[string] [string]`,[e,t],arguments.length),e||=this.$0,I(this,fn,`f`).log(I(this,R,`f`).generateCompletionScript(e,t||I(this,z,`f`)||`completion`)),this}showHelp(e){if(P(`[string|function]`,[e],arguments.length),F(this,U,!0,`f`),!I(this,Y,`f`).hasCachedHelpMessage()){if(!this.parsed){let t=this[nr](I(this,vn,`f`),void 0,void 0,0,!0);if(M(t))return t.then(()=>{I(this,Y,`f`).showHelp(e)}),this}let t=I(this,L,`f`).runDefaultBuilderOn(this);if(M(t))return t.then(()=>{I(this,Y,`f`).showHelp(e)}),this}return I(this,Y,`f`).showHelp(e),this}scriptName(e){return this.customScriptName=!0,this.$0=e,this}showHelpOnFail(e,t){return P(`[boolean|string] [string]`,[e,t],arguments.length),I(this,Y,`f`).showHelpOnFail(e,t),this}showVersion(e){return P(`[string|function]`,[e],arguments.length),I(this,Y,`f`).showVersion(e),this}skipValidation(e){return P(`<array|string>`,[e],arguments.length),this[Q](`skipValidation`,e),this}strict(e){return P(`[boolean]`,[e],arguments.length),F(this,bn,e!==!1,`f`),this}strictCommands(e){return P(`[boolean]`,[e],arguments.length),F(this,xn,e!==!1,`f`),this}strictOptions(e){return P(`[boolean]`,[e],arguments.length),F(this,Sn,e!==!1,`f`),this}string(e){return P(`<array|string>`,[e],arguments.length),this[Q](`string`,e),this[ar](e),this}terminalWidth(){return P([],0),I(this,J,`f`).process.stdColumns}updateLocale(e){return this.updateStrings(e)}updateStrings(e){return P(`<object>`,[e],arguments.length),F(this,cn,!1,`f`),I(this,J,`f`).y18n.updateLocale(e),this}usage(e,t,n,r){if(P(`<string|null|undefined> [string|boolean] [function|object] [function]`,[e,t,n,r],arguments.length),t!==void 0){if(j(e,null,I(this,J,`f`)),(e||``).match(/^\$0( |$)/))return this.command(e,t,n,r);throw new N(`.usage() description must start with $0 if being used as alias for .command()`)}else return I(this,Y,`f`).usage(e),this}usageConfiguration(e){return P(`<object>`,[e],arguments.length),F(this,Cn,e,`f`),this}version(e,t,n){let r=`version`;if(P(`[boolean|string] [string] [string]`,[e,t,n],arguments.length),I(this,X,`f`)&&(this[Dn](I(this,X,`f`)),I(this,Y,`f`).version(void 0),F(this,X,null,`f`)),arguments.length===0)n=this[Pn](),e=r;else if(arguments.length===1){if(e===!1)return this;n=e,e=r}else arguments.length===2&&(n=t,t=void 0);return F(this,X,typeof e==`string`?e:r,`f`),t||=I(this,Y,`f`).deferY18nLookup(`Show version number`),I(this,Y,`f`).version(n||void 0),this.boolean(I(this,X,`f`)),this.describe(I(this,X,`f`),t),this}wrap(e){return P(`<number|null|undefined>`,[e],arguments.length),I(this,Y,`f`).wrap(e),this}[(L=new WeakMap,rn=new WeakMap,an=new WeakMap,R=new WeakMap,z=new WeakMap,on=new WeakMap,sn=new WeakMap,cn=new WeakMap,ln=new WeakMap,B=new WeakMap,un=new WeakMap,V=new WeakMap,H=new WeakMap,U=new WeakMap,W=new WeakMap,dn=new WeakMap,fn=new WeakMap,G=new WeakMap,K=new WeakMap,pn=new WeakMap,mn=new WeakMap,q=new WeakMap,hn=new WeakMap,gn=new WeakMap,_n=new WeakMap,vn=new WeakMap,yn=new WeakMap,J=new WeakMap,bn=new WeakMap,xn=new WeakMap,Sn=new WeakMap,Y=new WeakMap,Cn=new WeakMap,X=new WeakMap,Z=new WeakMap,Tn)](e){if(!e._||!e[`--`])return e;e._.push.apply(e._,e[`--`]);try{delete e[`--`]}catch{}return e}[En](){return{log:(...e)=>{this[Zn]()||console.log(...e),F(this,U,!0,`f`),I(this,G,`f`).length&&F(this,G,I(this,G,`f`)+`
97
- `,`f`),F(this,G,I(this,G,`f`)+e.join(` `),`f`)},error:(...e)=>{this[Zn]()||console.error(...e),F(this,U,!0,`f`),I(this,G,`f`).length&&F(this,G,I(this,G,`f`)+`
98
- `,`f`),F(this,G,I(this,G,`f`)+e.join(` `),`f`)}}}[Dn](e){vt(I(this,K,`f`)).forEach(t=>{if((e=>e===`configObjects`)(t))return;let n=I(this,K,`f`)[t];Array.isArray(n)?n.includes(e)&&n.splice(n.indexOf(e),1):typeof n==`object`&&delete n[e]}),delete I(this,Y,`f`).getDescriptions()[e]}[On](e,t,n){I(this,ln,`f`)[n]||(I(this,J,`f`).process.emitWarning(e,t),I(this,ln,`f`)[n]=!0)}[kn](){I(this,un,`f`).push({options:I(this,K,`f`),configObjects:I(this,K,`f`).configObjects.slice(0),exitProcess:I(this,B,`f`),groups:I(this,H,`f`),strict:I(this,bn,`f`),strictCommands:I(this,xn,`f`),strictOptions:I(this,Sn,`f`),completionCommand:I(this,z,`f`),output:I(this,G,`f`),exitError:I(this,sn,`f`),hasOutput:I(this,U,`f`),parsed:this.parsed,parseFn:I(this,q,`f`),parseContext:I(this,hn,`f`)}),I(this,Y,`f`).freeze(),I(this,Z,`f`).freeze(),I(this,L,`f`).freeze(),I(this,V,`f`).freeze()}[An](){let e=``,t;return t=/\b(node|iojs|electron)(\.exe)?$/.test(I(this,J,`f`).process.argv()[0])?I(this,J,`f`).process.argv().slice(1,2):I(this,J,`f`).process.argv().slice(0,1),e=t.map(e=>{let t=this[er](I(this,rn,`f`),e);return e.match(/^(\/|([a-zA-Z]:)?\\)/)&&t.length<e.length?t:e}).join(` `).trim(),I(this,J,`f`).getEnv(`_`)&&I(this,J,`f`).getProcessArgvBin()===I(this,J,`f`).getEnv(`_`)&&(e=I(this,J,`f`).getEnv(`_`).replace(`${I(this,J,`f`).path.dirname(I(this,J,`f`).process.execPath())}/`,``)),e}[jn](){return I(this,mn,`f`)}[Mn](){return I(this,Cn,`f`)}[Nn](){if(!I(this,cn,`f`))return;let e=I(this,J,`f`).getEnv(`LC_ALL`)||I(this,J,`f`).getEnv(`LC_MESSAGES`)||I(this,J,`f`).getEnv(`LANG`)||I(this,J,`f`).getEnv(`LANGUAGE`)||`en_US`;this.locale(e.replace(/[.:].*/,``))}[Pn](){return this[In]().version||`unknown`}[Fn](e){let t=e[`--`]?e[`--`]:e._;for(let e=0,n;(n=t[e])!==void 0;e++)I(this,J,`f`).Parser.looksLikeNumber(n)&&Number.isSafeInteger(Math.floor(parseFloat(`${n}`)))&&(t[e]=Number(n));return e}[In](e){let t=e||`*`;if(I(this,gn,`f`)[t])return I(this,gn,`f`)[t];let n={};try{let t=e||I(this,J,`f`).mainFilename;I(this,J,`f`).path.extname(t)&&(t=I(this,J,`f`).path.dirname(t));let r=I(this,J,`f`).findUp(t,(e,t)=>{if(t.includes(`package.json`))return`package.json`});j(r,void 0,I(this,J,`f`)),n=JSON.parse(I(this,J,`f`).readFileSync(r,`utf8`))}catch{}return I(this,gn,`f`)[t]=n||{},I(this,gn,`f`)[t]}[Q](e,t){t=[].concat(t),t.forEach(t=>{t=this[Bn](t),I(this,K,`f`)[e].push(t)})}[Ln](e,t,n,r){this[zn](e,t,n,r,(e,t,n)=>{I(this,K,`f`)[e][t]=n})}[Rn](e,t,n,r){this[zn](e,t,n,r,(e,t,n)=>{I(this,K,`f`)[e][t]=(I(this,K,`f`)[e][t]||[]).concat(n)})}[zn](e,t,n,r,i){if(Array.isArray(n))n.forEach(t=>{e(t,r)});else if((e=>typeof e==`object`)(n))for(let t of vt(n))e(t,n[t]);else i(t,this[Bn](n),r)}[Bn](e){return e===`__proto__`?`___proto___`:e}[Vn](e,t){return this[Ln](this[Vn].bind(this),`key`,e,t),this}[Hn](){var e,t,n,r,i,a,o,s,c,l,u,d;let f=I(this,un,`f`).pop();j(f,void 0,I(this,J,`f`));let p;e=this,t=this,n=this,r=this,i=this,a=this,o=this,s=this,c=this,l=this,u=this,d=this,{options:{set value(t){F(e,K,t,`f`)}}.value,configObjects:p,exitProcess:{set value(e){F(t,B,e,`f`)}}.value,groups:{set value(e){F(n,H,e,`f`)}}.value,output:{set value(e){F(r,G,e,`f`)}}.value,exitError:{set value(e){F(i,sn,e,`f`)}}.value,hasOutput:{set value(e){F(a,U,e,`f`)}}.value,parsed:this.parsed,strict:{set value(e){F(o,bn,e,`f`)}}.value,strictCommands:{set value(e){F(s,xn,e,`f`)}}.value,strictOptions:{set value(e){F(c,Sn,e,`f`)}}.value,completionCommand:{set value(e){F(l,z,e,`f`)}}.value,parseFn:{set value(e){F(u,q,e,`f`)}}.value,parseContext:{set value(e){F(d,hn,e,`f`)}}.value}=f,I(this,K,`f`).configObjects=p,I(this,Y,`f`).unfreeze(),I(this,Z,`f`).unfreeze(),I(this,L,`f`).unfreeze(),I(this,V,`f`).unfreeze()}[Un](e,t){return Et(t,t=>(e(t),t))}getInternalMethods(){return{getCommandInstance:this[Wn].bind(this),getContext:this[Gn].bind(this),getHasOutput:this[Kn].bind(this),getLoggerInstance:this[qn].bind(this),getParseContext:this[Jn].bind(this),getParserConfiguration:this[jn].bind(this),getUsageConfiguration:this[Mn].bind(this),getUsageInstance:this[Yn].bind(this),getValidationInstance:this[Xn].bind(this),hasParseCallback:this[Zn].bind(this),isGlobalContext:this[Qn].bind(this),postProcess:this[$n].bind(this),reset:this[tr].bind(this),runValidation:this[rr].bind(this),runYargsParserAndExecuteCommands:this[nr].bind(this),setHasOutput:this[ir].bind(this)}}[Wn](){return I(this,L,`f`)}[Gn](){return I(this,an,`f`)}[Kn](){return I(this,U,`f`)}[qn](){return I(this,fn,`f`)}[Jn](){return I(this,hn,`f`)||{}}[Yn](){return I(this,Y,`f`)}[Xn](){return I(this,Z,`f`)}[Zn](){return!!I(this,q,`f`)}[Qn](){return I(this,dn,`f`)}[$n](e,t,n,r){return n||M(e)?e:(t||(e=this[Tn](e)),(this[jn]()[`parse-positional-numbers`]||this[jn]()[`parse-positional-numbers`]===void 0)&&(e=this[Fn](e)),r&&(e=Tt(e,this,I(this,V,`f`).getMiddleware(),!1)),e)}[tr](e={}){F(this,K,I(this,K,`f`)||{},`f`);let t={};t.local=I(this,K,`f`).local||[],t.configObjects=I(this,K,`f`).configObjects||[];let n={};return t.local.forEach(t=>{n[t]=!0,(e[t]||[]).forEach(e=>{n[e]=!0})}),Object.assign(I(this,_n,`f`),Object.keys(I(this,H,`f`)).reduce((e,t)=>{let r=I(this,H,`f`)[t].filter(e=>!(e in n));return r.length>0&&(e[t]=r),e},{})),F(this,H,{},`f`),[`array`,`boolean`,`string`,`skipValidation`,`count`,`normalize`,`number`,`hiddenOptions`].forEach(e=>{t[e]=(I(this,K,`f`)[e]||[]).filter(e=>!n[e])}),[`narg`,`key`,`alias`,`default`,`defaultDescription`,`config`,`choices`,`demandedOptions`,`demandedCommands`,`deprecatedOptions`].forEach(e=>{t[e]=It(I(this,K,`f`)[e],e=>!n[e])}),t.envPrefix=I(this,K,`f`).envPrefix,F(this,K,t,`f`),F(this,Y,I(this,Y,`f`)?I(this,Y,`f`).reset(n):zt(this,I(this,J,`f`)),`f`),F(this,Z,I(this,Z,`f`)?I(this,Z,`f`).reset(n):Xt(this,I(this,Y,`f`),I(this,J,`f`)),`f`),F(this,L,I(this,L,`f`)?I(this,L,`f`).reset():At(I(this,Y,`f`),I(this,Z,`f`),I(this,V,`f`),I(this,J,`f`)),`f`),I(this,R,`f`)||F(this,R,Gt(this,I(this,Y,`f`),I(this,L,`f`),I(this,J,`f`)),`f`),I(this,V,`f`).reset(),F(this,z,null,`f`),F(this,G,``,`f`),F(this,sn,null,`f`),F(this,U,!1,`f`),this.parsed=!1,this}[er](e,t){return I(this,J,`f`).path.relative(e,t)}[nr](e,t,n,r=0,i=!1){let a=!!n||i;e||=I(this,vn,`f`),I(this,K,`f`).__=I(this,J,`f`).y18n.__,I(this,K,`f`).configuration=this[jn]();let o=!!I(this,K,`f`).configuration[`populate--`],s=Object.assign({},I(this,K,`f`).configuration,{"populate--":!0}),c=I(this,J,`f`).Parser.detailed(e,Object.assign({},I(this,K,`f`),{configuration:{"parse-positional-numbers":!1,...s}})),l=Object.assign(c.argv,I(this,hn,`f`)),u,d=c.aliases,f=!1,p=!1;Object.keys(l).forEach(e=>{e===I(this,W,`f`)&&l[e]?f=!0:e===I(this,X,`f`)&&l[e]&&(p=!0)}),l.$0=this.$0,this.parsed=c,r===0&&I(this,Y,`f`).clearCachedHelpMessage();try{if(this[Nn](),t)return this[$n](l,o,!!n,!1);I(this,W,`f`)&&[I(this,W,`f`)].concat(d[I(this,W,`f`)]||[]).filter(e=>e.length>1).includes(``+l._[l._.length-1])&&(l._.pop(),f=!0),F(this,dn,!1,`f`);let s=I(this,L,`f`).getCommands(),m=I(this,R,`f`)?.completionKey?[I(this,R,`f`)?.completionKey,...this.getAliases()[I(this,R,`f`)?.completionKey]??[]].some(e=>Object.prototype.hasOwnProperty.call(l,e)):!1,h=f||m||i;if(l._.length){if(s.length){let e;for(let t=r||0,a;l._[t]!==void 0;t++)if(a=String(l._[t]),s.includes(a)&&a!==I(this,z,`f`)){let e=I(this,L,`f`).runCommand(a,this,c,t+1,i,f||p||i);return this[$n](e,o,!!n,!1)}else if(!e&&a!==I(this,z,`f`)){e=a;break}!I(this,L,`f`).hasDefaultCommand()&&I(this,yn,`f`)&&e&&!h&&I(this,Z,`f`).recommendCommands(e,s)}I(this,z,`f`)&&l._.includes(I(this,z,`f`))&&!m&&(I(this,B,`f`)&&Lt(!0),this.showCompletionScript(),this.exit(0))}if(I(this,L,`f`).hasDefaultCommand()&&!h){let e=I(this,L,`f`).runCommand(null,this,c,0,i,f||p||i);return this[$n](e,o,!!n,!1)}if(m){I(this,B,`f`)&&Lt(!0),e=[].concat(e);let t=e.slice(e.indexOf(`--${I(this,R,`f`).completionKey}`)+1);return I(this,R,`f`).getCompletion(t,(e,t)=>{if(e)throw new N(e.message);(t||[]).forEach(e=>{I(this,fn,`f`).log(e)}),this.exit(0)}),this[$n](l,!o,!!n,!1)}if(I(this,U,`f`)||(f?(I(this,B,`f`)&&Lt(!0),a=!0,this.showHelp(e=>{I(this,fn,`f`).log(e),this.exit(0)})):p&&(I(this,B,`f`)&&Lt(!0),a=!0,I(this,Y,`f`).showVersion(`log`),this.exit(0))),!a&&I(this,K,`f`).skipValidation.length>0&&(a=Object.keys(l).some(e=>I(this,K,`f`).skipValidation.indexOf(e)>=0&&l[e]===!0)),!a){if(c.error)throw new N(c.error.message);if(!m){let e=this[rr](d,{},c.error);n||(u=Tt(l,this,I(this,V,`f`).getMiddleware(),!0)),u=this[Un](e,u??l),M(u)&&!n&&(u=u.then(()=>Tt(l,this,I(this,V,`f`).getMiddleware(),!1)))}}}catch(e){if(e instanceof N)I(this,Y,`f`).fail(e.message,e);else throw e}return this[$n](u??l,o,!!n,!0)}[rr](e,t,n,r){let i={...this.getDemandedOptions()};return a=>{if(n)throw new N(n.message);I(this,Z,`f`).nonOptionCount(a),I(this,Z,`f`).requiredArguments(a,i);let o=!1;I(this,xn,`f`)&&(o=I(this,Z,`f`).unknownCommands(a)),I(this,bn,`f`)&&!o?I(this,Z,`f`).unknownArguments(a,e,t,!!r):I(this,Sn,`f`)&&I(this,Z,`f`).unknownArguments(a,e,{},!1,!1),I(this,Z,`f`).limitedChoices(a),I(this,Z,`f`).implications(a),I(this,Z,`f`).conflicting(a)}}[ir](){F(this,U,!0,`f`)}[ar](e){if(typeof e==`string`)I(this,K,`f`).key[e]=!0;else for(let t of e)I(this,K,`f`).key[t]=!0}};function sr(e){return!!e&&typeof e.getInternalMethods==`function`}const cr=wn(gt);function $(e,t,n){return{command:e,describe:t,builder:async e=>{let t=(await n()).default.builder;return typeof t==`function`?t(e):e},handler:async e=>{await(await n()).default.handler(e)}}}const lr=[{command:$(`abuse-reports`,`Submit and track abuse reports for phishing, malware, and other policy violations on Cloudflare-proxied sites`,()=>import(`./abuse-reports-ChV_yD7f.mjs`)),hideCommand:!0},{command:$(`accounts`,`Account settings, members, roles, subscriptions, and API tokens for your Cloudflare account`,()=>import(`./accounts-BCYecXFh.mjs`)),hideCommand:!1},{command:$(`acm`,`Advanced Certificate Manager — Total TLS auto-issuance and custom origin trust store certificates`,()=>import(`./acm-DD8zSds2.mjs`)),hideCommand:!0},{command:$(`addressing`,`IP address management — BYOIP prefixes, address maps, regional hostnames, and BGP advertisement control`,()=>import(`./addressing-D4Eqw5Bi.mjs`)),hideCommand:!0},{command:$(`ai`,`Run inference on Workers AI models — text generation, image classification, embeddings, and more`,()=>import(`./ai-DfXMOMx_.mjs`)),hideCommand:!0},{command:$(`ai-gateway`,`Proxy, cache, rate-limit, and observe requests to AI providers — OpenAI, Anthropic, Workers AI, and more`,()=>import(`./ai-gateway-DdRFthMo.mjs`)),hideCommand:!0},{command:$(`ai-search`,`Managed search-as-a-service — crawl, index, and query content with AI-powered relevance and chat completions`,()=>import(`./ai-search-C_68CDj1.mjs`)),hideCommand:!0},{command:$(`alerting`,`Notification policies, delivery destinations, silence windows, and alert history`,()=>import(`./alerting-DbhqhVCp.mjs`)),hideCommand:!0},{command:$(`analytics`,`Zone-level traffic analytics — dashboard summaries, per-colo breakdowns, and Argo latency metrics`,()=>import(`./analytics-BSBBc7ep.mjs`)),hideCommand:!0},{command:$(`api-gateway`,`Discover, monitor, and protect your API endpoints with schema validation, abuse detection, and routing`,()=>import(`./api-gateway-CZ4swbkQ.mjs`)),hideCommand:!0},{command:$(`argo`,`Network optimization features that speed up and improve reliability of traffic to your origins`,()=>import(`./argo-tms9ZwHO.mjs`)),hideCommand:!0},{command:$(`audit-logs`,`Immutable audit trail of actions taken by account members — who changed what and when`,()=>import(`./audit-logs-24qyW8cl.mjs`)),hideCommand:!0},{command:$(`autorag`,`AutoRAG — AI search, file management, job tracking, and sync for retrieval-augmented generation`,()=>import(`./autorag-kgNt06GD.mjs`)),hideCommand:!0},{command:$(`billing`,`Account billing profiles and usage data for Cloudflare subscriptions and add-on services`,()=>import(`./billing-lwBHNTXC.mjs`)),hideCommand:!0},{command:$(`bot-management`,`Bot detection and mitigation settings — configure bot scores, JavaScript detections, and challenge behavior`,()=>import(`./bot-management-LKf7BqUr.mjs`)),hideCommand:!0},{command:$(`botnet-feed`,`Botnet threat intelligence feeds — IP and ASN-level data on known command-and-control infrastructure`,()=>import(`./botnet-feed-nQ-gErTS.mjs`)),hideCommand:!0},{command:$(`brand-protection`,`Monitor the Internet for phishing sites, lookalike domains, and unauthorized use of your brand assets`,()=>import(`./brand-protection-DOKv9GRr.mjs`)),hideCommand:!0},{command:$(`browser-rendering`,`Headless browser API — render pages, take screenshots, generate PDFs, scrape content, and extract structured data`,()=>import(`./browser-rendering-CBExtgGt.mjs`)),hideCommand:!0},{command:$(`builds`,`Automated build and deployment pipeline for Workers — track builds, logs, and repo connections`,()=>import(`./builds-C_ySULja.mjs`)),hideCommand:!0},{command:$(`cache`,`Purge cached content and configure Cache Reserve, tiered caching, and variant serving`,()=>import(`./cache-BBiiNZHP.mjs`)),hideCommand:!0},{command:$(`calls`,`Real-time audio/video communication infrastructure — SFU apps for WebRTC and TURN relay keys`,()=>import(`./calls-DA5Xzwev.mjs`)),hideCommand:!0},{command:$(`certificate-authorities`,`Map client certificates to specific hostnames for mTLS authentication`,()=>import(`./certificate-authorities-sXyR_yGp.mjs`)),hideCommand:!0},{command:$(`client-certificates`,`Issue and manage client certificates for mutual TLS (mTLS) authentication on your zone`,()=>import(`./client-certificates-tV0aCLQJ.mjs`)),hideCommand:!0},{command:$(`cloud-connector`,`Route traffic from Cloudflare directly to cloud provider services (AWS, Azure, GCP) without origin servers`,()=>import(`./cloud-connector-DZfHcSso.mjs`)),hideCommand:!0},{command:$(`cloudforce-one`,`Threat intelligence platform — request investigations, scan indicators, and track threat events`,()=>import(`./cloudforce-one-y1PgQmI9.mjs`)),hideCommand:!0},{command:$(`connectivity`,`Service directory for network connectivity endpoints and their configurations`,()=>import(`./connectivity-8SOqaFDn.mjs`)),hideCommand:!0},{command:$(`content-scanning`,`Scan uploaded content in HTTP requests for malware and malicious payloads`,()=>import(`./content-scanning-B9y6K_G5.mjs`)),hideCommand:!0},{command:$(`custom-certificates`,`Upload and manage your own SSL/TLS certificates for a zone, with priority ordering`,()=>import(`./custom-certificates-sWksR8Ys.mjs`)),hideCommand:!0},{command:$(`custom-hostnames`,`Bring custom vanity domains to your SaaS zone with per-hostname SSL and origin mapping`,()=>import(`./custom-hostnames-91QZkdqN.mjs`)),hideCommand:!0},{command:$(`custom-nameservers`,`Vanity nameservers that use your own domain instead of Cloudflare-assigned NS records`,()=>import(`./custom-nameservers-DajZaZvE.mjs`)),hideCommand:!0},{command:$(`custom-pages`,`Custom error and challenge pages (1000s, WAF blocks, captchas) for zones and accounts`,()=>import(`./custom-pages-Cu7gmwzT.mjs`)),hideCommand:!0},{command:$(`d1`,`D1 is Cloudflare's managed, serverless database with SQLite's SQL semantics, built-in disaster recovery, and Worker and HTTP API access.`,()=>import(`./d1-H_VRsVmF.mjs`)),hideCommand:!0},{command:$(`dcv-delegation`,`Delegate domain control validation (DCV) to Cloudflare so certificates auto-renew without manual DNS changes`,()=>import(`./dcv-delegation-C-qhEYEZ.mjs`)),hideCommand:!0},{command:$(`diagnostics`,`Network diagnostic tools — traceroutes from Cloudflare's edge and endpoint health checks`,()=>import(`./diagnostics-D2B2LPZZ.mjs`)),hideCommand:!0},{command:$(`dispatch-namespaces`,`Workers for Platforms dispatch namespaces — isolate customer Workers for SaaS and multi-tenant deployments`,()=>import(`./dispatch-namespaces-CyrXBU_w.mjs`)),hideCommand:!0},{command:$(`dns`,`DNS management API for zones, records, DNSSEC, analytics, and zone transfers`,()=>import(`./dns-Bn9Uz_Nj.mjs`)),hideCommand:!1},{command:$(`dns-firewall`,`DNS proxy clusters that filter and forward DNS queries with DDoS protection and caching`,()=>import(`./dns-firewall-BslP4p-j.mjs`)),hideCommand:!0},{command:$(`durable-objects`,`Stateful serverless objects with transactional storage, ideal for coordination, sessions, and real-time collaboration`,()=>import(`./durable-objects-BN1ZnHhm.mjs`)),hideCommand:!0},{command:$(`email-routing`,`Route incoming emails to destination addresses using custom rules, catch-all handlers, and DNS configuration`,()=>import(`./email-routing-n2TnTaRR.mjs`)),hideCommand:!0},{command:$(`email-security`,`Cloud email security (Area 1) — investigate threats, manage allow/block policies, and detect phishing`,()=>import(`./email-security-C9SEx0kh.mjs`)),hideCommand:!0},{command:$(`email-sending`,`Send emails and manage sending subdomains`,()=>import(`./email-sending-DayZ7u3I.mjs`)),hideCommand:!0},{command:$(`filters`,`Filter expressions used by legacy firewall rules to match requests — prefer Rulesets for new configurations`,()=>import(`./filters-CI_XTgfQ.mjs`)),hideCommand:!0},{command:$(`firewall`,`Legacy firewall rules, zone lockdowns, access rules, user-agent blocking, and WAF packages`,()=>import(`./firewall-CcaayGig.mjs`)),hideCommand:!0},{command:$(`fraud`,`Fraud detection for login and signup flows — identify credential stuffing, account takeover, and fake accounts`,()=>import(`./fraud-Cr7aPCV8.mjs`)),hideCommand:!0},{command:$(`google-tag-gateway`,`Google Tag Gateway operations`,()=>import(`./google-tag-gateway-B3GpYgQ4.mjs`)),hideCommand:!0},{command:$(`healthchecks`,`Standalone health checks that monitor origin server availability from Cloudflare's edge`,()=>import(`./healthchecks-CVTsR_OC.mjs`)),hideCommand:!0},{command:$(`hostnames`,`Per-hostname TLS settings — minimum TLS version, ciphers, and certificate pinning overrides`,()=>import(`./hostnames-Bd_Wa5l6.mjs`)),hideCommand:!0},{command:$(`hyperdrive`,`Accelerate access to existing databases by caching queries and pooling connections at the edge`,()=>import(`./hyperdrive-BBJhEDZd.mjs`)),hideCommand:!0},{command:$(`iam`,`Identity and access management — permission groups, resource groups, user groups, and SSO connectors`,()=>import(`./iam-D_FN0pDF.mjs`)),hideCommand:!0},{command:$(`images`,`Store, resize, and deliver optimized images globally — variants, signing keys, and direct uploads`,()=>import(`./images-CAP2hAlZ.mjs`)),hideCommand:!0},{command:$(`intel`,`Threat intelligence lookups — IP reputation, domain info, ASN details, WHOIS, and indicator feeds`,()=>import(`./intel-CkxfzqmJ.mjs`)),hideCommand:!0},{command:$(`ips`,`List Cloudflare's IP ranges used for proxying traffic — useful for firewall allowlisting`,()=>import(`./ips-B0cK7D0_.mjs`)),hideCommand:!0},{command:$(`keyless-certificates`,`Use your own SSL certificates without exposing private keys — keys stay on your infrastructure`,()=>import(`./keyless-certificates-LcLmHZsX.mjs`)),hideCommand:!0},{command:$(`kv`,`Global, low-latency key-value storage for Workers — namespaces, keys, values, and bulk operations`,()=>import(`./kv-_TkUQ6fs.mjs`)),hideCommand:!0},{command:$(`leaked-credential-checks`,`Detect compromised credentials in login requests by checking against known breach databases`,()=>import(`./leaked-credential-checks-Dhvaen22.mjs`)),hideCommand:!0},{command:$(`load-balancers`,`Distribute traffic across origin pools with health monitoring, geo-steering, and failover`,()=>import(`./load-balancers-Ckr0UIpk.mjs`)),hideCommand:!0},{command:$(`logpush`,`Push Cloudflare logs to external storage destinations — R2, S3, Splunk, Datadog, and more`,()=>import(`./logpush-Cj946hxT.mjs`)),hideCommand:!0},{command:$(`logs`,`Log control, retention, and raw log access — CMB config, ray ID lookups, and received fields`,()=>import(`./logs-DgC9hjvJ.mjs`)),hideCommand:!0},{command:$(`magic-cloud-networking`,`Multi-cloud networking — discover cloud resources, manage on-ramps, and automate cross-cloud connectivity`,()=>import(`./magic-cloud-networking-WbDvPzuG.mjs`)),hideCommand:!0},{command:$(`magic-network-monitoring`,`Flow-based network traffic monitoring with configurable alerting rules and VPC flow ingestion`,()=>import(`./magic-network-monitoring-BcHShvGQ.mjs`)),hideCommand:!0},{command:$(`magic-transit`,`DDoS-protected network transit — GRE/IPsec tunnels, static routes, Magic WAN sites, connectors, and packet captures`,()=>import(`./magic-transit-B8sCOkt_.mjs`)),hideCommand:!0},{command:$(`managed-transforms`,`Cloudflare-managed HTTP header transforms — automatically add security headers, remove server info, etc.`,()=>import(`./managed-transforms-BpOr-8HY.mjs`)),hideCommand:!0},{command:$(`mtls-certificates`,`Upload and manage mTLS certificates used by API Shield, Workers, and Gateway for client authentication`,()=>import(`./mtls-certificates-fOul8D5g.mjs`)),hideCommand:!0},{command:$(`network-interconnects`,`Physical and virtual private interconnects between your infrastructure and Cloudflare's network`,()=>import(`./network-interconnects-BSW65xlh.mjs`)),hideCommand:!0},{command:$(`organizations`,`Multi-user organizations that group accounts, members, and shared settings under a single entity`,()=>import(`./organizations-T4vKGFAb.mjs`)),hideCommand:!0},{command:$(`origin-ca-certificates`,`Free Cloudflare-signed certificates installed on your origin server for Full (strict) SSL mode`,()=>import(`./origin-ca-certificates-ChM0lZ64.mjs`)),hideCommand:!0},{command:$(`origin-post-quantum-encryption`,`Enable post-quantum key exchange for connections between Cloudflare and your origin server`,()=>import(`./origin-post-quantum-encryption-C7o26ARh.mjs`)),hideCommand:!0},{command:$(`origin-tls-client-auth`,`Authenticated Origin Pulls — require Cloudflare to present a client certificate when connecting to your origin`,()=>import(`./origin-tls-client-auth-D32dpZk_.mjs`)),hideCommand:!0},{command:$(`page-rules`,`Legacy URL-pattern rules that override zone settings for matching requests — prefer Rules/Transform Rules instead`,()=>import(`./page-rules-RFoj8CjN.mjs`)),hideCommand:!0},{command:$(`page-shield`,`Client-side security — monitor JavaScript, connections, and cookies on your pages for supply-chain attacks`,()=>import(`./page-shield-VTktzKDN.mjs`)),hideCommand:!0},{command:$(`pages`,`Full-stack application hosting with Git-integrated builds, preview deployments, and custom domains`,()=>import(`./pages-L1ITjXDZ.mjs`)),hideCommand:!0},{command:$(`pipelines`,`Ingest, transform, and route event streams into R2, analytics, or other destinations in real time`,()=>import(`./pipelines-BPO0Lnil.mjs`)),hideCommand:!0},{command:$(`queues`,`Reliable message queuing between Workers — produce, consume, and batch-process messages at scale`,()=>import(`./queues-B0C06L9r.mjs`)),hideCommand:!0},{command:$(`r2`,`S3-compatible object storage with zero egress fees — buckets, lifecycle rules, event notifications, and data migration`,()=>import(`./r2-DP020Tmq.mjs`)),hideCommand:!0},{command:$(`r2-data-catalog`,`Iceberg-compatible data catalog for R2 — organize objects into tables and namespaces for SQL query engines`,()=>import(`./r2-data-catalog-Dmipvz5F.mjs`)),hideCommand:!0},{command:$(`radar`,`Internet-wide traffic intelligence — BGP, DNS, HTTP trends, attack data, and network quality insights`,()=>import(`./radar-DR3VMknH.mjs`)),hideCommand:!0},{command:$(`rate-limits`,`Legacy per-zone rate limiting rules — prefer Advanced Rate Limiting in Rulesets for new configurations`,()=>import(`./rate-limits-DnHPBPgU.mjs`)),hideCommand:!0},{command:$(`realtime-kit`,`Real-time video and audio — meetings, livestreams, recordings, and session management via Cloudflare Calls`,()=>import(`./realtime-kit-C430aq2d.mjs`)),hideCommand:!0},{command:$(`registrar`,`Domain registration and transfer management through Cloudflare Registrar`,()=>import(`./registrar-7Qy50zbW.mjs`)),hideCommand:!1},{command:$(`request-tracers`,`Trace how a request would be processed through Cloudflare's rules and configuration pipeline`,()=>import(`./request-tracers-sv99NDIl.mjs`)),hideCommand:!0},{command:$(`resource-sharing`,`Share Cloudflare resources (zones, accounts) across organizations with granular access controls`,()=>import(`./resource-sharing-uEjC7lnQ.mjs`)),hideCommand:!0},{command:$(`resource-tagging`,`Tag accounts and zones with key-value metadata for organization, filtering, and policy targeting`,()=>import(`./resource-tagging-CiODdP3N.mjs`)),hideCommand:!0},{command:$(`rules`,`Account-level IP lists, hostname lists, and other reusable lists referenced by firewall rules and rulesets`,()=>import(`./rules-FXAyTrwk.mjs`)),hideCommand:!0},{command:$(`rulesets`,`Versioned collections of rules that control how Cloudflare processes traffic — WAF, transform, redirect, and more`,()=>import(`./rulesets-B6aUsFFB.mjs`)),hideCommand:!0},{command:$(`rum`,`Real User Measurement (Web Analytics) — track page loads, Core Web Vitals, and visitor metrics`,()=>import(`./rum-CyyGJhp5.mjs`)),hideCommand:!0},{command:$(`schema-validation`,`API schema validation settings — enforce request/response schemas and configure validation behavior`,()=>import(`./schema-validation-ByU49h--.mjs`)),hideCommand:!0},{command:$(`scim`,`SCIM 2.0 provisioning — manage users, groups, and identity provider sync for your account`,()=>import(`./scim-DdTS65_C.mjs`)),hideCommand:!0},{command:$(`scm`,`Source code management connections — link Git providers, browse repos, create pull requests, and manage grants`,()=>import(`./scm-CilfPOue.mjs`)),hideCommand:!0},{command:$(`secrets-store`,`Centralized secret management — store API keys, tokens, and credentials for use across Workers and other products`,()=>import(`./secrets-store-ClOUVhBJ.mjs`)),hideCommand:!0},{command:$(`security-center`,`Security posture dashboard — view and manage security insights, misconfigurations, and vulnerabilities`,()=>import(`./security-center-4iSBqTrf.mjs`)),hideCommand:!0},{command:$(`security-txt`,`Manage the /.well-known/security.txt file that tells security researchers how to report vulnerabilities`,()=>import(`./security-txt-kGxdkDY6.mjs`)),hideCommand:!0},{command:$(`smart-shield`,`Smart Shield settings, health checks, and cache reserve management`,()=>import(`./smart-shield-B-SQd2Qp.mjs`)),hideCommand:!0},{command:$(`snippets`,`Lightweight JavaScript snippets that run on requests before Workers — for quick header modifications and redirects`,()=>import(`./snippets-Aq58ojqw.mjs`)),hideCommand:!0},{command:$(`spectrum`,`Proxy and protect arbitrary TCP/UDP applications through Cloudflare's network with DDoS mitigation`,()=>import(`./spectrum-0gFvGI6y.mjs`)),hideCommand:!0},{command:$(`speed`,`Observatory speed tests — run Lighthouse audits, track performance trends, and schedule recurring tests`,()=>import(`./speed-DAZU8w3T.mjs`)),hideCommand:!0},{command:$(`ssl`,`SSL/TLS certificate management — certificate packs, Universal SSL, verification, and TLS mode recommendations`,()=>import(`./ssl-BRlXa-5w.mjs`)),hideCommand:!0},{command:$(`stream`,`Video encoding, storage, and delivery — upload, live-stream, clip, caption, and embed video at scale`,()=>import(`./stream-BAxsVeBX.mjs`)),hideCommand:!0},{command:$(`tenants`,`Multi-tenant account management — manage tenant accounts, entitlements, and memberships`,()=>import(`./tenants-Df6xDqoA.mjs`)),hideCommand:!0},{command:$(`token-validation`,`Validate JWT tokens at the edge — configure token sources, signing keys, and validation rules`,()=>import(`./token-validation-pO4dCjCy.mjs`)),hideCommand:!0},{command:$(`turnstile`,`CAPTCHA-free bot verification widgets that protect forms and APIs without degrading user experience`,()=>import(`./turnstile-B1dmO8wE.mjs`)),hideCommand:!0},{command:$(`url-normalization`,`Normalize incoming request URLs to a consistent format before rule evaluation and caching`,()=>import(`./url-normalization-sUDVmrUt.mjs`)),hideCommand:!0},{command:$(`url-scanner`,`Scan URLs for phishing, malware, and other threats — submit scans and retrieve detailed results`,()=>import(`./url-scanner-CwOKRkYo.mjs`)),hideCommand:!0},{command:$(`user`,`Your Cloudflare user profile, invitations, organizations, billing, and personal API tokens`,()=>import(`./user-D_UrIdNq.mjs`)),hideCommand:!0},{command:$(`vectorize`,`Globally distributed vector database for building semantic search, recommendations, and RAG applications on Workers`,()=>import(`./vectorize-BEbBn9G9.mjs`)),hideCommand:!0},{command:$(`vuln-scanner`,`Vulnerability scanning for web applications — manage scans, credential sets, and scan reports`,()=>import(`./vuln-scanner-Br_2lQp1.mjs`)),hideCommand:!0},{command:$(`waiting-rooms`,`Virtual queues that throttle traffic to your site during peak demand with customizable waiting pages`,()=>import(`./waiting-rooms-BQC-urV4.mjs`)),hideCommand:!0},{command:$(`web3`,`Web3 gateways — serve IPFS and Ethereum content through custom hostnames on Cloudflare`,()=>import(`./web3-CIH2iQeX.mjs`)),hideCommand:!0},{command:$(`workers`,`Deploy and manage serverless JavaScript/WASM applications on Cloudflare's global network`,()=>import(`./workers-B9EvrpH3.mjs`)),hideCommand:!0},{command:$(`workers-builds`,`Automated build and deployment pipeline for Workers — track builds, logs, and repo connections`,()=>import(`./workers-builds-DzWSiRd2.mjs`)),hideCommand:!0},{command:$(`workflows`,`Durable, multi-step workflows that run on Workers with automatic retries and state persistence`,()=>import(`./workflows-aD81gA4k.mjs`)),hideCommand:!0},{command:$(`zaraz`,`Server-side tag manager — load third-party tools (analytics, pixels, etc.) from Cloudflare's edge without client-side JS`,()=>import(`./zaraz-Cg1dsvrZ.mjs`)),hideCommand:!0},{command:$(`zero-trust`,`Cloudflare's SASE platform — secure access, device posture, DLP, tunnels, gateway policies, and network segmentation`,()=>import(`./zero-trust-D-xQXWcy.mjs`)),hideCommand:!0},{command:$(`zones`,`Zones are domains on Cloudflare — list, create, and configure domain settings`,()=>import(`./zones-DQzucJDd.mjs`)),hideCommand:!1}];function ur(e){try{let t=new URL(e);return`${t.pathname.replace(/^\/client\/v\d+/,``)}${t.search}`}catch{return e}}function dr(e){if(s(a),e instanceof n){let t=u(),n=pr(e.status),r=[];if(e.error){let t=e.error;Array.isArray(t.errors)&&(r=t.errors)}let i=e.request?`${e.request.method} ${ur(e.request.url)}`:void 0,a=`${e.status} ${n}`,o=i?`${a} · ${i}`:a,s=t.dim(o),c=``;return c=r.length>0?r.map((e,n)=>{let i=typeof e.code==`number`?t.hex(d.error).bold(`[${e.code}]`):t.hex(d.error).bold(`[error]`),a=t.bold(e.message??``);return n===r.length-1?`${i} ${a}\n${s}`:`${i} ${a}`}).join(`
95
+ `)}`:``;t.fail(i(`Missing required argument: %s`,`Missing required arguments: %s`,Object.keys(r).length,Object.keys(r).join(`, `)+n))}},a.unknownArguments=function(n,r,o,s,c=!0){let l=e.getInternalMethods().getCommandInstance().getCommands(),u=[],d=e.getInternalMethods().getContext();if(Object.keys(n).forEach(t=>{!Yt.includes(t)&&!Object.prototype.hasOwnProperty.call(o,t)&&!Object.prototype.hasOwnProperty.call(e.getInternalMethods().getParseContext(),t)&&!a.isValidAndSomeAliasIsNotNew(t,r)&&u.push(t)}),c&&(d.commands.length>0||l.length>0||s)&&n._.slice(d.commands.length).forEach(e=>{l.includes(``+e)||u.push(``+e)}),c){let t=e.getDemandedCommands()._?.max||0,r=d.commands.length+t;r<n._.length&&n._.slice(r).forEach(e=>{e=String(e),!d.commands.includes(e)&&!u.includes(e)&&u.push(e)})}u.length&&t.fail(i(`Unknown argument: %s`,`Unknown arguments: %s`,u.length,u.map(e=>e.trim()?e:`"${e}"`).join(`, `)))},a.unknownCommands=function(n){let r=e.getInternalMethods().getCommandInstance().getCommands(),a=[],o=e.getInternalMethods().getContext();return(o.commands.length>0||r.length>0)&&n._.slice(o.commands.length).forEach(e=>{r.includes(``+e)||a.push(``+e)}),a.length>0?(t.fail(i(`Unknown command: %s`,`Unknown commands: %s`,a.length,a.join(`, `))),!0):!1},a.isValidAndSomeAliasIsNotNew=function(t,n){if(!Object.prototype.hasOwnProperty.call(n,t))return!1;let r=e.parsed.newAliases;return[t,...n[t]].some(e=>!Object.prototype.hasOwnProperty.call(r,e)||!r[t])},a.limitedChoices=function(n){let i=e.getOptions(),a={};if(!Object.keys(i.choices).length)return;Object.keys(n).forEach(e=>{Yt.indexOf(e)===-1&&Object.prototype.hasOwnProperty.call(i.choices,e)&&[].concat(n[e]).forEach(t=>{i.choices[e].indexOf(t)===-1&&t!==void 0&&(a[e]=(a[e]||[]).concat(t))})});let o=Object.keys(a);if(!o.length)return;let s=r(`Invalid values:`);o.forEach(e=>{s+=`\n ${r(`Argument: %s, Given: %s, Choices: %s`,e,t.stringifiedValues(a[e]),t.stringifiedValues(i.choices[e]))}`}),t.fail(s)};let o={};a.implies=function(t,r){P(`<string|object> [array|number|string]`,[t,r],arguments.length),typeof t==`object`?Object.keys(t).forEach(e=>{a.implies(e,t[e])}):(e.global(t),o[t]||(o[t]=[]),Array.isArray(r)?r.forEach(e=>a.implies(t,e)):(j(r,void 0,n),o[t].push(r)))},a.getImplied=function(){return o};function s(e,t){let n=Number(t);return t=isNaN(n)?t:n,typeof t==`number`?t=e._.length>=t:t.match(/^--no-.+/)?(t=t.match(/^--no-(.+)/)[1],t=!Object.prototype.hasOwnProperty.call(e,t)):t=Object.prototype.hasOwnProperty.call(e,t),t}a.implications=function(e){let n=[];if(Object.keys(o).forEach(t=>{let r=t;(o[t]||[]).forEach(t=>{let i=r,a=t;i=s(e,i),t=s(e,t),i&&!t&&n.push(` ${r} -> ${a}`)})}),n.length){let e=`${r(`Implications failed:`)}\n`;n.forEach(t=>{e+=t}),t.fail(e)}};let c={};a.conflicts=function(t,n){P(`<string|object> [array|string]`,[t,n],arguments.length),typeof t==`object`?Object.keys(t).forEach(e=>{a.conflicts(e,t[e])}):(e.global(t),c[t]||(c[t]=[]),Array.isArray(n)?n.forEach(e=>a.conflicts(t,e)):c[t].push(n))},a.getConflicting=()=>c,a.conflicting=function(i){Object.keys(i).forEach(e=>{c[e]&&c[e].forEach(n=>{n&&i[e]!==void 0&&i[n]!==void 0&&t.fail(r(`Arguments %s and %s are mutually exclusive`,e,n))})}),e.getInternalMethods().getParserConfiguration()[`strip-dashed`]&&Object.keys(c).forEach(e=>{c[e].forEach(a=>{a&&i[n.Parser.camelCase(e)]!==void 0&&i[n.Parser.camelCase(a)]!==void 0&&t.fail(r(`Arguments %s and %s are mutually exclusive`,e,a))})})},a.recommendCommands=function(e,n){n=n.sort((e,t)=>t.length-e.length);let i=null,a=1/0;for(let t=0,r;(r=n[t])!==void 0;t++){let t=Jt(e,r);t<=3&&t<a&&(a=t,i=r)}i&&t.fail(r(`Did you mean %s?`,i))},a.reset=function(e){return o=It(o,t=>!e[t]),c=It(c,t=>!e[t]),a};let l=[];return a.freeze=function(){l.push({implied:o,conflicting:c})},a.unfreeze=function(){let e=l.pop();j(e,void 0,n),{implied:o,conflicting:c}=e},a}let Zt=[],Qt;function $t(e,t,n,r){Qt=r;let i={};if(Object.prototype.hasOwnProperty.call(e,`extends`)){if(typeof e.extends!=`string`)return i;let a=/\.json|\..*rc$/.test(e.extends),o=null;if(a)o=tn(t,e.extends);else try{o=import.meta.resolve(e.extends)}catch{return e}en(o),Zt.push(o),i=a?JSON.parse(Qt.readFileSync(o,`utf8`)):r.require(e.extends),delete e.extends,i=$t(i,Qt.path.dirname(o),n,Qt)}return Zt=[],n?nn(i,e):Object.assign({},i,e)}function en(e){if(Zt.indexOf(e)>-1)throw new N(`Circular extended configurations: '${e}'.`)}function tn(e,t){return Qt.path.resolve(e,t)}function nn(e,t){let n={};function r(e){return e&&typeof e==`object`&&!Array.isArray(e)}Object.assign(n,e);for(let i of Object.keys(t))r(t[i])&&r(n[i])?n[i]=nn(e[i],t[i]):n[i]=t[i];return n}var F=function(e,t,n,r,i){if(r===`m`)throw TypeError(`Private method is not writable`);if(r===`a`&&!i)throw TypeError(`Private accessor was defined without a setter`);if(typeof t==`function`?e!==t||!i:!t.has(e))throw TypeError(`Cannot write private member to an object whose class did not declare it`);return r===`a`?i.call(e,n):i?i.value=n:t.set(e,n),n},I=function(e,t,n,r){if(n===`a`&&!r)throw TypeError(`Private accessor was defined without a getter`);if(typeof t==`function`?e!==t||!r:!t.has(e))throw TypeError(`Cannot read private member from an object whose class did not declare it`);return n===`m`?r:n===`a`?r.call(e):r?r.value:t.get(e)},L,rn,an,R,z,on,B,sn,cn,V,ln,H,U,W,G,un,dn,K,q,fn,pn,J,mn,hn,gn,_n,vn,Y,yn,bn,xn,X,Sn,Z,Q;function Cn(e){return(t=[],n=e.process.cwd(),r)=>{let i=new or(t,n,r,e);return Object.defineProperty(i,`argv`,{get:()=>i.parse(),enumerable:!0}),i.help(),i.version(),i}}const wn=Symbol(`copyDoubleDash`),Tn=Symbol(`copyDoubleDash`),En=Symbol(`deleteFromParserHintObject`),Dn=Symbol(`emitWarning`),On=Symbol(`freeze`),kn=Symbol(`getDollarZero`),An=Symbol(`getParserConfiguration`),jn=Symbol(`getUsageConfiguration`),Mn=Symbol(`guessLocale`),Nn=Symbol(`guessVersion`),Pn=Symbol(`parsePositionalNumbers`),Fn=Symbol(`pkgUp`),In=Symbol(`populateParserHintArray`),Ln=Symbol(`populateParserHintSingleValueDictionary`),Rn=Symbol(`populateParserHintArrayDictionary`),zn=Symbol(`populateParserHintDictionary`),Bn=Symbol(`sanitizeKey`),Vn=Symbol(`setKey`),Hn=Symbol(`unfreeze`),Un=Symbol(`validateAsync`),Wn=Symbol(`getCommandInstance`),Gn=Symbol(`getContext`),Kn=Symbol(`getHasOutput`),qn=Symbol(`getLoggerInstance`),Jn=Symbol(`getParseContext`),Yn=Symbol(`getUsageInstance`),Xn=Symbol(`getValidationInstance`),Zn=Symbol(`hasParseCallback`),Qn=Symbol(`isGlobalContext`),$n=Symbol(`postProcess`),er=Symbol(`rebase`),tr=Symbol(`reset`),nr=Symbol(`runYargsParserAndExecuteCommands`),rr=Symbol(`runValidation`),ir=Symbol(`setHasOutput`),ar=Symbol(`kTrackManuallySetKeys`);var or=class{constructor(e=[],t,n,r){this.customScriptName=!1,this.parsed=!1,L.set(this,void 0),rn.set(this,void 0),an.set(this,{commands:[],fullCommands:[]}),R.set(this,null),z.set(this,null),on.set(this,`show-hidden`),B.set(this,null),sn.set(this,!0),cn.set(this,{}),V.set(this,!0),ln.set(this,[]),H.set(this,void 0),U.set(this,{}),W.set(this,!1),G.set(this,null),un.set(this,!0),dn.set(this,void 0),K.set(this,``),q.set(this,void 0),fn.set(this,void 0),pn.set(this,{}),J.set(this,null),mn.set(this,null),hn.set(this,{}),gn.set(this,{}),_n.set(this,void 0),vn.set(this,!1),Y.set(this,void 0),yn.set(this,!1),bn.set(this,!1),xn.set(this,!1),X.set(this,void 0),Sn.set(this,{}),Z.set(this,null),Q.set(this,void 0),F(this,Y,r,`f`),F(this,_n,e,`f`),F(this,rn,t,`f`),F(this,fn,n,`f`),F(this,H,new Ct(this),`f`),this.$0=this[kn](),this[tr](),F(this,L,I(this,L,`f`),`f`),F(this,X,I(this,X,`f`),`f`),F(this,Q,I(this,Q,`f`),`f`),F(this,q,I(this,q,`f`),`f`),I(this,q,`f`).showHiddenOpt=I(this,on,`f`),F(this,dn,this[Tn](),`f`),I(this,Y,`f`).y18n.setLocale(`en_US`)}addHelpOpt(e,t){return P(`[string|boolean] [string]`,[e,t],arguments.length),I(this,G,`f`)&&(this[En](I(this,G,`f`)),F(this,G,null,`f`)),e===!1&&t===void 0?this:(F(this,G,typeof e==`string`?e:`help`,`f`),this.boolean(I(this,G,`f`)),this.describe(I(this,G,`f`),t||I(this,X,`f`).deferY18nLookup(`Show help`)),this)}help(e,t){return this.addHelpOpt(e,t)}addShowHiddenOpt(e,t){if(P(`[string|boolean] [string]`,[e,t],arguments.length),e===!1&&t===void 0)return this;let n=typeof e==`string`?e:I(this,on,`f`);return this.boolean(n),this.describe(n,t||I(this,X,`f`).deferY18nLookup(`Show hidden options`)),I(this,q,`f`).showHiddenOpt=n,this}showHidden(e,t){return this.addShowHiddenOpt(e,t)}alias(e,t){return P(`<object|string|array> [string|array]`,[e,t],arguments.length),this[Rn](this.alias.bind(this),`alias`,e,t),this}array(e){return P(`<array|string>`,[e],arguments.length),this[In](`array`,e),this[ar](e),this}boolean(e){return P(`<array|string>`,[e],arguments.length),this[In](`boolean`,e),this[ar](e),this}check(e,t){return P(`<function> [boolean]`,[e,t],arguments.length),this.middleware((t,n)=>Et(()=>e(t,n.getOptions()),n=>(n?(typeof n==`string`||n instanceof Error)&&I(this,X,`f`).fail(n.toString(),n):I(this,X,`f`).fail(I(this,Y,`f`).y18n.__(`Argument check failed: %s`,e.toString())),t),e=>(I(this,X,`f`).fail(e.message?e.message:e.toString(),e),t)),!1,t),this}choices(e,t){return P(`<object|string|array> [string|array]`,[e,t],arguments.length),this[Rn](this.choices.bind(this),`choices`,e,t),this}coerce(e,t){if(P(`<object|string|array> [function]`,[e,t],arguments.length),Array.isArray(e)){if(!t)throw new N(`coerce callback must be provided`);for(let n of e)this.coerce(n,t);return this}else if(typeof e==`object`){for(let t of Object.keys(e))this.coerce(t,e[t]);return this}if(!t)throw new N(`coerce callback must be provided`);let n=e;return I(this,q,`f`).key[n]=!0,I(this,H,`f`).addCoerceMiddleware((e,r)=>{let i=[n,...r.getAliases()[n]??[]].filter(t=>Object.prototype.hasOwnProperty.call(e,t));return i.length===0?e:Et(()=>t(e[i[0]]),t=>(i.forEach(n=>{e[n]=t}),e),e=>{throw new N(e.message)})},n),this}conflicts(e,t){return P(`<string|object> [string|array]`,[e,t],arguments.length),I(this,Q,`f`).conflicts(e,t),this}config(e=`config`,t,n){return P(`[object|string] [string|function] [function]`,[e,t,n],arguments.length),typeof e==`object`&&!Array.isArray(e)?(e=$t(e,I(this,rn,`f`),this[An]()[`deep-merge-config`]||!1,I(this,Y,`f`)),I(this,q,`f`).configObjects=(I(this,q,`f`).configObjects||[]).concat(e),this):(typeof t==`function`&&(n=t,t=void 0),this.describe(e,t||I(this,X,`f`).deferY18nLookup(`Path to JSON config file`)),(Array.isArray(e)?e:[e]).forEach(e=>{I(this,q,`f`).config[e]=n||!0}),this)}completion(e,t,n){return P(`[string] [string|boolean|function] [function]`,[e,t,n],arguments.length),typeof t==`function`&&(n=t,t=void 0),F(this,z,e||I(this,z,`f`)||`completion`,`f`),!t&&t!==!1&&(t=`generate completion script`),this.command(I(this,z,`f`),t),n&&I(this,R,`f`).registerFunction(n),this}command(e,t,n,r,i,a){return P(`<string|array|object> [string|boolean] [function|object] [function] [array] [boolean|string]`,[e,t,n,r,i,a],arguments.length),I(this,L,`f`).addHandler(e,t,n,r,i,a),this}commands(e,t,n,r,i,a){return this.command(e,t,n,r,i,a)}commandDir(e,t){P(`<string> [object]`,[e,t],arguments.length);let n=I(this,fn,`f`)||I(this,Y,`f`).require;return I(this,L,`f`).addDirectory(e,n,I(this,Y,`f`).getCallerFile(),t),this}count(e){return P(`<array|string>`,[e],arguments.length),this[In](`count`,e),this[ar](e),this}default(e,t,n){return P(`<object|string|array> [*] [string]`,[e,t,n],arguments.length),n&&(_t(e,I(this,Y,`f`)),I(this,q,`f`).defaultDescription[e]=n),typeof t==`function`&&(_t(e,I(this,Y,`f`)),I(this,q,`f`).defaultDescription[e]||(I(this,q,`f`).defaultDescription[e]=I(this,X,`f`).functionDescription(t)),t=t.call()),this[Ln](this.default.bind(this),`default`,e,t),this}defaults(e,t,n){return this.default(e,t,n)}demandCommand(e=1,t,n,r){return P(`[number] [number|string] [string|null|undefined] [string|null|undefined]`,[e,t,n,r],arguments.length),typeof t!=`number`&&(n=t,t=1/0),this.global(`_`,!1),I(this,q,`f`).demandedCommands._={min:e,max:t,minMsg:n,maxMsg:r},this}demand(e,t,n){return Array.isArray(t)?(t.forEach(e=>{j(n,!0,I(this,Y,`f`)),this.demandOption(e,n)}),t=1/0):typeof t!=`number`&&(n=t,t=1/0),typeof e==`number`?(j(n,!0,I(this,Y,`f`)),this.demandCommand(e,t,n,n)):Array.isArray(e)?e.forEach(e=>{j(n,!0,I(this,Y,`f`)),this.demandOption(e,n)}):typeof n==`string`?this.demandOption(e,n):(n===!0||n===void 0)&&this.demandOption(e),this}demandOption(e,t){return P(`<object|string|array> [string]`,[e,t],arguments.length),this[Ln](this.demandOption.bind(this),`demandedOptions`,e,t),this}deprecateOption(e,t){return P(`<string> [string|boolean]`,[e,t],arguments.length),I(this,q,`f`).deprecatedOptions[e]=t,this}describe(e,t){return P(`<object|string|array> [string]`,[e,t],arguments.length),this[Vn](e,!0),I(this,X,`f`).describe(e,t),this}detectLocale(e){return P(`<boolean>`,[e],arguments.length),F(this,sn,e,`f`),this}env(e){return P(`[string|boolean]`,[e],arguments.length),e===!1?delete I(this,q,`f`).envPrefix:I(this,q,`f`).envPrefix=e||``,this}epilogue(e){return P(`<string>`,[e],arguments.length),I(this,X,`f`).epilog(e),this}epilog(e){return this.epilogue(e)}example(e,t){return P(`<string|array> [string]`,[e,t],arguments.length),Array.isArray(e)?e.forEach(e=>this.example(...e)):I(this,X,`f`).example(e,t),this}exit(e,t){F(this,W,!0,`f`),F(this,B,t,`f`),I(this,V,`f`)&&I(this,Y,`f`).process.exit(e)}exitProcess(e=!0){return P(`[boolean]`,[e],arguments.length),F(this,V,e,`f`),this}fail(e){if(P(`<function|boolean>`,[e],arguments.length),typeof e==`boolean`&&e!==!1)throw new N(`Invalid first argument. Expected function or boolean 'false'`);return I(this,X,`f`).failFn(e),this}getAliases(){return this.parsed?this.parsed.aliases:{}}async getCompletion(e,t){return P(`<array> [function]`,[e,t],arguments.length),t?I(this,R,`f`).getCompletion(e,t):new Promise((t,n)=>{I(this,R,`f`).getCompletion(e,(e,r)=>{e?n(e):t(r)})})}getDemandedOptions(){return P([],0),I(this,q,`f`).demandedOptions}getDemandedCommands(){return P([],0),I(this,q,`f`).demandedCommands}getDeprecatedOptions(){return P([],0),I(this,q,`f`).deprecatedOptions}getDetectLocale(){return I(this,sn,`f`)}getExitProcess(){return I(this,V,`f`)}getGroups(){return Object.assign({},I(this,U,`f`),I(this,gn,`f`))}getHelp(){if(F(this,W,!0,`f`),!I(this,X,`f`).hasCachedHelpMessage()){if(!this.parsed){let e=this[nr](I(this,_n,`f`),void 0,void 0,0,!0);if(M(e))return e.then(()=>I(this,X,`f`).help())}let e=I(this,L,`f`).runDefaultBuilderOn(this);if(M(e))return e.then(()=>I(this,X,`f`).help())}return Promise.resolve(I(this,X,`f`).help())}getOptions(){return I(this,q,`f`)}getStrict(){return I(this,yn,`f`)}getStrictCommands(){return I(this,bn,`f`)}getStrictOptions(){return I(this,xn,`f`)}global(e,t){return P(`<string|array> [boolean]`,[e,t],arguments.length),e=[].concat(e),t===!1?e.forEach(e=>{I(this,q,`f`).local.includes(e)||I(this,q,`f`).local.push(e)}):I(this,q,`f`).local=I(this,q,`f`).local.filter(t=>e.indexOf(t)===-1),this}group(e,t){P(`<string|array> <string>`,[e,t],arguments.length);let n=I(this,gn,`f`)[t]||I(this,U,`f`)[t];I(this,gn,`f`)[t]&&delete I(this,gn,`f`)[t];let r={};return I(this,U,`f`)[t]=(n||[]).concat(e).filter(e=>r[e]?!1:r[e]=!0),this}hide(e){return P(`<string>`,[e],arguments.length),I(this,q,`f`).hiddenOptions.push(e),this}implies(e,t){return P(`<string|object> [number|string|array]`,[e,t],arguments.length),I(this,Q,`f`).implies(e,t),this}locale(e){return P(`[string]`,[e],arguments.length),e===void 0?(this[Mn](),I(this,Y,`f`).y18n.getLocale()):(F(this,sn,!1,`f`),I(this,Y,`f`).y18n.setLocale(e),this)}middleware(e,t,n){return I(this,H,`f`).addMiddleware(e,!!t,n)}nargs(e,t){return P(`<string|object|array> [number]`,[e,t],arguments.length),this[Ln](this.nargs.bind(this),`narg`,e,t),this}normalize(e){return P(`<array|string>`,[e],arguments.length),this[In](`normalize`,e),this}number(e){return P(`<array|string>`,[e],arguments.length),this[In](`number`,e),this[ar](e),this}option(e,t){if(P(`<string|object> [object]`,[e,t],arguments.length),typeof e==`object`)Object.keys(e).forEach(t=>{this.options(t,e[t])});else{typeof t!=`object`&&(t={}),this[ar](e),I(this,Z,`f`)&&(e===`version`||t?.alias===`version`)&&this[Dn]([`"version" is a reserved word.`,`Please do one of the following:`,'- Disable version with `yargs.version(false)` if using "version" as an option',"- Use the built-in `yargs.version` method instead (if applicable)",`- Use a different option key`,`https://yargs.js.org/docs/#api-reference-version`].join(`
96
+ `),void 0,`versionWarning`),I(this,q,`f`).key[e]=!0,t.alias&&this.alias(e,t.alias);let n=t.deprecate||t.deprecated;n&&this.deprecateOption(e,n);let r=t.demand||t.required||t.require;r&&this.demand(e,r),t.demandOption&&this.demandOption(e,typeof t.demandOption==`string`?t.demandOption:void 0),t.conflicts&&this.conflicts(e,t.conflicts),`default`in t&&this.default(e,t.default),t.implies!==void 0&&this.implies(e,t.implies),t.nargs!==void 0&&this.nargs(e,t.nargs),t.config&&this.config(e,t.configParser),t.normalize&&this.normalize(e),t.choices&&this.choices(e,t.choices),t.coerce&&this.coerce(e,t.coerce),t.group&&this.group(e,t.group),(t.boolean||t.type===`boolean`)&&(this.boolean(e),t.alias&&this.boolean(t.alias)),(t.array||t.type===`array`)&&(this.array(e),t.alias&&this.array(t.alias)),(t.number||t.type===`number`)&&(this.number(e),t.alias&&this.number(t.alias)),(t.string||t.type===`string`)&&(this.string(e),t.alias&&this.string(t.alias)),(t.count||t.type===`count`)&&this.count(e),typeof t.global==`boolean`&&this.global(e,t.global),t.defaultDescription&&(I(this,q,`f`).defaultDescription[e]=t.defaultDescription),t.skipValidation&&this.skipValidation(e);let i=t.describe||t.description||t.desc,a=I(this,X,`f`).getDescriptions();(!Object.prototype.hasOwnProperty.call(a,e)||typeof i==`string`)&&this.describe(e,i),t.hidden&&this.hide(e),t.requiresArg&&this.requiresArg(e)}return this}options(e,t){return this.option(e,t)}parse(e,t,n){P(`[string|array] [function|boolean|object] [function]`,[e,t,n],arguments.length),this[On](),e===void 0&&(e=I(this,_n,`f`)),typeof t==`object`&&(F(this,mn,t,`f`),t=n),typeof t==`function`&&(F(this,J,t,`f`),t=!1),t||F(this,_n,e,`f`),I(this,J,`f`)&&F(this,V,!1,`f`);let r=this[nr](e,!!t),i=this.parsed;return I(this,R,`f`).setParsed(this.parsed),M(r)?r.then(e=>(I(this,J,`f`)&&I(this,J,`f`).call(this,I(this,B,`f`),e,I(this,K,`f`)),e)).catch(e=>{throw I(this,J,`f`)&&I(this,J,`f`)(e,this.parsed.argv,I(this,K,`f`)),e}).finally(()=>{this[Hn](),this.parsed=i}):(I(this,J,`f`)&&I(this,J,`f`).call(this,I(this,B,`f`),r,I(this,K,`f`)),this[Hn](),this.parsed=i,r)}parseAsync(e,t,n){let r=this.parse(e,t,n);return M(r)?r:Promise.resolve(r)}parseSync(e,t,n){let r=this.parse(e,t,n);if(M(r))throw new N(`.parseSync() must not be used with asynchronous builders, handlers, or middleware`);return r}parserConfiguration(e){return P(`<object>`,[e],arguments.length),F(this,pn,e,`f`),this}pkgConf(e,t){P(`<string> [string]`,[e,t],arguments.length);let n=null,r=this[Fn](t||I(this,rn,`f`));return r[e]&&typeof r[e]==`object`&&(n=$t(r[e],t||I(this,rn,`f`),this[An]()[`deep-merge-config`]||!1,I(this,Y,`f`)),I(this,q,`f`).configObjects=(I(this,q,`f`).configObjects||[]).concat(n)),this}positional(e,t){P(`<string> <object>`,[e,t],arguments.length);let n=[`default`,`defaultDescription`,`implies`,`normalize`,`choices`,`conflicts`,`coerce`,`type`,`describe`,`desc`,`description`,`alias`];t=It(t,(e,t)=>e===`type`&&![`string`,`number`,`boolean`].includes(t)?!1:n.includes(e));let r=I(this,an,`f`).fullCommands[I(this,an,`f`).fullCommands.length-1],i=r?I(this,L,`f`).cmdToParseOptions(r):{array:[],alias:{},default:{},demand:{}};return vt(i).forEach(n=>{let r=i[n];Array.isArray(r)?r.indexOf(e)!==-1&&(t[n]=!0):r[e]&&!(n in t)&&(t[n]=r[e])}),this.group(e,I(this,X,`f`).getPositionalGroupName()),this.option(e,t)}recommendCommands(e=!0){return P(`[boolean]`,[e],arguments.length),F(this,vn,e,`f`),this}required(e,t,n){return this.demand(e,t,n)}require(e,t,n){return this.demand(e,t,n)}requiresArg(e){return P(`<array|string|object> [number]`,[e],arguments.length),typeof e==`string`&&I(this,q,`f`).narg[e]||this[Ln](this.requiresArg.bind(this),`narg`,e,NaN),this}showCompletionScript(e,t){return P(`[string] [string]`,[e,t],arguments.length),e||=this.$0,I(this,dn,`f`).log(I(this,R,`f`).generateCompletionScript(e,t||I(this,z,`f`)||`completion`)),this}showHelp(e){if(P(`[string|function]`,[e],arguments.length),F(this,W,!0,`f`),!I(this,X,`f`).hasCachedHelpMessage()){if(!this.parsed){let t=this[nr](I(this,_n,`f`),void 0,void 0,0,!0);if(M(t))return t.then(()=>{I(this,X,`f`).showHelp(e)}),this}let t=I(this,L,`f`).runDefaultBuilderOn(this);if(M(t))return t.then(()=>{I(this,X,`f`).showHelp(e)}),this}return I(this,X,`f`).showHelp(e),this}scriptName(e){return this.customScriptName=!0,this.$0=e,this}showHelpOnFail(e,t){return P(`[boolean|string] [string]`,[e,t],arguments.length),I(this,X,`f`).showHelpOnFail(e,t),this}showVersion(e){return P(`[string|function]`,[e],arguments.length),I(this,X,`f`).showVersion(e),this}skipValidation(e){return P(`<array|string>`,[e],arguments.length),this[In](`skipValidation`,e),this}strict(e){return P(`[boolean]`,[e],arguments.length),F(this,yn,e!==!1,`f`),this}strictCommands(e){return P(`[boolean]`,[e],arguments.length),F(this,bn,e!==!1,`f`),this}strictOptions(e){return P(`[boolean]`,[e],arguments.length),F(this,xn,e!==!1,`f`),this}string(e){return P(`<array|string>`,[e],arguments.length),this[In](`string`,e),this[ar](e),this}terminalWidth(){return P([],0),I(this,Y,`f`).process.stdColumns}updateLocale(e){return this.updateStrings(e)}updateStrings(e){return P(`<object>`,[e],arguments.length),F(this,sn,!1,`f`),I(this,Y,`f`).y18n.updateLocale(e),this}usage(e,t,n,r){if(P(`<string|null|undefined> [string|boolean] [function|object] [function]`,[e,t,n,r],arguments.length),t!==void 0){if(j(e,null,I(this,Y,`f`)),(e||``).match(/^\$0( |$)/))return this.command(e,t,n,r);throw new N(`.usage() description must start with $0 if being used as alias for .command()`)}else return I(this,X,`f`).usage(e),this}usageConfiguration(e){return P(`<object>`,[e],arguments.length),F(this,Sn,e,`f`),this}version(e,t,n){let r=`version`;if(P(`[boolean|string] [string] [string]`,[e,t,n],arguments.length),I(this,Z,`f`)&&(this[En](I(this,Z,`f`)),I(this,X,`f`).version(void 0),F(this,Z,null,`f`)),arguments.length===0)n=this[Nn](),e=r;else if(arguments.length===1){if(e===!1)return this;n=e,e=r}else arguments.length===2&&(n=t,t=void 0);return F(this,Z,typeof e==`string`?e:r,`f`),t||=I(this,X,`f`).deferY18nLookup(`Show version number`),I(this,X,`f`).version(n||void 0),this.boolean(I(this,Z,`f`)),this.describe(I(this,Z,`f`),t),this}wrap(e){return P(`<number|null|undefined>`,[e],arguments.length),I(this,X,`f`).wrap(e),this}[(L=new WeakMap,rn=new WeakMap,an=new WeakMap,R=new WeakMap,z=new WeakMap,on=new WeakMap,B=new WeakMap,sn=new WeakMap,cn=new WeakMap,V=new WeakMap,ln=new WeakMap,H=new WeakMap,U=new WeakMap,W=new WeakMap,G=new WeakMap,un=new WeakMap,dn=new WeakMap,K=new WeakMap,q=new WeakMap,fn=new WeakMap,pn=new WeakMap,J=new WeakMap,mn=new WeakMap,hn=new WeakMap,gn=new WeakMap,_n=new WeakMap,vn=new WeakMap,Y=new WeakMap,yn=new WeakMap,bn=new WeakMap,xn=new WeakMap,X=new WeakMap,Sn=new WeakMap,Z=new WeakMap,Q=new WeakMap,wn)](e){if(!e._||!e[`--`])return e;e._.push.apply(e._,e[`--`]);try{delete e[`--`]}catch{}return e}[Tn](){return{log:(...e)=>{this[Zn]()||console.log(...e),F(this,W,!0,`f`),I(this,K,`f`).length&&F(this,K,I(this,K,`f`)+`
97
+ `,`f`),F(this,K,I(this,K,`f`)+e.join(` `),`f`)},error:(...e)=>{this[Zn]()||console.error(...e),F(this,W,!0,`f`),I(this,K,`f`).length&&F(this,K,I(this,K,`f`)+`
98
+ `,`f`),F(this,K,I(this,K,`f`)+e.join(` `),`f`)}}}[En](e){vt(I(this,q,`f`)).forEach(t=>{if((e=>e===`configObjects`)(t))return;let n=I(this,q,`f`)[t];Array.isArray(n)?n.includes(e)&&n.splice(n.indexOf(e),1):typeof n==`object`&&delete n[e]}),delete I(this,X,`f`).getDescriptions()[e]}[Dn](e,t,n){I(this,cn,`f`)[n]||(I(this,Y,`f`).process.emitWarning(e,t),I(this,cn,`f`)[n]=!0)}[On](){I(this,ln,`f`).push({options:I(this,q,`f`),configObjects:I(this,q,`f`).configObjects.slice(0),exitProcess:I(this,V,`f`),groups:I(this,U,`f`),strict:I(this,yn,`f`),strictCommands:I(this,bn,`f`),strictOptions:I(this,xn,`f`),completionCommand:I(this,z,`f`),output:I(this,K,`f`),exitError:I(this,B,`f`),hasOutput:I(this,W,`f`),parsed:this.parsed,parseFn:I(this,J,`f`),parseContext:I(this,mn,`f`)}),I(this,X,`f`).freeze(),I(this,Q,`f`).freeze(),I(this,L,`f`).freeze(),I(this,H,`f`).freeze()}[kn](){let e=``,t;return t=/\b(node|iojs|electron)(\.exe)?$/.test(I(this,Y,`f`).process.argv()[0])?I(this,Y,`f`).process.argv().slice(1,2):I(this,Y,`f`).process.argv().slice(0,1),e=t.map(e=>{let t=this[er](I(this,rn,`f`),e);return e.match(/^(\/|([a-zA-Z]:)?\\)/)&&t.length<e.length?t:e}).join(` `).trim(),I(this,Y,`f`).getEnv(`_`)&&I(this,Y,`f`).getProcessArgvBin()===I(this,Y,`f`).getEnv(`_`)&&(e=I(this,Y,`f`).getEnv(`_`).replace(`${I(this,Y,`f`).path.dirname(I(this,Y,`f`).process.execPath())}/`,``)),e}[An](){return I(this,pn,`f`)}[jn](){return I(this,Sn,`f`)}[Mn](){if(!I(this,sn,`f`))return;let e=I(this,Y,`f`).getEnv(`LC_ALL`)||I(this,Y,`f`).getEnv(`LC_MESSAGES`)||I(this,Y,`f`).getEnv(`LANG`)||I(this,Y,`f`).getEnv(`LANGUAGE`)||`en_US`;this.locale(e.replace(/[.:].*/,``))}[Nn](){return this[Fn]().version||`unknown`}[Pn](e){let t=e[`--`]?e[`--`]:e._;for(let e=0,n;(n=t[e])!==void 0;e++)I(this,Y,`f`).Parser.looksLikeNumber(n)&&Number.isSafeInteger(Math.floor(parseFloat(`${n}`)))&&(t[e]=Number(n));return e}[Fn](e){let t=e||`*`;if(I(this,hn,`f`)[t])return I(this,hn,`f`)[t];let n={};try{let t=e||I(this,Y,`f`).mainFilename;I(this,Y,`f`).path.extname(t)&&(t=I(this,Y,`f`).path.dirname(t));let r=I(this,Y,`f`).findUp(t,(e,t)=>{if(t.includes(`package.json`))return`package.json`});j(r,void 0,I(this,Y,`f`)),n=JSON.parse(I(this,Y,`f`).readFileSync(r,`utf8`))}catch{}return I(this,hn,`f`)[t]=n||{},I(this,hn,`f`)[t]}[In](e,t){t=[].concat(t),t.forEach(t=>{t=this[Bn](t),I(this,q,`f`)[e].push(t)})}[Ln](e,t,n,r){this[zn](e,t,n,r,(e,t,n)=>{I(this,q,`f`)[e][t]=n})}[Rn](e,t,n,r){this[zn](e,t,n,r,(e,t,n)=>{I(this,q,`f`)[e][t]=(I(this,q,`f`)[e][t]||[]).concat(n)})}[zn](e,t,n,r,i){if(Array.isArray(n))n.forEach(t=>{e(t,r)});else if((e=>typeof e==`object`)(n))for(let t of vt(n))e(t,n[t]);else i(t,this[Bn](n),r)}[Bn](e){return e===`__proto__`?`___proto___`:e}[Vn](e,t){return this[Ln](this[Vn].bind(this),`key`,e,t),this}[Hn](){var e,t,n,r,i,a,o,s,c,l,u,d;let f=I(this,ln,`f`).pop();j(f,void 0,I(this,Y,`f`));let p;e=this,t=this,n=this,r=this,i=this,a=this,o=this,s=this,c=this,l=this,u=this,d=this,{options:{set value(t){F(e,q,t,`f`)}}.value,configObjects:p,exitProcess:{set value(e){F(t,V,e,`f`)}}.value,groups:{set value(e){F(n,U,e,`f`)}}.value,output:{set value(e){F(r,K,e,`f`)}}.value,exitError:{set value(e){F(i,B,e,`f`)}}.value,hasOutput:{set value(e){F(a,W,e,`f`)}}.value,parsed:this.parsed,strict:{set value(e){F(o,yn,e,`f`)}}.value,strictCommands:{set value(e){F(s,bn,e,`f`)}}.value,strictOptions:{set value(e){F(c,xn,e,`f`)}}.value,completionCommand:{set value(e){F(l,z,e,`f`)}}.value,parseFn:{set value(e){F(u,J,e,`f`)}}.value,parseContext:{set value(e){F(d,mn,e,`f`)}}.value}=f,I(this,q,`f`).configObjects=p,I(this,X,`f`).unfreeze(),I(this,Q,`f`).unfreeze(),I(this,L,`f`).unfreeze(),I(this,H,`f`).unfreeze()}[Un](e,t){return Et(t,t=>(e(t),t))}getInternalMethods(){return{getCommandInstance:this[Wn].bind(this),getContext:this[Gn].bind(this),getHasOutput:this[Kn].bind(this),getLoggerInstance:this[qn].bind(this),getParseContext:this[Jn].bind(this),getParserConfiguration:this[An].bind(this),getUsageConfiguration:this[jn].bind(this),getUsageInstance:this[Yn].bind(this),getValidationInstance:this[Xn].bind(this),hasParseCallback:this[Zn].bind(this),isGlobalContext:this[Qn].bind(this),postProcess:this[$n].bind(this),reset:this[tr].bind(this),runValidation:this[rr].bind(this),runYargsParserAndExecuteCommands:this[nr].bind(this),setHasOutput:this[ir].bind(this)}}[Wn](){return I(this,L,`f`)}[Gn](){return I(this,an,`f`)}[Kn](){return I(this,W,`f`)}[qn](){return I(this,dn,`f`)}[Jn](){return I(this,mn,`f`)||{}}[Yn](){return I(this,X,`f`)}[Xn](){return I(this,Q,`f`)}[Zn](){return!!I(this,J,`f`)}[Qn](){return I(this,un,`f`)}[$n](e,t,n,r){return n||M(e)?e:(t||(e=this[wn](e)),(this[An]()[`parse-positional-numbers`]||this[An]()[`parse-positional-numbers`]===void 0)&&(e=this[Pn](e)),r&&(e=Tt(e,this,I(this,H,`f`).getMiddleware(),!1)),e)}[tr](e={}){F(this,q,I(this,q,`f`)||{},`f`);let t={};t.local=I(this,q,`f`).local||[],t.configObjects=I(this,q,`f`).configObjects||[];let n={};return t.local.forEach(t=>{n[t]=!0,(e[t]||[]).forEach(e=>{n[e]=!0})}),Object.assign(I(this,gn,`f`),Object.keys(I(this,U,`f`)).reduce((e,t)=>{let r=I(this,U,`f`)[t].filter(e=>!(e in n));return r.length>0&&(e[t]=r),e},{})),F(this,U,{},`f`),[`array`,`boolean`,`string`,`skipValidation`,`count`,`normalize`,`number`,`hiddenOptions`].forEach(e=>{t[e]=(I(this,q,`f`)[e]||[]).filter(e=>!n[e])}),[`narg`,`key`,`alias`,`default`,`defaultDescription`,`config`,`choices`,`demandedOptions`,`demandedCommands`,`deprecatedOptions`].forEach(e=>{t[e]=It(I(this,q,`f`)[e],e=>!n[e])}),t.envPrefix=I(this,q,`f`).envPrefix,F(this,q,t,`f`),F(this,X,I(this,X,`f`)?I(this,X,`f`).reset(n):zt(this,I(this,Y,`f`)),`f`),F(this,Q,I(this,Q,`f`)?I(this,Q,`f`).reset(n):Xt(this,I(this,X,`f`),I(this,Y,`f`)),`f`),F(this,L,I(this,L,`f`)?I(this,L,`f`).reset():At(I(this,X,`f`),I(this,Q,`f`),I(this,H,`f`),I(this,Y,`f`)),`f`),I(this,R,`f`)||F(this,R,Gt(this,I(this,X,`f`),I(this,L,`f`),I(this,Y,`f`)),`f`),I(this,H,`f`).reset(),F(this,z,null,`f`),F(this,K,``,`f`),F(this,B,null,`f`),F(this,W,!1,`f`),this.parsed=!1,this}[er](e,t){return I(this,Y,`f`).path.relative(e,t)}[nr](e,t,n,r=0,i=!1){let a=!!n||i;e||=I(this,_n,`f`),I(this,q,`f`).__=I(this,Y,`f`).y18n.__,I(this,q,`f`).configuration=this[An]();let o=!!I(this,q,`f`).configuration[`populate--`],s=Object.assign({},I(this,q,`f`).configuration,{"populate--":!0}),c=I(this,Y,`f`).Parser.detailed(e,Object.assign({},I(this,q,`f`),{configuration:{"parse-positional-numbers":!1,...s}})),l=Object.assign(c.argv,I(this,mn,`f`)),u,d=c.aliases,f=!1,p=!1;Object.keys(l).forEach(e=>{e===I(this,G,`f`)&&l[e]?f=!0:e===I(this,Z,`f`)&&l[e]&&(p=!0)}),l.$0=this.$0,this.parsed=c,r===0&&I(this,X,`f`).clearCachedHelpMessage();try{if(this[Mn](),t)return this[$n](l,o,!!n,!1);I(this,G,`f`)&&[I(this,G,`f`)].concat(d[I(this,G,`f`)]||[]).filter(e=>e.length>1).includes(``+l._[l._.length-1])&&(l._.pop(),f=!0),F(this,un,!1,`f`);let s=I(this,L,`f`).getCommands(),m=I(this,R,`f`)?.completionKey?[I(this,R,`f`)?.completionKey,...this.getAliases()[I(this,R,`f`)?.completionKey]??[]].some(e=>Object.prototype.hasOwnProperty.call(l,e)):!1,h=f||m||i;if(l._.length){if(s.length){let e;for(let t=r||0,a;l._[t]!==void 0;t++)if(a=String(l._[t]),s.includes(a)&&a!==I(this,z,`f`)){let e=I(this,L,`f`).runCommand(a,this,c,t+1,i,f||p||i);return this[$n](e,o,!!n,!1)}else if(!e&&a!==I(this,z,`f`)){e=a;break}!I(this,L,`f`).hasDefaultCommand()&&I(this,vn,`f`)&&e&&!h&&I(this,Q,`f`).recommendCommands(e,s)}I(this,z,`f`)&&l._.includes(I(this,z,`f`))&&!m&&(I(this,V,`f`)&&Lt(!0),this.showCompletionScript(),this.exit(0))}if(I(this,L,`f`).hasDefaultCommand()&&!h){let e=I(this,L,`f`).runCommand(null,this,c,0,i,f||p||i);return this[$n](e,o,!!n,!1)}if(m){I(this,V,`f`)&&Lt(!0),e=[].concat(e);let t=e.slice(e.indexOf(`--${I(this,R,`f`).completionKey}`)+1);return I(this,R,`f`).getCompletion(t,(e,t)=>{if(e)throw new N(e.message);(t||[]).forEach(e=>{I(this,dn,`f`).log(e)}),this.exit(0)}),this[$n](l,!o,!!n,!1)}if(I(this,W,`f`)||(f?(I(this,V,`f`)&&Lt(!0),a=!0,this.showHelp(e=>{I(this,dn,`f`).log(e),this.exit(0)})):p&&(I(this,V,`f`)&&Lt(!0),a=!0,I(this,X,`f`).showVersion(`log`),this.exit(0))),!a&&I(this,q,`f`).skipValidation.length>0&&(a=Object.keys(l).some(e=>I(this,q,`f`).skipValidation.indexOf(e)>=0&&l[e]===!0)),!a){if(c.error)throw new N(c.error.message);if(!m){let e=this[rr](d,{},c.error);n||(u=Tt(l,this,I(this,H,`f`).getMiddleware(),!0)),u=this[Un](e,u??l),M(u)&&!n&&(u=u.then(()=>Tt(l,this,I(this,H,`f`).getMiddleware(),!1)))}}}catch(e){if(e instanceof N)I(this,X,`f`).fail(e.message,e);else throw e}return this[$n](u??l,o,!!n,!0)}[rr](e,t,n,r){let i={...this.getDemandedOptions()};return a=>{if(n)throw new N(n.message);I(this,Q,`f`).nonOptionCount(a),I(this,Q,`f`).requiredArguments(a,i);let o=!1;I(this,bn,`f`)&&(o=I(this,Q,`f`).unknownCommands(a)),I(this,yn,`f`)&&!o?I(this,Q,`f`).unknownArguments(a,e,t,!!r):I(this,xn,`f`)&&I(this,Q,`f`).unknownArguments(a,e,{},!1,!1),I(this,Q,`f`).limitedChoices(a),I(this,Q,`f`).implications(a),I(this,Q,`f`).conflicting(a)}}[ir](){F(this,W,!0,`f`)}[ar](e){if(typeof e==`string`)I(this,q,`f`).key[e]=!0;else for(let t of e)I(this,q,`f`).key[t]=!0}};function sr(e){return!!e&&typeof e.getInternalMethods==`function`}const cr=Cn(gt);function $(e,t,n){return{command:e,describe:t,builder:async e=>{let t=(await n()).default.builder;return typeof t==`function`?t(e):e},handler:async e=>{await(await n()).default.handler(e)}}}const lr=[{command:$(`abuse-reports`,`Submit and track abuse reports for phishing, malware, and other policy violations on Cloudflare-proxied sites`,()=>import(`./abuse-reports-KtfZhi6j.mjs`)),hideCommand:!0},{command:$(`accounts`,`Account settings, members, roles, subscriptions, and API tokens for your Cloudflare account`,()=>import(`./accounts-BopMfODC.mjs`)),hideCommand:!1},{command:$(`acm`,`Advanced Certificate Manager — Total TLS auto-issuance and custom origin trust store certificates`,()=>import(`./acm-BT4vlnEJ.mjs`)),hideCommand:!0},{command:$(`addressing`,`IP address management — BYOIP prefixes, address maps, regional hostnames, and BGP advertisement control`,()=>import(`./addressing-B3uFxHst.mjs`)),hideCommand:!0},{command:$(`ai`,`Run inference on Workers AI models — text generation, image classification, embeddings, and more`,()=>import(`./ai-DWHqwMap.mjs`)),hideCommand:!0},{command:$(`ai-gateway`,`Proxy, cache, rate-limit, and observe requests to AI providers — OpenAI, Anthropic, Workers AI, and more`,()=>import(`./ai-gateway-CbKEO-3o.mjs`)),hideCommand:!0},{command:$(`ai-search`,`Managed search-as-a-service — crawl, index, and query content with AI-powered relevance and chat completions`,()=>import(`./ai-search-VnOQ5n--.mjs`)),hideCommand:!0},{command:$(`alerting`,`Notification policies, delivery destinations, silence windows, and alert history`,()=>import(`./alerting-BmmgIlIO.mjs`)),hideCommand:!0},{command:$(`analytics`,`Zone-level traffic analytics — dashboard summaries, per-colo breakdowns, and Argo latency metrics`,()=>import(`./analytics-isY03taL.mjs`)),hideCommand:!0},{command:$(`api-gateway`,`Discover, monitor, and protect your API endpoints with schema validation, abuse detection, and routing`,()=>import(`./api-gateway-DXurEbA-.mjs`)),hideCommand:!0},{command:$(`argo`,`Network optimization features that speed up and improve reliability of traffic to your origins`,()=>import(`./argo-B02BL_hp.mjs`)),hideCommand:!0},{command:$(`audit-logs`,`Immutable audit trail of actions taken by account members — who changed what and when`,()=>import(`./audit-logs-DcgR9xUc.mjs`)),hideCommand:!0},{command:$(`autorag`,`AutoRAG — AI search, file management, job tracking, and sync for retrieval-augmented generation`,()=>import(`./autorag-CmrwnGVj.mjs`)),hideCommand:!0},{command:$(`billing`,`Account billing profiles and usage data for Cloudflare subscriptions and add-on services`,()=>import(`./billing-CaW1ZAB1.mjs`)),hideCommand:!0},{command:$(`bot-management`,`Bot detection and mitigation settings — configure bot scores, JavaScript detections, and challenge behavior`,()=>import(`./bot-management-CeBsFx68.mjs`)),hideCommand:!0},{command:$(`botnet-feed`,`Botnet threat intelligence feeds — IP and ASN-level data on known command-and-control infrastructure`,()=>import(`./botnet-feed-B396vQeQ.mjs`)),hideCommand:!0},{command:$(`brand-protection`,`Monitor the Internet for phishing sites, lookalike domains, and unauthorized use of your brand assets`,()=>import(`./brand-protection-D4V1v5Kl.mjs`)),hideCommand:!0},{command:$(`browser-rendering`,`Headless browser API — render pages, take screenshots, generate PDFs, scrape content, and extract structured data`,()=>import(`./browser-rendering-GF7rNtKI.mjs`)),hideCommand:!0},{command:$(`builds`,`Automated build and deployment pipeline for Workers — track builds, logs, and repo connections`,()=>import(`./builds-C_ySULja.mjs`)),hideCommand:!0},{command:$(`cache`,`Purge cached content and configure Cache Reserve, tiered caching, and variant serving`,()=>import(`./cache-DmXizSMi.mjs`)),hideCommand:!0},{command:$(`calls`,`Real-time audio/video communication infrastructure — SFU apps for WebRTC and TURN relay keys`,()=>import(`./calls-x4KQpTB4.mjs`)),hideCommand:!0},{command:$(`certificate-authorities`,`Map client certificates to specific hostnames for mTLS authentication`,()=>import(`./certificate-authorities-hC0SG-Ga.mjs`)),hideCommand:!0},{command:$(`client-certificates`,`Issue and manage client certificates for mutual TLS (mTLS) authentication on your zone`,()=>import(`./client-certificates-BGVsDyeJ.mjs`)),hideCommand:!0},{command:$(`cloud-connector`,`Route traffic from Cloudflare directly to cloud provider services (AWS, Azure, GCP) without origin servers`,()=>import(`./cloud-connector-BClQpEzI.mjs`)),hideCommand:!0},{command:$(`cloudforce-one`,`Threat intelligence platform — request investigations, scan indicators, and track threat events`,()=>import(`./cloudforce-one-BfhFrO6M.mjs`)),hideCommand:!0},{command:$(`connectivity`,`Service directory for network connectivity endpoints and their configurations`,()=>import(`./connectivity-G0NP6LtW.mjs`)),hideCommand:!0},{command:$(`content-scanning`,`Scan uploaded content in HTTP requests for malware and malicious payloads`,()=>import(`./content-scanning-DEtPJ7aF.mjs`)),hideCommand:!0},{command:$(`custom-certificates`,`Upload and manage your own SSL/TLS certificates for a zone, with priority ordering`,()=>import(`./custom-certificates-rJXFpUWu.mjs`)),hideCommand:!0},{command:$(`custom-hostnames`,`Bring custom vanity domains to your SaaS zone with per-hostname SSL and origin mapping`,()=>import(`./custom-hostnames-Be5mgLeF.mjs`)),hideCommand:!0},{command:$(`custom-nameservers`,`Vanity nameservers that use your own domain instead of Cloudflare-assigned NS records`,()=>import(`./custom-nameservers-CoFdy6hD.mjs`)),hideCommand:!0},{command:$(`custom-pages`,`Custom error and challenge pages (1000s, WAF blocks, captchas) for zones and accounts`,()=>import(`./custom-pages-D-oErw57.mjs`)),hideCommand:!0},{command:$(`d1`,`D1 is Cloudflare's managed, serverless database with SQLite's SQL semantics, built-in disaster recovery, and Worker and HTTP API access.`,()=>import(`./d1-C95ckPKI.mjs`)),hideCommand:!0},{command:$(`dcv-delegation`,`Delegate domain control validation (DCV) to Cloudflare so certificates auto-renew without manual DNS changes`,()=>import(`./dcv-delegation-CWSkbGuc.mjs`)),hideCommand:!0},{command:$(`diagnostics`,`Network diagnostic tools — traceroutes from Cloudflare's edge and endpoint health checks`,()=>import(`./diagnostics-DEEhPnXj.mjs`)),hideCommand:!0},{command:$(`dispatch-namespaces`,`Workers for Platforms dispatch namespaces — isolate customer Workers for SaaS and multi-tenant deployments`,()=>import(`./dispatch-namespaces-BzXeV7PH.mjs`)),hideCommand:!0},{command:$(`dns`,`DNS management API for zones, records, DNSSEC, analytics, and zone transfers`,()=>import(`./dns-qW-3TZOT.mjs`)),hideCommand:!1},{command:$(`dns-firewall`,`DNS proxy clusters that filter and forward DNS queries with DDoS protection and caching`,()=>import(`./dns-firewall-BQXD_NxG.mjs`)),hideCommand:!0},{command:$(`durable-objects`,`Stateful serverless objects with transactional storage, ideal for coordination, sessions, and real-time collaboration`,()=>import(`./durable-objects-CgWFYEJJ.mjs`)),hideCommand:!0},{command:$(`email-routing`,`Route incoming emails to destination addresses using custom rules, catch-all handlers, and DNS configuration`,()=>import(`./email-routing-tdNJaCpJ.mjs`)),hideCommand:!0},{command:$(`email-security`,`Cloud email security (Area 1) — investigate threats, manage allow/block policies, and detect phishing`,()=>import(`./email-security-DTVHNr2h.mjs`)),hideCommand:!0},{command:$(`email-sending`,`Send emails and manage sending subdomains`,()=>import(`./email-sending-DsFTvE31.mjs`)),hideCommand:!0},{command:$(`filters`,`Filter expressions used by legacy firewall rules to match requests — prefer Rulesets for new configurations`,()=>import(`./filters-DO1Is_tI.mjs`)),hideCommand:!0},{command:$(`firewall`,`Legacy firewall rules, zone lockdowns, access rules, user-agent blocking, and WAF packages`,()=>import(`./firewall-DbUhVTCg.mjs`)),hideCommand:!0},{command:$(`fraud`,`Fraud detection for login and signup flows — identify credential stuffing, account takeover, and fake accounts`,()=>import(`./fraud-Bzr4njYb.mjs`)),hideCommand:!0},{command:$(`google-tag-gateway`,`Google Tag Gateway operations`,()=>import(`./google-tag-gateway-BQxkA90M.mjs`)),hideCommand:!0},{command:$(`healthchecks`,`Standalone health checks that monitor origin server availability from Cloudflare's edge`,()=>import(`./healthchecks-BBAs-lS_.mjs`)),hideCommand:!0},{command:$(`hostnames`,`Per-hostname TLS settings — minimum TLS version, ciphers, and certificate pinning overrides`,()=>import(`./hostnames-Dz9PEUKS.mjs`)),hideCommand:!0},{command:$(`hyperdrive`,`Accelerate access to existing databases by caching queries and pooling connections at the edge`,()=>import(`./hyperdrive-B1iUJddG.mjs`)),hideCommand:!0},{command:$(`iam`,`Identity and access management — permission groups, resource groups, user groups, and SSO connectors`,()=>import(`./iam-CJM8gHpG.mjs`)),hideCommand:!0},{command:$(`images`,`Store, resize, and deliver optimized images globally — variants, signing keys, and direct uploads`,()=>import(`./images-DEoBmtFS.mjs`)),hideCommand:!0},{command:$(`intel`,`Threat intelligence lookups — IP reputation, domain info, ASN details, WHOIS, and indicator feeds`,()=>import(`./intel-BM6xkZ0C.mjs`)),hideCommand:!0},{command:$(`ips`,`List Cloudflare's IP ranges used for proxying traffic — useful for firewall allowlisting`,()=>import(`./ips-B8fwxKZD.mjs`)),hideCommand:!0},{command:$(`keyless-certificates`,`Use your own SSL certificates without exposing private keys — keys stay on your infrastructure`,()=>import(`./keyless-certificates-DffYnd4b.mjs`)),hideCommand:!0},{command:$(`kv`,`Global, low-latency key-value storage for Workers — namespaces, keys, values, and bulk operations`,()=>import(`./kv-BTceLtWZ.mjs`)),hideCommand:!0},{command:$(`leaked-credential-checks`,`Detect compromised credentials in login requests by checking against known breach databases`,()=>import(`./leaked-credential-checks-CALfvoCo.mjs`)),hideCommand:!0},{command:$(`load-balancers`,`Distribute traffic across origin pools with health monitoring, geo-steering, and failover`,()=>import(`./load-balancers-C1Ho1gCF.mjs`)),hideCommand:!0},{command:$(`logpush`,`Push Cloudflare logs to external storage destinations — R2, S3, Splunk, Datadog, and more`,()=>import(`./logpush-CSYhgevA.mjs`)),hideCommand:!0},{command:$(`logs`,`Log control, retention, and raw log access — CMB config, ray ID lookups, and received fields`,()=>import(`./logs-DlIwmMpt.mjs`)),hideCommand:!0},{command:$(`magic-cloud-networking`,`Multi-cloud networking — discover cloud resources, manage on-ramps, and automate cross-cloud connectivity`,()=>import(`./magic-cloud-networking-Czu0pZ0a.mjs`)),hideCommand:!0},{command:$(`magic-network-monitoring`,`Flow-based network traffic monitoring with configurable alerting rules and VPC flow ingestion`,()=>import(`./magic-network-monitoring-d7GJE5Yt.mjs`)),hideCommand:!0},{command:$(`magic-transit`,`DDoS-protected network transit — GRE/IPsec tunnels, static routes, Magic WAN sites, connectors, and packet captures`,()=>import(`./magic-transit-qQmA-981.mjs`)),hideCommand:!0},{command:$(`managed-transforms`,`Cloudflare-managed HTTP header transforms — automatically add security headers, remove server info, etc.`,()=>import(`./managed-transforms-Dd6AnbWE.mjs`)),hideCommand:!0},{command:$(`mtls-certificates`,`Upload and manage mTLS certificates used by API Shield, Workers, and Gateway for client authentication`,()=>import(`./mtls-certificates-C0rlCRGs.mjs`)),hideCommand:!0},{command:$(`network-interconnects`,`Physical and virtual private interconnects between your infrastructure and Cloudflare's network`,()=>import(`./network-interconnects-CxG2deY0.mjs`)),hideCommand:!0},{command:$(`organizations`,`Multi-user organizations that group accounts, members, and shared settings under a single entity`,()=>import(`./organizations-DyEAiGiR.mjs`)),hideCommand:!0},{command:$(`origin-ca-certificates`,`Free Cloudflare-signed certificates installed on your origin server for Full (strict) SSL mode`,()=>import(`./origin-ca-certificates-S8RcoMF6.mjs`)),hideCommand:!0},{command:$(`origin-post-quantum-encryption`,`Enable post-quantum key exchange for connections between Cloudflare and your origin server`,()=>import(`./origin-post-quantum-encryption-B8ZcpLu5.mjs`)),hideCommand:!0},{command:$(`origin-tls-client-auth`,`Authenticated Origin Pulls — require Cloudflare to present a client certificate when connecting to your origin`,()=>import(`./origin-tls-client-auth-BlxMmQrE.mjs`)),hideCommand:!0},{command:$(`page-rules`,`Legacy URL-pattern rules that override zone settings for matching requests — prefer Rules/Transform Rules instead`,()=>import(`./page-rules-DP-w6TAm.mjs`)),hideCommand:!0},{command:$(`page-shield`,`Client-side security — monitor JavaScript, connections, and cookies on your pages for supply-chain attacks`,()=>import(`./page-shield-Bf7kFp8c.mjs`)),hideCommand:!0},{command:$(`pages`,`Full-stack application hosting with Git-integrated builds, preview deployments, and custom domains`,()=>import(`./pages-D0Y_XRqW.mjs`)),hideCommand:!0},{command:$(`pipelines`,`Ingest, transform, and route event streams into R2, analytics, or other destinations in real time`,()=>import(`./pipelines-C-SPESAk.mjs`)),hideCommand:!0},{command:$(`queues`,`Reliable message queuing between Workers — produce, consume, and batch-process messages at scale`,()=>import(`./queues-wv6CZsi8.mjs`)),hideCommand:!0},{command:$(`r2`,`S3-compatible object storage with zero egress fees — buckets, lifecycle rules, event notifications, and data migration`,()=>import(`./r2-DuXjp9n5.mjs`)),hideCommand:!0},{command:$(`r2-data-catalog`,`Iceberg-compatible data catalog for R2 — organize objects into tables and namespaces for SQL query engines`,()=>import(`./r2-data-catalog-DQCMrmNO.mjs`)),hideCommand:!0},{command:$(`radar`,`Internet-wide traffic intelligence — BGP, DNS, HTTP trends, attack data, and network quality insights`,()=>import(`./radar-BW_ZHP8X.mjs`)),hideCommand:!0},{command:$(`rate-limits`,`Legacy per-zone rate limiting rules — prefer Advanced Rate Limiting in Rulesets for new configurations`,()=>import(`./rate-limits-DLTkIvwr.mjs`)),hideCommand:!0},{command:$(`realtime-kit`,`Real-time video and audio — meetings, livestreams, recordings, and session management via Cloudflare Calls`,()=>import(`./realtime-kit-Ch7Vg3vj.mjs`)),hideCommand:!0},{command:$(`registrar`,`Domain registration and transfer management through Cloudflare Registrar`,()=>import(`./registrar-DIIv6fWd.mjs`)),hideCommand:!1},{command:$(`request-tracers`,`Trace how a request would be processed through Cloudflare's rules and configuration pipeline`,()=>import(`./request-tracers-DMej0Drs.mjs`)),hideCommand:!0},{command:$(`resource-sharing`,`Share Cloudflare resources (zones, accounts) across organizations with granular access controls`,()=>import(`./resource-sharing-CYJ7cMWq.mjs`)),hideCommand:!0},{command:$(`resource-tagging`,`Tag accounts and zones with key-value metadata for organization, filtering, and policy targeting`,()=>import(`./resource-tagging-Dnz65MgH.mjs`)),hideCommand:!0},{command:$(`rules`,`Account-level IP lists, hostname lists, and other reusable lists referenced by firewall rules and rulesets`,()=>import(`./rules-DLJpOYbC.mjs`)),hideCommand:!0},{command:$(`rulesets`,`Versioned collections of rules that control how Cloudflare processes traffic — WAF, transform, redirect, and more`,()=>import(`./rulesets-D9nqEJT5.mjs`)),hideCommand:!0},{command:$(`rum`,`Real User Measurement (Web Analytics) — track page loads, Core Web Vitals, and visitor metrics`,()=>import(`./rum-DBVmdPkp.mjs`)),hideCommand:!0},{command:$(`schema-validation`,`API schema validation settings — enforce request/response schemas and configure validation behavior`,()=>import(`./schema-validation-MCd3xdtX.mjs`)),hideCommand:!0},{command:$(`scim`,`SCIM 2.0 provisioning — manage users, groups, and identity provider sync for your account`,()=>import(`./scim-DZA3VXog.mjs`)),hideCommand:!0},{command:$(`scm`,`Source code management connections — link Git providers, browse repos, create pull requests, and manage grants`,()=>import(`./scm-CilfPOue.mjs`)),hideCommand:!0},{command:$(`secrets-store`,`Centralized secret management — store API keys, tokens, and credentials for use across Workers and other products`,()=>import(`./secrets-store-BrvcZSOM.mjs`)),hideCommand:!0},{command:$(`security-center`,`Security posture dashboard — view and manage security insights, misconfigurations, and vulnerabilities`,()=>import(`./security-center-BU6f3Cm1.mjs`)),hideCommand:!0},{command:$(`security-txt`,`Manage the /.well-known/security.txt file that tells security researchers how to report vulnerabilities`,()=>import(`./security-txt-BPIbP3dG.mjs`)),hideCommand:!0},{command:$(`smart-shield`,`Smart Shield settings, health checks, and cache reserve management`,()=>import(`./smart-shield-e8XFBkiF.mjs`)),hideCommand:!0},{command:$(`snippets`,`Lightweight JavaScript snippets that run on requests before Workers — for quick header modifications and redirects`,()=>import(`./snippets-B4M3MMb8.mjs`)),hideCommand:!0},{command:$(`spectrum`,`Proxy and protect arbitrary TCP/UDP applications through Cloudflare's network with DDoS mitigation`,()=>import(`./spectrum-B0adfSRI.mjs`)),hideCommand:!0},{command:$(`speed`,`Observatory speed tests — run Lighthouse audits, track performance trends, and schedule recurring tests`,()=>import(`./speed-BVcUtkAz.mjs`)),hideCommand:!0},{command:$(`ssl`,`SSL/TLS certificate management — certificate packs, Universal SSL, verification, and TLS mode recommendations`,()=>import(`./ssl-BAa91gsc.mjs`)),hideCommand:!0},{command:$(`stream`,`Video encoding, storage, and delivery — upload, live-stream, clip, caption, and embed video at scale`,()=>import(`./stream-D53sxKb3.mjs`)),hideCommand:!0},{command:$(`tenants`,`Multi-tenant account management — manage tenant accounts, entitlements, and memberships`,()=>import(`./tenants-bH5pt3dJ.mjs`)),hideCommand:!0},{command:$(`token-validation`,`Validate JWT tokens at the edge — configure token sources, signing keys, and validation rules`,()=>import(`./token-validation-M61Vx_Tw.mjs`)),hideCommand:!0},{command:$(`turnstile`,`CAPTCHA-free bot verification widgets that protect forms and APIs without degrading user experience`,()=>import(`./turnstile-wAU0Gc2Z.mjs`)),hideCommand:!0},{command:$(`url-normalization`,`Normalize incoming request URLs to a consistent format before rule evaluation and caching`,()=>import(`./url-normalization-DZrWDgB5.mjs`)),hideCommand:!0},{command:$(`url-scanner`,`Scan URLs for phishing, malware, and other threats — submit scans and retrieve detailed results`,()=>import(`./url-scanner-Zo49edNp.mjs`)),hideCommand:!0},{command:$(`user`,`Your Cloudflare user profile, invitations, organizations, billing, and personal API tokens`,()=>import(`./user-DbXlVReB.mjs`)),hideCommand:!0},{command:$(`vectorize`,`Globally distributed vector database for building semantic search, recommendations, and RAG applications on Workers`,()=>import(`./vectorize-CUnTM0DT.mjs`)),hideCommand:!0},{command:$(`vuln-scanner`,`Vulnerability scanning for web applications — manage scans, credential sets, and scan reports`,()=>import(`./vuln-scanner-Br_2lQp1.mjs`)),hideCommand:!0},{command:$(`waiting-rooms`,`Virtual queues that throttle traffic to your site during peak demand with customizable waiting pages`,()=>import(`./waiting-rooms-BZW0X69-.mjs`)),hideCommand:!0},{command:$(`web3`,`Web3 gateways — serve IPFS and Ethereum content through custom hostnames on Cloudflare`,()=>import(`./web3-DueyOQtx.mjs`)),hideCommand:!0},{command:$(`workers`,`Deploy and manage serverless JavaScript/WASM applications on Cloudflare's global network`,()=>import(`./workers-nV_vBCfV.mjs`)),hideCommand:!0},{command:$(`workers-builds`,`Automated build and deployment pipeline for Workers — track builds, logs, and repo connections`,()=>import(`./workers-builds-BM_aoeUR.mjs`)),hideCommand:!0},{command:$(`workflows`,`Durable, multi-step workflows that run on Workers with automatic retries and state persistence`,()=>import(`./workflows-CQITmo-s.mjs`)),hideCommand:!0},{command:$(`zaraz`,`Server-side tag manager — load third-party tools (analytics, pixels, etc.) from Cloudflare's edge without client-side JS`,()=>import(`./zaraz-DIbpF5Op.mjs`)),hideCommand:!0},{command:$(`zero-trust`,`Cloudflare's SASE platform — secure access, device posture, DLP, tunnels, gateway policies, and network segmentation`,()=>import(`./zero-trust-CKp8j512.mjs`)),hideCommand:!0},{command:$(`zones`,`Zones are domains on Cloudflare — list, create, and configure domain settings`,()=>import(`./zones-BZ5tZDbH.mjs`)),hideCommand:!1}];function ur(e){try{let t=new URL(e);return`${t.pathname.replace(/^\/client\/v\d+/,``)}${t.search}`}catch{return e}}function dr(e){if(s(a),e instanceof n){let t=u(),n=pr(e.status),r=[];if(e.error){let t=e.error;Array.isArray(t.errors)&&(r=t.errors)}let i=e.request?`${e.request.method} ${ur(e.request.url)}`:void 0,a=`${e.status} ${n}`,o=i?`${a} · ${i}`:a,s=t.dim(o),c=``;return c=r.length>0?r.map((e,n)=>{let i=typeof e.code==`number`?t.hex(d.error).bold(`[${e.code}]`):t.hex(d.error).bold(`[error]`),a=t.bold(e.message??``);return n===r.length-1?`${i} ${a}\n${s}`:`${i} ${a}`}).join(`
99
99
 
100
100
  `):t.hex(d.error).bold(o),console.error(f(c,void 0,{title:`APIError`,rawMessage:!0})),e.status===401?console.error(`
101
101
  `+p(`Try running: cf auth login`)):e.status===403&&console.error(`
@@ -103,6 +103,6 @@ complete -o bashdefault -o default -F _{{app_name}}_yargs_completions {{app_name
103
103
 
104
104
  `)}else{let n=t.hex(d.error).bold(e.message);a=r?`${n}\n${r}`:n}return console.error(f(a,void 0,{title:`APIError`,rawMessage:!0})),e.status===401?console.error(`
105
105
  `+p(`Try running: cf auth login`)):e.status===403&&console.error(`
106
- `+p(`Check your API token permissions`)),e}if(e instanceof Error){let t=process.env.DEBUG&&e.stack?fr(e.stack):void 0;return console.error(f(e.message,t)),e}return console.error(f(`An unexpected error occurred`,String(e))),e}function fr(e){return e.replace(/[A-Za-z0-9_-]{40,}/g,`[REDACTED]`)}function pr(e){return{400:`Bad Request`,401:`Unauthorized`,403:`Forbidden`,404:`Not Found`,405:`Method Not Allowed`,409:`Conflict`,422:`Unprocessable Entity`,429:`Too Many Requests`,500:`Internal Server Error`,502:`Bad Gateway`,503:`Service Unavailable`,504:`Gateway Timeout`}[e]??``}const mr=$(`auth`,`Authentication commands (login, logout, whoami)`,()=>import(`./auth-DQ8miey6.mjs`)),hr=$(`context`,`Manage default account and zone context`,()=>import(`./context-DTIbtQn5.mjs`)),gr=$(`complete [shell]`,`Generate and handle shell completions`,()=>import(`./completions-BKrxcfhN.mjs`)),_r=$(`schema [command..]`,`Show API schema details for a command`,()=>import(`./schema-D0_cbcDt.mjs`)),vr=$(`agent-context [product]`,`Output agent context and tool definitions`,()=>import(`./agent-context-D26woB9J.mjs`)),yr=$(`tools`,!1,()=>import(`./tools-CtKbk6VS.mjs`)),br=$(`dev [implArgs..]`,`Run the project's Cloudflare dev server`,()=>import(`./dev-BfKYB-R_.mjs`)),xr=$(`build`,`Build a project for Cloudflare`,()=>import(`./build-C_48VvoK.mjs`)),Sr=$(`deploy`,`Deploy a project to Cloudflare`,()=>import(`./deploy--9wYOkHg.mjs`));function Cr(e){return e.includes(`--quiet`)||e.includes(`-q`)}function wr(){process.stderr.isTTY&&(Cr(process.argv.slice(2))||process.argv.slice(2).find(e=>!e.startsWith(`-`))!==`complete`&&import(`./config-BIfdEY0E.mjs`).then(e=>e.t).then(({loadConfig:e,updateConfig:t})=>{e().completions?.prompted||(process.stderr.write(l.muted("Tip: run `cf complete <bash|zsh|fish>` to install shell completions.\n")),t({completions:{prompted:!0}}))}))}function Tr(){let e=process.argv.slice(2);return!e.includes(`--version`)&&!e.includes(`-v`)?!1:(console.log(r(a)),!0)}function Er(){if(process.argv.slice(2).length>0)return!1;let e=[r(a),``,`The Cloudflare CLI — manage your account, zones, and developer platform.`,``,`${l.bold(`Get started:`)}`,` ${l.code(`cf auth login`)} ${l.muted(`Authenticate with Cloudflare`)}`,` ${l.code(`cf --help`)} ${l.muted(`Browse all commands`)}`,` ${l.code(`cf <command> --help`)} ${l.muted(`Per-command help`)}`,` ${l.code(`cf complete bash`)} ${l.muted(`Install shell completions`)}`,``,`${l.bold(`Docs:`)} ${l.brand(`https://developers.cloudflare.com/`)}`,``];return console.log(e.join(`
107
- `)),!0}function Dr(){let e=process.argv.slice(2);e.length!==0&&(e.includes(`--version`)||e.includes(`-v`)||e.find(e=>!e.startsWith(`-`))!==`complete`&&s(a,{quiet:Cr(e)}))}function Or(e){let t=e=>l.brand(e),n=cr(e).scriptName(`cf`).usage(`$0 <command> [options]`).usage(`
108
- The Cloudflare CLI - manage your Cloudflare resources`).updateStrings({"Commands:":t(`Commands`),"Options:":t(`Options`),"Positionals:":t(`Positionals`),"Examples:":t(`Examples`)}).help(`help`,`Show help`).alias(`h`,`help`).option(`quiet`,{type:`boolean`,alias:`q`,description:`Suppress non-essential output`,global:!0,default:!1}).option(`zone`,{type:`string`,alias:`z`,description:`Zone ID or domain name (overrides CLOUDFLARE_ZONE_ID)`,global:!0}).option(`local`,{type:`boolean`,description:"Route to a local `wrangler dev` / `cf dev` Miniflare session",global:!0,default:!1}).option(`local-endpoint`,{type:`string`,description:`Local Miniflare endpoint URL (required with --local until auto-discovery ships)`,global:!0}).group([`quiet`,`zone`,`local`,`local-endpoint`,`help`,`version`],t(`Global flags`)).command(mr).command(hr).command(xr).command(gr).command(Sr).command(br).command(_r).command(vr).command(yr);for(let e of lr)e.hideCommand?n.command({...e.command,describe:!1}):n.command(e.command);return n.middleware(e=>{if(e.local&&!e.localEndpoint)throw Error("--local requires --local-endpoint <url> (e.g. http://127.0.0.1:8787).\nDiscovery via the dev registry will land in a future release; until then,\npoint cf at your running `wrangler dev` / `cf dev` session explicitly.")}).demandCommand(1,`You need to specify a command`).strict().version(a).alias(`v`,`version`).epilogue(`For more information, visit https://developers.cloudflare.com/`).exitProcess(!1).fail((e,t,n)=>{if(t)throw t;if(e===`Please specify a subcommand`){n.showHelp(`log`);return}throw Error(e)}),n}var kr=class extends Error{constructor(e){super(`CliExit(${e})`),this.code=e,this.name=`CliExit`}};async function Ar(e){let t=process.argv;process.argv=[`node`,`cf`,...e];try{await jr()}finally{process.argv=t}}async function jr(){if(Tr()||Er())throw new kr(0);Dr();let e=Or(ot(process.argv));wr();try{await e.parse(ot(process.argv))}catch(e){throw e instanceof kr?e:dr(e)}}export{Ar as i,Or as n,jr as r,kr as t};
106
+ `+p(`Check your API token permissions`)),e}if(e instanceof Error){let t=process.env.DEBUG&&e.stack?fr(e.stack):void 0;return console.error(f(e.message,t)),e}return console.error(f(`An unexpected error occurred`,String(e))),e}function fr(e){return e.replace(/[A-Za-z0-9_-]{40,}/g,`[REDACTED]`)}function pr(e){return{400:`Bad Request`,401:`Unauthorized`,403:`Forbidden`,404:`Not Found`,405:`Method Not Allowed`,409:`Conflict`,422:`Unprocessable Entity`,429:`Too Many Requests`,500:`Internal Server Error`,502:`Bad Gateway`,503:`Service Unavailable`,504:`Gateway Timeout`}[e]??``}const mr=$(`auth`,`Authentication commands (login, logout, whoami)`,()=>import(`./auth-DenWm_X0.mjs`)),hr=$(`context`,`Manage default account and zone context`,()=>import(`./context-CC0Rhkhy.mjs`)),gr=$(`complete [shell]`,`Generate and handle shell completions`,()=>import(`./completions-BKrxcfhN.mjs`)),_r=$(`schema [command..]`,`Show API schema details for a command`,()=>import(`./schema-CHBfkARI.mjs`)),vr=$(`agent-context [product]`,`Output agent context and tool definitions`,()=>import(`./agent-context-D26woB9J.mjs`)),yr=$(`tools`,!1,()=>import(`./tools-B7QiNu-d.mjs`)),br=$(`dev [implArgs..]`,`Run the project's Cloudflare dev server`,()=>import(`./dev-C6iSuQZm.mjs`)),xr=$(`build`,`Build a project for Cloudflare`,()=>import(`./build-5jmmOZhm.mjs`).then(e=>e.t)),Sr=$(`deploy`,`Deploy a project to Cloudflare`,()=>import(`./deploy-DbkiIzUr.mjs`)),Cr=$(`versions`,`Manage Worker Versions`,()=>import(`./versions-DzyrlUAi.mjs`));function wr(e){return e.includes(`--quiet`)||e.includes(`-q`)}function Tr(){process.stderr.isTTY&&(wr(process.argv.slice(2))||process.argv.slice(2).find(e=>!e.startsWith(`-`))!==`complete`&&import(`./config-DYzlVxcB.mjs`).then(e=>e.t).then(({loadConfig:e,updateConfig:t})=>{e().completions?.prompted||(process.stderr.write(l.muted("Tip: run `cf complete <bash|zsh|fish>` to install shell completions.\n")),t({completions:{prompted:!0}}))}))}function Er(){let e=process.argv.slice(2);return!e.includes(`--version`)&&!e.includes(`-v`)?!1:(console.log(r(a)),!0)}function Dr(){if(process.argv.slice(2).length>0)return!1;let e=[r(a),``,`The Cloudflare CLI — manage your account, zones, and developer platform.`,``,`${l.bold(`Get started:`)}`,` ${l.code(`cf auth login`)} ${l.muted(`Authenticate with Cloudflare`)}`,` ${l.code(`cf --help`)} ${l.muted(`Browse all commands`)}`,` ${l.code(`cf <command> --help`)} ${l.muted(`Per-command help`)}`,` ${l.code(`cf complete bash`)} ${l.muted(`Install shell completions`)}`,``,`${l.bold(`Docs:`)} ${l.brand(`https://developers.cloudflare.com/`)}`,``];return console.log(e.join(`
107
+ `)),!0}function Or(){let e=process.argv.slice(2);e.length!==0&&(e.includes(`--version`)||e.includes(`-v`)||e.find(e=>!e.startsWith(`-`))!==`complete`&&s(a,{quiet:wr(e)}))}function kr(e){let t=e=>l.brand(e),n=cr(e).scriptName(`cf`).usage(`$0 <command> [options]`).usage(`
108
+ The Cloudflare CLI - manage your Cloudflare resources`).updateStrings({"Commands:":t(`Commands`),"Options:":t(`Options`),"Positionals:":t(`Positionals`),"Examples:":t(`Examples`)}).help(`help`,`Show help`).alias(`h`,`help`).option(`quiet`,{type:`boolean`,alias:`q`,description:`Suppress non-essential output`,global:!0,default:!1}).option(`zone`,{type:`string`,alias:`z`,description:`Zone ID or domain name (overrides CLOUDFLARE_ZONE_ID)`,global:!0}).option(`local`,{type:`boolean`,description:"Route to a local `wrangler dev` / `cf dev` Miniflare session",global:!0,default:!1}).option(`local-endpoint`,{type:`string`,description:`Local Miniflare endpoint URL (required with --local until auto-discovery ships)`,global:!0}).group([`quiet`,`zone`,`local`,`local-endpoint`,`help`,`version`],t(`Global flags`)).command(mr).command(hr).command(xr).command(gr).command(Sr).command(br).command(Cr).command(_r).command(vr).command(yr);for(let e of lr)e.hideCommand?n.command({...e.command,describe:!1}):n.command(e.command);return n.middleware(e=>{if(e.local&&!e.localEndpoint)throw Error("--local requires --local-endpoint <url> (e.g. http://127.0.0.1:8787).\nDiscovery via the dev registry will land in a future release; until then,\npoint cf at your running `wrangler dev` / `cf dev` session explicitly.")}).demandCommand(1,`You need to specify a command`).strict().version(a).alias(`v`,`version`).epilogue(`For more information, visit https://developers.cloudflare.com/`).exitProcess(!1).fail((e,t,n)=>{if(t)throw t;if(e===`Please specify a subcommand`){n.showHelp(`log`);return}throw n.showHelp(`error`),Error(e)}),n}var Ar=class extends Error{constructor(e){super(`CliExit(${e})`),this.code=e,this.name=`CliExit`}};async function jr(e){let t=process.argv;process.argv=[`node`,`cf`,...e];try{await Mr()}finally{process.argv=t}}async function Mr(){if(Er()||Dr())throw new Ar(0);Or();let e=kr(ot(process.argv));Tr();try{await e.parse(ot(process.argv))}catch(e){throw e instanceof Ar?e:dr(e)}}export{jr as i,kr as n,Mr as r,Ar as t};
@@ -0,0 +1,15 @@
1
+ #!/usr/bin/env node
2
+ import{C as e,b as t,t as n,w as r}from"./auth-CQcAgnOy.mjs";import{n as i,t as a}from"./body-parser-Br-BoYk-.mjs";import{t as o}from"./output-D7_yAFVR.mjs";import{n as s,t as c}from"./progress-CjcQ6ato.mjs";import{n as l}from"./input-validation-zEO81MWN.mjs";function u(e){return e.option(`bundle-method`,{type:`string`,description:`A ubiquitous bundle has the highest probability of being verified everywhere, even by clients using outdated or unusual trust stores. An optimal bundle uses the shortest chain and newest intermediates. And the force bundle verifies the chain, but does not otherwise modify it.`,choices:[`ubiquitous`,`optimal`,`force`],default:`ubiquitous`}).option(`certificate`,{type:`string`,description:`The zone's SSL certificate or certificate and the intermediate(s).`}).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:`create`,describe:`Returns the set of hostnames, the signature algorithm, and the expiration date of the certificate.`,builder:u,handler:async e=>{if(e.dryRun){s({command:`cf ssl analyze create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/ssl/analyze`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:{"bundle-method":e[`bundle-method`],certificate:e.certificate,body:e.body}});return}let r=await n(e);if(e.zoneId=await t({zone:e.zone},r,{quiet:e.quiet}),e.body){let t=a(e.body);o(await c(`Creating`,async()=>r.post(`/zones/${e.zoneId}/ssl/analyze`,{body:t})),{successLabel:`Created`});return}let u={};e[`bundle-method`]!==void 0&&i(u,[`bundle_method`],l(e[`bundle-method`],`bundle-method`,`text`)),e.certificate!==void 0&&i(u,[`certificate`],l(e.certificate,`certificate`,`text`)),o(await c(`Creating`,async()=>r.post(`/zones/${e.zoneId}/ssl/analyze`,{body:Object.keys(u).length>0?u:void 0})),{successLabel:`Created`})}},f={command:`analyze`,describe:`Analyze a certificate or certificate chain for validity and compatibility issues`,builder:e=>e.command(d).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function p(e){return e.option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const m={command:`get`,describe:`If the system is enabled, the response will include next_scheduled_scan, representing the next time this zone will be scanned and the zone's ssl/tls encryption mode is potentially upgraded by the system. If the system is disabled, next_scheduled_scan will not be present in the response body.`,builder:p,handler:async e=>{if(e.dryRun){s({command:`cf ssl automatic-upgrader get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/settings/ssl_automatic_mode`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let r=await n(e),i=await t({zone:e.zone},r,{quiet:e.quiet});e.zoneId=i,o(await c(`Loading`,async()=>r.ssl.automaticUpgrader.get(i)),{successLabel:`Loaded`})}};function h(e){return e.option(`value`,{type:`string`,description:`Controls enablement of Automatic SSL/TLS.`,choices:[`auto`,`custom`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Update enablement of Automatic SSL/TLS.`})}const g={command:`patch`,describe:`The automatic system is enabled when this endpoint is hit with value in the request body is set to "auto", and disabled when the request body value is set to "custom".`,builder:h,handler:async e=>{if(e.dryRun){s({command:`cf ssl automatic-upgrader patch`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/settings/ssl_automatic_mode`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:{value:e.value,body:e.body}});return}let u=await n(e);if(e.zoneId=await t({zone:e.zone},u,{quiet:e.quiet}),e.body){let t=a(e.body);o(await c(`Updating`,async()=>u.patch(`/zones/${e.zoneId}/settings/ssl_automatic_mode`,{body:t})),{successLabel:`Updated`});return}e.value===void 0&&(e.value=await r(`value`,`Controls enablement of Automatic SSL/TLS.`,[`auto`,`custom`]));let d={};e.value!==void 0&&i(d,[`value`],l(e.value,`value`,`text`)),o(await c(`Updating`,async()=>u.patch(`/zones/${e.zoneId}/settings/ssl_automatic_mode`,{body:Object.keys(d).length>0?d:void 0})),{successLabel:`Updated`})}},_={command:`automatic-upgrader`,describe:`SSL automatic mode enrollment — get or update automatic SSL/TLS upgrader settings`,builder:e=>e.command(m).command(g).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function v(e){return e.option(`certificate-authority`,{type:`string`,description:`Certificate Authority selected for the order. For information on any certificate authority specific details or restrictions [see this page for more details.](https://developers.cloudflare.com/ssl/reference/certificate-authorities)`,choices:[`google`,`lets_encrypt`,`ssl_com`]}).option(`cloudflare-branding`,{type:`boolean`,description:`Whether or not to add Cloudflare Branding for the order. This will add a subdomain of sni.cloudflaressl.com as the Common Name if set to true.`}).option(`hosts`,{type:`string`,array:!0,description:`Comma separated list of valid host names for the certificate packs. Must contain the zone apex, may not contain more than 50 hosts, and may not be empty.`}).option(`type`,{type:`string`,description:`Type of certificate pack.`,choices:[`advanced`]}).option(`validation-method`,{type:`string`,description:`Validation Method selected for the order.`,choices:[`txt`,`http`,`email`]}).option(`validity-days`,{type:`number`,description:`Validity Days selected for the order.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const y={command:`create`,describe:`For a given zone, order an advanced certificate pack.`,builder:v,handler:async e=>{if(e.dryRun){s({command:`cf ssl certificate-packs create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/ssl/certificate_packs/order`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:{"certificate-authority":e[`certificate-authority`],"cloudflare-branding":e[`cloudflare-branding`],hosts:e.hosts,type:e.type,"validation-method":e[`validation-method`],"validity-days":e[`validity-days`],body:e.body}});return}let u=await n(e);if(e.zoneId=await t({zone:e.zone},u,{quiet:e.quiet}),e.body){let t=a(e.body);o(await c(`Creating`,async()=>u.post(`/zones/${e.zoneId}/ssl/certificate_packs/order`,{body:t})),{successLabel:`Created`});return}if(e[`certificate-authority`]===void 0&&(e[`certificate-authority`]=await r(`certificate-authority`,`Certificate Authority selected for the order. For information on any certificate authority specific details or restrictions [see this page for more details.](https://developers.cloudflare.com/ssl/reference/certificate-authorities)`,[`google`,`lets_encrypt`,`ssl_com`])),e.hosts===void 0)throw Error(`--hosts is required (or pass --body with this field set).`);if(e.type===void 0&&(e.type=await r(`type`,`Type of certificate pack.`,[`advanced`])),e[`validation-method`]===void 0&&(e[`validation-method`]=await r(`validation-method`,`Validation Method selected for the order.`,[`txt`,`http`,`email`])),e[`validity-days`]===void 0)throw Error(`--validity-days is required (or pass --body with this field set).`);let d={};e[`certificate-authority`]!==void 0&&i(d,[`certificate_authority`],l(e[`certificate-authority`],`certificate-authority`,`text`)),e[`cloudflare-branding`]!==void 0&&i(d,[`cloudflare_branding`],e[`cloudflare-branding`]),e.hosts!==void 0&&i(d,[`hosts`],e.hosts),e.type!==void 0&&i(d,[`type`],l(e.type,`type`,`text`)),e[`validation-method`]!==void 0&&i(d,[`validation_method`],l(e[`validation-method`],`validation-method`,`text`)),e[`validity-days`]!==void 0&&i(d,[`validity_days`],e[`validity-days`]),o(await c(`Creating`,async()=>u.post(`/zones/${e.zoneId}/ssl/certificate_packs/order`,{body:Object.keys(d).length>0?d:void 0})),{successLabel:`Created`})}};function b(e){return e.positional(`certificate-pack-id`,{type:`string`,description:`Identifier.`,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}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const x={command:`delete <certificate-pack-id>`,describe:`For a given zone, delete an advanced certificate pack.`,builder:b,handler:async r=>{if(r.dryRun){s({command:`cf ssl certificate-packs delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${r.zone??r.zoneId??`<zone>`}/ssl/certificate_packs/${r[`certificate-pack-id`]==null?`<certificate-pack-id>`:encodeURIComponent(String(r[`certificate-pack-id`]))}`,pathParams:{"certificate-pack-id":String(r[`certificate-pack-id`]??``),"zone-id":String(r.zone??r[`zone-id`]??``)},bodyKind:`json`,body:{body:r.body}});return}let i=await n(r),l=await t({zone:r.zone},i,{quiet:r.quiet});if(r.zoneId=l,!await e({force:!!r.force})){process.stderr.write(`Aborted.
3
+ `);return}if(r.body){let e=a(r.body);o(await c(`Deleting`,async()=>i.delete(`/zones/${r.zoneId}/ssl/certificate_packs/${encodeURIComponent(String(r[`certificate-pack-id`]))}`,{body:e})),{successLabel:`Deleted`});return}o(await c(`Deleting`,async()=>i.ssl.certificatePacks.delete(r[`certificate-pack-id`],l)),{successLabel:`Deleted`})}};function S(e){return e.positional(`certificate-pack-id`,{type:`string`,description:`Identifier.`,demandOption:!0}).option(`cloudflare-branding`,{type:`boolean`,description:`Whether or not to add Cloudflare Branding for the order. This will add a subdomain of sni.cloudflaressl.com as the Common Name if set to true.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const C={command:`edit <certificate-pack-id>`,describe:`For a given zone, restart validation or add cloudflare branding for an advanced certificate pack. The former is only a validation operation for a Certificate Pack in a validation_timed_out status.`,builder:S,handler:async e=>{if(e.dryRun){s({command:`cf ssl certificate-packs edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/ssl/certificate_packs/${e[`certificate-pack-id`]==null?`<certificate-pack-id>`:encodeURIComponent(String(e[`certificate-pack-id`]))}`,pathParams:{"certificate-pack-id":String(e[`certificate-pack-id`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:{"cloudflare-branding":e[`cloudflare-branding`],body:e.body}});return}let r=await n(e);if(e.zoneId=await t({zone:e.zone},r,{quiet:e.quiet}),e.body){let t=a(e.body);o(await c(`Updating`,async()=>r.patch(`/zones/${e.zoneId}/ssl/certificate_packs/${encodeURIComponent(String(e[`certificate-pack-id`]))}`,{body:t})),{successLabel:`Updated`});return}let l={};e[`cloudflare-branding`]!==void 0&&i(l,[`cloudflare_branding`],e[`cloudflare-branding`]),o(await c(`Updating`,async()=>r.patch(`/zones/${e.zoneId}/ssl/certificate_packs/${encodeURIComponent(String(e[`certificate-pack-id`]))}`,{body:Object.keys(l).length>0?l:void 0})),{successLabel:`Updated`})}};function w(e){return e.positional(`certificate-pack-id`,{type:`string`,description:`Identifier.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const T={command:`get <certificate-pack-id>`,describe:`For a given zone, get a certificate pack.`,builder:w,handler:async e=>{if(e.dryRun){s({command:`cf ssl certificate-packs get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/ssl/certificate_packs/${e[`certificate-pack-id`]==null?`<certificate-pack-id>`:encodeURIComponent(String(e[`certificate-pack-id`]))}`,pathParams:{"certificate-pack-id":String(e[`certificate-pack-id`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let r=await n(e),i=await t({zone:e.zone},r,{quiet:e.quiet});e.zoneId=i,o(await c(`Loading`,async()=>r.ssl.certificatePacks.get(e[`certificate-pack-id`],i)),{successLabel:`Loaded`})}};function E(e){return e.option(`page`,{type:`number`,description:`Page number of paginated results.`}).option(`per-page`,{type:`number`,description:`Number of certificate packs per page.`}).option(`status`,{type:`string`,description:`Include Certificate Packs of all statuses, not just active ones.`,choices:[`all`]}).option(`deploy`,{type:`string`,description:`Specify the deployment environment for the certificate packs.`,choices:[`staging`,`production`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const D={command:`list`,describe:`For a given zone, list all active certificate packs.`,builder:E,handler:async e=>{let r={page:e.page,per_page:e[`per-page`],status:e.status,deploy:e.deploy};if(e.dryRun){s({command:`cf ssl certificate-packs list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/ssl/certificate_packs`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},query:r,bodyKind:`none`});return}let i=await n(e),a=await t({zone:e.zone},i,{quiet:e.quiet});e.zoneId=a,o(await c(`Loading`,async()=>i.ssl.certificatePacks.list(a,r)),{successLabel:`Loaded`})}};function O(e){return e.option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const k={command:`get`,describe:`For a given zone, list certificate pack quotas.`,builder:O,handler:async e=>{if(e.dryRun){s({command:`cf ssl certificate-packs quota get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/ssl/certificate_packs/quota`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let r=await n(e),i=await t({zone:e.zone},r,{quiet:e.quiet});e.zoneId=i,o(await c(`Loading`,async()=>r.ssl.certificatePacks.quota.get(i)),{successLabel:`Loaded`})}},A={command:`quota`,describe:`Advanced Certificate Manager packs — order, renew, and manage dedicated SSL certificates`,builder:e=>e.command(k).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},j={command:`certificate-packs`,describe:`Advanced Certificate Manager packs — order, renew, and manage dedicated SSL certificates`,builder:e=>e.command(y).command(x).command(C).command(T).command(D).command(A).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function M(e){return e.option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const N={command:`get`,describe:`Retrieve the SSL/TLS Recommender's recommendation for a zone.`,builder:M,handler:async e=>{if(e.dryRun){s({command:`cf ssl recommendations get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/ssl/recommendation`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let r=await n(e),i=await t({zone:e.zone},r,{quiet:e.quiet});e.zoneId=i,o(await c(`Loading`,async()=>r.ssl.recommendations.get(i)),{successLabel:`Loaded`})}},P={command:`recommendations`,describe:`Get the recommended SSL/TLS encryption mode based on your origin server's certificate configuration`,builder:e=>e.command(N).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function F(e){return e.option(`enabled`,{type:`boolean`,description:`Disabling Universal SSL removes any currently active Universal SSL certificates for your zone from the edge and prevents any future Universal SSL certificates from being ordered. If there are no advanced certificates or custom certificates uploaded for the domain, visitors will be unable to access the domain over HTTPS.
4
+
5
+ By disabling Universal SSL, you understand that the following Cloudflare settings and preferences will result in visitors being unable to visit your domain unless you have uploaded a custom certificate or purchased an advanced certificate.
6
+
7
+ * HSTS
8
+ * Always Use HTTPS
9
+ * Opportunistic Encryption
10
+ * Onion Routing
11
+ * Any Page Rules redirecting traffic to HTTPS
12
+
13
+ Similarly, any HTTP redirect to HTTPS at the origin while the Cloudflare proxy is enabled will result in users being unable to visit your site without a valid certificate at Cloudflare's edge.
14
+
15
+ If you do not have a valid custom or advanced certificate at Cloudflare's edge and are unsure if any of the above Cloudflare settings are enabled, or if any HTTP redirects exist at your origin, we advise leaving Universal SSL enabled for your domain.`}).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 I={command:`edit`,describe:`Patch Universal SSL Settings for a Zone.`,builder:F,handler:async e=>{if(e.dryRun){s({command:`cf ssl universal settings edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/ssl/universal/settings`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:{enabled:e.enabled,body:e.body}});return}let r=await n(e);if(e.zoneId=await t({zone:e.zone},r,{quiet:e.quiet}),e.body){let t=a(e.body);o(await c(`Updating`,async()=>r.patch(`/zones/${e.zoneId}/ssl/universal/settings`,{body:t})),{successLabel:`Updated`});return}let l={};e.enabled!==void 0&&i(l,[`enabled`],e.enabled),o(await c(`Updating`,async()=>r.patch(`/zones/${e.zoneId}/ssl/universal/settings`,{body:Object.keys(l).length>0?l:void 0})),{successLabel:`Updated`})}};function L(e){return e.option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const R={command:`get`,describe:`Get Universal SSL Settings for a Zone.`,builder:L,handler:async e=>{if(e.dryRun){s({command:`cf ssl universal settings get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/ssl/universal/settings`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let r=await n(e),i=await t({zone:e.zone},r,{quiet:e.quiet});e.zoneId=i,o(await c(`Loading`,async()=>r.ssl.universal.settings.get(i)),{successLabel:`Loaded`})}},z={command:`settings`,describe:`Universal SSL settings — enable/disable automatic free SSL certificates for the zone`,builder:e=>e.command(I).command(R).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},B={command:`universal`,describe:`Operations for universal`,builder:e=>e.command(z).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function V(e){return e.positional(`certificate-pack-id`,{type:`string`,description:`Certificate Pack UUID.`,demandOption:!0}).option(`validation-method`,{type:`string`,description:`Desired validation method.`,choices:[`http`,`cname`,`txt`,`email`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const H={command:`edit <certificate-pack-id>`,describe:`Edit SSL validation method for a certificate pack. A PATCH request will request an immediate validation check on any certificate, and return the updated status. If a validation method is provided, the validation will be immediately attempted using that method.`,builder:V,handler:async e=>{if(e.dryRun){s({command:`cf ssl verification edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/ssl/verification/${e[`certificate-pack-id`]==null?`<certificate-pack-id>`:encodeURIComponent(String(e[`certificate-pack-id`]))}`,pathParams:{"certificate-pack-id":String(e[`certificate-pack-id`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:{"validation-method":e[`validation-method`],body:e.body}});return}let u=await n(e);if(e.zoneId=await t({zone:e.zone},u,{quiet:e.quiet}),e.body){let t=a(e.body);o(await c(`Updating`,async()=>u.patch(`/zones/${e.zoneId}/ssl/verification/${encodeURIComponent(String(e[`certificate-pack-id`]))}`,{body:t})),{successLabel:`Updated`});return}e[`validation-method`]===void 0&&(e[`validation-method`]=await r(`validation-method`,`Desired validation method.`,[`http`,`cname`,`txt`,`email`]));let d={};e[`validation-method`]!==void 0&&i(d,[`validation_method`],l(e[`validation-method`],`validation-method`,`text`)),o(await c(`Updating`,async()=>u.patch(`/zones/${e.zoneId}/ssl/verification/${encodeURIComponent(String(e[`certificate-pack-id`]))}`,{body:Object.keys(d).length>0?d:void 0})),{successLabel:`Updated`})}};function U(e){return e.option(`retry`,{type:`string`,description:`Immediately retry SSL Verification.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const W={command:`get`,describe:`Get SSL Verification Info for a Zone.`,builder:U,handler:async e=>{let r={retry:e.retry};if(e.dryRun){s({command:`cf ssl verification get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/ssl/verification`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},query:r,bodyKind:`none`});return}let i=await n(e),a=await t({zone:e.zone},i,{quiet:e.quiet});e.zoneId=a,o(await c(`Loading`,async()=>i.ssl.verification.get(a,r)),{successLabel:`Loaded`})}},G={command:`verification`,describe:`Check or modify the domain control validation (DCV) method for pending certificate orders`,builder:e=>e.command(H).command(W).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},K={command:`ssl`,describe:`SSL/TLS certificate management — certificate packs, Universal SSL, verification, and TLS mode recommendations`,builder:e=>e.command(f).command(_).command(j).command(P).command(B).command(G).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{K as default};