cf 1.0.0-beta.20 → 1.0.0-beta.21
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 +1 -1
- package/dist/_meta/commands.json +911 -751
- package/dist/_meta/schemas.json +401 -382
- package/dist/{abuse-reports-mKv00yPh.mjs → abuse-reports-CbUAnJxd.mjs} +1 -1
- package/dist/{access-CyRjTbhh.mjs → access-C-78DlxL.mjs} +1 -1
- package/dist/{accounts-BmF_YKvG.mjs → accounts-DEqQPxCz.mjs} +8 -15
- package/dist/{acm-BcIFiAb8.mjs → acm-jmhCq3Yh.mjs} +2 -3
- package/dist/{addressing-D6xVD7MM.mjs → addressing-BeYFpQvC.mjs} +12 -23
- package/dist/{agent-memory-Blldunhv.mjs → agent-memory-Chlovb7j.mjs} +5 -9
- package/dist/{ai-CU8tdTfC.mjs → ai-BndH3HYN.mjs} +2 -3
- package/dist/{ai-audit-Id3hq5pV.mjs → ai-audit-BUJ-70O_.mjs} +1 -1
- package/dist/{ai-gateway-BKeZ28CQ.mjs → ai-gateway-CCk7VKhL.mjs} +9 -15
- package/dist/{ai-search-DOiZEmn7.mjs → ai-search-BexET_wp.mjs} +6 -11
- package/dist/{ai-security-CioADDZi.mjs → ai-security-D4MxRlxX.mjs} +3 -5
- package/dist/{alerting-BzN1N3Se.mjs → alerting-rw8Oi3x7.mjs} +5 -9
- package/dist/{analytics-engine-CugCQfDe.mjs → analytics-engine-Bk7dQLcm.mjs} +1 -1
- package/dist/{analytics-Cte-DrzH.mjs → analytics-q-guNEOK.mjs} +1 -1
- package/dist/{api-security-CCs0g510.mjs → api-security-BDc6gkf1.mjs} +9 -17
- package/dist/{argo-BHBFZnmO.mjs → argo-CnLIqm0i.mjs} +1 -1
- package/dist/args-BAOHroBC.mjs +2 -0
- package/dist/{artifacts-BzAwvrCD.mjs → artifacts-Cil33dzV.mjs} +4 -7
- package/dist/{audit-logs-jWivEKCy.mjs → audit-logs--E2Eclb7.mjs} +1 -1
- package/dist/auth-B0lEsD_1.mjs +2 -0
- package/dist/{auth-BUQscD5b.mjs → auth-BcNLQji1.mjs} +1 -1
- package/dist/auth-BtZmY6sE.mjs +2 -0
- package/dist/{auth-token-T0aqYgl9.mjs → auth-token-aF5AVLlH.mjs} +1 -1
- package/dist/{autoconfig-CBdcYYf4.mjs → autoconfig-Dbp6J25P.mjs} +88 -88
- package/dist/{basin-catalog-_8w_4599.mjs → basin-catalog-dnVyzopm.mjs} +3 -5
- package/dist/{billing-Ce0WN0yw.mjs → billing-Fqp3jB2V.mjs} +2 -3
- package/dist/{blocks-CFAm0Ma3.mjs → blocks-BOQH-Won.mjs} +1 -1
- package/dist/{bot-management-DskcSr4B.mjs → bot-management-SEDgo1Xg.mjs} +1 -1
- package/dist/{botnet-feed-CmBm13-D.mjs → botnet-feed-DPqR4M0Y.mjs} +2 -3
- package/dist/{brand-protection-DTuFrsN0.mjs → brand-protection-B8vwKfM9.mjs} +2 -3
- package/dist/{browser-run-CXdzSOHa.mjs → browser-run-BybYDq3I.mjs} +3 -5
- package/dist/build-BqGmiORA.mjs +2 -0
- package/dist/build-CWlpWVBf.mjs +2 -0
- package/dist/{builds-_1u5Nx6f.mjs → builds-CvtOG-Gk.mjs} +8 -15
- package/dist/cache-Bme_d2Wx.mjs +36 -0
- package/dist/cf-fIBhEAxU.mjs +18 -0
- package/dist/chunk-DSGVRFIS-DHC6NOIj.mjs +2 -0
- package/dist/{chunk-2K52M2W5-iYNzknM1.mjs → chunk-XVBBSNW2-DfMyGS-l.mjs} +8 -8
- package/dist/{cli-DyhOdzMo.mjs → cli-CIKDqm-u.mjs} +3 -3
- package/dist/{client-side-security-DnnYaRsd.mjs → client-side-security-ZQeRoo1t.mjs} +2 -3
- package/dist/{cloud-connector-Ct6b6pz8.mjs → cloud-connector-BeunZlNV.mjs} +1 -1
- package/dist/{cloudflared-CHLpWU35.mjs → cloudflared-DbzoIouQ.mjs} +1 -1
- package/dist/{cloudforce-one-Rl6nCCm0.mjs → cloudforce-one-D20t9ojD.mjs} +26 -51
- package/dist/{command-BwgvUpNx.mjs → command-B3uWlw57.mjs} +1 -1
- package/dist/{command-DuLxEkGq.mjs → command-BGRucANI.mjs} +1 -1
- package/dist/{command-BONLLcyz.mjs → command-C6kE7BU0.mjs} +1 -1
- package/dist/{command-DOpykk8X.mjs → command-C9CNvZi_.mjs} +1 -1
- package/dist/{command-BRpBIju7.mjs → command-CQ5qHE7n.mjs} +1 -1
- package/dist/{command-CHGc-KZ7.mjs → command-CkZkTjIj.mjs} +1 -1
- package/dist/{command-BRXOUAGD.mjs → command-CqKRlHGv.mjs} +1 -1
- package/dist/{command-BwlIi3Bv.mjs → command-CtlD6MEi.mjs} +1 -1
- package/dist/{command-CXzje7qc.mjs → command-CzWWQv8j.mjs} +1 -1
- package/dist/{command-BMYi_gS-.mjs → command-DWWuXQV8.mjs} +1 -1
- package/dist/{command-CPDQPdss.mjs → command-DkwmylF2.mjs} +1 -1
- package/dist/{command-CMa807gY.mjs → command-MxFFWqMg.mjs} +1 -1
- package/dist/{command-BVO9UOuU.mjs → command-orlUsdgf.mjs} +1 -1
- package/dist/{command-CVoDyQnL.mjs → command-prWMAJbg.mjs} +1 -1
- package/dist/{command-0WS5I_JW.mjs → command-rUCxlpQI.mjs} +1 -1
- package/dist/command-resolution-DAQ4PWUt.mjs +2 -0
- package/dist/{completions-DMwrvK_S.mjs → completions-2Otv0HMd.mjs} +1 -1
- package/dist/{connector-interrupts-DyWilINb.mjs → connector-interrupts-Dfhxupmg.mjs} +1 -1
- package/dist/{connector-telemetry-events-BUW9qTOs.mjs → connector-telemetry-events-CLVpDTIa.mjs} +1 -1
- package/dist/{connector-telemetry-snapshots-Djs5QssR.mjs → connector-telemetry-snapshots-E_1tmNmQ.mjs} +1 -1
- package/dist/{connectors-e_cpzDEm.mjs → connectors-ChJpQFSl.mjs} +2 -3
- package/dist/{containers-CEH15JUu.mjs → containers-Cj5-9nUg.mjs} +6 -9
- package/dist/containers-CzAZfmnj.mjs +380 -0
- package/dist/{content-scan-B6Ahw9JA.mjs → content-scan-CIA_9PV8.mjs} +3 -5
- package/dist/{context-Sgba0fZP.mjs → context-DVh8Wyfs.mjs} +2 -2
- package/dist/{cps-uDD0SSJ-.mjs → cps-hJkqdsHx.mjs} +1 -1
- package/dist/{csam-scanner-BSUl7jGn.mjs → csam-scanner-cCVO3lNF.mjs} +1 -1
- package/dist/{custom-csrs-BDcXggph.mjs → custom-csrs-BrTWUZ0c.mjs} +2 -3
- package/dist/{custom-hostnames-UmIlwkwt.mjs → custom-hostnames-C4ft77oC.mjs} +4 -7
- package/dist/{custom-nameservers-D7kU6d--.mjs → custom-nameservers-BWfrZhD1.mjs} +2 -3
- package/dist/{custom-pages-CkhIQCfM.mjs → custom-pages-DqTMKtRc.mjs} +2 -3
- package/dist/{d1-myRLEAGs.mjs → d1-B58AA9PA.mjs} +3 -6
- package/dist/delegate-D7yYckA4.mjs +2 -0
- package/dist/delegate.mjs +1 -1
- package/dist/{deploy-BJqCpycz.mjs → deploy-CEROLAdh.mjs} +1 -1
- package/dist/deploy-context-Do89WayB.mjs +56 -0
- package/dist/{deploy-input-v2DryyLP.mjs → deploy-input-DyMuMsi5.mjs} +1 -1
- package/dist/{dev-S1PJi83q.mjs → dev-BaFS7kOM.mjs} +2 -2
- package/dist/{diagnostics-q65rcNIk.mjs → diagnostics-4gfYj7Pf.mjs} +2 -3
- package/dist/dialog-D5lus4M4.mjs +2 -0
- package/dist/discover-6kAmVMPp.mjs +2 -0
- package/dist/discover-C06Syc2B.mjs +2 -0
- package/dist/dist-BtzWfAjU.mjs +453 -0
- package/dist/dls-ClWVxTBg.mjs +16 -0
- package/dist/{dns-DhARjFQs.mjs → dns-CML-wxIt.mjs} +68 -68
- package/dist/{dns-firewall-BP6r9QG6.mjs → dns-firewall-CL0b3dJ1.mjs} +2 -3
- package/dist/{docs-CReGWDrw.mjs → docs-BeYBHwUN.mjs} +1 -1
- package/dist/{dotenv-Ck-6V1hm.mjs → dotenv-CmPRiXmU.mjs} +1 -1
- package/dist/{dry-run-BBjUQUhR.mjs → dry-run-gy0Hl9xo.mjs} +1 -1
- package/dist/{durable-objects-tOJy-5te.mjs → durable-objects-uZECeq_f.mjs} +1 -1
- package/dist/{email-auth-Bq9sq_2j.mjs → email-auth-CCNW798I.mjs} +1 -1
- package/dist/email-domains-1rD1d84O.mjs +12 -0
- package/dist/{email-routing-CYo4dp50.mjs → email-routing-CYv-LrbV.mjs} +4 -7
- package/dist/{email-security-CNtWET2d.mjs → email-security-CWEUYPYo.mjs} +16 -31
- package/dist/{email-sending-BvagNLRr.mjs → email-sending-DHSzCfJx.mjs} +3 -5
- package/dist/{errors-DpbAQQv8.mjs → errors-ol9sMqSe.mjs} +8 -8
- package/dist/{field-extractors-C9R3Qivh.mjs → field-extractors-CuBM_uO4.mjs} +2 -3
- package/dist/{firewall-DsgUY-Qv.mjs → firewall-SMIUSypF.mjs} +4 -7
- package/dist/flagship-D3v6iDdw.mjs +24 -0
- package/dist/{fraud-24l8dKyk.mjs → fraud-B2f7O15X.mjs} +1 -1
- package/dist/{google-tag-gateway-CAkudP5W.mjs → google-tag-gateway-BwOc62Gy.mjs} +1 -1
- package/dist/{gt-D6YemCLh.mjs → gt-BQkaDQDq.mjs} +1 -1
- package/dist/{healthchecks-CEGMe3lO.mjs → healthchecks-BQXHnihB.mjs} +3 -5
- package/dist/{hyperdrive-DLDaOU2O.mjs → hyperdrive-Bd6Yfje3.mjs} +2 -3
- package/dist/{iam-ChldOMSL.mjs → iam-qJPI1_aZ.mjs} +5 -9
- package/dist/{images-Ba9tS5wT.mjs → images-goHZJOxy.mjs} +6 -11
- package/dist/index.mjs +1 -1
- package/dist/init-CVx0Ya1E.mjs +43 -0
- package/dist/{intel-DbLRah4Y.mjs → intel-CwiqwJI9.mjs} +18 -21
- package/dist/interactive-CHcvofEp.mjs +2 -0
- package/dist/{interactive-d_lFnSev.mjs → interactive-D4E8PdaW.mjs} +31 -31
- package/dist/interactive-wQM7Blhm.mjs +2 -0
- package/dist/internal-5cnlw9mH.mjs +4 -0
- package/dist/{ips-BGyzyQLL.mjs → ips-KBxmXhvO.mjs} +1 -1
- package/dist/{k2-BVQ3MqEl.mjs → k2-KhIP5NFT.mjs} +2 -3
- package/dist/kv-CCem2sEY.mjs +12 -0
- package/dist/{lazy-command-D0I6itZs.mjs → lazy-command-BMhD5ffF.mjs} +1 -1
- package/dist/{leaked-credential-checks-Dga83Qy3.mjs → leaked-credential-checks-BkPZiwE2.mjs} +3 -5
- package/dist/live-BhHzxFna.mjs +4 -0
- package/dist/{load-balancers-D9cB6of8.mjs → load-balancers-17GBXdju.mjs} +5 -9
- package/dist/local-CAs8RWYW.mjs +2 -0
- package/dist/{local-B7ZJ78al.mjs → local-CSH3UMpD.mjs} +1 -1
- package/dist/{local-runtime-DB545Gqq.mjs → local-runtime-KOFLRZeZ.mjs} +1 -1
- package/dist/log-BWdaOGOW.mjs +66 -0
- package/dist/log-DZfik9Jk.mjs +2 -0
- package/dist/login-BTiflOun.mjs +2 -0
- package/dist/login-Buhvx6Fi.mjs +5 -0
- package/dist/{logpush-Ccmr0Y_I.mjs → logpush-BCCUxa4J.mjs} +3 -5
- package/dist/{logs-CZBMuuBC.mjs → logs-4CwupKRG.mjs} +2 -3
- package/dist/{magic-cloud-networking-BwOxZVql.mjs → magic-cloud-networking-Xy6SC-V-.mjs} +4 -7
- package/dist/{magic-network-monitoring-Cx5kKdbk.mjs → magic-network-monitoring-B8pRZp2g.mjs} +3 -5
- package/dist/{magic-transit-BJwg3sVK.mjs → magic-transit-CwfO3OOX.mjs} +36 -67
- package/dist/managed-defense-CtFLuvuB.mjs +18 -0
- package/dist/{managed-transforms-C-HMtesC.mjs → managed-transforms-Hto8OCBS.mjs} +2 -3
- package/dist/{mcp-bGKgzz6F.mjs → mcp-SQ0MAVUJ.mjs} +3 -5
- package/dist/{mesh-DeQIll19.mjs → mesh-C8A6tVqA.mjs} +3 -5
- package/dist/{migrate-B6HsPeFh.mjs → migrate-Dufxsb_F.mjs} +1 -1
- package/dist/{monetization-B-TIrpA5.mjs → monetization-CYVaCAe9.mjs} +3 -5
- package/dist/{network-BrjykU-I.mjs → network-CJBTdEM3.mjs} +5 -9
- package/dist/{network-interconnects-I06kbxIl.mjs → network-interconnects-CKlNFj3i.mjs} +3 -5
- package/dist/{o11y-Ba0Fa98_.mjs → o11y-5x2Q8CWm.mjs} +8 -15
- package/dist/{oauth-BH-uQd3C.mjs → oauth-BN6_FpYp.mjs} +1 -1
- package/dist/oauth-D_A8AcIS.mjs +4 -0
- package/dist/{oauth-clients-Dd5gvDqf.mjs → oauth-clients-qKXg8ZH3.mjs} +3 -5
- package/dist/{oauth-scopes-CXpH3Syj.mjs → oauth-scopes-Ct1jDyC5.mjs} +1 -1
- package/dist/{organization-DKPqwe3j.mjs → organization-lBQSeqS1.mjs} +3 -5
- package/dist/{organizations-Cq4iy-Yr.mjs → organizations-DEX8Er3g.mjs} +1 -1
- package/dist/{origin-post-quantum-encryption-DSB1sbYV.mjs → origin-post-quantum-encryption-DUsxVGCs.mjs} +1 -1
- package/dist/output-BJEgbI0G.mjs +2 -0
- package/dist/package-BqSbnt6u.mjs +2 -0
- package/dist/{page-rules-CDWTYaf7.mjs → page-rules-BMt6nt03.mjs} +2 -3
- package/dist/{pages-Dgtm51Uj.mjs → pages-Jxa92ECz.mjs} +7 -13
- package/dist/{pay-per-crawl-CHenxdhv.mjs → pay-per-crawl-Cv0044CZ.mjs} +3 -5
- package/dist/{pay-per-use-Bd5l0hBi.mjs → pay-per-use-DGEeG-dC.mjs} +2 -3
- package/dist/{pipelines-GsyD6nUM.mjs → pipelines-CEC78A3w.mjs} +5 -9
- package/dist/{precursor-mO-Zua09.mjs → precursor-Ba0Ejhzt.mjs} +1 -1
- package/dist/previews-DnZbUTym.mjs +6 -0
- package/dist/progress-CtGsPOpV.mjs +2 -0
- package/dist/prompt-YrI7ltMa.mjs +4 -0
- package/dist/{queues-D8cAr2lB.mjs → queues-Chq997uj.mjs} +6 -11
- package/dist/{r2-CJiJbG6b.mjs → r2-BFgZDs-F.mjs} +17 -33
- package/dist/{radar-PUZ_PCZ8.mjs → radar-DJdDzLJw.mjs} +1 -1
- package/dist/{raw-fetch-DSdFjojI.mjs → raw-fetch-BE3QgdTE.mjs} +1 -1
- package/dist/ready-Cok0aqke.mjs +4 -0
- package/dist/{realtime-X6uQsldp.mjs → realtime-BHWWCiKp.mjs} +10 -19
- package/dist/{registrar-BqZdUTss.mjs → registrar-9Y-1IQ0n.mjs} +1 -1
- package/dist/{registrar-sandbox-CmM3e1QN.mjs → registrar-sandbox-DTS1kRnb.mjs} +1 -1
- package/dist/{registry-D0tMkLv6.mjs → registry-Bm-GgDC3.mjs} +1 -1
- package/dist/{reporting-DFVz98Xg.mjs → reporting-D5RbKQJf.mjs} +1 -1
- package/dist/request-headers-KhW_hy36.mjs +2 -0
- package/dist/{request-tracers-BC1u2WDU.mjs → request-tracers-wxWCjmHo.mjs} +1 -1
- package/dist/{resource-sharing-CdEn5Iex.mjs → resource-sharing-BGoaVvJa.mjs} +5 -9
- package/dist/rolldown-runtime-BNtqjh-B.mjs +2 -0
- package/dist/{rules-B663VetJ.mjs → rules-Cd3EjhdF.mjs} +3 -5
- package/dist/{rulesets-p4EijVr6.mjs → rulesets-Bnz3rSBT.mjs} +4 -7
- package/dist/{rum-CHHXe4KK.mjs → rum-CK9HEe3O.mjs} +3 -5
- package/dist/run-Be6Js7D6.mjs +2 -0
- package/dist/run-DnZGQbq_.mjs +2 -0
- package/dist/sanitization-DkVWMHkc.mjs +2 -0
- package/dist/{schema-B38ojvsS.mjs → schema-DuLIZRhA.mjs} +1 -1
- package/dist/{schema-flags-z7yn0JZ_.mjs → schema-flags-BrDlFwLv.mjs} +1 -1
- package/dist/{scim-BMnUa4Oz.mjs → scim-UdqaWnOu.mjs} +3 -5
- package/dist/{secrets-store-EYrhEzVG.mjs → secrets-store-Bf5v96LC.mjs} +3 -5
- package/dist/{security-insights-C-AwDwXb.mjs → security-insights-BAGySlGu.mjs} +1 -1
- package/dist/{security-txt-CQMe8TD3.mjs → security-txt-D0fMmjHs.mjs} +2 -3
- package/dist/session-6xqrJWXy.mjs +2 -0
- package/dist/shared-DYRRG9A-.mjs +2 -0
- package/dist/signed-url-Ce0muRem.mjs +4 -0
- package/dist/{smart-shield-CHSuitaH.mjs → smart-shield-CCy7_M3j.mjs} +3 -5
- package/dist/{snippets-DGSBz4lg.mjs → snippets-Bc8m3HSV.mjs} +3 -5
- package/dist/spawn-BAEdy9kS.mjs +5 -0
- package/dist/{spectrum-59LhYG1t.mjs → spectrum-DtNX8WBX.mjs} +2 -3
- package/dist/{speed-CMCfoG3s.mjs → speed-TbkeWV_x.mjs} +3 -5
- package/dist/{sql-MxWaTDdj.mjs → sql-DI319y25.mjs} +1 -1
- package/dist/src-COwxoocl.mjs +2 -0
- package/dist/{src-J3Yss3VM.mjs → src-Dc6ojwUW.mjs} +5 -5
- package/dist/{ssl-DTTFZR9x.mjs → ssl-D0MIzFl2.mjs} +9 -17
- package/dist/startup-profile-CZYtQziF.mjs +2 -0
- package/dist/{startup-profile-bp348qmf.mjs → startup-profile-DlWrt4Fm.mjs} +5 -5
- package/dist/state-B3Uy1jPX.mjs +2 -0
- package/dist/{state-CqAtTENS.mjs → state-DazGSbRx.mjs} +1 -1
- package/dist/{stream-gVG_7si-.mjs → stream-4Mrb8HEo.mjs} +14 -27
- package/dist/tags-BP25qydR.mjs +22 -0
- package/dist/telemetry-CvZean4s.mjs +2 -0
- package/dist/telemetry-DKSJSLtq.mjs +2 -0
- package/dist/{tenant-custom-nameservers-DBmmUcxn.mjs → tenant-custom-nameservers-BzVP85Tq.mjs} +2 -3
- package/dist/{tenant-Qv_PC8gW.mjs → tenant-jmfZqEZ4.mjs} +1 -1
- package/dist/{tools-B1ajcUAF.mjs → tools-C-vmgYSv.mjs} +1 -1
- package/dist/{tunnels-CHNKPYRV.mjs → tunnels-BNswR1Dj.mjs} +4 -6
- package/dist/{turnstile-C60RxPo2.mjs → turnstile-BgsTP2fz.mjs} +2 -3
- package/dist/ui-Bo6DCvbS.mjs +2 -0
- package/dist/{update-check-BHarE3V9.mjs → update-check-BOF1hn_I.mjs} +1 -1
- package/dist/update-check-C7mfEeQ7.mjs +2 -0
- package/dist/update-check-worker.mjs +1 -1
- package/dist/{url-normalization-3t6Xpafi.mjs → url-normalization-Bqrs4-2F.mjs} +2 -3
- package/dist/{url-scanner-DNG__DiK.mjs → url-scanner-Dm4Fps5T.mjs} +1 -1
- package/dist/{user-B4i7OIFK.mjs → user-u_LxzLM4.mjs} +8 -15
- package/dist/{vectorize-y3PCQDDf.mjs → vectorize-DLGiOyd4.mjs} +3 -5
- package/dist/version-DmTuWNZ5.mjs +2 -0
- package/dist/{waiting-rooms-xkZLvPkT.mjs → waiting-rooms-DmgJgJXb.mjs} +4 -7
- package/dist/{web-assets-BlqHZywy.mjs → web-assets-rNhZWP-6.mjs} +7 -13
- package/dist/{web3-DGAJMcLv.mjs → web3-BVBdFt8E.mjs} +3 -5
- package/dist/{workers-cCNBx0Bc.mjs → workers-CjUKJvH8.mjs} +18 -22
- package/dist/{workers-builds-COKp3NfU.mjs → workers-builds-D3Q97l7X.mjs} +1 -1
- package/dist/{workers-for-platforms-CAtiWI_G.mjs → workers-for-platforms-C_fcw30y.mjs} +5 -9
- package/dist/{workers-vpc-ChBfXwPy.mjs → workers-vpc-CnRO3Stc.mjs} +2 -3
- package/dist/{workflows-BYhgJvyR.mjs → workflows-cpHFe5v6.mjs} +5 -9
- package/dist/{wrangler-migration-B12OR2bu.mjs → wrangler-migration-DQehjmoh.mjs} +74 -74
- package/dist/{zaraz-BW0kvRCK.mjs → zaraz-BRj0J7vK.mjs} +1 -1
- package/dist/{zero-trust-DSeWXkNV.mjs → zero-trust-CVZKDLCB.mjs} +75 -149
- package/dist/{zone-B-YJG2UA.mjs → zone-N6ccK70C.mjs} +1 -1
- package/dist/{zones-B8pqPHu8.mjs → zones-C4S_kpGz.mjs} +49 -52
- package/package.json +12 -12
- package/dist/auth-CdEGiJ5Y.mjs +0 -2
- package/dist/auth-DF_ml7rE.mjs +0 -2
- package/dist/build-BJHRK6qE.mjs +0 -2
- package/dist/build-D7s3a8zW.mjs +0 -2
- package/dist/cache-CDPUUv_O.mjs +0 -45
- package/dist/cf-3vj8dGYz.mjs +0 -18
- package/dist/chunk-DSGVRFIS-RUG6Dtqz.mjs +0 -2
- package/dist/containers-CcZHRM9g.mjs +0 -376
- package/dist/delegate-Tgfxa-MZ.mjs +0 -2
- package/dist/deploy-context-DIAl408H.mjs +0 -56
- package/dist/dialog-BnIgdgWi.mjs +0 -2
- package/dist/discover-DEjUARkU.mjs +0 -2
- package/dist/discover-P20XeGBF.mjs +0 -2
- package/dist/dist-CX6dDtzj.mjs +0 -449
- package/dist/dist-DAeCUX-u.mjs +0 -60
- package/dist/dls-CMTrCDjZ.mjs +0 -17
- package/dist/flagship-geGDHp9H.mjs +0 -28
- package/dist/init-C08hBFYn.mjs +0 -43
- package/dist/interactive-pjVqirHx.mjs +0 -2
- package/dist/kv-Cd8vbPWK.mjs +0 -15
- package/dist/local-CFZtOOxg.mjs +0 -2
- package/dist/log-CRbgNbDp.mjs +0 -3
- package/dist/login-C3Bahro9.mjs +0 -5
- package/dist/login-DvsRxI3E.mjs +0 -2
- package/dist/logo-matches-jeNkUxAq.mjs +0 -6
- package/dist/logos-pxN5aumY.mjs +0 -7
- package/dist/managed-defense-C_KLy4oB.mjs +0 -18
- package/dist/matches-DnjBnG-Y.mjs +0 -6
- package/dist/oauth-Cf3-g-kk.mjs +0 -4
- package/dist/output-CpiIVa7Q.mjs +0 -2
- package/dist/previews-oHUiD54J.mjs +0 -7
- package/dist/progress-B1dpmxCT.mjs +0 -2
- package/dist/prompt-Y5OBwDVE.mjs +0 -4
- package/dist/queries-CS0sYfte.mjs +0 -9
- package/dist/request-headers-Bg8_Idw3.mjs +0 -2
- package/dist/run-0EozpORq.mjs +0 -2
- package/dist/run-DKg70Sqf.mjs +0 -2
- package/dist/session-3DgztoAI.mjs +0 -2
- package/dist/shared-o8saqcSK.mjs +0 -2
- package/dist/source-AlTrHNem.mjs +0 -6
- package/dist/spawn-BZd__5sj.mjs +0 -10
- package/dist/startup-profile-DJsOtbVN.mjs +0 -2
- package/dist/state-Dvzl3aSj.mjs +0 -2
- package/dist/submit-wJYcQB8d.mjs +0 -4
- package/dist/tags-BwFKjaOr.mjs +0 -23
- package/dist/telemetry-BczXOpQn.mjs +0 -2
- package/dist/telemetry-CE15pfOU.mjs +0 -2
- package/dist/ui-CBhKUPys.mjs +0 -2
- package/dist/update-check-C3RhhXja.mjs +0 -2
- package/dist/url-info-By6VD20A.mjs +0 -4
- package/dist/version-izjB0Yrl.mjs +0 -2
|
@@ -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-CSH3UMpD.mjs";import{n}from"./auth-BcNLQji1.mjs";import{a as r,t as i}from"./context-DVh8Wyfs.mjs";import{t as a}from"./output-BJEgbI0G.mjs";import{t as o}from"./dry-run-gy0Hl9xo.mjs";import{t as s}from"./progress-CtGsPOpV.mjs";import{t as c}from"./run-DnZGQbq_.mjs";import"./telemetry-CvZean4s.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-YrI7ltMa.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).
|
|
@@ -13,8 +13,7 @@ widget, and where it is used.
|
|
|
13
13
|
`}).option(`region`,{type:`string`,description:`Region where this widget can be used. This cannot be changed after creation.
|
|
14
14
|
`,choices:[`world`,`china`],default:`world`}).coerce(`region`,e=>d(e,`region`,`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 _={command:`create`,describe:`Create a Turnstile Widget`,builder:g,handler:async e=>c({command:`turnstile widgets create`,classification:{safeFlags:[`order`,`direction`,`bot-fight-mode`,`clearance-level`,`ephemeral-id`,`widget-mode`,`offlabel`,`region`,`dry-run`]}},e,async()=>{let c={page:e.page,per_page:e[`per-page`],order:e.order,direction:e.direction,filter:e.filter};if(e.dryRun){let t=await r();o({command:`cf turnstile widgets create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/challenges/widgets`,pathParams:{},query:c,bodyKind:`json`,body:e.body===void 0?u({bot_fight_mode:e[`bot-fight-mode`],clearance_level:e[`clearance-level`],domains:e.domains,ephemeral_id:e[`ephemeral-id`],mode:e[`widget-mode`],name:d(e.name,`name`,`text`),offlabel:e.offlabel,region:e.region}):l(e.body)});return}let m=await n(e),g=e.local?t:await i();if(e.accountId=g,e.body){let t=l(e.body);new URLSearchParams(Object.entries(c).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString();let n=await s(`Creating`,async()=>m.send(h,{body:t,account_id:g,...c}));a(n,{successLabel:`Created`});return}if(e.domains===void 0)throw Error(`--domains is required (or pass --body with this field set).`);e[`widget-mode`]===void 0&&(e[`widget-mode`]=await p(`widget-mode`,`Widget mode`,[`non-interactive`,`invisible`,`managed`])),e.name===void 0&&(e.name=await f(`name`,`Human readable widget name. Not unique. Cloudflare suggests that you set this to a meaningful string to make it easier to identify your widget, and where it is used. `));let _=u({bot_fight_mode:e[`bot-fight-mode`],clearance_level:e[`clearance-level`],domains:e.domains,ephemeral_id:e[`ephemeral-id`],mode:e[`widget-mode`],name:d(e.name,`name`,`text`),offlabel:e.offlabel,region:e.region});new URLSearchParams(Object.entries(c).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString();let v=await s(`Creating`,async()=>m.send(h,{body:_,account_id:g,...c}));a(v,{successLabel:`Created`})})};var v={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/challenges/widgets/${t.sitekey}`};function y(e){return e.usage(`$0 turnstile widgets delete <sitekey>
|
|
15
15
|
|
|
16
|
-
Deletes a Turnstile widget from an account.`).positional(`sitekey`,{type:`string`,description:`Unique identifier for a Turnstile widget.`,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 <sitekey>`,describe:`Delete a Turnstile Widget`,builder:y,handler:async e=>c({command:`turnstile widgets delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){let t=await r();o({command:`cf turnstile widgets delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/challenges/widgets/${e.sitekey==null?`<sitekey>`:encodeURIComponent(String(e.sitekey))}`,pathParams:{sitekey:String(e.sitekey??``)},bodyKind:`none`});return}let c=await n(e),l=e.local?t:await i();if(e.accountId=l,!await m({force:!!e.force})){
|
|
17
|
-
`);return}let u=await s(`Deleting`,async()=>c.send(v,{account_id:l,sitekey:e.sitekey}));a(u,{successLabel:`Deleted`})})};var x={method:`GET`,path:t=>e`/accounts/${t.account_id}/challenges/widgets/${t.sitekey}`};function S(e){return e.usage(`$0 turnstile widgets get <sitekey>
|
|
16
|
+
Deletes a Turnstile widget from an account.`).positional(`sitekey`,{type:`string`,description:`Unique identifier for a Turnstile widget.`,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 <sitekey>`,describe:`Delete a Turnstile Widget`,builder:y,handler:async e=>c({command:`turnstile widgets delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){let t=await r();o({command:`cf turnstile widgets delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/challenges/widgets/${e.sitekey==null?`<sitekey>`:encodeURIComponent(String(e.sitekey))}`,pathParams:{sitekey:String(e.sitekey??``)},bodyKind:`none`});return}let c=await n(e),l=e.local?t:await i();if(e.accountId=l,!await m({force:!!e.force}))return;let u=await s(`Deleting`,async()=>c.send(v,{account_id:l,sitekey:e.sitekey}));a(u,{successLabel:`Deleted`})})};var x={method:`GET`,path:t=>e`/accounts/${t.account_id}/challenges/widgets/${t.sitekey}`};function S(e){return e.usage(`$0 turnstile widgets get <sitekey>
|
|
18
17
|
|
|
19
18
|
Returns the configuration of a Turnstile widget.`).positional(`sitekey`,{type:`string`,description:`Unique identifier for a Turnstile widget.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const C={command:`get <sitekey>`,describe:`Turnstile Widget Details`,builder:S,handler:async e=>c({command:`turnstile widgets get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await r();o({command:`cf turnstile widgets get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/challenges/widgets/${e.sitekey==null?`<sitekey>`:encodeURIComponent(String(e.sitekey))}`,pathParams:{sitekey:String(e.sitekey??``)},bodyKind:`none`});return}let c=await n(e),l=e.local?t:await i();e.accountId=l;let u=await s(`Loading`,async()=>c.send(x,{account_id:l,sitekey:e.sitekey}));a(u,{successLabel:`Loaded`})})};var w={method:`GET`,path:t=>e`/accounts/${t.account_id}/challenges/widgets`,query:[`page`,`per_page`,`order`,`direction`,`filter`]};function T(e){return e.usage(`$0 turnstile widgets list
|
|
20
19
|
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
export{n as getUpdateNotice,r as maybeStartBackgroundUpdateCheck}from"./update-check-
|
|
2
|
+
export{n as getUpdateNotice,r as maybeStartBackgroundUpdateCheck}from"./update-check-C7mfEeQ7.mjs";
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import{r as e,t}from"./rolldown-runtime-BNtqjh-B.mjs";import{n}from"./version-DmTuWNZ5.mjs";import{i as r}from"./cf-fIBhEAxU.mjs";import{r as i,t as a}from"./gt-BQkaDQDq.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-C7mfEeQ7.mjs";await e();export{};
|
|
@@ -1,8 +1,7 @@
|
|
|
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-BcNLQji1.mjs";import{i as n}from"./context-DVh8Wyfs.mjs";import{t as r}from"./output-BJEgbI0G.mjs";import{t as i}from"./dry-run-gy0Hl9xo.mjs";import{t as a}from"./progress-CtGsPOpV.mjs";import{t as o}from"./run-DnZGQbq_.mjs";import"./telemetry-CvZean4s.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-YrI7ltMa.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
|
-
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})){
|
|
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
|
|
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}))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
|
|
6
5
|
|
|
7
6
|
Fetches the current URL Normalization settings.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const _={command:`get`,describe:`Get URL Normalization settings`,builder:g,handler:async e=>o({command:`url-normalization get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf url-normalization get`,method:`GET`,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});e.zoneId=s;let c=await a(`Loading`,async()=>o.send(h,{zone_id:s}));r(c,{successLabel:`Loaded`})})};var v={method:`PUT`,path:t=>e`/zones/${t.zone_id}/url_normalization`,body:`json`};function y(e){return e.usage(`$0 url-normalization update
|
|
8
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"./local-
|
|
2
|
+
import"./api-eMuS5GI1.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{t}from"./local-CSH3UMpD.mjs";import{n}from"./auth-BcNLQji1.mjs";import{a as r,t as i}from"./context-DVh8Wyfs.mjs";import{t as a}from"./output-BJEgbI0G.mjs";import{t as o}from"./dry-run-gy0Hl9xo.mjs";import{t as s}from"./progress-CtGsPOpV.mjs";import{t as c}from"./run-DnZGQbq_.mjs";import"./telemetry-CvZean4s.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-YrI7ltMa.mjs";import{n as m,t as h}from"./raw-fetch-BE3QgdTE.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
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
|
|
|
@@ -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-BcNLQji1.mjs";import{t as i}from"./output-BJEgbI0G.mjs";import{t as a}from"./dry-run-gy0Hl9xo.mjs";import{t as o}from"./progress-CtGsPOpV.mjs";import{t as s}from"./run-DnZGQbq_.mjs";import"./telemetry-CvZean4s.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-YrI7ltMa.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
|
|
|
@@ -11,8 +11,7 @@ Edit part of your user details.`).option(`country`,{type:`string`,description:`T
|
|
|
11
11
|
|
|
12
12
|
Creates a new IP Access rule for all zones owned by the current user. Note: To create an IP Access rule that applies to a specific zone, refer to the [IP Access rules for a zone](#ip-access-rules-for-a-zone) endpoints.`).option(`configuration-target`,{type:`string`,description:"The configuration target. You must set the target to `ip` when specifying an IP address in the rule.",choices:[`ip`,`ip6`,`ip_range`,`asn`,`country`]}).coerce(`configuration-target`,e=>f(e,`configuration-target`,`text`)).option(`configuration-value`,{type:`string`,description:`The IP address to match. This address will be compared to the IP address of incoming requests.`}).option(`access-rule-mode`,{type:`string`,description:`The action to apply to a matched request.`,choices:[`block`,`challenge`,`whitelist`,`js_challenge`,`managed_challenge`]}).coerce(`access-rule-mode`,e=>f(e,`access-rule-mode`,`text`)).option(`notes`,{type:`string`,description:`An informative summary of the rule, typically used as a reminder or explanation.`,default:``}).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 he={command:`create`,describe:`Create an IP Access rule`,builder:me,handler:async e=>s({command:`user firewall access-rules create`,classification:{safeFlags:[`configuration-target`,`access-rule-mode`,`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf user firewall access-rules create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/user/firewall/access_rules/rules`,pathParams:{},bodyKind:`json`,body:e.body===void 0?d({configuration:{target:e[`configuration-target`],value:f(e[`configuration-value`],`configuration-value`,`text`)},mode:e[`access-rule-mode`],notes:f(e.notes,`notes`,`text`)}):l(e.body)});return}let t=await n(e);if(e.body){let n=l(e.body),r=await o(`Creating`,async()=>t.send(v,{body:n}));i(r,{successLabel:`Created`});return}e[`access-rule-mode`]===void 0&&(e[`access-rule-mode`]=await m(`access-rule-mode`,`The action to apply to a matched request.`,[`block`,`challenge`,`whitelist`,`js_challenge`,`managed_challenge`]));let r=d({configuration:{target:e[`configuration-target`],value:f(e[`configuration-value`],`configuration-value`,`text`)},mode:e[`access-rule-mode`],notes:f(e.notes,`notes`,`text`)}),s=await o(`Creating`,async()=>t.send(v,{body:r}));i(s,{successLabel:`Created`})})};var y={method:`DELETE`,path:t=>e`/user/firewall/access_rules/rules/${t.rule_id}`};function b(e){return e.usage(`$0 user firewall access-rules delete <rule-id>
|
|
13
13
|
|
|
14
|
-
Deletes an IP Access rule at the user level. Note: Deleting a user-level rule will affect all zones owned by the user.`).positional(`rule-id`,{type:`string`,description:`Unique identifier for a rule.`,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 x={command:`delete <rule-id>`,describe:`Delete an IP Access rule`,builder:b,handler:async e=>s({command:`user firewall access-rules delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){a({command:`cf user firewall access-rules delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/user/firewall/access_rules/rules/${e[`rule-id`]==null?`<rule-id>`:encodeURIComponent(String(e[`rule-id`]))}`,pathParams:{"rule-id":String(e[`rule-id`]??``)},bodyKind:`none`});return}let t=await n(e);if(!await h({force:!!e.force,message:`This operation deletes the user-level IP Access Rule and affects every zone owned by the user.`})){
|
|
15
|
-
`);return}let r=await o(`Deleting`,async()=>t.send(y,{rule_id:e[`rule-id`]}));i(r,{successLabel:`Deleted`})})};var S={method:`PATCH`,path:t=>e`/user/firewall/access_rules/rules/${t.rule_id}`,body:`json`};function C(e){return e.usage(`$0 user firewall access-rules edit <rule-id>
|
|
14
|
+
Deletes an IP Access rule at the user level. Note: Deleting a user-level rule will affect all zones owned by the user.`).positional(`rule-id`,{type:`string`,description:`Unique identifier for a rule.`,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 x={command:`delete <rule-id>`,describe:`Delete an IP Access rule`,builder:b,handler:async e=>s({command:`user firewall access-rules delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){a({command:`cf user firewall access-rules delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/user/firewall/access_rules/rules/${e[`rule-id`]==null?`<rule-id>`:encodeURIComponent(String(e[`rule-id`]))}`,pathParams:{"rule-id":String(e[`rule-id`]??``)},bodyKind:`none`});return}let t=await n(e);if(!await h({force:!!e.force,message:`This operation deletes the user-level IP Access Rule and affects every zone owned by the user.`}))return;let r=await o(`Deleting`,async()=>t.send(y,{rule_id:e[`rule-id`]}));i(r,{successLabel:`Deleted`})})};var S={method:`PATCH`,path:t=>e`/user/firewall/access_rules/rules/${t.rule_id}`,body:`json`};function C(e){return e.usage(`$0 user firewall access-rules edit <rule-id>
|
|
16
15
|
|
|
17
16
|
Updates an IP Access rule defined at the user level. You can only update the rule action (\`mode\` parameter) and notes.`).positional(`rule-id`,{type:`string`,description:`Unique identifier for a rule.`,demandOption:!0}).option(`access-rule-mode`,{type:`string`,description:`The action to apply to a matched request.`,choices:[`block`,`challenge`,`whitelist`,`js_challenge`,`managed_challenge`]}).coerce(`access-rule-mode`,e=>f(e,`access-rule-mode`,`text`)).option(`notes`,{type:`string`,description:`An informative summary of the rule, typically used as a reminder or explanation.`}).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:`edit <rule-id>`,describe:`Update an IP Access rule`,builder:C,handler:async e=>s({command:`user firewall access-rules edit`,classification:{safeFlags:[`access-rule-mode`,`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf user firewall access-rules edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/user/firewall/access_rules/rules/${e[`rule-id`]==null?`<rule-id>`:encodeURIComponent(String(e[`rule-id`]))}`,pathParams:{"rule-id":String(e[`rule-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({mode:e[`access-rule-mode`],notes:f(e.notes,`notes`,`text`)}):l(e.body)});return}let t=await n(e);if(e.body){let n=l(e.body),r=await o(`Updating`,async()=>t.send(S,{body:n,rule_id:e[`rule-id`]}));i(r,{successLabel:`Updated`});return}let r=d({mode:e[`access-rule-mode`],notes:f(e.notes,`notes`,`text`)}),s=await o(`Updating`,async()=>t.send(S,{body:r,rule_id:e[`rule-id`]}));i(s,{successLabel:`Updated`})})};var T={method:`GET`,path:t=>e`/user/firewall/access_rules/rules/${t.rule_id}`};function E(e){return e.usage(`$0 user firewall access-rules get <rule-id>
|
|
18
17
|
|
|
@@ -31,8 +30,7 @@ Responds to an invitation.`).positional(`invite-id`,{type:`string`,description:`
|
|
|
31
30
|
|
|
32
31
|
Create a configured monitor.`).option(`allow-insecure`,{type:`boolean`,description:`Do not validate the certificate when monitor use HTTPS. This parameter is currently only valid for HTTP and HTTPS monitors.`,default:!1}).option(`consecutive-down`,{type:`number`,description:`To be marked unhealthy the monitored origin must fail this healthcheck N consecutive times.`}).option(`consecutive-up`,{type:`number`,description:`To be marked healthy the monitored origin must pass this healthcheck N consecutive times.`}).option(`description`,{type:`string`,description:`Object description.`,default:``}).option(`expected-body`,{type:`string`,description:`A case-insensitive sub-string to look for in the response body. If this string is not found, the origin will be marked as unhealthy. This parameter is only valid for HTTP and HTTPS monitors.`,default:``}).option(`expected-codes`,{type:`string`,description:`The expected HTTP response code or code range of the health check. This parameter is only valid for HTTP and HTTPS monitors.`,default:``}).option(`follow-redirects`,{type:`boolean`,description:`Follow redirects if returned by the origin. This parameter is only valid for HTTP and HTTPS monitors.`,default:!1}).option(`header`,{type:`string`,description:`The HTTP request headers to send in the health check. It is recommended you set a Host header by default. The User-Agent header cannot be overridden. This parameter is only valid for HTTP and HTTPS monitors. Provide as a JSON object or @path/to/file.json.`}).option(`interval`,{type:`number`,description:`The interval between each health check. Shorter intervals may improve failover time, but will increase load on the origins as we check from multiple locations.`,default:60}).option(`method`,{type:`string`,description:`The method to use for the health check. This defaults to 'GET' for HTTP/HTTPS based checks and 'connection_established' for TCP based health checks.`}).option(`path`,{type:`string`,description:`The endpoint path you want to conduct a health check against. This parameter is only valid for HTTP and HTTPS monitors.`}).option(`port`,{type:`number`,description:`The port number to connect to for the health check. Required for TCP, UDP, and SMTP checks. HTTP and HTTPS checks should only define the port when using a non-standard port (HTTP: default 80, HTTPS: default 443).`}).option(`probe-zone`,{type:`string`,description:`Assign this monitor to emulate the specified zone while probing. This parameter is only valid for HTTP and HTTPS monitors.`,default:``}).option(`retries`,{type:`number`,description:`The number of retries to attempt in case of a timeout before marking the origin as unhealthy. Retries are attempted immediately.`,default:2}).option(`timeout`,{type:`number`,description:`The timeout (in seconds) before marking the health check as failed.`,default:5}).option(`type`,{type:`string`,description:`The protocol to use for the health check. Currently supported protocols are 'HTTP','HTTPS', 'TCP', 'ICMP-PING', 'UDP-ICMP', and 'SMTP'.`,choices:[`http`,`https`,`tcp`,`udp_icmp`,`icmp_ping`,`smtp`],default:`http`}).coerce(`type`,e=>f(e,`type`,`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 Se={command:`create`,describe:`Create Monitor`,builder:xe,handler:async e=>s({command:`user load-balancers monitors create`,classification:{safeFlags:[`allow-insecure`,`follow-redirects`,`type`,`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf user load-balancers monitors create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/user/load_balancers/monitors`,pathParams:{},bodyKind:`json`,body:e.body===void 0?d({allow_insecure:e[`allow-insecure`],consecutive_down:e[`consecutive-down`],consecutive_up:e[`consecutive-up`],description:f(e.description,`description`,`text`),expected_body:f(e[`expected-body`],`expected-body`,`text`),expected_codes:f(e[`expected-codes`],`expected-codes`,`text`),follow_redirects:e[`follow-redirects`],header:u(e.header,`header`),interval:e.interval,method:f(e.method,`method`,`text`),path:f(e.path,`path`,`text`),port:e.port,probe_zone:f(e[`probe-zone`],`probe-zone`,`text`),retries:e.retries,timeout:e.timeout,type:e.type},[[`header`]]):l(e.body)});return}let t=await n(e);if(e.body){let n=l(e.body),r=await o(`Creating`,async()=>t.send(B,{body:n}));i(r,{successLabel:`Created`});return}let r=d({allow_insecure:e[`allow-insecure`],consecutive_down:e[`consecutive-down`],consecutive_up:e[`consecutive-up`],description:f(e.description,`description`,`text`),expected_body:f(e[`expected-body`],`expected-body`,`text`),expected_codes:f(e[`expected-codes`],`expected-codes`,`text`),follow_redirects:e[`follow-redirects`],header:u(e.header,`header`),interval:e.interval,method:f(e.method,`method`,`text`),path:f(e.path,`path`,`text`),port:e.port,probe_zone:f(e[`probe-zone`],`probe-zone`,`text`),retries:e.retries,timeout:e.timeout,type:e.type},[[`header`]]),s=await o(`Creating`,async()=>t.send(B,{body:r}));i(s,{successLabel:`Created`})})};var Ce={method:`DELETE`,path:t=>e`/user/load_balancers/monitors/${t.monitor_id}`};function we(e){return e.usage(`$0 user load-balancers monitors delete <monitor-id>
|
|
33
32
|
|
|
34
|
-
Delete a configured monitor.`).positional(`monitor-id`,{type:`string`,description:`Monitor ID`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const Te={command:`delete <monitor-id>`,describe:`Delete Monitor`,builder:we,handler:async e=>s({command:`user load-balancers monitors delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){a({command:`cf user load-balancers monitors delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/user/load_balancers/monitors/${e[`monitor-id`]==null?`<monitor-id>`:encodeURIComponent(String(e[`monitor-id`]))}`,pathParams:{"monitor-id":String(e[`monitor-id`]??``)},bodyKind:`none`});return}let t=await n(e);if(!await h({force:!!e.force})){
|
|
35
|
-
`);return}let r=await o(`Deleting`,async()=>t.send(Ce,{monitor_id:e[`monitor-id`]}));i(r,{successLabel:`Deleted`})})};var V={method:`PATCH`,path:t=>e`/user/load_balancers/monitors/${t.monitor_id}`,body:`json`};function Ee(e){return e.usage(`$0 user load-balancers monitors edit <monitor-id>
|
|
33
|
+
Delete a configured monitor.`).positional(`monitor-id`,{type:`string`,description:`Monitor ID`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const Te={command:`delete <monitor-id>`,describe:`Delete Monitor`,builder:we,handler:async e=>s({command:`user load-balancers monitors delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){a({command:`cf user load-balancers monitors delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/user/load_balancers/monitors/${e[`monitor-id`]==null?`<monitor-id>`:encodeURIComponent(String(e[`monitor-id`]))}`,pathParams:{"monitor-id":String(e[`monitor-id`]??``)},bodyKind:`none`});return}let t=await n(e);if(!await h({force:!!e.force}))return;let r=await o(`Deleting`,async()=>t.send(Ce,{monitor_id:e[`monitor-id`]}));i(r,{successLabel:`Deleted`})})};var V={method:`PATCH`,path:t=>e`/user/load_balancers/monitors/${t.monitor_id}`,body:`json`};function Ee(e){return e.usage(`$0 user load-balancers monitors edit <monitor-id>
|
|
36
34
|
|
|
37
35
|
Apply changes to an existing monitor, overwriting the supplied properties.`).positional(`monitor-id`,{type:`string`,description:`Monitor ID`,demandOption:!0}).option(`allow-insecure`,{type:`boolean`,description:`Do not validate the certificate when monitor use HTTPS. This parameter is currently only valid for HTTP and HTTPS monitors.`}).option(`consecutive-down`,{type:`number`,description:`To be marked unhealthy the monitored origin must fail this healthcheck N consecutive times.`}).option(`consecutive-up`,{type:`number`,description:`To be marked healthy the monitored origin must pass this healthcheck N consecutive times.`}).option(`description`,{type:`string`,description:`Object description.`}).option(`expected-body`,{type:`string`,description:`A case-insensitive sub-string to look for in the response body. If this string is not found, the origin will be marked as unhealthy. This parameter is only valid for HTTP and HTTPS monitors.`}).option(`expected-codes`,{type:`string`,description:`The expected HTTP response code or code range of the health check. This parameter is only valid for HTTP and HTTPS monitors.`}).option(`follow-redirects`,{type:`boolean`,description:`Follow redirects if returned by the origin. This parameter is only valid for HTTP and HTTPS monitors.`}).option(`header`,{type:`string`,description:`The HTTP request headers to send in the health check. It is recommended you set a Host header by default. The User-Agent header cannot be overridden. This parameter is only valid for HTTP and HTTPS monitors. Provide as a JSON object or @path/to/file.json.`}).option(`interval`,{type:`number`,description:`The interval between each health check. Shorter intervals may improve failover time, but will increase load on the origins as we check from multiple locations.`}).option(`method`,{type:`string`,description:`The method to use for the health check. This defaults to 'GET' for HTTP/HTTPS based checks and 'connection_established' for TCP based health checks.`}).option(`path`,{type:`string`,description:`The endpoint path you want to conduct a health check against. This parameter is only valid for HTTP and HTTPS monitors.`}).option(`port`,{type:`number`,description:`The port number to connect to for the health check. Required for TCP, UDP, and SMTP checks. HTTP and HTTPS checks should only define the port when using a non-standard port (HTTP: default 80, HTTPS: default 443).`}).option(`probe-zone`,{type:`string`,description:`Assign this monitor to emulate the specified zone while probing. This parameter is only valid for HTTP and HTTPS monitors.`}).option(`retries`,{type:`number`,description:`The number of retries to attempt in case of a timeout before marking the origin as unhealthy. Retries are attempted immediately.`}).option(`timeout`,{type:`number`,description:`The timeout (in seconds) before marking the health check as failed.`}).option(`type`,{type:`string`,description:`The protocol to use for the health check. Currently supported protocols are 'HTTP','HTTPS', 'TCP', 'ICMP-PING', 'UDP-ICMP', and 'SMTP'.`,choices:[`http`,`https`,`tcp`,`udp_icmp`,`icmp_ping`,`smtp`]}).coerce(`type`,e=>f(e,`type`,`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:`edit <monitor-id>`,describe:`Patch Monitor`,builder:Ee,handler:async e=>s({command:`user load-balancers monitors edit`,classification:{safeFlags:[`allow-insecure`,`follow-redirects`,`type`,`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf user load-balancers monitors edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/user/load_balancers/monitors/${e[`monitor-id`]==null?`<monitor-id>`:encodeURIComponent(String(e[`monitor-id`]))}`,pathParams:{"monitor-id":String(e[`monitor-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({allow_insecure:e[`allow-insecure`],consecutive_down:e[`consecutive-down`],consecutive_up:e[`consecutive-up`],description:f(e.description,`description`,`text`),expected_body:f(e[`expected-body`],`expected-body`,`text`),expected_codes:f(e[`expected-codes`],`expected-codes`,`text`),follow_redirects:e[`follow-redirects`],header:u(e.header,`header`),interval:e.interval,method:f(e.method,`method`,`text`),path:f(e.path,`path`,`text`),port:e.port,probe_zone:f(e[`probe-zone`],`probe-zone`,`text`),retries:e.retries,timeout:e.timeout,type:e.type},[[`header`]]):l(e.body)});return}let t=await n(e);if(e.body){let n=l(e.body),r=await o(`Updating`,async()=>t.send(V,{body:n,monitor_id:e[`monitor-id`]}));i(r,{successLabel:`Updated`});return}let r=d({allow_insecure:e[`allow-insecure`],consecutive_down:e[`consecutive-down`],consecutive_up:e[`consecutive-up`],description:f(e.description,`description`,`text`),expected_body:f(e[`expected-body`],`expected-body`,`text`),expected_codes:f(e[`expected-codes`],`expected-codes`,`text`),follow_redirects:e[`follow-redirects`],header:u(e.header,`header`),interval:e.interval,method:f(e.method,`method`,`text`),path:f(e.path,`path`,`text`),port:e.port,probe_zone:f(e[`probe-zone`],`probe-zone`,`text`),retries:e.retries,timeout:e.timeout,type:e.type},[[`header`]]),s=await o(`Updating`,async()=>t.send(V,{body:r,monitor_id:e[`monitor-id`]}));i(s,{successLabel:`Updated`})})};var Oe={method:`GET`,path:t=>e`/user/load_balancers/monitors/${t.monitor_id}`};function ke(e){return e.usage(`$0 user load-balancers monitors get <monitor-id>
|
|
38
36
|
|
|
@@ -48,8 +46,7 @@ Modify a configured monitor.`).positional(`monitor-id`,{type:`string`,descriptio
|
|
|
48
46
|
|
|
49
47
|
Create a new pool.`).option(`check-regions`,{type:`string`,array:!0,description:`A list of regions from which to run health checks. Null means every Cloudflare data center.`}).option(`description`,{type:`string`,description:`A human-readable description of the pool.`,default:``}).option(`enabled`,{type:`boolean`,description:`Whether to enable (the default) or disable this pool. Disabled pools will not receive traffic and are excluded from health checks. Disabling a pool will cause any load balancers using it to failover to the next pool (if any).`,default:!0}).option(`health-sources`,{type:`string`,array:!0,description:`A list of health sources, ordered from highest to lowest priority, used to evaluate individual origin health and overall pool health. The load balancer uses the first source that has data and falls back to the next. Currently accepted values are null or the exact array ["regional", "global"]; any other combination is rejected. Null (the default) behaves like ["local", "global"]. ["regional", "global"] makes each region steer on its own health, falling back to the global decision when a region has no fresh data. Setting regional requires at least one region in check_regions.`}).option(`latitude`,{type:`number`,description:`The latitude of the data center containing the origins used in this pool in decimal degrees. If this is set, longitude must also be set.`}).option(`load-shedding-default-percent`,{type:`number`,description:`The percent of traffic to shed from the pool, according to the default policy. Applies to new sessions and traffic without session affinity.`}).option(`load-shedding-default-policy`,{type:`string`,description:`The default policy to use when load shedding. A random policy randomly sheds a given percent of requests. A hash policy computes a hash over the CF-Connecting-IP address and sheds all requests originating from a percent of IPs.`,choices:[`random`,`hash`]}).coerce(`load-shedding-default-policy`,e=>f(e,`load-shedding-default-policy`,`text`)).option(`load-shedding-session-percent`,{type:`number`,description:`The percent of existing sessions to shed from the pool, according to the session policy.`}).option(`load-shedding-session-policy`,{type:`string`,description:`Only the hash policy is supported for existing sessions (to avoid exponential decay).`,choices:[`hash`]}).coerce(`load-shedding-session-policy`,e=>f(e,`load-shedding-session-policy`,`text`)).option(`longitude`,{type:`number`,description:`The longitude of the data center containing the origins used in this pool in decimal degrees. If this is set, latitude must also be set.`}).option(`minimum-origins`,{type:`number`,description:`The minimum number of origins that must be healthy for this pool to serve traffic. If the number of healthy origins falls below this number, the pool will be marked unhealthy and will failover to the next available pool.`,default:1}).option(`monitor`,{type:`string`,description:`The ID of the Monitor to use for checking the health of origins within this pool.`}).option(`monitor-group`,{type:`string`,description:`The ID of the Monitor Group to use for checking the health of origins within this pool.`}).option(`name`,{type:`string`,description:`A short name (tag) for the pool. Only alphanumeric characters, hyphens, and underscores are allowed.`}).option(`networks`,{type:`string`,array:!0,description:`List of networks where Load Balancer or Pool is enabled.`}).option(`notification-email`,{type:`string`,description:`This field is now deprecated. It has been moved to Cloudflare's Centralized Notification service https://developers.cloudflare.com/fundamentals/notifications/. The email address to send health status notifications to. This can be an individual mailbox or a mailing list. Multiple emails can be supplied as a comma delimited list.`,default:``}).option(`notification-filter-origin-disable`,{type:`boolean`,description:`If set true, disable notifications for this type of resource (pool or origin).`}).option(`notification-filter-origin-healthy`,{type:`boolean`,description:`If present, send notifications only for this health status (e.g. false for only DOWN events). Use null to reset (all events).`}).option(`notification-filter-pool-disable`,{type:`boolean`,description:`If set true, disable notifications for this type of resource (pool or origin).`}).option(`notification-filter-pool-healthy`,{type:`boolean`,description:`If present, send notifications only for this health status (e.g. false for only DOWN events). Use null to reset (all events).`}).option(`origin-steering-policy`,{type:`string`,description:'The type of origin steering policy to use.\n- `"random"`: Select an origin randomly.\n- `"hash"`: Select an origin by computing a hash over the CF-Connecting-IP address.\n- `"least_outstanding_requests"`: Select an origin by taking into consideration origin weights, as well as each origin\'s number of outstanding requests. Origins with more pending requests are weighted proportionately less relative to others.\n- `"least_connections"`: Select an origin by taking into consideration origin weights, as well as each origin\'s number of open connections. Origins with more open connections are weighted proportionately less relative to others. Supported for HTTP/1 and HTTP/2 connections.',choices:[`random`,`hash`,`least_outstanding_requests`,`least_connections`]}).coerce(`origin-steering-policy`,e=>f(e,`origin-steering-policy`,`text`)).option(`origins`,{type:`string`,description:`The list of origins within this pool. Traffic directed at this pool is balanced across all currently healthy origins, provided the pool itself is healthy. Provide as a JSON array of objects or @path/to/file.json.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const Ge={command:`create`,describe:`Create Pool`,builder:We,handler:async e=>s({command:`user load-balancers pools create`,classification:{safeFlags:[`enabled`,`load-shedding-default-policy`,`load-shedding-session-policy`,`notification-filter-origin-disable`,`notification-filter-origin-healthy`,`notification-filter-pool-disable`,`notification-filter-pool-healthy`,`origin-steering-policy`,`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf user load-balancers pools create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/user/load_balancers/pools`,pathParams:{},bodyKind:`json`,body:e.body===void 0?d({check_regions:e[`check-regions`],description:f(e.description,`description`,`text`),enabled:e.enabled,health_sources:e[`health-sources`],latitude:e.latitude,load_shedding:{default_percent:e[`load-shedding-default-percent`],default_policy:e[`load-shedding-default-policy`],session_percent:e[`load-shedding-session-percent`],session_policy:e[`load-shedding-session-policy`]},longitude:e.longitude,minimum_origins:e[`minimum-origins`],monitor:f(e.monitor,`monitor`,`text`),monitor_group:f(e[`monitor-group`],`monitor-group`,`text`),name:f(e.name,`name`,`text`),networks:e.networks,notification_email:f(e[`notification-email`],`notification-email`,`text`),notification_filter:{origin:{disable:e[`notification-filter-origin-disable`],healthy:e[`notification-filter-origin-healthy`]},pool:{disable:e[`notification-filter-pool-disable`],healthy:e[`notification-filter-pool-healthy`]}},origin_steering:{policy:e[`origin-steering-policy`]},origins:c(e.origins,`origins`)}):l(e.body)});return}let t=await n(e);if(e.body){let n=l(e.body),r=await o(`Creating`,async()=>t.send(W,{body:n}));i(r,{successLabel:`Created`});return}if(e.name===void 0&&(e.name=await p(`name`,`A short name (tag) for the pool. Only alphanumeric characters, hyphens, and underscores are allowed.`)),e.origins===void 0)throw Error(`--origins is required (or pass --body with this field set).`);let r=d({check_regions:e[`check-regions`],description:f(e.description,`description`,`text`),enabled:e.enabled,health_sources:e[`health-sources`],latitude:e.latitude,load_shedding:{default_percent:e[`load-shedding-default-percent`],default_policy:e[`load-shedding-default-policy`],session_percent:e[`load-shedding-session-percent`],session_policy:e[`load-shedding-session-policy`]},longitude:e.longitude,minimum_origins:e[`minimum-origins`],monitor:f(e.monitor,`monitor`,`text`),monitor_group:f(e[`monitor-group`],`monitor-group`,`text`),name:f(e.name,`name`,`text`),networks:e.networks,notification_email:f(e[`notification-email`],`notification-email`,`text`),notification_filter:{origin:{disable:e[`notification-filter-origin-disable`],healthy:e[`notification-filter-origin-healthy`]},pool:{disable:e[`notification-filter-pool-disable`],healthy:e[`notification-filter-pool-healthy`]}},origin_steering:{policy:e[`origin-steering-policy`]},origins:c(e.origins,`origins`)}),s=await o(`Creating`,async()=>t.send(W,{body:r}));i(s,{successLabel:`Created`})})};var Ke={method:`DELETE`,path:t=>e`/user/load_balancers/pools/${t.pool_id}`};function qe(e){return e.usage(`$0 user load-balancers pools delete <pool-id>
|
|
50
48
|
|
|
51
|
-
Delete a configured pool.`).positional(`pool-id`,{type:`string`,description:`Pool ID`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const Je={command:`delete <pool-id>`,describe:`Delete Pool`,builder:qe,handler:async e=>s({command:`user load-balancers pools delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){a({command:`cf user load-balancers pools delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/user/load_balancers/pools/${e[`pool-id`]==null?`<pool-id>`:encodeURIComponent(String(e[`pool-id`]))}`,pathParams:{"pool-id":String(e[`pool-id`]??``)},bodyKind:`none`});return}let t=await n(e);if(!await h({force:!!e.force})){
|
|
52
|
-
`);return}let r=await o(`Deleting`,async()=>t.send(Ke,{pool_id:e[`pool-id`]}));i(r,{successLabel:`Deleted`})})};var G={method:`PATCH`,path:t=>e`/user/load_balancers/pools/${t.pool_id}`,body:`json`};function Ye(e){return e.usage(`$0 user load-balancers pools edit pools pool <pool-id>
|
|
49
|
+
Delete a configured pool.`).positional(`pool-id`,{type:`string`,description:`Pool ID`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const Je={command:`delete <pool-id>`,describe:`Delete Pool`,builder:qe,handler:async e=>s({command:`user load-balancers pools delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){a({command:`cf user load-balancers pools delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/user/load_balancers/pools/${e[`pool-id`]==null?`<pool-id>`:encodeURIComponent(String(e[`pool-id`]))}`,pathParams:{"pool-id":String(e[`pool-id`]??``)},bodyKind:`none`});return}let t=await n(e);if(!await h({force:!!e.force}))return;let r=await o(`Deleting`,async()=>t.send(Ke,{pool_id:e[`pool-id`]}));i(r,{successLabel:`Deleted`})})};var G={method:`PATCH`,path:t=>e`/user/load_balancers/pools/${t.pool_id}`,body:`json`};function Ye(e){return e.usage(`$0 user load-balancers pools edit pools pool <pool-id>
|
|
53
50
|
|
|
54
51
|
Apply changes to an existing pool, overwriting the supplied properties.`).positional(`pool-id`,{type:`string`,description:`Pool ID`,demandOption:!0}).option(`check-regions`,{type:`string`,array:!0,description:`A list of regions from which to run health checks. Null means every Cloudflare data center.`}).option(`description`,{type:`string`,description:`A human-readable description of the pool.`}).option(`enabled`,{type:`boolean`,description:`Whether to enable (the default) or disable this pool. Disabled pools will not receive traffic and are excluded from health checks. Disabling a pool will cause any load balancers using it to failover to the next pool (if any).`}).option(`health-sources`,{type:`string`,array:!0,description:`A list of health sources, ordered from highest to lowest priority, used to evaluate individual origin health and overall pool health. The load balancer uses the first source that has data and falls back to the next. Currently accepted values are null or the exact array ["regional", "global"]; any other combination is rejected. Null (the default) behaves like ["local", "global"]. ["regional", "global"] makes each region steer on its own health, falling back to the global decision when a region has no fresh data. Setting regional requires at least one region in check_regions.`}).option(`latitude`,{type:`number`,description:`The latitude of the data center containing the origins used in this pool in decimal degrees. If this is set, longitude must also be set.`}).option(`load-shedding-default-percent`,{type:`number`,description:`The percent of traffic to shed from the pool, according to the default policy. Applies to new sessions and traffic without session affinity.`}).option(`load-shedding-default-policy`,{type:`string`,description:`The default policy to use when load shedding. A random policy randomly sheds a given percent of requests. A hash policy computes a hash over the CF-Connecting-IP address and sheds all requests originating from a percent of IPs.`,choices:[`random`,`hash`]}).coerce(`load-shedding-default-policy`,e=>f(e,`load-shedding-default-policy`,`text`)).option(`load-shedding-session-percent`,{type:`number`,description:`The percent of existing sessions to shed from the pool, according to the session policy.`}).option(`load-shedding-session-policy`,{type:`string`,description:`Only the hash policy is supported for existing sessions (to avoid exponential decay).`,choices:[`hash`]}).coerce(`load-shedding-session-policy`,e=>f(e,`load-shedding-session-policy`,`text`)).option(`longitude`,{type:`number`,description:`The longitude of the data center containing the origins used in this pool in decimal degrees. If this is set, latitude must also be set.`}).option(`minimum-origins`,{type:`number`,description:`The minimum number of origins that must be healthy for this pool to serve traffic. If the number of healthy origins falls below this number, the pool will be marked unhealthy and will failover to the next available pool.`}).option(`monitor`,{type:`string`,description:`The ID of the Monitor to use for checking the health of origins within this pool.`}).option(`monitor-group`,{type:`string`,description:`The ID of the Monitor Group to use for checking the health of origins within this pool.`}).option(`name`,{type:`string`,description:`A short name (tag) for the pool. Only alphanumeric characters, hyphens, and underscores are allowed.`}).option(`notification-email`,{type:`string`,description:`This field is now deprecated. It has been moved to Cloudflare's Centralized Notification service https://developers.cloudflare.com/fundamentals/notifications/. The email address to send health status notifications to. This can be an individual mailbox or a mailing list. Multiple emails can be supplied as a comma delimited list.`}).option(`notification-filter-origin-disable`,{type:`boolean`,description:`If set true, disable notifications for this type of resource (pool or origin).`}).option(`notification-filter-origin-healthy`,{type:`boolean`,description:`If present, send notifications only for this health status (e.g. false for only DOWN events). Use null to reset (all events).`}).option(`notification-filter-pool-disable`,{type:`boolean`,description:`If set true, disable notifications for this type of resource (pool or origin).`}).option(`notification-filter-pool-healthy`,{type:`boolean`,description:`If present, send notifications only for this health status (e.g. false for only DOWN events). Use null to reset (all events).`}).option(`origin-steering-policy`,{type:`string`,description:'The type of origin steering policy to use.\n- `"random"`: Select an origin randomly.\n- `"hash"`: Select an origin by computing a hash over the CF-Connecting-IP address.\n- `"least_outstanding_requests"`: Select an origin by taking into consideration origin weights, as well as each origin\'s number of outstanding requests. Origins with more pending requests are weighted proportionately less relative to others.\n- `"least_connections"`: Select an origin by taking into consideration origin weights, as well as each origin\'s number of open connections. Origins with more open connections are weighted proportionately less relative to others. Supported for HTTP/1 and HTTP/2 connections.',choices:[`random`,`hash`,`least_outstanding_requests`,`least_connections`]}).coerce(`origin-steering-policy`,e=>f(e,`origin-steering-policy`,`text`)).option(`origins`,{type:`string`,description:`The list of origins within this pool. Traffic directed at this pool is balanced across all currently healthy origins, provided the pool itself is healthy. Provide as a JSON array of objects or @path/to/file.json.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const Xe={command:`pool <pool-id>`,describe:`Patch Pool`,builder:Ye,handler:async e=>s({command:`user load-balancers pools edit pools pool`,classification:{safeFlags:[`enabled`,`load-shedding-default-policy`,`load-shedding-session-policy`,`notification-filter-origin-disable`,`notification-filter-origin-healthy`,`notification-filter-pool-disable`,`notification-filter-pool-healthy`,`origin-steering-policy`,`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf user load-balancers pools edit pools pool`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/user/load_balancers/pools/${e[`pool-id`]==null?`<pool-id>`:encodeURIComponent(String(e[`pool-id`]))}`,pathParams:{"pool-id":String(e[`pool-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({check_regions:e[`check-regions`],description:f(e.description,`description`,`text`),enabled:e.enabled,health_sources:e[`health-sources`],latitude:e.latitude,load_shedding:{default_percent:e[`load-shedding-default-percent`],default_policy:e[`load-shedding-default-policy`],session_percent:e[`load-shedding-session-percent`],session_policy:e[`load-shedding-session-policy`]},longitude:e.longitude,minimum_origins:e[`minimum-origins`],monitor:f(e.monitor,`monitor`,`text`),monitor_group:f(e[`monitor-group`],`monitor-group`,`text`),name:f(e.name,`name`,`text`),notification_email:f(e[`notification-email`],`notification-email`,`text`),notification_filter:{origin:{disable:e[`notification-filter-origin-disable`],healthy:e[`notification-filter-origin-healthy`]},pool:{disable:e[`notification-filter-pool-disable`],healthy:e[`notification-filter-pool-healthy`]}},origin_steering:{policy:e[`origin-steering-policy`]},origins:c(e.origins,`origins`)}):l(e.body)});return}let t=await n(e);if(e.body){let n=l(e.body),r=await o(`Updating`,async()=>t.send(G,{body:n,pool_id:e[`pool-id`]}));i(r,{successLabel:`Updated`});return}let r=d({check_regions:e[`check-regions`],description:f(e.description,`description`,`text`),enabled:e.enabled,health_sources:e[`health-sources`],latitude:e.latitude,load_shedding:{default_percent:e[`load-shedding-default-percent`],default_policy:e[`load-shedding-default-policy`],session_percent:e[`load-shedding-session-percent`],session_policy:e[`load-shedding-session-policy`]},longitude:e.longitude,minimum_origins:e[`minimum-origins`],monitor:f(e.monitor,`monitor`,`text`),monitor_group:f(e[`monitor-group`],`monitor-group`,`text`),name:f(e.name,`name`,`text`),notification_email:f(e[`notification-email`],`notification-email`,`text`),notification_filter:{origin:{disable:e[`notification-filter-origin-disable`],healthy:e[`notification-filter-origin-healthy`]},pool:{disable:e[`notification-filter-pool-disable`],healthy:e[`notification-filter-pool-healthy`]}},origin_steering:{policy:e[`origin-steering-policy`]},origins:c(e.origins,`origins`)}),s=await o(`Updating`,async()=>t.send(G,{body:r,pool_id:e[`pool-id`]}));i(s,{successLabel:`Updated`})})};var K={method:`PATCH`,path:()=>`/user/load_balancers/pools`,body:`json`};function Ze(e){return e.usage("$0 user load-balancers pools edit pools pools\n\nApply changes to a number of existing pools, overwriting the supplied properties. Pools are ordered by ascending `name`. Returns the list of affected pools. Supports the standard pagination query parameters, either `limit`/`offset` or `per_page`/`page`.").option(`notification-email`,{type:`string`,description:'The email address to send health status notifications to. This field is now deprecated in favor of Cloudflare Notifications for Load Balancing, so only resetting this field with an empty string `""` is accepted.'}).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 Qe={command:`pools`,describe:`Patch Pools`,builder:Ze,handler:async e=>s({command:`user load-balancers pools edit pools pools`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf user load-balancers pools edit pools pools`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/user/load_balancers/pools`,pathParams:{},bodyKind:`json`,body:e.body===void 0?d({notification_email:f(e[`notification-email`],`notification-email`,`text`)}):l(e.body)});return}let t=await n(e);if(e.body){let n=l(e.body),r=await o(`Updating`,async()=>t.send(K,{body:n}));i(r,{successLabel:`Updated`});return}let r=d({notification_email:f(e[`notification-email`],`notification-email`,`text`)}),s=await o(`Updating`,async()=>t.send(K,{body:r}));i(s,{successLabel:`Updated`})})},$e={command:`pools`,describe:`Update one or multiple origin pools`,builder:e=>e.command(Xe).command(Qe).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},et={command:`edit`,describe:`Operations for load-balancers.pools.edit`,builder:e=>e.command($e).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var tt={method:`GET`,path:t=>e`/user/load_balancers/pools/${t.pool_id}`};function nt(e){return e.usage(`$0 user load-balancers pools get <pool-id>
|
|
55
52
|
|
|
@@ -71,8 +68,7 @@ List all region mappings in the user context.`).option(`subdivision-code`,{type:
|
|
|
71
68
|
|
|
72
69
|
List origin health changes.`).option(`until`,{type:`string`,description:`End date and time of requesting data period in the ISO8601 format.`}).option(`pool-name`,{type:`string`,description:`The name for the pool to filter.`}).option(`origin-healthy`,{type:`boolean`,description:`If true, filter events where the origin status is healthy. If false, filter events where the origin status is unhealthy.`}).option(`pool-id`,{type:`string`,description:`Pool ID`}).option(`since`,{type:`string`,description:`Start date and time of requesting data period in the ISO8601 format.`}).option(`origin-name`,{type:`string`,description:`The name for the origin to filter.`}).option(`pool-healthy`,{type:`boolean`,description:`If true, filter events where the pool status is healthy. If false, filter events where the pool status is unhealthy.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const Mt={command:`list`,describe:`List Healthcheck Events`,builder:jt,handler:async e=>s({command:`user load-balancing-analytics events list`,classification:{safeFlags:[`origin-healthy`,`pool-healthy`,`dry-run`]}},e,async()=>{let t={until:e.until,pool_name:e[`pool-name`],origin_healthy:e[`origin-healthy`],pool_id:e[`pool-id`],since:e.since,origin_name:e[`origin-name`],pool_healthy:e[`pool-healthy`]};if(e.dryRun){a({command:`cf user load-balancing-analytics events list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/user/load_balancing_analytics/events`,pathParams:{},query:t,bodyKind:`none`});return}let r=await n(e),s=await o(`Loading`,async()=>r.send(At,t));i(s,{successLabel:`Loaded`})})},Nt={command:`events`,describe:`Origin health changes recorded by Load Balancing analytics`,builder:e=>e.command(Mt).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},Pt={command:`load-balancing-analytics`,describe:`Operations for load-balancing-analytics`,builder:e=>e.command(Nt).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var Ft={method:`DELETE`,path:t=>e`/memberships/${t.membership_id}`};function It(e){return e.usage(`$0 user memberships delete <membership-id>
|
|
73
70
|
|
|
74
|
-
Remove the associated member from an account.`).positional(`membership-id`,{type:`string`,description:`Membership identifier tag.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const Lt={command:`delete <membership-id>`,describe:`Delete Membership`,builder:It,handler:async e=>s({command:`user memberships delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){a({command:`cf user memberships delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/memberships/${e[`membership-id`]==null?`<membership-id>`:encodeURIComponent(String(e[`membership-id`]))}`,pathParams:{"membership-id":String(e[`membership-id`]??``)},bodyKind:`none`});return}let t=await n(e);if(!await h({force:!!e.force,message:`Are you sure? This action cannot be undone.`}))
|
|
75
|
-
`);return}let r=await o(`Deleting`,async()=>t.send(Ft,{membership_id:e[`membership-id`]}));i(r,{successLabel:`Deleted`})})};function Rt(e){return e.usage(`$0 user memberships list
|
|
71
|
+
Remove the associated member from an account.`).positional(`membership-id`,{type:`string`,description:`Membership identifier tag.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const Lt={command:`delete <membership-id>`,describe:`Delete Membership`,builder:It,handler:async e=>s({command:`user memberships delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){a({command:`cf user memberships delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/memberships/${e[`membership-id`]==null?`<membership-id>`:encodeURIComponent(String(e[`membership-id`]))}`,pathParams:{"membership-id":String(e[`membership-id`]??``)},bodyKind:`none`});return}let t=await n(e);if(!await h({force:!!e.force,message:`Are you sure? This action cannot be undone.`}))return;let r=await o(`Deleting`,async()=>t.send(Ft,{membership_id:e[`membership-id`]}));i(r,{successLabel:`Deleted`})})};function Rt(e){return e.usage(`$0 user memberships list
|
|
76
72
|
|
|
77
73
|
List memberships of accounts the user can access.`).option(`account-name`,{type:`string`,description:`Account name`}).option(`page`,{type:`number`,description:`Page number of paginated results.`}).option(`per-page`,{type:`number`,description:`Number of memberships per page.`}).option(`order`,{type:`string`,description:`Field to order memberships by.`,choices:[`id`,`account.name`,`status`]}).option(`direction`,{type:`string`,description:`Direction to order memberships.`,choices:[`asc`,`desc`]}).option(`name`,{type:`string`,description:`Account name`}).option(`status`,{type:`string`,description:`Status of this membership.`,choices:[`accepted`,`pending`,`rejected`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const zt={command:`list`,describe:`List Memberships`,builder:Rt,handler:async e=>s({command:`user memberships list`,classification:{safeFlags:[`order`,`direction`,`status`,`dry-run`]}},e,async()=>{let t={"account.name":e[`account-name`],page:e.page,per_page:e[`per-page`],order:e.order,direction:e.direction,name:e.name,status:e.status};if(e.dryRun){a({command:`cf user memberships list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/memberships`,pathParams:{},query:t,bodyKind:`none`});return}let s=await n(e),c=await o(`Loading`,async()=>s.send(r,t));i(c,{successLabel:`Loaded`})})};var Y={method:`PUT`,path:t=>e`/memberships/${t.membership_id}`,body:`json`};function Bt(e){return e.usage(`$0 user memberships update <membership-id>
|
|
78
74
|
|
|
@@ -82,8 +78,7 @@ Get a specific membership for the currently authenticated user.`).positional(`me
|
|
|
82
78
|
|
|
83
79
|
Get a specific membership.`).positional(`membership-id`,{type:`string`,description:`Membership identifier tag.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const qt={command:`user-s-account-memberships-membership-details <membership-id>`,describe:`Membership Details`,builder:Kt,handler:async e=>s({command:`user memberships user-s-account-memberships-membership-details`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf user memberships user-s-account-memberships-membership-details`,method:`GET`,url:`https://api.cloudflare.com/client/v4/memberships/${e[`membership-id`]==null?`<membership-id>`:encodeURIComponent(String(e[`membership-id`]))}`,pathParams:{"membership-id":String(e[`membership-id`]??``)},bodyKind:`none`});return}let t=await n(e),r=await o(`Loading`,async()=>t.send(Gt,{membership_id:e[`membership-id`]}));i(r,{successLabel:`Loaded`})})},Jt={command:`memberships`,describe:`Operations for memberships`,builder:e=>e.command(Lt).command(zt).command(Vt).command(Wt).command(qt).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var Yt={method:`DELETE`,path:t=>e`/user/subscriptions/${t.identifier}`};function Xt(e){return e.usage(`$0 user subscriptions delete <identifier>
|
|
84
80
|
|
|
85
|
-
Deletes a user's subscription.`).positional(`identifier`,{type:`string`,description:`Subscription identifier tag.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const Zt={command:`delete <identifier>`,describe:`Delete User Subscription`,builder:Xt,handler:async e=>s({command:`user subscriptions delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){a({command:`cf user subscriptions delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/user/subscriptions/${e.identifier==null?`<identifier>`:encodeURIComponent(String(e.identifier))}`,pathParams:{identifier:String(e.identifier??``)},bodyKind:`none`});return}let t=await n(e);if(!await h({force:!!e.force})){
|
|
86
|
-
`);return}let r=await o(`Deleting`,async()=>t.send(Yt,{identifier:e.identifier}));i(r,{successLabel:`Deleted`})})};var Qt={method:`GET`,path:()=>`/user/subscriptions`};function $t(e){return e.usage(`$0 user subscriptions get
|
|
81
|
+
Deletes a user's subscription.`).positional(`identifier`,{type:`string`,description:`Subscription identifier tag.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const Zt={command:`delete <identifier>`,describe:`Delete User Subscription`,builder:Xt,handler:async e=>s({command:`user subscriptions delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){a({command:`cf user subscriptions delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/user/subscriptions/${e.identifier==null?`<identifier>`:encodeURIComponent(String(e.identifier))}`,pathParams:{identifier:String(e.identifier??``)},bodyKind:`none`});return}let t=await n(e);if(!await h({force:!!e.force}))return;let r=await o(`Deleting`,async()=>t.send(Yt,{identifier:e.identifier}));i(r,{successLabel:`Deleted`})})};var Qt={method:`GET`,path:()=>`/user/subscriptions`};function $t(e){return e.usage(`$0 user subscriptions get
|
|
87
82
|
|
|
88
83
|
Lists all of a user's subscriptions.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const en={command:`get`,describe:`Get User Subscriptions`,builder:$t,handler:async e=>s({command:`user subscriptions get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf user subscriptions get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/user/subscriptions`,pathParams:{},bodyKind:`none`});return}let t=await n(e),r=await o(`Loading`,async()=>t.send(Qt));i(r,{successLabel:`Loaded`})})};var X={method:`PUT`,path:t=>e`/user/subscriptions/${t.identifier}`,body:`json`};function tn(e){return e.usage(`$0 user subscriptions update <identifier>
|
|
89
84
|
|
|
@@ -93,8 +88,7 @@ Retrieves list of tenants the authenticated user / method has access to.`).optio
|
|
|
93
88
|
|
|
94
89
|
Create a new access token.`).option(`condition-request-ip-in`,{type:`string`,array:!0,description:`List of IPv4/IPv6 CIDR addresses.`}).option(`condition-request-ip-not-in`,{type:`string`,array:!0,description:`List of IPv4/IPv6 CIDR addresses.`}).option(`expires-on`,{type:`string`,description:`The expiration time on or after which the JWT MUST NOT be accepted for processing.`}).option(`name`,{type:`string`,description:`Token name.`}).option(`not-before`,{type:`string`,description:`The time before which the token MUST NOT be accepted for processing.`}).option(`policies`,{type:`string`,description:`List of access policies assigned to the token. Provide as a JSON array of objects or @path/to/file.json.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const un={command:`create`,describe:`Create Token`,builder:ln,handler:async e=>s({command:`user tokens create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf user tokens create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/user/tokens`,pathParams:{},bodyKind:`json`,body:e.body===void 0?d({condition:{request_ip:{in:e[`condition-request-ip-in`],not_in:e[`condition-request-ip-not-in`]}},expires_on:f(e[`expires-on`],`expires-on`,`text`),name:f(e.name,`name`,`text`),not_before:f(e[`not-before`],`not-before`,`text`),policies:c(e.policies,`policies`)}):l(e.body)});return}let t=await n(e);if(e.body){let n=l(e.body),r=await o(`Creating`,async()=>t.send(Z,{body:n}));i(r,{successLabel:`Created`});return}if(e.name===void 0&&(e.name=await p(`name`,`Token name.`)),e.policies===void 0)throw Error(`--policies is required (or pass --body with this field set).`);let r=d({condition:{request_ip:{in:e[`condition-request-ip-in`],not_in:e[`condition-request-ip-not-in`]}},expires_on:f(e[`expires-on`],`expires-on`,`text`),name:f(e.name,`name`,`text`),not_before:f(e[`not-before`],`not-before`,`text`),policies:c(e.policies,`policies`)}),s=await o(`Creating`,async()=>t.send(Z,{body:r}));i(s,{successLabel:`Created`})})};var dn={method:`DELETE`,path:t=>e`/user/tokens/${t.token_id}`};function fn(e){return e.usage(`$0 user tokens delete <token-id>
|
|
95
90
|
|
|
96
|
-
Destroy a token.`).positional(`token-id`,{type:`string`,description:`Token identifier tag.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const pn={command:`delete <token-id>`,describe:`Delete Token`,builder:fn,handler:async e=>s({command:`user tokens delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){a({command:`cf user tokens delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/user/tokens/${e[`token-id`]==null?`<token-id>`:encodeURIComponent(String(e[`token-id`]))}`,pathParams:{"token-id":String(e[`token-id`]??``)},bodyKind:`none`});return}let t=await n(e);if(!await h({force:!!e.force,message:`Are you sure? This action cannot be undone.`})){
|
|
97
|
-
`);return}let r=await o(`Deleting`,async()=>t.send(dn,{token_id:e[`token-id`]}));i(r,{successLabel:`Deleted`})})};var mn={method:`GET`,path:t=>e`/user/tokens/${t.token_id}`};function hn(e){return e.usage(`$0 user tokens get <token-id>
|
|
91
|
+
Destroy a token.`).positional(`token-id`,{type:`string`,description:`Token identifier tag.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const pn={command:`delete <token-id>`,describe:`Delete Token`,builder:fn,handler:async e=>s({command:`user tokens delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){a({command:`cf user tokens delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/user/tokens/${e[`token-id`]==null?`<token-id>`:encodeURIComponent(String(e[`token-id`]))}`,pathParams:{"token-id":String(e[`token-id`]??``)},bodyKind:`none`});return}let t=await n(e);if(!await h({force:!!e.force,message:`Are you sure? This action cannot be undone.`}))return;let r=await o(`Deleting`,async()=>t.send(dn,{token_id:e[`token-id`]}));i(r,{successLabel:`Deleted`})})};var mn={method:`GET`,path:t=>e`/user/tokens/${t.token_id}`};function hn(e){return e.usage(`$0 user tokens get <token-id>
|
|
98
92
|
|
|
99
93
|
Get information about a specific token.`).positional(`token-id`,{type:`string`,description:`Token identifier tag.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const gn={command:`get <token-id>`,describe:`Token Details`,builder:hn,handler:async e=>s({command:`user tokens get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf user tokens get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/user/tokens/${e[`token-id`]==null?`<token-id>`:encodeURIComponent(String(e[`token-id`]))}`,pathParams:{"token-id":String(e[`token-id`]??``)},bodyKind:`none`});return}let t=await n(e),r=await o(`Loading`,async()=>t.send(mn,{token_id:e[`token-id`]}));i(r,{successLabel:`Loaded`})})};var _n={method:`GET`,path:()=>`/user/tokens`,query:[`page`,`per_page`,`direction`,`include_expired`]};function vn(e){return e.usage(`$0 user tokens list
|
|
100
94
|
|
|
@@ -104,8 +98,7 @@ Find all available permission groups for API Tokens.`).option(`name`,{type:`stri
|
|
|
104
98
|
The value must be URL-encoded.`}).option(`scope`,{type:`string`,description:`Filter by the scope of the permission group.
|
|
105
99
|
The value must be URL-encoded.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const xn={command:`list`,describe:`List Token Permission Groups`,builder:Q,handler:async e=>s({command:`user tokens permission-groups list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{let t={name:e.name,scope:e.scope};if(e.dryRun){a({command:`cf user tokens permission-groups list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/user/tokens/permission_groups`,pathParams:{},query:t,bodyKind:`none`});return}let r=await n(e),s=await o(`Loading`,async()=>r.send(bn,t));i(s,{successLabel:`Loaded`})})},Sn={command:`permission-groups`,describe:`Operations for tokens.permission-groups`,builder:e=>e.command(xn).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var Cn={method:`PUT`,path:t=>e`/user/tokens/${t.token_id}/value`};function wn(e){return e.usage(`$0 user tokens roll <token-id>
|
|
106
100
|
|
|
107
|
-
Roll the token secret.`).positional(`token-id`,{type:`string`,description:`Token identifier tag.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const Tn={command:`roll <token-id>`,describe:`Roll Token`,builder:wn,handler:async e=>s({command:`user tokens roll`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){a({command:`cf user tokens roll`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/user/tokens/${e[`token-id`]==null?`<token-id>`:encodeURIComponent(String(e[`token-id`]))}/value`,pathParams:{"token-id":String(e[`token-id`]??``)},bodyKind:`none`});return}let t=await n(e);if(!await h({force:!!e.force,message:`Rolling this token will invalidate the current secret and generate a new one. Any integrations using the current secret will stop working.`})){
|
|
108
|
-
`);return}let r=await o(`Deleting`,async()=>t.send(Cn,{token_id:e[`token-id`]}));i(r,{successLabel:`Deleted`})})};var $={method:`PUT`,path:t=>e`/user/tokens/${t.token_id}`,body:`json`};function En(e){return e.usage(`$0 user tokens update <token-id>
|
|
101
|
+
Roll the token secret.`).positional(`token-id`,{type:`string`,description:`Token identifier tag.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const Tn={command:`roll <token-id>`,describe:`Roll Token`,builder:wn,handler:async e=>s({command:`user tokens roll`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){a({command:`cf user tokens roll`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/user/tokens/${e[`token-id`]==null?`<token-id>`:encodeURIComponent(String(e[`token-id`]))}/value`,pathParams:{"token-id":String(e[`token-id`]??``)},bodyKind:`none`});return}let t=await n(e);if(!await h({force:!!e.force,message:`Rolling this token will invalidate the current secret and generate a new one. Any integrations using the current secret will stop working.`}))return;let r=await o(`Deleting`,async()=>t.send(Cn,{token_id:e[`token-id`]}));i(r,{successLabel:`Deleted`})})};var $={method:`PUT`,path:t=>e`/user/tokens/${t.token_id}`,body:`json`};function En(e){return e.usage(`$0 user tokens update <token-id>
|
|
109
102
|
|
|
110
103
|
Update an existing token.`).positional(`token-id`,{type:`string`,description:`Token identifier tag.`,demandOption:!0}).option(`condition-request-ip-in`,{type:`string`,array:!0,description:`List of IPv4/IPv6 CIDR addresses.`}).option(`condition-request-ip-not-in`,{type:`string`,array:!0,description:`List of IPv4/IPv6 CIDR addresses.`}).option(`expires-on`,{type:`string`,description:`The expiration time on or after which the JWT MUST NOT be accepted for processing.`}).option(`name`,{type:`string`,description:`Token name.`}).option(`not-before`,{type:`string`,description:`The time before which the token MUST NOT be accepted for processing.`}).option(`policies`,{type:`string`,description:`List of access policies assigned to the token. Provide as a JSON array of objects or @path/to/file.json.`}).option(`status`,{type:`string`,description:`Status of the token.`,choices:[`active`,`disabled`,`expired`]}).coerce(`status`,e=>f(e,`status`,`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 Dn={command:`update <token-id>`,describe:`Update Token`,builder:En,handler:async e=>s({command:`user tokens update`,classification:{safeFlags:[`status`,`dry-run`]}},e,async()=>{if(e.dryRun){a({command:`cf user tokens update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/user/tokens/${e[`token-id`]==null?`<token-id>`:encodeURIComponent(String(e[`token-id`]))}`,pathParams:{"token-id":String(e[`token-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({condition:{request_ip:{in:e[`condition-request-ip-in`],not_in:e[`condition-request-ip-not-in`]}},expires_on:f(e[`expires-on`],`expires-on`,`text`),name:f(e.name,`name`,`text`),not_before:f(e[`not-before`],`not-before`,`text`),policies:c(e.policies,`policies`),status:e.status}):l(e.body)});return}let t=await n(e);if(e.body){let n=l(e.body),r=await o(`Updating`,async()=>t.send($,{body:n,token_id:e[`token-id`]}));i(r,{successLabel:`Updated`});return}if(e.name===void 0&&(e.name=await p(`name`,`Token name.`)),e.policies===void 0)throw Error(`--policies is required (or pass --body with this field set).`);let r=d({condition:{request_ip:{in:e[`condition-request-ip-in`],not_in:e[`condition-request-ip-not-in`]}},expires_on:f(e[`expires-on`],`expires-on`,`text`),name:f(e.name,`name`,`text`),not_before:f(e[`not-before`],`not-before`,`text`),policies:c(e.policies,`policies`),status:e.status}),s=await o(`Updating`,async()=>t.send($,{body:r,token_id:e[`token-id`]}));i(s,{successLabel:`Updated`})})};var On={method:`GET`,path:()=>`/user/tokens/verify`};function kn(e){return e.usage(`$0 user tokens verify
|
|
111
104
|
|
|
@@ -1,12 +1,11 @@
|
|
|
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-CSH3UMpD.mjs";import{i as n,n as r}from"./auth-BcNLQji1.mjs";import{a as i,t as a}from"./context-DVh8Wyfs.mjs";import{t as o}from"./output-BJEgbI0G.mjs";import{t as s}from"./dry-run-gy0Hl9xo.mjs";import{t as c}from"./progress-CtGsPOpV.mjs";import{t as l}from"./run-DnZGQbq_.mjs";import"./telemetry-CvZean4s.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-YrI7ltMa.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
|
|
|
6
6
|
Delete a set of vectors from an index by their vector identifiers.`).positional(`index-name`,{type:`string`,description:`Index name`,demandOption:!0}).option(`ids`,{type:`string`,array:!0,description:`A list of vector identifiers to delete from the index indicated by the path.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const C={command:`delete-by-ids <index-name>`,describe:`Delete Vectors By Identifier`,builder:S,handler:async e=>l({command:`vectorize delete-by-ids`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();s({command:`cf vectorize delete-by-ids`,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`]))}/delete_by_ids`,pathParams:{"index-name":String(e[`index-name`]??``)},bodyKind:`json`,body:e.body===void 0?f({ids:e.ids}):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(x,{body:t,account_id:l,index_name:e[`index-name`]}));o(r,{successLabel:`Created`});return}let d=f({ids:e.ids}),p=await c(`Creating`,async()=>n.send(x,{body:d,account_id:l,index_name:e[`index-name`]}));o(p,{successLabel:`Created`})})};var w={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/vectorize/v2/indexes/${t.index_name}`};function T(e){return e.usage(`$0 vectorize delete <index-name>
|
|
7
7
|
|
|
8
|
-
Deletes the specified 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}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const E={command:`delete <index-name>`,describe:`Delete Vectorize Index`,builder:T,handler:async e=>l({command:`vectorize delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){let t=await i();s({command:`cf vectorize delete`,method:`DELETE`,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`]))}`,pathParams:{"index-name":String(e[`index-name`]??``)},bodyKind:`none`});return}let n=await r(e),l=e.local?t:await a();if(e.accountId=l,!await _({force:!!e.force})){
|
|
9
|
-
`);return}let u=await c(`Deleting`,async()=>n.send(w,{account_id:l,index_name:e[`index-name`]}));o(u,{successLabel:`Deleted`})})};var D={method:`POST`,path:t=>e`/accounts/${t.account_id}/vectorize/v2/indexes/${t.index_name}/get_by_ids`,body:`json`};function O(e){return e.usage(`$0 vectorize get-by-ids <index-name>
|
|
8
|
+
Deletes the specified 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}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const E={command:`delete <index-name>`,describe:`Delete Vectorize Index`,builder:T,handler:async e=>l({command:`vectorize delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){let t=await i();s({command:`cf vectorize delete`,method:`DELETE`,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`]))}`,pathParams:{"index-name":String(e[`index-name`]??``)},bodyKind:`none`});return}let n=await r(e),l=e.local?t:await a();if(e.accountId=l,!await _({force:!!e.force}))return;let u=await c(`Deleting`,async()=>n.send(w,{account_id:l,index_name:e[`index-name`]}));o(u,{successLabel:`Deleted`})})};var D={method:`POST`,path:t=>e`/accounts/${t.account_id}/vectorize/v2/indexes/${t.index_name}/get_by_ids`,body:`json`};function O(e){return e.usage(`$0 vectorize get-by-ids <index-name>
|
|
10
9
|
|
|
11
10
|
Get a set of vectors from an index by their vector identifiers.`).positional(`index-name`,{type:`string`,description:`Index name`,demandOption:!0}).option(`ids`,{type:`string`,array:!0,description:`A list of vector identifiers to retrieve from the index indicated by the path.`}).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:`get-by-ids <index-name>`,describe:`Get Vectors By Identifier`,builder:O,handler:async e=>l({command:`vectorize get-by-ids`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();s({command:`cf vectorize get-by-ids`,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`]))}/get_by_ids`,pathParams:{"index-name":String(e[`index-name`]??``)},bodyKind:`json`,body:e.body===void 0?f({ids:e.ids}):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(D,{body:t,account_id:l,index_name:e[`index-name`]}));o(r,{successLabel:`Created`});return}let d=f({ids:e.ids}),p=await c(`Creating`,async()=>n.send(D,{body:d,account_id:l,index_name:e[`index-name`]}));o(p,{successLabel:`Created`})})};var A={method:`GET`,path:t=>e`/accounts/${t.account_id}/vectorize/v2/indexes/${t.index_name}`};function j(e){return e.usage(`$0 vectorize get <index-name>
|
|
12
11
|
|
|
@@ -22,8 +21,7 @@ Returns a list of Vectorize Indexes`).option(`dry-run`,{type:`boolean`,descripti
|
|
|
22
21
|
|
|
23
22
|
Enable metadata filtering based on metadata property. Limited to 10 properties.`).positional(`index-name`,{type:`string`,description:`Index name`,demandOption:!0}).option(`index-type`,{type:`string`,description:`Specifies the type of metadata property to index.`,choices:[`string`,`number`,`boolean`]}).coerce(`index-type`,e=>p(e,`index-type`,`text`)).option(`property-name`,{type:`string`,description:`Specifies the metadata property to index.`}).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 <index-name>`,describe:`Create Metadata Index`,builder:W,handler:async e=>l({command:`vectorize metadata-index create`,classification:{safeFlags:[`index-type`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();s({command:`cf vectorize metadata-index create`,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`]))}/metadata_index/create`,pathParams:{"index-name":String(e[`index-name`]??``)},bodyKind:`json`,body:e.body===void 0?f({indexType:e[`index-type`],propertyName:p(e[`property-name`],`property-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(U,{body:t,account_id:l,index_name:e[`index-name`]}));o(r,{successLabel:`Created`});return}e[`index-type`]===void 0&&(e[`index-type`]=await g(`index-type`,`Specifies the type of metadata property to index.`,[`string`,`number`,`boolean`])),e[`property-name`]===void 0&&(e[`property-name`]=await h(`property-name`,`Specifies the metadata property to index.`));let d=f({indexType:e[`index-type`],propertyName:p(e[`property-name`],`property-name`,`text`)}),m=await c(`Creating`,async()=>n.send(U,{body:d,account_id:l,index_name:e[`index-name`]}));o(m,{successLabel:`Created`})})};var K={method:`POST`,path:t=>e`/accounts/${t.account_id}/vectorize/v2/indexes/${t.index_name}/metadata_index/delete`,body:`json`};function q(e){return e.usage(`$0 vectorize metadata-index delete <index-name>
|
|
24
23
|
|
|
25
|
-
Allow Vectorize to delete the specified metadata index.`).positional(`index-name`,{type:`string`,description:`Index name`,demandOption:!0}).option(`property-name`,{type:`string`,description:`Specifies the metadata property for which the index must be deleted.`}).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 J={command:`delete <index-name>`,describe:`Delete Metadata Index`,builder:q,handler:async e=>l({command:`vectorize metadata-index delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){let t=await i();s({command:`cf vectorize metadata-index delete`,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`]))}/metadata_index/delete`,pathParams:{"index-name":String(e[`index-name`]??``)},bodyKind:`json`,body:e.body===void 0?f({propertyName:p(e[`property-name`],`property-name`,`text`)}):u(e.body)});return}let n=await r(e),l=e.local?t:await a();if(e.accountId=l,!await _({force:!!e.force,message:`This operation deletes a metadata index destructively.`})){
|
|
26
|
-
`);return}if(e.body){let t=u(e.body),r=await c(`Deleting`,async()=>n.send(K,{body:t,account_id:l,index_name:e[`index-name`]}));o(r,{successLabel:`Deleted`});return}e[`property-name`]===void 0&&(e[`property-name`]=await h(`property-name`,`Specifies the metadata property for which the index must be deleted.`));let d=f({propertyName:p(e[`property-name`],`property-name`,`text`)}),m=await c(`Deleting`,async()=>n.send(K,{body:d,account_id:l,index_name:e[`index-name`]}));o(m,{successLabel:`Deleted`})})};var Y={method:`GET`,path:t=>e`/accounts/${t.account_id}/vectorize/v2/indexes/${t.index_name}/metadata_index/list`};function X(e){return e.usage(`$0 vectorize metadata-index list
|
|
24
|
+
Allow Vectorize to delete the specified metadata index.`).positional(`index-name`,{type:`string`,description:`Index name`,demandOption:!0}).option(`property-name`,{type:`string`,description:`Specifies the metadata property for which the index must be deleted.`}).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 J={command:`delete <index-name>`,describe:`Delete Metadata Index`,builder:q,handler:async e=>l({command:`vectorize metadata-index delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){let t=await i();s({command:`cf vectorize metadata-index delete`,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`]))}/metadata_index/delete`,pathParams:{"index-name":String(e[`index-name`]??``)},bodyKind:`json`,body:e.body===void 0?f({propertyName:p(e[`property-name`],`property-name`,`text`)}):u(e.body)});return}let n=await r(e),l=e.local?t:await a();if(e.accountId=l,!await _({force:!!e.force,message:`This operation deletes a metadata index destructively.`}))return;if(e.body){let t=u(e.body),r=await c(`Deleting`,async()=>n.send(K,{body:t,account_id:l,index_name:e[`index-name`]}));o(r,{successLabel:`Deleted`});return}e[`property-name`]===void 0&&(e[`property-name`]=await h(`property-name`,`Specifies the metadata property for which the index must be deleted.`));let d=f({propertyName:p(e[`property-name`],`property-name`,`text`)}),m=await c(`Deleting`,async()=>n.send(K,{body:d,account_id:l,index_name:e[`index-name`]}));o(m,{successLabel:`Deleted`})})};var Y={method:`GET`,path:t=>e`/accounts/${t.account_id}/vectorize/v2/indexes/${t.index_name}/metadata_index/list`};function X(e){return e.usage(`$0 vectorize metadata-index list
|
|
27
25
|
|
|
28
26
|
List Metadata Indexes for the specified Vectorize Index.`).option(`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 Z={command:`list`,describe:`List Metadata Indexes`,builder:X,handler:async e=>l({command:`vectorize metadata-index list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();s({command:`cf vectorize metadata-index list`,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`]))}/metadata_index/list`,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(Y,{account_id:l,index_name:e[`index-name`]}));o(u,{successLabel:`Loaded`})})},Q={command:`metadata-index`,describe:`Metadata indexes for filtered vector search`,builder:e=>e.command(G).command(J).command(Z).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var $={method:`POST`,path:t=>e`/accounts/${t.account_id}/vectorize/v2/indexes/${t.index_name}/query`,body:`json`};function te(e){return e.usage(`$0 vectorize query <index-name>
|
|
29
27
|
|