cf 1.0.0-beta.1 → 1.0.0-beta.11
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 +12 -0
- package/dist/_meta/commands.json +11448 -13819
- package/dist/_meta/hand-written-commands.json +579 -41
- package/dist/_meta/schemas.json +14496 -16450
- package/dist/abuse-reports-DX5xgeka.mjs +24 -0
- package/dist/access-DuHs0Mii.mjs +2 -0
- package/dist/{account-tags-DAf-hq1m.mjs → account-tags-CiKwgOWd.mjs} +6 -6
- package/dist/{accounts-BDIKjiG2.mjs → accounts-DfXSHrkF.mjs} +63 -57
- package/dist/{acm-D-q1FVWJ.mjs → acm-BgSr3Ig4.mjs} +7 -7
- package/dist/{addressing-0w2U1NEy.mjs → addressing-B70NFnrX.mjs} +43 -43
- package/dist/agent-context-GRiQ4zRU.mjs +2 -0
- package/dist/{agent-memory-Drumm4qd.mjs → agent-memory-DJRquHeq.mjs} +15 -15
- package/dist/ai-CP2oIS-I.mjs +29 -0
- package/dist/{ai-audit-CPrmohqf.mjs → ai-audit-Bn_BfMFS.mjs} +3 -3
- package/dist/ai-gateway-CrrEtzUP.mjs +82 -0
- package/dist/{ai-search-B5l4IDSR.mjs → ai-search-C4YWVTCa.mjs} +42 -42
- package/dist/{ai-security-C7_IGDDl.mjs → ai-security-Bt_fG65f.mjs} +4 -4
- package/dist/{alerting-B6m1Rhf4.mjs → alerting-CRr88fVR.mjs} +26 -26
- package/dist/{analytics-nnzFBB_7.mjs → analytics-XqS9OP5B.mjs} +11 -12
- package/dist/{analytics_engine-BvjKCwn1.mjs → analytics_engine-CzmYem4f.mjs} +2 -2
- package/dist/{api-security-B9IozS2a.mjs → api-security-gB1FHrHq.mjs} +57 -57
- package/dist/{argo-C_QcqR6P.mjs → argo-wFCAsYx7.mjs} +5 -5
- package/dist/args-CXgkQKK7.mjs +2 -0
- package/dist/{artifacts-DDFNpYBz.mjs → artifacts-qFjlNRqb.mjs} +20 -20
- package/dist/{audit-logs-cTzNV0DV.mjs → audit-logs-CpPUjMUP.mjs} +2 -2
- package/dist/auth-7Fk7PVIC.mjs +2 -0
- package/dist/auth-BmJ946bE.mjs +2 -0
- package/dist/auth-Br-t8vL_.mjs +2 -0
- package/dist/auth-token-DeG33BMQ.mjs +8 -0
- package/dist/autoconfig-D-copdZG.mjs +511 -0
- package/dist/banner-Xk4xBN8U.mjs +2 -0
- package/dist/basin-catalog-CshcpsAH.mjs +46 -0
- package/dist/{billing-DU2X-q-x.mjs → billing-B-xNxxiP.mjs} +11 -11
- package/dist/{bot-management-BHAAoZOh.mjs → bot-management-DhafeA2J.mjs} +4 -4
- package/dist/{botnet-feed-DOOnGVVY.mjs → botnet-feed-D6uCLE_D.mjs} +5 -5
- package/dist/{brand-protection-C_DYa7IK.mjs → brand-protection-c3WiHbYn.mjs} +13 -13
- package/dist/browser-extension-Dee2Y1qn.mjs +2 -0
- package/dist/{browser-run-Dw-vgWGR.mjs → browser-run-D9_cwaSD.mjs} +24 -24
- package/dist/build-9ihDp-Gy.mjs +2 -0
- package/dist/build-DrG6TqMw.mjs +2 -0
- package/dist/{builds-CO0MmSd3.mjs → builds-Dl8if-2k.mjs} +32 -32
- package/dist/cache-CIZokBjd.mjs +45 -0
- package/dist/{certificate-authorities-Dmxh7w-Z.mjs → certificate-authorities-NUQzCDK8.mjs} +3 -3
- package/dist/cf-DfQfIu3q.mjs +18 -0
- package/dist/chunk-FT2NMTJB-BFqlGcem.mjs +97 -0
- package/dist/chunk-KKDV4JPS-B_t8sDTz.mjs +2 -0
- package/dist/chunk-U6NEESU5-BhF4rnpx.mjs +2 -0
- package/dist/chunk-WMOON6TZ-B8xCqjB1.mjs +2 -0
- package/dist/cli-aChy8ou_.mjs +6 -0
- package/dist/cli-exit-Dqoo6Jgb.mjs +2 -0
- package/dist/client-certificates-qgLpBn8t.mjs +13 -0
- package/dist/{client-side-security-D7NWV0YH.mjs → client-side-security-DZO6Xw14.mjs} +14 -14
- package/dist/{cloud-connector-XMFOTNqT.mjs → cloud-connector-C7vGDCzX.mjs} +3 -3
- package/dist/{cloudflared-DhItYrCq.mjs → cloudflared-CEfZhSQH.mjs} +1 -1
- package/dist/{cloudforce-one-Cew4MHvA.mjs → cloudforce-one-CE7y5UkF.mjs} +237 -246
- package/dist/command-07vhr56i.mjs +2 -0
- package/dist/command-B6TpINoN.mjs +2 -0
- package/dist/command-BWC9CbE7.mjs +2 -0
- package/dist/command-BsmF3J_l.mjs +2 -0
- package/dist/command-C2pNxAeL.mjs +2 -0
- package/dist/command-C65Ed0o9.mjs +2 -0
- package/dist/command-Cdx___59.mjs +2 -0
- package/dist/command-CrtDkZNs.mjs +2 -0
- package/dist/command-D0MKPucK.mjs +2 -0
- package/dist/command-DHdWKtqx.mjs +2 -0
- package/dist/command-Ds5OVat3.mjs +2 -0
- package/dist/command-Dv6YavZa.mjs +2 -0
- package/dist/command-dAYWrB5y.mjs +2 -0
- package/dist/command-eM48o0J6.mjs +2 -0
- package/dist/command-maDJWJgu.mjs +2 -0
- package/dist/{completions-xPLd1cvL.mjs → completions-D0280hul.mjs} +26 -26
- package/dist/{connector-interrupts-BfQN_pm6.mjs → connector-interrupts-CVjFhU-C.mjs} +3 -3
- package/dist/{connector-telemetry-events-B7qLZsZJ.mjs → connector-telemetry-events-Bu3LKP6T.mjs} +3 -3
- package/dist/{connector-telemetry-snapshots-Ckvg9BPc.mjs → connector-telemetry-snapshots-BbDTIc06.mjs} +3 -3
- package/dist/{connectors-BhvAP5fb.mjs → connectors-DGtx-rPI.mjs} +7 -7
- package/dist/{containers-Cq1gtnq6.mjs → containers-CzNbBrYE.mjs} +70 -72
- package/dist/{containers-Bl3EY-cy.mjs → containers-DEFrbNgO.mjs} +17 -17
- package/dist/{content-scan-BYGe9fFj.mjs → content-scan-BCtWBCqd.mjs} +6 -6
- package/dist/context-CquYYyS3.mjs +7 -0
- package/dist/{cps-BWMDWeVq.mjs → cps-C8BbnbuD.mjs} +1 -1
- package/dist/{csamScanner-DMYGzLNi.mjs → csamScanner-CsJ9H2fA.mjs} +3 -3
- package/dist/{ct-alerting-Vq4l2s7n.mjs → ct-alerting-CYsQZO2H.mjs} +3 -3
- package/dist/{custom-certificates-BDEHH0Ym.mjs → custom-certificates-CA8HqolM.mjs} +8 -8
- package/dist/{custom-csrs-CHSkZNdX.mjs → custom-csrs-D0P2vWJE.mjs} +5 -5
- package/dist/{custom-hostnames-Bch3iQZC.mjs → custom-hostnames-CzYMChbh.mjs} +12 -12
- package/dist/{custom-nameservers-Tdvu1-vr.mjs → custom-nameservers-Cet3oF56.mjs} +5 -5
- package/dist/{custom-pages-rFsiIXlr.mjs → custom-pages-DUkHIaTP.mjs} +10 -10
- package/dist/d1-B2duXfH2.mjs +41 -0
- package/dist/{dcv-delegation-D6xiYj2l.mjs → dcv-delegation-BkdRVEAH.mjs} +2 -2
- package/dist/{delegate-GctF_lrq.mjs → delegate-CCGgla7X.mjs} +1 -1
- package/dist/delegate.mjs +1 -1
- package/dist/{deploy-D04Xvm0m.mjs → deploy-BdWBEbLj.mjs} +1 -1
- package/dist/{deploy-input-COEKxOA1.mjs → deploy-input-LmLfj6kI.mjs} +1 -1
- package/dist/dev-BHkVwAea.mjs +4 -0
- package/dist/{diagnostics-BZVAAguV.mjs → diagnostics-9Wj5UWBL.mjs} +7 -7
- package/dist/dialog-Dpi-UVbz.mjs +2 -0
- package/dist/discover-BYkHr5Ja.mjs +2 -0
- package/dist/discover-t6E9lpf3.mjs +2 -0
- package/dist/{dist-BpadEMNY.mjs → dist-Cpb7_h4N.mjs} +35 -35
- package/dist/dist-D1iG7guo.mjs +366 -0
- package/dist/dist-zep5OXGt.mjs +48 -0
- package/dist/{dls-BsnURYja.mjs → dls-Caya7FZc.mjs} +8 -8
- package/dist/{dns-B_nTXhuM.mjs → dns-BLNa0GrP.mjs} +72 -63
- package/dist/{dns-firewall-DDsrdulo.mjs → dns-firewall-ChCvC5rT.mjs} +8 -8
- package/dist/dot-prop-IITUZ2XW-BsZYdILY.mjs +2 -0
- package/dist/dotenv-CcQjGlV0.mjs +4 -0
- package/dist/dry-run-p9Q7nMZ5.mjs +2 -0
- package/dist/durable-objects-DuRbdp7N.mjs +6 -0
- package/dist/{email-auth-CzjtGH6g.mjs → email-auth-C28s03aI.mjs} +3 -3
- package/dist/{email-routing-B92fty1-.mjs → email-routing-Ci-xjXIN.mjs} +24 -24
- package/dist/email-security-DPU6xvI9.mjs +158 -0
- package/dist/{email-sending-B7f95epu.mjs → email-sending-kTVAlVKO.mjs} +23 -23
- package/dist/error-sanitization-BbEw--0B.mjs +2 -0
- package/dist/error-sanitization-p5rmb53x.mjs +2 -0
- package/dist/errors-cuuW88wR.mjs +3 -0
- package/dist/{fieldExtractors-DL_H1m7E.mjs → fieldExtractors-ceaXu4zD.mjs} +4 -4
- package/dist/firewall-BND3qSY2.mjs +36 -0
- package/dist/flagship-DfxbNzgx.mjs +28 -0
- package/dist/{fraud-DU_YCLC5.mjs → fraud-DgyYv_CC.mjs} +3 -3
- package/dist/generate-9P8Q_RiO.mjs +2 -0
- package/dist/generate-VxmGG8BF.mjs +3 -0
- package/dist/{google-tag-gateway-xqN-QudN.mjs → google-tag-gateway-v3p7murv.mjs} +3 -3
- package/dist/gt-KlYHH-UC.mjs +2 -0
- package/dist/{healthchecks-COnq1YOx.mjs → healthchecks-CByb4qYA.mjs} +10 -10
- package/dist/{hostnames-CxRAY_Pp.mjs → hostnames-3CqeMF5g.mjs} +6 -6
- package/dist/hyperdrive-CmyYTE-K.mjs +37 -0
- package/dist/{iam-CtX9NPCy.mjs → iam-CV_M681j.mjs} +24 -24
- package/dist/{images-CuWFOsGw.mjs → images-DaLPjskW.mjs} +33 -33
- package/dist/index.mjs +1 -1
- package/dist/init-CBKifk5L.mjs +39 -0
- package/dist/{intel-BeGV3VXt.mjs → intel-MpftjuPB.mjs} +36 -36
- package/dist/interactive-D80kbTap.mjs +32 -0
- package/dist/interactive-mJQ_IrGd.mjs +2 -0
- package/dist/{ips-d6aoKAI4.mjs → ips-WWvPwSBc.mjs} +1 -1
- package/dist/k2-D0QYUFqT.mjs +13 -0
- package/dist/keyless-certificates-DqILy3t9.mjs +13 -0
- package/dist/{keys-Fyf3vWcA.mjs → keys-DhX4AcqF.mjs} +2 -2
- package/dist/kv-DLUfUL0_.mjs +15 -0
- package/dist/lazy-command--5YpWUVY.mjs +2 -0
- package/dist/{leaked-credential-checks-B7ewx3W-.mjs → leaked-credential-checks-C0U1oYM5.mjs} +8 -8
- package/dist/{load-balancers-DHD4f2CT.mjs → load-balancers-BJKI9lm7.mjs} +39 -39
- package/dist/local-DkYQiSQQ.mjs +2 -0
- package/dist/{local-B6b2OIBW.mjs → local-rYpzEQb-.mjs} +1 -1
- package/dist/{local-runtime-DD8DAIlm.mjs → local-runtime-DZTTIe6x.mjs} +1 -1
- package/dist/login-CnE2Ii_F.mjs +2 -0
- package/dist/login-bnylLTit.mjs +5 -0
- package/dist/{logo-matches-BAX8v3iL.mjs → logo-matches-DFZybI0C.mjs} +3 -3
- package/dist/{logos-BWBVGwU6.mjs → logos-Da2YtqSN.mjs} +4 -4
- package/dist/{logpush-CZKR8DHO.mjs → logpush-Q7WIEHS1.mjs} +23 -23
- package/dist/logs-c3b3USyS.mjs +36 -0
- package/dist/{magic-cloud-networking-DttrBXqd.mjs → magic-cloud-networking-BoyDmFq3.mjs} +37 -37
- package/dist/{magic-network-monitoring-9VXDSYuL.mjs → magic-network-monitoring-BkUbpMUp.mjs} +18 -18
- package/dist/{magic-transit-Dsu_cSGM.mjs → magic-transit-4-THD45G.mjs} +161 -165
- package/dist/{managed-defense-SYreve4W.mjs → managed-defense-CTMqSp6z.mjs} +9 -9
- package/dist/{managed-transforms-CzSy_xPw.mjs → managed-transforms-DcYAvqTe.mjs} +4 -4
- package/dist/{matches-qf7GReyu.mjs → matches-hnU16rSJ.mjs} +3 -3
- package/dist/{mcp-DYSk5_gc.mjs → mcp-kZX4irfN.mjs} +15 -15
- package/dist/{mesh-DdY07OYt.mjs → mesh-Dxzvvso6.mjs} +12 -12
- package/dist/migrate-BNvUWrjy.mjs +2 -0
- package/dist/monetization-Dsqj9DCA.mjs +20 -0
- package/dist/mtls-certificates-BSbMwIna.mjs +13 -0
- package/dist/{network-interconnects-C4uUoeNa.mjs → network-interconnects-osO_vAPu.mjs} +17 -17
- package/dist/{network-DpaZ5LJL.mjs → network-mEnXTEiG.mjs} +24 -24
- package/dist/oauth-CeZ3d_dB.mjs +9 -0
- package/dist/{oauth-clients-D7Ou7oAS.mjs → oauth-clients-CWPHi-Yn.mjs} +7 -7
- package/dist/{oauth-scopes-BFoE82Mv.mjs → oauth-scopes-CxpRD6d7.mjs} +1 -1
- package/dist/{oauth-nsTDJ0dF.mjs → oauth-w0fWmrwU.mjs} +1 -1
- package/dist/{observability-smcOFbC1.mjs → observability-BxL2RqWZ.mjs} +44 -44
- package/dist/open-PCXX3ZDZ-C7gpxSsl.mjs +4 -0
- package/dist/{organization-Dyf_0mq4.mjs → organization-DNieJ1xJ.mjs} +7 -7
- package/dist/{organizations-D7zGPLVm.mjs → organizations-BIXPmTy5.mjs} +1 -1
- package/dist/{origin-ca-certificates-DJrp29gv.mjs → origin-ca-certificates-dVJvSIH8.mjs} +3 -3
- package/dist/{origin-post-quantum-encryption-BYj3kJiq.mjs → origin-post-quantum-encryption-CO6tDW1t.mjs} +3 -3
- package/dist/{origin-tls-client-auth-j0tGh6Fy.mjs → origin-tls-client-auth-DeTY8aN2.mjs} +14 -14
- package/dist/output-ClYel9WX.mjs +2 -0
- package/dist/{page-rules-CLzba_nr.mjs → page-rules-DA552Ra4.mjs} +7 -7
- package/dist/pages-B0x7tidm.mjs +54 -0
- package/dist/{pay-per-crawl-DbaTVI8V.mjs → pay-per-crawl-DoTg9VP7.mjs} +32 -32
- package/dist/{pay-per-use-BEvtoppJ.mjs → pay-per-use-yRO2QBfe.mjs} +3 -3
- package/dist/{pipelines-lps71uoA.mjs → pipelines-CQxrm9ao.mjs} +20 -20
- package/dist/precursor-FiGYDRV9.mjs +4 -0
- package/dist/previews-BthBa50j.mjs +4 -0
- package/dist/progress-TLUEIYE6.mjs +2 -0
- package/dist/prompt-Ck_1PCHm.mjs +3 -0
- package/dist/{queries-EJYlFw8m.mjs → queries-C0RRdol7.mjs} +4 -4
- package/dist/{queues-CozKGaA4.mjs → queues-sLgvjsRP.mjs} +29 -35
- package/dist/r2-C2PllL6i.mjs +125 -0
- package/dist/r2-data-catalog-Bg7zq1IB.mjs +2 -0
- package/dist/{radar-NmpdyMo5.mjs → radar-Bez6k9Dw.mjs} +1 -1
- package/dist/raw-fetch-DNxNCoeP.mjs +2 -0
- package/dist/{realtime-iWTz8WbH.mjs → realtime-D-HSXznX.mjs} +78 -78
- package/dist/{registrar-Cza1L8i_.mjs → registrar-DwHrG9QR.mjs} +9 -9
- package/dist/{registrar-sandbox-BP4GQg5s.mjs → registrar-sandbox-jNukmzQP.mjs} +6 -6
- package/dist/{registry-vreNkX6u.mjs → registry-CsSLAAOE.mjs} +1 -1
- package/dist/{reporting-gvXX2MxY.mjs → reporting-DolhAb10.mjs} +7 -7
- package/dist/request-headers-Lhj314mk.mjs +2 -0
- package/dist/{request-tracers-F8a_aj32.mjs → request-tracers-w72hKc33.mjs} +2 -2
- package/dist/resolve-Djf2xgBx.mjs +2 -0
- package/dist/{resource-sharing-D6XWIDmb.mjs → resource-sharing-DTrSkqI4.mjs} +18 -18
- package/dist/{resource-tagging-c_z4VZt0.mjs → resource-tagging-aURR4fIJ.mjs} +2 -2
- package/dist/{rules-_QDaG3U5.mjs → rules-C8a7cV-W.mjs} +8 -8
- package/dist/{rulesets-Bc4ZuPG_.mjs → rulesets-RJ6yBefy.mjs} +20 -20
- package/dist/{rum-ChPyfpM2.mjs → rum-Bk1dPW4p.mjs} +14 -14
- package/dist/run-BJOAPmsz.mjs +2 -0
- package/dist/run-iFM5TxtQ.mjs +2 -0
- package/dist/{schema-flags-C9lbLgE-.mjs → schema-flags-PagOq-G2.mjs} +2 -2
- package/dist/schema-v7mOxMdx.mjs +2 -0
- package/dist/{scim-BjiswXbC.mjs → scim-C0FmjkkV.mjs} +10 -10
- package/dist/{secrets-store-Cn3D5a0d.mjs → secrets-store-cG_5RMzK.mjs} +11 -11
- package/dist/security-insights-DVAqroY5.mjs +40 -0
- package/dist/{security-txt-CaR5Idmz.mjs → security-txt-rfrrdiZV.mjs} +4 -4
- package/dist/session-B6mFkaVZ.mjs +2 -0
- package/dist/shared-BqsWoApw.mjs +2 -0
- package/dist/{smart-shield-CphSzoh4.mjs → smart-shield-_HA814Im.mjs} +11 -11
- package/dist/{snippets-r-Mre0cE.mjs → snippets-mRelEw0p.mjs} +10 -10
- package/dist/source-38bULAR8.mjs +6 -0
- package/dist/spawn-BzPhcLJI.mjs +10 -0
- package/dist/{spectrum-BhjCVFZk.mjs → spectrum-BwtOiaDw.mjs} +11 -11
- package/dist/{speed-CPgypY7n.mjs → speed-DmqsZtiJ.mjs} +11 -11
- package/dist/src--KDGqL5N.mjs +109 -0
- package/dist/{ssl-DsMrXyqK.mjs → ssl-DCvfveJB.mjs} +16 -16
- package/dist/startup-profile-BCe9k9sR.mjs +17 -0
- package/dist/startup-profile-WrwRyMwH.mjs +2 -0
- package/dist/{state-BxCejn42.mjs → state-BPwdiNO_.mjs} +1 -1
- package/dist/state-a1tTOGjm.mjs +2 -0
- package/dist/{stream-L2NmGPby.mjs → stream-aroClJeD.mjs} +56 -56
- package/dist/{submit-KN0Ul5fV.mjs → submit-BBKhoKT8.mjs} +2 -2
- package/dist/{tags-CZMFKGdP.mjs → tags-Djw0e-4j.mjs} +2 -2
- package/dist/telemetry-DoBQOGRk.mjs +2 -0
- package/dist/telemetry-DrFNujdx.mjs +2 -0
- package/dist/{tenant-custom-nameservers-Nx59Buv0.mjs → tenant-custom-nameservers-XCbXryBZ.mjs} +1 -1
- package/dist/tenant-tc1wb_ym.mjs +10 -0
- package/dist/{theme-BiIYWOed.mjs → theme-BIWQFmZ0.mjs} +2 -2
- package/dist/tools-CB4NleeJ.mjs +2 -0
- package/dist/{tunnels-C-mMZy4v.mjs → tunnels-C2FTswb6.mjs} +15 -15
- package/dist/{turnstile-39JL9tMt.mjs → turnstile-BV4Mdd-j.mjs} +8 -8
- package/dist/ui-D1hhIDIs.mjs +5 -0
- package/dist/update-check-CFt6cMOi.mjs +2 -0
- package/dist/update-check-Dtj9fzNe.mjs +2 -0
- package/dist/update-check-worker.mjs +1 -1
- package/dist/{url-info-7ikewAnp.mjs → url-info-CeegsDK7.mjs} +2 -2
- package/dist/{url-normalization-B0D7Fhf3.mjs → url-normalization-Dbypc9wz.mjs} +4 -4
- package/dist/{url-scanner-DpKIqkin.mjs → url-scanner-BFXMrpJF.mjs} +8 -8
- package/dist/{user-BFq8UM1s.mjs → user-3uwLMH78.mjs} +1 -1
- package/dist/{values-DnBYV1ZD.mjs → values-BTncDc3U.mjs} +2 -2
- package/dist/{vectorize-BpZ4UsUj.mjs → vectorize-CtMAtx8r.mjs} +17 -17
- package/dist/version-oN1bmOgM.mjs +2 -0
- package/dist/{waiting-rooms-DJfqehy9.mjs → waiting-rooms-1xDvjF13.mjs} +25 -25
- package/dist/{web-assets-CCSSW_JH.mjs → web-assets-BfEprX1S.mjs} +29 -29
- package/dist/{web3-bbT1REPc.mjs → web3-DNbp5sZw.mjs} +13 -13
- package/dist/workers-DK_JgS4Y.mjs +38 -0
- package/dist/{workers-builds-TRF3K416.mjs → workers-builds-CdhwmmsQ.mjs} +7 -7
- package/dist/workers-for-platforms-CP6IqxrK.mjs +42 -0
- package/dist/{workers-vpc-kgryQ48l.mjs → workers-vpc-LVfayM2-.mjs} +6 -6
- package/dist/{workflows-CKdPlIkK.mjs → workflows-CA5K8FFb.mjs} +23 -23
- package/dist/wrangler-migration-B0mKHqGd.mjs +2 -0
- package/dist/{zaraz-BXFlEWSx.mjs → zaraz-BY60ZUQ4.mjs} +11 -11
- package/dist/{zero-trust-M08mBsYd.mjs → zero-trust-CQNohO7_.mjs} +460 -434
- package/dist/{zone-DHmrotGW.mjs → zone-BVDW2UGd.mjs} +2 -2
- package/dist/{zones-C0eKBTqG.mjs → zones-CcZL0YQp.mjs} +44 -44
- package/package.json +23 -15
- package/dist/abuse-reports-Dd6kJM7r.mjs +0 -26
- package/dist/access-C_2rEi0H.mjs +0 -27
- package/dist/account-CZ9SPVdz.mjs +0 -12
- package/dist/ai-ARwLeQ1O.mjs +0 -31
- package/dist/ai-gateway-DNY4FPF2.mjs +0 -147
- package/dist/auth-DJhSjNNL.mjs +0 -8
- package/dist/auth-sAorfdWU.mjs +0 -2
- package/dist/browser-extension-C48pKh3t.mjs +0 -15
- package/dist/build-1a8CiNIT.mjs +0 -2
- package/dist/build-Ca_drQY2.mjs +0 -2
- package/dist/cache-XxusQxXe.mjs +0 -45
- package/dist/cf-oadujOtC.mjs +0 -18
- package/dist/chunk-6EUZQHAF-QVTL_mC-.mjs +0 -2
- package/dist/chunk-DL5FNmn1.mjs +0 -2
- package/dist/chunk-Q72B4Q5Z-Cr1H_iK6.mjs +0 -2
- package/dist/chunk-Q72B4Q5Z-DKhx_4ok.mjs +0 -2
- package/dist/chunk-QBZBEHZB-Byagrlop.mjs +0 -2
- package/dist/chunk-XLADBZ7F-BXKOjWbx.mjs +0 -374
- package/dist/client-certificates-CgaIc3zN.mjs +0 -13
- package/dist/command-CF0giIIc.mjs +0 -3
- package/dist/command-CsZFRm3P.mjs +0 -2
- package/dist/command-DBz8QiFk.mjs +0 -2
- package/dist/command-RiZ_LYcm.mjs +0 -2
- package/dist/config-B4vIa0zp.mjs +0 -2
- package/dist/d1-C1GK7DsW.mjs +0 -45
- package/dist/data-security-DDhPnX8Z.mjs +0 -71
- package/dist/dev-CVD3BVUG.mjs +0 -4
- package/dist/dialog--iw0F2s-.mjs +0 -2
- package/dist/dist-CUUGKvjh.mjs +0 -48
- package/dist/dist-dc4E1u01.mjs +0 -272
- package/dist/dot-prop-6SRZBKHT-Dj7YOlwR.mjs +0 -2
- package/dist/dry-run-CLX6Pbtq.mjs +0 -2
- package/dist/durable-objects-8U8DpF9q.mjs +0 -8
- package/dist/email-security-keTqF0nJ.mjs +0 -160
- package/dist/error-sanitization-Cbd_oegl.mjs +0 -2
- package/dist/error-sanitization-DwOlM3R7.mjs +0 -2
- package/dist/firewall-67qoXiqD.mjs +0 -56
- package/dist/flagship-CjC3dF7L.mjs +0 -28
- package/dist/hyperdrive-DPWyiXpj.mjs +0 -37
- package/dist/interactive-B6woOLo-.mjs +0 -32
- package/dist/interactive-DnUvQHjc.mjs +0 -2
- package/dist/keyless-certificates-Dvib4jhw.mjs +0 -13
- package/dist/kv-CA4J7cCq.mjs +0 -21
- package/dist/local-BrfySqnx.mjs +0 -2
- package/dist/login-CLW108XX.mjs +0 -5
- package/dist/login-xgRjiyJa.mjs +0 -2
- package/dist/logs-CiDyrqEu.mjs +0 -48
- package/dist/mtls-certificates-LXlgdkf1.mjs +0 -13
- package/dist/oauth-Dzk6Gy-6.mjs +0 -14
- package/dist/open-PBXRGS4R-C4CKEADM.mjs +0 -4
- package/dist/open-PBXRGS4R-C_-G_4DC.mjs +0 -4
- package/dist/output-Bia1u2k5.mjs +0 -2
- package/dist/pages-pah6dZBJ.mjs +0 -60
- package/dist/precursor-DTTYLDEa.mjs +0 -4
- package/dist/previews-B89cUmpr.mjs +0 -4
- package/dist/progress-D_mL-Kcy.mjs +0 -2
- package/dist/prompt-sL_yMZbI.mjs +0 -3
- package/dist/r2-Chn_JQUM.mjs +0 -127
- package/dist/r2-data-catalog-Bfn3AWzn.mjs +0 -44
- package/dist/raw-fetch-lSVttVJF.mjs +0 -2
- package/dist/request-headers-POBKmu93.mjs +0 -2
- package/dist/resolve-BXemCSyA.mjs +0 -2
- package/dist/run-DtN51G2A.mjs +0 -2
- package/dist/run-oACgYK8I.mjs +0 -2
- package/dist/schema-DZSSJaY0.mjs +0 -2
- package/dist/sdk-CsWOex96.mjs +0 -3
- package/dist/security-center-DP4GC1cG.mjs +0 -30
- package/dist/shared-W9uoX1-W.mjs +0 -2
- package/dist/source-BR4_k2ad.mjs +0 -6
- package/dist/spawn-BWEuIO-w.mjs +0 -523
- package/dist/src-Hw-TlVAO.mjs +0 -108
- package/dist/startup-profile-CYEokTVe.mjs +0 -2
- package/dist/startup-profile-CgWHy4rE.mjs +0 -17
- package/dist/state-DSzkxXML.mjs +0 -2
- package/dist/telemetry-CSj_ezpk.mjs +0 -2
- package/dist/telemetry-DAf9gLyH.mjs +0 -2
- package/dist/telemetry-Dk1GcQ0u.mjs +0 -5
- package/dist/tenant-Cu4P-foo.mjs +0 -12
- package/dist/tools-BMKpYraQ.mjs +0 -2
- package/dist/ui-DH95w1Qk.mjs +0 -5
- package/dist/undici-DTSBJHNS.mjs +0 -96
- package/dist/update-check-BKQBD4MQ.mjs +0 -2
- package/dist/update-check-CE9XB6gf.mjs +0 -2
- package/dist/version-Bh3b9vTa.mjs +0 -2
- package/dist/workers-CXuyjZB8.mjs +0 -36
- package/dist/workers-for-platforms-B57iKiSN.mjs +0 -25
- /package/dist/{Page-C-JHZnIy.mjs → Page-DAgOEX17.mjs} +0 -0
- /package/dist/{alerts-CstOk8n0.mjs → alerts-D3iKtzoN.mjs} +0 -0
- /package/dist/{autorag-PRTwXGgn.mjs → autorag-pvRfDwne.mjs} +0 -0
- /package/dist/{body-parser-CUWbw_Tq.mjs → body-parser-NjzJZMOV.mjs} +0 -0
- /package/dist/{brands-BHRXlWDm.mjs → brands-DP5Ndir1.mjs} +0 -0
- /package/dist/{clear-UvKESVx3.mjs → clear-qLKPlJqb.mjs} +0 -0
- /package/dist/{cli-types-tt_LZMbn.mjs → cli-types-_Kmwfpnp.mjs} +0 -0
- /package/dist/{connector-telemetry-events-latest-DwnFeZg0.mjs → connector-telemetry-events-latest-_aCmWeZx.mjs} +0 -0
- /package/dist/{connector-telemetry-snapshots-latest-Dv6rZlxs.mjs → connector-telemetry-snapshots-latest-CffEplpV.mjs} +0 -0
- /package/dist/{domain-info-BqTDXNBo.mjs → domain-info-BQh9XapD.mjs} +0 -0
- /package/dist/{health-CwPzzrV6.mjs → health--10IShMi.mjs} +0 -0
- /package/dist/{input-validation-Ch4Vllrm.mjs → input-validation-0CeePPHp.mjs} +0 -0
- /package/dist/{internal-WLHfxX64.mjs → internal-BUs583vv.mjs} +0 -0
- /package/dist/{lifecycle-Ichnb2x1.mjs → lifecycle-Cyc3fmyN.mjs} +0 -0
- /package/dist/{live-D_k7eHdv.mjs → live-VCSxA0N9.mjs} +0 -0
- /package/dist/{metadata-APBiectA.mjs → metadata-C33s4rc-.mjs} +0 -0
- /package/dist/{project-settings-DSXevRvj.mjs → project-settings-Bf6rReo1.mjs} +0 -0
- /package/dist/{rate-limit-analytics-CDTPxSET.mjs → rate-limit-analytics-D3q0mGv2.mjs} +0 -0
- /package/dist/{rate-limits-C3K9smdl.mjs → rate-limits-BIxlBuMn.mjs} +0 -0
- /package/dist/{ready-CvwvbdTX.mjs → ready-CAgelFmC.mjs} +0 -0
- /package/dist/{recent-submissions-CjzcT-iH.mjs → recent-submissions-B3TOjNmk.mjs} +0 -0
- /package/dist/{refute-CIAFMj00.mjs → refute-BZNkFpBB.mjs} +0 -0
- /package/dist/{resolve-CUDKxUrW.mjs → resolve-CGKqk7q8.mjs} +0 -0
- /package/dist/{scan-logo-zFkphtQ3.mjs → scan-logo-StecHiaf.mjs} +0 -0
- /package/dist/{scan-page-CLl2MAkZ.mjs → scan-page-B4adr-vD.mjs} +0 -0
- /package/dist/{search-12jA1b4l.mjs → search-Devngw4M.mjs} +0 -0
- /package/dist/{signed-url-U0T_PEMR.mjs → signed-url-ChR5eXXd.mjs} +0 -0
- /package/dist/{submission-info-CZ84a3Nb.mjs → submission-info-BGb81HZN.mjs} +0 -0
- /package/dist/{total-queries-CJTc9Pde.mjs → total-queries-_wa6KxEl.mjs} +0 -0
- /package/dist/{tracked-domains-BKLxnnSv.mjs → tracked-domains-BesKGqfI.mjs} +0 -0
- /package/dist/{verify-CZW5Fo1q.mjs → verify-CYM5GlPu.mjs} +0 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{t as e}from"./local-
|
|
2
|
+
import{t as e}from"./local-rYpzEQb-.mjs";import{n as t}from"./auth-Br-t8vL_.mjs";import{a as n,t as r}from"./context-CquYYyS3.mjs";import{t as i}from"./output-ClYel9WX.mjs";import{t as a}from"./dry-run-p9Q7nMZ5.mjs";import{t as o}from"./progress-TLUEIYE6.mjs";import{t as s}from"./run-iFM5TxtQ.mjs";import"./telemetry-DoBQOGRk.mjs";import{n as c,t as l}from"./body-parser-NjzJZMOV.mjs";import{n as u}from"./input-validation-0CeePPHp.mjs";import{a as d,n as f}from"./prompt-Ck_1PCHm.mjs";function p(e){return e.usage(`$0 dns-firewall create
|
|
3
3
|
|
|
4
4
|
Create a DNS Firewall cluster`).option(`attack-mitigation-enabled`,{type:`boolean`,description:`When enabled, automatically mitigate random-prefix attacks to protect upstream DNS servers`}).option(`attack-mitigation-only-when-upstream-unhealthy`,{type:`boolean`,description:`Only mitigate attacks when upstream servers seem unhealthy`}).option(`deprecate-any-requests`,{type:`boolean`,description:`Whether to refuse to answer queries for the ANY type`}).option(`ecs-fallback`,{type:`boolean`,description:`Whether to forward client IP (resolver) subnet if no EDNS Client Subnet is sent`}).option(`maximum-cache-ttl`,{type:`number`,description:`By default, Cloudflare attempts to cache responses for as long as
|
|
5
5
|
indicated by the TTL received from upstream nameservers. This setting
|
|
@@ -28,9 +28,9 @@ responses (e.g., NXDOMAIN) from the upstream servers.
|
|
|
28
28
|
This setting does not affect the TTL value in the DNS response
|
|
29
29
|
Cloudflare returns to clients. Cloudflare will always forward the TTL
|
|
30
30
|
value received from upstream nameservers.
|
|
31
|
-
`}).option(`ratelimit`,{type:`number`,description:`Maximum number of DNS queries per second that will be forwarded to your upstream nameservers. The limit is enforced per server, where each server receives a fraction of the configured value. The actual aggregate rate for a data center may vary depending on how many servers are present. Responses served from cache do not count toward this limit. Set to null to disable rate limiting.`}).option(`retries`,{type:`number`,description:`Number of retries for fetching DNS responses from upstream nameservers (not counting the initial attempt)`,default:2}).option(`upstream-ips`,{type:`string`,array:!0,description:`The upstream_ips field`}).option(`dns-firewall-ip-count`,{type:`number`,description:`Number of IPv4 addresses to assign to the DNS Firewall cluster. Only used during cluster creation and cannot be changed later.`,default:2}).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 m={command:`create`,describe:`Create DNS Firewall Cluster`,builder:p,handler:async f=>s({command:`dns-firewall create`,classification:{safeFlags:[`attack-mitigation-enabled`,`attack-mitigation-only-when-upstream-unhealthy`,`deprecate-any-requests`,`ecs-fallback`,`dry-run`]}},f,async()=>{if(f.dryRun){a({command:`cf dns-firewall create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/dns_firewall`,pathParams:{},bodyKind:`json`,body:f.body===void 0?l({attack_mitigation:{enabled:f[`attack-mitigation-enabled`],only_when_upstream_unhealthy:f[`attack-mitigation-only-when-upstream-unhealthy`]},deprecate_any_requests:f[`deprecate-any-requests`],ecs_fallback:f[`ecs-fallback`],maximum_cache_ttl:f[`maximum-cache-ttl`],minimum_cache_ttl:f[`minimum-cache-ttl`],name:u(f.name,`name`,`text`),negative_cache_ttl:f[`negative-cache-ttl`],ratelimit:f.ratelimit,retries:f.retries,upstream_ips:f[`upstream-ips`],dns_firewall_ip_count:f[`dns-firewall-ip-count`]}):c(f.body)});return}let s=await
|
|
31
|
+
`}).option(`ratelimit`,{type:`number`,description:`Maximum number of DNS queries per second that will be forwarded to your upstream nameservers. The limit is enforced per server, where each server receives a fraction of the configured value. The actual aggregate rate for a data center may vary depending on how many servers are present. Responses served from cache do not count toward this limit. Set to null to disable rate limiting.`}).option(`retries`,{type:`number`,description:`Number of retries for fetching DNS responses from upstream nameservers (not counting the initial attempt)`,default:2}).option(`upstream-ips`,{type:`string`,array:!0,description:`The upstream_ips field`}).option(`dns-firewall-ip-count`,{type:`number`,description:`Number of IPv4 addresses to assign to the DNS Firewall cluster. Only used during cluster creation and cannot be changed later.`,default:2}).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 m={command:`create`,describe:`Create DNS Firewall Cluster`,builder:p,handler:async f=>s({command:`dns-firewall create`,classification:{safeFlags:[`attack-mitigation-enabled`,`attack-mitigation-only-when-upstream-unhealthy`,`deprecate-any-requests`,`ecs-fallback`,`dry-run`]}},f,async()=>{if(f.dryRun){a({command:`cf dns-firewall create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/dns_firewall`,pathParams:{},bodyKind:`json`,body:f.body===void 0?l({attack_mitigation:{enabled:f[`attack-mitigation-enabled`],only_when_upstream_unhealthy:f[`attack-mitigation-only-when-upstream-unhealthy`]},deprecate_any_requests:f[`deprecate-any-requests`],ecs_fallback:f[`ecs-fallback`],maximum_cache_ttl:f[`maximum-cache-ttl`],minimum_cache_ttl:f[`minimum-cache-ttl`],name:u(f.name,`name`,`text`),negative_cache_ttl:f[`negative-cache-ttl`],ratelimit:f.ratelimit,retries:f.retries,upstream_ips:f[`upstream-ips`],dns_firewall_ip_count:f[`dns-firewall-ip-count`]}):c(f.body)});return}let s=await t(f),p=f.local?e:await r();if(f.accountId=p,f.body){let e=c(f.body);i(await o(`Creating`,async()=>s.dnsFirewall.create({...e,account_id:p})),{successLabel:`Created`});return}if(f.name===void 0&&(f.name=await d(`name`,`DNS Firewall cluster name`)),f[`upstream-ips`]===void 0)throw Error(`--upstream-ips is required (or pass --body with this field set).`);let m=l({attack_mitigation:{enabled:f[`attack-mitigation-enabled`],only_when_upstream_unhealthy:f[`attack-mitigation-only-when-upstream-unhealthy`]},deprecate_any_requests:f[`deprecate-any-requests`],ecs_fallback:f[`ecs-fallback`],maximum_cache_ttl:f[`maximum-cache-ttl`],minimum_cache_ttl:f[`minimum-cache-ttl`],name:u(f.name,`name`,`text`),negative_cache_ttl:f[`negative-cache-ttl`],ratelimit:f.ratelimit,retries:f.retries,upstream_ips:f[`upstream-ips`],dns_firewall_ip_count:f[`dns-firewall-ip-count`]});i(await o(`Creating`,async()=>s.dnsFirewall.create({...m,account_id:p})),{successLabel:`Created`})})};function h(e){return e.usage(`$0 dns-firewall delete <dns-firewall-id>
|
|
32
32
|
|
|
33
|
-
Delete a DNS Firewall cluster`).positional(`dns-firewall-id`,{type:`string`,description:`Identifier.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const g={command:`delete <dns-firewall-id>`,describe:`Delete DNS Firewall Cluster`,builder:h,handler:async c=>s({command:`dns-firewall delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},c,async()=>{if(c.dryRun){a({command:`cf dns-firewall delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/dns_firewall/${c[`dns-firewall-id`]==null?`<dns-firewall-id>`:encodeURIComponent(String(c[`dns-firewall-id`]))}`,pathParams:{"dns-firewall-id":String(c[`dns-firewall-id`]??``)},bodyKind:`none`});return}let s=await
|
|
33
|
+
Delete a DNS Firewall cluster`).positional(`dns-firewall-id`,{type:`string`,description:`Identifier.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const g={command:`delete <dns-firewall-id>`,describe:`Delete DNS Firewall Cluster`,builder:h,handler:async c=>s({command:`dns-firewall delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},c,async()=>{if(c.dryRun){a({command:`cf dns-firewall delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/dns_firewall/${c[`dns-firewall-id`]==null?`<dns-firewall-id>`:encodeURIComponent(String(c[`dns-firewall-id`]))}`,pathParams:{"dns-firewall-id":String(c[`dns-firewall-id`]??``)},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();if(c.accountId=l,!await f({force:!!c.force})){process.stderr.write(`Aborted.
|
|
34
34
|
`);return}i(await o(`Deleting`,async()=>s.dnsFirewall.delete({account_id:l,dns_firewall_id:c[`dns-firewall-id`]})),{successLabel:`Deleted`})})};function _(e){return e.usage(`$0 dns-firewall edit <dns-firewall-id>
|
|
35
35
|
|
|
36
36
|
Modify the configuration of a DNS Firewall cluster`).positional(`dns-firewall-id`,{type:`string`,description:`Identifier.`,demandOption:!0}).option(`attack-mitigation-enabled`,{type:`boolean`,description:`When enabled, automatically mitigate random-prefix attacks to protect upstream DNS servers`}).option(`attack-mitigation-only-when-upstream-unhealthy`,{type:`boolean`,description:`Only mitigate attacks when upstream servers seem unhealthy`}).option(`deprecate-any-requests`,{type:`boolean`,description:`Whether to refuse to answer queries for the ANY type`}).option(`ecs-fallback`,{type:`boolean`,description:`Whether to forward client IP (resolver) subnet if no EDNS Client Subnet is sent`}).option(`maximum-cache-ttl`,{type:`number`,description:`By default, Cloudflare attempts to cache responses for as long as
|
|
@@ -60,12 +60,12 @@ responses (e.g., NXDOMAIN) from the upstream servers.
|
|
|
60
60
|
This setting does not affect the TTL value in the DNS response
|
|
61
61
|
Cloudflare returns to clients. Cloudflare will always forward the TTL
|
|
62
62
|
value received from upstream nameservers.
|
|
63
|
-
`}).option(`ratelimit`,{type:`number`,description:`Maximum number of DNS queries per second that will be forwarded to your upstream nameservers. The limit is enforced per server, where each server receives a fraction of the configured value. The actual aggregate rate for a data center may vary depending on how many servers are present. Responses served from cache do not count toward this limit. Set to null to disable rate limiting.`}).option(`retries`,{type:`number`,description:`Number of retries for fetching DNS responses from upstream nameservers (not counting the initial attempt)`}).option(`upstream-ips`,{type:`string`,array:!0,description:`The upstream_ips field`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const v={command:`edit <dns-firewall-id>`,describe:`Update DNS Firewall Cluster`,builder:_,handler:async d=>s({command:`dns-firewall edit`,classification:{safeFlags:[`attack-mitigation-enabled`,`attack-mitigation-only-when-upstream-unhealthy`,`deprecate-any-requests`,`ecs-fallback`,`dry-run`]}},d,async()=>{if(d.dryRun){a({command:`cf dns-firewall edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/dns_firewall/${d[`dns-firewall-id`]==null?`<dns-firewall-id>`:encodeURIComponent(String(d[`dns-firewall-id`]))}`,pathParams:{"dns-firewall-id":String(d[`dns-firewall-id`]??``)},bodyKind:`json`,body:d.body===void 0?l({attack_mitigation:{enabled:d[`attack-mitigation-enabled`],only_when_upstream_unhealthy:d[`attack-mitigation-only-when-upstream-unhealthy`]},deprecate_any_requests:d[`deprecate-any-requests`],ecs_fallback:d[`ecs-fallback`],maximum_cache_ttl:d[`maximum-cache-ttl`],minimum_cache_ttl:d[`minimum-cache-ttl`],name:u(d.name,`name`,`text`),negative_cache_ttl:d[`negative-cache-ttl`],ratelimit:d.ratelimit,retries:d.retries,upstream_ips:d[`upstream-ips`]}):c(d.body)});return}let s=await
|
|
63
|
+
`}).option(`ratelimit`,{type:`number`,description:`Maximum number of DNS queries per second that will be forwarded to your upstream nameservers. The limit is enforced per server, where each server receives a fraction of the configured value. The actual aggregate rate for a data center may vary depending on how many servers are present. Responses served from cache do not count toward this limit. Set to null to disable rate limiting.`}).option(`retries`,{type:`number`,description:`Number of retries for fetching DNS responses from upstream nameservers (not counting the initial attempt)`}).option(`upstream-ips`,{type:`string`,array:!0,description:`The upstream_ips field`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const v={command:`edit <dns-firewall-id>`,describe:`Update DNS Firewall Cluster`,builder:_,handler:async d=>s({command:`dns-firewall edit`,classification:{safeFlags:[`attack-mitigation-enabled`,`attack-mitigation-only-when-upstream-unhealthy`,`deprecate-any-requests`,`ecs-fallback`,`dry-run`]}},d,async()=>{if(d.dryRun){a({command:`cf dns-firewall edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/dns_firewall/${d[`dns-firewall-id`]==null?`<dns-firewall-id>`:encodeURIComponent(String(d[`dns-firewall-id`]))}`,pathParams:{"dns-firewall-id":String(d[`dns-firewall-id`]??``)},bodyKind:`json`,body:d.body===void 0?l({attack_mitigation:{enabled:d[`attack-mitigation-enabled`],only_when_upstream_unhealthy:d[`attack-mitigation-only-when-upstream-unhealthy`]},deprecate_any_requests:d[`deprecate-any-requests`],ecs_fallback:d[`ecs-fallback`],maximum_cache_ttl:d[`maximum-cache-ttl`],minimum_cache_ttl:d[`minimum-cache-ttl`],name:u(d.name,`name`,`text`),negative_cache_ttl:d[`negative-cache-ttl`],ratelimit:d.ratelimit,retries:d.retries,upstream_ips:d[`upstream-ips`]}):c(d.body)});return}let s=await t(d),f=d.local?e:await r();if(d.accountId=f,d.body){let e=c(d.body);i(await o(`Updating`,async()=>s.dnsFirewall.edit({...e,account_id:f,dns_firewall_id:d[`dns-firewall-id`]})),{successLabel:`Updated`});return}let p=l({attack_mitigation:{enabled:d[`attack-mitigation-enabled`],only_when_upstream_unhealthy:d[`attack-mitigation-only-when-upstream-unhealthy`]},deprecate_any_requests:d[`deprecate-any-requests`],ecs_fallback:d[`ecs-fallback`],maximum_cache_ttl:d[`maximum-cache-ttl`],minimum_cache_ttl:d[`minimum-cache-ttl`],name:u(d.name,`name`,`text`),negative_cache_ttl:d[`negative-cache-ttl`],ratelimit:d.ratelimit,retries:d.retries,upstream_ips:d[`upstream-ips`]});i(await o(`Updating`,async()=>s.dnsFirewall.edit({...p,account_id:f,dns_firewall_id:d[`dns-firewall-id`]})),{successLabel:`Updated`})})};function y(e){return e.usage(`$0 dns-firewall get <dns-firewall-id>
|
|
64
64
|
|
|
65
|
-
Show a single DNS Firewall cluster for an account`).positional(`dns-firewall-id`,{type:`string`,description:`Identifier.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const b={command:`get <dns-firewall-id>`,describe:`DNS Firewall Cluster Details`,builder:y,handler:async c=>s({command:`dns-firewall get`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){a({command:`cf dns-firewall get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/dns_firewall/${c[`dns-firewall-id`]==null?`<dns-firewall-id>`:encodeURIComponent(String(c[`dns-firewall-id`]))}`,pathParams:{"dns-firewall-id":String(c[`dns-firewall-id`]??``)},bodyKind:`none`});return}let s=await
|
|
65
|
+
Show a single DNS Firewall cluster for an account`).positional(`dns-firewall-id`,{type:`string`,description:`Identifier.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const b={command:`get <dns-firewall-id>`,describe:`DNS Firewall Cluster Details`,builder:y,handler:async c=>s({command:`dns-firewall get`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){a({command:`cf dns-firewall get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/dns_firewall/${c[`dns-firewall-id`]==null?`<dns-firewall-id>`:encodeURIComponent(String(c[`dns-firewall-id`]))}`,pathParams:{"dns-firewall-id":String(c[`dns-firewall-id`]??``)},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();c.accountId=l,i(await o(`Loading`,async()=>s.dnsFirewall.get({account_id:l,dns_firewall_id:c[`dns-firewall-id`]})),{successLabel:`Loaded`})})};function x(e){return e.usage(`$0 dns-firewall list
|
|
66
66
|
|
|
67
|
-
List DNS Firewall clusters for an account`).option(`page`,{type:`number`,description:`Page number of paginated results`}).option(`per-page`,{type:`number`,description:`Number of clusters per page`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const S={command:`list`,describe:`List DNS Firewall Clusters`,builder:x,handler:async c=>s({command:`dns-firewall list`,classification:{safeFlags:[`dry-run`]}},c,async()=>{let s={page:c.page,per_page:c[`per-page`]};if(c.dryRun){a({command:`cf dns-firewall list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/dns_firewall`,pathParams:{},query:s,bodyKind:`none`});return}let l=await
|
|
67
|
+
List DNS Firewall clusters for an account`).option(`page`,{type:`number`,description:`Page number of paginated results`}).option(`per-page`,{type:`number`,description:`Number of clusters per page`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const S={command:`list`,describe:`List DNS Firewall Clusters`,builder:x,handler:async c=>s({command:`dns-firewall list`,classification:{safeFlags:[`dry-run`]}},c,async()=>{let s={page:c.page,per_page:c[`per-page`]};if(c.dryRun){a({command:`cf dns-firewall list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/dns_firewall`,pathParams:{},query:s,bodyKind:`none`});return}let l=await t(c),u=c.local?e:await r();c.accountId=u,i(await o(`Loading`,async()=>l.dnsFirewall.list({account_id:u,...s})),{successLabel:`Loaded`})})};function C(e){return e.usage(`$0 dns-firewall reverse-dns edit <dns-firewall-id>
|
|
68
68
|
|
|
69
|
-
Update reverse DNS configuration (PTR records) for a DNS Firewall cluster`).positional(`dns-firewall-id`,{type:`string`,description:`Identifier.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const w={command:`edit <dns-firewall-id>`,describe:`Update DNS Firewall Cluster Reverse DNS`,builder:C,handler:async l=>s({command:`dns-firewall reverse-dns edit`,classification:{safeFlags:[`dry-run`]}},l,async()=>{if(l.dryRun){a({command:`cf dns-firewall reverse-dns edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/dns_firewall/${l[`dns-firewall-id`]==null?`<dns-firewall-id>`:encodeURIComponent(String(l[`dns-firewall-id`]))}/reverse_dns`,pathParams:{"dns-firewall-id":String(l[`dns-firewall-id`]??``)},bodyKind:`json`,body:l.body===void 0?void 0:c(l.body)});return}let s=await
|
|
69
|
+
Update reverse DNS configuration (PTR records) for a DNS Firewall cluster`).positional(`dns-firewall-id`,{type:`string`,description:`Identifier.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const w={command:`edit <dns-firewall-id>`,describe:`Update DNS Firewall Cluster Reverse DNS`,builder:C,handler:async l=>s({command:`dns-firewall reverse-dns edit`,classification:{safeFlags:[`dry-run`]}},l,async()=>{if(l.dryRun){a({command:`cf dns-firewall reverse-dns edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/dns_firewall/${l[`dns-firewall-id`]==null?`<dns-firewall-id>`:encodeURIComponent(String(l[`dns-firewall-id`]))}/reverse_dns`,pathParams:{"dns-firewall-id":String(l[`dns-firewall-id`]??``)},bodyKind:`json`,body:l.body===void 0?void 0:c(l.body)});return}let s=await t(l),u=l.local?e:await r();if(l.accountId=u,l.body){let e=c(l.body);i(await o(`Updating`,async()=>s.dnsFirewall.reverseDns.edit({...e,account_id:u,dns_firewall_id:l[`dns-firewall-id`]})),{successLabel:`Updated`});return}i(await o(`Updating`,async()=>s.dnsFirewall.reverseDns.edit({account_id:u,dns_firewall_id:l[`dns-firewall-id`]})),{successLabel:`Updated`})})};function T(e){return e.usage(`$0 dns-firewall reverse-dns get <dns-firewall-id>
|
|
70
70
|
|
|
71
|
-
Show reverse DNS configuration (PTR records) for a DNS Firewall cluster`).positional(`dns-firewall-id`,{type:`string`,description:`Identifier.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const E={command:`get <dns-firewall-id>`,describe:`Show DNS Firewall Cluster Reverse DNS`,builder:T,handler:async c=>s({command:`dns-firewall reverse-dns get`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){a({command:`cf dns-firewall reverse-dns get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/dns_firewall/${c[`dns-firewall-id`]==null?`<dns-firewall-id>`:encodeURIComponent(String(c[`dns-firewall-id`]))}/reverse_dns`,pathParams:{"dns-firewall-id":String(c[`dns-firewall-id`]??``)},bodyKind:`none`});return}let s=await
|
|
71
|
+
Show reverse DNS configuration (PTR records) for a DNS Firewall cluster`).positional(`dns-firewall-id`,{type:`string`,description:`Identifier.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const E={command:`get <dns-firewall-id>`,describe:`Show DNS Firewall Cluster Reverse DNS`,builder:T,handler:async c=>s({command:`dns-firewall reverse-dns get`,classification:{safeFlags:[`dry-run`]}},c,async()=>{if(c.dryRun){a({command:`cf dns-firewall reverse-dns get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/dns_firewall/${c[`dns-firewall-id`]==null?`<dns-firewall-id>`:encodeURIComponent(String(c[`dns-firewall-id`]))}/reverse_dns`,pathParams:{"dns-firewall-id":String(c[`dns-firewall-id`]??``)},bodyKind:`none`});return}let s=await t(c),l=c.local?e:await r();c.accountId=l,i(await o(`Loading`,async()=>s.dnsFirewall.reverseDns.get({account_id:l,dns_firewall_id:c[`dns-firewall-id`]})),{successLabel:`Loaded`})})},D={command:`reverse-dns`,describe:`Operations for reverse-dns`,builder:e=>e.command(w).command(E).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},O={command:`dns-firewall`,describe:`dns-firewall`,builder:e=>e.command(m).command(g).command(v).command(b).command(S).command(D).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{O as default};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import{i as e}from"./chunk-WMOON6TZ-B8xCqjB1.mjs";import{createRequire as t}from"node:module";t(import.meta.url||(typeof __filename==`string`?__filename:`/`));var n=e(e=>{let t=typeof e;return e!==null&&(t===`object`||t===`function`)},`isObject`),r=e(e=>n(e)&&Object.keys(e).length===0,`isEmptyObject`),i=new Set([`__proto__`,`prototype`,`constructor`]),a=new Set(`0123456789`);function o(e){let t=[],n=``,r=`start`,o=!1;for(let s of e)switch(s){case`\\`:if(r===`index`)throw Error(`Invalid character in an index`);if(r===`indexEnd`)throw Error(`Invalid character after an index`);o&&(n+=s),r=`property`,o=!o;break;case`.`:if(r===`index`)throw Error(`Invalid character in an index`);if(r===`indexEnd`){r=`property`;break}if(o){o=!1,n+=s;break}if(i.has(n))return[];t.push(n),n=``,r=`property`;break;case`[`:if(r===`index`)throw Error(`Invalid character in an index`);if(r===`indexEnd`){r=`index`;break}if(o){o=!1,n+=s;break}if(r===`property`){if(i.has(n))return[];t.push(n),n=``}r=`index`;break;case`]`:if(r===`index`){t.push(Number.parseInt(n,10)),n=``,r=`indexEnd`;break}if(r===`indexEnd`)throw Error(`Invalid character after an index`);default:if(r===`index`&&!a.has(s))throw Error(`Invalid character in an index`);if(r===`indexEnd`)throw Error(`Invalid character after an index`);r===`start`&&(r=`property`),o&&(o=!1,n+=`\\`),n+=s}switch(o&&(n+=`\\`),r){case`property`:if(i.has(n))return[];t.push(n);break;case`index`:throw Error(`Index was not closed`);case`start`:t.push(``);break}return t}e(o,`getPathSegments`);function s(e,t){if(typeof t!=`number`&&Array.isArray(e)){let n=Number.parseInt(t,10);return Number.isInteger(n)&&e[n]===e[t]}return!1}e(s,`isStringIndex`);function c(e,t){if(s(e,t))throw Error(`Cannot use string index`)}e(c,`assertNotStringIndex`);function l(e,t,r){if(!n(e)||typeof t!=`string`)return r===void 0?e:r;let i=o(t);if(i.length===0)return r;for(let t=0;t<i.length;t++){let n=i[t];if(e=s(e,n)?t===i.length-1?void 0:null:e[n],e==null){if(t!==i.length-1)return r;break}}return e===void 0?r:e}e(l,`getProperty`);function u(e,t,r){if(!n(e)||typeof t!=`string`)return e;let i=e,a=o(t);for(let t=0;t<a.length;t++){let i=a[t];c(e,i),t===a.length-1?e[i]=r:n(e[i])||(e[i]=typeof a[t+1]==`number`?[]:{}),e=e[i]}return i}e(u,`setProperty`);function d(e,t){if(!n(e)||typeof t!=`string`)return!1;let r=o(t);for(let t=0;t<r.length;t++){let i=r[t];if(c(e,i),t===r.length-1)return delete e[i],!0;if(e=e[i],!n(e))return!1}}e(d,`deleteProperty`);function f(e,t){if(!n(e)||typeof t!=`string`)return!1;let r=o(t);if(r.length===0)return!1;for(let t of r){if(!n(e)||!(t in e)||s(e,t))return!1;e=e[t]}return!0}e(f,`hasProperty`);function p(e){if(typeof e!=`string`)throw TypeError(`Expected a string`);return e.replaceAll(/[\\.[]/g,`\\$&`)}e(p,`escapePath`);function m(e){let t=Object.entries(e);return Array.isArray(e)?t.map(([e,t])=>[Number(e),t]):t}e(m,`entries`);function h(e){let t=``;for(let[n,r]of m(e))typeof r==`number`?t+=`[${r}]`:(r=p(r),t+=n===0?r:`.${r}`);return t}e(h,`stringifyPath`);function*g(e,t=[]){if(!n(e)||r(e)){t.length>0&&(yield h(t));return}for(let[n,r]of m(e))yield*g(r,[...t,n])}e(g,`deepKeysIterator`);function _(e){return[...g(e)]}e(_,`deepKeys`);export{l as getProperty};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import{n as e,r as t}from"./source-38bULAR8.mjs";import{a as n,r,t as i}from"./chunk-U6NEESU5-BhF4rnpx.mjs";import{createRequire as a}from"node:module";import*as o from"node:path";import*as s from"node:fs/promises";var c=e(((e,t)=>{t.exports={name:`dotenv`,version:`16.3.1`,description:`Loads environment variables from .env file`,main:`lib/main.js`,types:`lib/main.d.ts`,exports:{".":{types:`./lib/main.d.ts`,require:`./lib/main.js`,default:`./lib/main.js`},"./config":`./config.js`,"./config.js":`./config.js`,"./lib/env-options":`./lib/env-options.js`,"./lib/env-options.js":`./lib/env-options.js`,"./lib/cli-options":`./lib/cli-options.js`,"./lib/cli-options.js":`./lib/cli-options.js`,"./package.json":`./package.json`},scripts:{"dts-check":`tsc --project tests/types/tsconfig.json`,lint:`standard`,"lint-readme":`standard-markdown`,pretest:`npm run lint && npm run dts-check`,test:`tap tests/*.js --100 -Rspec`,prerelease:`npm test`,release:`standard-version`},repository:{type:`git`,url:`git://github.com/motdotla/dotenv.git`},funding:`https://github.com/motdotla/dotenv?sponsor=1`,keywords:[`dotenv`,`env`,`.env`,`environment`,`variables`,`config`,`settings`],readmeFilename:`README.md`,license:`BSD-2-Clause`,devDependencies:{"@definitelytyped/dtslint":`^0.0.133`,"@types/node":`^18.11.3`,decache:`^4.6.1`,sinon:`^14.0.1`,standard:`^17.0.0`,"standard-markdown":`^7.1.0`,"standard-version":`^9.5.0`,tap:`^16.3.0`,tar:`^6.1.11`,typescript:`^4.8.4`},engines:{node:`>=12`},browser:{fs:!1}}})),l=e(((e,n)=>{let r=t(`fs`),i=t(`path`),a=t(`os`),o=t(`crypto`),s=c().version,l=/(?:^|^)\s*(?:export\s+)?([\w.-]+)(?:\s*=\s*?|:\s+?)(\s*'(?:\\'|[^'])*'|\s*"(?:\\"|[^"])*"|\s*`(?:\\`|[^`])*`|[^#\r\n]+)?\s*(?:#.*)?(?:$|$)/gm;function u(e){let t={},n=e.toString();n=n.replace(/\r\n?/gm,`
|
|
3
|
+
`);let r;for(;(r=l.exec(n))!=null;){let e=r[1],n=r[2]||``;n=n.trim();let i=n[0];n=n.replace(/^(['"`])([\s\S]*)\1$/gm,`$2`),i===`"`&&(n=n.replace(/\\n/g,`
|
|
4
|
+
`),n=n.replace(/\\r/g,`\r`)),t[e]=n}return t}function d(e){let t=_(e),n=w.configDotenv({path:t});if(!n.parsed)throw Error(`MISSING_DATA: Cannot parse ${t} for an unknown reason`);let r=h(e).split(`,`),i=r.length,a;for(let e=0;e<i;e++)try{let t=g(n,r[e].trim());a=w.decrypt(t.ciphertext,t.key);break}catch(t){if(e+1>=i)throw t}return w.parse(a)}function f(e){console.log(`[dotenv@${s}][INFO] ${e}`)}function p(e){console.log(`[dotenv@${s}][WARN] ${e}`)}function m(e){console.log(`[dotenv@${s}][DEBUG] ${e}`)}function h(e){return e&&e.DOTENV_KEY&&e.DOTENV_KEY.length>0?e.DOTENV_KEY:process.env.DOTENV_KEY&&process.env.DOTENV_KEY.length>0?process.env.DOTENV_KEY:``}function g(e,t){let n;try{n=new URL(t)}catch(e){throw e.code===`ERR_INVALID_URL`?Error(`INVALID_DOTENV_KEY: Wrong format. Must be in valid uri format like dotenv://:key_1234@dotenv.org/vault/.env.vault?environment=development`):e}let r=n.password;if(!r)throw Error(`INVALID_DOTENV_KEY: Missing key part`);let i=n.searchParams.get(`environment`);if(!i)throw Error(`INVALID_DOTENV_KEY: Missing environment part`);let a=`DOTENV_VAULT_${i.toUpperCase()}`,o=e.parsed[a];if(!o)throw Error(`NOT_FOUND_DOTENV_ENVIRONMENT: Cannot locate environment ${a} in your .env.vault file.`);return{ciphertext:o,key:r}}function _(e){let t=i.resolve(process.cwd(),`.env`);return e&&e.path&&e.path.length>0&&(t=e.path),t.endsWith(`.vault`)?t:`${t}.vault`}function v(e){return e[0]===`~`?i.join(a.homedir(),e.slice(1)):e}function y(e){f(`Loading env from encrypted .env.vault`);let t=w._parseVault(e),n=process.env;return e&&e.processEnv!=null&&(n=e.processEnv),w.populate(n,t,e),{parsed:t}}function b(e){let t=i.resolve(process.cwd(),`.env`),n=`utf8`,a=!!(e&&e.debug);e&&(e.path!=null&&(t=v(e.path)),e.encoding!=null&&(n=e.encoding));try{let i=w.parse(r.readFileSync(t,{encoding:n})),a=process.env;return e&&e.processEnv!=null&&(a=e.processEnv),w.populate(a,i,e),{parsed:i}}catch(e){return a&&m(`Failed to load ${t} ${e.message}`),{error:e}}}function x(e){let t=_(e);return h(e).length===0?w.configDotenv(e):r.existsSync(t)?w._configVault(e):(p(`You set DOTENV_KEY but you are missing a .env.vault file at ${t}. Did you forget to build it?`),w.configDotenv(e))}function S(e,t){let n=Buffer.from(t.slice(-64),`hex`),r=Buffer.from(e,`base64`),i=r.slice(0,12),a=r.slice(-16);r=r.slice(12,-16);try{let e=o.createDecipheriv(`aes-256-gcm`,n,i);return e.setAuthTag(a),`${e.update(r)}${e.final()}`}catch(e){let t=e instanceof RangeError,n=e.message===`Invalid key length`,r=e.message===`Unsupported state or unable to authenticate data`;throw t||n?Error(`INVALID_DOTENV_KEY: It must be 64 characters long (or more)`):r?Error(`DECRYPTION_FAILED: Please check your DOTENV_KEY`):(console.error(`Error: `,e.code),console.error(`Error: `,e.message),e)}}function C(e,t,n={}){let r=!!(n&&n.debug),i=!!(n&&n.override);if(typeof t!=`object`)throw Error(`OBJECT_REQUIRED: Please check the processEnv argument being passed to populate`);for(let n of Object.keys(t))Object.prototype.hasOwnProperty.call(e,n)?(i===!0&&(e[n]=t[n]),r&&m(i===!0?`"${n}" is already defined and WAS overwritten`:`"${n}" is already defined and was NOT overwritten`)):e[n]=t[n]}let w={configDotenv:b,_configVault:y,_parseVault:d,config:x,decrypt:S,parse:u,populate:C};n.exports.configDotenv=w.configDotenv,n.exports._configVault=w._configVault,n.exports._parseVault=w._parseVault,n.exports.config=w.config,n.exports.decrypt=w.decrypt,n.exports.parse=w.parse,n.exports.populate=w.populate,n.exports=w})),u=l();a(import.meta.url||(typeof __filename==`string`?__filename:`/`));var d=n(i({"../../node_modules/.pnpm/dotenv-expand@13.0.0/node_modules/dotenv-expand/lib/main.js"(e,t){function n(e){return e.replace(/\\\$/g,`$`)}r(n,`_resolveEscapeSequences`);function i(e,t,n){let r={...n,...t},i=/(?<!\\)\${([^{}]+)}|(?<!\\)\$([A-Za-z_][A-Za-z0-9_]*)/g,a=e,o,s=new Set;for(;(o=i.exec(a))!==null;){s.add(a);let[e,t,c]=o,l=t||c,u=l.match(/(:\+|\+|:-|-)/),d=u?u[0]:null,f=l.split(d),p,m,h=f.shift();if([`:+`,`+`].includes(d)?(p=r[h]?f.join(d):``,m=null):(p=f.join(d),m=r[h]),a=m?s.has(m)?a.replace(e,p):a.replace(e,m):a.replace(e,p),a===n[h])break;i.lastIndex=0}return a}r(i,`expandValue`);function a(e){let t={},r=process.env;e&&e.processEnv!=null&&(r=e.processEnv);for(let a in e.parsed){let o=e.parsed[a];o=r[a]&&r[a]!==o?r[a]:i(o,r,t),e.parsed[a]=n(o),t[a]=n(o)}for(let t in e.parsed)r[t]=e.parsed[t];return e}r(a,`expand`),t.exports.expand=a}})());function f(e,t){return e===!1?[]:[`.env`,`.env.local`,...t===void 0?[]:[`.env.${t}`,`.env.${t}.local`]].map(t=>o.resolve(e,t))}r(f,`getEnvPaths`);function p(e,t){return e===!1?[]:[...t===void 0?[]:[`.dev.vars.${t}`],`.dev.vars`].map(t=>o.resolve(e,t))}r(p,`getDevVarsCandidatePaths`);async function m(e,t){if(t===`local`)throw Error(`"local" cannot be used as a mode name because it conflicts with the .local postfix for .env files.`);let n=f(e,t),r={},i={};for(let e of n){let t=await g(e,u.parse);if(t!==void 0)for(let[e,n]of Object.entries(t.values))r[e]=n,i[e]={type:`file`,path:t.path}}let a=v();(0,d.expand)({parsed:r,processEnv:{...a}});let o={...r},s={...i};for(let[e,t]of Object.entries(a))o[e]=t,s[e]={type:`process`};return{values:o,sources:s}}r(m,`loadEnv`);async function h(e,t){let n=p(e,t);for(let e of n){let t=await g(e,u.parse);if(t!==void 0)return t.values}}r(h,`loadDevVars`);async function g(e,t){try{let n=await s.stat(e);return!n.isFile()&&!n.isFIFO()?void 0:{path:e,values:t(await s.readFile(e,`utf8`))}}catch(e){if(_(e))return;throw e}}r(g,`tryParseFile`);function _(e){return e instanceof Error&&`code`in e&&(e.code===`ENOENT`||e.code===`ENOTDIR`)}r(_,`isMissingFileError`);function v(){return Object.fromEntries(Object.entries(process.env).filter(e=>e[1]!==void 0))}r(v,`copyProcessEnv`);const y=new Set([`CLOUDFLARE_ACCESS_CLIENT_ID`,`CLOUDFLARE_ACCESS_CLIENT_SECRET`,`CLOUDFLARE_ACCOUNT_ID`,`CLOUDFLARE_API_TOKEN`,`CLOUDFLARE_COMPLIANCE_REGION`,`CLOUDFLARE_ZONE_ID`,`WRANGLER_API_ENVIRONMENT`]);function b(e){return y.has(e)}async function x(e={}){if(e.local)return()=>{};let t=await m(process.cwd(),e.mode),n=[];for(let[e,r]of Object.entries(t.values))!b(e)||t.sources[e]?.type!==`file`||(process.env[e]=r,n.push(e));return()=>{for(let e of n)delete process.env[e]}}async function S(e,t){let n=await x(e);try{return await t()}finally{n()}}const C=new Set(`access curl.access login.access rdp.access smb.access ssh.access ssh-config.access ssh-gen.access tcp.access token.build.dev.init.init workers.migrate.tunnels diag.tunnels login.tunnels quick-start.tunnels ready.tunnels tail.workers check.workers types.deploy.previews deploy.tunnels run.workers triggers deploy.workers versions create`.split(`.`));function w(e,t){return!t&&!C.has(e)}export{l as i,w as n,S as r,x as t};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import{t as e}from"./local-rYpzEQb-.mjs";import{n as t}from"./auth-Br-t8vL_.mjs";import{a as n,t as r}from"./context-CquYYyS3.mjs";import{t as i}from"./output-ClYel9WX.mjs";import{t as a}from"./dry-run-p9Q7nMZ5.mjs";import{t as o}from"./progress-TLUEIYE6.mjs";import{t as s}from"./run-iFM5TxtQ.mjs";import"./telemetry-DoBQOGRk.mjs";function c(e){return e.usage(`$0 durable-objects namespaces list
|
|
3
|
+
|
|
4
|
+
Returns the Durable Object namespaces owned by an account.`).option(`page`,{type:`number`,description:`Current page.`}).option(`per-page`,{type:`number`,description:`Items per-page.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const l={command:`list`,describe:`List Durable Object Namespaces`,builder:c,handler:async c=>s({command:`durable-objects namespaces list`,classification:{safeFlags:[`dry-run`]}},c,async()=>{let s={page:c.page,per_page:c[`per-page`]};if(c.dryRun){a({command:`cf durable-objects namespaces list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/workers/durable_objects/namespaces`,pathParams:{},query:s,bodyKind:`none`});return}let l=await t(c),u=c.local?e:await r();c.accountId=u,i(await o(`Loading`,async()=>l.durableObjects.namespaces.list({account_id:u,...s})),{successLabel:`Loaded`})})};function u(e){return e.usage(`$0 durable-objects namespaces objects list
|
|
5
|
+
|
|
6
|
+
Returns the Durable Objects in a given Durable Object namespace.`).option(`id`,{type:`string`,description:`ID of the namespace.`,demandOption:!0}).option(`limit`,{type:`number`,description:`The number of objects to return. The cursor attribute may be used to iterate over the next batch of objects if there are more than the limit.`}).option(`cursor`,{type:`string`,description:`Opaque token indicating the position from which to continue when requesting the next set of records. A valid value for the cursor can be obtained from the cursors object in the result_info structure.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const d={command:`list`,describe:`List Objects in a Durable Object namespace`,builder:u,handler:async c=>s({command:`durable-objects namespaces objects list`,classification:{safeFlags:[`dry-run`]}},c,async()=>{let s={limit:c.limit,cursor:c.cursor};if(c.dryRun){a({command:`cf durable-objects namespaces objects list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/workers/durable_objects/namespaces/${c.id==null?`<id>`:encodeURIComponent(String(c.id))}/objects`,pathParams:{id:String(c.id??``)},query:s,bodyKind:`none`});return}let l=await t(c),u=c.local?e:await r();c.accountId=u,i(await o(`Loading`,async()=>l.durableObjects.namespaces.objects.list({account_id:u,id:c.id,...s})),{successLabel:`Loaded`})})},f={command:`objects`,describe:`Operations for namespaces.objects`,builder:e=>e.command(d).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},p={command:`namespaces`,describe:`Operations for namespaces`,builder:e=>e.command(l).command(f).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},m={command:`durable-objects`,describe:`durable-objects`,builder:e=>e.command(p).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{m as default};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{
|
|
2
|
+
import{n as e}from"./auth-Br-t8vL_.mjs";import{i as t}from"./context-CquYYyS3.mjs";import{t as n}from"./output-ClYel9WX.mjs";import{t as r}from"./dry-run-p9Q7nMZ5.mjs";import{t as i}from"./progress-TLUEIYE6.mjs";import{t as a}from"./run-iFM5TxtQ.mjs";import"./telemetry-DoBQOGRk.mjs";import{n as o,t as s}from"./body-parser-NjzJZMOV.mjs";function c(e){return e.usage("$0 email-auth dmarc-reports edit\n\nUpdates the DMARC report configuration for a zone. At least one of `enabled` or `skip_wizard` must be provided. When enabling, the handler will ensure the DMARC RUA record exists in DNS.").option(`enabled`,{type:`boolean`,description:`Enable or disable DMARC reports for this zone`}).option(`skip-wizard`,{type:`boolean`,description:`Skip the DMARC setup wizard`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Request body for PATCH /dmarc-reports`})}const l={command:`edit`,describe:`Configure DMARC Reports`,builder:c,handler:async c=>a({command:`email-auth dmarc-reports edit`,classification:{safeFlags:[`enabled`,`skip-wizard`,`dry-run`]}},c,async()=>{if(c.dryRun){r({command:`cf email-auth dmarc-reports edit`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/zones/${c.zone??c.zoneId??`<zone>`}/email/auth/dmarc-reports`,pathParams:{"zone-id":String(c.zone??c[`zone-id`]??``)},bodyKind:`json`,body:c.body===void 0?s({enabled:c.enabled,skip_wizard:c[`skip-wizard`]}):o(c.body)});return}let a=await e(c),l=await t({zone:c.zone},a,{quiet:c.quiet});if(c.zoneId=l,c.body){let e=o(c.body);n(await i(`Updating`,async()=>a.emailAuth.dmarcReports.edit({...e,zone_id:l})),{successLabel:`Updated`});return}let u=s({enabled:c.enabled,skip_wizard:c[`skip-wizard`]});n(await i(`Updating`,async()=>a.emailAuth.dmarcReports.edit({...u,zone_id:l})),{successLabel:`Updated`})})};function u(e){return e.usage(`$0 email-auth dmarc-reports get
|
|
3
3
|
|
|
4
|
-
Retrieves the current DMARC report configuration and status for a zone. Returns the RUA prefix, enabled status, approved sources, and DNS records.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const d={command:`get`,describe:`Get DMARC Report Status`,builder:u,handler:async o=>a({command:`email-auth dmarc-reports get`,classification:{safeFlags:[`dry-run`]}},o,async()=>{if(o.dryRun){r({command:`cf email-auth dmarc-reports get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${o.zone??o.zoneId??`<zone>`}/email/auth/dmarc-reports`,pathParams:{"zone-id":String(o.zone??o[`zone-id`]??``)},bodyKind:`none`});return}let a=await
|
|
4
|
+
Retrieves the current DMARC report configuration and status for a zone. Returns the RUA prefix, enabled status, approved sources, and DNS records.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const d={command:`get`,describe:`Get DMARC Report Status`,builder:u,handler:async o=>a({command:`email-auth dmarc-reports get`,classification:{safeFlags:[`dry-run`]}},o,async()=>{if(o.dryRun){r({command:`cf email-auth dmarc-reports get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${o.zone??o.zoneId??`<zone>`}/email/auth/dmarc-reports`,pathParams:{"zone-id":String(o.zone??o[`zone-id`]??``)},bodyKind:`none`});return}let a=await e(o),s=await t({zone:o.zone},a,{quiet:o.quiet});o.zoneId=s,n(await i(`Loading`,async()=>a.emailAuth.dmarcReports.get({zone_id:s})),{successLabel:`Loaded`})})},f={command:`dmarc-reports`,describe:`Operations for dmarc-reports`,builder:e=>e.command(l).command(d).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function p(e){return e.usage(`$0 email-auth spf inspect
|
|
5
5
|
|
|
6
|
-
Inspects a specific SPF TXT record and returns a parsed tree structure in the spflimit-worker format. The record ID must be provided via the \`id\` query parameter. Returns a recursive tree showing: - Parsed components with their qualifiers and types - Nested includes recursively resolved within components - Per-component and total lookup counts - Detailed error information with context`).option(`id`,{type:`string`,description:`DNS record ID (rec_tag) to inspect`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const m={command:`inspect`,describe:`Inspect SPF Record`,builder:p,handler:async o=>a({command:`email-auth spf inspect`,classification:{safeFlags:[`dry-run`]}},o,async()=>{let a={id:o.id};if(o.dryRun){r({command:`cf email-auth spf inspect`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${o.zone??o.zoneId??`<zone>`}/email/auth/spf/inspect`,pathParams:{"zone-id":String(o.zone??o[`zone-id`]??``)},query:a,bodyKind:`none`});return}let s=await
|
|
6
|
+
Inspects a specific SPF TXT record and returns a parsed tree structure in the spflimit-worker format. The record ID must be provided via the \`id\` query parameter. Returns a recursive tree showing: - Parsed components with their qualifiers and types - Nested includes recursively resolved within components - Per-component and total lookup counts - Detailed error information with context`).option(`id`,{type:`string`,description:`DNS record ID (rec_tag) to inspect`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const m={command:`inspect`,describe:`Inspect SPF Record`,builder:p,handler:async o=>a({command:`email-auth spf inspect`,classification:{safeFlags:[`dry-run`]}},o,async()=>{let a={id:o.id};if(o.dryRun){r({command:`cf email-auth spf inspect`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${o.zone??o.zoneId??`<zone>`}/email/auth/spf/inspect`,pathParams:{"zone-id":String(o.zone??o[`zone-id`]??``)},query:a,bodyKind:`none`});return}let s=await e(o),c=await t({zone:o.zone},s,{quiet:o.quiet});o.zoneId=c,n(await i(`Loading`,async()=>s.emailAuth.spf.inspect({zone_id:c,...a})),{successLabel:`Loaded`})})},h={command:`spf`,describe:`Operations for spf`,builder:e=>e.command(m).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},g={command:`email-auth`,describe:`email-auth`,builder:e=>e.command(f).command(h).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{g as default};
|
|
@@ -1,45 +1,45 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{t as e}from"./local-
|
|
2
|
+
import{t as e}from"./local-rYpzEQb-.mjs";import{n as t}from"./auth-Br-t8vL_.mjs";import{a as n,i as r,t as i}from"./context-CquYYyS3.mjs";import{t as a}from"./output-ClYel9WX.mjs";import{t as o}from"./dry-run-p9Q7nMZ5.mjs";import{t as s}from"./progress-TLUEIYE6.mjs";import{t as c}from"./run-iFM5TxtQ.mjs";import"./telemetry-DoBQOGRk.mjs";import{n as l,r as u,t as d}from"./body-parser-NjzJZMOV.mjs";import{n as f}from"./input-validation-0CeePPHp.mjs";import{a as p,i as m,n as h}from"./prompt-Ck_1PCHm.mjs";import{t as g}from"./cli-types-_Kmwfpnp.mjs";function _(e){return e.usage(`$0 email-routing addresses create
|
|
3
3
|
|
|
4
|
-
Create a destination address to forward your emails to. Destination addresses need to be verified before they can be used.`).option(`email`,{type:`string`,description:`The contact email address of the user.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const v={command:`create`,describe:`Create a destination address`,builder:_,handler:async
|
|
4
|
+
Create a destination address to forward your emails to. Destination addresses need to be verified before they can be used.`).option(`email`,{type:`string`,description:`The contact email address of the user.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const v={command:`create`,describe:`Create a destination address`,builder:_,handler:async r=>c({command:`email-routing addresses create`,classification:{safeFlags:[`dry-run`]}},r,async()=>{if(r.dryRun){o({command:`cf email-routing addresses create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/email/routing/addresses`,pathParams:{},bodyKind:`json`,body:r.body===void 0?d({email:f(r.email,`email`,`text`)}):l(r.body)});return}let c=await t(r),u=r.local?e:await i();if(r.accountId=u,r.body){let e=l(r.body);a(await s(`Creating`,async()=>c.emailRouting.addresses.create({...e,account_id:u})),{successLabel:`Created`});return}r.email===void 0&&(r.email=await p(`email`,`The contact email address of the user.`));let m=d({email:f(r.email,`email`,`text`)});a(await s(`Creating`,async()=>c.emailRouting.addresses.create({...m,account_id:u})),{successLabel:`Created`})})};function y(e){return e.usage(`$0 email-routing addresses delete <destination-address-identifier>
|
|
5
5
|
|
|
6
|
-
Deletes a specific destination address.`).positional(`destination-address-identifier`,{type:`string`,description:`Destination address identifier.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const b={command:`delete <destination-address-identifier>`,describe:`Delete destination address`,builder:y,handler:async
|
|
7
|
-
`);return}a(await s(`Deleting`,async()=>c.emailRouting.addresses.delete({account_id:l,destination_address_identifier:
|
|
6
|
+
Deletes a specific destination address.`).positional(`destination-address-identifier`,{type:`string`,description:`Destination address identifier.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const b={command:`delete <destination-address-identifier>`,describe:`Delete destination address`,builder:y,handler:async r=>c({command:`email-routing addresses delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},r,async()=>{if(r.dryRun){o({command:`cf email-routing addresses delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/email/routing/addresses/${r[`destination-address-identifier`]==null?`<destination-address-identifier>`:encodeURIComponent(String(r[`destination-address-identifier`]))}`,pathParams:{"destination-address-identifier":String(r[`destination-address-identifier`]??``)},bodyKind:`none`});return}let c=await t(r),l=r.local?e:await i();if(r.accountId=l,!await h({force:!!r.force,message:`This operation permanently deletes a destination address.`})){process.stderr.write(`Aborted.
|
|
7
|
+
`);return}a(await s(`Deleting`,async()=>c.emailRouting.addresses.delete({account_id:l,destination_address_identifier:r[`destination-address-identifier`]})),{successLabel:`Deleted`})})};function x(e){return e.usage(`$0 email-routing addresses get <destination-address-identifier>
|
|
8
8
|
|
|
9
|
-
Gets information for a specific destination email already created.`).positional(`destination-address-identifier`,{type:`string`,description:`Destination address identifier.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const S={command:`get <destination-address-identifier>`,describe:`Get a destination address`,builder:x,handler:async
|
|
9
|
+
Gets information for a specific destination email already created.`).positional(`destination-address-identifier`,{type:`string`,description:`Destination address identifier.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const S={command:`get <destination-address-identifier>`,describe:`Get a destination address`,builder:x,handler:async r=>c({command:`email-routing addresses get`,classification:{safeFlags:[`dry-run`]}},r,async()=>{if(r.dryRun){o({command:`cf email-routing addresses get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/email/routing/addresses/${r[`destination-address-identifier`]==null?`<destination-address-identifier>`:encodeURIComponent(String(r[`destination-address-identifier`]))}`,pathParams:{"destination-address-identifier":String(r[`destination-address-identifier`]??``)},bodyKind:`none`});return}let c=await t(r),l=r.local?e:await i();r.accountId=l,a(await s(`Loading`,async()=>c.emailRouting.addresses.get({account_id:l,destination_address_identifier:r[`destination-address-identifier`]})),{successLabel:`Loaded`})})};function C(e){return e.usage(`$0 email-routing addresses list
|
|
10
10
|
|
|
11
|
-
Lists destination addresses configured for Email Routing in an account.`).option(`page`,{type:`number`,description:`Page number of paginated results.`}).option(`per-page`,{type:`number`,description:`Maximum number of results per page.`}).option(`direction`,{type:`string`,description:`Sorts results in an ascending or descending order.`,choices:[`asc`,`desc`]}).option(`verified`,{type:`string`,description:`Filter by verified destination addresses.`,choices:[`true`,`false`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const w={command:`list`,describe:`List destination addresses`,builder:g(C),handler:async
|
|
11
|
+
Lists destination addresses configured for Email Routing in an account.`).option(`page`,{type:`number`,description:`Page number of paginated results.`}).option(`per-page`,{type:`number`,description:`Maximum number of results per page.`}).option(`direction`,{type:`string`,description:`Sorts results in an ascending or descending order.`,choices:[`asc`,`desc`]}).option(`verified`,{type:`string`,description:`Filter by verified destination addresses.`,choices:[`true`,`false`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const w={command:`list`,describe:`List destination addresses`,builder:g(C),handler:async r=>c({command:`email-routing addresses list`,classification:{safeFlags:[`direction`,`verified`,`dry-run`]}},r,async()=>{let c={page:r.page,per_page:r[`per-page`],direction:r.direction,verified:r.verified};if(r.dryRun){o({command:`cf email-routing addresses list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/email/routing/addresses`,pathParams:{},query:c,bodyKind:`none`});return}let l=await t(r),u=r.local?e:await i();r.accountId=u,a(await s(`Loading`,async()=>l.emailRouting.addresses.list({account_id:u,...c})),{successLabel:`Loaded`})})};function T(e){return e.usage(`$0 email-routing addresses update <destination-address-identifier>
|
|
12
12
|
|
|
13
|
-
Updates the status of a specific destination address.`).positional(`destination-address-identifier`,{type:`string`,description:`Destination address identifier.`,demandOption:!0}).option(`status`,{type:`string`,description:`Destination address status. Non-admin callers may only set verified addresses back to unverified; setting to verified requires admin privileges.`,choices:[`unverified`,`verified`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const E={command:`update <destination-address-identifier>`,describe:`Update destination address`,builder:T,handler:async
|
|
13
|
+
Updates the status of a specific destination address.`).positional(`destination-address-identifier`,{type:`string`,description:`Destination address identifier.`,demandOption:!0}).option(`status`,{type:`string`,description:`Destination address status. Non-admin callers may only set verified addresses back to unverified; setting to verified requires admin privileges.`,choices:[`unverified`,`verified`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const E={command:`update <destination-address-identifier>`,describe:`Update destination address`,builder:T,handler:async r=>c({command:`email-routing addresses update`,classification:{safeFlags:[`status`,`dry-run`]}},r,async()=>{if(r.dryRun){o({command:`cf email-routing addresses update`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/email/routing/addresses/${r[`destination-address-identifier`]==null?`<destination-address-identifier>`:encodeURIComponent(String(r[`destination-address-identifier`]))}`,pathParams:{"destination-address-identifier":String(r[`destination-address-identifier`]??``)},bodyKind:`json`,body:r.body===void 0?d({status:f(r.status,`status`,`text`)}):l(r.body)});return}let c=await t(r),u=r.local?e:await i();if(r.accountId=u,r.body){let e=l(r.body);a(await s(`Updating`,async()=>c.emailRouting.addresses.update({...e,account_id:u,destination_address_identifier:r[`destination-address-identifier`]})),{successLabel:`Updated`});return}r.status===void 0&&(r.status=await m(`status`,`Destination address status. Non-admin callers may only set verified addresses back to unverified; setting to verified requires admin privileges.`,[`unverified`,`verified`]));let p=d({status:f(r.status,`status`,`text`)});a(await s(`Updating`,async()=>c.emailRouting.addresses.update({...p,account_id:u,destination_address_identifier:r[`destination-address-identifier`]})),{successLabel:`Updated`})})},D={command:`addresses`,describe:`Verified destination email addresses that can receive forwarded mail`,builder:e=>e.command(v).command(b).command(S).command(w).command(E).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function O(e){return e.usage(`$0 email-routing disable
|
|
14
14
|
|
|
15
|
-
Disable your Email Routing zone. Also removes additional MX records previously required for Email Routing to work.`).option(`name`,{type:`string`,description:`Domain of your zone.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const k={command:`disable`,describe:`Disable Email Routing`,builder:O,handler:async e=>c({command:`email-routing disable`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){o({command:`cf email-routing disable`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/dns`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({name:f(e.name,`name`,`text`)}):l(e.body)});return}let n=await
|
|
16
|
-
`);return}if(e.body){let t=l(e.body);a(await s(`Deleting`,async()=>n.emailRouting.disable({body:t,zone_id:
|
|
15
|
+
Disable your Email Routing zone. Also removes additional MX records previously required for Email Routing to work.`).option(`name`,{type:`string`,description:`Domain of your zone.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const k={command:`disable`,describe:`Disable Email Routing`,builder:O,handler:async e=>c({command:`email-routing disable`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){o({command:`cf email-routing disable`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/dns`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({name:f(e.name,`name`,`text`)}):l(e.body)});return}let n=await t(e),i=await r({zone:e.zone},n,{quiet:e.quiet});if(e.zoneId=i,!await h({force:!!e.force,message:`This operation disables Email Routing and removes its DNS records.`})){process.stderr.write(`Aborted.
|
|
16
|
+
`);return}if(e.body){let t=l(e.body);a(await s(`Deleting`,async()=>n.emailRouting.disable({body:t,zone_id:i})),{successLabel:`Deleted`});return}let c=d({name:f(e.name,`name`,`text`)});a(await s(`Deleting`,async()=>n.emailRouting.disable({body:c,zone_id:i})),{successLabel:`Deleted`})})};function A(e){return e.usage(`$0 email-routing dns get
|
|
17
17
|
|
|
18
|
-
Show the DNS records needed to configure your Email Routing zone.`).option(`subdomain`,{type:`string`,description:`Deprecated. When supplied, the response shape differs from the documented default and is not modeled in generated SDKs. Do not rely on this parameter.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const j={command:`get`,describe:`Email Routing - DNS settings`,builder:A,handler:async e=>c({command:`email-routing dns get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{let n={subdomain:e.subdomain};if(e.dryRun){o({command:`cf email-routing dns get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/dns`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},query:n,bodyKind:`none`});return}let
|
|
18
|
+
Show the DNS records needed to configure your Email Routing zone.`).option(`subdomain`,{type:`string`,description:`Deprecated. When supplied, the response shape differs from the documented default and is not modeled in generated SDKs. Do not rely on this parameter.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const j={command:`get`,describe:`Email Routing - DNS settings`,builder:A,handler:async e=>c({command:`email-routing dns get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{let n={subdomain:e.subdomain};if(e.dryRun){o({command:`cf email-routing dns get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/dns`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},query:n,bodyKind:`none`});return}let i=await t(e),c=await r({zone:e.zone},i,{quiet:e.quiet});e.zoneId=c,a(await s(`Loading`,async()=>i.emailRouting.dns.get({zone_id:c,...n})),{successLabel:`Loaded`})})};function M(e){return e.usage(`$0 email-routing dns unlock
|
|
19
19
|
|
|
20
|
-
Unlock MX Records previously locked by Email Routing.`).option(`name`,{type:`string`,description:`Domain of your zone.`}).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 N={command:`unlock`,describe:`Unlock Email Routing DNS records`,builder:M,handler:async e=>c({command:`email-routing dns unlock`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing dns unlock`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/dns`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({name:f(e.name,`name`,`text`)}):l(e.body)});return}let n=await
|
|
20
|
+
Unlock MX Records previously locked by Email Routing.`).option(`name`,{type:`string`,description:`Domain of your zone.`}).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 N={command:`unlock`,describe:`Unlock Email Routing DNS records`,builder:M,handler:async e=>c({command:`email-routing dns unlock`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing dns unlock`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/dns`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({name:f(e.name,`name`,`text`)}):l(e.body)});return}let n=await t(e),i=await r({zone:e.zone},n,{quiet:e.quiet});if(e.zoneId=i,e.body){let t=l(e.body);a(await s(`Updating`,async()=>n.emailRouting.dns.unlock({body:t,zone_id:i})),{successLabel:`Updated`});return}let c=d({name:f(e.name,`name`,`text`)});a(await s(`Updating`,async()=>n.emailRouting.dns.unlock({body:c,zone_id:i})),{successLabel:`Updated`})})},P={command:`dns`,describe:`Inspect or unlock the DNS records required by Email Routing`,builder:e=>e.command(j).command(N).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function F(e){return e.usage(`$0 email-routing enable
|
|
21
21
|
|
|
22
|
-
Enable your Email Routing zone. Add and lock the necessary MX and SPF records.`).option(`name`,{type:`string`,description:`Domain of your zone.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const I={command:`enable`,describe:`Enable Email Routing`,builder:F,handler:async e=>c({command:`email-routing enable`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing enable`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/dns`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({name:f(e.name,`name`,`text`)}):l(e.body)});return}let n=await
|
|
22
|
+
Enable your Email Routing zone. Add and lock the necessary MX and SPF records.`).option(`name`,{type:`string`,description:`Domain of your zone.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const I={command:`enable`,describe:`Enable Email Routing`,builder:F,handler:async e=>c({command:`email-routing enable`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing enable`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/dns`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({name:f(e.name,`name`,`text`)}):l(e.body)});return}let n=await t(e),i=await r({zone:e.zone},n,{quiet:e.quiet});if(e.zoneId=i,e.body){let t=l(e.body);a(await s(`Creating`,async()=>n.emailRouting.enable({body:t,zone_id:i})),{successLabel:`Created`});return}let c=d({name:f(e.name,`name`,`text`)});a(await s(`Creating`,async()=>n.emailRouting.enable({body:c,zone_id:i})),{successLabel:`Created`})})};function L(e){return e.usage(`$0 email-routing rules catch-all get
|
|
23
23
|
|
|
24
|
-
Get information on the default catch-all routing rule.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const ee={command:`get`,describe:`Get catch-all rule`,builder:L,handler:async e=>c({command:`email-routing rules catch-all get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing rules catch-all get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/rules/catch_all`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let n=await
|
|
24
|
+
Get information on the default catch-all routing rule.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const ee={command:`get`,describe:`Get catch-all rule`,builder:L,handler:async e=>c({command:`email-routing rules catch-all get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing rules catch-all get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/rules/catch_all`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let n=await t(e),i=await r({zone:e.zone},n,{quiet:e.quiet});e.zoneId=i,a(await s(`Loading`,async()=>n.emailRouting.rules.catchAll.get({zone_id:i})),{successLabel:`Loaded`})})};function R(e){return e.usage(`$0 email-routing rules catch-all update
|
|
25
25
|
|
|
26
|
-
Enable or disable catch-all routing rule, or change action to forward to a specific destination address. Forward actions require exactly one verified destination address.`).option(`actions`,{type:`string`,description:`List actions for the catch-all routing rule. Provide as a JSON array of objects or @path/to/file.json.`}).option(`enabled`,{type:`boolean`,description:`Routing rule status.`}).option(`matchers`,{type:`string`,description:`List of matchers for the catch-all routing rule. Provide as a JSON array of objects or @path/to/file.json.`}).option(`name`,{type:`string`,description:`Routing rule name.`}).option(`owner-worker-tag`,{type:`string`,description:"Public tag (script_tag) of the Worker that owns this rule. Required when\n`source` is `wrangler`.\n"}).option(`source`,{type:`string`,description:"Who manages the rule. `api` covers dashboard, generic API, and Terraform;\n`wrangler` means the rule is managed by a Worker's wrangler.jsonc. Defaults\nto `api` when omitted on write.\n",choices:[`api`,`wrangler`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const z={command:`update`,describe:`Update catch-all rule`,builder:R,handler:async e=>c({command:`email-routing rules catch-all update`,classification:{safeFlags:[`enabled`,`source`,`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing rules catch-all update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/rules/catch_all`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({actions:u(e.actions,`actions`),enabled:e.enabled,matchers:u(e.matchers,`matchers`),name:f(e.name,`name`,`text`),owner_worker_tag:f(e[`owner-worker-tag`],`owner-worker-tag`,`text`),source:f(e.source,`source`,`text`)}):l(e.body)});return}let n=await
|
|
26
|
+
Enable or disable catch-all routing rule, or change action to forward to a specific destination address. Forward actions require exactly one verified destination address.`).option(`actions`,{type:`string`,description:`List actions for the catch-all routing rule. Provide as a JSON array of objects or @path/to/file.json.`}).option(`enabled`,{type:`boolean`,description:`Routing rule status.`}).option(`matchers`,{type:`string`,description:`List of matchers for the catch-all routing rule. Provide as a JSON array of objects or @path/to/file.json.`}).option(`name`,{type:`string`,description:`Routing rule name.`}).option(`owner-worker-tag`,{type:`string`,description:"Public tag (script_tag) of the Worker that owns this rule. Required when\n`source` is `wrangler`.\n"}).option(`source`,{type:`string`,description:"Who manages the rule. `api` covers dashboard, generic API, and Terraform;\n`wrangler` means the rule is managed by a Worker's wrangler.jsonc. Defaults\nto `api` when omitted on write.\n",choices:[`api`,`wrangler`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const z={command:`update`,describe:`Update catch-all rule`,builder:R,handler:async e=>c({command:`email-routing rules catch-all update`,classification:{safeFlags:[`enabled`,`source`,`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing rules catch-all update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/rules/catch_all`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({actions:u(e.actions,`actions`),enabled:e.enabled,matchers:u(e.matchers,`matchers`),name:f(e.name,`name`,`text`),owner_worker_tag:f(e[`owner-worker-tag`],`owner-worker-tag`,`text`),source:f(e.source,`source`,`text`)}):l(e.body)});return}let n=await t(e),i=await r({zone:e.zone},n,{quiet:e.quiet});if(e.zoneId=i,e.body){let t=l(e.body);a(await s(`Updating`,async()=>n.emailRouting.rules.catchAll.update({...t,zone_id:i})),{successLabel:`Updated`});return}if(e.actions===void 0)throw Error(`--actions is required (or pass --body with this field set).`);if(e.matchers===void 0)throw Error(`--matchers is required (or pass --body with this field set).`);let c=d({actions:u(e.actions,`actions`),enabled:e.enabled,matchers:u(e.matchers,`matchers`),name:f(e.name,`name`,`text`),owner_worker_tag:f(e[`owner-worker-tag`],`owner-worker-tag`,`text`),source:f(e.source,`source`,`text`)});a(await s(`Updating`,async()=>n.emailRouting.rules.catchAll.update({...c,zone_id:i})),{successLabel:`Updated`})})},B={command:`catch-all`,describe:`Operations for rules.catch-all`,builder:e=>e.command(ee).command(z).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function V(e){return e.usage(`$0 email-routing rules create
|
|
27
27
|
|
|
28
|
-
Rules consist of a set of criteria for matching emails (such as an email being sent to a specific custom email address) plus a set of actions to take on the email (like forwarding it to a specific destination address). Forward actions require exactly one verified destination address.`).option(`actions`,{type:`string`,description:`List actions patterns. Provide as a JSON array of objects or @path/to/file.json.`}).option(`enabled`,{type:`boolean`,description:`Routing rule status.`,default:!0}).option(`matchers`,{type:`string`,description:`Matching patterns to forward to your actions. Provide as a JSON array of objects or @path/to/file.json.`}).option(`name`,{type:`string`,description:`Routing rule name.`}).option(`owner-worker-tag`,{type:`string`,description:"Public tag (script_tag) of the Worker that owns this rule. Required when\n`source` is `wrangler`.\n"}).option(`priority`,{type:`number`,description:`Priority of the routing rule.`,default:0}).option(`source`,{type:`string`,description:"Who manages the rule. `api` covers dashboard, generic API, and Terraform;\n`wrangler` means the rule is managed by a Worker's wrangler.jsonc. Defaults\nto `api` when omitted on write.\n",choices:[`api`,`wrangler`],default:`api`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const H={command:`create`,describe:`Create routing rule`,builder:V,handler:async e=>c({command:`email-routing rules create`,classification:{safeFlags:[`enabled`,`source`,`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing rules create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/rules`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({actions:u(e.actions,`actions`),enabled:e.enabled,matchers:u(e.matchers,`matchers`),name:f(e.name,`name`,`text`),owner_worker_tag:f(e[`owner-worker-tag`],`owner-worker-tag`,`text`),priority:e.priority,source:f(e.source,`source`,`text`)}):l(e.body)});return}let n=await
|
|
28
|
+
Rules consist of a set of criteria for matching emails (such as an email being sent to a specific custom email address) plus a set of actions to take on the email (like forwarding it to a specific destination address). Forward actions require exactly one verified destination address.`).option(`actions`,{type:`string`,description:`List actions patterns. Provide as a JSON array of objects or @path/to/file.json.`}).option(`enabled`,{type:`boolean`,description:`Routing rule status.`,default:!0}).option(`matchers`,{type:`string`,description:`Matching patterns to forward to your actions. Provide as a JSON array of objects or @path/to/file.json.`}).option(`name`,{type:`string`,description:`Routing rule name.`}).option(`owner-worker-tag`,{type:`string`,description:"Public tag (script_tag) of the Worker that owns this rule. Required when\n`source` is `wrangler`.\n"}).option(`priority`,{type:`number`,description:`Priority of the routing rule.`,default:0}).option(`source`,{type:`string`,description:"Who manages the rule. `api` covers dashboard, generic API, and Terraform;\n`wrangler` means the rule is managed by a Worker's wrangler.jsonc. Defaults\nto `api` when omitted on write.\n",choices:[`api`,`wrangler`],default:`api`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const H={command:`create`,describe:`Create routing rule`,builder:V,handler:async e=>c({command:`email-routing rules create`,classification:{safeFlags:[`enabled`,`source`,`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing rules create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/rules`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({actions:u(e.actions,`actions`),enabled:e.enabled,matchers:u(e.matchers,`matchers`),name:f(e.name,`name`,`text`),owner_worker_tag:f(e[`owner-worker-tag`],`owner-worker-tag`,`text`),priority:e.priority,source:f(e.source,`source`,`text`)}):l(e.body)});return}let n=await t(e),i=await r({zone:e.zone},n,{quiet:e.quiet});if(e.zoneId=i,e.body){let t=l(e.body);a(await s(`Creating`,async()=>n.emailRouting.rules.create({...t,zone_id:i})),{successLabel:`Created`});return}if(e.actions===void 0)throw Error(`--actions is required (or pass --body with this field set).`);if(e.matchers===void 0)throw Error(`--matchers is required (or pass --body with this field set).`);let c=d({actions:u(e.actions,`actions`),enabled:e.enabled,matchers:u(e.matchers,`matchers`),name:f(e.name,`name`,`text`),owner_worker_tag:f(e[`owner-worker-tag`],`owner-worker-tag`,`text`),priority:e.priority,source:f(e.source,`source`,`text`)});a(await s(`Creating`,async()=>n.emailRouting.rules.create({...c,zone_id:i})),{successLabel:`Created`})})};function U(e){return e.usage(`$0 email-routing rules delete <rule-identifier>
|
|
29
29
|
|
|
30
|
-
Deletes a routing rule so matching incoming messages are no longer forwarded by it.`).positional(`rule-identifier`,{type:`string`,description:`Routing rule identifier.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const W={command:`delete <rule-identifier>`,describe:`Delete routing rule`,builder:U,handler:async e=>c({command:`email-routing rules delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){o({command:`cf email-routing rules delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/rules/${e[`rule-identifier`]==null?`<rule-identifier>`:encodeURIComponent(String(e[`rule-identifier`]))}`,pathParams:{"rule-identifier":String(e[`rule-identifier`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let n=await
|
|
31
|
-
`);return}a(await s(`Deleting`,async()=>n.emailRouting.rules.delete({zone_id:
|
|
30
|
+
Deletes a routing rule so matching incoming messages are no longer forwarded by it.`).positional(`rule-identifier`,{type:`string`,description:`Routing rule identifier.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const W={command:`delete <rule-identifier>`,describe:`Delete routing rule`,builder:U,handler:async e=>c({command:`email-routing rules delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){o({command:`cf email-routing rules delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/rules/${e[`rule-identifier`]==null?`<rule-identifier>`:encodeURIComponent(String(e[`rule-identifier`]))}`,pathParams:{"rule-identifier":String(e[`rule-identifier`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let n=await t(e),i=await r({zone:e.zone},n,{quiet:e.quiet});if(e.zoneId=i,!await h({force:!!e.force,message:`This operation permanently deletes an Email Routing rule.`})){process.stderr.write(`Aborted.
|
|
31
|
+
`);return}a(await s(`Deleting`,async()=>n.emailRouting.rules.delete({zone_id:i,rule_identifier:e[`rule-identifier`]})),{successLabel:`Deleted`})})};function G(e){return e.usage(`$0 email-routing rules get <rule-identifier>
|
|
32
32
|
|
|
33
|
-
Get information for a specific routing rule already created.`).positional(`rule-identifier`,{type:`string`,description:`Routing rule identifier.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const K={command:`get <rule-identifier>`,describe:`Get routing rule`,builder:G,handler:async e=>c({command:`email-routing rules get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing rules get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/rules/${e[`rule-identifier`]==null?`<rule-identifier>`:encodeURIComponent(String(e[`rule-identifier`]))}`,pathParams:{"rule-identifier":String(e[`rule-identifier`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let n=await
|
|
33
|
+
Get information for a specific routing rule already created.`).positional(`rule-identifier`,{type:`string`,description:`Routing rule identifier.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const K={command:`get <rule-identifier>`,describe:`Get routing rule`,builder:G,handler:async e=>c({command:`email-routing rules get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing rules get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/rules/${e[`rule-identifier`]==null?`<rule-identifier>`:encodeURIComponent(String(e[`rule-identifier`]))}`,pathParams:{"rule-identifier":String(e[`rule-identifier`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let n=await t(e),i=await r({zone:e.zone},n,{quiet:e.quiet});e.zoneId=i,a(await s(`Loading`,async()=>n.emailRouting.rules.get({zone_id:i,rule_identifier:e[`rule-identifier`]})),{successLabel:`Loaded`})})};function q(e){return e.usage(`$0 email-routing rules list-account
|
|
34
34
|
|
|
35
|
-
Lists existing routing rules across all zones in the account or zone.`).option(`page`,{type:`number`,description:`Page number of paginated results.`}).option(`per-page`,{type:`number`,description:`Maximum number of results per page.`}).option(`enabled`,{type:`string`,description:`Filter by enabled routing rules.`,choices:[`true`,`false`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const J={command:`list-account`,describe:`List account or zone routing rules`,builder:g(q),handler:async l=>c({command:`email-routing rules list-account`,classification:{safeFlags:[`enabled`,`dry-run`]}},l,async()=>{let c={page:l.page,per_page:l[`per-page`],enabled:l.enabled};if(l.dryRun){let e=l.zone===void 0?await
|
|
35
|
+
Lists existing routing rules across all zones in the account or zone.`).option(`page`,{type:`number`,description:`Page number of paginated results.`}).option(`per-page`,{type:`number`,description:`Maximum number of results per page.`}).option(`enabled`,{type:`string`,description:`Filter by enabled routing rules.`,choices:[`true`,`false`]}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const J={command:`list-account`,describe:`List account or zone routing rules`,builder:g(q),handler:async l=>c({command:`email-routing rules list-account`,classification:{safeFlags:[`enabled`,`dry-run`]}},l,async()=>{let c={page:l.page,per_page:l[`per-page`],enabled:l.enabled};if(l.dryRun){let e=l.zone===void 0?await n():void 0,t=l.zone===void 0?`accounts`:`zones`,r=l.zone??e??`<account-id>`;o({command:`cf email-routing rules list-account`,method:`GET`,url:`https://api.cloudflare.com/client/v4/${t}/${r}/email/routing/rules`,pathParams:{"account-or-zone":String(t),"account-or-zone-id":String(r)},query:c,bodyKind:`none`});return}let u=await t(l),d=l.zone===void 0?`accounts`:`zones`,f=d===`zones`?await r({zone:l.zone},u,{quiet:l.quiet}):l.local?e:await i();d===`zones`?l.zoneId=f:l.accountId=f,a(await s(`Loading`,async()=>u.emailRouting.rules.listAccount({account_or_zone:d,account_or_zone_id:f,...c})),{successLabel:`Loaded`})})};function Y(e){return e.usage(`$0 email-routing rules plan
|
|
36
36
|
|
|
37
|
-
Computes the Email Routing rule changes that would be needed to reconcile a Wrangler-managed desired ruleset. This endpoint is read-only and does not create, update, or delete rules.`).option(`catch-all-rules`,{type:`string`,description:`Desired catch-all Email Routing rules managed by the deploying Worker. Provide as a JSON array of objects or @path/to/file.json.`}).option(`owner-worker-tag`,{type:`string`,description:"Public tag (script_tag) of the Worker that owns this rule. Required when\n`source` is `wrangler`.\n"}).option(`rules`,{type:`string`,description:`Desired normal Email Routing rules managed by the deploying Worker. Provide as a JSON array of objects or @path/to/file.json.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const X={command:`plan`,describe:`Plan account routing rule changes`,builder:Y,handler:async
|
|
37
|
+
Computes the Email Routing rule changes that would be needed to reconcile a Wrangler-managed desired ruleset. This endpoint is read-only and does not create, update, or delete rules.`).option(`catch-all-rules`,{type:`string`,description:`Desired catch-all Email Routing rules managed by the deploying Worker. Provide as a JSON array of objects or @path/to/file.json.`}).option(`owner-worker-tag`,{type:`string`,description:"Public tag (script_tag) of the Worker that owns this rule. Required when\n`source` is `wrangler`.\n"}).option(`rules`,{type:`string`,description:`Desired normal Email Routing rules managed by the deploying Worker. Provide as a JSON array of objects or @path/to/file.json.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const X={command:`plan`,describe:`Plan account routing rule changes`,builder:Y,handler:async r=>c({command:`email-routing rules plan`,classification:{safeFlags:[`dry-run`]}},r,async()=>{if(r.dryRun){o({command:`cf email-routing rules plan`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${await n()??`<account-id>`}/email/routing/rules/plan`,pathParams:{},bodyKind:`json`,body:r.body===void 0?d({catch_all_rules:u(r[`catch-all-rules`],`catch-all-rules`),owner_worker_tag:f(r[`owner-worker-tag`],`owner-worker-tag`,`text`),rules:u(r.rules,`rules`)}):l(r.body)});return}let c=await t(r),m=r.local?e:await i();if(r.accountId=m,r.body){let e=l(r.body);a(await s(`Creating`,async()=>c.emailRouting.rules.plan({...e,account_id:m})),{successLabel:`Created`});return}r[`owner-worker-tag`]===void 0&&(r[`owner-worker-tag`]=await p(`owner-worker-tag`,"Public tag (script_tag) of the Worker that owns this rule. Required when `source` is `wrangler`. "));let h=d({catch_all_rules:u(r[`catch-all-rules`],`catch-all-rules`),owner_worker_tag:f(r[`owner-worker-tag`],`owner-worker-tag`,`text`),rules:u(r.rules,`rules`)});a(await s(`Creating`,async()=>c.emailRouting.rules.plan({...h,account_id:m})),{successLabel:`Created`})})};function Z(e){return e.usage(`$0 email-routing rules update <rule-identifier>
|
|
38
38
|
|
|
39
|
-
Update actions and matches, or enable/disable specific routing rules. Forward actions require exactly one verified destination address.`).positional(`rule-identifier`,{type:`string`,description:`Routing rule identifier.`,demandOption:!0}).option(`actions`,{type:`string`,description:`List actions patterns. Provide as a JSON array of objects or @path/to/file.json.`}).option(`enabled`,{type:`boolean`,description:`Routing rule status.`}).option(`matchers`,{type:`string`,description:`Matching patterns to forward to your actions. Provide as a JSON array of objects or @path/to/file.json.`}).option(`name`,{type:`string`,description:`Routing rule name.`}).option(`owner-worker-tag`,{type:`string`,description:"Public tag (script_tag) of the Worker that owns this rule. Required when\n`source` is `wrangler`.\n"}).option(`priority`,{type:`number`,description:`Priority of the routing rule.`}).option(`source`,{type:`string`,description:"Who manages the rule. `api` covers dashboard, generic API, and Terraform;\n`wrangler` means the rule is managed by a Worker's wrangler.jsonc. Defaults\nto `api` when omitted on write.\n",choices:[`api`,`wrangler`]}).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 Q={command:`update <rule-identifier>`,describe:`Update routing rule`,builder:Z,handler:async e=>c({command:`email-routing rules update`,classification:{safeFlags:[`enabled`,`source`,`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing rules update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/rules/${e[`rule-identifier`]==null?`<rule-identifier>`:encodeURIComponent(String(e[`rule-identifier`]))}`,pathParams:{"rule-identifier":String(e[`rule-identifier`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({actions:u(e.actions,`actions`),enabled:e.enabled,matchers:u(e.matchers,`matchers`),name:f(e.name,`name`,`text`),owner_worker_tag:f(e[`owner-worker-tag`],`owner-worker-tag`,`text`),priority:e.priority,source:f(e.source,`source`,`text`)}):l(e.body)});return}let n=await
|
|
39
|
+
Update actions and matches, or enable/disable specific routing rules. Forward actions require exactly one verified destination address.`).positional(`rule-identifier`,{type:`string`,description:`Routing rule identifier.`,demandOption:!0}).option(`actions`,{type:`string`,description:`List actions patterns. Provide as a JSON array of objects or @path/to/file.json.`}).option(`enabled`,{type:`boolean`,description:`Routing rule status.`}).option(`matchers`,{type:`string`,description:`Matching patterns to forward to your actions. Provide as a JSON array of objects or @path/to/file.json.`}).option(`name`,{type:`string`,description:`Routing rule name.`}).option(`owner-worker-tag`,{type:`string`,description:"Public tag (script_tag) of the Worker that owns this rule. Required when\n`source` is `wrangler`.\n"}).option(`priority`,{type:`number`,description:`Priority of the routing rule.`}).option(`source`,{type:`string`,description:"Who manages the rule. `api` covers dashboard, generic API, and Terraform;\n`wrangler` means the rule is managed by a Worker's wrangler.jsonc. Defaults\nto `api` when omitted on write.\n",choices:[`api`,`wrangler`]}).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 Q={command:`update <rule-identifier>`,describe:`Update routing rule`,builder:Z,handler:async e=>c({command:`email-routing rules update`,classification:{safeFlags:[`enabled`,`source`,`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing rules update`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing/rules/${e[`rule-identifier`]==null?`<rule-identifier>`:encodeURIComponent(String(e[`rule-identifier`]))}`,pathParams:{"rule-identifier":String(e[`rule-identifier`]??``),"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({actions:u(e.actions,`actions`),enabled:e.enabled,matchers:u(e.matchers,`matchers`),name:f(e.name,`name`,`text`),owner_worker_tag:f(e[`owner-worker-tag`],`owner-worker-tag`,`text`),priority:e.priority,source:f(e.source,`source`,`text`)}):l(e.body)});return}let n=await t(e),i=await r({zone:e.zone},n,{quiet:e.quiet});if(e.zoneId=i,e.body){let t=l(e.body);a(await s(`Updating`,async()=>n.emailRouting.rules.update({...t,zone_id:i,rule_identifier:e[`rule-identifier`]})),{successLabel:`Updated`});return}if(e.actions===void 0)throw Error(`--actions is required (or pass --body with this field set).`);if(e.matchers===void 0)throw Error(`--matchers is required (or pass --body with this field set).`);let c=d({actions:u(e.actions,`actions`),enabled:e.enabled,matchers:u(e.matchers,`matchers`),name:f(e.name,`name`,`text`),owner_worker_tag:f(e[`owner-worker-tag`],`owner-worker-tag`,`text`),priority:e.priority,source:f(e.source,`source`,`text`)});a(await s(`Updating`,async()=>n.emailRouting.rules.update({...c,zone_id:i,rule_identifier:e[`rule-identifier`]})),{successLabel:`Updated`})})},$={command:`rules`,describe:`Match incoming email addresses and forward messages to destination mailboxes or Workers`,builder:e=>e.command(H).command(W).command(K).command(J).command(X).command(Q).command(B).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function te(e){return e.usage(`$0 email-routing settings apply
|
|
40
40
|
|
|
41
|
-
Apply the provided settings to your Email Routing zone. Omitted settings retain their current values, as with PATCH.`).option(`enabled`,{type:`boolean`,description:"State of your zone Email Routing settings. No-op on this endpoint - use `POST`/`DELETE /zones/{zone_id}/email/routing/dns`."}).option(`skip-wizard`,{type:`boolean`,description:`Flag to check if the user skipped the configuration wizard.`}).option(`support-subaddress`,{type:`boolean`,description:`Whether subaddressing (plus-addressing) is honored when matching incoming mail against routing rules.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const ne={command:`apply`,describe:`Apply Email Routing settings`,builder:te,handler:async e=>c({command:`email-routing settings apply`,classification:{safeFlags:[`enabled`,`skip-wizard`,`support-subaddress`,`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing settings apply`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({enabled:e.enabled,skip_wizard:e[`skip-wizard`],support_subaddress:e[`support-subaddress`]}):l(e.body)});return}let n=await
|
|
41
|
+
Apply the provided settings to your Email Routing zone. Omitted settings retain their current values, as with PATCH.`).option(`enabled`,{type:`boolean`,description:"State of your zone Email Routing settings. No-op on this endpoint - use `POST`/`DELETE /zones/{zone_id}/email/routing/dns`."}).option(`skip-wizard`,{type:`boolean`,description:`Flag to check if the user skipped the configuration wizard.`}).option(`support-subaddress`,{type:`boolean`,description:`Whether subaddressing (plus-addressing) is honored when matching incoming mail against routing rules.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const ne={command:`apply`,describe:`Apply Email Routing settings`,builder:te,handler:async e=>c({command:`email-routing settings apply`,classification:{safeFlags:[`enabled`,`skip-wizard`,`support-subaddress`,`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing settings apply`,method:`PUT`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({enabled:e.enabled,skip_wizard:e[`skip-wizard`],support_subaddress:e[`support-subaddress`]}):l(e.body)});return}let n=await t(e),i=await r({zone:e.zone},n,{quiet:e.quiet});if(e.zoneId=i,e.body){let t=l(e.body);a(await s(`Updating`,async()=>n.emailRouting.settings.apply({...t,zone_id:i})),{successLabel:`Updated`});return}let c=d({enabled:e.enabled,skip_wizard:e[`skip-wizard`],support_subaddress:e[`support-subaddress`]});a(await s(`Updating`,async()=>n.emailRouting.settings.apply({...c,zone_id:i})),{successLabel:`Updated`})})};function re(e){return e.usage(`$0 email-routing settings get
|
|
42
42
|
|
|
43
|
-
Get information about the settings for your Email Routing zone.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const ie={command:`get`,describe:`Get Email Routing settings`,builder:re,handler:async e=>c({command:`email-routing settings get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing settings get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let n=await
|
|
43
|
+
Get information about the settings for your Email Routing zone.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const ie={command:`get`,describe:`Get Email Routing settings`,builder:re,handler:async e=>c({command:`email-routing settings get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing settings get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let n=await t(e),i=await r({zone:e.zone},n,{quiet:e.quiet});e.zoneId=i,a(await s(`Loading`,async()=>n.emailRouting.settings.get({zone_id:i})),{successLabel:`Loaded`})})};function ae(e){return e.usage(`$0 email-routing settings update
|
|
44
44
|
|
|
45
|
-
Update the settings for your Email Routing zone.`).option(`enabled`,{type:`boolean`,description:"State of your zone Email Routing settings. No-op on this endpoint - use `POST`/`DELETE /zones/{zone_id}/email/routing/dns`."}).option(`skip-wizard`,{type:`boolean`,description:`Flag to check if the user skipped the configuration wizard.`}).option(`support-subaddress`,{type:`boolean`,description:`Whether subaddressing (plus-addressing) is honored when matching incoming mail against routing rules.`}).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 oe={command:`update`,describe:`Update Email Routing settings`,builder:ae,handler:async e=>c({command:`email-routing settings update`,classification:{safeFlags:[`enabled`,`skip-wizard`,`support-subaddress`,`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing settings update`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({enabled:e.enabled,skip_wizard:e[`skip-wizard`],support_subaddress:e[`support-subaddress`]}):l(e.body)});return}let n=await
|
|
45
|
+
Update the settings for your Email Routing zone.`).option(`enabled`,{type:`boolean`,description:"State of your zone Email Routing settings. No-op on this endpoint - use `POST`/`DELETE /zones/{zone_id}/email/routing/dns`."}).option(`skip-wizard`,{type:`boolean`,description:`Flag to check if the user skipped the configuration wizard.`}).option(`support-subaddress`,{type:`boolean`,description:`Whether subaddressing (plus-addressing) is honored when matching incoming mail against routing rules.`}).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 oe={command:`update`,describe:`Update Email Routing settings`,builder:ae,handler:async e=>c({command:`email-routing settings update`,classification:{safeFlags:[`enabled`,`skip-wizard`,`support-subaddress`,`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf email-routing settings update`,method:`PATCH`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/email/routing`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?d({enabled:e.enabled,skip_wizard:e[`skip-wizard`],support_subaddress:e[`support-subaddress`]}):l(e.body)});return}let n=await t(e),i=await r({zone:e.zone},n,{quiet:e.quiet});if(e.zoneId=i,e.body){let t=l(e.body);a(await s(`Updating`,async()=>n.emailRouting.settings.update({...t,zone_id:i})),{successLabel:`Updated`});return}let c=d({enabled:e.enabled,skip_wizard:e[`skip-wizard`],support_subaddress:e[`support-subaddress`]});a(await s(`Updating`,async()=>n.emailRouting.settings.update({...c,zone_id:i})),{successLabel:`Updated`})})},se={command:`settings`,describe:`Inspect and update Email Routing settings`,builder:e=>e.command(ne).command(ie).command(oe).demandCommand(1,`Please specify a subcommand`),handler:()=>{}},ce={command:`email-routing`,describe:`Route incoming email to verified destination addresses or Workers with routing rules, catch-all behavior, and managed DNS records`,builder:e=>e.command(k).command(I).command(D).command(P).command($).command(se).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{ce as default};
|