cf 1.0.0-beta.30 → 1.0.0-beta.32
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 +2404 -1420
- package/dist/_meta/schemas.json +1875 -956
- package/dist/{abuse-reports-Dzop8iDe.mjs → abuse-reports-DYm1nDLb.mjs} +1 -1
- package/dist/{access-2NeD3Gu8.mjs → access-Be_7nPz4.mjs} +1 -1
- package/dist/{accounts-CeJbhhX4.mjs → accounts-DXULGfnh.mjs} +3 -3
- package/dist/{acm-Dub0B14J.mjs → acm-Btsz5gzV.mjs} +1 -1
- package/dist/{addressing-BzWJU8m6.mjs → addressing-DBQ5dUBd.mjs} +1 -1
- package/dist/{agent-memory-2l9zyQFA.mjs → agent-memory-Df0q-68_.mjs} +1 -1
- package/dist/{ai-laLv3daG.mjs → ai-CJfI9JI2.mjs} +1 -1
- package/dist/{ai-audit-rgNePq5W.mjs → ai-audit-Dv37OLES.mjs} +1 -1
- package/dist/{ai-gateway-e9b8CcL6.mjs → ai-gateway-BRSUY1QZ.mjs} +5 -5
- package/dist/{ai-search-DZ0AqoPe.mjs → ai-search-Bxv4hDG9.mjs} +3 -3
- package/dist/{ai-security-CQuBTtmw.mjs → ai-security-ByNRXyJv.mjs} +1 -1
- package/dist/{alerting-_4ra-f_v.mjs → alerting-UkiCzqAq.mjs} +2 -4
- package/dist/{analytics-DLNn4bJ4.mjs → analytics-B4Wq2vJx.mjs} +1 -1
- package/dist/{analytics-engine-CY45yWuL.mjs → analytics-engine-BbwIXL0f.mjs} +1 -1
- package/dist/{api-security-BSvJAjJV.mjs → api-security-B6YETCDG.mjs} +1 -1
- package/dist/{argo-xzl0p--1.mjs → argo-CHSOLyFh.mjs} +1 -1
- package/dist/{artifacts-DAS14gcM.mjs → artifacts-1xMBpJLr.mjs} +1 -1
- package/dist/{audit-logs-3nYyCGQA.mjs → audit-logs-Cz__6-PH.mjs} +1 -1
- package/dist/auth-Byb5Y3o4.mjs +2 -0
- package/dist/{auth-cj71dGxS.mjs → auth-CRq9OQKr.mjs} +1 -1
- package/dist/{auth-B0mFB6nU.mjs → auth-CrBQca61.mjs} +1 -1
- package/dist/{auth-token-D9MnaZ-L.mjs → auth-token-BEkR6ulS.mjs} +1 -1
- package/dist/{autoconfig-DoLQ5ct8.mjs → autoconfig-BDEt9orA.mjs} +386 -120
- package/dist/{basin-catalog-BbCsAKyZ.mjs → basin-catalog-DRVVY1Ff.mjs} +1 -1
- package/dist/{billing-BsiLsjWJ.mjs → billing-CInp7pBa.mjs} +1 -1
- package/dist/{blocks-DK5qAzLe.mjs → blocks-DGXsHh9X.mjs} +1 -1
- package/dist/{bot-management-DkErOsIO.mjs → bot-management--NcaqMij.mjs} +1 -1
- package/dist/{botnet-feed-CK4_PKrf.mjs → botnet-feed-DbPZ3Wzl.mjs} +1 -1
- package/dist/{brand-protection-Czt-2Ei5.mjs → brand-protection-B3s-8soV.mjs} +2 -2
- package/dist/{browser-run-DLMdEaSJ.mjs → browser-run-B9hyiK7P.mjs} +1 -1
- package/dist/build-Bd56lS7c.mjs +2 -0
- package/dist/{build-DiEXOgHH.mjs → build-I3m3uZn6.mjs} +1 -1
- package/dist/{builds-D--zUbR2.mjs → builds-D0mRyKe3.mjs} +1 -1
- package/dist/{cache-C8PQmkjD.mjs → cache-eKHZG4U7.mjs} +1 -1
- package/dist/{cf-QIG83e0V.mjs → cf-MAiSK--E.mjs} +1 -1
- package/dist/{chunk-DSGVRFIS-CeCM3XGQ.mjs → chunk-DSGVRFIS-L76IWWlr.mjs} +1 -1
- package/dist/{chunk-Q5KVZMHK-Bjvrcihk.mjs → chunk-Q5KVZMHK-CYhKv3kZ.mjs} +1 -1
- package/dist/{cli-BBv5YMan.mjs → cli-hFt2ZEED.mjs} +1 -1
- package/dist/{client-side-security-CFxePUL9.mjs → client-side-security-BvIdcAtV.mjs} +1 -1
- package/dist/{cloud-connector-BitfLQ3s.mjs → cloud-connector-B-04mm0j.mjs} +1 -1
- package/dist/{cloudflared-DKh4JK7j.mjs → cloudflared-DynBXmdP.mjs} +1 -1
- package/dist/{cloudforce-one-D2dzA7VD.mjs → cloudforce-one-BAGybQNM.mjs} +139 -143
- package/dist/command-5bkZXAlq.mjs +2 -0
- package/dist/{command-BORazCDG.mjs → command-BCECG198.mjs} +1 -1
- package/dist/{command-BC_nezLE.mjs → command-BaFQsuac.mjs} +1 -1
- package/dist/{command-C2HYwGn_.mjs → command-BdnTjDyg.mjs} +1 -1
- package/dist/{command-n7QausoH.mjs → command-BkCc_9UI.mjs} +1 -1
- package/dist/{command-B6ustzcW.mjs → command-CQU92hcH.mjs} +1 -1
- package/dist/{command-D5FrTb2N.mjs → command-CdB1DQZl.mjs} +1 -1
- package/dist/{command-DoXuskBZ.mjs → command-CoR-c8lP.mjs} +1 -1
- package/dist/{command-iwrZ2Sb1.mjs → command-D-a4KxcW.mjs} +1 -1
- package/dist/{command-aeKPI1bt.mjs → command-D6wod_eb.mjs} +1 -1
- package/dist/{command-Xqidhyr_.mjs → command-DSPEpZHp.mjs} +1 -1
- package/dist/{command-BwcAuPBr.mjs → command-EG23K_k6.mjs} +1 -1
- package/dist/{command-s15KaL-x.mjs → command-Ux0DLWdC.mjs} +1 -1
- package/dist/{command-CQhD3Q1t.mjs → command-oko8tT2c.mjs} +1 -1
- package/dist/{completions-BAUSggys.mjs → completions-CdlqoV7q.mjs} +1 -1
- package/dist/{connector-interrupts-D9tI84Fk.mjs → connector-interrupts-D9iiu7ZU.mjs} +1 -1
- package/dist/{connector-telemetry-events-Bs9wLYwc.mjs → connector-telemetry-events-C8ouyC4A.mjs} +1 -1
- package/dist/{connector-telemetry-snapshots-CbwE4lrE.mjs → connector-telemetry-snapshots-Ck9btYy7.mjs} +1 -1
- package/dist/{connectors-LyJN1htu.mjs → connectors-kGPYvin5.mjs} +1 -1
- package/dist/{containers-CKs7ZyZq.mjs → containers-DIf9nmcC.mjs} +2 -2
- package/dist/{content-scan-BQRz7C7Z.mjs → content-scan-Cr0i9wJK.mjs} +1 -1
- package/dist/{context-DlFhI9cN.mjs → context-DsVjrTbe.mjs} +1 -1
- package/dist/{cps-DYlXx89C.mjs → cps-BHmMKg5Q.mjs} +1 -1
- package/dist/{csam-scanner-BFANxGD-.mjs → csam-scanner-DGTOi2EL.mjs} +1 -1
- package/dist/{custom-csrs-BX4aCeof.mjs → custom-csrs-DpLkO9_M.mjs} +1 -1
- package/dist/{custom-hostnames-BRYABKN3.mjs → custom-hostnames-beJnRWcQ.mjs} +1 -1
- package/dist/{custom-nameservers-CP1Vf1TD.mjs → custom-nameservers-B1WtaEDH.mjs} +1 -1
- package/dist/{custom-pages-BNL69ToU.mjs → custom-pages-BVXmc-u6.mjs} +1 -1
- package/dist/{d1-D4AZsUKn.mjs → d1-DYQBKGMz.mjs} +1 -1
- package/dist/{delegate-BKlomUk6.mjs → delegate-4bIHEQ8-.mjs} +1 -1
- package/dist/delegate.mjs +1 -1
- package/dist/{deploy-LbXgSfAd.mjs → deploy-DEq6UKzb.mjs} +1 -1
- package/dist/{deploy-context-BYw6gbl-.mjs → deploy-context-DJNsb7w-.mjs} +1 -1
- package/dist/deploy-input-Bkll8tDW.mjs +2 -0
- package/dist/{dev-DaFSd8WC.mjs → dev-DIguZvJE.mjs} +1 -1
- package/dist/{diagnostics-Dk3pyWx_.mjs → diagnostics-DyCPKwXL.mjs} +1 -1
- package/dist/{discover-DGsMj9ZN.mjs → discover-DtcZCeSh.mjs} +1 -1
- package/dist/discover-Dxb5yh9L.mjs +2 -0
- package/dist/{disk-cache-nbuwH1Dh.mjs → disk-cache-BVfJigfC.mjs} +1 -1
- package/dist/{dist-DwxlJ9Ms.mjs → dist-BoDdDWjK.mjs} +33 -33
- package/dist/{dls-DU6EdhQK.mjs → dls-BXGJug7c.mjs} +1 -1
- package/dist/{dns-3QDtCu6f.mjs → dns-Ev7l7p2X.mjs} +25 -25
- package/dist/{dns-firewall-Bbrr_0_a.mjs → dns-firewall-CrkTqlYI.mjs} +1 -1
- package/dist/{docs-lLLKcLr_.mjs → docs-Dx9n33S3.mjs} +1 -1
- package/dist/{durable-objects-DPf1DMeq.mjs → durable-objects-ChKP2Y6u.mjs} +1 -1
- package/dist/{email-auth-DOlEoi8q.mjs → email-auth-B-n1rKim.mjs} +1 -1
- package/dist/{email-routing-D56SPGty.mjs → email-routing-Dfs1g7hk.mjs} +1 -1
- package/dist/{email-security-CSawx0kD.mjs → email-security-B9wpMLHr.mjs} +1 -1
- package/dist/{email-sending-CgFi0cLA.mjs → email-sending-DUyDi24R.mjs} +3 -3
- package/dist/{errors-CilNjDVk.mjs → errors-CUuKkONZ.mjs} +1 -1
- package/dist/{field-extractors-FvIgySB4.mjs → field-extractors-B_R4gU51.mjs} +1 -1
- package/dist/{firewall-BrTvywhW.mjs → firewall-B5_DMZ5c.mjs} +1 -1
- package/dist/{flagship-BGFN1Epo.mjs → flagship-D_jWMrT9.mjs} +1 -1
- package/dist/{fraud-DzK6OIO3.mjs → fraud-BPywqzR5.mjs} +1 -1
- package/dist/{google-tag-gateway-Cd9v8A7Z.mjs → google-tag-gateway-B8SGqWxf.mjs} +1 -1
- package/dist/{healthchecks-Cm7EHaBA.mjs → healthchecks-C1NL0A-K.mjs} +1 -1
- package/dist/{hyperdrive-CVaSt0qX.mjs → hyperdrive-C1C_n591.mjs} +1 -1
- package/dist/{iam-CWN62Mi4.mjs → iam-BWm6OeLJ.mjs} +1 -1
- package/dist/{images-Bo_pdvQC.mjs → images-CU9B4ml9.mjs} +1 -1
- package/dist/index.mjs +1 -1
- package/dist/{init-Dwmpc_S-.mjs → init-DJGas0DL.mjs} +1 -1
- package/dist/{intel-CQFYeGEA.mjs → intel-COtK2F9g.mjs} +1 -1
- package/dist/{interactive-DCbIwYxy.mjs → interactive-CQ29h7qo.mjs} +1 -1
- package/dist/{ips-jTSzoqMU.mjs → ips-Dv5eyxgM.mjs} +1 -1
- package/dist/{k2-utE2lCYd.mjs → k2-CdhxgeiI.mjs} +1 -1
- package/dist/{kv-Cdh5hHte.mjs → kv-gNSTaGhd.mjs} +1 -1
- package/dist/{lazy-command-QoHlmXHW.mjs → lazy-command-CJcN1Ze6.mjs} +1 -1
- package/dist/{leaked-credential-checks-CqApscD3.mjs → leaked-credential-checks-B222QFHE.mjs} +1 -1
- package/dist/{load-balancers-w_4Uz9Gi.mjs → load-balancers-CM-4BY5q.mjs} +1 -1
- package/dist/{login-CS3KxVbk.mjs → login-Csb8Ld0x.mjs} +1 -1
- package/dist/login-bHCEjxRS.mjs +2 -0
- package/dist/{logpush-C76I5dgN.mjs → logpush-CmothcrK.mjs} +1 -1
- package/dist/{logs-B5aCYVCv.mjs → logs-CnKqBsDl.mjs} +1 -1
- package/dist/{magic-network-monitoring-CGf7cVQ9.mjs → magic-network-monitoring-BEdRTgMa.mjs} +1 -1
- package/dist/{magic-transit-CN5noqOR.mjs → magic-transit-CXjc5Yo4.mjs} +1 -1
- package/dist/{managed-defense-DAGr0UGm.mjs → managed-defense-BuOxTHAO.mjs} +1 -1
- package/dist/{managed-transforms-_SuwzZ-5.mjs → managed-transforms-BlqW4xkh.mjs} +1 -1
- package/dist/{mcp-CzedsjOf.mjs → mcp-ubFVHsP4.mjs} +1 -1
- package/dist/{mesh-DXX1S3pX.mjs → mesh-DQS7KfDF.mjs} +1 -1
- package/dist/{migrate-CvRQ4x3_.mjs → migrate-fY24KHV_.mjs} +1 -1
- package/dist/{monetization-8nt9PYln.mjs → monetization-CagZDoKh.mjs} +1 -1
- package/dist/{network-CaiRDY2e.mjs → network-BB35dF4N.mjs} +1 -1
- package/dist/{network-interconnects-Ad6JbAVd.mjs → network-interconnects-Dy4m1jMu.mjs} +2 -2
- package/dist/{o11y-DD2Hfnzi.mjs → o11y-Dmll3yib.mjs} +4 -4
- package/dist/{oauth-CQRlNgt5.mjs → oauth-Dv7Wucj6.mjs} +1 -1
- package/dist/{oauth-BUcV_xbm.mjs → oauth-NljTb7u9.mjs} +1 -1
- package/dist/observability-rtMYSCht.mjs +4 -0
- package/dist/{ohttp-gateway-Sej9-GCm.mjs → ohttp-gateway-BM3nsC92.mjs} +1 -1
- package/dist/{organizations-DwYsCbYD.mjs → organizations-Xus5102w.mjs} +1 -1
- package/dist/package-BJWSNfbc.mjs +2 -0
- package/dist/{page-rules-CjufEmIt.mjs → page-rules-BKoA5eaf.mjs} +1 -1
- package/dist/{pages-Dj0Cdf3G.mjs → pages-CLhvyehs.mjs} +4 -4
- package/dist/{pay-per-crawl-DPVlluRA.mjs → pay-per-crawl-BLjKJl62.mjs} +1 -1
- package/dist/{pay-per-use-DhuLjaoo.mjs → pay-per-use-FbddmVNv.mjs} +1 -1
- package/dist/{pipelines-D2pM69oq.mjs → pipelines-BsJkvK-K.mjs} +1 -1
- package/dist/{precursor-DzuA1m8D.mjs → precursor-oLj-WPJH.mjs} +1 -1
- package/dist/{previews-CHHd5Rx7.mjs → previews-BRPPf7UU.mjs} +3 -3
- package/dist/{progress-AML-AVs4.mjs → progress-DItBn6ZV.mjs} +1 -1
- package/dist/{prompt-Bnon9lfK.mjs → prompt-BGz3DNLz.mjs} +1 -1
- package/dist/{queues-GDwznw0o.mjs → queues-DAnbmO-t.mjs} +3 -3
- package/dist/{r2-B3Xkb0S4.mjs → r2-DNN91rtN.mjs} +2 -2
- package/dist/{radar-fBT7VIO2.mjs → radar-YWsfV39d.mjs} +150 -150
- package/dist/{raw-fetch-0T1SwPa1.mjs → raw-fetch-CmI3Ol3q.mjs} +1 -1
- package/dist/{realtime-B7mR3XtY.mjs → realtime-CfsgoOsd.mjs} +1 -1
- package/dist/{registrar-DOoxlZc7.mjs → registrar-N1c89kFV.mjs} +1 -1
- package/dist/{registrar-sandbox-DC7xAqqc.mjs → registrar-sandbox-D5lsoy-x.mjs} +1 -1
- package/dist/{reporting-DlD7J6Pq.mjs → reporting-CI5TLvj4.mjs} +1 -1
- package/dist/{request-headers-BEYXy4JN.mjs → request-headers-CUwBDAwI.mjs} +1 -1
- package/dist/{request-tracers-DYCGkszp.mjs → request-tracers-DO63p3ou.mjs} +1 -1
- package/dist/{resource-sharing-D_bUv7E8.mjs → resource-sharing-CxdcY5n1.mjs} +1 -1
- package/dist/{rules-C4cu3_jr.mjs → rules-DuuULmp2.mjs} +1 -1
- package/dist/{rulesets-Bl4mLnXA.mjs → rulesets-3_8IWMfL.mjs} +1 -1
- package/dist/{rum-DE_uJb09.mjs → rum-DkfsMJa7.mjs} +1 -1
- package/dist/run-C9SxROBF.mjs +2 -0
- package/dist/{run-DAg7dfIW.mjs → run-DAK_kbUa.mjs} +1 -1
- package/dist/{schema-cache-CTVUtkAl.mjs → schema-cache-BcbUfb3D.mjs} +1 -1
- package/dist/{scim-Dz4r0fnH.mjs → scim-DCR6AQp5.mjs} +1 -1
- package/dist/{secrets-store-C2GwCUKs.mjs → secrets-store-C3v0_Us9.mjs} +1 -1
- package/dist/{security-insights-DZCm5D3U.mjs → security-insights-0el4fk-S.mjs} +4 -2
- package/dist/security-txt-CcsEaOm5.mjs +8 -0
- package/dist/{session-BEsQIuwP.mjs → session-CgJ6kB79.mjs} +1 -1
- package/dist/shared-DjaJ-SCM.mjs +2 -0
- package/dist/{smart-shield-C2uSFcGN.mjs → smart-shield-BxTEZqtZ.mjs} +1 -1
- package/dist/{snippets-BoaGEAC6.mjs → snippets-CH4PcqCg.mjs} +1 -1
- package/dist/{spawn-B4y5Urjv.mjs → spawn-B681PPG2.mjs} +2 -2
- package/dist/{spectrum-Bb0KXA8R.mjs → spectrum-DconVKYG.mjs} +1 -1
- package/dist/{speed-zKYgLTHA.mjs → speed-Euqtk0Vc.mjs} +1 -1
- package/dist/{sql-pjWozuvl.mjs → sql-UNZoawTj.mjs} +1 -1
- package/dist/{src-B8i6_XGg.mjs → src-CSSFtpQM.mjs} +5 -5
- package/dist/{ssl-C5bg1X0i.mjs → ssl-CGWF2ZSz.mjs} +9 -9
- package/dist/startup-profile-ajl_yZx2.mjs +2 -0
- package/dist/{startup-profile-CyIelqtC.mjs → startup-profile-ne34QxOx.mjs} +1 -1
- package/dist/{state-BI_wSuID.mjs → state-BFClIYM_.mjs} +1 -1
- package/dist/state-V1KLVkd6.mjs +2 -0
- package/dist/{static-assets-CTv7XwIQ.mjs → static-assets-CWo7dxyW.mjs} +164 -164
- package/dist/{stream-C_FiNrLV.mjs → stream-B3tkAx82.mjs} +1 -1
- package/dist/{tags-CXlivF3y.mjs → tags-CKnt6RT6.mjs} +9 -9
- package/dist/telemetry-B3S5OfOn.mjs +2 -0
- package/dist/{telemetry-CtQWhsmy.mjs → telemetry-COJrOM3V.mjs} +1 -1
- package/dist/{tenant-custom-nameservers-DBg9Hzvn.mjs → tenant-custom-nameservers-BdVLeMsA.mjs} +1 -1
- package/dist/{tenants-89Q0u5_Q.mjs → tenants-C8Emd5Ou.mjs} +1 -1
- package/dist/{tunnels-CL2fIINH.mjs → tunnels-vUfvvRWt.mjs} +15 -13
- package/dist/{turnstile-D6GtQULo.mjs → turnstile-D-6e0ShA.mjs} +1 -1
- package/dist/ui-YBIkZLZt.mjs +2 -0
- package/dist/{update-check-0kpbTLvy.mjs → update-check-BW_N6gX4.mjs} +1 -1
- package/dist/{update-check-D3axIoUi.mjs → update-check-CvzNuZHG.mjs} +1 -1
- package/dist/update-check-worker.mjs +1 -1
- package/dist/{url-normalization--iS57OT_.mjs → url-normalization-Bfj-1zgi.mjs} +1 -1
- package/dist/{url-scanner-C6AtXGc2.mjs → url-scanner-CcZzqvrj.mjs} +1 -1
- package/dist/{user-C5vRYIta.mjs → user-CYHyVzic.mjs} +1 -1
- package/dist/{vectorize-C1Kxb1Ou.mjs → vectorize-69UvmqNI.mjs} +1 -1
- package/dist/version-5uL0ecbB.mjs +2 -0
- package/dist/{waiting-rooms-BCVZY9vI.mjs → waiting-rooms-Dj92gXpa.mjs} +1 -1
- package/dist/{web-assets-D2gXqKZS.mjs → web-assets-vbQ0MSCd.mjs} +1 -1
- package/dist/{web3-CJDZQCOk.mjs → web3-0Sz4gIto.mjs} +1 -1
- package/dist/{whoami-BEad9QUB.mjs → whoami-C4xRnPxf.mjs} +3 -3
- package/dist/whoami-wYc70ks4.mjs +2 -0
- package/dist/{workers-DzXSJMv9.mjs → workers-BQM8pUYu.mjs} +18 -18
- package/dist/{workers-for-platforms-CvazgrqD.mjs → workers-for-platforms-BfXIqCm4.mjs} +1 -1
- package/dist/{workers-vpc-DP4QC6UC.mjs → workers-vpc-CR3tfj4I.mjs} +1 -1
- package/dist/{workflows-BSOj56io.mjs → workflows-DpQgBIHz.mjs} +1 -1
- package/dist/{wrangler-migration-DZ9Oelof.mjs → wrangler-migration-ChTsuUHx.mjs} +57 -57
- package/dist/{zaraz-BnQvKXFy.mjs → zaraz-BPOBM0-W.mjs} +1 -1
- package/dist/{zero-trust-DsslXRub.mjs → zero-trust-Cridhy7G.mjs} +21 -17
- package/dist/{zones-DQ3SjGsZ.mjs → zones-BIKClc2S.mjs} +3 -3
- package/package.json +13 -13
- package/dist/auth-CXR2vsII.mjs +0 -2
- package/dist/build-ByjJ6yIB.mjs +0 -2
- package/dist/command-ycXauMSv.mjs +0 -2
- package/dist/deploy-input-BFWpjDVr.mjs +0 -2
- package/dist/discover-D9FNaCDK.mjs +0 -2
- package/dist/internal-CYrPZ9IX.mjs +0 -4
- package/dist/live-hZgMkXJf.mjs +0 -4
- package/dist/login-BBSJytOt.mjs +0 -2
- package/dist/observability-BzKBUUSf.mjs +0 -4
- package/dist/package-DXaRIx2f.mjs +0 -2
- package/dist/ready-BkXNDNTd.mjs +0 -4
- package/dist/run-Cg9utScS.mjs +0 -2
- package/dist/security-txt-Dbi9KxNc.mjs +0 -8
- package/dist/shared-DqW2vICA.mjs +0 -2
- package/dist/signed-url-BhHSAUam.mjs +0 -4
- package/dist/startup-profile-Dif7XOsU.mjs +0 -2
- package/dist/state-xUh3Z77T.mjs +0 -2
- package/dist/telemetry-DDs3zhdw.mjs +0 -2
- package/dist/ui-CY75N4Tm.mjs +0 -2
- package/dist/version-pcpa_kv3.mjs +0 -2
- package/dist/whoami-2eFTt0-Y.mjs +0 -2
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{J as e}from"./dist-
|
|
2
|
+
import{J as e}from"./dist-BoDdDWjK.mjs";import{c as t,l as n,u as r}from"./auth-CRq9OQKr.mjs";import{t as i}from"./auth-token-BEkR6ulS.mjs";import{n as a}from"./context-DsVjrTbe.mjs";import{r as o}from"./local-B3zt9PXR.mjs";import{n as s}from"./request-headers-CUwBDAwI.mjs";import{i as c}from"./api-Dnt6lRJG.mjs";async function l(l,u={}){let{method:d=`GET`,local:f=!1}=u,p=e({compliance_region:await a()}),m=`${p.replace(/\/+$/,``)}${l}`,h={...s()};u.headers&&Object.assign(h,u.headers);let g=n(globalThis.fetch);f?g=o({persistTo:u.persistTo,apiBaseUrl:p}):h.Authorization=`Bearer ${await i()}`;let _,v=u.body;v!=null&&(v instanceof FormData?_=v:Buffer.isBuffer(v)||v instanceof Uint8Array||v instanceof ArrayBuffer?(_=v,h[`Content-Type`]??=u.contentType??`application/octet-stream`):typeof v==`string`?(_=v,u.contentType&&(h[`Content-Type`]??=u.contentType)):(_=JSON.stringify(v),h[`Content-Type`]??=u.contentType??`application/json`));let y=await g(m,{method:d,headers:h,..._===void 0?{}:{body:_},...t(_)?{}:{signal:AbortSignal.timeout(r)}});if(!y.ok){let e=y.headers.get(`content-type`)??``,t;try{t=e.includes(`application/json`)?await y.json():await y.text()}catch{t=null}throw new c({statusCode:y.status,body:t,rawResponse:{status:y.status,statusText:y.statusText,url:y.url||m,headers:y.headers,redirected:y.redirected,type:y.type}})}let b=await y.arrayBuffer();return Buffer.from(b)}function u(e){process.stdout.write(e)}export{u as n,l as t};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-CRq9OQKr.mjs";import{t as n}from"./dry-run-mrA7FFLR.mjs";import{a as r,t as i}from"./context-DsVjrTbe.mjs";import{t as a}from"./local-B3zt9PXR.mjs";import{t as o}from"./output-PRKYaJuo.mjs";import{t as s}from"./progress-DItBn6ZV.mjs";import{t as c}from"./run-DAK_kbUa.mjs";import"./telemetry-B3S5OfOn.mjs";import{i as l,o as u,r as d,t as f}from"./body-parser-HN91kAf0.mjs";import{n as p}from"./input-validation-D7z60HJH.mjs";import{a as m,i as h,n as g}from"./prompt-BGz3DNLz.mjs";var _={method:`GET`,path:t=>e`/accounts/${t.account_id}/realtime/kit/${t.app_id}/analytics/livestreams/daywise`,query:[`start_time`,`end_time`,`filters`]};function v(e){return e.usage(`$0 realtime kit analytics livestreams daily get <app-id>
|
|
3
3
|
|
|
4
4
|
Returns day-wise livestream analytics for the specified time range.`).positional(`app-id`,{type:`string`,description:`The app identifier tag.`,demandOption:!0}).option(`start-time`,{type:`number`,description:`Specify the start time as a Unix timestamp in seconds to access the livestream analytics.`}).option(`end-time`,{type:`number`,description:`Specify the end time as a Unix timestamp in seconds to access the livestream analytics.`}).option(`filters`,{type:`string`,description:`Optional filters for livestream analytics.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const ee={command:`get <app-id>`,describe:`Fetch day-wise analytics data for your livestreams`,builder:v,handler:async e=>c({command:`realtime kit analytics livestreams daily get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{let c={start_time:e[`start-time`],end_time:e[`end-time`],filters:e.filters};if(e.dryRun){let t=await r();n({command:`cf realtime kit analytics livestreams daily get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/realtime/kit/${e[`app-id`]==null?`<app-id>`:encodeURIComponent(String(e[`app-id`]))}/analytics/livestreams/daywise`,pathParams:{"app-id":String(e[`app-id`]??``)},query:c,bodyKind:`none`});return}let l=await t(e),u=e.local?a:await i();e.accountId=u;let d=await s(`Loading`,async()=>l.send(_,{account_id:u,app_id:e[`app-id`],...c}));o(d,{successLabel:`Loaded`})})},te={command:`daily`,describe:`Daily livestream analytics for RealtimeKit applications`,builder:e=>e.command(ee).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var ne={method:`GET`,path:t=>e`/accounts/${t.account_id}/realtime/kit/${t.app_id}/analytics/livestreams/overall`,query:[`start_time`,`end_time`,`filters`]};function re(e){return e.usage(`$0 realtime kit analytics livestreams get <app-id>
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{a as e,i as t,n}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{a as e,i as t,n}from"./auth-CRq9OQKr.mjs";import{t as r}from"./path-DRw6Y-nd.mjs";import{t as i}from"./dry-run-mrA7FFLR.mjs";import{n as a,t as o}from"./local-B3zt9PXR.mjs";import{a as s,t as c}from"./context-DsVjrTbe.mjs";import{t as l}from"./output-PRKYaJuo.mjs";import{t as u}from"./progress-DItBn6ZV.mjs";import"./telemetry-B3S5OfOn.mjs";import{n as d,t as f}from"./run-DAK_kbUa.mjs";import{c as p,i as m,n as h,o as g,r as _,t as v}from"./body-parser-HN91kAf0.mjs";import{n as y}from"./input-validation-D7z60HJH.mjs";import{t as b}from"./sanitize-DHx5dAJu.mjs";import{a as x,i as S,n as C,r as w,t as T}from"./schema-cache-BcbUfb3D.mjs";import{a as E,c as D,d as O,f as k,i as ee,l as A,o as j,r as M,s as te,t as ne}from"./schema-flags-YgeJ6Bey.mjs";import{r as N}from"./theme-BGHWSKCw.mjs";import{a as re,i as ie,n as ae,r as oe}from"./prompt-BGz3DNLz.mjs";import{domainToASCII as se}from"node:url";import{isDeepStrictEqual as ce}from"node:util";var P={method:`GET`,path:e=>r`/accounts/${e.account_id}/registrar/extensions/${e.extension}`};function le(e){return e.usage("$0 registrar extensions get <extension>\n\nReturns metadata and JSON Schema documents describing the expected input structure for registration and transfer operations on a specific extension (TLD). Supports HTTP conditional GET via `ETag`. Include the `ETag` value from a previous response in an `If-None-Match` header to receive a `304 Not Modified` when the data has not changed.").positional(`extension`,{type:`string`,description:"The extension name (e.g., `com`, `co.uk`).",demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const ue={command:`get <extension>`,describe:`Get extension`,builder:le,handler:async e=>f({command:`registrar extensions get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await s();i({command:`cf registrar extensions get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/registrar/extensions/${e.extension==null?`<extension>`:encodeURIComponent(String(e.extension))}`,pathParams:{extension:String(e.extension??``)},bodyKind:`none`});return}let t=await n(e),r=e.local?o:await c();e.accountId=r;let a=await u(`Loading`,async()=>t.send(P,{account_id:r,extension:e.extension}));l(a,{successLabel:`Loaded`})})};var de={method:`GET`,path:e=>r`/accounts/${e.account_id}/registrar/extensions`,query:[`name`,`cursor`,`per_page`,`direction`,`sort_by`]};function fe(e){return e.usage("$0 registrar extensions list\n\nReturns metadata and JSON Schema documents describing the expected input structure for registration and transfer operations on each supported extension (TLD). This endpoint uses cursor-based pagination. Results are ordered by extension name by default. To fetch the next page, pass the `cursor` value from the `result_info` object in the response as the `cursor` query parameter in your next request. An empty `cursor` string indicates there are no more pages. Supports HTTP conditional GET via `ETag`. Include the `ETag` value from a previous response in an `If-None-Match` header to receive a `304 Not Modified` when the data has not changed.").option(`name`,{type:`string`,description:"Filter extensions by exact name match.\nFor example, `name=com` returns only the `com` extension."}).option(`cursor`,{type:`string`,description:`Opaque token from a previous response's \`result_info.cursor\`.
|
|
3
3
|
Pass this value to fetch the next page of results. Omit (or
|
|
4
4
|
pass an empty string) for the first page.`}).option(`per-page`,{type:`number`,description:`Number of items to return per page.`}).option(`direction`,{type:`string`,description:`Sort direction for results. Defaults to ascending order.`,choices:[`asc`,`desc`]}).option(`sort-by`,{type:`string`,description:"Column to sort results by. Defaults to `name` when omitted.",choices:[`name`,`created_at`,`updated_at`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const pe={command:`list`,describe:`List extensions`,builder:fe,handler:async e=>f({command:`registrar extensions list`,classification:{safeFlags:[`direction`,`sort-by`,`dry-run`]}},e,async()=>{let t={name:e.name,cursor:e.cursor,per_page:e[`per-page`],direction:e.direction,sort_by:e[`sort-by`]};if(e.dryRun){let e=await s();i({command:`cf registrar extensions list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/registrar/extensions`,pathParams:{},query:t,bodyKind:`none`});return}let r=await n(e),a=e.local?o:await c();e.accountId=a;let d=await u(`Loading`,async()=>r.send(de,{account_id:a,...t}));l(d,{successLabel:`Loaded`})})},me={command:`extensions`,describe:`Operations for extensions`,builder:e=>e.command(ue).command(pe).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var F={method:`POST`,path:e=>r`/accounts/${e.account_id}/registrar/domain-check`,body:`json`,errors:{400:`BadRequestError`}};function he(e){return e.usage("$0 registrar registrations check <domains...>\n\nPerforms real-time, authoritative availability checks directly against domain registries. Use this endpoint to verify a domain is available before attempting registration via `POST /registrations`. **Important:** Unlike the Search endpoint, these results are authoritative and reflect current registry status. Always check availability immediately before registration as domain status can change rapidly. **Note:** This endpoint uses POST to accept a list of domains in the request body. It is a read-only operation — it does not create, modify, or reserve any domains. ### Extension support Only domains on extensions supported for programmatic registration by this API can be registered. If you check a domain on an unsupported extension, the response will include `registrable: false` with a `reason` field explaining why: - `extension_not_supported_via_api` — Cloudflare Registrar supports this extension in the dashboard, but it is not yet available for programmatic registration via this API. Register via `https://dash.cloudflare.com/{account_id}/domains/registrations` instead. - `extension_not_supported` — This extension is not supported by Cloudflare Registrar. - `extension_disallows_registration` — The extension's registry has temporarily or permanently frozen new registrations. No registrar can register domains on this extension at this time. - `domain_premium` — The domain is premium priced. Premium registration is not currently supported by this API. - `domain_unavailable` — The domain is already registered, reserved, or otherwise not available for registration on a supported extension. The `reason` field is only present when `registrable` is `false`. ### Behavior - Maximum 20 domains per request - Pricing is only returned for domains where `registrable: true` - Results are not cached; each request queries the registry ### Workflow 1. Call this endpoint with domains the user wants to register. 2. For each domain where `registrable: true`, present pricing to the user. 3. If `tier: premium`, note that premium registration is not currently supported by this API and do not proceed to `POST /registrations`. 4. Proceed to `POST /registrations` only for supported non-premium domains.").positional(`domains`,{type:`string`,array:!0,description:"List of fully qualified domain names (FQDNs) to check for availability. Each domain must include the extension. - Minimum: 1 domain. - Maximum: 20 domains per request. - The response returns domains on unsupported extensions with `registrable: false` and a `reason` field. - The response may omit malformed domain names (e.g., names missing an extension). ",demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`List of fully qualified domain names (FQDNs) to check. Each domain must include the extension (e.g., "example.com", not "example").`})}const ge={command:`check <domains...>`,describe:`Check domain availability`,builder:he,handler:async e=>f({command:`registrar registrations check`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await s();i({command:`cf registrar registrations check`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/registrar/domain-check`,pathParams:{},bodyKind:`json`,body:e.body===void 0?v({domains:e.domains}):h(_(e.body),[{name:`domains`,field:`domains`,value:e.domains}])});return}let t=e.body===void 0?void 0:h(_(e.body),[{name:`domains`,field:`domains`,value:e.domains}]),r=await n(e),a=e.local?o:await c();if(e.accountId=a,e.body!==void 0){let e=t,n=await u(`Creating`,async()=>r.send(F,{body:e,account_id:a}));l(n,{successLabel:`Created`});return}let d=v({domains:e.domains}),f=await u(`Creating`,async()=>r.send(F,{body:d,account_id:a}));l(f,{successLabel:`Created`})})};var _e={method:`GET`,path:e=>r`/accounts/${e.account_id}/registrar/registrations/${e.domain_name}/registration-status`};function ve(e){return e.usage("$0 registrar registrations get-registration-status <domain-name>\n\nReturns the current status of a domain registration workflow. Use this endpoint to poll for completion when the POST response returned `202 Accepted`. The URL is provided in the `links.self` field of the workflow status response. Poll this endpoint until the workflow reaches a terminal state or a state that requires user attention. **Terminal states:** `succeeded` and `failed` are terminal and always have `completed: true`. **Non-terminal states:** - `action_required` has `completed: false` and will not resolve on its own. The workflow is paused pending user intervention. - `blocked` has `completed: false` and indicates the workflow is waiting on a third party such as the extension registry or losing registrar. Continue polling while informing the user of the delay. Use increasing backoff between polls. When `state: blocked`, use a longer polling interval and do not poll indefinitely. A naive polling loop that only checks `completed` can run indefinitely when `state: action_required`. Break explicitly on `action_required`: ```js let status; do { await new Promise(r => setTimeout(r, 2000)); status = await cloudflare.request({ method: 'GET', path: reg.result.links.self, }); } while ( !status.result.completed && status.result.state !== 'action_required' ); if (status.result.state === 'action_required') { // Surface context.action and context.confirmation_sent_to to the user. // Do not re-submit the registration request. } ```").positional(`domain-name`,{type:`string`,description:"Provides a fully qualified domain name (FQDN), including the extension (e.g., `example.com`, `mybrand.app`). The domain name uniquely identifies a registration. Cloudflare permits only one registration per domain, making the domain name a natural idempotency key for registration requests.",demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const ye={command:`get-registration-status <domain-name>`,describe:`Get Registration Status`,builder:ve,handler:async e=>f({command:`registrar registrations get-registration-status`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await s();i({command:`cf registrar registrations get-registration-status`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/registrar/registrations/${e[`domain-name`]==null?`<domain-name>`:encodeURIComponent(String(e[`domain-name`]))}/registration-status`,pathParams:{"domain-name":String(e[`domain-name`]??``)},bodyKind:`none`});return}let t=await n(e),r=e.local?o:await c();e.accountId=r;let a=await u(`Loading`,async()=>t.send(_e,{account_id:r,domain_name:e[`domain-name`]}));l(a,{successLabel:`Loaded`})})};var be={method:`GET`,path:e=>r`/accounts/${e.account_id}/registrar/registrations/${e.domain_name}/transfer-in-status`};function xe(e){return e.usage("$0 registrar registrations get-transfer-status <domain-name>\n\nReturns the current status of a domain transfer workflow. Use this endpoint to poll transfer progress after initiating a transfer with `POST /accounts/{account_id}/registrar/registrations/{domain_name}/transfer-in`. The URL is provided in the `links.self` field of the transfer response. ### Transfer timelines Transfers typically take 1–10 days due to ICANN-mandated approval windows. ### Workflow states **Terminal states:** `succeeded` and `failed` are terminal and always have `completed: true`. **Non-terminal states:** - `in_progress`: Transfer has been submitted to the registry and is being processed. Continue polling. - `blocked`: The workflow is waiting on the losing registrar or registry to release the domain. This is the **most common state** for transfers and is entirely normal — it means the ICANN transfer approval window is in effect. The losing registrar has up to 5 days to approve or reject. Continue polling with longer intervals (e.g., every 30–60 minutes). - `action_required`: The user needs to take action (e.g., the FOA email needs to be accepted). See `context` for details on what is needed. - `pending`: Transfer workflow created but not yet started processing. ### Polling guidance Adjust your polling interval based on the current workflow state: - `pending` or `in_progress`: Poll every 30 seconds. - `blocked`: The transfer is waiting on a third party (e.g., losing registrar approval). Poll every 30–60 minutes. - `action_required`: Stop polling. The workflow will not advance until the user takes action. Check `context` for details on what is needed. - `succeeded` or `failed`: Terminal — stop polling.").positional(`domain-name`,{type:`string`,description:"Provides a fully qualified domain name (FQDN), including the extension (e.g., `example.com`, `mybrand.app`). The domain name uniquely identifies a registration. Cloudflare permits only one registration per domain, making the domain name a natural idempotency key for registration requests.",demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const Se={command:`get-transfer-status <domain-name>`,describe:`Get Transfer Status`,builder:xe,handler:async e=>f({command:`registrar registrations get-transfer-status`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await s();i({command:`cf registrar registrations get-transfer-status`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/registrar/registrations/${e[`domain-name`]==null?`<domain-name>`:encodeURIComponent(String(e[`domain-name`]))}/transfer-in-status`,pathParams:{"domain-name":String(e[`domain-name`]??``)},bodyKind:`none`});return}let t=await n(e),r=e.local?o:await c();e.accountId=r;let a=await u(`Loading`,async()=>t.send(be,{account_id:r,domain_name:e[`domain-name`]}));l(a,{successLabel:`Loaded`})})};var Ce={method:`GET`,path:e=>r`/accounts/${e.account_id}/registrar/registrations/${e.domain_name}/update-status`};function we(e){return e.usage("$0 registrar registrations get-update-status <domain-name>\n\nReturns the current status of a domain update workflow. Use this endpoint to poll for completion when the PATCH response returned `202 Accepted`. The URL is provided in the `links.self` field of the workflow status response. Poll this endpoint until the workflow reaches a terminal state or a state that requires user attention. Use increasing backoff between polls. When the workflow remains blocked on a third party, use a longer polling interval and do not poll indefinitely.").positional(`domain-name`,{type:`string`,description:"Provides a fully qualified domain name (FQDN), including the extension (e.g., `example.com`, `mybrand.app`). The domain name uniquely identifies a registration. Cloudflare permits only one registration per domain, making the domain name a natural idempotency key for registration requests.",demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const Te={command:`get-update-status <domain-name>`,describe:`Get Update Status`,builder:we,handler:async e=>f({command:`registrar registrations get-update-status`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await s();i({command:`cf registrar registrations get-update-status`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/registrar/registrations/${e[`domain-name`]==null?`<domain-name>`:encodeURIComponent(String(e[`domain-name`]))}/update-status`,pathParams:{"domain-name":String(e[`domain-name`]??``)},bodyKind:`none`});return}let t=await n(e),r=e.local?o:await c();e.accountId=r;let a=await u(`Loading`,async()=>t.send(Ce,{account_id:r,domain_name:e[`domain-name`]}));l(a,{successLabel:`Loaded`})})};var Ee={method:`GET`,path:e=>r`/accounts/${e.account_id}/registrar/registrations/${e.domain_name}`};function De(e){return e.usage("$0 registrar registrations get <domain-name>\n\nReturns the current state of a domain registration. This is the canonical read endpoint for a domain you own. It returns the full registration resource including current settings and expiration. When the registration resource is ready, both `created_at` and `expires_at` are present in the response.").positional(`domain-name`,{type:`string`,description:`Domain name to retrieve.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const Oe={command:`get <domain-name>`,describe:`Get Registration`,builder:De,handler:async e=>f({command:`registrar registrations get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await s();i({command:`cf registrar registrations get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/registrar/registrations/${e[`domain-name`]==null?`<domain-name>`:encodeURIComponent(String(e[`domain-name`]))}`,pathParams:{"domain-name":String(e[`domain-name`]??``)},bodyKind:`none`});return}let t=await n(e),r=e.local?o:await c();e.accountId=r;let a=await u(`Loading`,async()=>t.send(Ee,{account_id:r,domain_name:e[`domain-name`]}));l(a,{successLabel:`Loaded`})})};var ke={method:`GET`,path:e=>r`/accounts/${e.account_id}/registrar/registrations`,query:[`cursor`,`per_page`,`direction`,`sort_by`]};function Ae(e){return e.usage("$0 registrar registrations list\n\nReturns a paginated list of domain registrations owned by the account. This endpoint uses cursor-based pagination. Results are ordered by registration date by default. To fetch the next page, pass the `cursor` value from the `result_info` object in the response as the `cursor` query parameter in your next request. An empty `cursor` string indicates there are no more pages.").option(`cursor`,{type:`string`,description:`Opaque token from a previous response's \`result_info.cursor\`.
|
|
5
5
|
Pass this value to fetch the next page of results. Omit (or
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{i as t,n}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{i as t,n}from"./auth-CRq9OQKr.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{a as i,t as a}from"./context-DsVjrTbe.mjs";import{t as o}from"./local-B3zt9PXR.mjs";import{t as s}from"./output-PRKYaJuo.mjs";import{t as c}from"./progress-DItBn6ZV.mjs";import{t as l}from"./run-DAK_kbUa.mjs";import"./telemetry-B3S5OfOn.mjs";import{c as u,i as d,n as f,r as p,t as m}from"./body-parser-HN91kAf0.mjs";import{n as h}from"./input-validation-D7z60HJH.mjs";import{a as g}from"./prompt-BGz3DNLz.mjs";var _={method:`GET`,path:t=>e`/accounts/${t.account_id}/registrar-sandbox/extensions/${t.extension}`};function v(e){return e.usage("$0 registrar-sandbox extensions get <extension>\n\nReturns metadata and JSON Schema documents describing the expected input structure for registration and transfer operations on a specific extension (TLD). Supports HTTP conditional GET via `ETag`. Include the `ETag` value from a previous response in an `If-None-Match` header to receive a `304 Not Modified` when the data has not changed.").positional(`extension`,{type:`string`,description:"The extension name (e.g., `com`, `co.uk`).",demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const y={command:`get <extension>`,describe:`Get extension`,builder:v,handler:async e=>l({command:`registrar-sandbox extensions get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf registrar-sandbox extensions get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/registrar-sandbox/extensions/${e.extension==null?`<extension>`:encodeURIComponent(String(e.extension))}`,pathParams:{extension:String(e.extension??``)},bodyKind:`none`});return}let t=await n(e),l=e.local?o:await a();e.accountId=l;let u=await c(`Loading`,async()=>t.send(_,{account_id:l,extension:e.extension}));s(u,{successLabel:`Loaded`})})};var b={method:`GET`,path:t=>e`/accounts/${t.account_id}/registrar-sandbox/extensions`,query:[`name`,`cursor`,`per_page`,`direction`,`sort_by`]};function x(e){return e.usage("$0 registrar-sandbox extensions list\n\nReturns metadata and JSON Schema documents describing the expected input structure for registration and transfer operations on each supported extension (TLD). This endpoint uses cursor-based pagination. Results are ordered by extension name by default. To fetch the next page, pass the `cursor` value from the `result_info` object in the response as the `cursor` query parameter in your next request. An empty `cursor` string indicates there are no more pages. Supports HTTP conditional GET via `ETag`. Include the `ETag` value from a previous response in an `If-None-Match` header to receive a `304 Not Modified` when the data has not changed.").option(`name`,{type:`string`,description:"Filter extensions by exact name match.\nFor example, `name=com` returns only the `com` extension."}).option(`cursor`,{type:`string`,description:`Opaque token from a previous response's \`result_info.cursor\`.
|
|
3
3
|
Pass this value to fetch the next page of results. Omit (or
|
|
4
4
|
pass an empty string) for the first page.`}).option(`per-page`,{type:`number`,description:`Number of items to return per page.`}).option(`direction`,{type:`string`,description:`Sort direction for results. Defaults to ascending order.`,choices:[`asc`,`desc`]}).option(`sort-by`,{type:`string`,description:"Column to sort results by. Defaults to `name` when omitted.",choices:[`name`,`created_at`,`updated_at`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const S={command:`list`,describe:`List extensions`,builder:x,handler:async e=>l({command:`registrar-sandbox extensions list`,classification:{safeFlags:[`direction`,`sort-by`,`dry-run`]}},e,async()=>{let t={name:e.name,cursor:e.cursor,per_page:e[`per-page`],direction:e.direction,sort_by:e[`sort-by`]};if(e.dryRun){let e=await i();r({command:`cf registrar-sandbox extensions list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/registrar-sandbox/extensions`,pathParams:{},query:t,bodyKind:`none`});return}let l=await n(e),u=e.local?o:await a();e.accountId=u;let d=await c(`Loading`,async()=>l.send(b,{account_id:u,...t}));s(d,{successLabel:`Loaded`})})},C={command:`extensions`,describe:`Operations for extensions`,builder:e=>e.command(y).command(S).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var w={method:`POST`,path:t=>e`/accounts/${t.account_id}/registrar-sandbox/domain-check`,body:`json`,errors:{400:`BadRequestError`}};function T(e){return e.usage("$0 registrar-sandbox registrations check <domains...>\n\nPerforms real-time, authoritative availability checks directly against domain registries. Use this endpoint to verify a domain is available before attempting registration via `POST /registrations`. **Important:** Unlike the Search endpoint, these results are authoritative and reflect current registry status. Always check availability immediately before registration as domain status can change rapidly. **Note:** This endpoint uses POST to accept a list of domains in the request body. It is a read-only operation — it does not create, modify, or reserve any domains. ### Extension support Only domains on extensions supported for programmatic registration by this API can be registered. If you check a domain on an unsupported extension, the response will include `registrable: false` with a `reason` field explaining why: - `extension_not_supported_via_api` — Cloudflare Registrar supports this extension in the dashboard, but it is not yet available for programmatic registration via this API. Register via `https://dash.cloudflare.com/{account_id}/domains/registrations` instead. - `extension_not_supported` — This extension is not supported by Cloudflare Registrar. - `extension_disallows_registration` — The extension's registry has temporarily or permanently frozen new registrations. No registrar can register domains on this extension at this time. - `domain_premium` — The domain is premium priced. Premium registration is not currently supported by this API. - `domain_unavailable` — The domain is already registered, reserved, or otherwise not available for registration on a supported extension. The `reason` field is only present when `registrable` is `false`. ### Behavior - Maximum 20 domains per request - Pricing is only returned for domains where `registrable: true` - Results are not cached; each request queries the registry ### Workflow 1. Call this endpoint with domains the user wants to register. 2. For each domain where `registrable: true`, present pricing to the user. 3. If `tier: premium`, note that premium registration is not currently supported by this API and do not proceed to `POST /registrations`. 4. Proceed to `POST /registrations` only for supported non-premium domains.").positional(`domains`,{type:`string`,array:!0,description:"List of fully qualified domain names (FQDNs) to check for availability. Each domain must include the extension. - Minimum: 1 domain. - Maximum: 20 domains per request. - The response returns domains on unsupported extensions with `registrable: false` and a `reason` field. - The response may omit malformed domain names (e.g., names missing an extension). ",demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`List of fully qualified domain names (FQDNs) to check. Each domain must include the extension (e.g., "example.com", not "example").`})}const E={command:`check <domains...>`,describe:`Check domain availability`,builder:T,handler:async e=>l({command:`registrar-sandbox registrations check`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await i();r({command:`cf registrar-sandbox registrations check`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/registrar-sandbox/domain-check`,pathParams:{},bodyKind:`json`,body:e.body===void 0?m({domains:e.domains}):f(p(e.body),[{name:`domains`,field:`domains`,value:e.domains}])});return}let t=e.body===void 0?void 0:f(p(e.body),[{name:`domains`,field:`domains`,value:e.domains}]),l=await n(e),u=e.local?o:await a();if(e.accountId=u,e.body!==void 0){let e=t,n=await c(`Creating`,async()=>l.send(w,{body:e,account_id:u}));s(n,{successLabel:`Created`});return}let d=m({domains:e.domains}),h=await c(`Creating`,async()=>l.send(w,{body:d,account_id:u}));s(h,{successLabel:`Created`})})};function D(e){return e.usage("$0 registrar-sandbox registrations create\n\nStarts a domain registration workflow. ### Prerequisites - The account must not already be at the maximum supported domain limit. A single account may own up to 500 domains in total across registrations created through either the dashboard or this API. - The domain must be on a supported extension for programmatic registration. - Use `POST /domain-check` immediately before calling this endpoint to confirm real-time availability and pricing. ### Defaults - `years`: defaults to the extension's minimum registration period (1 year for most extensions, but varies — for example, `.ai` (if supported) requires a minimum of 2 years). - `auto_renew`: defaults to `false`. Setting it to `true` is an explicit opt-in authorizing Cloudflare to charge the account's default payment method up to 30 days before domain expiry to renew the registration. Renewal pricing may change over time based on registry pricing. - `privacy_mode`: defaults to `redaction`. ### Premium domains Premium domain registration is not currently supported by this API. If `POST /domain-check` returns `tier: premium`, do not call this endpoint for that domain. ### Response behavior By default, the server holds the connection for a bounded, server-defined amount of time while the registration completes. Most registrations finish within this window and return `201 Created` with a completed workflow status. If the registration is still processing after this synchronous wait window, the server returns `202 Accepted`. Poll the URL in `links.self` to track progress. To skip the wait and receive an immediate `202`, send `Prefer: respond-async`.").option(`prefer`,{type:`string`,description:`Set to \`respond-async\` to receive an immediate \`202 Accepted\` without
|
|
5
5
|
waiting for the operation to complete (RFC 7240).
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-CRq9OQKr.mjs";import{t as n}from"./dry-run-mrA7FFLR.mjs";import{a as r,t as i}from"./context-DsVjrTbe.mjs";import{t as a}from"./local-B3zt9PXR.mjs";import{t as o}from"./output-PRKYaJuo.mjs";import{t as s}from"./progress-DItBn6ZV.mjs";import{t as c}from"./run-DAK_kbUa.mjs";import"./telemetry-B3S5OfOn.mjs";import{r as l,t as u}from"./body-parser-HN91kAf0.mjs";import{n as d}from"./input-validation-D7z60HJH.mjs";import{i as f}from"./prompt-BGz3DNLz.mjs";var p={method:`GET`,path:t=>e`/accounts/${t.account_id}/reporting/industry`,errors:{400:`BadRequestError`}};function m(e){return e.usage(`$0 reporting industry get
|
|
3
3
|
|
|
4
4
|
Gets the industry classification for an account.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const h={command:`get`,describe:`Get an account industry`,builder:m,handler:async e=>c({command:`reporting industry get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let e=await r();n({command:`cf reporting industry get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/reporting/industry`,pathParams:{},bodyKind:`none`});return}let c=await t(e),l=e.local?a:await i();e.accountId=l;let u=await s(`Loading`,async()=>c.send(p,{account_id:l}));o(u,{successLabel:`Loaded`})})};var g={method:`PATCH`,path:t=>e`/accounts/${t.account_id}/reporting/industry`,body:`json`,errors:{400:`BadRequestError`,423:`LockedError`,500:`InternalServerError`}};function _(e){return e.usage(`$0 reporting industry update
|
|
5
5
|
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{n as e}from"./interactive-
|
|
2
|
+
import{n as e}from"./interactive-CQ29h7qo.mjs";import{t}from"./version-5uL0ecbB.mjs";import{t as n}from"./agent-context-Dtyy4aKL.mjs";import{t as r}from"./interactive-wQM7Blhm.mjs";function i(){return r?`ci`:e()?`interactive`:`non-interactive`}function a(){let e=n(),r=e.isAgentic&&e.harness!==null?{"X-CF-CLI-Agent":e.harness.id}:{};return{"User-Agent":t,"X-CF-CLI-Mode":i(),...r}}export{a as n,i as t};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-CRq9OQKr.mjs";import{i as n,r,t as i}from"./body-parser-HN91kAf0.mjs";import{a,t as o}from"./context-DsVjrTbe.mjs";import{t as s}from"./dry-run-mrA7FFLR.mjs";import{n as c}from"./input-validation-D7z60HJH.mjs";import{t as l}from"./local-B3zt9PXR.mjs";import{t as u}from"./run-DAK_kbUa.mjs";import{t as d}from"./output-PRKYaJuo.mjs";import{t as f}from"./progress-DItBn6ZV.mjs";import{a as p}from"./prompt-BGz3DNLz.mjs";import"./telemetry-B3S5OfOn.mjs";var m={method:`POST`,path:t=>e`/accounts/${t.account_id}/request-tracer/trace`,body:`json`};function h(e){return e.usage(`$0 request-tracers traces create
|
|
3
3
|
|
|
4
4
|
Traces a simulated HTTP request through Cloudflare's edge to analyze how rules, settings, and configurations would process the request. Useful for debugging firewall rules, page rules, and other request transformations without sending actual traffic. Supports custom headers, cookies, body content, and geolocation context.`).option(`body-base64`,{type:`string`,description:`Base64 encoded request body`}).option(`body-json`,{type:`string`,description:`Arbitrary json as request body. Provide as a JSON object or @path/to/file.json. Shape: {"<key>": unknown}.`}).option(`body-plain-text`,{type:`string`,description:`Request body as plain text`}).option(`context-bot-score`,{type:`number`,description:`Bot score used for evaluating tracing request processing`}).option(`context-geoloc-city`,{type:`string`,description:`The context.geoloc.city field`}).option(`context-geoloc-continent`,{type:`string`,description:`The context.geoloc.continent field`}).option(`context-geoloc-is-eu-country`,{type:`boolean`,description:`The context.geoloc.is_eu_country field`}).option(`context-geoloc-iso-code`,{type:`string`,description:`The context.geoloc.iso_code field`}).option(`context-geoloc-latitude`,{type:`number`,description:`The context.geoloc.latitude field`}).option(`context-geoloc-longitude`,{type:`number`,description:`The context.geoloc.longitude field`}).option(`context-geoloc-postal-code`,{type:`string`,description:`The context.geoloc.postal_code field`}).option(`context-geoloc-region-code`,{type:`string`,description:`The context.geoloc.region_code field`}).option(`context-geoloc-subdivision-2-iso-code`,{type:`string`,description:`The context.geoloc.subdivision_2_iso_code field`}).option(`context-geoloc-timezone`,{type:`string`,description:`The context.geoloc.timezone field`}).option(`context-skip-challenge`,{type:`boolean`,description:`Whether to skip any challenges for tracing request (e.g.: captcha)`}).option(`context-threat-score`,{type:`number`,description:`Threat score used for evaluating tracing request processing`}).option(`cookies`,{type:`string`,description:`Cookies added to tracing request. Provide as a JSON object or @path/to/file.json. Shape: {"<key>": string}.`}).option(`headers`,{type:`string`,description:`Headers added to tracing request. Provide as a JSON object or @path/to/file.json. Shape: {"<key>": string}.`}).option(`method`,{type:`string`,description:`HTTP Method of tracing request`}).option(`protocol`,{type:`string`,description:`HTTP Protocol of tracing request`}).option(`skip-response`,{type:`boolean`,description:`Skip sending the request to the Origin server after all rules evaluation`}).option(`url`,{type:`string`,description:`URL to which perform tracing request`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const g={command:`create`,describe:`Request Trace`,builder:h,handler:async e=>u({command:`request-tracers traces create`,classification:{safeFlags:[`context-geoloc-is-eu-country`,`context-skip-challenge`,`skip-response`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=await a();s({command:`cf request-tracers traces create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/request-tracer/trace`,pathParams:{},bodyKind:`json`,body:e.body===void 0?i({body:{base64:c(e[`body-base64`],`body-base64`,`text`),json:n(e[`body-json`],`body-json`),plain_text:c(e[`body-plain-text`],`body-plain-text`,`text`)},context:{bot_score:e[`context-bot-score`],geoloc:{city:c(e[`context-geoloc-city`],`context-geoloc-city`,`text`),continent:c(e[`context-geoloc-continent`],`context-geoloc-continent`,`text`),is_eu_country:e[`context-geoloc-is-eu-country`],iso_code:c(e[`context-geoloc-iso-code`],`context-geoloc-iso-code`,`text`),latitude:e[`context-geoloc-latitude`],longitude:e[`context-geoloc-longitude`],postal_code:c(e[`context-geoloc-postal-code`],`context-geoloc-postal-code`,`text`),region_code:c(e[`context-geoloc-region-code`],`context-geoloc-region-code`,`text`),subdivision_2_iso_code:c(e[`context-geoloc-subdivision-2-iso-code`],`context-geoloc-subdivision-2-iso-code`,`text`),timezone:c(e[`context-geoloc-timezone`],`context-geoloc-timezone`,`text`)},skip_challenge:e[`context-skip-challenge`],threat_score:e[`context-threat-score`]},cookies:n(e.cookies,`cookies`),headers:n(e.headers,`headers`),method:c(e.method,`method`,`text`),protocol:c(e.protocol,`protocol`,`text`),skip_response:e[`skip-response`],url:c(e.url,`url`,`text`)},[[`body`,`json`],[`cookies`],[`headers`]]):r(e.body)});return}let u=e.body===void 0?void 0:r(e.body),h=await t(e),g=e.local?l:await o();if(e.accountId=g,e.body!==void 0){let e=u,t=await f(`Creating`,async()=>h.send(m,{body:e,account_id:g}));d(t,{successLabel:`Created`});return}e.method===void 0&&(e.method=await p(`method`,`HTTP Method of tracing request`)),e.url===void 0&&(e.url=await p(`url`,`URL to which perform tracing request`));let _=i({body:{base64:c(e[`body-base64`],`body-base64`,`text`),json:n(e[`body-json`],`body-json`),plain_text:c(e[`body-plain-text`],`body-plain-text`,`text`)},context:{bot_score:e[`context-bot-score`],geoloc:{city:c(e[`context-geoloc-city`],`context-geoloc-city`,`text`),continent:c(e[`context-geoloc-continent`],`context-geoloc-continent`,`text`),is_eu_country:e[`context-geoloc-is-eu-country`],iso_code:c(e[`context-geoloc-iso-code`],`context-geoloc-iso-code`,`text`),latitude:e[`context-geoloc-latitude`],longitude:e[`context-geoloc-longitude`],postal_code:c(e[`context-geoloc-postal-code`],`context-geoloc-postal-code`,`text`),region_code:c(e[`context-geoloc-region-code`],`context-geoloc-region-code`,`text`),subdivision_2_iso_code:c(e[`context-geoloc-subdivision-2-iso-code`],`context-geoloc-subdivision-2-iso-code`,`text`),timezone:c(e[`context-geoloc-timezone`],`context-geoloc-timezone`,`text`)},skip_challenge:e[`context-skip-challenge`],threat_score:e[`context-threat-score`]},cookies:n(e.cookies,`cookies`),headers:n(e.headers,`headers`),method:c(e.method,`method`,`text`),protocol:c(e.protocol,`protocol`,`text`),skip_response:e[`skip-response`],url:c(e.url,`url`,`text`)},[[`body`,`json`],[`cookies`],[`headers`]]),v=await f(`Creating`,async()=>h.send(m,{body:_,account_id:g}));d(v,{successLabel:`Created`})})},_={command:`traces`,describe:`Simulate request processing to debug rule matches, transforms, and routing decisions`,builder:e=>e.command(g).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},v={command:`request-tracers`,describe:`Trace how a request would be processed through Cloudflare's rules and configuration pipeline`,builder:e=>e.command(_).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{v as default};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-CRq9OQKr.mjs";import{i as n,o as r,r as i,t as a}from"./body-parser-HN91kAf0.mjs";import{a as o,t as s}from"./context-DsVjrTbe.mjs";import{t as c}from"./dry-run-mrA7FFLR.mjs";import{n as l}from"./input-validation-D7z60HJH.mjs";import{t as u}from"./local-B3zt9PXR.mjs";import{t as d}from"./run-DAK_kbUa.mjs";import{t as f}from"./output-PRKYaJuo.mjs";import{t as p}from"./progress-DItBn6ZV.mjs";import{a as m,i as h,n as g}from"./prompt-BGz3DNLz.mjs";import"./telemetry-B3S5OfOn.mjs";var _={method:`POST`,path:t=>e`/accounts/${t.account_id}/shares`,body:`json`};function v(e){return e.usage(`$0 resource-sharing create
|
|
3
3
|
|
|
4
4
|
Creates a share that makes a resource available to specific accounts in the caller's organization, or to the whole organization.`).option(`excluded-recipients`,{type:`string`,description:'Accounts to exclude from an organization-targeted share. Only allowed when `recipients` contains no account entries. The share owner cannot be excluded. Duplicate entries are ignored. Provide as a JSON array of objects or @path/to/file.json. Shape: [{"account_id": string}].'}).option(`name`,{type:`string`,description:`The name of the share.`}).option(`recipients`,{type:`string`,description:`The recipients field. Provide as a JSON array of objects or @path/to/file.json. Shape: [{"account_id"?: string, "organization_id"?: string, "recipient_account_id"?: string}]. ? marks optional keys.`}).option(`resources`,{type:`string`,description:`The resources field. Provide as a JSON array of objects or @path/to/file.json. Shape: [{"meta": {...}, "resource_account_id": string, "resource_id": string, "resource_type": "custom-ruleset" | "gateway-policy" | "gateway-destination-ip" | ...more}].`}).option(`tags`,{type:`string`,description:`Tags associated with the share. Provide as a JSON object or @path/to/file.json. Shape: {"<key>": string}.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const y={command:`create`,describe:`Trigger a share creation`,builder:v,handler:async e=>d({command:`resource-sharing create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await o();c({command:`cf resource-sharing create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/shares`,pathParams:{},bodyKind:`json`,body:e.body===void 0?a({excluded_recipients:r(e[`excluded-recipients`],`excluded-recipients`),name:l(e.name,`name`,`text`),recipients:r(e.recipients,`recipients`),resources:r(e.resources,`resources`),tags:n(e.tags,`tags`)},[[`tags`]]):i(e.body)});return}let d=e.body===void 0?void 0:i(e.body),h=await t(e),g=e.local?u:await s();if(e.accountId=g,e.body!==void 0){let e=d,t=await p(`Creating`,async()=>h.send(_,{body:e,account_id:g}));f(t,{successLabel:`Created`});return}e.name===void 0&&(e.name=await m(`name`,`The name of the share.`));let v=a({excluded_recipients:r(e[`excluded-recipients`],`excluded-recipients`),name:l(e.name,`name`,`text`),recipients:r(e.recipients,`recipients`),resources:r(e.resources,`resources`),tags:n(e.tags,`tags`)},[[`tags`]]),y=await p(`Creating`,async()=>h.send(_,{body:v,account_id:g}));f(y,{successLabel:`Created`})})};var b={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/shares/${t.share_id}`};function ee(e){return e.usage(`$0 resource-sharing delete <share-id>
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-CRq9OQKr.mjs";import{t as n}from"./dry-run-mrA7FFLR.mjs";import{a as r,t as i}from"./context-DsVjrTbe.mjs";import{t as a}from"./local-B3zt9PXR.mjs";import{t as o}from"./output-PRKYaJuo.mjs";import{t as s}from"./progress-DItBn6ZV.mjs";import{t as c}from"./run-DAK_kbUa.mjs";import"./telemetry-B3S5OfOn.mjs";import{o as l,r as u,t as d}from"./body-parser-HN91kAf0.mjs";import{n as f}from"./input-validation-D7z60HJH.mjs";import{a as p,i as m,n as h}from"./prompt-BGz3DNLz.mjs";var g={method:`GET`,path:t=>e`/accounts/${t.account_id}/rules/lists/bulk_operations/${t.operation_id}`};function _(e){return e.usage("$0 rules lists bulk-operations get <operation-id>\n\nGets the current status of an asynchronous operation on a list. The `status` property can have one of the following values: `pending`, `running`, `completed`, or `failed`. If the status is `failed`, the `error` property will contain a message describing the error.").positional(`operation-id`,{type:`string`,description:`The unique operation ID of the asynchronous action.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const v={command:`get <operation-id>`,describe:`Get bulk operation status`,builder:_,handler:async e=>c({command:`rules lists bulk-operations get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await r();n({command:`cf rules lists bulk-operations get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/rules/lists/bulk_operations/${e[`operation-id`]==null?`<operation-id>`:encodeURIComponent(String(e[`operation-id`]))}`,pathParams:{"operation-id":String(e[`operation-id`]??``)},bodyKind:`none`});return}let c=await t(e),l=e.local?a:await i();e.accountId=l;let u=await s(`Loading`,async()=>c.send(g,{account_id:l,operation_id:e[`operation-id`]}));o(u,{successLabel:`Loaded`})})},y={command:`bulk-operations`,describe:`Operations for lists.bulk-operations`,builder:e=>e.command(v).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var b={method:`POST`,path:t=>e`/accounts/${t.account_id}/rules/lists`,body:`json`};function x(e){return e.usage(`$0 rules lists create
|
|
3
3
|
|
|
4
4
|
Creates a new list of the specified kind.`).option(`description`,{type:`string`,description:`An informative summary of the list.`}).option(`kind`,{type:`string`,description:`The type of the list. Each type supports specific list items (IP addresses, ASNs, hostnames or redirects).`,choices:[`ip`,`redirect`,`hostname`,`asn`]}).coerce(`kind`,e=>f(e,`kind`,`text`)).option(`name`,{type:`string`,description:`An informative name for the list. Use this name in filter and rule expressions.`}).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 S={command:`create`,describe:`Create a list`,builder:x,handler:async e=>c({command:`rules lists create`,classification:{safeFlags:[`kind`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=await r();n({command:`cf rules lists create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/rules/lists`,pathParams:{},bodyKind:`json`,body:e.body===void 0?d({description:f(e.description,`description`,`text`),kind:e.kind,name:f(e.name,`name`,`text`)}):u(e.body)});return}let c=e.body===void 0?void 0:u(e.body),l=await t(e),h=e.local?a:await i();if(e.accountId=h,e.body!==void 0){let e=c,t=await s(`Creating`,async()=>l.send(b,{body:e,account_id:h}));o(t,{successLabel:`Created`});return}e.kind===void 0&&(e.kind=await m(`kind`,`The type of the list. Each type supports specific list items (IP addresses, ASNs, hostnames or redirects).`,[`ip`,`redirect`,`hostname`,`asn`])),e.name===void 0&&(e.name=await p(`name`,`An informative name for the list. Use this name in filter and rule expressions.`));let g=d({description:f(e.description,`description`,`text`),kind:e.kind,name:f(e.name,`name`,`text`)}),_=await s(`Creating`,async()=>l.send(b,{body:g,account_id:h}));o(_,{successLabel:`Created`})})};var C={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/rules/lists/${t.list_id}`};function w(e){return e.usage(`$0 rules lists delete <list-id>
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{i as t,n}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{i as t,n}from"./auth-CRq9OQKr.mjs";import{c as r,o as i,r as a,t as o}from"./body-parser-HN91kAf0.mjs";import{a as s,i as c,t as l}from"./context-DsVjrTbe.mjs";import{t as u}from"./dry-run-mrA7FFLR.mjs";import{n as d}from"./input-validation-D7z60HJH.mjs";import{t as f}from"./local-B3zt9PXR.mjs";import{t as p}from"./run-DAK_kbUa.mjs";import{t as m}from"./output-PRKYaJuo.mjs";import{t as h}from"./progress-DItBn6ZV.mjs";import"./telemetry-B3S5OfOn.mjs";import{n as g}from"./prompt-BGz3DNLz.mjs";var _={method:`POST`,path:t=>e`/${t.account_or_zone}/${t.account_or_zone_id}/rulesets`,query:[`dry_run`],body:`json`};function v(e){return e.usage(`$0 rulesets create
|
|
3
3
|
|
|
4
4
|
Creates a ruleset.
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-CRq9OQKr.mjs";import{o as n,r,t as i}from"./body-parser-HN91kAf0.mjs";import{a,t as o}from"./context-DsVjrTbe.mjs";import{t as s}from"./dry-run-mrA7FFLR.mjs";import{t as c}from"./local-B3zt9PXR.mjs";import{t as l}from"./output-PRKYaJuo.mjs";import{t as u}from"./run-DAK_kbUa.mjs";import{t as d}from"./progress-DItBn6ZV.mjs";import"./telemetry-B3S5OfOn.mjs";import{n as f}from"./input-validation-D7z60HJH.mjs";import{n as p}from"./prompt-BGz3DNLz.mjs";var m={method:`POST`,path:t=>e`/accounts/${t.account_id}/rum/v2/${t.ruleset_id}/rules`,body:`json`};function h(e){return e.usage(`$0 rum rules bulk-create
|
|
3
3
|
|
|
4
4
|
Modifies one or more rules in a Web Analytics ruleset with a single request.`).option(`ruleset-id`,{type:`string`,description:`The Web Analytics ruleset identifier.`,demandOption:!0}).option(`delete-rules`,{type:`string`,array:!0,description:`A list of rule identifiers to delete.`}).option(`rules`,{type:`string`,description:`A list of rules to create or update. Provide as a JSON array of objects or @path/to/file.json. Shape: [{"host"?: string, "id"?: string, "inclusive"?: boolean, "is_paused"?: boolean, "paths"?: [string]}]. ? marks optional keys.`}).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:`bulk-create`,describe:`Update Web Analytics rules`,builder:h,handler:async e=>u({command:`rum rules bulk-create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await a();s({command:`cf rum rules bulk-create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/rum/v2/${e[`ruleset-id`]==null?`<ruleset-id>`:encodeURIComponent(String(e[`ruleset-id`]))}/rules`,pathParams:{"ruleset-id":String(e[`ruleset-id`]??``)},bodyKind:`json`,body:e.body===void 0?i({delete_rules:e[`delete-rules`],rules:n(e.rules,`rules`)}):r(e.body)});return}let u=e.body===void 0?void 0:r(e.body),f=await t(e),p=e.local?c:await o();if(e.accountId=p,e.body!==void 0){let t=u,n=await d(`Creating`,async()=>f.send(m,{body:t,account_id:p,ruleset_id:e[`ruleset-id`]}));l(n,{successLabel:`Created`});return}let h=i({delete_rules:e[`delete-rules`],rules:n(e.rules,`rules`)}),g=await d(`Creating`,async()=>f.send(m,{body:h,account_id:p,ruleset_id:e[`ruleset-id`]}));l(g,{successLabel:`Created`})})};var _={method:`POST`,path:t=>e`/accounts/${t.account_id}/rum/v2/${t.ruleset_id}/rule`,body:`json`};function v(e){return e.usage(`$0 rum rules create <ruleset-id>
|
|
5
5
|
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{n as t}from"./interactive-
|
|
2
|
+
import{t as e}from"./cli-exit-CstFZ1eJ.mjs";import{n as t}from"./interactive-CQ29h7qo.mjs";import{n}from"./version-5uL0ecbB.mjs";import{t as r}from"./agent-context-Dtyy4aKL.mjs";import{t as i}from"./interactive-wQM7Blhm.mjs";import{t as a}from"./request-headers-CUwBDAwI.mjs";import{tt as o}from"./dist-BoDdDWjK.mjs";import{n as s,t as c}from"./state-BFClIYM_.mjs";import{n as l,t as u}from"./delegate-4bIHEQ8-.mjs";import{i as d,r as f}from"./lifecycle-oud60haK.mjs";import{t as p}from"./error-sanitization-BkgtZ0Vx.mjs";import{r as m}from"./sanitization-DkVWMHkc.mjs";import h from"node:os";import{createHash as g,randomUUID as _}from"node:crypto";const v=/* @__PURE__ */ new Date(`2026-01-01T00:00:00.000Z`),y=`CF_SEND_TELEMETRY`,b=`WRANGLER_SEND_METRICS`,x=/^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i;function S(e){if(e===void 0)return;let t=e.trim().toLowerCase();if(t===`true`||t===`1`)return!0;if(t===`false`||t===`0`)return!1}function C(){let e=S(process.env[y]);if(e!==void 0)return{enabled:e,source:`env`};let t=S(process.env[b]);if(t!==void 0)return{enabled:t,source:`wrangler-env`}}function w(){return C()?.enabled}function T(){let e=c();if(typeof e.deviceId==`string`&&x.test(e.deviceId))return e.deviceId;let t=_();return s({deviceId:t}),t}function E(){return c().deviceId===void 0}function D(){if(o())return{enabled:!1,source:`do-not-track`};let e=C();if(e!==void 0)return e;let t=c().telemetry?.preference;return t?.enabled===!1?{enabled:!1,source:`config`}:t?.enabled===!0&&typeof t.date==`string`&&new Date(t.date)>=v?{enabled:!0,source:`config`}:{enabled:!0,source:`default`}}function O(e){switch(e){case`do-not-track`:return`DO_NOT_TRACK`;case`env`:return y;case`wrangler-env`:return b;default:return}}function k(e){s({telemetry:{preference:{enabled:e,date:(/* @__PURE__ */ new Date()).toISOString()}}})}function A(){return c().telemetry?.bannerLastShown}function j(e){s({telemetry:{bannerLastShown:e}})}const M=/^\d{1,5}\.\d{1,5}\.\d{1,5}(?:-[0-9A-Za-z.-]{1,40})?(?:\+[0-9A-Za-z.-]{1,40})?$/;function N(){switch(process.platform){case`win32`:return`Windows`;case`darwin`:return`Mac OS`;case`linux`:return`Linux`;default:return`Others: ${process.platform}`}}function P(){return h.version()}function F(){return process.arch}function I(){return Number.parseInt(process.versions.node.split(`.`)[0]??`0`,10)}function L(){let e=process.env.npm_config_user_agent??``;return e.startsWith(`pnpm`)?`pnpm`:e.startsWith(`yarn`)?`yarn`:e.startsWith(`bun`)?`bun`:e.startsWith(`npm`)?`npm`:`unknown`}function R(e=process.env,t=process.ppid){if(!e.CF_DELEGATION)return!1;let n=e[u];return n===void 0||n===String(t)}function z(e=process.env,t=process.ppid){if(!e.CF_DELEGATION_PID||!R(e,t))return;let n=e[l];if(!(typeof n!=`string`||n.length>64||!M.test(n)))return n}function B(e,t,n){return g(`sha256`).update(`cf-agent-session-v1\0`).update(e).update(`\0`).update(t).update(`\0`).update(n).digest(`hex`).slice(0,32)}function V(){return typeof PACKAGE_PRERELEASE_LABEL==`string`?PACKAGE_PRERELEASE_LABEL:void 0}let H;function U(){if(H)return H;let[e,o,s]=n.split(`.`).map(e=>{let t=Number.parseInt(e,10);return Number.isNaN(t)?0:t}),c=Date.now(),l=0,u=E(),{enabled:f}=D(),p=r(),m=p.harness?.id??null,h=p.matches.find(e=>e.sessionId),g=R(),_=z();function v(){let r=V(),d=T();return{product:`cf`,cliVersion:n,cliMajor:e??0,cliMinor:o??0,cliPatch:s??0,...r?{prereleaseLabel:r}:{},osPlatform:N(),osVersion:P(),arch:F(),nodeVersion:I(),packageManager:L(),deviceId:d,amplitude_session_id:c,amplitude_event_id:l++,...h?.sessionId?{agentSessionKey:B(d,h.harness.id,h.sessionId)}:{},isFirstUsage:u,isCI:i,isInteractive:t(),cliMode:a(),agent:m,delegated:g,..._?{globalCliVersion:_}:{}}}function y(e,t){let n={deviceId:t.deviceId,event:e,timestamp:Date.now(),properties:t};if(process.env.DEBUG&&console.error(`Telemetry ${f?`sending`:`would send`}: ${JSON.stringify(n)}`),f)return fetch(`https://sparrow.cloudflare.com/api/v1/event`,{method:`POST`,signal:AbortSignal.timeout(1e3),headers:{Accept:`*/*`,"Content-Type":`application/json`,"Sparrow-Source-Key":`50598e014ed44c739ec8074fdc16057c`},mode:`cors`,keepalive:!0,body:JSON.stringify(n)}).then(()=>void 0).catch(e=>{process.env.DEBUG&&console.error(`Telemetry failed to send:`,e instanceof Error?e.message:String(e))})}return H={enabled:f,sendCommandEvent(e,t){if(f)try{d(y(e,{...v(),...t}))}catch(e){process.env.DEBUG&&console.error(`Telemetry failed to prepare:`,e)}},sendAdhocEvent(e,t={}){if(f)try{d(y(e,{...v(),...t}))}catch(e){process.env.DEBUG&&console.error(`Telemetry failed to prepare:`,e)}}},H}const W=/* @__PURE__ */ new Set([`SIGINT`,`SIGTERM`]),G=1024;function K(t){if(t instanceof e)return t.cancelled||t.signal&&W.has(t.signal)?`cancelled`:t.code===0?`success`:`error`}async function q(e,t,n){let r;try{r=U()}catch{return n()}if(f(),e.sendMetrics===!1||!r.enabled)return n();let i={...e.recordArgs===!1?{sanitizedArgs:{},argsUsed:[],argsCombination:``}:m(t,process.argv.slice(2),e.classification),command:e.command};r.sendCommandEvent(`cf command started`,i);let a=e.searchQuery===void 0?{}:{searchQuery:e.searchQuery.slice(0,G),...e.searchQuery.length>G?{searchQueryTruncated:!0}:{}},o=Date.now();try{let e=await n();return r.sendCommandEvent(`cf command finished`,{...i,...a,outcome:`success`,durationMs:Date.now()-o}),e}catch(e){let t=K(e)??`error`;throw r.sendCommandEvent(`cf command finished`,{...i,...a,outcome:t,durationMs:Date.now()-o,...t===`error`?p(e):{}}),e}}function J(e,t){return{...e,handler:n=>q(t,n,()=>e.handler(n))}}export{v as a,w as c,D as d,j as f,y as i,O as l,J as n,A as o,k as p,U as r,T as s,q as t,E as u};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{n as e,t}from"./disk-cache-
|
|
2
|
+
import{n as e,t}from"./disk-cache-BVfJigfC.mjs";const n=5e3;function r(e,t=/* @__PURE__ */ new WeakSet){if(typeof e!=`object`||!e||Array.isArray(e)||t.has(e))return!1;t.add(e);let n=e,i=/* @__PURE__ */ new Set([`array`,`boolean`,`integer`,`null`,`number`,`object`,`string`]),a=Array.isArray(n.type)?n.type:[n.type];if(n.type!==void 0&&(a.length===0||!a.every(e=>typeof e==`string`&&i.has(e)))||n.description!==void 0&&typeof n.description!=`string`||n.title!==void 0&&typeof n.title!=`string`||n.required!==void 0&&(!Array.isArray(n.required)||!n.required.every(e=>typeof e==`string`))||n.enum!==void 0&&!Array.isArray(n.enum)||n.oneOf!==void 0&&(!Array.isArray(n.oneOf)||n.oneOf.length===0||!n.oneOf.every(e=>r(e,t)))||n.anyOf!==void 0&&(!Array.isArray(n.anyOf)||n.anyOf.length===0||!n.anyOf.every(e=>r(e,t)))||n.allOf!==void 0&&(!Array.isArray(n.allOf)||n.allOf.length===0||!n.allOf.every(e=>r(e,t)))||n.if!==void 0&&!r(n.if,t)||n.then!==void 0&&!r(n.then,t)||n.additionalProperties!==void 0&&typeof n.additionalProperties!=`boolean`&&!r(n.additionalProperties,t)||n.uniqueItems!==void 0&&typeof n.uniqueItems!=`boolean`||[`minLength`,`maxLength`,`minimum`,`maximum`,`multipleOf`,`minItems`,`maxItems`,`minProperties`,`maxProperties`].some(e=>n[e]!==void 0&&(typeof n[e]!=`number`||!Number.isFinite(n[e])))||[`exclusiveMinimum`,`exclusiveMaximum`].some(e=>n[e]!==void 0&&typeof n[e]!=`boolean`&&(typeof n[e]!=`number`||!Number.isFinite(n[e])))||n.items!==void 0&&!(Array.isArray(n.items)?n.items:[n.items]).every(e=>r(e,t))||n.properties!==void 0&&(n.properties===null||typeof n.properties!=`object`||Array.isArray(n.properties)||!Object.values(n.properties).every(e=>r(e,t))))return!1;if(n.pattern!==void 0){if(typeof n.pattern!=`string`)return!1;try{new RegExp(n.pattern)}catch{return!1}}return!0}function i(e,t){if(typeof e!=`object`||!e)return;let n=e[t]??e;if(typeof n!=`object`||!n||!r(n))return;let i=n;return i.properties??i.oneOf??i.anyOf??i.allOf?i:void 0}function a(e,n){return t(e,n,36e5,e=>r(e)?e:void 0)}function o(t,n,r){e(t,n,r)}function s(e){if(typeof e!=`object`||!e)return`the request failed`;let t=e.statusCode;if(t===404)return`not found, or this account can't access it`;if(t===401)return"credentials were rejected; update `CLOUDFLARE_API_TOKEN` or run `cf auth login`";if(t===403)return`these credentials can't read it — check your API token permissions`;let n=e.message;if(!n)return`the request failed`;let r=(n.split(`
|
|
3
3
|
`)[0]??``).replace(/\.$/,``);return/^"?timeout"?$/i.test(r)?`the request timed out`:r}export{o as a,a as i,s as n,i as r,n as t};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{i as e,n as t}from"./auth-
|
|
2
|
+
import{i as e,n as t}from"./auth-CRq9OQKr.mjs";import{t as n}from"./path-DRw6Y-nd.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{n as i,t as a}from"./input-validation-D7z60HJH.mjs";import{a as o,t as s}from"./context-DsVjrTbe.mjs";import{t as c}from"./local-B3zt9PXR.mjs";import{t as l}from"./output-PRKYaJuo.mjs";import{t as u}from"./progress-DItBn6ZV.mjs";import{t as d}from"./run-DAK_kbUa.mjs";import"./telemetry-B3S5OfOn.mjs";import"./api-Dnt6lRJG.mjs";import{n as f}from"./prompt-BGz3DNLz.mjs";function p(e){return e.usage("$0 scim groups create\n\nCreates a new SCIM Group (user group) for the account. The `displayName` must not be empty and must not begin with `CF` (reserved for system groups).").option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`}).option(`file`,{type:`string`,description:`Path to a file to upload as the request body`})}const ee={command:`create`,describe:`Create SCIM Group`,builder:p,handler:async n=>d({command:`scim groups create`,classification:{safeFlags:[`dry-run`]}},n,async()=>{if(n.dryRun){let e=await o();r({command:`cf scim groups create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/scim/v2/Groups`,pathParams:{},bodyKind:`octet-stream`,body:n.file===void 0?n.body:{file:n.file}});return}if(n.body===void 0&&n.file===void 0)throw Error(`--body or --file is required for this command. Pass --body '<value>' or --file path/to/file.`);let d=n.file===void 0?i(n.body,`body`,`binary`):void 0,f=await t(n),p=n.local?c:await s();if(n.accountId=p,n.file!==void 0){let t=a(n.file),r=await u(`Creating`,async()=>e(f,`POST`,`/accounts/${p}/scim/v2/Groups`,{body:t,headers:{"Content-Type":`application/scim+json`}}));l(r,{successLabel:`Created`})}else if(n.body!==void 0){let t=d,n=await u(`Creating`,async()=>e(f,`POST`,`/accounts/${p}/scim/v2/Groups`,{body:t,headers:{"Content-Type":`application/scim+json`}}));l(n,{successLabel:`Created`})}})};var m={method:`DELETE`,path:e=>n`/accounts/${e.account_id}/scim/v2/Groups/${e.group_id}`,response:!1};function h(e){return e.usage(`$0 scim groups delete <group-id>
|
|
3
3
|
|
|
4
4
|
Deletes a SCIM Group (custom user groups only). System groups backed by Cloudflare permission groups cannot be deleted via SCIM. Returns 204 No Content on success.`).positional(`group-id`,{type:`string`,description:"The group identifier for a SCIM Group resource. For system groups this is prefixed `cloudflare-v1-<permissionGroupTag>`; for custom user groups this is a UUID-style 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 g={command:`delete <group-id>`,describe:`Delete SCIM Group`,builder:h,handler:async e=>d({command:`scim groups delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){let t=await o();r({command:`cf scim groups delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/scim/v2/Groups/${e[`group-id`]==null?`<group-id>`:encodeURIComponent(String(e[`group-id`]))}`,pathParams:{"group-id":String(e[`group-id`]??``)},bodyKind:`none`});return}let n=await t(e),i=e.local?c:await s();if(e.accountId=i,!await f({force:!!e.force,message:`Are you sure? This action cannot be undone.`}))return;let a=await u(`Deleting`,async()=>n.send(m,{account_id:i,group_id:e[`group-id`]}));l(a,{successLabel:`Deleted`})})};function _(e){return e.usage("$0 scim groups edit <group-id>\n\nPartially updates a SCIM Group via PATCH operations (RFC 7644 Section 3.5.2). Supports add, remove, and replace operations on `members`, `displayName`, and `externalId`. For system groups (prefixed `cloudflare-v1-`), only member management operations are supported.").positional(`group-id`,{type:`string`,description:"The group identifier for a SCIM Group resource. For system groups this is prefixed `cloudflare-v1-<permissionGroupTag>`; for custom user groups this is a UUID-style tag.",demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`}).option(`file`,{type:`string`,description:`Path to a file to upload as the request body`})}const v={command:`edit <group-id>`,describe:`Patch SCIM Group`,builder:_,handler:async n=>d({command:`scim groups edit`,classification:{safeFlags:[`dry-run`]}},n,async()=>{if(n.dryRun){let e=await o();r({command:`cf scim groups edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/scim/v2/Groups/${n[`group-id`]==null?`<group-id>`:encodeURIComponent(String(n[`group-id`]))}`,pathParams:{"group-id":String(n[`group-id`]??``)},bodyKind:`octet-stream`,body:n.file===void 0?n.body:{file:n.file}});return}if(n.body===void 0&&n.file===void 0)throw Error(`--body or --file is required for this command. Pass --body '<value>' or --file path/to/file.`);let d=n.file===void 0?i(n.body,`body`,`binary`):void 0,f=await t(n),p=n.local?c:await s();if(n.accountId=p,n.file!==void 0){let t=a(n.file),r=await u(`Updating`,async()=>e(f,`PATCH`,`/accounts/${p}/scim/v2/Groups/${encodeURIComponent(String(n[`group-id`]))}`,{body:t,headers:{"Content-Type":`application/scim+json`}}));l(r,{successLabel:`Updated`})}else if(n.body!==void 0){let t=d,r=await u(`Updating`,async()=>e(f,`PATCH`,`/accounts/${p}/scim/v2/Groups/${encodeURIComponent(String(n[`group-id`]))}`,{body:t,headers:{"Content-Type":`application/scim+json`}}));l(r,{successLabel:`Updated`})}})};var y={method:`GET`,path:e=>n`/accounts/${e.account_id}/scim/v2/Groups/${e.group_id}`};function b(e){return e.usage(`$0 scim groups get <group-id>
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-CRq9OQKr.mjs";import{t as n}from"./dry-run-mrA7FFLR.mjs";import{a as r,t as i}from"./context-DsVjrTbe.mjs";import{t as a}from"./local-B3zt9PXR.mjs";import{t as o}from"./output-PRKYaJuo.mjs";import{t as s}from"./progress-DItBn6ZV.mjs";import{t as c}from"./run-DAK_kbUa.mjs";import"./telemetry-B3S5OfOn.mjs";import{r as l,t as u}from"./body-parser-HN91kAf0.mjs";import{a as d,n as f}from"./prompt-BGz3DNLz.mjs";import{n as p}from"./input-validation-D7z60HJH.mjs";var m={method:`GET`,path:t=>e`/accounts/${t.account_id}/secrets_store/quota`};function h(e){return e.usage(`$0 secrets-store quota get
|
|
3
3
|
|
|
4
4
|
Lists the number of secrets used in the account.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const g={command:`get`,describe:`View secret usage`,builder:h,handler:async e=>c({command:`secrets-store quota get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let e=await r();n({command:`cf secrets-store quota get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/secrets_store/quota`,pathParams:{},bodyKind:`none`});return}let c=await t(e),l=e.local?a:await i();e.accountId=l;let u=await s(`Loading`,async()=>c.send(m,{account_id:l}));o(u,{successLabel:`Loaded`})})},_={command:`quota`,describe:`Account quota limits for secrets stores, secrets count, and storage capacity`,builder:e=>e.command(g).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var v={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/secrets_store/stores/${t.store_id}/secrets`,body:`json`};function y(e){return e.usage(`$0 secrets-store secrets bulk-delete
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-CRq9OQKr.mjs";import{t as n}from"./dry-run-mrA7FFLR.mjs";import{a as r,i,t as a}from"./context-DsVjrTbe.mjs";import{t as o}from"./local-B3zt9PXR.mjs";import{t as s}from"./output-PRKYaJuo.mjs";import{t as c}from"./progress-DItBn6ZV.mjs";import{t as l}from"./run-DAK_kbUa.mjs";import"./telemetry-B3S5OfOn.mjs";import{r as u,t as d}from"./body-parser-HN91kAf0.mjs";import{n as f}from"./input-validation-D7z60HJH.mjs";import{n as p,t as m}from"./raw-fetch-CmI3Ol3q.mjs";var h={method:`GET`,path:t=>e`/${t.account_or_zone}/${t.account_or_zone_id}/security-center/insights/${t.issue_id}/audit-log`,query:[`per_page`,`cursor`,`field_changed`,`changed_by`,`since`,`before`,`order`]};function g(e){return e.usage(`$0 security-insights audit-logs get <issue-id>
|
|
3
3
|
|
|
4
4
|
Lists audit log entries for a specific Security Center insight, showing changes to its status and classification over time.
|
|
5
5
|
|
|
@@ -41,7 +41,9 @@ Runs against your account. Pass --zone to run against a zone instead. CLOUDFLARE
|
|
|
41
41
|
|
|
42
42
|
Returns whether the account has enabled the selected partner integration and, if enabled, whether the account has been matched with the partner. An integration that has not been configured is returned as disabled.`).positional(`partner`,{type:`string`,description:`The partner integration identifier.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const q={command:`get <partner>`,describe:`Retrieves Partner Integration Settings`,builder:K,handler:async e=>l({command:`security-insights partners settings get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let t=await r();n({command:`cf security-insights partners settings get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/security-center/partners/${e.partner==null?`<partner>`:encodeURIComponent(String(e.partner))}/settings`,pathParams:{partner:String(e.partner??``)},bodyKind:`none`});return}let i=await t(e),l=e.local?o:await a();e.accountId=l;let u=await c(`Loading`,async()=>i.send(G,{account_id:l,partner:e.partner}));s(u,{successLabel:`Loaded`})})};var J={method:`POST`,path:t=>e`/accounts/${t.account_id}/security-center/partners/${t.partner}/settings`,body:`json`};function re(e){return e.usage(`$0 security-insights partners settings update <partner>
|
|
43
43
|
|
|
44
|
-
Enables or disables the selected partner integration for the account. Enabling the integration for the first time also schedules an account scan for that partner.`).positional(`partner`,{type:`string`,description:`The partner integration identifier.`,demandOption:!0}).option(`enabled`,{type:`boolean`,description:`Whether the partner integration is enabled for the account
|
|
44
|
+
Enables or disables the selected partner integration for the account. Enabling the integration for the first time also schedules an account scan for that partner. Disabling the integration will purge all partner integration-related data, including partner insights, shadow zones, and shadow hosts.`).positional(`partner`,{type:`string`,description:`The partner integration identifier.`,demandOption:!0}).option(`enabled`,{type:`boolean`,description:`Whether the partner integration is enabled for the account.
|
|
45
|
+
Enabling the integration for the first time also schedules an account scan for that partner.
|
|
46
|
+
Disabling the integration will purge all partner integration-related data, including partner insights, shadow zones, and shadow hosts.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const Y={command:`update <partner>`,describe:`Updates Partner Integration Settings`,builder:re,handler:async e=>l({command:`security-insights partners settings update`,classification:{safeFlags:[`enabled`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=await r();n({command:`cf security-insights partners settings update`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/security-center/partners/${e.partner==null?`<partner>`:encodeURIComponent(String(e.partner))}/settings`,pathParams:{partner:String(e.partner??``)},bodyKind:`json`,body:e.body===void 0?d({enabled:e.enabled}):u(e.body)});return}let i=e.body===void 0?void 0:u(e.body),l=await t(e),f=e.local?o:await a();if(e.accountId=f,e.body!==void 0){let t=i,n=await c(`Creating`,async()=>l.send(J,{body:t,account_id:f,partner:e.partner}));s(n,{successLabel:`Created`});return}if(e.enabled===void 0)throw Error(`--enabled is required (or pass --body with this field set).`);let p=d({enabled:e.enabled}),m=await c(`Creating`,async()=>l.send(J,{body:p,account_id:f,partner:e.partner}));s(m,{successLabel:`Created`})})},X={command:`settings`,describe:`Operations for partners.settings`,builder:e=>e.command(q).command(Y).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function ie(e){return e.usage(`$0 security-insights partners shadow-hosts list
|
|
45
47
|
|
|
46
48
|
Lists partner-discovered hosts beneath the zone that are not in the account.`).option(`partner`,{type:`string`,description:`The partner integration identifier.`,demandOption:!0}).option(`cursor`,{type:`string`,description:"Opaque cursor from the previous response's `result_info.cursor`. Omit for the first page."}).option(`per-page`,{type:`number`,description:`Number of premium partner asset results per page. Values other than 1 must be a multiple of 5.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const ae={command:`list`,describe:`Lists Partner-Discovered Shadow Hosts for a Zone`,builder:ie,handler:async e=>l({command:`security-insights partners shadow-hosts list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{let r={cursor:e.cursor,per_page:e[`per-page`]};if(e.dryRun){n({command:`cf security-insights partners shadow-hosts list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/security-center/partners/${e.partner==null?`<partner>`:encodeURIComponent(String(e.partner))}/shadow-hosts`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``),partner:String(e.partner??``)},query:r,bodyKind:`none`});return}let a=await t(e);e.zoneId=await i({zone:e.zone},a,{quiet:e.quiet});let o=new URLSearchParams(Object.entries(r).filter(([,e])=>e!==void 0).map(([e,t])=>[e,String(t)])).toString(),s=await c(`Loading`,async()=>m(`/zones/${e.zoneId}/security-center/partners/${encodeURIComponent(String(e.partner))}/shadow-hosts${o?`?`+o:``}`,{method:`GET`,local:e.local===!0,persistTo:e.persistTo}));p(s.toString(`utf-8`))})},oe={command:`shadow-hosts`,describe:`Operations for partners.shadow-hosts`,builder:e=>e.command(ae).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function se(e){return e.usage(`$0 security-insights partners shadow-zone-hosts list
|
|
47
49
|
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-CRq9OQKr.mjs";import{i as n}from"./context-DsVjrTbe.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{t as i}from"./output-PRKYaJuo.mjs";import{t as a}from"./progress-DItBn6ZV.mjs";import{t as o}from"./run-DAK_kbUa.mjs";import{a as s,n as c}from"./prompt-BGz3DNLz.mjs";import"./telemetry-B3S5OfOn.mjs";import{r as l,t as u}from"./body-parser-HN91kAf0.mjs";import{n as d}from"./input-validation-D7z60HJH.mjs";var f={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/security-center/securitytxt`};function p(e){return e.usage(`$0 security-txt delete
|
|
3
|
+
|
|
4
|
+
Removes the security.txt file configuration for a zone. The /.well-known/security.txt endpoint will no longer be served.`).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:`Deletes security.txt`,builder:p,handler:async e=>o({command:`security-txt delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){r({command:`cf security-txt delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/security-center/securitytxt`,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 c({force:!!e.force}))return;let l=await a(`Deleting`,async()=>o.send(f,{zone_id:s}));i(l,{successLabel:`Deleted`})})};var h={method:`GET`,path:t=>e`/zones/${t.zone_id}/security-center/securitytxt`};function g(e){return e.usage(`$0 security-txt get
|
|
5
|
+
|
|
6
|
+
Retrieves the current security.txt file configuration for a zone, used for security vulnerability reporting.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const _={command:`get`,describe:`Retrieves security.txt`,builder:g,handler:async e=>o({command:`security-txt get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf security-txt get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/security-center/securitytxt`,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}));i(c,{successLabel:`Loaded`})})};var v={method:`PUT`,path:t=>e`/zones/${t.zone_id}/security-center/securitytxt`,body:`json`};function y(e){return e.usage(`$0 security-txt update
|
|
7
|
+
|
|
8
|
+
Updates the security.txt file configuration for a zone, which provides security researchers with vulnerability reporting information.`).option(`acknowledgments`,{type:`string`,array:!0,description:`Link(s) to a page where security researchers are recognised for their reports.`}).option(`canonical`,{type:`string`,array:!0,description:`Canonical URI where the security.txt file is located.`}).option(`contact`,{type:`string`,array:!0,description:`Methods that researchers should use for reporting vulnerabilities. Can be a URI for an email address, phone number, or URL.`}).option(`enabled`,{type:`boolean`,description:`Whether or not to serve the security.txt file in this zone. If false, security.txt requests will pass through to the origin server.`}).option(`encryption`,{type:`string`,array:!0,description:`URI(s) pointing to a location where an encryption key that researchers should use for encrypted communications can be retrieved. The key itself must not appear in this field.`}).option(`expires`,{type:`string`,description:`RFC3339-formatted date and time string indicating the time that, after which, the contents of the security.txt file should be considered stale. It is recommended that this value is less than a year into the future.`}).option(`hiring`,{type:`string`,array:!0,description:`Link(s) to any security-related job positions.`}).option(`policy`,{type:`string`,array:!0,description:`Link(s) to where a vulnerability disclosure policy is located.`}).option(`preferred-languages`,{type:`string`,description:`Comma-separated list of natural languages that are preferred when submitting security reports. Language codes should be as defined in RFC5646.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Configuration of the zone security.txt file`})}const b={command:`update`,describe:`Updates security.txt`,builder:y,handler:async e=>o({command:`security-txt update`,classification:{safeFlags:[`enabled`,`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf security-txt update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/security-center/securitytxt`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?u({acknowledgments:e.acknowledgments,canonical:e.canonical,contact:e.contact,enabled:e.enabled,encryption:e.encryption,expires:d(e.expires,`expires`,`text`),hiring:e.hiring,policy:e.policy,preferred_languages:d(e[`preferred-languages`],`preferred-languages`,`text`)}):l(e.body)});return}let o=e.body===void 0?void 0:l(e.body),c=await t(e),f=await n({zone:e.zone},c,{quiet:e.quiet});if(e.zoneId=f,e.body!==void 0){let e=o,t=await a(`Updating`,async()=>c.send(v,{body:e,zone_id:f}));i(t,{successLabel:`Updated`});return}if(e.contact===void 0)throw Error(`--contact is required (or pass --body with this field set).`);e.expires===void 0&&(e.expires=await s(`expires`,`RFC3339-formatted date and time string indicating the time that, after which, the contents of the security.txt file should be considered stale. It is recommended that this value is less than a year into the future.`));let p=u({acknowledgments:e.acknowledgments,canonical:e.canonical,contact:e.contact,enabled:e.enabled,encryption:e.encryption,expires:d(e.expires,`expires`,`text`),hiring:e.hiring,policy:e.policy,preferred_languages:d(e[`preferred-languages`],`preferred-languages`,`text`)}),m=await a(`Updating`,async()=>c.send(v,{body:p,zone_id:f}));i(m,{successLabel:`Updated`})})},x={command:`security-txt`,describe:`Manage the /.well-known/security.txt file that tells security researchers how to report vulnerabilities`,builder:e=>e.command(m).command(_).command(b).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{x as default};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{c as e}from"./chunk-Q5KVZMHK-
|
|
2
|
+
import{c as e}from"./chunk-Q5KVZMHK-CYhKv3kZ.mjs";import{r as t}from"./blocks-DGXsHh9X.mjs";import{r as n}from"./theme-BGHWSKCw.mjs";let r=!1,i=!1,a=!1;function o(){a=!0}function s(e,n={}){r||i||(n.quiet||!process.stderr.isTTY?i=!0:(process.stderr.write(`${t(e,n.update)}\n`),r=!0))}function c(t){!r||i||a||t==="default"||e({allowGlobalAuthKey:!1})!==void 0||(process.stderr.write(`${n.muted(`Active profile:`)} ${n.info(t)}\n`),a=!0)}export{c as n,o as r,s as t};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import{_ as e,d as t,f as n,t as r}from"./deploy-context-DJNsb7w-.mjs";import{a as i,d as a,f as o,r as s,s as c}from"./static-assets-CWo7dxyW.mjs";import{J as l,X as u,at as d}from"./dist-BoDdDWjK.mjs";import{a as f,c as p,i as m,l as h,n as g,o as _,r as v,s as y}from"./build-I3m3uZn6.mjs";import{t as b}from"./cli-exit-CstFZ1eJ.mjs";import{i as x,r as S}from"./dotenv-DKRemNCH.mjs";import{i as C,n as w,t as T}from"./deploy-input-Bkll8tDW.mjs";import{t as E}from"./log-Brx-wjJW.mjs";import{readBuildOutput as D}from"@cloudflare/build-output-utils";function O(e){return e.option(`prebuilt`,{type:`boolean`,description:`Deploy existing Build Output Specification files without building`,default:!1}).option(`tag`,{type:`string`,description:`A tag to associate with this Worker Version`,requiresArg:!0}).option(`message`,{type:`string`,description:`A message to associate with this Worker Version`,requiresArg:!0}).option(`secrets-file`,{type:`string`,description:"Path to a file containing secrets to upload with the version (JSON or .env format). Dotenv values expand $VAR and ${VAR} using process environment values and earlier file values; process environment values override file values, including empty values. Only declared file keys are uploaded. Only use trusted dotenv secrets files: they can read and upload any process environment value. Escape literal dollar signs with \\$ or use JSON.",requiresArg:!0}).option(`dry-run`,{describe:`Build a project and run checks without actually uploading the Worker`,type:`boolean`,default:!1}).option(`worker`,f)}async function k(e,t){if(!e.prebuilt){if(await g(e.mode,{worker:e.worker,dryRun:e[`dry-run`]})===`setup-needed`){E.success(`--dry-run: exiting now.`);return}E.message(``)}return S(e,()=>A(e,t))}async function A(f,g){let{root:S,workers:O,rootConfig:k,containers:A}=await D(process.cwd());if(k.buildContext.isPreview){let e=[`cf previews deploy`,...f.prebuilt?[`--prebuilt`]:[],...k.buildContext.mode===void 0?[]:[`--mode`,k.buildContext.mode]].join(` `);throw Error(`This build output is for a Preview. Run ${e} instead.`)}h(f.mode,k.buildContext.mode),p(k.accountId,f[`temporary-account`]===!0);let{worker:j,workerNameOverridden:M}=m(y(O,f.worker)),N=_(j,k),P=x(N.wranglerConfig),F=T(j,N.builtConfig,S),I=u(P),{authToken:L,accountId:R}=await i({accountId:k.accountId,complianceRegion:I,dryRun:f[`dry-run`]}),z=r(L);o(z),e({logger:z.logger,fetchResult:z.fetchResult,fetchPagedListResult:z.fetchPagedListResult}),R!==void 0&&A.length>0&&n(R,L,l(P));let B=s(A,P,{accountId:R,containersRollout:f[`containers-rollout`]}),V,H=!1,U=process.exitCode,W=v();try{if(process.exitCode=void 0,g.command===`Deploy`){let e=w(j,P,R,f,B);e.workerNameOverridden=M,E.section(`Deploy`),{versionId:V}=await c(e,P,F,{deployCommand:`cf deploy`,versionsDeployCommand:`cf workers deployments create --worker <worker-name> --strategy percentage --versions <versions-json>`,d1ListCommand:`cf d1 list`,d1DeleteCommand:`cf d1 delete <database-id>`,queueCreateCommand:e=>`cf queues create --queue-name ${e}`,secretPutCommand:`cf workers secrets update --worker <worker-name> --type secret_text`,workersDevConfigFieldName:`workersDev`,workersDevConfigAssignment:e=>`workersDev: ${e}`,previewUrlsConfigFieldName:`previewUrls`,previewUrlsConfigAssignment:e=>`previewUrls: ${e}`,configFileName:`cloudflare.config.ts`,observabilityTargetPercentageField:`targetInstancePercentage`,observabilityTargetCountField:`targetInstanceCount`,syncWorkersSite:void 0,analyseBundle:void 0})}else{let e=C(j,P,R,f,B);e.workerNameOverridden=M,E.section(`Upload`),{versionId:V}=await a(e,P,F,{deployCommand:`cf deploy`,versionsUploadCommand:`cf workers versions create`,versionsDeployCommand:`cf workers deployments create --worker <worker-name> --strategy percentage --versions <versions-json>`,triggersDeployCommand:`cf workers triggers deploy`,d1ListCommand:`cf d1 list`,d1DeleteCommand:`cf d1 delete <database-id>`,queueCreateCommand:e=>`cf queues create --queue-name ${e}`,versionsSecretPutCommand:`wrangler versions secret put`,analyseBundle:void 0})}H=V===null&&process.exitCode===1&&!f[`dry-run`]}finally{process.exitCode??=U,W()}if(H)throw new b(1);V===null||f[`dry-run`]||g.command===`Deploy`&&f[`containers-rollout`]===`none`||await t([...g.command===`Deploy`?B.standard.builtImages:[],...B.durableObjects.builtImages],d()),f[`dry-run`]||E.success(`${g.command} complete`)}export{O as n,k as t};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-CRq9OQKr.mjs";import{i as n}from"./context-DsVjrTbe.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{t as i}from"./output-PRKYaJuo.mjs";import{t as a}from"./progress-DItBn6ZV.mjs";import{t as o}from"./run-DAK_kbUa.mjs";import{a as s,n as c}from"./prompt-BGz3DNLz.mjs";import"./telemetry-B3S5OfOn.mjs";import{i as l,o as u,r as d,t as f}from"./body-parser-HN91kAf0.mjs";import{n as p}from"./input-validation-D7z60HJH.mjs";var m={method:`POST`,path:t=>e`/zones/${t.zone_id}/smart_shield/cache_reserve_clear`};function h(e){return e.usage(`$0 smart-shield cache-reserve-clear clear
|
|
3
3
|
|
|
4
4
|
You can use Cache Reserve Clear to clear your Cache Reserve, but you must first disable Cache Reserve. In most cases, this will be accomplished within 24 hours. You cannot re-enable Cache Reserve while this process is ongoing. Keep in mind that you cannot undo or cancel this operation.`).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 g={command:`clear`,describe:`Start Cache Reserve Clear`,builder:h,handler:async e=>o({command:`smart-shield cache-reserve-clear clear`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){r({command:`cf smart-shield cache-reserve-clear clear`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/smart_shield/cache_reserve_clear`,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 c({force:!!e.force,message:`This operation permanently clears Cache Reserve for this zone and cannot be undone.`}))return;let l=await a(`Processing`,async()=>o.send(m,{zone_id:s}));i(l,{successLabel:`Done`})})};var _={method:`GET`,path:t=>e`/zones/${t.zone_id}/smart_shield/cache_reserve_clear`};function v(e){return e.usage(`$0 smart-shield cache-reserve-clear status
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{i as e,n as t}from"./auth-
|
|
2
|
+
import{i as e,n as t}from"./auth-CRq9OQKr.mjs";import{t as n}from"./path-DRw6Y-nd.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{i}from"./context-DsVjrTbe.mjs";import{t as a}from"./progress-DItBn6ZV.mjs";import{n as o,t as s}from"./raw-fetch-CmI3Ol3q.mjs";import"./telemetry-B3S5OfOn.mjs";import{t as c}from"./run-DAK_kbUa.mjs";import"./api-Dnt6lRJG.mjs";import{t as l}from"./output-PRKYaJuo.mjs";import{n as u}from"./prompt-BGz3DNLz.mjs";import{o as d,r as f,t as p}from"./body-parser-HN91kAf0.mjs";import{n as m,t as h}from"./input-validation-D7z60HJH.mjs";function g(e){return e.usage(`$0 snippets content get <snippet-name>
|
|
3
3
|
|
|
4
4
|
Fetches the content of a snippet belonging to the zone.`).positional(`snippet-name`,{type:`string`,description:`Identify the snippet.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`text`,{type:`boolean`,description:`Decode the response body as UTF-8 text instead of writing raw bytes`,default:!1})}const _={command:`get <snippet-name>`,describe:`Get a zone snippet content`,builder:g,handler:async e=>c({command:`snippets content get`,classification:{safeFlags:[`dry-run`,`text`]}},e,async()=>{if(e.dryRun){r({command:`cf snippets content get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/snippets/${e[`snippet-name`]==null?`<snippet-name>`:encodeURIComponent(String(e[`snippet-name`]))}/content`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``),"snippet-name":String(e[`snippet-name`]??``)},bodyKind:`none`});return}let n=await t(e);e.zoneId=await i({zone:e.zone},n,{quiet:e.quiet});let c=await a(`Loading`,async()=>s(`/zones/${e.zoneId}/snippets/${encodeURIComponent(String(e[`snippet-name`]))}/content`,{method:`GET`,local:e.local===!0,persistTo:e.persistTo}));o(e.text===!0?c.toString(`utf-8`):c)})},v={command:`content`,describe:`Operations for content`,builder:e=>e.command(_).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var y={method:`DELETE`,path:e=>n`/zones/${e.zone_id}/snippets/${e.snippet_name}`};function b(e){return e.usage(`$0 snippets delete <snippet-name>
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{r as e,t}from"./rolldown-runtime-BNtqjh-B.mjs";import{r as n}from"./theme-BGHWSKCw.mjs";import{t as r}from"./cli-exit-CstFZ1eJ.mjs";import{a as i}from"./autoconfig-DoLQ5ct8.mjs";import{t as a}from"./blocks-DK5qAzLe.mjs";import"./ui-CY75N4Tm.mjs";import{a as o,i as s,n as c,o as l,r as u,s as d,t as f}from"./gt-BV-jij5q.mjs";import"./log-Brx-wjJW.mjs";import{n as p,t as m}from"./discover-DGsMj9ZN.mjs";import{constants as h}from"node:os";var g=/* @__PURE__ */ t(((e,t)=>{t.exports=class{constructor(){this.max=1e3,this.map=/* @__PURE__ */ new Map}get(e){let t=this.map.get(e);if(t!==void 0)return this.map.delete(e),this.map.set(e,t),t}delete(e){return this.map.delete(e)}set(e,t){if(!this.delete(e)&&t!==void 0){if(this.map.size>=this.max){let e=this.map.keys().next().value;this.delete(e)}this.map.set(e,t)}return this}}})),_=/* @__PURE__ */ t(((e,t)=>{let n=c();t.exports=(e,t,r)=>n(e,t,r)===0})),v=/* @__PURE__ */ t(((e,t)=>{let n=c();t.exports=(e,t,r)=>n(e,t,r)!==0})),y=/* @__PURE__ */ t(((e,t)=>{let n=c();t.exports=(e,t,r)=>n(e,t,r)>=0})),b=/* @__PURE__ */ t(((e,t)=>{let n=c();t.exports=(e,t,r)=>n(e,t,r)<0})),x=/* @__PURE__ */ t(((e,t)=>{let n=c();t.exports=(e,t,r)=>n(e,t,r)<=0})),S=/* @__PURE__ */ t(((e,t)=>{let n=_(),r=v(),i=f(),a=y(),o=b(),s=x();t.exports=(e,t,c,l)=>{switch(t){case`===`:return typeof e==`object`&&(e=e.version),typeof c==`object`&&(c=c.version),e===c;case`!==`:return typeof e==`object`&&(e=e.version),typeof c==`object`&&(c=c.version),e!==c;case``:case`=`:case`==`:return n(e,c,l);case`!=`:return r(e,c,l);case`>`:return i(e,c,l);case`>=`:return a(e,c,l);case`<`:return o(e,c,l);case`<=`:return s(e,c,l);default:throw TypeError(`Invalid operator: ${t}`)}}})),C=/* @__PURE__ */ t(((e,t)=>{let n=Symbol(`SemVer ANY`);t.exports=class e{static get ANY(){return n}constructor(t,i){if(i=r(i),t instanceof e){if(t.loose===!!i.loose)return t;t=t.value}t=t.trim().split(/\s+/).join(` `),l(`comparator`,t,i),this.options=i,this.loose=!!i.loose,this.parse(t),this.value=this.semver===n?``:this.operator+this.semver.version,l(`comp`,this)}parse(e){let t=this.options.loose?i[a.COMPARATORLOOSE]:i[a.COMPARATOR],r=e.match(t);if(!r)throw TypeError(`Invalid comparator: ${e}`);this.operator=r[1]===void 0?``:r[1],this.operator===`=`&&(this.operator=``),this.semver=r[2]?new f(r[2],this.options.loose):n}toString(){return this.value}test(e){if(l(`Comparator.test`,e,this.options.loose),this.semver===n||e===n)return!0;if(typeof e==`string`)try{e=new f(e,this.options)}catch{return!1}return c(e,this.operator,this.semver,this.options)}intersects(t,n){if(!(t instanceof e))throw TypeError(`a Comparator is required`);return this.operator===``?this.value===``||new p(t.value,n).test(this.value):t.operator===``?t.value===``||new p(this.value,n).test(t.semver):(n=r(n),n.includePrerelease&&(this.value===`<0.0.0-0`||t.value===`<0.0.0-0`)||!n.includePrerelease&&(this.value.startsWith(`<0.0.0`)||t.value.startsWith(`<0.0.0`))?!1:!!(this.operator.startsWith(`>`)&&t.operator.startsWith(`>`)||this.operator.startsWith(`<`)&&t.operator.startsWith(`<`)||this.semver.version===t.semver.version&&this.operator.includes(`=`)&&t.operator.includes(`=`)||c(this.semver,`<`,t.semver,n)&&this.operator.startsWith(`>`)&&t.operator.startsWith(`<`)||c(this.semver,`>`,t.semver,n)&&this.operator.startsWith(`<`)&&t.operator.startsWith(`>`)))}};let r=s(),{safeRe:i,t:a}=o(),c=S(),l=d(),f=u(),p=T()})),w=/* @__PURE__ */ t(((e,t)=>{let{MAX_LENGTH:n,MAX_SAFE_BUILD_LENGTH:r,WHITESPACE_CHARACTERS:i}=l(),a=/* @__PURE__ */ new Uint8Array(65536);for(let e of i)a[e.charCodeAt(0)]=1;let o=e=>e!==void 0&&a[e.charCodeAt(0)]===1,s=e=>e===`v`||e===`=`||o(e),c=e=>e!==void 0&&e>=`0`&&e<=`9`,u=e=>e!==void 0&&(e>=`a`&&e<=`z`||e>=`A`&&e<=`Z`),d=e=>c(e)||u(e)||e===`-`,f=e=>c(e)||e===`x`||e===`X`||e===`*`,p=(e,t,n,r)=>{if(!c(e[t]))return t;if(t>=r.start&&t<r.end)return Math.min(t+n,r.end);if(t>=r.previousStart&&t<r.previousEnd)return Math.min(t+n,r.previousEnd);let i=t+1;for(;c(e[i]);)i++;return r.previousStart=r.start,r.previousEnd=r.end,r.start=t,r.end=i,Math.min(t+n,i)},m=(e,t,r,i)=>!r&&e[t]===`0`?t+1:p(e,t,r?n:n+1,i),h=(e,t,i,a)=>{let o=p(e,t,n,a);if(u(e[o])||e[o]===`-`){let t=o+1,n=t+r;for(;t<n&&d(e[t]);)t++;return t}return m(e,t,i,a)},g=(e,t,n,r)=>{let i=e[t]===`-`;if(!n&&!i)return t;let a=t+ +!!i,o=h(e,a,n,r);if(o===a){if(!n||!i)return t;o=h(e,t,n,r)}for(;e[o]===`.`;){let t=h(e,o+1,n,r);if(t===o+1)break;o=t}return o},_=(e,t)=>{let n=t;for(;n-t<r&&d(e[n]);)n++;return n},v=(e,t)=>{if(e[t]!==`+`)return t;let n=_(e,t+1);if(n===t+1)return t;for(;e[n]===`.`;){let t=_(e,n+1);if(t===n+1)break;n=t}return n},y=(e,t,n)=>{let r=t;for(let i=0;i<3;i++){let a=m(e,r,!0,n);if(a===r)return t;if(r=a,i<2){if(e[r]!==`.`)return t;r++}}let i=g(e,r,!0,n);return v(e,i)},b=(e,t,n)=>c(e[t])?m(e,t,!1,n):f(e[t])?t+1:t,x=(e,t,n)=>{let r=b(e,t,n);for(let t=0;t<2;t++){if(e[r]!==`.`)return r;let t=b(e,r+1,n);if(t===r+1)return r;r=t}let i=g(e,r,!1,n);return v(e,i)},S=(e,t,n)=>{let r=y(e,t,n);return r===t?x(e,t,n):r},C=(e,t)=>{let n=t;return o(e[n])&&n++,(e[n]===`<`||e[n]===`>`)&&n++,e[n]===`=`&&n++,o(e[n])?n:-1};t.exports=e=>{let t=``,n=0,r=0,i={start:-1,end:-1,previousStart:-1,previousEnd:-1};for(;r<e.length;){let a=r;if(e[r]===`<`||e[r]===`>`)r++;else if(!s(e[r])&&!f(e[r])){r++;continue}for(;r<e.length&&s(e[r]);)r++;if(!f(e[r]))continue;let o=C(e,a);o!==-1&&(t+=e.slice(n,o),n=o+1),r=S(e,r,i)}return t+e.slice(n)}})),T=/* @__PURE__ */ t(((e,t)=>{let n=/\s+/g;t.exports=class e{constructor(t,r){if(r=i(r),t instanceof e)return t.loose===!!r.loose&&t.includePrerelease===!!r.includePrerelease?t:new e(t.raw,r);if(t instanceof a)return this.raw=t.value,this.set=[[t]],this.formatted=void 0,this;if(this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease,this.raw=t.trim().replace(n,` `),this.set=this.raw.split(`||`).map(e=>this.parseRange(e.trim())).filter(e=>e.length),!this.set.length)throw TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){let e=this.set[0];if(this.set=this.set.filter(e=>!T(e[0])),this.set.length===0)this.set=[e];else if(this.set.length>1){for(let e of this.set)if(e.length===1&&E(e[0])){this.set=[e];break}}}this.formatted=void 0}get range(){if(this.formatted===void 0){this.formatted=``;for(let e=0;e<this.set.length;e++){e>0&&(this.formatted+=`||`);let t=this.set[e];for(let e=0;e<t.length;e++)e>0&&(this.formatted+=` `),this.formatted+=t[e].toString().trim()}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(e){e=e.replace(S,``);let t=((this.options.includePrerelease&&b)|(this.options.loose&&x))+`:`+e,n=r.get(t);if(n)return n;let i=this.options.loose,o=i?m[_.HYPHENRANGELOOSE]:m[_.HYPHENRANGE];e=e.replace(o,z(this.options.includePrerelease)),c(`hyphen replace`,e),e=p(e),c(`comparator trim`,e),e=e.replace(m[_.TILDETRIM],v),c(`tilde trim`,e),e=e.replace(m[_.CARETTRIM],y),c(`caret trim`,e);let s=e.split(` `).map(e=>O(e,this.options)).join(` `).split(/\s+/).map(e=>R(e,this.options));i&&(s=s.filter(e=>(c(`loose invalid filter`,e,this.options),!!e.match(m[_.COMPARATORLOOSE])))),c(`range list`,s);let l=/* @__PURE__ */ new Map,u=s.map(e=>new a(e,this.options));for(let e of u){if(T(e))return[e];l.set(e.value,e)}l.size>1&&l.has(``)&&l.delete(``);let d=[...l.values()];return r.set(t,d),d}intersects(t,n){if(!(t instanceof e))throw TypeError(`a Range is required`);return this.set.some(e=>D(e,n)&&t.set.some(t=>D(t,n)&&e.every(e=>t.every(t=>e.intersects(t,n)))))}test(e){if(!e)return!1;if(typeof e==`string`)try{e=new f(e,this.options)}catch{return!1}for(let t=0;t<this.set.length;t++)if(B(this.set[t],e,this.options))return!0;return!1}};let r=new(g()),i=s(),a=C(),c=d(),f=u(),p=w(),{safeRe:m,src:h,t:_,tildeTrimReplace:v,caretTrimReplace:y}=o(),{FLAG_INCLUDE_PRERELEASE:b,FLAG_LOOSE:x}=l(),S=new RegExp(h[_.BUILD],`g`),T=e=>e.value===`<0.0.0-0`,E=e=>e.value===``,D=(e,t)=>{let n=!0,r=e.slice(),i=r.pop();for(;n&&r.length;)n=r.every(e=>i.intersects(e,t)),i=r.pop();return n},O=(e,t)=>(e=e.replace(m[_.BUILD],``),c(`comp`,e,t),e=N(e,t),c(`caret`,e),e=j(e,t),c(`tildes`,e),e=F(e,t),c(`xrange`,e),e=L(e,t),c(`stars`,e),e),k=e=>!e||e.toLowerCase()===`x`||e===`*`,A=(e,t,n)=>k(e)&&!k(t)||k(t)&&n&&!k(n),j=(e,t)=>e.trim().split(/\s+/).map(e=>M(e,t)).join(` `),M=(e,t)=>{let n=t.loose?m[_.TILDELOOSE]:m[_.TILDE],r=t.includePrerelease?`-0`:``;return e.replace(n,(t,n,i,a,o)=>{c(`tilde`,e,t,n,i,a,o);let s;return k(n)?s=``:k(i)?s=`>=${n}.0.0${r} <${+n+1}.0.0-0`:k(a)?s=`>=${n}.${i}.0${r} <${n}.${+i+1}.0-0`:o?(c(`replaceTilde pr`,o),s=`>=${n}.${i}.${a}-${o} <${n}.${+i+1}.0-0`):s=`>=${n}.${i}.${a} <${n}.${+i+1}.0-0`,c(`tilde return`,s),s})},N=(e,t)=>e.trim().split(/\s+/).map(e=>P(e,t)).join(` `),P=(e,t)=>{c(`caret`,e,t);let n=t.loose?m[_.CARETLOOSE]:m[_.CARET],r=t.includePrerelease?`-0`:``;return e.replace(n,(t,n,i,a,o)=>{c(`caret`,e,t,n,i,a,o);let s;return k(n)?s=``:k(i)?s=`>=${n}.0.0${r} <${+n+1}.0.0-0`:k(a)?s=n===`0`?`>=${n}.${i}.0${r} <${n}.${+i+1}.0-0`:`>=${n}.${i}.0${r} <${+n+1}.0.0-0`:o?(c(`replaceCaret pr`,o),s=n===`0`?i===`0`?`>=${n}.${i}.${a}-${o} <${n}.${i}.${+a+1}-0`:`>=${n}.${i}.${a}-${o} <${n}.${+i+1}.0-0`:`>=${n}.${i}.${a}-${o} <${+n+1}.0.0-0`):(c(`no pr`),s=n===`0`?i===`0`?`>=${n}.${i}.${a} <${n}.${i}.${+a+1}-0`:`>=${n}.${i}.${a} <${n}.${+i+1}.0-0`:`>=${n}.${i}.${a} <${+n+1}.0.0-0`),c(`caret return`,s),s})},F=(e,t)=>(c(`replaceXRanges`,e,t),e.split(/\s+/).map(e=>I(e,t)).join(` `)),I=(e,t)=>{e=e.trim();let n=t.loose?m[_.XRANGELOOSE]:m[_.XRANGE];return e.replace(n,(n,r,i,a,o,s)=>{if(c(`xRange`,e,n,r,i,a,o,s),A(i,a,o))return e;let l=k(i),u=l||k(a),d=u||k(o),f=d;return r===`=`&&f&&(r=``),s=t.includePrerelease?`-0`:``,l?n=r===`>`||r===`<`?`<0.0.0-0`:`*`:r&&f?(u&&(a=0),o=0,r===`>`?(r=`>=`,u?(i=+i+1,a=0,o=0):(a=+a+1,o=0)):r===`<=`&&(r=`<`,u?i=+i+1:a=+a+1),r===`<`&&(s=`-0`),n=`${r+i}.${a}.${o}${s}`):u?n=`>=${i}.0.0${s} <${+i+1}.0.0-0`:d&&(n=`>=${i}.${a}.0${s} <${i}.${+a+1}.0-0`),c(`xRange return`,n),n})},L=(e,t)=>(c(`replaceStars`,e,t),e.trim().replace(m[_.STAR],``)),R=(e,t)=>(c(`replaceGTE0`,e,t),e.trim().replace(m[t.includePrerelease?_.GTE0PRE:_.GTE0],``)),z=e=>(t,n,r,i,a,o,s,c,l,u,d,f)=>(n=k(r)?``:k(i)?`>=${r}.0.0${e?`-0`:``}`:k(a)?`>=${r}.${i}.0${e?`-0`:``}`:o?`>=${n}`:`>=${n}${e?`-0`:``}`,c=k(l)?``:k(u)?`<${+l+1}.0.0-0`:k(d)?`<${l}.${+u+1}.0-0`:f?`<=${l}.${u}.${d}-${f}`:e?`<${l}.${u}.${+d+1}-0`:`<=${c}`,`${n} ${c}`.trim()),B=(e,t,n)=>{for(let n=0;n<e.length;n++)if(!e[n].test(t))return!1;if(t.prerelease.length&&!n.includePrerelease){for(let n=0;n<e.length;n++)if(c(e[n].semver),e[n].semver!==a.ANY&&e[n].semver.prerelease.length>0){let r=e[n].semver;if(r.major===t.major&&r.minor===t.minor&&r.patch===t.patch)return!0}return!1}return!0}})),E=/* @__PURE__ */ e((/* @__PURE__ */ t(((e,t)=>{let n=T();t.exports=(e,t,r)=>{try{t=new n(t,r)}catch{return!1}return t.test(e)}})))(),1);function D(e){let t=m(e);if(t.length===0)throw j(e),new r(1);if(t.length>1)throw M(t),new r(1);let[n]=t;if(!n)throw new r(1);if(!n.binary)throw N(n),new r(1);if(n.impl.versionConstraint!==void 0&&!O(n.installedVersion,n.impl.versionConstraint.range))throw k(n),new r(1);return n}function O(e,t){return e!==void 0&&(0,E.default)(e,t,{includePrerelease:!0})}function k(e){P(`${e.impl.pkg}@${e.installedVersion??`unknown`} is installed, but it is not compatible with cf's local runtime.`,A(e),e.impl)}function A(e){return`cf requires ${e.impl.versionConstraint?.display??`a compatible version`} for cf dev, cf build, cf deploy, and cf previews deploy.`}function j(e){console.error(a(`No Cloudflare dev server is installed in ${e}.`,`Checked package.json, pyproject.toml and Cargo.toml.`)),console.error(`
|
|
2
|
+
import{r as e,t}from"./rolldown-runtime-BNtqjh-B.mjs";import{r as n}from"./theme-BGHWSKCw.mjs";import{t as r}from"./cli-exit-CstFZ1eJ.mjs";import{a as i}from"./autoconfig-BDEt9orA.mjs";import{t as a}from"./blocks-DGXsHh9X.mjs";import"./ui-YBIkZLZt.mjs";import{a as o,i as s,n as c,o as l,r as u,s as d,t as f}from"./gt-BV-jij5q.mjs";import"./log-Brx-wjJW.mjs";import{n as p,t as m}from"./discover-DtcZCeSh.mjs";import{constants as h}from"node:os";var g=/* @__PURE__ */ t(((e,t)=>{t.exports=class{constructor(){this.max=1e3,this.map=/* @__PURE__ */ new Map}get(e){let t=this.map.get(e);if(t!==void 0)return this.map.delete(e),this.map.set(e,t),t}delete(e){return this.map.delete(e)}set(e,t){if(!this.delete(e)&&t!==void 0){if(this.map.size>=this.max){let e=this.map.keys().next().value;this.delete(e)}this.map.set(e,t)}return this}}})),_=/* @__PURE__ */ t(((e,t)=>{let n=c();t.exports=(e,t,r)=>n(e,t,r)===0})),v=/* @__PURE__ */ t(((e,t)=>{let n=c();t.exports=(e,t,r)=>n(e,t,r)!==0})),y=/* @__PURE__ */ t(((e,t)=>{let n=c();t.exports=(e,t,r)=>n(e,t,r)>=0})),b=/* @__PURE__ */ t(((e,t)=>{let n=c();t.exports=(e,t,r)=>n(e,t,r)<0})),x=/* @__PURE__ */ t(((e,t)=>{let n=c();t.exports=(e,t,r)=>n(e,t,r)<=0})),S=/* @__PURE__ */ t(((e,t)=>{let n=_(),r=v(),i=f(),a=y(),o=b(),s=x();t.exports=(e,t,c,l)=>{switch(t){case`===`:return typeof e==`object`&&(e=e.version),typeof c==`object`&&(c=c.version),e===c;case`!==`:return typeof e==`object`&&(e=e.version),typeof c==`object`&&(c=c.version),e!==c;case``:case`=`:case`==`:return n(e,c,l);case`!=`:return r(e,c,l);case`>`:return i(e,c,l);case`>=`:return a(e,c,l);case`<`:return o(e,c,l);case`<=`:return s(e,c,l);default:throw TypeError(`Invalid operator: ${t}`)}}})),C=/* @__PURE__ */ t(((e,t)=>{let n=Symbol(`SemVer ANY`);t.exports=class e{static get ANY(){return n}constructor(t,i){if(i=r(i),t instanceof e){if(t.loose===!!i.loose)return t;t=t.value}t=t.trim().split(/\s+/).join(` `),l(`comparator`,t,i),this.options=i,this.loose=!!i.loose,this.parse(t),this.value=this.semver===n?``:this.operator+this.semver.version,l(`comp`,this)}parse(e){let t=this.options.loose?i[a.COMPARATORLOOSE]:i[a.COMPARATOR],r=e.match(t);if(!r)throw TypeError(`Invalid comparator: ${e}`);this.operator=r[1]===void 0?``:r[1],this.operator===`=`&&(this.operator=``),this.semver=r[2]?new f(r[2],this.options.loose):n}toString(){return this.value}test(e){if(l(`Comparator.test`,e,this.options.loose),this.semver===n||e===n)return!0;if(typeof e==`string`)try{e=new f(e,this.options)}catch{return!1}return c(e,this.operator,this.semver,this.options)}intersects(t,n){if(!(t instanceof e))throw TypeError(`a Comparator is required`);return this.operator===``?this.value===``||new p(t.value,n).test(this.value):t.operator===``?t.value===``||new p(this.value,n).test(t.semver):(n=r(n),n.includePrerelease&&(this.value===`<0.0.0-0`||t.value===`<0.0.0-0`)||!n.includePrerelease&&(this.value.startsWith(`<0.0.0`)||t.value.startsWith(`<0.0.0`))?!1:!!(this.operator.startsWith(`>`)&&t.operator.startsWith(`>`)||this.operator.startsWith(`<`)&&t.operator.startsWith(`<`)||this.semver.version===t.semver.version&&this.operator.includes(`=`)&&t.operator.includes(`=`)||c(this.semver,`<`,t.semver,n)&&this.operator.startsWith(`>`)&&t.operator.startsWith(`<`)||c(this.semver,`>`,t.semver,n)&&this.operator.startsWith(`<`)&&t.operator.startsWith(`>`)))}};let r=s(),{safeRe:i,t:a}=o(),c=S(),l=d(),f=u(),p=T()})),w=/* @__PURE__ */ t(((e,t)=>{let{MAX_LENGTH:n,MAX_SAFE_BUILD_LENGTH:r,WHITESPACE_CHARACTERS:i}=l(),a=/* @__PURE__ */ new Uint8Array(65536);for(let e of i)a[e.charCodeAt(0)]=1;let o=e=>e!==void 0&&a[e.charCodeAt(0)]===1,s=e=>e===`v`||e===`=`||o(e),c=e=>e!==void 0&&e>=`0`&&e<=`9`,u=e=>e!==void 0&&(e>=`a`&&e<=`z`||e>=`A`&&e<=`Z`),d=e=>c(e)||u(e)||e===`-`,f=e=>c(e)||e===`x`||e===`X`||e===`*`,p=(e,t,n,r)=>{if(!c(e[t]))return t;if(t>=r.start&&t<r.end)return Math.min(t+n,r.end);if(t>=r.previousStart&&t<r.previousEnd)return Math.min(t+n,r.previousEnd);let i=t+1;for(;c(e[i]);)i++;return r.previousStart=r.start,r.previousEnd=r.end,r.start=t,r.end=i,Math.min(t+n,i)},m=(e,t,r,i)=>!r&&e[t]===`0`?t+1:p(e,t,r?n:n+1,i),h=(e,t,i,a)=>{let o=p(e,t,n,a);if(u(e[o])||e[o]===`-`){let t=o+1,n=t+r;for(;t<n&&d(e[t]);)t++;return t}return m(e,t,i,a)},g=(e,t,n,r)=>{let i=e[t]===`-`;if(!n&&!i)return t;let a=t+ +!!i,o=h(e,a,n,r);if(o===a){if(!n||!i)return t;o=h(e,t,n,r)}for(;e[o]===`.`;){let t=h(e,o+1,n,r);if(t===o+1)break;o=t}return o},_=(e,t)=>{let n=t;for(;n-t<r&&d(e[n]);)n++;return n},v=(e,t)=>{if(e[t]!==`+`)return t;let n=_(e,t+1);if(n===t+1)return t;for(;e[n]===`.`;){let t=_(e,n+1);if(t===n+1)break;n=t}return n},y=(e,t,n)=>{let r=t;for(let i=0;i<3;i++){let a=m(e,r,!0,n);if(a===r)return t;if(r=a,i<2){if(e[r]!==`.`)return t;r++}}let i=g(e,r,!0,n);return v(e,i)},b=(e,t,n)=>c(e[t])?m(e,t,!1,n):f(e[t])?t+1:t,x=(e,t,n)=>{let r=b(e,t,n);for(let t=0;t<2;t++){if(e[r]!==`.`)return r;let t=b(e,r+1,n);if(t===r+1)return r;r=t}let i=g(e,r,!1,n);return v(e,i)},S=(e,t,n)=>{let r=y(e,t,n);return r===t?x(e,t,n):r},C=(e,t)=>{let n=t;return o(e[n])&&n++,(e[n]===`<`||e[n]===`>`)&&n++,e[n]===`=`&&n++,o(e[n])?n:-1};t.exports=e=>{let t=``,n=0,r=0,i={start:-1,end:-1,previousStart:-1,previousEnd:-1};for(;r<e.length;){let a=r;if(e[r]===`<`||e[r]===`>`)r++;else if(!s(e[r])&&!f(e[r])){r++;continue}for(;r<e.length&&s(e[r]);)r++;if(!f(e[r]))continue;let o=C(e,a);o!==-1&&(t+=e.slice(n,o),n=o+1),r=S(e,r,i)}return t+e.slice(n)}})),T=/* @__PURE__ */ t(((e,t)=>{let n=/\s+/g;t.exports=class e{constructor(t,r){if(r=i(r),t instanceof e)return t.loose===!!r.loose&&t.includePrerelease===!!r.includePrerelease?t:new e(t.raw,r);if(t instanceof a)return this.raw=t.value,this.set=[[t]],this.formatted=void 0,this;if(this.options=r,this.loose=!!r.loose,this.includePrerelease=!!r.includePrerelease,this.raw=t.trim().replace(n,` `),this.set=this.raw.split(`||`).map(e=>this.parseRange(e.trim())).filter(e=>e.length),!this.set.length)throw TypeError(`Invalid SemVer Range: ${this.raw}`);if(this.set.length>1){let e=this.set[0];if(this.set=this.set.filter(e=>!T(e[0])),this.set.length===0)this.set=[e];else if(this.set.length>1){for(let e of this.set)if(e.length===1&&E(e[0])){this.set=[e];break}}}this.formatted=void 0}get range(){if(this.formatted===void 0){this.formatted=``;for(let e=0;e<this.set.length;e++){e>0&&(this.formatted+=`||`);let t=this.set[e];for(let e=0;e<t.length;e++)e>0&&(this.formatted+=` `),this.formatted+=t[e].toString().trim()}}return this.formatted}format(){return this.range}toString(){return this.range}parseRange(e){e=e.replace(S,``);let t=((this.options.includePrerelease&&b)|(this.options.loose&&x))+`:`+e,n=r.get(t);if(n)return n;let i=this.options.loose,o=i?m[_.HYPHENRANGELOOSE]:m[_.HYPHENRANGE];e=e.replace(o,z(this.options.includePrerelease)),c(`hyphen replace`,e),e=p(e),c(`comparator trim`,e),e=e.replace(m[_.TILDETRIM],v),c(`tilde trim`,e),e=e.replace(m[_.CARETTRIM],y),c(`caret trim`,e);let s=e.split(` `).map(e=>O(e,this.options)).join(` `).split(/\s+/).map(e=>R(e,this.options));i&&(s=s.filter(e=>(c(`loose invalid filter`,e,this.options),!!e.match(m[_.COMPARATORLOOSE])))),c(`range list`,s);let l=/* @__PURE__ */ new Map,u=s.map(e=>new a(e,this.options));for(let e of u){if(T(e))return[e];l.set(e.value,e)}l.size>1&&l.has(``)&&l.delete(``);let d=[...l.values()];return r.set(t,d),d}intersects(t,n){if(!(t instanceof e))throw TypeError(`a Range is required`);return this.set.some(e=>D(e,n)&&t.set.some(t=>D(t,n)&&e.every(e=>t.every(t=>e.intersects(t,n)))))}test(e){if(!e)return!1;if(typeof e==`string`)try{e=new f(e,this.options)}catch{return!1}for(let t=0;t<this.set.length;t++)if(B(this.set[t],e,this.options))return!0;return!1}};let r=new(g()),i=s(),a=C(),c=d(),f=u(),p=w(),{safeRe:m,src:h,t:_,tildeTrimReplace:v,caretTrimReplace:y}=o(),{FLAG_INCLUDE_PRERELEASE:b,FLAG_LOOSE:x}=l(),S=new RegExp(h[_.BUILD],`g`),T=e=>e.value===`<0.0.0-0`,E=e=>e.value===``,D=(e,t)=>{let n=!0,r=e.slice(),i=r.pop();for(;n&&r.length;)n=r.every(e=>i.intersects(e,t)),i=r.pop();return n},O=(e,t)=>(e=e.replace(m[_.BUILD],``),c(`comp`,e,t),e=N(e,t),c(`caret`,e),e=j(e,t),c(`tildes`,e),e=F(e,t),c(`xrange`,e),e=L(e,t),c(`stars`,e),e),k=e=>!e||e.toLowerCase()===`x`||e===`*`,A=(e,t,n)=>k(e)&&!k(t)||k(t)&&n&&!k(n),j=(e,t)=>e.trim().split(/\s+/).map(e=>M(e,t)).join(` `),M=(e,t)=>{let n=t.loose?m[_.TILDELOOSE]:m[_.TILDE],r=t.includePrerelease?`-0`:``;return e.replace(n,(t,n,i,a,o)=>{c(`tilde`,e,t,n,i,a,o);let s;return k(n)?s=``:k(i)?s=`>=${n}.0.0${r} <${+n+1}.0.0-0`:k(a)?s=`>=${n}.${i}.0${r} <${n}.${+i+1}.0-0`:o?(c(`replaceTilde pr`,o),s=`>=${n}.${i}.${a}-${o} <${n}.${+i+1}.0-0`):s=`>=${n}.${i}.${a} <${n}.${+i+1}.0-0`,c(`tilde return`,s),s})},N=(e,t)=>e.trim().split(/\s+/).map(e=>P(e,t)).join(` `),P=(e,t)=>{c(`caret`,e,t);let n=t.loose?m[_.CARETLOOSE]:m[_.CARET],r=t.includePrerelease?`-0`:``;return e.replace(n,(t,n,i,a,o)=>{c(`caret`,e,t,n,i,a,o);let s;return k(n)?s=``:k(i)?s=`>=${n}.0.0${r} <${+n+1}.0.0-0`:k(a)?s=n===`0`?`>=${n}.${i}.0${r} <${n}.${+i+1}.0-0`:`>=${n}.${i}.0${r} <${+n+1}.0.0-0`:o?(c(`replaceCaret pr`,o),s=n===`0`?i===`0`?`>=${n}.${i}.${a}-${o} <${n}.${i}.${+a+1}-0`:`>=${n}.${i}.${a}-${o} <${n}.${+i+1}.0-0`:`>=${n}.${i}.${a}-${o} <${+n+1}.0.0-0`):(c(`no pr`),s=n===`0`?i===`0`?`>=${n}.${i}.${a} <${n}.${i}.${+a+1}-0`:`>=${n}.${i}.${a} <${n}.${+i+1}.0-0`:`>=${n}.${i}.${a} <${+n+1}.0.0-0`),c(`caret return`,s),s})},F=(e,t)=>(c(`replaceXRanges`,e,t),e.split(/\s+/).map(e=>I(e,t)).join(` `)),I=(e,t)=>{e=e.trim();let n=t.loose?m[_.XRANGELOOSE]:m[_.XRANGE];return e.replace(n,(n,r,i,a,o,s)=>{if(c(`xRange`,e,n,r,i,a,o,s),A(i,a,o))return e;let l=k(i),u=l||k(a),d=u||k(o),f=d;return r===`=`&&f&&(r=``),s=t.includePrerelease?`-0`:``,l?n=r===`>`||r===`<`?`<0.0.0-0`:`*`:r&&f?(u&&(a=0),o=0,r===`>`?(r=`>=`,u?(i=+i+1,a=0,o=0):(a=+a+1,o=0)):r===`<=`&&(r=`<`,u?i=+i+1:a=+a+1),r===`<`&&(s=`-0`),n=`${r+i}.${a}.${o}${s}`):u?n=`>=${i}.0.0${s} <${+i+1}.0.0-0`:d&&(n=`>=${i}.${a}.0${s} <${i}.${+a+1}.0-0`),c(`xRange return`,n),n})},L=(e,t)=>(c(`replaceStars`,e,t),e.trim().replace(m[_.STAR],``)),R=(e,t)=>(c(`replaceGTE0`,e,t),e.trim().replace(m[t.includePrerelease?_.GTE0PRE:_.GTE0],``)),z=e=>(t,n,r,i,a,o,s,c,l,u,d,f)=>(n=k(r)?``:k(i)?`>=${r}.0.0${e?`-0`:``}`:k(a)?`>=${r}.${i}.0${e?`-0`:``}`:o?`>=${n}`:`>=${n}${e?`-0`:``}`,c=k(l)?``:k(u)?`<${+l+1}.0.0-0`:k(d)?`<${l}.${+u+1}.0-0`:f?`<=${l}.${u}.${d}-${f}`:e?`<${l}.${u}.${+d+1}-0`:`<=${c}`,`${n} ${c}`.trim()),B=(e,t,n)=>{for(let n=0;n<e.length;n++)if(!e[n].test(t))return!1;if(t.prerelease.length&&!n.includePrerelease){for(let n=0;n<e.length;n++)if(c(e[n].semver),e[n].semver!==a.ANY&&e[n].semver.prerelease.length>0){let r=e[n].semver;if(r.major===t.major&&r.minor===t.minor&&r.patch===t.patch)return!0}return!1}return!0}})),E=/* @__PURE__ */ e((/* @__PURE__ */ t(((e,t)=>{let n=T();t.exports=(e,t,r)=>{try{t=new n(t,r)}catch{return!1}return t.test(e)}})))(),1);function D(e){let t=m(e);if(t.length===0)throw j(e),new r(1);if(t.length>1)throw M(t),new r(1);let[n]=t;if(!n)throw new r(1);if(!n.binary)throw N(n),new r(1);if(n.impl.versionConstraint!==void 0&&!O(n.installedVersion,n.impl.versionConstraint.range))throw k(n),new r(1);return n}function O(e,t){return e!==void 0&&(0,E.default)(e,t,{includePrerelease:!0})}function k(e){P(`${e.impl.pkg}@${e.installedVersion??`unknown`} is installed, but it is not compatible with cf's local runtime.`,A(e),e.impl)}function A(e){return`cf requires ${e.impl.versionConstraint?.display??`a compatible version`} for cf dev, cf build, cf deploy, and cf previews deploy.`}function j(e){console.error(a(`No Cloudflare dev server is installed in ${e}.`,`Checked package.json, pyproject.toml and Cargo.toml.`)),console.error(`
|
|
3
3
|
Install one of these:`);for(let e of p)console.error(`\n${n.bold(e.pkg)} ${n.muted(e.description)}`),F(e)}function M(e){console.error(a(`Multiple Cloudflare dev-server implementations are configured.`,[...e.map(e=>`${e.impl.pkg} (${e.manifestPath})`),``,`A project can only use one dev-server. Remove all but one from your project's manifest and try again.`].join(`
|
|
4
4
|
`)))}function N(e){e.installed&&e.impl.versionConstraint?P(`${e.impl.pkg} is declared in ${e.manifestPath}, but this installation does not include the cf delegate.`,A(e),e.impl):P(`${e.impl.pkg} is declared in ${e.manifestPath} but is not installed.`,void 0,e.impl)}function P(e,t,n){console.error(a(e,t)),console.error(`
|
|
5
|
-
Try:`),F(n)}function F(e){for(let t of e.installCommands)console.error(`${` `.repeat(3)}${n.code(t)}`)}function I(e,t=process.platform){return t!==`win32`||e!==`SIGINT`}function L(e,t,n){let r=t??n??void 0;return{exitCode:e??(r?128+(h.signals[r]??1):1),...r?{signal:r}:{}}}async function R(e,t,n,r={}){let a=r.output??`stderr`,o=e.binary;if(!o){let t=e.impl.installCommands.map(e=>`\`${e}\``);throw Error(`Cannot spawn ${e.impl.pkg}: binary not found.\nTry: ${new Intl.ListFormat(`en`,{type:`disjunction`}).format(t)}`)}let{command:s,prefixArgs:c}=B(o),l=i(s,[...c,t,...n],{nodePath:!1,nodeOptions:{stdio:[`inherit`,a===`inherit`?`inherit`:a===`silent`?`ignore`:process.stderr,`inherit`],env:z(r.env)}}),u,d=e=>{u??=e,I(e)&&l.kill(e)},f=()=>d(`SIGINT`),p=()=>d(`SIGTERM`);process.on(`SIGINT`,f),process.on(`SIGTERM`,p);try{return L((await l).exitCode??null,l.process?.signalCode??null,u)}finally{process.off(`SIGINT`,f),process.off(`SIGTERM`,p)}}function z(e={}){return{...V(process.env,`--no-deprecation`),...e
|
|
5
|
+
Try:`),F(n)}function F(e){for(let t of e.installCommands)console.error(`${` `.repeat(3)}${n.code(t)}`)}function I(e,t=process.platform){return t!==`win32`||e!==`SIGINT`}function L(e,t,n){let r=t??n??void 0;return{exitCode:e??(r?128+(h.signals[r]??1):1),...r?{signal:r}:{}}}async function R(e,t,n,r={}){let a=r.output??`stderr`,o=e.binary;if(!o){let t=e.impl.installCommands.map(e=>`\`${e}\``);throw Error(`Cannot spawn ${e.impl.pkg}: binary not found.\nTry: ${new Intl.ListFormat(`en`,{type:`disjunction`}).format(t)}`)}let{command:s,prefixArgs:c}=B(o),l=i(s,[...c,t,...n],{nodePath:!1,nodeOptions:{stdio:[`inherit`,a===`inherit`?`inherit`:a===`silent`?`ignore`:process.stderr,`inherit`],env:z(r.env)}}),u,d=e=>{u??=e,I(e)&&l.kill(e)},f=()=>d(`SIGINT`),p=()=>d(`SIGTERM`);process.on(`SIGINT`,f),process.on(`SIGTERM`,p);try{return L((await l).exitCode??null,l.process?.signalCode??null,u)}finally{process.off(`SIGINT`,f),process.off(`SIGTERM`,p)}}function z(e={}){return{...V(process.env,`--no-deprecation`),...e}}function B(e){return e.startsWith(`uv:`)?{command:`uv`,prefixArgs:[`run`,`--no-sync`,e.slice(3)]}:{command:e,prefixArgs:[]}}function V(e,t){let n=e.NODE_OPTIONS??``;return n.split(/\s+/).includes(t)?e:{...e,NODE_OPTIONS:n?`${n} ${t}`:t}}export{D as n,R as t};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-CRq9OQKr.mjs";import{i as n}from"./context-DsVjrTbe.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{t as i}from"./output-PRKYaJuo.mjs";import{t as a}from"./progress-DItBn6ZV.mjs";import{t as o}from"./run-DAK_kbUa.mjs";import"./telemetry-B3S5OfOn.mjs";import{r as s,s as c,t as l}from"./body-parser-HN91kAf0.mjs";import{n as u}from"./input-validation-D7z60HJH.mjs";import{a as d,n as f}from"./prompt-BGz3DNLz.mjs";var p={method:`GET`,path:t=>e`/zones/${t.zone_id}/spectrum/analytics/aggregate/current`,query:[`appID`,`colo_name`]};function m(e){return e.usage(`$0 spectrum analytics aggregates currents get
|
|
3
3
|
|
|
4
4
|
Retrieves analytics aggregated from the last minute of usage on Spectrum applications underneath a given zone.`).option(`app-id`,{type:`string`,description:`Comma-delimited list of Spectrum Application Id(s). If provided, the response will be limited to Spectrum Application Id(s) that match.`}).option(`colo-name`,{type:`string`,description:`Co-location identifier.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const h={command:`get`,describe:`Get current aggregated analytics`,builder:m,handler:async e=>o({command:`spectrum analytics aggregates currents get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{let o={appID:e[`app-id`],colo_name:e[`colo-name`]};if(e.dryRun){r({command:`cf spectrum analytics aggregates currents get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/spectrum/analytics/aggregate/current`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},query:o,bodyKind:`none`});return}let s=await t(e),c=await n({zone:e.zone},s,{quiet:e.quiet});e.zoneId=c;let l=await a(`Loading`,async()=>s.send(p,{zone_id:c,...o}));i(l,{successLabel:`Loaded`})})},g={command:`currents`,describe:`Operations for analytics.aggregates.currents`,builder:e=>e.command(h).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},_={command:`aggregates`,describe:`Operations for analytics.aggregates`,builder:e=>e.command(g).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var v={method:`GET`,path:t=>e`/zones/${t.zone_id}/spectrum/analytics/events/bytime`,query:[`dimensions`,`sort`,`until`,`metrics`,`filters`,`since`,`time_delta`]};function y(e){return e.usage(`$0 spectrum analytics events bytimes get
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-CRq9OQKr.mjs";import{i as n}from"./context-DsVjrTbe.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{t as i}from"./output-PRKYaJuo.mjs";import{t as a}from"./progress-DItBn6ZV.mjs";import{t as o}from"./run-DAK_kbUa.mjs";import"./telemetry-B3S5OfOn.mjs";import{r as s,t as c}from"./body-parser-HN91kAf0.mjs";import{n as l}from"./input-validation-D7z60HJH.mjs";import{n as u}from"./prompt-BGz3DNLz.mjs";var d={method:`GET`,path:t=>e`/zones/${t.zone_id}/speed_api/availabilities`};function f(e){return e.usage(`$0 speed availabilities list
|
|
3
3
|
|
|
4
4
|
Retrieves quota for all plans, as well as the current zone quota.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const p={command:`list`,describe:`Get quota and availability`,builder:f,handler:async e=>o({command:`speed availabilities list`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf speed availabilities list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/speed_api/availabilities`,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(d,{zone_id:s}));i(c,{successLabel:`Loaded`})})},m={command:`availabilities`,describe:`Check which speed test regions and configurations are available for your zone`,builder:e=>e.command(p).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var h={method:`GET`,path:t=>e`/zones/${t.zone_id}/speed_api/pages`};function g(e){return e.usage(`$0 speed pages list
|
|
5
5
|
|