cf 1.0.0-beta.18 → 1.0.0-beta.19
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.
- package/README.md +7 -0
- package/dist/_meta/commands.json +3003 -1544
- package/dist/_meta/hand-written-commands.json +6 -0
- package/dist/_meta/schemas.json +2127 -1070
- package/dist/{abuse-reports-Ce-g5uZP.mjs → abuse-reports-DhgunVFo.mjs} +3 -3
- package/dist/{access-BtsMwesh.mjs → access-BDoDq_WZ.mjs} +1 -1
- package/dist/{accounts-X5QVzEUW.mjs → accounts-DLTCzZJg.mjs} +24 -26
- package/dist/{acm-C_NepMi6.mjs → acm-DS1CosYq.mjs} +1 -1
- package/dist/{addressing-BkQY1hoA.mjs → addressing-DFeYj8TY.mjs} +2 -2
- package/dist/{agent-memory-1OPgC3lK.mjs → agent-memory-DXjQ8N0g.mjs} +1 -1
- package/dist/{ai-Bb0_Zknm.mjs → ai-V5YopMkS.mjs} +4 -4
- package/dist/{ai-audit-DuEjVdML.mjs → ai-audit-yg8D0azz.mjs} +2 -2
- package/dist/{ai-gateway-Cm2vWMSI.mjs → ai-gateway--dkH9qGz.mjs} +13 -13
- package/dist/ai-search-BRtsUaUI.mjs +79 -0
- package/dist/{ai-security-A2STvE1b.mjs → ai-security-DRJCcLpF.mjs} +1 -1
- package/dist/{alerting-CIwSk-Ks.mjs → alerting-8DsyMKGG.mjs} +30 -30
- package/dist/{analytics-H--uM3DA.mjs → analytics-BpYUZTtQ.mjs} +1 -1
- package/dist/{analytics-engine-Alu7cllT.mjs → analytics-engine-CT2E0Dkw.mjs} +1 -1
- package/dist/{api-security-D-pcnhUL.mjs → api-security-CBhWZE8z.mjs} +6 -6
- package/dist/{argo-Lvmcx3am.mjs → argo-B0u2N3Dh.mjs} +1 -1
- package/dist/{artifacts-xT5S-mVa.mjs → artifacts-B6XzjMiM.mjs} +1 -1
- package/dist/{audit-logs-DEoRBLkU.mjs → audit-logs-59fCc1aw.mjs} +1 -1
- package/dist/auth-5cgi8ePZ.mjs +2 -0
- package/dist/auth-BaUNb1Ed.mjs +2 -0
- package/dist/auth-ChYOc_rS.mjs +2 -0
- package/dist/{auth-token-D9XIPlwf.mjs → auth-token-B1pP2jaK.mjs} +1 -1
- package/dist/{autoconfig-9po_tqsS.mjs → autoconfig-Cdm2IFLM.mjs} +20 -20
- package/dist/{basin-catalog-DFHt3cWi.mjs → basin-catalog-CV05WlA4.mjs} +1 -1
- package/dist/{billing-Bm2JNSGa.mjs → billing-Ad-rK-JH.mjs} +3 -3
- package/dist/{blocks-Bat9A8V_.mjs → blocks-CKb_aLWN.mjs} +1 -1
- package/dist/body-parser-ChnyBsfm.mjs +2 -0
- package/dist/{bot-management-CSr38g-O.mjs → bot-management-CGpfjQ4w.mjs} +1 -1
- package/dist/{botnet-feed-ebeWWSJj.mjs → botnet-feed-CMrF6ZGq.mjs} +1 -1
- package/dist/{brand-protection-BCn9Mv-d.mjs → brand-protection-CP73_yX8.mjs} +1 -1
- package/dist/{browser-run-BcWxzhAn.mjs → browser-run-OpUfawh_.mjs} +21 -21
- package/dist/{build-i8l2qGVZ.mjs → build-CMPlf8mh.mjs} +1 -1
- package/dist/build-DQZ2w_dQ.mjs +2 -0
- package/dist/{builds-BMwDzi7G.mjs → builds-DsRNlILV.mjs} +39 -39
- package/dist/{cache-_VaTLC5T.mjs → cache-RppXjxXA.mjs} +3 -3
- package/dist/{cf-Bq4pA4n6.mjs → cf-PISMdEje.mjs} +11 -11
- package/dist/{chunk-2HLTAS5V-D7COzUOd.mjs → chunk-2HLTAS5V-B92NbX1j.mjs} +1 -1
- package/dist/{chunk-2K52M2W5-CYxfQXUq.mjs → chunk-2K52M2W5-c__08AOB.mjs} +7 -7
- package/dist/chunk-DSGVRFIS-DfQO1boa.mjs +2 -0
- package/dist/{cli-P3q5DG3W.mjs → cli-Dd1n2YAJ.mjs} +1 -1
- package/dist/{client-side-security-CjSXrpa9.mjs → client-side-security-BYfwOkUo.mjs} +1 -1
- package/dist/{cloud-connector-BPJBeP06.mjs → cloud-connector-CQZUqAMQ.mjs} +2 -2
- package/dist/{cloudflared-By8BzYXc.mjs → cloudflared-C1SdXpYv.mjs} +1 -1
- package/dist/{cloudforce-one-DXX31GMi.mjs → cloudforce-one-C1xdpspb.mjs} +200 -210
- package/dist/{command-Bkc04OyY.mjs → command-BioiZMm9.mjs} +1 -1
- package/dist/{command-BbsPxJBT.mjs → command-C0nJ2LRd.mjs} +1 -1
- package/dist/{command-DDcBC4px.mjs → command-C5ARgURy.mjs} +1 -1
- package/dist/{command-CL7LLXM7.mjs → command-C7NIRU-u.mjs} +1 -1
- package/dist/{command-BXiA79DP.mjs → command-C8DV-x_C.mjs} +1 -1
- package/dist/{command-BtTc28ql.mjs → command-CFV1cqfR.mjs} +1 -1
- package/dist/{command-NoxvOARP.mjs → command-ChQXv0jP.mjs} +1 -1
- package/dist/{command-DCQgsd2U.mjs → command-D203VrTG.mjs} +1 -1
- package/dist/{command-DZfKHiru.mjs → command-D5BUzDX8.mjs} +1 -1
- package/dist/{command-CBZhxmKD.mjs → command-DWE7YdeC.mjs} +1 -1
- package/dist/{command-C6w1OdoC.mjs → command-DlB10kIb.mjs} +1 -1
- package/dist/{command-CxWLFv5Y.mjs → command-DmPQXNRg.mjs} +1 -1
- package/dist/{command-Bgb-3yPg.mjs → command-F0jlqvKr.mjs} +1 -1
- package/dist/{command-DppVezAB.mjs → command-FOQNhNqP.mjs} +1 -1
- package/dist/{command-CYyfigfC.mjs → command-yAXk5NXh.mjs} +1 -1
- package/dist/{completions-CrDmwKnK.mjs → completions-Bh0Hz-hA.mjs} +3 -3
- package/dist/{connector-interrupts-V4HGULCM.mjs → connector-interrupts-Bd949WX0.mjs} +1 -1
- package/dist/{connector-telemetry-events-D9mTcfbJ.mjs → connector-telemetry-events-Dw8iIg5Q.mjs} +1 -1
- package/dist/{connector-telemetry-snapshots-COrPVKol.mjs → connector-telemetry-snapshots-DqEIaz99.mjs} +1 -1
- package/dist/{connectors-DvVlxGDx.mjs → connectors-RUEU1QDB.mjs} +1 -1
- package/dist/containers-xU-0EhLO.mjs +78 -0
- package/dist/{containers-BtcOgwm5.mjs → containers-yUOvm-4V.mjs} +211 -211
- package/dist/{content-scan-DldLmTjy.mjs → content-scan-Cm2-Xhqo.mjs} +2 -2
- package/dist/{context-C_a8oSY9.mjs → context-BQ6KeMgq.mjs} +2 -2
- package/dist/{cps-REo1OWP1.mjs → cps-CgPduy0H.mjs} +1 -1
- package/dist/{csam-scanner-CIbbdoJK.mjs → csam-scanner-B0Ra6fXL.mjs} +1 -1
- package/dist/{custom-csrs-iGNc3rSZ.mjs → custom-csrs-6lfu1-RR.mjs} +1 -1
- package/dist/{custom-hostnames-BNxYbTyu.mjs → custom-hostnames-Dzov_CPw.mjs} +15 -15
- package/dist/{custom-nameservers-BMJoTSlQ.mjs → custom-nameservers-Bfhv_9_k.mjs} +1 -1
- package/dist/{custom-pages-Qdemt1Fm.mjs → custom-pages-DxVD_f10.mjs} +1 -1
- package/dist/{d1-DvCiQibO.mjs → d1-D7p4uJ-e.mjs} +10 -12
- package/dist/delegate.mjs +1 -1
- package/dist/{deploy-K664XPOb.mjs → deploy-BjWvVZol.mjs} +1 -1
- package/dist/deploy-context-C-ZdGP0Z.mjs +56 -0
- package/dist/{deploy-input-KK6yyBN_.mjs → deploy-input-B8Nq6Eh6.mjs} +1 -1
- package/dist/{dev-CnoMHxf4.mjs → dev-D20UkcYT.mjs} +1 -1
- package/dist/{diagnostics-Cw0mtcep.mjs → diagnostics-DdhTemYB.mjs} +1 -1
- package/dist/{dialog-D4Y9ocuF.mjs → dialog-BnIgdgWi.mjs} +1 -1
- package/dist/discover-DEjUARkU.mjs +2 -0
- package/dist/{dist-DZRTPMMA.mjs → dist-CnKd5XoR.mjs} +19 -19
- package/dist/{dist-uRuGmkMB.mjs → dist-DAeCUX-u.mjs} +3 -3
- package/dist/{dls-DoqfqutH.mjs → dls-BBODA9Rk.mjs} +1 -1
- package/dist/{dns-DC6WcO3m.mjs → dns-CK_hyn5q.mjs} +5 -5
- package/dist/{dns-firewall-DpQH9BCE.mjs → dns-firewall-DbvX9R-7.mjs} +1 -1
- package/dist/{docs-CqNRBHab.mjs → docs-BDTijwM3.mjs} +1 -1
- package/dist/{dot-prop-IITUZ2XW-BnPfnQkb.mjs → dot-prop-IITUZ2XW-C4pkmT-K.mjs} +1 -1
- package/dist/{dotenv-usOKkeW7.mjs → dotenv-Ck-6V1hm.mjs} +1 -1
- package/dist/{dry-run-C2KjGX10.mjs → dry-run-DQmFkNK_.mjs} +1 -1
- package/dist/{durable-objects-CJDDy3CC.mjs → durable-objects-DcFbd1Ka.mjs} +1 -1
- package/dist/{email-auth--NHg1TjG.mjs → email-auth-BEgDxU-g.mjs} +1 -1
- package/dist/{email-routing-COjENK55.mjs → email-routing-DKWmPOVo.mjs} +1 -1
- package/dist/{email-security-rdjH95T2.mjs → email-security-RWbAp8qa.mjs} +15 -15
- package/dist/{email-sending-26VJhR6Q.mjs → email-sending-BbJy_vl8.mjs} +1 -1
- package/dist/error-sanitization-Byb-_IS9.mjs +2 -0
- package/dist/{error-sanitization-pOyzm2F1.mjs → error-sanitization-DWJ5ka7h.mjs} +1 -1
- package/dist/{field-extractors-DBOvGOwz.mjs → field-extractors-Bob6udAc.mjs} +1 -1
- package/dist/{firewall-D8K93ffF.mjs → firewall-DziiEsR8.mjs} +1 -1
- package/dist/{flagship-CHdmCmvQ.mjs → flagship-xOtgddUK.mjs} +1 -1
- package/dist/{fraud-CY4TV5Vc.mjs → fraud-BUS7i5Yh.mjs} +1 -1
- package/dist/generate-D6V4Q58z.mjs +2 -0
- package/dist/get-BTisquA3.mjs +2 -0
- package/dist/{google-tag-gateway-DzSt4wlz.mjs → google-tag-gateway-DgSzyeK-.mjs} +1 -1
- package/dist/{gt-3bcLGJ7V.mjs → gt-D6YemCLh.mjs} +1 -1
- package/dist/{healthchecks-B52Mf3uL.mjs → healthchecks-CbD2PsnM.mjs} +1 -1
- package/dist/{hyperdrive-CHsW0r6Z.mjs → hyperdrive-Cs_cfSXU.mjs} +1 -1
- package/dist/{iam-o1n9eUXf.mjs → iam-DvsCztqU.mjs} +5 -5
- package/dist/{images-CJHAGxX6.mjs → images-BipVjHNw.mjs} +1 -1
- package/dist/index.mjs +1 -1
- package/dist/init-LvFgCsNX.mjs +43 -0
- package/dist/{intel-B3S1gxUg.mjs → intel-D1LPkkBM.mjs} +31 -41
- package/dist/{interactive-BW9T1D1q.mjs → interactive-d_lFnSev.mjs} +3 -3
- package/dist/interactive-pjVqirHx.mjs +2 -0
- package/dist/{ips-q_UJMiy8.mjs → ips-2iUGs8ws.mjs} +1 -1
- package/dist/{k2-BNqVZnDN.mjs → k2-DGzRm3NJ.mjs} +1 -1
- package/dist/{kv-B0nXSOcW.mjs → kv-BW-s9MJY.mjs} +4 -4
- package/dist/{lazy-command-4ccdBqrc.mjs → lazy-command-Bq-rWPQe.mjs} +1 -1
- package/dist/{leaked-credential-checks-BXwIjlTs.mjs → leaked-credential-checks-CnY6ih6p.mjs} +1 -1
- package/dist/{load-balancers-DJtMztJ0.mjs → load-balancers-CtnusAzP.mjs} +1 -1
- package/dist/{local-Dil4fTWX.mjs → local-B4sZZTRA.mjs} +1 -1
- package/dist/local-DCnFIgLJ.mjs +2 -0
- package/dist/{local-runtime-B7TKFu6E.mjs → local-runtime-DoBuyriC.mjs} +1 -1
- package/dist/login-CqZJgUF1.mjs +5 -0
- package/dist/{login-D-1FiBNv.mjs → login-DR60WiAY.mjs} +1 -1
- package/dist/{logo-matches-qVYq8tWL.mjs → logo-matches-C1-6KOkZ.mjs} +1 -1
- package/dist/{logos-tnIahhcu.mjs → logos-Yzhd-VKb.mjs} +2 -2
- package/dist/{logpush-D4s3pJRw.mjs → logpush-JYG4gXZ-.mjs} +3 -3
- package/dist/{logs-cw7UL5V2.mjs → logs-DLblEjK0.mjs} +1 -1
- package/dist/{magic-cloud-networking-CLEHztNY.mjs → magic-cloud-networking-CblQwsQr.mjs} +13 -13
- package/dist/{magic-network-monitoring-DRwygeVq.mjs → magic-network-monitoring-D2px4Ep4.mjs} +3 -3
- package/dist/{magic-transit-BFopRdPs.mjs → magic-transit-Bnwsi0UQ.mjs} +61 -61
- package/dist/{managed-defense-D5kpmq0T.mjs → managed-defense-CTtNoxzW.mjs} +3 -3
- package/dist/{managed-transforms-CT4jjnzJ.mjs → managed-transforms-B92mJi5i.mjs} +1 -1
- package/dist/{matches-ClJ_24EY.mjs → matches-CzbL1XD-.mjs} +1 -1
- package/dist/{mcp-50os3IRG.mjs → mcp-Cic_aMer.mjs} +1 -1
- package/dist/{mesh-jxtQP8sS.mjs → mesh-DZTgD16C.mjs} +14 -14
- package/dist/{migrate-DerOyuv2.mjs → migrate-DtNDRcAI.mjs} +1 -1
- package/dist/{monetization-D6cCDi-h.mjs → monetization-DCQ2_niU.mjs} +1 -1
- package/dist/{network-dnWHB2uY.mjs → network-BqMqD2qn.mjs} +1 -1
- package/dist/{network-interconnects-Cf8qSVdt.mjs → network-interconnects-BFQ1yARl.mjs} +2 -2
- package/dist/{o11y-oMSg1pG4.mjs → o11y-CS5q1vSh.mjs} +5 -5
- package/dist/oauth-DPLYUvRl.mjs +2 -0
- package/dist/oauth-DdYSPYoE.mjs +4 -0
- package/dist/{oauth-clients-XDmoe-b4.mjs → oauth-clients-9BPswYm_.mjs} +1 -1
- package/dist/{oauth-scopes-D9VYGuTs.mjs → oauth-scopes-CLOKfQi2.mjs} +1 -1
- package/dist/{open-PCXX3ZDZ-5J5IU2MX-CKla-jDt.mjs → open-PCXX3ZDZ-5J5IU2MX-DFe2CQkm.mjs} +1 -1
- package/dist/{open-PCXX3ZDZ-D55O2jpQ.mjs → open-PCXX3ZDZ-BD2iNJqn.mjs} +1 -1
- package/dist/{organization-94lHeeOs.mjs → organization-DFRN2g6z.mjs} +1 -1
- package/dist/{organizations-BJf3UTFi.mjs → organizations-yiGopnKf.mjs} +1 -1
- package/dist/{origin-post-quantum-encryption-DMytVSUZ.mjs → origin-post-quantum-encryption-n9gsxikn.mjs} +1 -1
- package/dist/output-O6b9MR9R.mjs +2 -0
- package/dist/{page-rules-BUI-50oz.mjs → page-rules-F1Jdxx6A.mjs} +1 -1
- package/dist/{pages-CcdpCzHs.mjs → pages-CezC0YrR.mjs} +2 -2
- package/dist/{pay-per-crawl-B1uHZn9j.mjs → pay-per-crawl-fZ-kTBbN.mjs} +2 -2
- package/dist/{pay-per-use-t066I5wm.mjs → pay-per-use-B14BTKVI.mjs} +2 -2
- package/dist/{pipelines-Co6S044l.mjs → pipelines-BN7ydBHl.mjs} +5 -5
- package/dist/{precursor-BftyvS86.mjs → precursor-B88RDDZT.mjs} +2 -2
- package/dist/previews-CiqRIq_k.mjs +7 -0
- package/dist/process-DiXf4VPi.mjs +2 -0
- package/dist/{progress-Q5w9PNTT.mjs → progress-CdlDthXA.mjs} +1 -1
- package/dist/{prompt-C0hKSr-R.mjs → prompt-1AC-qwxS.mjs} +1 -1
- package/dist/{queries-4MubO6Sz.mjs → queries-C2sgUI9j.mjs} +1 -1
- package/dist/{queues-CteS5M92.mjs → queues-DCP5x-PZ.mjs} +1 -1
- package/dist/{r2-2QpT_Gso.mjs → r2-D7UhzWR7.mjs} +26 -26
- package/dist/{radar-ODKaK4FJ.mjs → radar-osOiFeY_.mjs} +1 -1
- package/dist/{raw-fetch-CEOuoKl9.mjs → raw-fetch-1VlXDwwX.mjs} +1 -1
- package/dist/{realtime-DkfU8uEX.mjs → realtime-DCnqxiWo.mjs} +90 -87
- package/dist/{registrar-DM6JTVPS.mjs → registrar-DAFYjjRa.mjs} +8 -8
- package/dist/{registrar-sandbox-BPNGf65G.mjs → registrar-sandbox-zeNHABZ0.mjs} +4 -4
- package/dist/{registry-CRnk93ur.mjs → registry-DG4ZiuN9.mjs} +1 -1
- package/dist/{reporting-5yFNXbJg.mjs → reporting-KehV_PXm.mjs} +1 -1
- package/dist/{request-headers-DXvswze2.mjs → request-headers-ojAw3pQO.mjs} +1 -1
- package/dist/{request-tracers-BarLZY95.mjs → request-tracers-BStCgh6m.mjs} +1 -1
- package/dist/resolve-BGNMAcGR.mjs +2 -0
- package/dist/{resource-sharing-BVEwBPs8.mjs → resource-sharing-3xtSgWG7.mjs} +3 -3
- package/dist/{rules-_C31X4Jz.mjs → rules-7F-G2Bg_.mjs} +3 -3
- package/dist/{rulesets-8RwxoFhG.mjs → rulesets-B0YtS2br.mjs} +20 -20
- package/dist/{rum-CAUcpXpM.mjs → rum-B3V6tqS-.mjs} +1 -1
- package/dist/{run-DtFLvOHB.mjs → run-B_07PrkW.mjs} +1 -1
- package/dist/run-D6AJfZT-.mjs +2 -0
- package/dist/{schema-S3pUZwpI.mjs → schema-C-tyhSnb.mjs} +1 -1
- package/dist/{schema-flags-DibfxEF6.mjs → schema-flags-DY3OKCvr.mjs} +4 -4
- package/dist/{scim-DX5XrQ4w.mjs → scim-CQ9TdajH.mjs} +6 -6
- package/dist/{secrets-store-DSqqrr25.mjs → secrets-store-Dl2hDxXu.mjs} +2 -2
- package/dist/{security-insights-FSktO04S.mjs → security-insights-BsLMdo1r.mjs} +2 -2
- package/dist/{security-txt-D2g3lQdg.mjs → security-txt-pCAiHvys.mjs} +1 -1
- package/dist/session-BsNzFtPi.mjs +2 -0
- package/dist/shared-CWBjMZDR.mjs +2 -0
- package/dist/{smart-shield-IVb2sR0C.mjs → smart-shield-BTXQsVxz.mjs} +1 -1
- package/dist/{snippets-cWwWficN.mjs → snippets-CYVieyc3.mjs} +2 -2
- package/dist/source-AlTrHNem.mjs +6 -0
- package/dist/{spawn-BW2bJmKO.mjs → spawn-Bdznd0EB.mjs} +2 -2
- package/dist/{spectrum-DYiIBYRB.mjs → spectrum-DLRr4Q03.mjs} +14 -14
- package/dist/{speed-C7uiW2Wf.mjs → speed-BJfaDYxz.mjs} +13 -13
- package/dist/sql-DQ4xrdc2.mjs +4 -0
- package/dist/src-BnMvFE3q.mjs +125 -0
- package/dist/{ssl-xQP_HbWN.mjs → ssl-CL1B69Pw.mjs} +1 -1
- package/dist/startup-profile-DuaJFX1y.mjs +2 -0
- package/dist/startup-profile-HMblAiBi.mjs +29 -0
- package/dist/{state-Boubf1X6.mjs → state-DN9yfd2C.mjs} +1 -1
- package/dist/state-DePlO0Kv.mjs +2 -0
- package/dist/{stream-CfWgj8Cr.mjs → stream-DrMZOO5u.mjs} +17 -17
- package/dist/{submit-DxGr1T40.mjs → submit-DjlLoVk2.mjs} +1 -1
- package/dist/{tags-LEJ2VYhQ.mjs → tags-DY7Ur1k-.mjs} +4 -4
- package/dist/{telemetry-BHne10Yy.mjs → telemetry-BG3kcYsV.mjs} +1 -1
- package/dist/telemetry-Dpm6GfZD.mjs +2 -0
- package/dist/{tenant-7d5vwc6K.mjs → tenant-BEMfNMjO.mjs} +1 -1
- package/dist/{tenant-custom-nameservers-BkxlPr5O.mjs → tenant-custom-nameservers-CCRbb0ch.mjs} +1 -1
- package/dist/{tools-BCCRUENY.mjs → tools-ZffhHUDd.mjs} +1 -1
- package/dist/tunnels-_JXe-UgM.mjs +29 -0
- package/dist/{turnstile-DhLkdhij.mjs → turnstile-DXEfneQq.mjs} +1 -1
- package/dist/ui-CY79jlGZ.mjs +2 -0
- package/dist/update-check-DfbYVefm.mjs +2 -0
- package/dist/{update-check-wvjOsnGK.mjs → update-check-atcehhBC.mjs} +1 -1
- package/dist/update-check-worker.mjs +1 -1
- package/dist/{url-info-CeoV5dBc.mjs → url-info-B1kL9asc.mjs} +1 -1
- package/dist/{url-normalization-9NoaoRNh.mjs → url-normalization-CUHKRKJh.mjs} +1 -1
- package/dist/{url-scanner-w_-Sumz-.mjs → url-scanner-OnZP_-jm.mjs} +2 -2
- package/dist/{user-D33B3alX.mjs → user-BBBuFNj4.mjs} +1 -1
- package/dist/{vectorize-Wp9De13y.mjs → vectorize-DcctB8bw.mjs} +3 -3
- package/dist/version-CLgSHoNm.mjs +2 -0
- package/dist/{waiting-rooms-BE8FloRd.mjs → waiting-rooms-JaFE5wP1.mjs} +2 -2
- package/dist/{web-assets-ew0iaP7c.mjs → web-assets-Cu0swUPe.mjs} +10 -10
- package/dist/{web3-BUyXBaqq.mjs → web3-C67z4OtQ.mjs} +1 -1
- package/dist/{workers-pP5tsDbD.mjs → workers-ClTP0Ysl.mjs} +5 -5
- package/dist/{workers-builds-DzU9NGno.mjs → workers-builds-C5wKhvKe.mjs} +7 -7
- package/dist/{workers-for-platforms-B4xzFNxJ.mjs → workers-for-platforms-rxwkYyb3.mjs} +5 -5
- package/dist/{workers-vpc-Bre_t9Al.mjs → workers-vpc-B4vyvr1W.mjs} +1 -1
- package/dist/{workflows-DXYGKtqq.mjs → workflows-COJ5jwvk.mjs} +24 -24
- package/dist/wrangler-migration-Cp546RDG.mjs +946 -0
- package/dist/{zaraz-DoH4QD0u.mjs → zaraz-BkZ7yW05.mjs} +2 -2
- package/dist/{zero-trust-DKt20rzE.mjs → zero-trust-lUFLYuL1.mjs} +496 -444
- package/dist/{zone-BXM3p0JR.mjs → zone-CC1_qxt-.mjs} +1 -1
- package/dist/{zones-CJdtqEBx.mjs → zones-BRiLlTmW.mjs} +37 -28
- package/package.json +11 -11
- package/dist/ai-search-DDRpxyOM.mjs +0 -79
- package/dist/auth-B73lQS2h.mjs +0 -2
- package/dist/auth-DMzEmOhG.mjs +0 -2
- package/dist/auth-Db1KT0vm.mjs +0 -2
- package/dist/body-parser-DnBfDdx3.mjs +0 -2
- package/dist/build-BRJnyeu8.mjs +0 -2
- package/dist/chunk-DSGVRFIS-C5SqiTOz.mjs +0 -2
- package/dist/containers-Bt2zFsFd.mjs +0 -78
- package/dist/deploy-context-ClNVJYlR.mjs +0 -56
- package/dist/discover-DIDEGKo3.mjs +0 -2
- package/dist/error-sanitization-CIQOep3I.mjs +0 -2
- package/dist/generate-D80-1GnZ.mjs +0 -2
- package/dist/get-By1q8YlI.mjs +0 -2
- package/dist/hostnames-BMITIM8P.mjs +0 -11
- package/dist/init-CqQDL6i3.mjs +0 -43
- package/dist/interactive-DGUWZ2Gk.mjs +0 -2
- package/dist/local-DxWDQDnG.mjs +0 -2
- package/dist/login-chQP8825.mjs +0 -5
- package/dist/oauth-BfBdHhPS.mjs +0 -4
- package/dist/oauth-DDOiiH7h.mjs +0 -2
- package/dist/output-Co4xdFf6.mjs +0 -2
- package/dist/previews-BLhnhElx.mjs +0 -7
- package/dist/process-2wmDCy17.mjs +0 -2
- package/dist/resolve-BpgXeklt.mjs +0 -2
- package/dist/run-LcOb9rhI.mjs +0 -2
- package/dist/session-Cq3YNLoI.mjs +0 -2
- package/dist/shared-eefMO8R4.mjs +0 -2
- package/dist/source-mXUcrTVw.mjs +0 -6
- package/dist/sql-TGV8qQMj.mjs +0 -4
- package/dist/src-BUH-P_zd.mjs +0 -125
- package/dist/startup-profile-BOaseXnO.mjs +0 -29
- package/dist/startup-profile-BwEZFVGS.mjs +0 -2
- package/dist/state-CODDG9Nx.mjs +0 -2
- package/dist/telemetry-BavSU4ku.mjs +0 -2
- package/dist/tunnels-DlGODvwT.mjs +0 -29
- package/dist/ui-BtIBQeaG.mjs +0 -2
- package/dist/update-check-nLfkSfdz.mjs +0 -2
- package/dist/version-B2RUUqGT.mjs +0 -2
- package/dist/wrangler-migration-R9TQ_4Qd.mjs +0 -946
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import{t as e}from"./lazy-command-Bq-rWPQe.mjs";import"./api-eMuS5GI1.mjs";import{t}from"./path-DRw6Y-nd.mjs";import{t as n}from"./hand-written-dry-run-B82fRl2N.mjs";import{t as r}from"./local-B4sZZTRA.mjs";import{n as i}from"./auth-BaUNb1Ed.mjs";import{a,t as o}from"./context-BQ6KeMgq.mjs";import{t as s}from"./output-O6b9MR9R.mjs";import{t as c}from"./dry-run-DQmFkNK_.mjs";import{t as l}from"./progress-CdlDthXA.mjs";import{t as u}from"./run-B_07PrkW.mjs";import"./telemetry-Dpm6GfZD.mjs";import{a as d,n as f,t as p}from"./body-parser-ChnyBsfm.mjs";import{n as m}from"./input-validation-D7z60HJH.mjs";import{a as h,n as g}from"./prompt-1AC-qwxS.mjs";import{t as _}from"./create-OXylMu6m.mjs";import{t as v}from"./get-iPUHxD1r.mjs";var y={method:`GET`,path:e=>t`/accounts/${e.account_id}/cfd_tunnel/${e.tunnel_id}/configurations`};function b(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 ee={command:`get <tunnel-id>`,describe:`Get Tunnel configuration`,builder:b,handler:async e=>u({command:`tunnels config get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await a();c({command:`cf tunnels config get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<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 t=await i(e),n=e.local?r:await o();e.accountId=n;let u=await l(`Loading`,async()=>t.send(y,{account_id:n,tunnel_id:e[`tunnel-id`]}));s(u,{successLabel:`Loaded`})})};var x={method:`PUT`,path:e=>t`/accounts/${e.account_id}/cfd_tunnel/${e.tunnel_id}/configurations`,body:`json`};function S(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(`tunnel-config-ingress`,{type:`string`,description:`List of public hostname definitions. At least one ingress rule needs to be defined for the tunnel. Provide as a JSON array of objects or @path/to/file.json.`}).option(`tunnel-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(`tunnel-config-origin-request-access-required`,{type:`boolean`,description:`Deny traffic that has not fulfilled Access authorization.`}).option(`tunnel-config-origin-request-access-team-name`,{type:`string`,description:`The config.originRequest.access.teamName field`}).option(`tunnel-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(`tunnel-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(`tunnel-config-origin-request-disable-chunked-encoding`,{type:`boolean`,description:`Disables chunked transfer encoding. Useful if you are running a WSGI server.`}).option(`tunnel-config-origin-request-http2origin`,{type:`boolean`,description:`Attempt to connect to origin using HTTP2. Origin must be configured as https.`}).option(`tunnel-config-origin-request-http-host-header`,{type:`string`,description:`Sets the HTTP Host header on requests sent to the local service.`}).option(`tunnel-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(`tunnel-config-origin-request-keep-alive-timeout`,{type:`number`,description:`Timeout after which an idle keepalive connection can be discarded.`}).option(`tunnel-config-origin-request-match-snito-host`,{type:`boolean`,description:`Auto configure the Hostname on the origin server certificate.`}).option(`tunnel-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(`tunnel-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(`tunnel-config-origin-request-origin-server-name`,{type:`string`,description:`Hostname that cloudflared should expect from your origin server certificate.`}).option(`tunnel-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(`tunnel-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(`tunnel-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([`tunnel-config-ingress`,`tunnel-config-origin-request-access-aud-tag`,`tunnel-config-origin-request-access-required`,`tunnel-config-origin-request-access-team-name`,`tunnel-config-origin-request-ca-pool`,`tunnel-config-origin-request-connect-timeout`,`tunnel-config-origin-request-disable-chunked-encoding`,`tunnel-config-origin-request-http2origin`,`tunnel-config-origin-request-http-host-header`,`tunnel-config-origin-request-keep-alive-connections`,`tunnel-config-origin-request-keep-alive-timeout`,`tunnel-config-origin-request-match-snito-host`,`tunnel-config-origin-request-no-happy-eyeballs`,`tunnel-config-origin-request-no-tlsverify`,`tunnel-config-origin-request-origin-server-name`,`tunnel-config-origin-request-proxy-type`,`tunnel-config-origin-request-tcp-keep-alive`,`tunnel-config-origin-request-tls-timeout`].some(t=>e[t]!==void 0)){let t=[`tunnel-config-origin-request-access-aud-tag`,`tunnel-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 C={command:`update <tunnel-id>`,describe:`Update Tunnel configuration`,builder:S,handler:async e=>u({command:`tunnels config update`,classification:{safeFlags:[`tunnel-config-origin-request-access-required`,`tunnel-config-origin-request-disable-chunked-encoding`,`tunnel-config-origin-request-http2origin`,`tunnel-config-origin-request-match-snito-host`,`tunnel-config-origin-request-no-happy-eyeballs`,`tunnel-config-origin-request-no-tlsverify`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=await a();c({command:`cf tunnels config update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<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?p({config:{ingress:d(e[`tunnel-config-ingress`],`tunnel-config-ingress`),originRequest:{access:{audTag:e[`tunnel-config-origin-request-access-aud-tag`],required:e[`tunnel-config-origin-request-access-required`],teamName:m(e[`tunnel-config-origin-request-access-team-name`],`tunnel-config-origin-request-access-team-name`,`text`)},caPool:m(e[`tunnel-config-origin-request-ca-pool`],`tunnel-config-origin-request-ca-pool`,`text`),connectTimeout:e[`tunnel-config-origin-request-connect-timeout`],disableChunkedEncoding:e[`tunnel-config-origin-request-disable-chunked-encoding`],http2Origin:e[`tunnel-config-origin-request-http2origin`],httpHostHeader:m(e[`tunnel-config-origin-request-http-host-header`],`tunnel-config-origin-request-http-host-header`,`text`),keepAliveConnections:e[`tunnel-config-origin-request-keep-alive-connections`],keepAliveTimeout:e[`tunnel-config-origin-request-keep-alive-timeout`],matchSNItoHost:e[`tunnel-config-origin-request-match-snito-host`],noHappyEyeballs:e[`tunnel-config-origin-request-no-happy-eyeballs`],noTLSVerify:e[`tunnel-config-origin-request-no-tlsverify`],originServerName:m(e[`tunnel-config-origin-request-origin-server-name`],`tunnel-config-origin-request-origin-server-name`,`text`),proxyType:m(e[`tunnel-config-origin-request-proxy-type`],`tunnel-config-origin-request-proxy-type`,`text`),tcpKeepAlive:e[`tunnel-config-origin-request-tcp-keep-alive`],tlsTimeout:e[`tunnel-config-origin-request-tls-timeout`]}}}):f(e.body)});return}let t=await i(e),n=e.local?r:await o();if(e.accountId=n,e.body){let r=f(e.body),i=await l(`Updating`,async()=>t.send(x,{body:r,account_id:n,tunnel_id:e[`tunnel-id`]}));s(i,{successLabel:`Updated`});return}let u=p({config:{ingress:d(e[`tunnel-config-ingress`],`tunnel-config-ingress`),originRequest:{access:{audTag:e[`tunnel-config-origin-request-access-aud-tag`],required:e[`tunnel-config-origin-request-access-required`],teamName:m(e[`tunnel-config-origin-request-access-team-name`],`tunnel-config-origin-request-access-team-name`,`text`)},caPool:m(e[`tunnel-config-origin-request-ca-pool`],`tunnel-config-origin-request-ca-pool`,`text`),connectTimeout:e[`tunnel-config-origin-request-connect-timeout`],disableChunkedEncoding:e[`tunnel-config-origin-request-disable-chunked-encoding`],http2Origin:e[`tunnel-config-origin-request-http2origin`],httpHostHeader:m(e[`tunnel-config-origin-request-http-host-header`],`tunnel-config-origin-request-http-host-header`,`text`),keepAliveConnections:e[`tunnel-config-origin-request-keep-alive-connections`],keepAliveTimeout:e[`tunnel-config-origin-request-keep-alive-timeout`],matchSNItoHost:e[`tunnel-config-origin-request-match-snito-host`],noHappyEyeballs:e[`tunnel-config-origin-request-no-happy-eyeballs`],noTLSVerify:e[`tunnel-config-origin-request-no-tlsverify`],originServerName:m(e[`tunnel-config-origin-request-origin-server-name`],`tunnel-config-origin-request-origin-server-name`,`text`),proxyType:m(e[`tunnel-config-origin-request-proxy-type`],`tunnel-config-origin-request-proxy-type`,`text`),tcpKeepAlive:e[`tunnel-config-origin-request-tcp-keep-alive`],tlsTimeout:e[`tunnel-config-origin-request-tls-timeout`]}}}),h=await l(`Updating`,async()=>t.send(x,{body:u,account_id:n,tunnel_id:e[`tunnel-id`]}));s(h,{successLabel:`Updated`})})},w={command:`config`,describe:`Operations for config`,builder:e=>e.command(ee).command(C).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var T={method:`DELETE`,path:e=>t`/accounts/${e.account_id}/cfd_tunnel/${e.tunnel_id}/connections`,query:[`client_id`]};function E(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 D={command:`cleanup <tunnel-id>`,describe:`Clean up Cloudflare Tunnel connections`,builder:E,handler:async e=>u({command:`tunnels connections cleanup`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{let t={client_id:e[`client-id`]};if(e.dryRun){let n=await a();c({command:`cf tunnels connections cleanup`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${n??`<account-id>`}/cfd_tunnel/${e[`tunnel-id`]==null?`<tunnel-id>`:encodeURIComponent(String(e[`tunnel-id`]))}/connections`,pathParams:{"tunnel-id":String(e[`tunnel-id`]??``)},query:t,bodyKind:`none`});return}let n=await i(e),u=e.local?r:await o();if(e.accountId=u,!await g({force:!!e.force,message:`This operation removes Cloudflare Tunnel connections.`})){process.stderr.write(`Aborted.
|
|
10
|
+
`);return}let d=await l(`Deleting`,async()=>n.send(T,{account_id:u,tunnel_id:e[`tunnel-id`],...t}));s(d,{successLabel:`Deleted`})})};var O={method:`GET`,path:e=>t`/accounts/${e.account_id}/cfd_tunnel/${e.tunnel_id}/connections`};function k(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 A={command:`list`,describe:`List Cloudflare Tunnel connections`,builder:k,handler:async e=>u({command:`tunnels connections list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await a();c({command:`cf tunnels connections list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<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 t=await i(e),n=e.local?r:await o();e.accountId=n;let u=await l(`Loading`,async()=>t.send(O,{account_id:n,tunnel_id:e[`tunnel-id`]}));s(u,{successLabel:`Loaded`})})},j={command:`connections`,describe:`Operations for connections`,builder:e=>e.command(D).command(A).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var M={method:`GET`,path:e=>t`/accounts/${e.account_id}/cfd_tunnel/${e.tunnel_id}/connectors/${e.connector_id}`};function N(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 P={command:`get <connector-id>`,describe:`Get Cloudflare Tunnel connector`,builder:N,handler:async e=>u({command:`tunnels connectors get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await a();c({command:`cf tunnels connectors get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<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 t=await i(e),n=e.local?r:await o();e.accountId=n;let u=await l(`Loading`,async()=>t.send(M,{account_id:n,tunnel_id:e[`tunnel-id`],connector_id:e[`connector-id`]}));s(u,{successLabel:`Loaded`})})},F={command:`connectors`,describe:`Operations for connectors`,builder:e=>e.command(P).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var I={method:`POST`,path:e=>t`/accounts/${e.account_id}/cfd_tunnel`,body:`json`};function L(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-source`,{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`]}).coerce(`config-source`,e=>m(e,`config-source`,`text`)).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 R={command:`create`,describe:`Create a Cloudflare Tunnel`,builder:L,handler:async e=>u({command:`tunnels create`,classification:{safeFlags:[`config-source`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=await a();c({command:`cf tunnels create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/cfd_tunnel`,pathParams:{},bodyKind:`json`,body:e.body===void 0?p({config_src:e[`config-source`],name:m(e.name,`name`,`text`),tunnel_secret:m(e[`tunnel-secret`],`tunnel-secret`,`text`)}):f(e.body),sensitiveBodyPaths:[[`tunnel_secret`]]});return}let t=await i(e),n=e.local?r:await o();if(e.accountId=n,e.body){let r=f(e.body),i=await l(`Creating`,async()=>t.send(I,{body:r,account_id:n}));s(i,{successLabel:`Created`});return}e.name===void 0&&(e.name=await h(`name`,`A user-friendly name for a tunnel.`));let u=p({config_src:e[`config-source`],name:m(e.name,`name`,`text`),tunnel_secret:m(e[`tunnel-secret`],`tunnel-secret`,`text`)}),d=await l(`Creating`,async()=>t.send(I,{body:u,account_id:n}));s(d,{successLabel:`Created`})})};var z={method:`DELETE`,path:e=>t`/accounts/${e.account_id}/cfd_tunnel/${e.tunnel_id}`};function B(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 te={command:`delete <tunnel-id>`,describe:`Delete a Cloudflare Tunnel`,builder:B,handler:async e=>u({command:`tunnels delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){let t=await a();c({command:`cf tunnels delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<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 t=await i(e),n=e.local?r:await o();if(e.accountId=n,!await g({force:!!e.force,message:`This operation permanently deletes a Cloudflare Tunnel.`})){process.stderr.write(`Aborted.
|
|
19
|
+
`);return}let u=await l(`Deleting`,async()=>t.send(z,{account_id:n,tunnel_id:e[`tunnel-id`]}));s(u,{successLabel:`Deleted`})})};var V={method:`PATCH`,path:e=>t`/accounts/${e.account_id}/cfd_tunnel/${e.tunnel_id}`,body:`json`};function H(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 U={command:`edit <tunnel-id>`,describe:`Update a Cloudflare Tunnel`,builder:H,handler:async e=>u({command:`tunnels edit`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await a();c({command:`cf tunnels edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<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?p({name:m(e.name,`name`,`text`),tunnel_secret:m(e[`tunnel-secret`],`tunnel-secret`,`text`)}):f(e.body),sensitiveBodyPaths:[[`tunnel_secret`]]});return}let t=await i(e),n=e.local?r:await o();if(e.accountId=n,e.body){let r=f(e.body),i=await l(`Updating`,async()=>t.send(V,{body:r,account_id:n,tunnel_id:e[`tunnel-id`]}));s(i,{successLabel:`Updated`});return}let u=p({name:m(e.name,`name`,`text`),tunnel_secret:m(e[`tunnel-secret`],`tunnel-secret`,`text`)}),d=await l(`Updating`,async()=>t.send(V,{body:u,account_id:n,tunnel_id:e[`tunnel-id`]}));s(d,{successLabel:`Updated`})})};var W={method:`GET`,path:e=>t`/accounts/${e.account_id}/cfd_tunnel/${e.tunnel_id}`};function G(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 K={command:`get <tunnel-id>`,describe:`Get a Cloudflare Tunnel`,builder:G,handler:async e=>u({command:`tunnels get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await a();c({command:`cf tunnels get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<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 t=await i(e),n=e.local?r:await o();e.accountId=n;let u=await l(`Loading`,async()=>t.send(W,{account_id:n,tunnel_id:e[`tunnel-id`]}));s(u,{successLabel:`Loaded`})})};var q={method:`GET`,path:e=>t`/accounts/${e.account_id}/tunnels`,query:[`name`,`is_deleted`,`existed_at`,`uuid`,`was_active_at`,`was_inactive_at`,`include_prefix`,`exclude_prefix`,`tun_types`,`status`,`per_page`,`page`]};function J(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 Y={command:`list`,describe:`List All Tunnels`,builder:J,handler:async e=>u({command:`tunnels list`,classification:{safeFlags:[`is-deleted`,`status`,`dry-run`]}},e,async()=>{let t={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){let e=await a();c({command:`cf tunnels list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/tunnels`,pathParams:{},query:t,bodyKind:`none`});return}let n=await i(e),u=e.local?r:await o();e.accountId=u;let d=await l(`Loading`,async()=>n.send(q,{account_id:u,...t}));s(d,{successLabel:`Loaded`})})};function X(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 Z={command:`create <tunnel-id>`,describe:`Get a Cloudflare Tunnel management token`,builder:X,handler:async e=>u({command:`tunnels management-token create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await a();c({command:`cf tunnels management-token create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<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?p({resources:e.resources}):f(e.body)});return}let t=await i(e),n=e.local?r:await o();if(e.accountId=n,e.body){let r=f(e.body),i=await l(`Creating`,async()=>t.send(_,{body:r,account_id:n,tunnel_id:e[`tunnel-id`]}));s(i,{successLabel:`Created`});return}if(e.resources===void 0)throw Error(`--resources is required (or pass --body with this field set).`);let u=p({resources:e.resources}),d=await l(`Creating`,async()=>t.send(_,{body:u,account_id:n,tunnel_id:e[`tunnel-id`]}));s(d,{successLabel:`Created`})})},Q={command:`management-token`,describe:`Operations for management-token`,builder:e=>e.command(Z).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function ne(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 re={command:`get <tunnel-id>`,describe:`Get a Cloudflare Tunnel token`,builder:ne,handler:async e=>u({command:`tunnels token get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await a();c({command:`cf tunnels token get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<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 t=await i(e),n=e.local?r:await o();e.accountId=n;let u=await l(`Loading`,async()=>t.send(v,{account_id:n,tunnel_id:e[`tunnel-id`]}));s(u,{successLabel:`Loaded`})})},ie={command:`token`,describe:`Operations for token`,builder:e=>e.command(re).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var ae=e(`diag`,`Create a diagnostic report from a local cloudflared instance.`,()=>import(`./command-F0jlqvKr.mjs`),{command:`tunnels diag`,recordArgs:!1}),oe=e(`login`,`Authorize cloudflared and download an origin certificate for locally managed tunnels.`,()=>import(`./command-ChQXv0jP.mjs`),{command:`tunnels login`,recordArgs:!1}),$=e(`quick-start <url>`,`Expose a local URL with a temporary trycloudflare.com tunnel. The tunnel remains active until cf exits.`,()=>import(`./command-D5BUzDX8.mjs`),{command:`tunnels quick-start`,recordArgs:!1}),se=e(`ready`,`Check the /ready endpoint exposed by a local cloudflared instance.`,()=>import(`./command-DlB10kIb.mjs`),{command:`tunnels ready`,recordArgs:!1}),ce=e(`run [tunnel]`,`Run a named Cloudflare Tunnel using the cf-managed cloudflared binary.`,()=>import(`./command-C0nJ2LRd.mjs`),{command:`tunnels run`,recordArgs:!1}),le=e(`tail [tunnel-id]`,`Stream logs from a remote cloudflared instance.`,()=>import(`./command-yAXk5NXh.mjs`),{command:`tunnels tail`,recordArgs:!1});const ue={command:`tunnels`,describe:`tunnels`,builder:e=>e.command(R).command(te).command(n(ae,`preview`)).command(U).command(K).command(Y).command(n(oe,`preview`)).command(n($,`preview`)).command(n(se,`preview`)).command(n(ce,`preview`)).command(n(le,`preview`)).command(w).command(j).command(F).command(Q).command(ie).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{ue as default};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-B4sZZTRA.mjs";import{n}from"./auth-BaUNb1Ed.mjs";import{a as r,t as i}from"./context-BQ6KeMgq.mjs";import{t as a}from"./output-O6b9MR9R.mjs";import{t as o}from"./dry-run-DQmFkNK_.mjs";import{t as s}from"./progress-CdlDthXA.mjs";import{t as c}from"./run-B_07PrkW.mjs";import"./telemetry-Dpm6GfZD.mjs";import{n as l,t as u}from"./body-parser-ChnyBsfm.mjs";import{n as d}from"./input-validation-D7z60HJH.mjs";import{a as f,i as p,n as m}from"./prompt-1AC-qwxS.mjs";var h={method:`POST`,path:t=>e`/accounts/${t.account_id}/challenges/widgets`,query:[`page`,`per_page`,`order`,`direction`,`filter`],body:`json`};function g(e){return e.usage(`$0 turnstile widgets create
|
|
3
3
|
|
|
4
4
|
Creates a Turnstile widget for 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. The `name` field uses case-insensitive\nsubstring matching; `sitekey` uses exact 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
5
|
expensive challenges in response to malicious bots (ENT only).
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{i as e,n as t}from"./source-
|
|
2
|
+
import{i as e,n as t}from"./source-AlTrHNem.mjs";import{n}from"./version-CLgSHoNm.mjs";import{i as r}from"./cf-PISMdEje.mjs";import{r as i,t as a}from"./gt-D6YemCLh.mjs";import{closeSync as o,mkdirSync as s,openSync as c,readFileSync as l,renameSync as u,statSync as d,unlinkSync as f,writeFileSync as p}from"node:fs";import{dirname as m,join as h}from"node:path";import{fileURLToPath as g}from"node:url";import{spawn as _}from"node:child_process";var v=/* @__PURE__ */ t(((e,t)=>{let n=i();t.exports=(e,t)=>new n(e,t).major})),y=/* @__PURE__ */ t(((e,t)=>{let n=i();t.exports=(e,t,r=!1)=>{if(e instanceof n)return e;try{return new n(e,t)}catch(e){if(!r)return null;throw e}}})),b=/* @__PURE__ */ t(((e,t)=>{let n=y();t.exports=(e,t)=>{let r=n(e,t);return r&&r.prerelease.length?r.prerelease:null}})),x=/* @__PURE__ */ t(((e,t)=>{let n=y();t.exports=(e,t)=>{let r=n(e,t);return r?r.version:null}})),S=/* @__PURE__ */ e(a(),1),C=/* @__PURE__ */ e(v(),1),w=/* @__PURE__ */ e(b(),1),T=/* @__PURE__ */ e(x(),1);const E=864e5;function D(e){return(0,w.default)(e)?.includes(`beta`)?`beta`:`latest`}function O(e=n){return h(r(),`cache`,`update-check-${D(e)}.json`)}function k(e=O()){try{let t=JSON.parse(l(e,`utf8`));if(typeof t!=`object`||!t||Array.isArray(t))return{};let n=t;return{lastAttemptedAt:typeof n.lastAttemptedAt==`number`&&Number.isFinite(n.lastAttemptedAt)?n.lastAttemptedAt:void 0,lastSuccessfulAt:typeof n.lastSuccessfulAt==`number`&&Number.isFinite(n.lastSuccessfulAt)?n.lastSuccessfulAt:void 0,latestVersion:typeof n.latestVersion==`string`&&(0,T.default)(n.latestVersion)?n.latestVersion:void 0}}catch{return{}}}function A(e,t=O()){let n=`${t}.${process.pid}.tmp`;try{return s(m(t),{recursive:!0}),p(n,`${JSON.stringify(e)}\n`,{encoding:`utf8`,mode:384}),u(n,t),!0}catch{try{f(n)}catch{}return!1}}function j(e,t,n){let r=`${e}.lock`,i;try{s(m(e),{recursive:!0});try{i=c(r,`wx`,384)}catch{try{if(t-d(r).mtimeMs<=5e3)return;f(r),i=c(r,`wx`,384)}catch{return}}return n()}catch{return}finally{if(i!==void 0)try{o(i),f(r)}catch{}}}function M(e,t){if(!(0,T.default)(e)||!t.latestVersion||!(0,S.default)(t.latestVersion,e))return;let n=(0,C.default)(t.latestVersion)>(0,C.default)(e);return{latestVersion:t.latestVersion,isMajor:n}}function N(e,t=O(e)){return M(e,k(t))}function P(){let e=import.meta.url.endsWith(`.ts`),t=new URL(e?`../update-check-worker.ts`:`./update-check-worker.mjs`,import.meta.url),n=e?[...process.execArgv,g(t)]:[g(t)];_(process.execPath,n,{detached:!0,stdio:`ignore`,windowsHide:!0}).unref()}function F(e={}){let t=e.cachePath??O(e.currentVersion??n),r=e.now??Date.now();if(j(t,r,()=>{let e=k(t);return e.lastAttemptedAt!==void 0&&r-e.lastAttemptedAt<864e5?!1:A({...e,lastAttemptedAt:r},t)}))try{(e.spawnWorker??P)()}catch{}}async function I(e,t,r,i){if(!(0,T.default)(t))return{status:`failed`};let a=await i(`https://registry.npmjs.org/${encodeURIComponent(e)}/${r}`,{headers:{accept:`application/json`,"user-agent":`cf-cli/${n}`},signal:AbortSignal.timeout(3e3)});if(!a.ok)return{status:`failed`};let o=await a.json();if(typeof o!=`object`||!o||Array.isArray(o))return{status:`failed`};let s=o;return s.name!==e||typeof s.version!=`string`||!(0,T.default)(s.version)?{status:`failed`}:(0,S.default)(s.version,t)?{status:`update-available`,latest:s.version}:{status:`up-to-date`}}async function L(e={}){let t=e.currentVersion??n,r=e.cachePath??O(t),i=e.now??Date.now();try{let n=await(e.check??((t,n,r)=>I(t,n,r,e.fetch??globalThis.fetch)))(`cf`,t,`latest`);if(n.status===`failed`)return;let a=n.status===`update-available`?n.latest:t;if(!(0,T.default)(a))return;A({...k(r),latestVersion:a,lastSuccessfulAt:i},r)}catch{}}export{L as i,N as n,F as r,E as t};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{i as e}from"./update-check-
|
|
2
|
+
import{i as e}from"./update-check-atcehhBC.mjs";await e();export{};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-B4sZZTRA.mjs";import{n}from"./auth-BaUNb1Ed.mjs";import{a as r,t as i}from"./context-BQ6KeMgq.mjs";import{t as a}from"./output-O6b9MR9R.mjs";import{t as o}from"./dry-run-DQmFkNK_.mjs";import{t as s}from"./progress-CdlDthXA.mjs";import{t as c}from"./run-B_07PrkW.mjs";import"./telemetry-Dpm6GfZD.mjs";var l={method:`GET`,path:t=>e`/accounts/${t.account_id}/brand-protection/url-info`};function u(e){return e.usage(`$0 url-info get
|
|
3
3
|
|
|
4
4
|
Return submitted URLs based on ID`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const d={command:`get`,describe:`Read submitted URLs by ID`,builder:u,handler:async e=>c({command:`url-info get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let e=await r();o({command:`cf url-info get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/brand-protection/url-info`,pathParams:{},bodyKind:`none`});return}let c=await n(e),u=e.local?t:await i();e.accountId=u;let d=await s(`Loading`,async()=>c.send(l,{account_id:u}));a(d,{successLabel:`Loaded`})})},f={command:`url-info`,describe:`url-info`,builder:e=>e.command(d).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{f as default};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-BaUNb1Ed.mjs";import{i as n}from"./context-BQ6KeMgq.mjs";import{t as r}from"./output-O6b9MR9R.mjs";import{t as i}from"./dry-run-DQmFkNK_.mjs";import{t as a}from"./progress-CdlDthXA.mjs";import{t as o}from"./run-B_07PrkW.mjs";import"./telemetry-Dpm6GfZD.mjs";import{n as s,t as c}from"./body-parser-ChnyBsfm.mjs";import{n as l}from"./input-validation-D7z60HJH.mjs";import{i as u,n as d}from"./prompt-1AC-qwxS.mjs";var f={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/url_normalization`,response:!1};function p(e){return e.usage(`$0 url-normalization delete
|
|
3
3
|
|
|
4
4
|
Deletes the URL Normalization settings.`).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 m={command:`delete`,describe:`Delete URL Normalization settings`,builder:p,handler:async e=>o({command:`url-normalization delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){i({command:`cf url-normalization delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/url_normalization`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let o=await t(e),s=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=s,!await d({force:!!e.force})){process.stderr.write(`Aborted.
|
|
5
5
|
`);return}let c=await a(`Deleting`,async()=>o.send(f,{zone_id:s}));r(c,{successLabel:`Deleted`})})};var h={method:`GET`,path:t=>e`/zones/${t.zone_id}/url_normalization`};function g(e){return e.usage(`$0 url-normalization get
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-B4sZZTRA.mjs";import{n}from"./auth-BaUNb1Ed.mjs";import{a as r,t as i}from"./context-BQ6KeMgq.mjs";import{t as a}from"./output-O6b9MR9R.mjs";import{t as o}from"./dry-run-DQmFkNK_.mjs";import{t as s}from"./progress-CdlDthXA.mjs";import{t as c}from"./run-B_07PrkW.mjs";import"./telemetry-Dpm6GfZD.mjs";import{n as l,r as u,t as d}from"./body-parser-ChnyBsfm.mjs";import{n as f}from"./input-validation-D7z60HJH.mjs";import{a as p}from"./prompt-1AC-qwxS.mjs";import{n as m,t as h}from"./raw-fetch-1VlXDwwX.mjs";function g(e){return e.usage("$0 url-scanner responses get <response-id>\n\nReturns the raw response of the network request. Find the `response_id` in the `data.requests.response.hash`.").positional(`response-id`,{type:`string`,description:`Response hash.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const _={command:`get <response-id>`,describe:`Get raw response`,builder:g,handler:async e=>c({command:`url-scanner responses get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await r();o({command:`cf url-scanner responses get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/urlscanner/v2/responses/${e[`response-id`]==null?`<response-id>`:encodeURIComponent(String(e[`response-id`]))}`,pathParams:{"response-id":String(e[`response-id`]??``)},bodyKind:`none`});return}await n(e);let a=e.local?t:await i();e.accountId=a;let c=await s(`Loading`,async()=>h(`/accounts/${a}/urlscanner/v2/responses/${encodeURIComponent(String(e[`response-id`]))}`,{method:`GET`,local:e.local===!0,persistTo:e.persistTo}));m(c.toString(`utf-8`))})},v={command:`responses`,describe:`Raw HTTP response data captured during URL scans`,builder:e=>e.command(_).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var y={method:`POST`,path:t=>e`/accounts/${t.account_id}/urlscanner/v2/bulk`,body:`json`,errors:{400:`BadRequestError`,429:`TooManyRequestsError`}};function b(e){return e.usage(`$0 url-scanner scans bulk-create
|
|
3
3
|
|
|
4
|
-
Submit URLs to scan. Check limits at https://developers.cloudflare.com/security-center/investigate/scan-limits/ and take into account scans submitted in bulk have lower priority and may take longer to finish.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`List of urls to scan (up to a 100).`})}const x={command:`bulk-create`,describe:`Bulk create URL Scans`,builder:b,handler:async e=>c({command:`url-scanner scans bulk-create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await r();o({command:`cf url-scanner scans bulk-create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/urlscanner/v2/bulk`,pathParams:{},bodyKind:`json`,body:e.body===void 0?void 0:l(e.body)});return}let c=await n(e),u=e.local?t:await i();if(e.accountId=u,e.body){let t=l(e.body),n=await s(`Creating`,async()=>c.send(y,{body:t,account_id:u}));a(n,{successLabel:`Created`})
|
|
4
|
+
Submit URLs to scan. Check limits at https://developers.cloudflare.com/security-center/investigate/scan-limits/ and take into account scans submitted in bulk have lower priority and may take longer to finish.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`List of urls to scan (up to a 100).`})}const x={command:`bulk-create`,describe:`Bulk create URL Scans`,builder:b,handler:async e=>c({command:`url-scanner scans bulk-create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await r();o({command:`cf url-scanner scans bulk-create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/urlscanner/v2/bulk`,pathParams:{},bodyKind:`json`,body:e.body===void 0?void 0:l(e.body)});return}let c=await n(e),u=e.local?t:await i();if(e.accountId=u,e.body){let t=l(e.body),n=await s(`Creating`,async()=>c.send(y,{body:t,account_id:u}));a(n,{successLabel:`Created`})}else if(e.body===void 0)throw Error(`--body is required for this command. Pass --body '<json>' or --body @path/to/file.json.`)})};var S={method:`POST`,path:t=>e`/accounts/${t.account_id}/urlscanner/v2/scan`,body:`json`,errors:{400:`BadRequestError`,409:`ConflictError`,429:`TooManyRequestsError`}};function C(e){return e.usage(`$0 url-scanner scans create
|
|
5
5
|
|
|
6
6
|
Submit a URL to scan. Check limits at https://developers.cloudflare.com/security-center/investigate/scan-limits/.`).option(`agent-readiness`,{type:`boolean`,description:`Enable agent readiness checks.`}).option(`country`,{type:`string`,description:`Country to geo egress from`,choices:/* @__PURE__ */ `AF.AL.DZ.AD.AO.AG.AR.AM.AU.AT.AZ.BH.BD.BB.BY.BE.BZ.BJ.BM.BT.BO.BA.BW.BR.BN.BG.BF.BI.KH.CM.CA.CV.KY.CF.TD.CL.CN.CO.KM.CG.CR.CI.HR.CU.CY.CZ.CD.DK.DJ.DM.DO.EC.EG.SV.GQ.ER.EE.SZ.ET.FJ.FI.FR.GA.GE.DE.GH.GR.GL.GD.GT.GN.GW.GY.HT.HN.HU.IS.IN.ID.IR.IQ.IE.IL.IT.JM.JP.JO.KZ.KE.KI.KW.KG.LA.LV.LB.LS.LR.LY.LI.LT.LU.MO.MG.MW.MY.MV.ML.MR.MU.MX.FM.MD.MC.MN.MS.MA.MZ.MM.NA.NR.NP.NL.NZ.NI.NE.NG.KP.MK.NO.OM.PK.PS.PA.PG.PY.PE.PH.PL.PT.QA.RO.RU.RW.SH.KN.LC.VC.WS.SM.ST.SA.SN.RS.SC.SL.SK.SI.SB.SO.ZA.KR.SS.ES.LK.SD.SR.SE.CH.SY.TW.TJ.TZ.TH.BS.GM.TL.TG.TO.TT.TN.TR.TM.UG.UA.AE.GB.US.UY.UZ.VU.VE.VN.YE.ZM.ZW`.split(`.`)}).coerce(`country`,e=>f(e,`country`,`text`)).option(`custom-headers`,{type:`string`,description:`Set custom headers. Provide as a JSON object or @path/to/file.json.`}).option(`customagent`,{type:`string`,description:`The customagent field`}).option(`referer`,{type:`string`,description:`The referer field`}).option(`screenshots-resolutions`,{type:`string`,array:!0,description:`Take multiple screenshots targeting different device types.`}).option(`url`,{type:`string`,description:`The url field`}).option(`visibility`,{type:`string`,description:"The option `Public` means it will be included in listings like recent scans and search results. `Unlisted` means it will not be included in the aforementioned listings, users will need to have the scan's ID to access it. A a scan will be automatically marked as unlisted if it fails, if it contains potential PII or other sensitive material.",choices:[`Public`,`Unlisted`],default:`Public`}).coerce(`visibility`,e=>f(e,`visibility`,`text`)).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 w={command:`create`,describe:`Create URL Scan`,builder:C,handler:async e=>c({command:`url-scanner scans create`,classification:{safeFlags:[`agent-readiness`,`country`,`visibility`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=await r();o({command:`cf url-scanner scans create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/urlscanner/v2/scan`,pathParams:{},bodyKind:`json`,body:e.body===void 0?d({agentReadiness:e[`agent-readiness`],country:e.country,customHeaders:u(e[`custom-headers`],`custom-headers`),customagent:f(e.customagent,`customagent`,`text`),referer:f(e.referer,`referer`,`text`),screenshotsResolutions:e[`screenshots-resolutions`],url:f(e.url,`url`,`text`),visibility:e.visibility},[[`customHeaders`]]):l(e.body)});return}let c=await n(e),m=e.local?t:await i();if(e.accountId=m,e.body){let t=l(e.body),n=await s(`Creating`,async()=>c.send(S,{body:t,account_id:m}));a(n,{successLabel:`Created`});return}e.url===void 0&&(e.url=await p(`url`,`The url field`));let h=d({agentReadiness:e[`agent-readiness`],country:e.country,customHeaders:u(e[`custom-headers`],`custom-headers`),customagent:f(e.customagent,`customagent`,`text`),referer:f(e.referer,`referer`,`text`),screenshotsResolutions:e[`screenshots-resolutions`],url:f(e.url,`url`,`text`),visibility:e.visibility},[[`customHeaders`]]),g=await s(`Creating`,async()=>c.send(S,{body:h,account_id:m}));a(g,{successLabel:`Created`})})};function T(e){return e.usage(`$0 url-scanner scans dom <scan-id>
|
|
7
7
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./get-CRKvqCu6.mjs";import{n,o as r}from"./auth-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./get-CRKvqCu6.mjs";import{n,o as r}from"./auth-BaUNb1Ed.mjs";import{t as i}from"./output-O6b9MR9R.mjs";import{t as a}from"./dry-run-DQmFkNK_.mjs";import{t as o}from"./progress-CdlDthXA.mjs";import{t as s}from"./run-B_07PrkW.mjs";import"./telemetry-Dpm6GfZD.mjs";import{a as c,n as l,r as u,t as d}from"./body-parser-ChnyBsfm.mjs";import{n as f}from"./input-validation-D7z60HJH.mjs";import{a as p,i as m,n as h}from"./prompt-1AC-qwxS.mjs";var ee={method:`GET`,path:()=>`/user/audit_logs`,query:[`id`,`export`,`action.type`,`actor.ip`,`actor.email`,`since`,`before`,`zone.name`,`direction`,`per_page`,`page`,`hide_user_logs`]};function te(e){return e.usage(`$0 user audit-logs list
|
|
3
3
|
|
|
4
4
|
Gets a list of audit logs for a user account. Can be filtered by who made the change, on which zone, and the timeframe of the change.`).option(`id`,{type:`string`,description:`Finds a specific log by its ID.`}).option(`export`,{type:`boolean`,description:`Indicates that this request is an export of logs in CSV format.`}).option(`action-type`,{type:`string`,description:`Filters by the action type.`}).option(`actor-ip`,{type:`string`,description:`Filters by the IP address of the request that made the change by specific IP address or valid CIDR Range.`}).option(`actor-email`,{type:`string`,description:`Filters by the email address of the actor that made the change.`}).option(`since`,{type:`string`,description:`Since`}).option(`before`,{type:`string`,description:`Before`}).option(`zone-name`,{type:`string`,description:`Filters by the name of the zone associated to the change.`}).option(`direction`,{type:`string`,description:`Changes the direction of the chronological sorting.`,choices:[`desc`,`asc`]}).option(`per-page`,{type:`number`,description:`Sets the number of results to return per page.`}).option(`page`,{type:`number`,description:`Defines which page of results to return.`}).option(`hide-user-logs`,{type:`boolean`,description:`Indicates whether or not to hide user level audit logs.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const g={command:`list`,describe:`Get user audit logs`,builder:te,handler:async e=>s({command:`user audit-logs list`,classification:{safeFlags:[`export`,`direction`,`hide-user-logs`,`dry-run`]}},e,async()=>{let t={id:e.id,export:e.export,"action.type":e[`action-type`],"actor.ip":e[`actor-ip`],"actor.email":e[`actor-email`],since:e.since,before:e.before,"zone.name":e[`zone-name`],direction:e.direction,per_page:e[`per-page`],page:e.page,hide_user_logs:e[`hide-user-logs`]};if(e.dryRun){a({command:`cf user audit-logs list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/user/audit_logs`,pathParams:{},query:t,bodyKind:`none`});return}let r=await n(e),s=await o(`Loading`,async()=>r.send(ee,t));i(s,{successLabel:`Loaded`})})},ne={command:`audit-logs`,describe:`Operations for audit-logs`,builder:e=>e.command(g).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var re={method:`GET`,path:()=>`/user/billing/history`,query:[`page`,`per_page`,`order`,`occurred_at`,`type`,`action`]};function ie(e){return e.usage(`$0 user billing history list
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-B4sZZTRA.mjs";import{i as n,n as r}from"./auth-BaUNb1Ed.mjs";import{a as i,t as a}from"./context-BQ6KeMgq.mjs";import{t as o}from"./output-O6b9MR9R.mjs";import{t as s}from"./dry-run-DQmFkNK_.mjs";import{t as c}from"./progress-CdlDthXA.mjs";import{t as l}from"./run-B_07PrkW.mjs";import"./telemetry-Dpm6GfZD.mjs";import{n as u,r as d,t as f}from"./body-parser-ChnyBsfm.mjs";import{n as p,t as m}from"./input-validation-D7z60HJH.mjs";import{a as h,i as g,n as _}from"./prompt-1AC-qwxS.mjs";var v={method:`POST`,path:t=>e`/accounts/${t.account_id}/vectorize/v2/indexes`,body:`json`};function y(e){return e.usage(`$0 vectorize create
|
|
3
3
|
|
|
4
4
|
Creates and returns a new Vectorize Index.`).option(`index-config-dimensions`,{type:`number`,description:`Specifies the number of dimensions for the index`}).option(`index-config-metric`,{type:`string`,description:`Specifies the type of metric to use calculating distance.`,choices:[`cosine`,`euclidean`,`dot-product`]}).coerce(`index-config-metric`,e=>p(e,`index-config-metric`,`text`)).option(`index-config-preset`,{type:`string`,description:`Specifies the preset to use for the index.`,choices:[`@cf/baai/bge-small-en-v1.5`,`@cf/baai/bge-base-en-v1.5`,`@cf/baai/bge-large-en-v1.5`,`openai/text-embedding-ada-002`,`cohere/embed-multilingual-v2.0`]}).coerce(`index-config-preset`,e=>p(e,`index-config-preset`,`text`)).option(`description`,{type:`string`,description:`Specifies the description of the index.`}).option(`name`,{type:`string`,description:`The name 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)`}).conflicts(`index-config-dimensions`,[`index-config-preset`]).implies(`index-config-dimensions`,[`index-config-metric`]).conflicts(`index-config-metric`,[`index-config-preset`]).implies(`index-config-metric`,[`index-config-dimensions`]).conflicts(`index-config-preset`,[`index-config-dimensions`,`index-config-metric`])}const b={command:`create`,describe:`Create Vectorize Index`,builder:y,handler:async e=>l({command:`vectorize create`,classification:{safeFlags:[`index-config-metric`,`index-config-preset`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();s({command:`cf vectorize create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/vectorize/v2/indexes`,pathParams:{},bodyKind:`json`,body:e.body===void 0?f({config:{dimensions:e[`index-config-dimensions`],metric:e[`index-config-metric`],preset:e[`index-config-preset`]},description:p(e.description,`description`,`text`),name:p(e.name,`name`,`text`)}):u(e.body)});return}let n=await r(e),l=e.local?t:await a();if(e.accountId=l,e.body){let t=u(e.body),r=await c(`Creating`,async()=>n.send(v,{body:t,account_id:l}));o(r,{successLabel:`Created`});return}e.name===void 0&&(e.name=await h(`name`,`The name field`));let d=f({config:{dimensions:e[`index-config-dimensions`],metric:e[`index-config-metric`],preset:e[`index-config-preset`]},description:p(e.description,`description`,`text`),name:p(e.name,`name`,`text`)}),m=await c(`Creating`,async()=>n.send(v,{body:d,account_id:l}));o(m,{successLabel:`Created`})})};var x={method:`POST`,path:t=>e`/accounts/${t.account_id}/vectorize/v2/indexes/${t.index_name}/delete_by_ids`,body:`json`};function S(e){return e.usage(`$0 vectorize delete-by-ids <index-name>
|
|
5
5
|
|
|
@@ -14,7 +14,7 @@ Returns the specified Vectorize Index.`).positional(`index-name`,{type:`string`,
|
|
|
14
14
|
|
|
15
15
|
Get information about a vectorize index.`).positional(`index-name`,{type:`string`,description:`Index name`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const F={command:`info <index-name>`,describe:`Get Vectorize Index Info`,builder:P,handler:async e=>l({command:`vectorize info`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();s({command:`cf vectorize info`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/vectorize/v2/indexes/${e[`index-name`]==null?`<index-name>`:encodeURIComponent(String(e[`index-name`]))}/info`,pathParams:{"index-name":String(e[`index-name`]??``)},bodyKind:`none`});return}let n=await r(e),l=e.local?t:await a();e.accountId=l;let u=await c(`Loading`,async()=>n.send(N,{account_id:l,index_name:e[`index-name`]}));o(u,{successLabel:`Loaded`})})};function I(e){return e.usage(`$0 vectorize insert <index-name>
|
|
16
16
|
|
|
17
|
-
Inserts vectors into the specified index and returns a mutation id corresponding to the vectors enqueued for insertion.`).positional(`index-name`,{type:`string`,description:`Index name`,demandOption:!0}).option(`unparsable-behavior`,{type:`string`,description:`Behavior for ndjson parse failures.`,choices:[`error`,`discard`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`}).option(`file`,{type:`string`,description:`Path to a file to upload as the request body`})}const L={command:`insert <index-name>`,describe:`Insert Vectors`,builder:I,handler:async e=>l({command:`vectorize insert`,classification:{safeFlags:[`unparsable-behavior`,`dry-run`]}},e,async()=>{let l={"unparsable-behavior":e[`unparsable-behavior`]};if(e.dryRun){let t=await i();s({command:`cf vectorize insert`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/vectorize/v2/indexes/${e[`index-name`]==null?`<index-name>`:encodeURIComponent(String(e[`index-name`]))}/insert`,pathParams:{"index-name":String(e[`index-name`]??``)},query:l,bodyKind:`octet-stream`,body:e.body});return}let u=await r(e),d=e.local?t:await a();if(e.accountId=d,e.file){let t=m(e.file),r=await c(`Creating`,async()=>n(u,`POST`,`/accounts/${d}/vectorize/v2/indexes/${encodeURIComponent(String(e[`index-name`]))}/insert`,{body:t,headers:{"Content-Type":`application/x-ndjson`}}));o(r,{successLabel:`Created`})
|
|
17
|
+
Inserts vectors into the specified index and returns a mutation id corresponding to the vectors enqueued for insertion.`).positional(`index-name`,{type:`string`,description:`Index name`,demandOption:!0}).option(`unparsable-behavior`,{type:`string`,description:`Behavior for ndjson parse failures.`,choices:[`error`,`discard`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`}).option(`file`,{type:`string`,description:`Path to a file to upload as the request body`})}const L={command:`insert <index-name>`,describe:`Insert Vectors`,builder:I,handler:async e=>l({command:`vectorize insert`,classification:{safeFlags:[`unparsable-behavior`,`dry-run`]}},e,async()=>{let l={"unparsable-behavior":e[`unparsable-behavior`]};if(e.dryRun){let t=await i();s({command:`cf vectorize insert`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/vectorize/v2/indexes/${e[`index-name`]==null?`<index-name>`:encodeURIComponent(String(e[`index-name`]))}/insert`,pathParams:{"index-name":String(e[`index-name`]??``)},query:l,bodyKind:`octet-stream`,body:e.body});return}let u=await r(e),d=e.local?t:await a();if(e.accountId=d,e.file){let t=m(e.file),r=await c(`Creating`,async()=>n(u,`POST`,`/accounts/${d}/vectorize/v2/indexes/${encodeURIComponent(String(e[`index-name`]))}/insert`,{body:t,headers:{"Content-Type":`application/x-ndjson`}}));o(r,{successLabel:`Created`})}else if(e.body){let t=p(e.body,`body`,`binary`),r=new URLSearchParams(Object.entries(l).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),i=await c(`Creating`,async()=>n(u,`POST`,`/accounts/${d}/vectorize/v2/indexes/${encodeURIComponent(String(e[`index-name`]))}/insert${r?`?`+r:``}`,{body:t,headers:{"Content-Type":`application/x-ndjson`}}));o(i,{successLabel:`Created`})}else if(e.body===void 0)throw Error(`--body is required for this command. Pass --body '<json>' or --body @path/to/file.json.`)})};var R={method:`GET`,path:t=>e`/accounts/${t.account_id}/vectorize/v2/indexes/${t.index_name}/list`,query:[`count`,`cursor`]};function z(e){return e.usage(`$0 vectorize list-vectors <index-name>
|
|
18
18
|
|
|
19
19
|
Returns a paginated list of vector identifiers from the specified index.`).positional(`index-name`,{type:`string`,description:`Index name`,demandOption:!0}).option(`count`,{type:`number`,description:`Maximum number of vectors to return`}).option(`cursor`,{type:`string`,description:`Cursor for pagination to get the next page of results`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const ee={command:`list-vectors <index-name>`,describe:`List Vectors`,builder:z,handler:async e=>l({command:`vectorize list-vectors`,classification:{safeFlags:[`dry-run`]}},e,async()=>{let n={count:e.count,cursor:e.cursor};if(e.dryRun){let t=await i();s({command:`cf vectorize list-vectors`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/vectorize/v2/indexes/${e[`index-name`]==null?`<index-name>`:encodeURIComponent(String(e[`index-name`]))}/list`,pathParams:{"index-name":String(e[`index-name`]??``)},query:n,bodyKind:`none`});return}let l=await r(e),u=e.local?t:await a();e.accountId=u;let d=await c(`Loading`,async()=>l.send(R,{account_id:u,index_name:e[`index-name`],...n}));o(d,{successLabel:`Loaded`})})};var B={method:`GET`,path:t=>e`/accounts/${t.account_id}/vectorize/v2/indexes`};function V(e){return e.usage(`$0 vectorize list
|
|
20
20
|
|
|
@@ -29,4 +29,4 @@ List Metadata Indexes for the specified Vectorize Index.`).option(`index-name`,{
|
|
|
29
29
|
|
|
30
30
|
Finds vectors closest to a given vector in an index.`).positional(`index-name`,{type:`string`,description:`Index name`,demandOption:!0}).option(`filter`,{type:`string`,description:`A metadata filter expression used to limit nearest neighbor results. Provide as a JSON object or @path/to/file.json.`}).option(`return-metadata`,{type:`string`,description:`Whether to return no metadata, indexed metadata or all metadata associated with the closest vectors.`,choices:[`none`,`indexed`,`all`],default:`none`}).coerce(`return-metadata`,e=>p(e,`return-metadata`,`text`)).option(`return-values`,{type:`boolean`,description:`Whether to return the values associated with the closest vectors.`,default:!1}).option(`top-k`,{type:`number`,description:`The number of nearest neighbors to find.`,default:5}).option(`vector`,{type:`string`,array:!0,description:`The search vector that will be used to find the nearest neighbors.`}).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 ne={command:`query <index-name>`,describe:`Query Vectors`,builder:te,handler:async e=>l({command:`vectorize query`,classification:{safeFlags:[`return-metadata`,`return-values`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();s({command:`cf vectorize query`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/vectorize/v2/indexes/${e[`index-name`]==null?`<index-name>`:encodeURIComponent(String(e[`index-name`]))}/query`,pathParams:{"index-name":String(e[`index-name`]??``)},bodyKind:`json`,body:e.body===void 0?f({filter:d(e.filter,`filter`),returnMetadata:e[`return-metadata`],returnValues:e[`return-values`],topK:e[`top-k`],vector:e.vector},[[`filter`]]):u(e.body)});return}let n=await r(e),l=e.local?t:await a();if(e.accountId=l,e.body){let t=u(e.body),r=await c(`Loading`,async()=>n.send($,{body:t,account_id:l,index_name:e[`index-name`]}));o(r,{successLabel:`Loaded`});return}if(e.vector===void 0)throw Error(`--vector is required (or pass --body with this field set).`);let p=f({filter:d(e.filter,`filter`),returnMetadata:e[`return-metadata`],returnValues:e[`return-values`],topK:e[`top-k`],vector:e.vector},[[`filter`]]),m=await c(`Loading`,async()=>n.send($,{body:p,account_id:l,index_name:e[`index-name`]}));o(m,{successLabel:`Loaded`})})};function re(e){return e.usage(`$0 vectorize upsert <index-name>
|
|
31
31
|
|
|
32
|
-
Upserts vectors into the specified index, creating them if they do not exist and returns a mutation id corresponding to the vectors enqueued for upsertion.`).positional(`index-name`,{type:`string`,description:`Index name`,demandOption:!0}).option(`unparsable-behavior`,{type:`string`,description:`Behavior for ndjson parse failures.`,choices:[`error`,`discard`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`}).option(`file`,{type:`string`,description:`Path to a file to upload as the request body`})}const ie={command:`upsert <index-name>`,describe:`Upsert Vectors`,builder:re,handler:async e=>l({command:`vectorize upsert`,classification:{safeFlags:[`unparsable-behavior`,`dry-run`]}},e,async()=>{let l={"unparsable-behavior":e[`unparsable-behavior`]};if(e.dryRun){let t=await i();s({command:`cf vectorize upsert`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/vectorize/v2/indexes/${e[`index-name`]==null?`<index-name>`:encodeURIComponent(String(e[`index-name`]))}/upsert`,pathParams:{"index-name":String(e[`index-name`]??``)},query:l,bodyKind:`octet-stream`,body:e.body});return}let u=await r(e),d=e.local?t:await a();if(e.accountId=d,e.file){let t=m(e.file),r=await c(`Creating`,async()=>n(u,`POST`,`/accounts/${d}/vectorize/v2/indexes/${encodeURIComponent(String(e[`index-name`]))}/upsert`,{body:t,headers:{"Content-Type":`application/x-ndjson`}}));o(r,{successLabel:`Created`})
|
|
32
|
+
Upserts vectors into the specified index, creating them if they do not exist and returns a mutation id corresponding to the vectors enqueued for upsertion.`).positional(`index-name`,{type:`string`,description:`Index name`,demandOption:!0}).option(`unparsable-behavior`,{type:`string`,description:`Behavior for ndjson parse failures.`,choices:[`error`,`discard`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`}).option(`file`,{type:`string`,description:`Path to a file to upload as the request body`})}const ie={command:`upsert <index-name>`,describe:`Upsert Vectors`,builder:re,handler:async e=>l({command:`vectorize upsert`,classification:{safeFlags:[`unparsable-behavior`,`dry-run`]}},e,async()=>{let l={"unparsable-behavior":e[`unparsable-behavior`]};if(e.dryRun){let t=await i();s({command:`cf vectorize upsert`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/vectorize/v2/indexes/${e[`index-name`]==null?`<index-name>`:encodeURIComponent(String(e[`index-name`]))}/upsert`,pathParams:{"index-name":String(e[`index-name`]??``)},query:l,bodyKind:`octet-stream`,body:e.body});return}let u=await r(e),d=e.local?t:await a();if(e.accountId=d,e.file){let t=m(e.file),r=await c(`Creating`,async()=>n(u,`POST`,`/accounts/${d}/vectorize/v2/indexes/${encodeURIComponent(String(e[`index-name`]))}/upsert`,{body:t,headers:{"Content-Type":`application/x-ndjson`}}));o(r,{successLabel:`Created`})}else if(e.body){let t=p(e.body,`body`,`binary`),r=new URLSearchParams(Object.entries(l).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),i=await c(`Creating`,async()=>n(u,`POST`,`/accounts/${d}/vectorize/v2/indexes/${encodeURIComponent(String(e[`index-name`]))}/upsert${r?`?`+r:``}`,{body:t,headers:{"Content-Type":`application/x-ndjson`}}));o(i,{successLabel:`Created`})}else if(e.body===void 0)throw Error(`--body is required for this command. Pass --body '<json>' or --body @path/to/file.json.`)})},ae={command:`vectorize`,describe:`Globally distributed vector database for building semantic search, recommendations, and RAG applications on Workers`,builder:e=>e.command(b).command(E).command(C).command(M).command(k).command(F).command(L).command(H).command(ee).command(ne).command(ie).command(Q).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{ae as default};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-B4sZZTRA.mjs";import{n}from"./auth-BaUNb1Ed.mjs";import{a as r,i,t as a}from"./context-BQ6KeMgq.mjs";import{t as o}from"./output-O6b9MR9R.mjs";import{t as s}from"./dry-run-DQmFkNK_.mjs";import{t as c}from"./progress-CdlDthXA.mjs";import{t as l}from"./run-B_07PrkW.mjs";import"./telemetry-Dpm6GfZD.mjs";import{a as u,n as d,t as f}from"./body-parser-ChnyBsfm.mjs";import{n as p}from"./input-validation-D7z60HJH.mjs";import{a as m,i as h,n as g}from"./prompt-1AC-qwxS.mjs";var _={method:`GET`,path:t=>e`/${t.account_or_zone}/${t.account_or_zone_id}/waiting_rooms`,query:[`page`,`per_page`]};function ee(e){return e.usage(`$0 waiting-rooms account-waiting-rooms list
|
|
3
3
|
|
|
4
4
|
Lists waiting rooms for account or zone.`).option(`page`,{type:`number`,description:`Page number of paginated results.`}).option(`per-page`,{type:`number`,description:`Maximum number of results per page. Must be a multiple of 5.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const v={command:`list`,describe:`List waiting rooms for account or zone`,builder:ee,handler:async e=>l({command:`waiting-rooms account-waiting-rooms list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{let l={page:e.page,per_page:e[`per-page`]};if(e.dryRun){let t=e.zone===void 0?await r():void 0,n=e.zone===void 0?`accounts`:`zones`,i=e.zone??t??`<account-id>`;s({command:`cf waiting-rooms account-waiting-rooms list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/${n}/${i}/waiting_rooms`,pathParams:{"account-or-zone":String(n),"account-or-zone-id":String(i)},query:l,bodyKind:`none`});return}let u=await n(e),d=e.zone===void 0?`accounts`:`zones`,f=d===`zones`?await i({zone:e.zone},u,{quiet:e.quiet}):e.local?t:await a();d===`zones`?e.zoneId=f:e.accountId=f;let p=await c(`Loading`,async()=>u.send(_,{account_or_zone:d,account_or_zone_id:f,...l}));o(p,{successLabel:`Loaded`})})},y={command:`account-waiting-rooms`,describe:`Account-scoped waiting room listing`,builder:e=>e.command(v).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var b={method:`POST`,path:t=>e`/zones/${t.zone_id}/waiting_rooms`,body:`json`};function te(e){return e.usage(`$0 waiting-rooms create
|
|
5
5
|
|
|
@@ -36,7 +36,7 @@ Patches a rule for a waiting room.`).positional(`rule-id`,{type:`string`,descrip
|
|
|
36
36
|
|
|
37
37
|
Lists rules for a waiting room.`).positional(`waiting-room-id`,{type:`string`,description:`Waiting room ID`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const xe={command:`get <waiting-room-id>`,describe:`List Waiting Room Rules`,builder:be,handler:async e=>l({command:`waiting-rooms rules get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){s({command:`cf waiting-rooms rules get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/waiting_rooms/${e[`waiting-room-id`]==null?`<waiting-room-id>`:encodeURIComponent(String(e[`waiting-room-id`]))}/rules`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``),"waiting-room-id":String(e[`waiting-room-id`]??``)},bodyKind:`none`});return}let t=await n(e),r=await i({zone:e.zone},t,{quiet:e.quiet});e.zoneId=r;let a=await c(`Loading`,async()=>t.send(ye,{zone_id:r,waiting_room_id:e[`waiting-room-id`]}));o(a,{successLabel:`Loaded`})})};var Se={method:`PUT`,path:t=>e`/zones/${t.zone_id}/waiting_rooms/${t.waiting_room_id}/rules`,body:`json`};function Ce(e){return e.usage(`$0 waiting-rooms rules update <waiting-room-id>
|
|
38
38
|
|
|
39
|
-
Only available for the Waiting Room Advanced subscription. Replaces all rules for a waiting room.`).positional(`waiting-room-id`,{type:`string`,description:`Waiting room ID`,demandOption:!0}).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 we={command:`update <waiting-room-id>`,describe:`Replace Waiting Room Rules`,builder:Ce,handler:async e=>l({command:`waiting-rooms rules update`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){s({command:`cf waiting-rooms rules update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/waiting_rooms/${e[`waiting-room-id`]==null?`<waiting-room-id>`:encodeURIComponent(String(e[`waiting-room-id`]))}/rules`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``),"waiting-room-id":String(e[`waiting-room-id`]??``)},bodyKind:`json`,body:e.body===void 0?void 0:d(e.body)});return}let t=await n(e),r=await i({zone:e.zone},t,{quiet:e.quiet});if(e.zoneId=r,e.body){let n=d(e.body),i=await c(`Updating`,async()=>t.send(Se,{body:n,zone_id:r,waiting_room_id:e[`waiting-room-id`]}));o(i,{successLabel:`Updated`})
|
|
39
|
+
Only available for the Waiting Room Advanced subscription. Replaces all rules for a waiting room.`).positional(`waiting-room-id`,{type:`string`,description:`Waiting room ID`,demandOption:!0}).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 we={command:`update <waiting-room-id>`,describe:`Replace Waiting Room Rules`,builder:Ce,handler:async e=>l({command:`waiting-rooms rules update`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){s({command:`cf waiting-rooms rules update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/waiting_rooms/${e[`waiting-room-id`]==null?`<waiting-room-id>`:encodeURIComponent(String(e[`waiting-room-id`]))}/rules`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``),"waiting-room-id":String(e[`waiting-room-id`]??``)},bodyKind:`json`,body:e.body===void 0?void 0:d(e.body)});return}let t=await n(e),r=await i({zone:e.zone},t,{quiet:e.quiet});if(e.zoneId=r,e.body){let n=d(e.body),i=await c(`Updating`,async()=>t.send(Se,{body:n,zone_id:r,waiting_room_id:e[`waiting-room-id`]}));o(i,{successLabel:`Updated`})}else if(e.body===void 0)throw Error(`--body is required for this command. Pass --body '<json>' or --body @path/to/file.json.`)})},Te={command:`rules`,describe:`Rules that bypass or modify waiting room behavior for specific request patterns`,builder:e=>e.command(pe).command(ge).command(ve).command(xe).command(we).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var X={method:`PATCH`,path:t=>e`/zones/${t.zone_id}/waiting_rooms/settings`,body:`json`};function Ee(e){return e.usage(`$0 waiting-rooms settings edit
|
|
40
40
|
|
|
41
41
|
Patch zone-level Waiting Room settings.`).option(`search-engine-crawler-bypass`,{type:`boolean`,description:`Whether to allow verified search engine crawlers to bypass all waiting rooms on this zone.
|
|
42
42
|
Verified search engine crawlers will not be tracked or counted by the waiting room system,
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-BaUNb1Ed.mjs";import{i as n}from"./context-BQ6KeMgq.mjs";import{t as r}from"./output-O6b9MR9R.mjs";import{t as i}from"./dry-run-DQmFkNK_.mjs";import{t as a}from"./progress-CdlDthXA.mjs";import{t as o}from"./run-B_07PrkW.mjs";import"./telemetry-Dpm6GfZD.mjs";import{n as s,r as c,t as l}from"./body-parser-ChnyBsfm.mjs";import{n as u}from"./input-validation-D7z60HJH.mjs";import{a as d,i as f,n as p}from"./prompt-1AC-qwxS.mjs";var m={method:`GET`,path:t=>e`/zones/${t.zone_id}/api_gateway/discovery`};function ee(e){return e.usage(`$0 web-assets discovery get
|
|
3
3
|
|
|
4
4
|
Returns the latest API operations discovered from zone traffic, rendered as OpenAPI schemas.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const h={command:`get`,describe:`Export discovered API operations as OpenAPI schemas`,builder:ee,handler:async e=>o({command:`web-assets discovery get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf web-assets discovery get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/discovery`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let o=await t(e),s=await n({zone:e.zone},o,{quiet:e.quiet});e.zoneId=s;let c=await a(`Loading`,async()=>o.send(m,{zone_id:s}));r(c,{successLabel:`Loaded`})})};var te={method:`PATCH`,path:t=>e`/zones/${t.zone_id}/api_gateway/discovery/operations`,body:`json`};function ne(e){return e.usage(`$0 web-assets discovery operations bulk-edit
|
|
5
5
|
|
|
6
|
-
Updates the state of one or more discovered web and API operations.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const re={command:`bulk-edit`,describe:`Edit discovered web and API operations`,builder:ne,handler:async e=>o({command:`web-assets discovery operations bulk-edit`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf web-assets discovery operations bulk-edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/discovery/operations`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?void 0:s(e.body)});return}let o=await t(e),c=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=c,e.body){let t=s(e.body),n=await a(`Updating`,async()=>o.send(te,{body:t,zone_id:c}));r(n,{successLabel:`Updated`})
|
|
6
|
+
Updates the state of one or more discovered web and API operations.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const re={command:`bulk-edit`,describe:`Edit discovered web and API operations`,builder:ne,handler:async e=>o({command:`web-assets discovery operations bulk-edit`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf web-assets discovery operations bulk-edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/discovery/operations`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?void 0:s(e.body)});return}let o=await t(e),c=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=c,e.body){let t=s(e.body),n=await a(`Updating`,async()=>o.send(te,{body:t,zone_id:c}));r(n,{successLabel:`Updated`})}else if(e.body===void 0)throw Error(`--body is required for this command. Pass --body '<json>' or --body @path/to/file.json.`)})};var g={method:`PATCH`,path:t=>e`/zones/${t.zone_id}/api_gateway/discovery/operations/${t.discovery_id}`,body:`json`};function ie(e){return e.usage(`$0 web-assets discovery operations edit <discovery-id>
|
|
7
7
|
|
|
8
8
|
Updates the state of a discovered web or API operation.`).positional(`discovery-id`,{type:`string`,description:`Discovery ID of a discovered operation`,demandOption:!0}).option(`state`,{type:`string`,description:"Mark state of operation in API Discovery\n * `review` - Mark operation as for review\n * `ignored` - Mark operation as ignored\n",choices:[`review`,`ignored`]}).coerce(`state`,e=>u(e,`state`,`text`)).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 ae={command:`edit <discovery-id>`,describe:`Edit a discovered web or API operation`,builder:ie,handler:async e=>o({command:`web-assets discovery operations edit`,classification:{safeFlags:[`state`,`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf web-assets discovery operations edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/discovery/operations/${e[`discovery-id`]==null?`<discovery-id>`:encodeURIComponent(String(e[`discovery-id`]))}`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``),"discovery-id":String(e[`discovery-id`]??``)},bodyKind:`json`,body:e.body===void 0?l({state:e.state}):s(e.body)});return}let o=await t(e),c=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=c,e.body){let t=s(e.body),n=await a(`Updating`,async()=>o.send(g,{body:t,zone_id:c,discovery_id:e[`discovery-id`]}));r(n,{successLabel:`Updated`});return}let u=l({state:e.state}),d=await a(`Updating`,async()=>o.send(g,{body:u,zone_id:c,discovery_id:e[`discovery-id`]}));r(d,{successLabel:`Updated`})})};var oe={method:`GET`,path:t=>e`/zones/${t.zone_id}/api_gateway/discovery/operations/${t.discovery_id}`};function se(e){return e.usage(`$0 web-assets discovery operations get <discovery-id>
|
|
9
9
|
|
|
@@ -15,12 +15,12 @@ Returns all managed and user-defined labels available for web and API operations
|
|
|
15
15
|
|
|
16
16
|
Returns a managed label and the web and API operations associated with it.`).positional(`name`,{type:`string`,description:`The label name`,demandOption:!0}).option(`with-mapped-resource-counts`,{type:`boolean`,description:"Include `mapped_resources` for each label"}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const E={command:`get <name>`,describe:`Get a managed operation label`,builder:T,handler:async e=>o({command:`web-assets labels managed get`,classification:{safeFlags:[`with-mapped-resource-counts`,`dry-run`]}},e,async()=>{let o={with_mapped_resource_counts:e[`with-mapped-resource-counts`]};if(e.dryRun){i({command:`cf web-assets labels managed get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/labels/managed/${e.name==null?`<name>`:encodeURIComponent(String(e.name))}`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``),name:String(e.name??``)},query:o,bodyKind:`none`});return}let s=await t(e),c=await n({zone:e.zone},s,{quiet:e.quiet});e.zoneId=c;let l=await a(`Loading`,async()=>s.send(w,{zone_id:c,name:e.name,...o}));r(l,{successLabel:`Loaded`})})};var D={method:`PUT`,path:t=>e`/zones/${t.zone_id}/api_gateway/labels/managed/${t.name}/resources/operation`,body:`json`};function O(e){return e.usage(`$0 web-assets labels managed operations update <name>
|
|
17
17
|
|
|
18
|
-
Replaces the complete set of web and API operations attached to the managed label.`).positional(`name`,{type:`string`,description:`The label name`,demandOption:!0}).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 k={command:`update <name>`,describe:`Replace operations attached to a managed label`,builder:O,handler:async e=>o({command:`web-assets labels managed operations update`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf web-assets labels managed operations update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/labels/managed/${e.name==null?`<name>`:encodeURIComponent(String(e.name))}/resources/operation`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``),name:String(e.name??``)},bodyKind:`json`,body:e.body===void 0?void 0:s(e.body)});return}let o=await t(e),c=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=c,e.body){let t=s(e.body),n=await a(`Updating`,async()=>o.send(D,{body:t,zone_id:c,name:e.name}));r(n,{successLabel:`Updated`})
|
|
18
|
+
Replaces the complete set of web and API operations attached to the managed label.`).positional(`name`,{type:`string`,description:`The label name`,demandOption:!0}).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 k={command:`update <name>`,describe:`Replace operations attached to a managed label`,builder:O,handler:async e=>o({command:`web-assets labels managed operations update`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf web-assets labels managed operations update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/labels/managed/${e.name==null?`<name>`:encodeURIComponent(String(e.name))}/resources/operation`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``),name:String(e.name??``)},bodyKind:`json`,body:e.body===void 0?void 0:s(e.body)});return}let o=await t(e),c=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=c,e.body){let t=s(e.body),n=await a(`Updating`,async()=>o.send(D,{body:t,zone_id:c,name:e.name}));r(n,{successLabel:`Updated`})}else if(e.body===void 0)throw Error(`--body is required for this command. Pass --body '<json>' or --body @path/to/file.json.`)})},A={command:`operations`,describe:`Operations for labels.managed.operations`,builder:e=>e.command(k).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},j={command:`managed`,describe:`Operations for labels.managed`,builder:e=>e.command(E).command(A).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var M={method:`POST`,path:t=>e`/zones/${t.zone_id}/api_gateway/labels/user`,body:`json`};function N(e){return e.usage(`$0 web-assets labels user bulk-create
|
|
19
19
|
|
|
20
|
-
Creates one or more user-defined labels for classifying web and API operations.`).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 P={command:`bulk-create`,describe:`Create user-defined operation labels`,builder:N,handler:async e=>o({command:`web-assets labels user bulk-create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf web-assets labels user bulk-create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/labels/user`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?void 0:s(e.body)});return}let o=await t(e),c=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=c,e.body){let t=s(e.body),n=await a(`Creating`,async()=>o.send(M,{body:t,zone_id:c}));r(n,{successLabel:`Created`})
|
|
20
|
+
Creates one or more user-defined labels for classifying web and API operations.`).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 P={command:`bulk-create`,describe:`Create user-defined operation labels`,builder:N,handler:async e=>o({command:`web-assets labels user bulk-create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf web-assets labels user bulk-create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/labels/user`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?void 0:s(e.body)});return}let o=await t(e),c=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=c,e.body){let t=s(e.body),n=await a(`Creating`,async()=>o.send(M,{body:t,zone_id:c}));r(n,{successLabel:`Created`})}else if(e.body===void 0)throw Error(`--body is required for this command. Pass --body '<json>' or --body @path/to/file.json.`)})};var F={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/api_gateway/labels/user`,body:`json`};function I(e){return e.usage(`$0 web-assets labels user bulk-delete
|
|
21
21
|
|
|
22
|
-
Deletes one or more user-defined labels and removes their associations with web and API operations.`).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 L={command:`bulk-delete`,describe:`Delete user-defined operation labels`,builder:I,handler:async e=>o({command:`web-assets labels user bulk-delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){i({command:`cf web-assets labels user bulk-delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/labels/user`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?void 0:s(e.body)});return}let o=await t(e),c=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=c,!await p({force:!!e.force,message:`This operation deletes the selected user-defined labels and removes them from associated web and API operations.`}))
|
|
23
|
-
`);
|
|
22
|
+
Deletes one or more user-defined labels and removes their associations with web and API operations.`).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 L={command:`bulk-delete`,describe:`Delete user-defined operation labels`,builder:I,handler:async e=>o({command:`web-assets labels user bulk-delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){i({command:`cf web-assets labels user bulk-delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/labels/user`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?void 0:s(e.body)});return}let o=await t(e),c=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=c,!await p({force:!!e.force,message:`This operation deletes the selected user-defined labels and removes them from associated web and API operations.`}))process.stderr.write(`Aborted.
|
|
23
|
+
`);else if(e.body){let t=s(e.body),n=await a(`Deleting`,async()=>o.send(F,{body:t,zone_id:c}));r(n,{successLabel:`Deleted`})}else if(e.body===void 0)throw Error(`--body is required for this command. Pass --body '<json>' or --body @path/to/file.json.`)})};var R={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/api_gateway/labels/user/${t.name}`};function z(e){return e.usage(`$0 web-assets labels user delete <name>
|
|
24
24
|
|
|
25
25
|
Deletes a user-defined label and removes its associations with web and API operations.`).positional(`name`,{type:`string`,description:`The label name`,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 B={command:`delete <name>`,describe:`Delete a user-defined operation label`,builder:z,handler:async e=>o({command:`web-assets labels user delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){i({command:`cf web-assets labels user delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/labels/user/${e.name==null?`<name>`:encodeURIComponent(String(e.name))}`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``),name:String(e.name??``)},bodyKind:`none`});return}let o=await t(e),s=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=s,!await p({force:!!e.force,message:`This operation deletes the user-defined label and removes it from associated web and API operations.`})){process.stderr.write(`Aborted.
|
|
26
26
|
`);return}let c=await a(`Deleting`,async()=>o.send(R,{zone_id:s,name:e.name}));r(c,{successLabel:`Deleted`})})};var V={method:`PATCH`,path:t=>e`/zones/${t.zone_id}/api_gateway/labels/user/${t.name}`,body:`json`};function H(e){return e.usage(`$0 web-assets labels user edit <name>
|
|
@@ -29,14 +29,14 @@ Updates only the supplied fields on a user-defined label.`).positional(`name`,{t
|
|
|
29
29
|
|
|
30
30
|
Returns a user-defined label and the web and API operations associated with it.`).positional(`name`,{type:`string`,description:`The label name`,demandOption:!0}).option(`with-mapped-resource-counts`,{type:`boolean`,description:"Include `mapped_resources` for each label"}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const de={command:`get <name>`,describe:`Get a user-defined operation label`,builder:ue,handler:async e=>o({command:`web-assets labels user get`,classification:{safeFlags:[`with-mapped-resource-counts`,`dry-run`]}},e,async()=>{let o={with_mapped_resource_counts:e[`with-mapped-resource-counts`]};if(e.dryRun){i({command:`cf web-assets labels user get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/labels/user/${e.name==null?`<name>`:encodeURIComponent(String(e.name))}`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``),name:String(e.name??``)},query:o,bodyKind:`none`});return}let s=await t(e),c=await n({zone:e.zone},s,{quiet:e.quiet});e.zoneId=c;let l=await a(`Loading`,async()=>s.send(W,{zone_id:c,name:e.name,...o}));r(l,{successLabel:`Loaded`})})};var fe={method:`PUT`,path:t=>e`/zones/${t.zone_id}/api_gateway/labels/user/${t.name}/resources/operation`,body:`json`};function pe(e){return e.usage(`$0 web-assets labels user operations update <name>
|
|
31
31
|
|
|
32
|
-
Replaces the complete set of web and API operations attached to the user-defined label.`).positional(`name`,{type:`string`,description:`The label name`,demandOption:!0}).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 me={command:`update <name>`,describe:`Replace operations attached to a user-defined label`,builder:pe,handler:async e=>o({command:`web-assets labels user operations update`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf web-assets labels user operations update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/labels/user/${e.name==null?`<name>`:encodeURIComponent(String(e.name))}/resources/operation`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``),name:String(e.name??``)},bodyKind:`json`,body:e.body===void 0?void 0:s(e.body)});return}let o=await t(e),c=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=c,e.body){let t=s(e.body),n=await a(`Updating`,async()=>o.send(fe,{body:t,zone_id:c,name:e.name}));r(n,{successLabel:`Updated`})
|
|
32
|
+
Replaces the complete set of web and API operations attached to the user-defined label.`).positional(`name`,{type:`string`,description:`The label name`,demandOption:!0}).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 me={command:`update <name>`,describe:`Replace operations attached to a user-defined label`,builder:pe,handler:async e=>o({command:`web-assets labels user operations update`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf web-assets labels user operations update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/labels/user/${e.name==null?`<name>`:encodeURIComponent(String(e.name))}/resources/operation`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``),name:String(e.name??``)},bodyKind:`json`,body:e.body===void 0?void 0:s(e.body)});return}let o=await t(e),c=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=c,e.body){let t=s(e.body),n=await a(`Updating`,async()=>o.send(fe,{body:t,zone_id:c,name:e.name}));r(n,{successLabel:`Updated`})}else if(e.body===void 0)throw Error(`--body is required for this command. Pass --body '<json>' or --body @path/to/file.json.`)})},he={command:`operations`,describe:`Operations for labels.user.operations`,builder:e=>e.command(me).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var G={method:`PUT`,path:t=>e`/zones/${t.zone_id}/api_gateway/labels/user/${t.name}`,body:`json`};function ge(e){return e.usage(`$0 web-assets labels user update <name>
|
|
33
33
|
|
|
34
34
|
Replaces all editable fields on a user-defined label.`).positional(`name`,{type:`string`,description:`The label name`,demandOption:!0}).option(`description`,{type:`string`,description:`The description of the label`}).option(`metadata`,{type:`string`,description:`Metadata for the label. Provide as a JSON object or @path/to/file.json.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const _e={command:`update <name>`,describe:`Update a user-defined operation label`,builder:ge,handler:async e=>o({command:`web-assets labels user update`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf web-assets labels user update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/labels/user/${e.name==null?`<name>`:encodeURIComponent(String(e.name))}`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``),name:String(e.name??``)},bodyKind:`json`,body:e.body===void 0?l({description:u(e.description,`description`,`text`),metadata:c(e.metadata,`metadata`)},[[`metadata`]]):s(e.body)});return}let o=await t(e),d=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=d,e.body){let t=s(e.body),n=await a(`Updating`,async()=>o.send(G,{body:t,zone_id:d,name:e.name}));r(n,{successLabel:`Updated`});return}let f=l({description:u(e.description,`description`,`text`),metadata:c(e.metadata,`metadata`)},[[`metadata`]]),p=await a(`Updating`,async()=>o.send(G,{body:f,zone_id:d,name:e.name}));r(p,{successLabel:`Updated`})})},ve={command:`user`,describe:`Operations for labels.user`,builder:e=>e.command(P).command(L).command(B).command(U).command(de).command(_e).command(he).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},ye={command:`labels`,describe:`Operations for labels`,builder:e=>e.command(C).command(j).command(ve).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var be={method:`POST`,path:t=>e`/zones/${t.zone_id}/api_gateway/operations`,body:`json`};function xe(e){return e.usage(`$0 web-assets operations bulk-create
|
|
35
35
|
|
|
36
|
-
Creates one or more web or API operations. Hosts, methods, and paths are normalized; an existing matching operation is returned instead of duplicated.`).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 Se={command:`bulk-create`,describe:`Create web or API operations`,builder:xe,handler:async e=>o({command:`web-assets operations bulk-create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf web-assets operations bulk-create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/operations`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?void 0:s(e.body)});return}let o=await t(e),c=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=c,e.body){let t=s(e.body),n=await a(`Creating`,async()=>o.send(be,{body:t,zone_id:c}));r(n,{successLabel:`Created`})
|
|
36
|
+
Creates one or more web or API operations. Hosts, methods, and paths are normalized; an existing matching operation is returned instead of duplicated.`).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 Se={command:`bulk-create`,describe:`Create web or API operations`,builder:xe,handler:async e=>o({command:`web-assets operations bulk-create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf web-assets operations bulk-create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/operations`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?void 0:s(e.body)});return}let o=await t(e),c=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=c,e.body){let t=s(e.body),n=await a(`Creating`,async()=>o.send(be,{body:t,zone_id:c}));r(n,{successLabel:`Created`})}else if(e.body===void 0)throw Error(`--body is required for this command. Pass --body '<json>' or --body @path/to/file.json.`)})};var Ce={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/api_gateway/operations`,body:`json`};function we(e){return e.usage(`$0 web-assets operations bulk-delete
|
|
37
37
|
|
|
38
|
-
Deletes multiple web or API operations from endpoint management in one request.`).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 Te={command:`bulk-delete`,describe:`Delete web or API operations`,builder:we,handler:async e=>o({command:`web-assets operations bulk-delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){i({command:`cf web-assets operations bulk-delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/operations`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?void 0:s(e.body)});return}let o=await t(e),c=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=c,!await p({force:!!e.force,message:`This operation deletes the selected web or API operations.`}))
|
|
39
|
-
`);
|
|
38
|
+
Deletes multiple web or API operations from endpoint management in one request.`).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 Te={command:`bulk-delete`,describe:`Delete web or API operations`,builder:we,handler:async e=>o({command:`web-assets operations bulk-delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){i({command:`cf web-assets operations bulk-delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/operations`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?void 0:s(e.body)});return}let o=await t(e),c=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=c,!await p({force:!!e.force,message:`This operation deletes the selected web or API operations.`}))process.stderr.write(`Aborted.
|
|
39
|
+
`);else if(e.body){let t=s(e.body),n=await a(`Deleting`,async()=>o.send(Ce,{body:t,zone_id:c}));r(n,{successLabel:`Deleted`})}else if(e.body===void 0)throw Error(`--body is required for this command. Pass --body '<json>' or --body @path/to/file.json.`)})};var K={method:`POST`,path:t=>e`/zones/${t.zone_id}/api_gateway/operations/item`,body:`json`};function Ee(e){return e.usage(`$0 web-assets operations create
|
|
40
40
|
|
|
41
41
|
Creates one web or API operation. The host, method, and path are normalized; an existing matching operation is returned instead of duplicated.`).option(`endpoint`,{type:`string`,description:`The endpoint which can contain path parameter templates in curly braces, each will be replaced from left to right with {varN}, starting with {var1}, during insertion. This will further be Cloudflare-normalized upon insertion. See: https://developers.cloudflare.com/rules/normalization/how-it-works/.`}).option(`host`,{type:`string`,description:`RFC3986-compliant host.`}).option(`method`,{type:`string`,description:`The HTTP method used to access the endpoint.`,choices:[`GET`,`POST`,`HEAD`,`OPTIONS`,`PUT`,`DELETE`,`CONNECT`,`PATCH`,`TRACE`]}).coerce(`method`,e=>u(e,`method`,`text`)).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 De={command:`create`,describe:`Create a web or API operation`,builder:Ee,handler:async e=>o({command:`web-assets operations create`,classification:{safeFlags:[`method`,`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf web-assets operations create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/operations/item`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?l({endpoint:u(e.endpoint,`endpoint`,`text`),host:u(e.host,`host`,`text`),method:e.method}):s(e.body)});return}let o=await t(e),c=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=c,e.body){let t=s(e.body),n=await a(`Creating`,async()=>o.send(K,{body:t,zone_id:c}));r(n,{successLabel:`Created`});return}e.endpoint===void 0&&(e.endpoint=await d(`endpoint`,`The endpoint which can contain path parameter templates in curly braces, each will be replaced from left to right with {varN}, starting with {var1}, during insertion. This will further be Cloudflare-normalized upon insertion. See: https://developers.cloudflare.com/rules/normalization/how-it-works/.`)),e.host===void 0&&(e.host=await d(`host`,`RFC3986-compliant host.`)),e.method===void 0&&(e.method=await f(`method`,`The HTTP method used to access the endpoint.`,[`GET`,`POST`,`HEAD`,`OPTIONS`,`PUT`,`DELETE`,`CONNECT`,`PATCH`,`TRACE`]));let p=l({endpoint:u(e.endpoint,`endpoint`,`text`),host:u(e.host,`host`,`text`),method:e.method}),m=await a(`Creating`,async()=>o.send(K,{body:p,zone_id:c}));r(m,{successLabel:`Created`})})};var Oe={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/api_gateway/operations/${t.operation_id}`};function ke(e){return e.usage(`$0 web-assets operations delete <operation-id>
|
|
42
42
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-BaUNb1Ed.mjs";import{i as n}from"./context-BQ6KeMgq.mjs";import{t as r}from"./output-O6b9MR9R.mjs";import{t as i}from"./dry-run-DQmFkNK_.mjs";import{t as a}from"./progress-CdlDthXA.mjs";import{t as o}from"./run-B_07PrkW.mjs";import"./telemetry-Dpm6GfZD.mjs";import{a as s,n as c,t as l}from"./body-parser-ChnyBsfm.mjs";import{n as u}from"./input-validation-D7z60HJH.mjs";import{a as d,i as f,n as p}from"./prompt-1AC-qwxS.mjs";var m={method:`POST`,path:t=>e`/zones/${t.zone_id}/web3/hostnames`,body:`json`};function h(e){return e.usage(`$0 web3 hostnames create
|
|
3
3
|
|
|
4
4
|
Create Web3 Hostname`).option(`description`,{type:`string`,description:`Specify an optional description of the hostname.`}).option(`dnslink`,{type:`string`,description:`Specify the DNSLink value used if the target is ipfs.`}).option(`name`,{type:`string`,description:`Specify the hostname that points to the target gateway via CNAME.`}).option(`target`,{type:`string`,description:`Specify the target gateway of the hostname.`,choices:[`ethereum`,`ipfs`,`ipfs_universal_path`]}).coerce(`target`,e=>u(e,`target`,`text`)).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const g={command:`create`,describe:`Create Web3 Hostname`,builder:h,handler:async e=>o({command:`web3 hostnames create`,classification:{safeFlags:[`target`,`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf web3 hostnames create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/web3/hostnames`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?l({description:u(e.description,`description`,`text`),dnslink:u(e.dnslink,`dnslink`,`text`),name:u(e.name,`name`,`text`),target:e.target}):c(e.body)});return}let o=await t(e),s=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=s,e.body){let t=c(e.body),n=await a(`Creating`,async()=>o.send(m,{body:t,zone_id:s}));r(n,{successLabel:`Created`});return}e.name===void 0&&(e.name=await d(`name`,`Specify the hostname that points to the target gateway via CNAME.`)),e.target===void 0&&(e.target=await f(`target`,`Specify the target gateway of the hostname.`,[`ethereum`,`ipfs`,`ipfs_universal_path`]));let p=l({description:u(e.description,`description`,`text`),dnslink:u(e.dnslink,`dnslink`,`text`),name:u(e.name,`name`,`text`),target:e.target}),h=await a(`Creating`,async()=>o.send(m,{body:p,zone_id:s}));r(h,{successLabel:`Created`})})};var _={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/web3/hostnames/${t.identifier}`};function v(e){return e.usage(`$0 web3 hostnames delete <identifier>
|
|
5
5
|
|