cf 0.14.0 → 1.0.0-beta.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 (451) hide show
  1. package/LICENSE-APACHE +176 -0
  2. package/LICENSE-MIT +25 -0
  3. package/README.md +6 -7
  4. package/dist/_meta/commands.json +4040 -1629
  5. package/dist/_meta/hand-written-commands.json +16 -43
  6. package/dist/_meta/schemas.json +445 -756
  7. package/dist/abuse-reports-BwsJLiPN.mjs +26 -0
  8. package/dist/access-BVbIajYr.mjs +27 -0
  9. package/dist/account-DBLarar2.mjs +12 -0
  10. package/dist/account-tags-BNrSShjj.mjs +15 -0
  11. package/dist/accounts-CCAnDjFk.mjs +132 -0
  12. package/dist/acm-ZPYQbZQr.mjs +15 -0
  13. package/dist/addressing-BFpzLfTn.mjs +93 -0
  14. package/dist/agent-memory-DEvy2dLU.mjs +34 -0
  15. package/dist/ai-BF0_0NtS.mjs +31 -0
  16. package/dist/ai-audit-Dn03zntn.mjs +6 -0
  17. package/dist/ai-gateway-CVABbCjv.mjs +147 -0
  18. package/dist/ai-search-g0tR8Cut.mjs +79 -0
  19. package/dist/ai-security-BXXA0Jnk.mjs +10 -0
  20. package/dist/alerting-Bst10SOG.mjs +56 -0
  21. package/dist/analytics-DgEaxta8.mjs +21 -0
  22. package/dist/analytics_engine-B4DvcYmB.mjs +4 -0
  23. package/dist/{lifecycle-CadF_i2n.mjs → ansi-styles-eKEZXVwN.mjs} +1 -1
  24. package/dist/api-security-Dkx1Codr.mjs +154 -0
  25. package/dist/argo-BvswWPlP.mjs +10 -0
  26. package/dist/artifacts-D8kZKJq0.mjs +43 -0
  27. package/dist/audit-logs-Bp_yQpXJ.mjs +4 -0
  28. package/dist/auth-B9w55oRg.mjs +2 -0
  29. package/dist/auth-C80y97yu.mjs +8 -0
  30. package/dist/billing-Cqj64fqz.mjs +23 -0
  31. package/dist/bot-management-CzZx_aml.mjs +9 -0
  32. package/dist/botnet-feed-Co0c8Xdj.mjs +11 -0
  33. package/dist/brand-protection-CDsGaPIl.mjs +27 -0
  34. package/dist/browser-extension-BRHJm3Qf.mjs +15 -0
  35. package/dist/browser-run-DFrohJ1p.mjs +46 -0
  36. package/dist/build-BbjcJxKq.mjs +2 -0
  37. package/dist/build-DQh5-KK4.mjs +2 -0
  38. package/dist/builds-CamhClyb.mjs +71 -0
  39. package/dist/cache-BiTk4-Zc.mjs +45 -0
  40. package/dist/certificate-authorities-Dal9DNjW.mjs +6 -0
  41. package/dist/cf-oadujOtC.mjs +18 -0
  42. package/dist/{chunk-6EUZQHAF-B7bSMYLe.mjs → chunk-6EUZQHAF-QVTL_mC-.mjs} +1 -1
  43. package/dist/chunk-DL5FNmn1.mjs +2 -0
  44. package/dist/{chunk-Q72B4Q5Z-CPy_WJKU.mjs → chunk-Q72B4Q5Z-Cr1H_iK6.mjs} +1 -1
  45. package/dist/chunk-Q72B4Q5Z-DKhx_4ok.mjs +2 -0
  46. package/dist/chunk-QBZBEHZB-Byagrlop.mjs +2 -0
  47. package/dist/chunk-XLADBZ7F-BXKOjWbx.mjs +374 -0
  48. package/dist/client-certificates-DDisXoTE.mjs +13 -0
  49. package/dist/client-side-security-CIO_YPtN.mjs +63 -0
  50. package/dist/cloud-connector-vwdixea0.mjs +6 -0
  51. package/dist/cloudflared-DhItYrCq.mjs +2 -0
  52. package/dist/cloudforce-one-C1cFVBGK.mjs +456 -0
  53. package/dist/command-BP7ldws1.mjs +2 -0
  54. package/dist/command-BtNRBTP6.mjs +2 -0
  55. package/dist/{command-BL6weJf3.mjs → command-CF0giIIc.mjs} +1 -1
  56. package/dist/command-Ck9rbHA4.mjs +2 -0
  57. package/dist/{completions-Dn621okY.mjs → completions-xPLd1cvL.mjs} +3 -3
  58. package/dist/{config-BY6KpMZs.mjs → config-B4vIa0zp.mjs} +1 -1
  59. package/dist/connector-interrupts-DQ5T-HMN.mjs +6 -0
  60. package/dist/connector-telemetry-events-DWam38_9.mjs +6 -0
  61. package/dist/connector-telemetry-snapshots-DX6AJf9Q.mjs +6 -0
  62. package/dist/connectors-CBhLWVd-.mjs +15 -0
  63. package/dist/{dist-CFQREIRi.mjs → containers-Bx_44bmJ.mjs} +84 -83
  64. package/dist/containers-C7blN-pe.mjs +78 -0
  65. package/dist/content-scan-CC91dAlv.mjs +14 -0
  66. package/dist/cps-D9a4N_bH.mjs +6 -0
  67. package/dist/csamScanner-T7nbCnep.mjs +10 -0
  68. package/dist/ct-alerting-CkjNJlla.mjs +5 -0
  69. package/dist/custom-certificates-DnWnt9oJ.mjs +17 -0
  70. package/dist/custom-csrs-Db2pF9Ib.mjs +11 -0
  71. package/dist/custom-hostnames-B_N-uSIa.mjs +27 -0
  72. package/dist/custom-nameservers-DPA_sFY8.mjs +9 -0
  73. package/dist/custom-pages-D6fxEBoh.mjs +21 -0
  74. package/dist/d1-DXs1xVmH.mjs +45 -0
  75. package/dist/data-security-CVZAIzhe.mjs +71 -0
  76. package/dist/dcv-delegation-as1ue_wx.mjs +4 -0
  77. package/dist/delegate-GctF_lrq.mjs +2 -0
  78. package/dist/delegate.mjs +1 -1
  79. package/dist/{deploy-BtETDvDA.mjs → deploy-D2XXCkqk.mjs} +1 -1
  80. package/dist/{deploy-input-BoLTdQzS.mjs → deploy-input-BCYyKXpp.mjs} +1 -1
  81. package/dist/{dev-B5WcIpEr.mjs → dev-nsNxyg2D.mjs} +1 -1
  82. package/dist/diagnostics-BKH1Oh-C.mjs +15 -0
  83. package/dist/{dialog-Bud0hiYv.mjs → dialog-Dx4rRcKM.mjs} +1 -1
  84. package/dist/dist-BDOzKthe.mjs +48 -0
  85. package/dist/{dist-BRg_z9Ut.mjs → dist-BpadEMNY.mjs} +1 -1
  86. package/dist/dist-dc4E1u01.mjs +272 -0
  87. package/dist/dls-C5kAQsN6.mjs +17 -0
  88. package/dist/dns-CYwXrdJO.mjs +135 -0
  89. package/dist/dns-firewall-BEw4QcXj.mjs +71 -0
  90. package/dist/{dot-prop-6SRZBKHT-wIVDg_fl.mjs → dot-prop-6SRZBKHT-Dj7YOlwR.mjs} +1 -1
  91. package/dist/dry-run-CLX6Pbtq.mjs +2 -0
  92. package/dist/durable-objects-3jvUgzKd.mjs +8 -0
  93. package/dist/email-auth-B3MD8FrJ.mjs +6 -0
  94. package/dist/email-routing-C4YhZGPw.mjs +45 -0
  95. package/dist/email-security-BcFyWNby.mjs +160 -0
  96. package/dist/email-sending-BO1GOAho.mjs +47 -0
  97. package/dist/error-sanitization-BkgUhGVc.mjs +2 -0
  98. package/dist/error-sanitization-DOlqWkNu.mjs +2 -0
  99. package/dist/fieldExtractors-BJDnzNCN.mjs +9 -0
  100. package/dist/firewall-BSMa9aH3.mjs +56 -0
  101. package/dist/flagship-BJYMb7hb.mjs +28 -0
  102. package/dist/fraud-C7kS7kP9.mjs +22 -0
  103. package/dist/google-tag-gateway-8VR-j0sa.mjs +6 -0
  104. package/dist/healthchecks-BJleItOD.mjs +22 -0
  105. package/dist/hostnames-CHajvoHa.mjs +11 -0
  106. package/dist/hyperdrive-DlxQrok-.mjs +37 -0
  107. package/dist/iam-B7oTr6vW.mjs +52 -0
  108. package/dist/images-xLAYe436.mjs +71 -0
  109. package/dist/index.mjs +1 -1
  110. package/dist/intel-DwZXY1YE.mjs +76 -0
  111. package/dist/{interactive-CGOh-aYq.mjs → interactive-B6woOLo-.mjs} +23 -23
  112. package/dist/interactive-DnUvQHjc.mjs +2 -0
  113. package/dist/ips-BC_9nKE7.mjs +4 -0
  114. package/dist/keyless-certificates-CtsCsbZ2.mjs +13 -0
  115. package/dist/keys-K-GFzhku.mjs +4 -0
  116. package/dist/kv-Bfwz_ULu.mjs +21 -0
  117. package/dist/leaked-credential-checks-D8UuxztO.mjs +18 -0
  118. package/dist/lifecycle-Ichnb2x1.mjs +2 -0
  119. package/dist/load-balancers-B0XeGLhT.mjs +76 -0
  120. package/dist/local-B6b2OIBW.mjs +2 -0
  121. package/dist/local-BrfySqnx.mjs +2 -0
  122. package/dist/{local-runtime-Dj8k-p62.mjs → local-runtime-DD8DAIlm.mjs} +1 -1
  123. package/dist/login-CAsRUF4c.mjs +2 -0
  124. package/dist/login-DaglE6WA.mjs +5 -0
  125. package/dist/logo-matches-DWg5ezsM.mjs +6 -0
  126. package/dist/logos-6A6gJC5C.mjs +7 -0
  127. package/dist/logpush-DwehajAw.mjs +46 -0
  128. package/dist/logs-BWg7YymF.mjs +48 -0
  129. package/dist/magic-cloud-networking--14hNj2F.mjs +71 -0
  130. package/dist/magic-network-monitoring-Dzo4L6kd.mjs +36 -0
  131. package/dist/magic-transit-DDO0A5v4.mjs +387 -0
  132. package/dist/managed-defense-DQ0iwWdG.mjs +18 -0
  133. package/dist/managed-transforms-DDIdcPG0.mjs +9 -0
  134. package/dist/matches-D6ahHNaP.mjs +6 -0
  135. package/dist/mcp-BcIrLbRv.mjs +32 -0
  136. package/dist/mesh-wLiPcWyN.mjs +26 -0
  137. package/dist/mtls-certificates-AEuNOERQ.mjs +13 -0
  138. package/dist/network-DZsrs_sw.mjs +50 -0
  139. package/dist/network-interconnects-Cjbu4EMv.mjs +73 -0
  140. package/dist/oauth-C-QCVfWz.mjs +14 -0
  141. package/dist/oauth-Cu1twz9z.mjs +2 -0
  142. package/dist/oauth-clients-DR0hzakz.mjs +16 -0
  143. package/dist/oauth-scopes-BDNpJJ32.mjs +4 -0
  144. package/dist/observability-BnHy2M6p.mjs +80 -0
  145. package/dist/{open-PBXRGS4R-ClEt4E8F.mjs → open-PBXRGS4R-C4CKEADM.mjs} +1 -1
  146. package/dist/open-PBXRGS4R-C_-G_4DC.mjs +4 -0
  147. package/dist/organization-iasRm69J.mjs +75 -0
  148. package/dist/organizations-CUzCIKXV.mjs +4 -0
  149. package/dist/origin-ca-certificates-iQXSqBI0.mjs +11 -0
  150. package/dist/origin-post-quantum-encryption-DcMDK6Tz.mjs +6 -0
  151. package/dist/origin-tls-client-auth-D1X26X7y.mjs +30 -0
  152. package/dist/{output-Z2lQmPUW.mjs → output-Bia1u2k5.mjs} +1 -1
  153. package/dist/page-rules-CXa8EYcP.mjs +39 -0
  154. package/dist/pages-Cu0m9GSH.mjs +60 -0
  155. package/dist/pay-per-crawl-DmF8xlm_.mjs +65 -0
  156. package/dist/pay-per-use-DIp2fwJU.mjs +6 -0
  157. package/dist/pipelines-MmXlsxYO.mjs +44 -0
  158. package/dist/precursor-jqeEG_mJ.mjs +4 -0
  159. package/dist/previews-Cg6lc24N.mjs +4 -0
  160. package/dist/progress-Bpp73hIu.mjs +2 -0
  161. package/dist/{prompt-BP8XrQSj.mjs → prompt-CpZztV8c.mjs} +1 -1
  162. package/dist/queries-VzdcSR5H.mjs +9 -0
  163. package/dist/queues-BZYl2emH.mjs +63 -0
  164. package/dist/r2-data-catalog-DISnPFPY.mjs +44 -0
  165. package/dist/r2-omcKF8_A.mjs +127 -0
  166. package/dist/radar-JzBTD249.mjs +300 -0
  167. package/dist/{raw-fetch-DNH2V8qH.mjs → raw-fetch-DxGs_eRm.mjs} +1 -1
  168. package/dist/realtime-yIdAJ0Yf.mjs +172 -0
  169. package/dist/registrar-D-Li9gNk.mjs +43 -0
  170. package/dist/registrar-sandbox-CKSSHAyv.mjs +56 -0
  171. package/dist/{registry-BrtVdMrC.mjs → registry-vreNkX6u.mjs} +1 -1
  172. package/dist/reporting-Cf-pnw6h.mjs +14 -0
  173. package/dist/request-headers-DaXBfmVn.mjs +2 -0
  174. package/dist/request-tracers-BegIQTzt.mjs +4 -0
  175. package/dist/resolve-BXemCSyA.mjs +2 -0
  176. package/dist/resolve-CUDKxUrW.mjs +2 -0
  177. package/dist/resource-sharing-DEVgiYzM.mjs +40 -0
  178. package/dist/resource-tagging-Cm2yJkU9.mjs +4 -0
  179. package/dist/rules-DDCa7cYF.mjs +18 -0
  180. package/dist/rulesets-BhS7Hvtu.mjs +37 -0
  181. package/dist/rum-EIj9ViSn.mjs +30 -0
  182. package/dist/run-CSFE1qVX.mjs +2 -0
  183. package/dist/run-ChM_YpZ0.mjs +2 -0
  184. package/dist/{schema-DmuJtMN5.mjs → schema-DCBb3Fcs.mjs} +1 -1
  185. package/dist/{schema-flags-CUGxFeZe.mjs → schema-flags--GosoCMU.mjs} +1 -1
  186. package/dist/scim-DA83eNe-.mjs +18 -0
  187. package/dist/{sdk-Bvqx-_3z.mjs → sdk-CvIO3tWS.mjs} +1 -1
  188. package/dist/secrets-store-BTd3eGIB.mjs +24 -0
  189. package/dist/security-center-DbH_7h-T.mjs +30 -0
  190. package/dist/security-txt-DSrHhVEN.mjs +9 -0
  191. package/dist/shared-CtBkOWGN.mjs +2 -0
  192. package/dist/smart-shield-DnSTo-OI.mjs +24 -0
  193. package/dist/snippets-An5kQs33.mjs +20 -0
  194. package/dist/source-BR4_k2ad.mjs +6 -0
  195. package/dist/spawn-7IW1UyoH.mjs +523 -0
  196. package/dist/spectrum-Ci79n7fd.mjs +83 -0
  197. package/dist/speed-BBL7LrLn.mjs +24 -0
  198. package/dist/src-CNHNCZpy.mjs +108 -0
  199. package/dist/ssl-B2psFIRm.mjs +45 -0
  200. package/dist/startup-profile-CYEokTVe.mjs +2 -0
  201. package/dist/startup-profile-CgWHy4rE.mjs +17 -0
  202. package/dist/state-BxCejn42.mjs +2 -0
  203. package/dist/state-DSzkxXML.mjs +2 -0
  204. package/dist/stream-Du0Q7UOh.mjs +102 -0
  205. package/dist/submit-CU8S2jBT.mjs +4 -0
  206. package/dist/tags-C3l5aZSi.mjs +4 -0
  207. package/dist/telemetry-CNt8H3aA.mjs +2 -0
  208. package/dist/{telemetry-2s9Y3FaN.mjs → telemetry-Dk1GcQ0u.mjs} +1 -1
  209. package/dist/telemetry-PHe8XxA2.mjs +2 -0
  210. package/dist/tenant-BZ0ysR9L.mjs +12 -0
  211. package/dist/tenant-custom-nameservers-DtKeyM5J.mjs +9 -0
  212. package/dist/{tools-Dz1JCrHd.mjs → tools-BMKpYraQ.mjs} +1 -1
  213. package/dist/tunnels-D1tRWQQi.mjs +29 -0
  214. package/dist/turnstile-DBa4_Vyz.mjs +33 -0
  215. package/dist/ui-DH95w1Qk.mjs +5 -0
  216. package/dist/undici-DTSBJHNS.mjs +96 -0
  217. package/dist/update-check-AAn7EXw8.mjs +2 -0
  218. package/dist/update-check-BbIXBq1o.mjs +2 -0
  219. package/dist/update-check-worker.mjs +2 -0
  220. package/dist/url-info-BRA0XGT2.mjs +4 -0
  221. package/dist/url-normalization-B6N2m5s6.mjs +9 -0
  222. package/dist/url-scanner-CeKkzkhe.mjs +16 -0
  223. package/dist/user-CftksgmF.mjs +112 -0
  224. package/dist/values-m7w9PX3o.mjs +4 -0
  225. package/dist/vectorize-BWBEtsgZ.mjs +32 -0
  226. package/dist/version-cPq-WKL8.mjs +2 -0
  227. package/dist/waiting-rooms-BVZSYTNJ.mjs +53 -0
  228. package/dist/web-assets-CLU5vAgP.mjs +64 -0
  229. package/dist/web3-Dkd4XRNH.mjs +28 -0
  230. package/dist/workers-BQi4_SBS.mjs +36 -0
  231. package/dist/workers-builds-BgtPSDYJ.mjs +14 -0
  232. package/dist/workers-for-platforms-actLCM6Q.mjs +25 -0
  233. package/dist/workers-vpc-DjGfJgQn.mjs +13 -0
  234. package/dist/workflows-Cm7WsAgB.mjs +43 -0
  235. package/dist/zaraz-DurWe32F.mjs +22 -0
  236. package/dist/zero-trust-D8SVU8YZ.mjs +795 -0
  237. package/dist/zone-B3AEAfcd.mjs +4 -0
  238. package/dist/zones-DiX5LoSU.mjs +124 -0
  239. package/package.json +26 -11
  240. package/dist/_meta/agent-context.json +0 -195
  241. package/dist/abuse-reports-CDFjJ2e8.mjs +0 -8
  242. package/dist/access-BoT1waG4.mjs +0 -11
  243. package/dist/account-agnMUKWj.mjs +0 -2
  244. package/dist/account-tags-BRMMHCee.mjs +0 -9
  245. package/dist/accounts-Cut77dAt.mjs +0 -30
  246. package/dist/acm-C8WgXNCl.mjs +0 -3
  247. package/dist/addressing-CR8EV42x.mjs +0 -13
  248. package/dist/agent-context-Wj5TRRbW.mjs +0 -8
  249. package/dist/agent-memory-CVJpKKZy.mjs +0 -6
  250. package/dist/ai-BbNYt-yI.mjs +0 -5
  251. package/dist/ai-audit-mVajM-2i.mjs +0 -2
  252. package/dist/ai-gateway-BsepSA_v.mjs +0 -13
  253. package/dist/ai-search-DbEJqm5-.mjs +0 -7
  254. package/dist/ai-security-DmyB5EYk.mjs +0 -4
  255. package/dist/alerting-dmy3hd8O.mjs +0 -6
  256. package/dist/analytics-B1xBMla0.mjs +0 -5
  257. package/dist/analytics_engine-DazCn3iC.mjs +0 -2
  258. package/dist/api-security-0HXCzfHk.mjs +0 -50
  259. package/dist/argo-DSHsE8zv.mjs +0 -2
  260. package/dist/artifacts-CwiU9Mxu.mjs +0 -5
  261. package/dist/audit-logs-DwFtMDwH.mjs +0 -2
  262. package/dist/auth-B0ZyXc3y.mjs +0 -5
  263. package/dist/auth-DWxtJ918.mjs +0 -8
  264. package/dist/billing-Cbpadkgu.mjs +0 -3
  265. package/dist/bot-management-B6M2Vyyn.mjs +0 -5
  266. package/dist/botnet-feed-Dn8UuE4h.mjs +0 -3
  267. package/dist/brand-protection-B5R0b3pu.mjs +0 -3
  268. package/dist/browser-extension-D55pYZf_.mjs +0 -3
  269. package/dist/browser-run-C1b2VkGB.mjs +0 -4
  270. package/dist/build-CP2JUfV1.mjs +0 -2
  271. package/dist/builds-CVEXO_4a.mjs +0 -9
  272. package/dist/cache-BU5xX82E.mjs +0 -9
  273. package/dist/certificate-authorities--tZTWJWD.mjs +0 -2
  274. package/dist/cf-BV2HLCQm.mjs +0 -18
  275. package/dist/chunk-QBZBEHZB-BcCMlc8C.mjs +0 -2
  276. package/dist/chunk-XLADBZ7F-DgFrtUhW.mjs +0 -103
  277. package/dist/chunk-vbHwaUoU.mjs +0 -2
  278. package/dist/client-certificates-DX84qeYG.mjs +0 -3
  279. package/dist/client-side-security-DsSO2rZQ.mjs +0 -37
  280. package/dist/cloud-connector-cf8qlxap.mjs +0 -2
  281. package/dist/cloudforce-one-DzVXorbu.mjs +0 -32
  282. package/dist/command-DYrspBc0.mjs +0 -2
  283. package/dist/connector-interrupts-DqpqPPkp.mjs +0 -2
  284. package/dist/connector-telemetry-events-CCD-_B-8.mjs +0 -2
  285. package/dist/connector-telemetry-snapshots-D3CeGGhk.mjs +0 -2
  286. package/dist/connectors-aPQspZdg.mjs +0 -3
  287. package/dist/containers-D0Kjl8h-.mjs +0 -58
  288. package/dist/content-scan-BVx18XmS.mjs +0 -4
  289. package/dist/cps-ByazyM0x.mjs +0 -2
  290. package/dist/csamScanner-OG5lQxBC.mjs +0 -6
  291. package/dist/ct-alerting-BJx5n8Zf.mjs +0 -3
  292. package/dist/custom-certificates-BuJ2e9TA.mjs +0 -5
  293. package/dist/custom-csrs-CR_5qbST.mjs +0 -3
  294. package/dist/custom-hostnames-BzDTsQXb.mjs +0 -5
  295. package/dist/custom-nameservers-OfMPRGkD.mjs +0 -3
  296. package/dist/custom-pages-BmGXoTIo.mjs +0 -3
  297. package/dist/d1-DedC8N0N.mjs +0 -21
  298. package/dist/data-security-B2UB26ry.mjs +0 -7
  299. package/dist/dcv-delegation-C11vmzbG.mjs +0 -2
  300. package/dist/diagnostics-Cf6BLpAo.mjs +0 -3
  301. package/dist/dist-CyisSore.mjs +0 -371
  302. package/dist/dist-Dr4Hg_Up.mjs +0 -48
  303. package/dist/dls-R6PvHbhj.mjs +0 -3
  304. package/dist/dns-Cl8se64c.mjs +0 -29
  305. package/dist/dns-firewall-WtmKilDT.mjs +0 -57
  306. package/dist/dry-run-YSQndLvt.mjs +0 -2
  307. package/dist/durable-objects-jfVU6yp_.mjs +0 -2
  308. package/dist/email-auth-DPmZ85eW.mjs +0 -2
  309. package/dist/email-routing-Bf6DbNTr.mjs +0 -6
  310. package/dist/email-security-DTifjSxM.mjs +0 -18
  311. package/dist/email-sending-Dm3WkFHV.mjs +0 -7
  312. package/dist/error-sanitization-D8zuyPj_.mjs +0 -2
  313. package/dist/fieldExtractors-CeXZL0-I.mjs +0 -3
  314. package/dist/firewall-D5N2APXO.mjs +0 -8
  315. package/dist/flagship-sUOy9jei.mjs +0 -4
  316. package/dist/fraud-WLW2Ep1Z.mjs +0 -20
  317. package/dist/google-tag-gateway-lbww1FaJ.mjs +0 -2
  318. package/dist/healthchecks-0ih8Qjiw.mjs +0 -4
  319. package/dist/hostnames-Ba6FuL8K.mjs +0 -3
  320. package/dist/hyperdrive-DMqcU639.mjs +0 -21
  321. package/dist/iam-CXlYm0uC.mjs +0 -6
  322. package/dist/images-D_g1oli6.mjs +0 -8
  323. package/dist/intel-B8bS0ARd.mjs +0 -8
  324. package/dist/ips-68fzniN4.mjs +0 -2
  325. package/dist/keyless-certificates-CeLnqBvX.mjs +0 -3
  326. package/dist/keys-DkVdS2lF.mjs +0 -2
  327. package/dist/kv-gDAN50BQ.mjs +0 -5
  328. package/dist/leaked-credential-checks-DfnvHpvg.mjs +0 -4
  329. package/dist/load-balancers-m0HqyXPZ.mjs +0 -6
  330. package/dist/local-BwL_gesw.mjs +0 -2
  331. package/dist/logo-matches-DPbHlsKQ.mjs +0 -2
  332. package/dist/logos-DFBJFAYJ.mjs +0 -3
  333. package/dist/logpush-gzmlZayc.mjs +0 -4
  334. package/dist/logs-BuzwQgt5.mjs +0 -18
  335. package/dist/magic-cloud-networking-BbHCi1Vp.mjs +0 -5
  336. package/dist/magic-network-monitoring-kWMmnPTG.mjs +0 -4
  337. package/dist/magic-transit-ClSmJDKw.mjs +0 -111
  338. package/dist/managed-defense-EOihg1UR.mjs +0 -2
  339. package/dist/managed-transforms-BZ_XdGE2.mjs +0 -3
  340. package/dist/matches-B6sG0_fr.mjs +0 -2
  341. package/dist/mcp--kK0vS5i.mjs +0 -4
  342. package/dist/mesh-DfXYUHOO.mjs +0 -4
  343. package/dist/mtls-certificates-DZd-0X7l.mjs +0 -3
  344. package/dist/network-U6f_5ihp.mjs +0 -6
  345. package/dist/network-interconnects-DKZGTiYM.mjs +0 -41
  346. package/dist/oauth-BdVr2hJp.mjs +0 -14
  347. package/dist/oauth-clients-CY3OkPhC.mjs +0 -4
  348. package/dist/oauth-scopes-BTY7_5L-.mjs +0 -2
  349. package/dist/observability-Bsp-LdmJ.mjs +0 -10
  350. package/dist/organization-BSeMdj-7.mjs +0 -45
  351. package/dist/organizations-BroR48Nv.mjs +0 -2
  352. package/dist/origin-ca-certificates-jC-EMn6W.mjs +0 -3
  353. package/dist/origin-post-quantum-encryption-DIspLvA0.mjs +0 -2
  354. package/dist/origin-tls-client-auth-CZ_nUEcM.mjs +0 -4
  355. package/dist/page-rules-ZcdjPohY.mjs +0 -27
  356. package/dist/pages-W4tKa7xk.mjs +0 -14
  357. package/dist/pay-per-crawl-BNM1mJmP.mjs +0 -5
  358. package/dist/pay-per-use-DKxlnkH3.mjs +0 -2
  359. package/dist/pipelines-Dug0BR-c.mjs +0 -6
  360. package/dist/precursor-D-11DkRU.mjs +0 -4
  361. package/dist/previews-D_Nv4dR6.mjs +0 -4
  362. package/dist/progress-a5IKeKni.mjs +0 -2
  363. package/dist/queries-BdA2vJoe.mjs +0 -3
  364. package/dist/queues-Bu06ZqUE.mjs +0 -7
  365. package/dist/r2-COC9wMKb.mjs +0 -25
  366. package/dist/r2-data-catalog-CX5Rl5Qx.mjs +0 -16
  367. package/dist/radar-L-yoLIHF.mjs +0 -2
  368. package/dist/realtime-JKIiXfzi.mjs +0 -20
  369. package/dist/registrar-_dYUZrK0.mjs +0 -43
  370. package/dist/registrar-sandbox-D1yfW_Q_.mjs +0 -56
  371. package/dist/reporting-3fyoMcmb.mjs +0 -2
  372. package/dist/request-headers-BhQQAfJt.mjs +0 -2
  373. package/dist/request-tracers-TisEth2p.mjs +0 -2
  374. package/dist/resolve-CYUp6YgC.mjs +0 -2
  375. package/dist/resource-sharing-C4-dnohU.mjs +0 -6
  376. package/dist/resource-tagging-BRDifKqM.mjs +0 -2
  377. package/dist/rules-BCF3gIkw.mjs +0 -4
  378. package/dist/rulesets-wp6rllt3.mjs +0 -5
  379. package/dist/rum-B77awgoB.mjs +0 -4
  380. package/dist/run-BS8otL3u.mjs +0 -2
  381. package/dist/scim-C9BmUYil.mjs +0 -4
  382. package/dist/secrets-store-ckkZR2dM.mjs +0 -7
  383. package/dist/security-center-BCahKT57.mjs +0 -2
  384. package/dist/security-txt-0SI5du7I.mjs +0 -3
  385. package/dist/shared-D0B-7q-D.mjs +0 -2
  386. package/dist/smart-shield-BDPbrZa4.mjs +0 -4
  387. package/dist/snippets-CVRR_h0i.mjs +0 -4
  388. package/dist/spawn-DP4T92ss.mjs +0 -519
  389. package/dist/spectrum-CjNXQIQE.mjs +0 -63
  390. package/dist/speed-CrXCHk3h.mjs +0 -4
  391. package/dist/src-BbnV77C4.mjs +0 -108
  392. package/dist/ssl-DKORhHkh.mjs +0 -15
  393. package/dist/startup-profile-CBIH6yZy.mjs +0 -17
  394. package/dist/state-QUu6HfxC.mjs +0 -2
  395. package/dist/stream-wY3zi3FK.mjs +0 -16
  396. package/dist/submit-B-4oCBSk.mjs +0 -2
  397. package/dist/tags-5uJEkYJZ.mjs +0 -2
  398. package/dist/telemetry-n3NJourL.mjs +0 -2
  399. package/dist/tenant-BkFvv2o3.mjs +0 -2
  400. package/dist/tenant-custom-nameservers-DcjC1q0r.mjs +0 -3
  401. package/dist/tunnel-Cd4ipbvJ.mjs +0 -2
  402. package/dist/tunnels-9Zg3ePwD.mjs +0 -5
  403. package/dist/turnstile-BTwKYpzD.mjs +0 -23
  404. package/dist/ui-DQSZeaG5.mjs +0 -5
  405. package/dist/url-info-D7Y61BFd.mjs +0 -2
  406. package/dist/url-normalization-B4n8HiNQ.mjs +0 -3
  407. package/dist/url-scanner-CiCIltSQ.mjs +0 -2
  408. package/dist/user-DDFDGJ0Y.mjs +0 -12
  409. package/dist/values-DRznB_Cl.mjs +0 -2
  410. package/dist/vectorize-CbznPhzq.mjs +0 -4
  411. package/dist/waiting-rooms-CKP5hYBK.mjs +0 -11
  412. package/dist/web-assets-C-ZoSkkh.mjs +0 -8
  413. package/dist/web3-DwlN4dOw.mjs +0 -4
  414. package/dist/workers-builds-ECw_x_kp.mjs +0 -2
  415. package/dist/workers-for-platforms-BYGy46R6.mjs +0 -5
  416. package/dist/workers-vpc-CCosFcxz.mjs +0 -3
  417. package/dist/workers-zFMrbUkg.mjs +0 -6
  418. package/dist/workflows-C8GXGDRW.mjs +0 -5
  419. package/dist/zaraz-B5UIREaz.mjs +0 -2
  420. package/dist/zero-trust-DUp0XoIo.mjs +0 -91
  421. package/dist/zone-BGLkk-mL.mjs +0 -2
  422. package/dist/zones-CwYjNXMH.mjs +0 -44
  423. /package/dist/{alerts-CarPLL8k.mjs → alerts-CstOk8n0.mjs} +0 -0
  424. /package/dist/{autorag-zK-3harf.mjs → autorag-PRTwXGgn.mjs} +0 -0
  425. /package/dist/{body-parser-Cmw7PZ7a.mjs → body-parser-CUWbw_Tq.mjs} +0 -0
  426. /package/dist/{brands-CpgTsX8h.mjs → brands-BHRXlWDm.mjs} +0 -0
  427. /package/dist/{clear-C5gzBA8G.mjs → clear-UvKESVx3.mjs} +0 -0
  428. /package/dist/{cli-types-abvWQN3T.mjs → cli-types-tt_LZMbn.mjs} +0 -0
  429. /package/dist/{connector-telemetry-events-latest-BY-dbhQZ.mjs → connector-telemetry-events-latest-DwnFeZg0.mjs} +0 -0
  430. /package/dist/{connector-telemetry-snapshots-latest-DoMvHvCO.mjs → connector-telemetry-snapshots-latest-Dv6rZlxs.mjs} +0 -0
  431. /package/dist/{domain-info-Cw3G4nap.mjs → domain-info-BqTDXNBo.mjs} +0 -0
  432. /package/dist/{health-DkEXPkS6.mjs → health-CwPzzrV6.mjs} +0 -0
  433. /package/dist/{input-validation-nF-0Ze2h.mjs → input-validation-Ch4Vllrm.mjs} +0 -0
  434. /package/dist/{internal-4fU2r5en.mjs → internal-WLHfxX64.mjs} +0 -0
  435. /package/dist/{live-B4iGrwY2.mjs → live-D_k7eHdv.mjs} +0 -0
  436. /package/dist/{metadata-C5fJJr-k.mjs → metadata-APBiectA.mjs} +0 -0
  437. /package/dist/{project-settings-Bc3wYHo8.mjs → project-settings-DSXevRvj.mjs} +0 -0
  438. /package/dist/{rate-limit-analytics-DNsAFIeM.mjs → rate-limit-analytics-CDTPxSET.mjs} +0 -0
  439. /package/dist/{rate-limits-CsOim7bm.mjs → rate-limits-C3K9smdl.mjs} +0 -0
  440. /package/dist/{ready-tTe-zcIw.mjs → ready-CvwvbdTX.mjs} +0 -0
  441. /package/dist/{recent-submissions-B3eTV5yC.mjs → recent-submissions-CjzcT-iH.mjs} +0 -0
  442. /package/dist/{refute-BY76YVrT.mjs → refute-CIAFMj00.mjs} +0 -0
  443. /package/dist/{scan-logo-DdoF_a5y.mjs → scan-logo-zFkphtQ3.mjs} +0 -0
  444. /package/dist/{scan-page-sSgLwwZN.mjs → scan-page-CLl2MAkZ.mjs} +0 -0
  445. /package/dist/{search-BFvQr-sl.mjs → search-12jA1b4l.mjs} +0 -0
  446. /package/dist/{signed-url-Cr8hiZPJ.mjs → signed-url-U0T_PEMR.mjs} +0 -0
  447. /package/dist/{submission-info-DT2mLnu1.mjs → submission-info-CZ84a3Nb.mjs} +0 -0
  448. /package/dist/{theme-CeVf-5qG.mjs → theme-BiIYWOed.mjs} +0 -0
  449. /package/dist/{total-queries-6gs5iy9T.mjs → total-queries-CJTc9Pde.mjs} +0 -0
  450. /package/dist/{tracked-domains-D6XKO2EV.mjs → tracked-domains-BKLxnnSv.mjs} +0 -0
  451. /package/dist/{verify-CM1NakP0.mjs → verify-CZW5Fo1q.mjs} +0 -0
@@ -0,0 +1,29 @@
1
+ #!/usr/bin/env node
2
+ import{s as e}from"./src-CNHNCZpy.mjs";import{t}from"./local-B6b2OIBW.mjs";import{m as n,v as r}from"./oauth-C-QCVfWz.mjs";import{r as i}from"./auth-C80y97yu.mjs";import{t as a}from"./output-Bia1u2k5.mjs";import{t as o}from"./dry-run-CLX6Pbtq.mjs";import{t as s}from"./progress-Bpp73hIu.mjs";import{t as c}from"./run-ChM_YpZ0.mjs";import"./telemetry-CNt8H3aA.mjs";import{n as l,t as u}from"./body-parser-CUWbw_Tq.mjs";import{n as d}from"./input-validation-Ch4Vllrm.mjs";import{a as f,n as p}from"./prompt-CpZztV8c.mjs";import{t as m}from"./cli-types-tt_LZMbn.mjs";var h=e(`quick-start <url>`,`Expose a local URL with a temporary trycloudflare.com tunnel. The tunnel remains active until cf exits.`,()=>import(`./command-BP7ldws1.mjs`)),g=e(`run [tunnel]`,`Run a named Cloudflare Tunnel using the cf-managed cloudflared binary.`,()=>import(`./command-BtNRBTP6.mjs`));function _(e){return e.usage(`$0 tunnels config get <tunnel-id>
3
+
4
+ Retrieves the configuration for a remotely managed Cloudflare Tunnel.`).positional(`tunnel-id`,{type:`string`,description:`UUID of the tunnel.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const v={command:`get <tunnel-id>`,describe:`Get Tunnel configuration`,builder:_,handler:async e=>c({command:`tunnels config get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf tunnels config get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await r()??`<account-id>`}/cfd_tunnel/${e[`tunnel-id`]==null?`<tunnel-id>`:encodeURIComponent(String(e[`tunnel-id`]))}/configurations`,pathParams:{"tunnel-id":String(e[`tunnel-id`]??``)},bodyKind:`none`});return}let c=await i(e),l=e.local?t:await n();e.accountId=l,a(await s(`Loading`,async()=>c.tunnels.config.get({account_id:l,tunnel_id:e[`tunnel-id`]})),{successLabel:`Loaded`})})};function y(e){return e.usage(`$0 tunnels config update <tunnel-id>
5
+
6
+ Replaces the configuration for a remotely managed Cloudflare Tunnel, including its ingress rules and origin request settings.`).positional(`tunnel-id`,{type:`string`,description:`UUID of the tunnel.`,demandOption:!0}).option(`config-origin-request-access-aud-tag`,{type:`string`,array:!0,description:`Access applications that are allowed to reach this hostname for this Tunnel. Audience tags can be identified in the dashboard or via the List Access policies API.`}).option(`config-origin-request-access-required`,{type:`boolean`,description:`Deny traffic that has not fulfilled Access authorization.`}).option(`config-origin-request-access-team-name`,{type:`string`,description:`The config.originRequest.access.teamName field`}).option(`config-origin-request-ca-pool`,{type:`string`,description:`Path to the certificate authority (CA) for the certificate of your origin. This option should be used only if your certificate is not signed by Cloudflare.`}).option(`config-origin-request-connect-timeout`,{type:`number`,description:`Timeout for establishing a new TCP connection to your origin server. This excludes the time taken to establish TLS, which is controlled by tlsTimeout.`}).option(`config-origin-request-disable-chunked-encoding`,{type:`boolean`,description:`Disables chunked transfer encoding. Useful if you are running a WSGI server.`}).option(`config-origin-request-http2origin`,{type:`boolean`,description:`Attempt to connect to origin using HTTP2. Origin must be configured as https.`}).option(`config-origin-request-http-host-header`,{type:`string`,description:`Sets the HTTP Host header on requests sent to the local service.`}).option(`config-origin-request-keep-alive-connections`,{type:`number`,description:`Maximum number of idle keepalive connections between Tunnel and your origin. This does not restrict the total number of concurrent connections.`}).option(`config-origin-request-keep-alive-timeout`,{type:`number`,description:`Timeout after which an idle keepalive connection can be discarded.`}).option(`config-origin-request-match-snito-host`,{type:`boolean`,description:`Auto configure the Hostname on the origin server certificate.`}).option(`config-origin-request-no-happy-eyeballs`,{type:`boolean`,description:`Disable the “happy eyeballs” algorithm for IPv4/IPv6 fallback if your local network has misconfigured one of the protocols.`}).option(`config-origin-request-no-tlsverify`,{type:`boolean`,description:`Disables TLS verification of the certificate presented by your origin. Will allow any certificate from the origin to be accepted.`}).option(`config-origin-request-origin-server-name`,{type:`string`,description:`Hostname that cloudflared should expect from your origin server certificate.`}).option(`config-origin-request-proxy-type`,{type:`string`,description:`cloudflared starts a proxy server to translate HTTP traffic into TCP when proxying, for example, SSH or RDP. This configures what type of proxy will be started. Valid options are: "" for the regular proxy and "socks" for a SOCKS5 proxy.
7
+ `}).option(`config-origin-request-tcp-keep-alive`,{type:`number`,description:`The timeout after which a TCP keepalive packet is sent on a connection between Tunnel and the origin server.`}).option(`config-origin-request-tls-timeout`,{type:`number`,description:`Timeout for completing a TLS handshake to your origin server, if you have chosen to connect Tunnel to an HTTPS server.`}).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)`}).check(e=>{if([`config-origin-request-access-aud-tag`,`config-origin-request-access-required`,`config-origin-request-access-team-name`,`config-origin-request-ca-pool`,`config-origin-request-connect-timeout`,`config-origin-request-disable-chunked-encoding`,`config-origin-request-http2origin`,`config-origin-request-http-host-header`,`config-origin-request-keep-alive-connections`,`config-origin-request-keep-alive-timeout`,`config-origin-request-match-snito-host`,`config-origin-request-no-happy-eyeballs`,`config-origin-request-no-tlsverify`,`config-origin-request-origin-server-name`,`config-origin-request-proxy-type`,`config-origin-request-tcp-keep-alive`,`config-origin-request-tls-timeout`].some(t=>e[t]!==void 0)){let t=[`config-origin-request-access-aud-tag`,`config-origin-request-access-team-name`].filter(t=>e[t]===void 0);if(t.length>0)throw Error(`${t.map(e=>`--`+e).join(`, `)} ${t.length===1?`is`:`are`} required when any --config-* flag is set`)}return!0})}const b={command:`update <tunnel-id>`,describe:`Update Tunnel configuration`,builder:y,handler:async e=>c({command:`tunnels config update`,classification:{safeFlags:[`config-origin-request-access-required`,`config-origin-request-disable-chunked-encoding`,`config-origin-request-http2origin`,`config-origin-request-match-snito-host`,`config-origin-request-no-happy-eyeballs`,`config-origin-request-no-tlsverify`,`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf tunnels config update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/accounts/${await r()??`<account-id>`}/cfd_tunnel/${e[`tunnel-id`]==null?`<tunnel-id>`:encodeURIComponent(String(e[`tunnel-id`]))}/configurations`,pathParams:{"tunnel-id":String(e[`tunnel-id`]??``)},bodyKind:`json`,body:e.body===void 0?u({config:{originRequest:{access:{audTag:e[`config-origin-request-access-aud-tag`],required:e[`config-origin-request-access-required`],teamName:d(e[`config-origin-request-access-team-name`],`config-origin-request-access-team-name`,`text`)},caPool:d(e[`config-origin-request-ca-pool`],`config-origin-request-ca-pool`,`text`),connectTimeout:e[`config-origin-request-connect-timeout`],disableChunkedEncoding:e[`config-origin-request-disable-chunked-encoding`],http2Origin:e[`config-origin-request-http2origin`],httpHostHeader:d(e[`config-origin-request-http-host-header`],`config-origin-request-http-host-header`,`text`),keepAliveConnections:e[`config-origin-request-keep-alive-connections`],keepAliveTimeout:e[`config-origin-request-keep-alive-timeout`],matchSNItoHost:e[`config-origin-request-match-snito-host`],noHappyEyeballs:e[`config-origin-request-no-happy-eyeballs`],noTLSVerify:e[`config-origin-request-no-tlsverify`],originServerName:d(e[`config-origin-request-origin-server-name`],`config-origin-request-origin-server-name`,`text`),proxyType:d(e[`config-origin-request-proxy-type`],`config-origin-request-proxy-type`,`text`),tcpKeepAlive:e[`config-origin-request-tcp-keep-alive`],tlsTimeout:e[`config-origin-request-tls-timeout`]}}}):l(e.body)});return}let c=await i(e),f=e.local?t:await n();if(e.accountId=f,e.body){let t=l(e.body);a(await s(`Updating`,async()=>c.tunnels.config.update({...t,account_id:f,tunnel_id:e[`tunnel-id`]})),{successLabel:`Updated`});return}let p=u({config:{originRequest:{access:{audTag:e[`config-origin-request-access-aud-tag`],required:e[`config-origin-request-access-required`],teamName:d(e[`config-origin-request-access-team-name`],`config-origin-request-access-team-name`,`text`)},caPool:d(e[`config-origin-request-ca-pool`],`config-origin-request-ca-pool`,`text`),connectTimeout:e[`config-origin-request-connect-timeout`],disableChunkedEncoding:e[`config-origin-request-disable-chunked-encoding`],http2Origin:e[`config-origin-request-http2origin`],httpHostHeader:d(e[`config-origin-request-http-host-header`],`config-origin-request-http-host-header`,`text`),keepAliveConnections:e[`config-origin-request-keep-alive-connections`],keepAliveTimeout:e[`config-origin-request-keep-alive-timeout`],matchSNItoHost:e[`config-origin-request-match-snito-host`],noHappyEyeballs:e[`config-origin-request-no-happy-eyeballs`],noTLSVerify:e[`config-origin-request-no-tlsverify`],originServerName:d(e[`config-origin-request-origin-server-name`],`config-origin-request-origin-server-name`,`text`),proxyType:d(e[`config-origin-request-proxy-type`],`config-origin-request-proxy-type`,`text`),tcpKeepAlive:e[`config-origin-request-tcp-keep-alive`],tlsTimeout:e[`config-origin-request-tls-timeout`]}}});a(await s(`Updating`,async()=>c.tunnels.config.update({...p,account_id:f,tunnel_id:e[`tunnel-id`]})),{successLabel:`Updated`})})},x={command:`config`,describe:`Operations for config`,builder:e=>e.command(v).command(b).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function S(e){return e.usage(`$0 tunnels connections cleanup <tunnel-id>
8
+
9
+ Removes a connection (aka Cloudflare Tunnel Connector) from a Cloudflare Tunnel independently of its current state. If no connector id (client_id) is provided all connectors will be removed. We recommend running this command after rotating tokens.`).positional(`tunnel-id`,{type:`string`,description:`UUID of the tunnel.`,demandOption:!0}).option(`client-id`,{type:`string`,description:`UUID of the Cloudflare Tunnel connector.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const C={command:`cleanup <tunnel-id>`,describe:`Clean up Cloudflare Tunnel connections`,builder:S,handler:async e=>c({command:`tunnels connections cleanup`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{let c={client_id:e[`client-id`]};if(e.dryRun){o({command:`cf tunnels connections cleanup`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${await r()??`<account-id>`}/cfd_tunnel/${e[`tunnel-id`]==null?`<tunnel-id>`:encodeURIComponent(String(e[`tunnel-id`]))}/connections`,pathParams:{"tunnel-id":String(e[`tunnel-id`]??``)},query:c,bodyKind:`none`});return}let l=await i(e),u=e.local?t:await n();if(e.accountId=u,!await p({force:!!e.force,message:`This operation removes Cloudflare Tunnel connections.`})){process.stderr.write(`Aborted.
10
+ `);return}a(await s(`Deleting`,async()=>l.tunnels.connections.cleanup({account_id:u,tunnel_id:e[`tunnel-id`],...c})),{successLabel:`Deleted`})})};function w(e){return e.usage(`$0 tunnels connections list
11
+
12
+ Lists the connections for a Cloudflare Tunnel, including connector IDs, cloudflared versions, and Cloudflare locations.`).option(`tunnel-id`,{type:`string`,description:`UUID of the tunnel.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const T={command:`list`,describe:`List Cloudflare Tunnel connections`,builder:w,handler:async e=>c({command:`tunnels connections list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf tunnels connections list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await r()??`<account-id>`}/cfd_tunnel/${e[`tunnel-id`]==null?`<tunnel-id>`:encodeURIComponent(String(e[`tunnel-id`]))}/connections`,pathParams:{"tunnel-id":String(e[`tunnel-id`]??``)},bodyKind:`none`});return}let c=await i(e),l=e.local?t:await n();e.accountId=l,a(await s(`Loading`,async()=>c.tunnels.connections.list({account_id:l,tunnel_id:e[`tunnel-id`]})),{successLabel:`Loaded`})})},E={command:`connections`,describe:`Operations for connections`,builder:e=>e.command(C).command(T).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function D(e){return e.usage(`$0 tunnels connectors get <connector-id>
13
+
14
+ Retrieves a connector and its connection details for a Cloudflare Tunnel, including its cloudflared version, architecture, and connected Cloudflare locations.`).positional(`connector-id`,{type:`string`,description:`UUID of the Cloudflare Tunnel connector.`,demandOption:!0}).option(`tunnel-id`,{type:`string`,description:`UUID of the tunnel.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const O={command:`get <connector-id>`,describe:`Get Cloudflare Tunnel connector`,builder:D,handler:async e=>c({command:`tunnels connectors get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf tunnels connectors get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await r()??`<account-id>`}/cfd_tunnel/${e[`tunnel-id`]==null?`<tunnel-id>`:encodeURIComponent(String(e[`tunnel-id`]))}/connectors/${e[`connector-id`]==null?`<connector-id>`:encodeURIComponent(String(e[`connector-id`]))}`,pathParams:{"tunnel-id":String(e[`tunnel-id`]??``),"connector-id":String(e[`connector-id`]??``)},bodyKind:`none`});return}let c=await i(e),l=e.local?t:await n();e.accountId=l,a(await s(`Loading`,async()=>c.tunnels.connectors.get({account_id:l,tunnel_id:e[`tunnel-id`],connector_id:e[`connector-id`]})),{successLabel:`Loaded`})})},k={command:`connectors`,describe:`Operations for connectors`,builder:e=>e.command(O).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function A(e){return e.usage(`$0 tunnels create
15
+
16
+ Creates a remotely or locally managed Cloudflare Tunnel in an account. After creation, retrieve its token and run cloudflared to establish the connector connection.`).option(`config-src`,{type:`string`,description:"Indicates if this is a locally or remotely configured tunnel. If `local`, manage the tunnel using a YAML file on the origin machine. If `cloudflare`, manage the tunnel on the Zero Trust dashboard.",choices:[`local`,`cloudflare`],default:`local`}).option(`name`,{type:`string`,description:`A user-friendly name for a tunnel.`}).option(`tunnel-secret`,{type:`string`,description:`Sets the password required to run a locally-managed tunnel. Must be at least 32 bytes and encoded as a base64 string.`}).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 j={command:`create`,describe:`Create a Cloudflare Tunnel`,builder:A,handler:async e=>c({command:`tunnels create`,classification:{safeFlags:[`config-src`,`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf tunnels create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${await r()??`<account-id>`}/cfd_tunnel`,pathParams:{},bodyKind:`json`,body:e.body===void 0?u({config_src:d(e[`config-src`],`config-src`,`text`),name:d(e.name,`name`,`text`),tunnel_secret:d(e[`tunnel-secret`],`tunnel-secret`,`text`)}):l(e.body)});return}let c=await i(e),p=e.local?t:await n();if(e.accountId=p,e.body){let t=l(e.body);a(await s(`Creating`,async()=>c.tunnels.create({...t,account_id:p})),{successLabel:`Created`});return}e.name===void 0&&(e.name=await f(`name`,`A user-friendly name for a tunnel.`));let m=u({config_src:d(e[`config-src`],`config-src`,`text`),name:d(e.name,`name`,`text`),tunnel_secret:d(e[`tunnel-secret`],`tunnel-secret`,`text`)});a(await s(`Creating`,async()=>c.tunnels.create({...m,account_id:p})),{successLabel:`Created`})})};function M(e){return e.usage(`$0 tunnels delete <tunnel-id>
17
+
18
+ Permanently deletes a Cloudflare Tunnel from an account. The tunnel must have no active connections.`).positional(`tunnel-id`,{type:`string`,description:`UUID of the tunnel.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const N={command:`delete <tunnel-id>`,describe:`Delete a Cloudflare Tunnel`,builder:M,handler:async e=>c({command:`tunnels delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){o({command:`cf tunnels delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${await r()??`<account-id>`}/cfd_tunnel/${e[`tunnel-id`]==null?`<tunnel-id>`:encodeURIComponent(String(e[`tunnel-id`]))}`,pathParams:{"tunnel-id":String(e[`tunnel-id`]??``)},bodyKind:`none`});return}let c=await i(e),l=e.local?t:await n();if(e.accountId=l,!await p({force:!!e.force,message:`This operation permanently deletes a Cloudflare Tunnel.`})){process.stderr.write(`Aborted.
19
+ `);return}a(await s(`Deleting`,async()=>c.tunnels.delete({account_id:l,tunnel_id:e[`tunnel-id`]})),{successLabel:`Deleted`})})};function P(e){return e.usage(`$0 tunnels edit <tunnel-id>
20
+
21
+ Updates the name or secret of an existing Cloudflare Tunnel.`).positional(`tunnel-id`,{type:`string`,description:`UUID of the tunnel.`,demandOption:!0}).option(`name`,{type:`string`,description:`A user-friendly name for a tunnel.`}).option(`tunnel-secret`,{type:`string`,description:`Sets the password required to run a locally-managed tunnel. Must be at least 32 bytes and encoded as a base64 string.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const F={command:`edit <tunnel-id>`,describe:`Update a Cloudflare Tunnel`,builder:P,handler:async e=>c({command:`tunnels edit`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf tunnels edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/accounts/${await r()??`<account-id>`}/cfd_tunnel/${e[`tunnel-id`]==null?`<tunnel-id>`:encodeURIComponent(String(e[`tunnel-id`]))}`,pathParams:{"tunnel-id":String(e[`tunnel-id`]??``)},bodyKind:`json`,body:e.body===void 0?u({name:d(e.name,`name`,`text`),tunnel_secret:d(e[`tunnel-secret`],`tunnel-secret`,`text`)}):l(e.body)});return}let c=await i(e),f=e.local?t:await n();if(e.accountId=f,e.body){let t=l(e.body);a(await s(`Updating`,async()=>c.tunnels.edit({...t,account_id:f,tunnel_id:e[`tunnel-id`]})),{successLabel:`Updated`});return}let p=u({name:d(e.name,`name`,`text`),tunnel_secret:d(e[`tunnel-secret`],`tunnel-secret`,`text`)});a(await s(`Updating`,async()=>c.tunnels.edit({...p,account_id:f,tunnel_id:e[`tunnel-id`]})),{successLabel:`Updated`})})};function I(e){return e.usage(`$0 tunnels get <tunnel-id>
22
+
23
+ Fetches a single Cloudflare Tunnel.`).positional(`tunnel-id`,{type:`string`,description:`UUID of the tunnel.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const L={command:`get <tunnel-id>`,describe:`Get a Cloudflare Tunnel`,builder:I,handler:async e=>c({command:`tunnels get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf tunnels get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await r()??`<account-id>`}/cfd_tunnel/${e[`tunnel-id`]==null?`<tunnel-id>`:encodeURIComponent(String(e[`tunnel-id`]))}`,pathParams:{"tunnel-id":String(e[`tunnel-id`]??``)},bodyKind:`none`});return}let c=await i(e),l=e.local?t:await n();e.accountId=l,a(await s(`Loading`,async()=>c.tunnels.get({account_id:l,tunnel_id:e[`tunnel-id`]})),{successLabel:`Loaded`})})};function R(e){return e.usage(`$0 tunnels list
24
+
25
+ Lists and filters all types of Tunnels in an account.`).option(`name`,{type:`string`,description:`A user-friendly name for the tunnel.`}).option(`is-deleted`,{type:`boolean`,description:"If `true`, only include deleted tunnels. If `false`, exclude deleted tunnels. If empty, all tunnels will be included."}).option(`existed-at`,{type:`string`,description:`If provided, include only resources that were created (and not deleted) before this time. URL encoded.`}).option(`uuid`,{type:`string`,description:`UUID of the tunnel.`}).option(`was-active-at`,{type:`string`,description:`Was active at`}).option(`was-inactive-at`,{type:`string`,description:`Was inactive at`}).option(`include-prefix`,{type:`string`,description:`Include prefix`}).option(`exclude-prefix`,{type:`string`,description:`Exclude prefix`}).option(`tun-types`,{type:`string`,description:`The types of tunnels to filter by, separated by commas.`}).option(`status`,{type:`string`,description:"The status of the tunnel. Valid values are `inactive` (tunnel has never been run), `degraded` (tunnel is active and able to serve traffic but in an unhealthy state), `healthy` (tunnel is active and able to serve traffic), or `down` (tunnel can not serve traffic as it has no connections to the Cloudflare Edge).",choices:[`inactive`,`degraded`,`healthy`,`down`]}).option(`per-page`,{type:`number`,description:`Number of results to display.`}).option(`page`,{type:`number`,description:`Page number of paginated results.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const z={command:`list`,describe:`List All Tunnels`,builder:m(R),handler:async e=>c({command:`tunnels list`,classification:{safeFlags:[`is-deleted`,`status`,`dry-run`]}},e,async()=>{let c={name:e.name,is_deleted:e[`is-deleted`],existed_at:e[`existed-at`],uuid:e.uuid,was_active_at:e[`was-active-at`],was_inactive_at:e[`was-inactive-at`],include_prefix:e[`include-prefix`],exclude_prefix:e[`exclude-prefix`],tun_types:e[`tun-types`],status:e.status,per_page:e[`per-page`],page:e.page};if(e.dryRun){o({command:`cf tunnels list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await r()??`<account-id>`}/tunnels`,pathParams:{},query:c,bodyKind:`none`});return}let l=await i(e),u=e.local?t:await n();e.accountId=u,a(await s(`Loading`,async()=>l.tunnels.list({account_id:u,...c})),{successLabel:`Loaded`})})};function B(e){return e.usage(`$0 tunnels management-token create <tunnel-id>
26
+
27
+ Creates a short-lived management token for the requested Tunnel management resources, such as streaming logs. Treat the token as a secret.`).positional(`tunnel-id`,{type:`string`,description:`UUID of the tunnel.`,demandOption:!0}).option(`resources`,{type:`string`,array:!0,description:`The resources field`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const V={command:`create <tunnel-id>`,describe:`Get a Cloudflare Tunnel management token`,builder:B,handler:async e=>c({command:`tunnels management-token create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf tunnels management-token create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${await r()??`<account-id>`}/cfd_tunnel/${e[`tunnel-id`]==null?`<tunnel-id>`:encodeURIComponent(String(e[`tunnel-id`]))}/management`,pathParams:{"tunnel-id":String(e[`tunnel-id`]??``)},bodyKind:`json`,body:e.body===void 0?u({resources:e.resources}):l(e.body)});return}let c=await i(e),d=e.local?t:await n();if(e.accountId=d,e.body){let t=l(e.body);a(await s(`Creating`,async()=>c.tunnels.managementToken.create({...t,account_id:d,tunnel_id:e[`tunnel-id`]})),{successLabel:`Created`});return}if(e.resources===void 0)throw Error(`--resources is required (or pass --body with this field set).`);let f=u({resources:e.resources});a(await s(`Creating`,async()=>c.tunnels.managementToken.create({...f,account_id:d,tunnel_id:e[`tunnel-id`]})),{successLabel:`Created`})})},H={command:`management-token`,describe:`Operations for management-token`,builder:e=>e.command(V).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function U(e){return e.usage(`$0 tunnels token get <tunnel-id>
28
+
29
+ Retrieves the token used to run cloudflared and associate it with a specific Cloudflare Tunnel. Treat the token as a secret.`).positional(`tunnel-id`,{type:`string`,description:`UUID of the tunnel.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const W={command:`get <tunnel-id>`,describe:`Get a Cloudflare Tunnel token`,builder:U,handler:async e=>c({command:`tunnels token get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf tunnels token get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await r()??`<account-id>`}/cfd_tunnel/${e[`tunnel-id`]==null?`<tunnel-id>`:encodeURIComponent(String(e[`tunnel-id`]))}/token`,pathParams:{"tunnel-id":String(e[`tunnel-id`]??``)},bodyKind:`none`});return}let c=await i(e),l=e.local?t:await n();e.accountId=l,a(await s(`Loading`,async()=>c.tunnels.token.get({account_id:l,tunnel_id:e[`tunnel-id`]})),{successLabel:`Loaded`})})},G={command:`token`,describe:`Operations for token`,builder:e=>e.command(W).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},K={command:`tunnels`,describe:`tunnels`,builder:e=>e.command(j).command(N).command(F).command(L).command(z).command(h).command(g).command(x).command(E).command(k).command(H).command(G).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{K as default};
@@ -0,0 +1,33 @@
1
+ #!/usr/bin/env node
2
+ import{t as e}from"./local-B6b2OIBW.mjs";import{m as t,v as n}from"./oauth-C-QCVfWz.mjs";import{r}from"./auth-C80y97yu.mjs";import{t as i}from"./output-Bia1u2k5.mjs";import{t as a}from"./dry-run-CLX6Pbtq.mjs";import{t as o}from"./progress-Bpp73hIu.mjs";import{t as s}from"./run-ChM_YpZ0.mjs";import"./telemetry-CNt8H3aA.mjs";import{n as c,t as l}from"./body-parser-CUWbw_Tq.mjs";import{n as u}from"./input-validation-Ch4Vllrm.mjs";import{a as d,n as f}from"./prompt-CpZztV8c.mjs";import{t as p}from"./cli-types-tt_LZMbn.mjs";function m(e){return e.usage(`$0 turnstile widgets create
3
+
4
+ Lists challenge widgets.`).option(`page`,{type:`number`,description:`Page number of paginated results.`}).option(`per-page`,{type:`number`,description:`Number of items per page.`}).option(`order`,{type:`string`,description:`Field to order widgets by.`,choices:[`id`,`sitekey`,`name`,`created_on`,`modified_on`]}).option(`direction`,{type:`string`,description:`Direction to order widgets.`,choices:[`asc`,`desc`]}).option(`filter`,{type:`string`,description:"Filter widgets by field using case-insensitive substring matching.\nFormat: `field:value`\n\nSupported fields:\n- `name` - Filter by widget name (e.g., `filter=name:login-form`)\n- `sitekey` - Filter by sitekey (e.g., `filter=sitekey:0x4AAA`)\n\nReturns 400 Bad Request if the field is unsupported or format is invalid.\nAn empty filter value returns all results."}).option(`bot-fight-mode`,{type:`boolean`,description:`If bot_fight_mode is set to \`true\`, Cloudflare issues computationally
5
+ expensive challenges in response to malicious bots (ENT only).
6
+ `}).option(`clearance-level`,{type:`string`,description:`If Turnstile is embedded on a Cloudflare site and the widget should grant challenge clearance,
7
+ this setting can determine the clearance level to be set
8
+ `,choices:[`no_clearance`,`jschallenge`,`managed`,`interactive`]}).option(`domains`,{type:`string`,array:!0,description:`The domains field`}).option(`ephemeral-id`,{type:`boolean`,description:`Return the Ephemeral ID in /siteverify (ENT only).
9
+ `}).option(`name`,{type:`string`,description:`Human readable widget name. Not unique. Cloudflare suggests that you
10
+ set this to a meaningful string to make it easier to identify your
11
+ widget, and where it is used.
12
+ `}).option(`offlabel`,{type:`boolean`,description:`Do not show any Cloudflare branding on the widget (ENT only).
13
+ `}).option(`region`,{type:`string`,description:`Region where this widget can be used. This cannot be changed after creation.
14
+ `,choices:[`world`,`china`],default:`world`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const h={command:`create`,describe:`Create a Turnstile Widget`,builder:p(m),handler:async f=>s({command:`turnstile widgets create`,classification:{safeFlags:[`order`,`direction`,`bot-fight-mode`,`clearance-level`,`ephemeral-id`,`offlabel`,`region`,`dry-run`]}},f,async()=>{let s={page:f.page,per_page:f[`per-page`],order:f.order,direction:f.direction,filter:f.filter};if(f.dryRun){a({command:`cf turnstile widgets create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/challenges/widgets`,pathParams:{},query:s,bodyKind:`json`,body:f.body===void 0?l({bot_fight_mode:f[`bot-fight-mode`],clearance_level:u(f[`clearance-level`],`clearance-level`,`text`),domains:f.domains,ephemeral_id:f[`ephemeral-id`],name:u(f.name,`name`,`text`),offlabel:f.offlabel,region:u(f.region,`region`,`text`)}):c(f.body)});return}let p=await r(f),m=f.local?e:await t();if(f.accountId=m,f.body){let e=c(f.body);new URLSearchParams(Object.entries(s).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),i(await o(`Creating`,async()=>p.turnstile.widgets.create({...e,account_id:m,...s})),{successLabel:`Created`});return}if(f.domains===void 0)throw Error(`--domains is required (or pass --body with this field set).`);f.name===void 0&&(f.name=await d(`name`,`Human readable widget name. Not unique. Cloudflare suggests that you set this to a meaningful string to make it easier to identify your widget, and where it is used. `));let h=l({bot_fight_mode:f[`bot-fight-mode`],clearance_level:u(f[`clearance-level`],`clearance-level`,`text`),domains:f.domains,ephemeral_id:f[`ephemeral-id`],name:u(f.name,`name`,`text`),offlabel:f.offlabel,region:u(f.region,`region`,`text`)});new URLSearchParams(Object.entries(s).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),i(await o(`Creating`,async()=>p.turnstile.widgets.create({...h,account_id:m,...s})),{successLabel:`Created`})})};function g(e){return e.usage(`$0 turnstile widgets delete <sitekey>
15
+
16
+ Destroy a Turnstile Widget.`).positional(`sitekey`,{type:`string`,description:`Widget item identifier tag.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const _={command:`delete <sitekey>`,describe:`Delete a Turnstile Widget`,builder:g,handler:async c=>s({command:`turnstile widgets delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},c,async()=>{if(c.dryRun){a({command:`cf turnstile widgets delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/challenges/widgets/${c.sitekey==null?`<sitekey>`:encodeURIComponent(String(c.sitekey))}`,pathParams:{sitekey:String(c.sitekey??``)},bodyKind:`none`});return}let s=await r(c),l=c.local?e:await t();if(c.accountId=l,!await f({force:!!c.force})){process.stderr.write(`Aborted.
17
+ `);return}i(await o(`Deleting`,async()=>s.turnstile.widgets.delete({account_id:l,sitekey:c.sitekey})),{successLabel:`Deleted`})})};function v(e){return e.usage(`$0 turnstile widgets get <sitekey>
18
+
19
+ Show a single challenge widget configuration.`).positional(`sitekey`,{type:`string`,description:`Widget item identifier tag.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const y={command:`get <sitekey>`,describe:`Turnstile Widget Details`,builder:v,handler:async c=>s({command:`turnstile widgets get`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){a({command:`cf turnstile widgets get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/challenges/widgets/${c.sitekey==null?`<sitekey>`:encodeURIComponent(String(c.sitekey))}`,pathParams:{sitekey:String(c.sitekey??``)},bodyKind:`none`});return}let s=await r(c),l=c.local?e:await t();c.accountId=l,i(await o(`Loading`,async()=>s.turnstile.widgets.get({account_id:l,sitekey:c.sitekey})),{successLabel:`Loaded`})})};function b(e){return e.usage(`$0 turnstile widgets list
20
+
21
+ Lists all turnstile widgets of an account.`).option(`page`,{type:`number`,description:`Page number of paginated results.`}).option(`per-page`,{type:`number`,description:`Number of items per page.`}).option(`order`,{type:`string`,description:`Field to order widgets by.`,choices:[`id`,`sitekey`,`name`,`created_on`,`modified_on`]}).option(`direction`,{type:`string`,description:`Direction to order widgets.`,choices:[`asc`,`desc`]}).option(`filter`,{type:`string`,description:"Filter widgets by field using case-insensitive substring matching.\nFormat: `field:value`\n\nSupported fields:\n- `name` - Filter by widget name (e.g., `filter=name:login-form`)\n- `sitekey` - Filter by sitekey (e.g., `filter=sitekey:0x4AAA`)\n\nReturns 400 Bad Request if the field is unsupported or format is invalid.\nAn empty filter value returns all results."}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const x={command:`list`,describe:`List Turnstile Widgets`,builder:p(b),handler:async c=>s({command:`turnstile widgets list`,classification:{safeFlags:[`order`,`direction`,`dry-run`]}},c,async()=>{let s={page:c.page,per_page:c[`per-page`],order:c.order,direction:c.direction,filter:c.filter};if(c.dryRun){a({command:`cf turnstile widgets list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/challenges/widgets`,pathParams:{},query:s,bodyKind:`none`});return}let l=await r(c),u=c.local?e:await t();c.accountId=u,i(await o(`Loading`,async()=>l.turnstile.widgets.list({account_id:u,...s})),{successLabel:`Loaded`})})};function S(e){return e.usage("$0 turnstile widgets rotate-secret <sitekey>\n\nGenerate a new secret key for this widget. If `invalidate_immediately` is set to `false`, the previous secret remains valid for 2 hours. Note that secrets cannot be rotated again during the grace period.").positional(`sitekey`,{type:`string`,description:`Widget item identifier tag.`,demandOption:!0}).option(`invalidate-immediately`,{type:`boolean`,description:"If `invalidate_immediately` is set to `false`, the previous secret will\nremain valid for two hours. Otherwise, the secret is immediately\ninvalidated, and requests using it will be rejected.\n",default:!1}).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:`rotate-secret <sitekey>`,describe:`Rotate Secret for a Turnstile Widget`,builder:S,handler:async u=>s({command:`turnstile widgets rotate-secret`,classification:{safeFlags:[`invalidate-immediately`,`dry-run`]}},u,async()=>{if(u.dryRun){a({command:`cf turnstile widgets rotate-secret`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/challenges/widgets/${u.sitekey==null?`<sitekey>`:encodeURIComponent(String(u.sitekey))}/rotate_secret`,pathParams:{sitekey:String(u.sitekey??``)},bodyKind:`json`,body:u.body===void 0?l({invalidate_immediately:u[`invalidate-immediately`]}):c(u.body)});return}let s=await r(u),d=u.local?e:await t();if(u.accountId=d,u.body){let e=c(u.body);i(await o(`Creating`,async()=>s.turnstile.widgets.rotateSecret({...e,account_id:d,sitekey:u.sitekey})),{successLabel:`Created`});return}let f=l({invalidate_immediately:u[`invalidate-immediately`]});i(await o(`Creating`,async()=>s.turnstile.widgets.rotateSecret({...f,account_id:d,sitekey:u.sitekey})),{successLabel:`Created`})})};function w(e){return e.usage(`$0 turnstile widgets update <sitekey>
22
+
23
+ Update the configuration of a widget.`).positional(`sitekey`,{type:`string`,description:`Widget item identifier tag.`,demandOption:!0}).option(`bot-fight-mode`,{type:`boolean`,description:`If bot_fight_mode is set to \`true\`, Cloudflare issues computationally
24
+ expensive challenges in response to malicious bots (ENT only).
25
+ `}).option(`clearance-level`,{type:`string`,description:`If Turnstile is embedded on a Cloudflare site and the widget should grant challenge clearance,
26
+ this setting can determine the clearance level to be set
27
+ `,choices:[`no_clearance`,`jschallenge`,`managed`,`interactive`]}).option(`domains`,{type:`string`,array:!0,description:`The domains field`}).option(`ephemeral-id`,{type:`boolean`,description:`Return the Ephemeral ID in /siteverify (ENT only).
28
+ `}).option(`name`,{type:`string`,description:`Human readable widget name. Not unique. Cloudflare suggests that you
29
+ set this to a meaningful string to make it easier to identify your
30
+ widget, and where it is used.
31
+ `}).option(`offlabel`,{type:`boolean`,description:`Do not show any Cloudflare branding on the widget (ENT only).
32
+ `}).option(`region`,{type:`string`,description:`Region where this widget can be used. This cannot be changed after creation.
33
+ `,choices:[`world`,`china`]}).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 T={command:`update <sitekey>`,describe:`Update a Turnstile Widget`,builder:w,handler:async f=>s({command:`turnstile widgets update`,classification:{safeFlags:[`bot-fight-mode`,`clearance-level`,`ephemeral-id`,`offlabel`,`region`,`dry-run`]}},f,async()=>{if(f.dryRun){a({command:`cf turnstile widgets update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/challenges/widgets/${f.sitekey==null?`<sitekey>`:encodeURIComponent(String(f.sitekey))}`,pathParams:{sitekey:String(f.sitekey??``)},bodyKind:`json`,body:f.body===void 0?l({bot_fight_mode:f[`bot-fight-mode`],clearance_level:u(f[`clearance-level`],`clearance-level`,`text`),domains:f.domains,ephemeral_id:f[`ephemeral-id`],name:u(f.name,`name`,`text`),offlabel:f.offlabel,region:u(f.region,`region`,`text`)}):c(f.body)});return}let s=await r(f),p=f.local?e:await t();if(f.accountId=p,f.body){let e=c(f.body);i(await o(`Updating`,async()=>s.turnstile.widgets.update({...e,account_id:p,sitekey:f.sitekey})),{successLabel:`Updated`});return}if(f.domains===void 0)throw Error(`--domains is required (or pass --body with this field set).`);f.name===void 0&&(f.name=await d(`name`,`Human readable widget name. Not unique. Cloudflare suggests that you set this to a meaningful string to make it easier to identify your widget, and where it is used. `));let m=l({bot_fight_mode:f[`bot-fight-mode`],clearance_level:u(f[`clearance-level`],`clearance-level`,`text`),domains:f.domains,ephemeral_id:f[`ephemeral-id`],name:u(f.name,`name`,`text`),offlabel:f.offlabel,region:u(f.region,`region`,`text`)});i(await o(`Updating`,async()=>s.turnstile.widgets.update({...m,account_id:p,sitekey:f.sitekey})),{successLabel:`Updated`})})},E={command:`widgets`,describe:`Turnstile widget configurations — site keys, secret rotation, and challenge mode settings`,builder:e=>e.command(h).command(_).command(y).command(x).command(C).command(T).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},D={command:`turnstile`,describe:`CAPTCHA-free bot verification widgets that protect forms and APIs without degrading user experience`,builder:e=>e.command(E).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{D as default};
@@ -0,0 +1,5 @@
1
+ #!/usr/bin/env node
2
+ import"./delegate-GctF_lrq.mjs";import{i as e,n as t,t as n}from"./theme-BiIYWOed.mjs";import{stripVTControlCharacters as r}from"node:util";function i(r){return`${t().hex(n.warning)(e.warning)} ${r}`}function a(r){return`${t().hex(n.info)(e.info)} ${r}`}function o(r){let i=t().hex(n.muted);return`${i(e.arrow)} ${i(r)}`}function s(e,a){let o=t(),s=process.env.CF_DELEGATION?` ${o.dim(`·`)} ${o.dim(`delegated`)}`:``,c=a?` ${o.dim(`·`)} ${o.hex(n.warning)(`update available: v${a.latestVersion}`)}`:``,l=`🍊☁️ ${o.bold.hex(n.orange)(`cf`)} ${o.dim(`·`)} ${o.dim(`v${e}`)}${s}${c}`,u=r(l).length,d=`─`.repeat(u);return`${l}\n${o.hex(n.orange)(d)}${a?.isMajor?`\n${i(`A new major version of cf is available. Updating is recommended.`)}`:``}`}const c={bar:`│`,top:`┌`,bottom:`└`};function l(e,r,i){let a=i?.title??`Error`,o=t(),s=n.error,l=o.hex(s)(c.bar),d=o.hex(s)(c.top),f=o.hex(s)(c.bottom),p=Math.max(20,(process.stdout.columns||80)-2),m=[];if(m.push(``),m.push(`${d} ${o.hex(s).bold(a)}`),i?.rawMessage)for(let t of e.split(`
3
+ `))m.push(t.length>0?`${l} ${t}`:l);else for(let t of u(e,p))m.push(t.length>0?`${l} ${o.hex(s).bold(t)}`:l);if(r){m.push(l);for(let e of u(r,p))m.push(e.length>0?`${l} ${o.dim(e)}`:l)}return m.push(f),m.join(`
4
+ `)}function u(e,t){let n=[];for(let r of e.split(`
5
+ `)){if(r.length<=t){n.push(r);continue}let e=r.split(/\s+/),i=``;for(let r of e){if(!i){i=r;continue}i.length+1+r.length<=t?i+=` `+r:(n.push(i),i=r)}i&&n.push(i)}return n}export{i as a,a as i,s as n,o as r,l as t};