cf 1.0.0-beta.29 → 1.0.0-beta.30
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/dist/_meta/commands.json +584 -96
- package/dist/_meta/hand-written-commands.json +7 -1
- package/dist/_meta/schemas.json +182 -48
- package/dist/{abuse-reports-DqXYX_6F.mjs → abuse-reports-Dzop8iDe.mjs} +1 -1
- package/dist/{access-Cte4yyIz.mjs → access-2NeD3Gu8.mjs} +1 -1
- package/dist/{accounts-G-x-_cEx.mjs → accounts-CeJbhhX4.mjs} +1 -1
- package/dist/{acm-Bg3HqMGG.mjs → acm-Dub0B14J.mjs} +1 -1
- package/dist/{addressing-BwEofGEm.mjs → addressing-BzWJU8m6.mjs} +1 -1
- package/dist/{agent-memory-DhwZ2KRw.mjs → agent-memory-2l9zyQFA.mjs} +1 -1
- package/dist/{ai-audit-CMEBz6ZP.mjs → ai-audit-rgNePq5W.mjs} +1 -1
- package/dist/{ai-gateway-D2s0isU-.mjs → ai-gateway-e9b8CcL6.mjs} +2 -2
- package/dist/{ai-DWWRIQIt.mjs → ai-laLv3daG.mjs} +1 -1
- package/dist/{ai-search-a0uqr9yJ.mjs → ai-search-DZ0AqoPe.mjs} +1 -1
- package/dist/{ai-security-H_RqjRoL.mjs → ai-security-CQuBTtmw.mjs} +1 -1
- package/dist/{alerting-Bgp9rE4I.mjs → alerting-_4ra-f_v.mjs} +1 -1
- package/dist/{analytics-CFYM82FD.mjs → analytics-DLNn4bJ4.mjs} +1 -1
- package/dist/{analytics-engine-BLiEaLxb.mjs → analytics-engine-CY45yWuL.mjs} +1 -1
- package/dist/{api-security-B0YtHglt.mjs → api-security-BSvJAjJV.mjs} +1 -1
- package/dist/{argo-BPwbzHY7.mjs → argo-xzl0p--1.mjs} +1 -1
- package/dist/{artifacts-B6UwC2PH.mjs → artifacts-DAS14gcM.mjs} +1 -1
- package/dist/{audit-logs-kG97iEnI.mjs → audit-logs-3nYyCGQA.mjs} +1 -1
- package/dist/auth-B0mFB6nU.mjs +3 -0
- package/dist/auth-CXR2vsII.mjs +2 -0
- package/dist/{auth-DA1PHaHi.mjs → auth-cj71dGxS.mjs} +1 -1
- package/dist/{auth-token-CE3Wa5-b.mjs → auth-token-D9MnaZ-L.mjs} +1 -1
- package/dist/{autoconfig-B4tFR6ua.mjs → autoconfig-DoLQ5ct8.mjs} +1 -1
- package/dist/{basin-catalog-DzVEPupy.mjs → basin-catalog-BbCsAKyZ.mjs} +1 -1
- package/dist/{billing-TERxOuLR.mjs → billing-BsiLsjWJ.mjs} +1 -1
- package/dist/{blocks-C3Im7AT0.mjs → blocks-DK5qAzLe.mjs} +1 -1
- package/dist/{body-unions-D9OSaf4M.mjs → body-unions-QFGGUlIr.mjs} +1 -1
- package/dist/{bot-management-SZw9jTOC.mjs → bot-management-DkErOsIO.mjs} +1 -1
- package/dist/{botnet-feed-DjdAeUtb.mjs → botnet-feed-CK4_PKrf.mjs} +1 -1
- package/dist/{brand-protection-BpA7Gmf1.mjs → brand-protection-Czt-2Ei5.mjs} +1 -1
- package/dist/{browser-run-BvjfMK3f.mjs → browser-run-DLMdEaSJ.mjs} +20 -20
- package/dist/build-ByjJ6yIB.mjs +2 -0
- package/dist/{build-yQOzZg6Z.mjs → build-DiEXOgHH.mjs} +1 -1
- package/dist/{builds-tMa3sbQU.mjs → builds-D--zUbR2.mjs} +1 -1
- package/dist/{cache-b_EPh6Is.mjs → cache-C8PQmkjD.mjs} +1 -1
- package/dist/{cf-DmvZ2L51.mjs → cf-QIG83e0V.mjs} +6 -6
- package/dist/{chunk-DSGVRFIS-Cj7pO-YQ.mjs → chunk-DSGVRFIS-CeCM3XGQ.mjs} +1 -1
- package/dist/{chunk-Q5KVZMHK-WOCEMyET.mjs → chunk-Q5KVZMHK-Bjvrcihk.mjs} +2 -2
- package/dist/{cli-Cc7ujzAy.mjs → cli-BBv5YMan.mjs} +1 -1
- package/dist/{client-side-security-DVkeCzcC.mjs → client-side-security-CFxePUL9.mjs} +1 -1
- package/dist/{cloud-connector-MVf4acRR.mjs → cloud-connector-BitfLQ3s.mjs} +1 -1
- package/dist/{cloudflared-BOkMl8Gm.mjs → cloudflared-DKh4JK7j.mjs} +1 -1
- package/dist/{cloudforce-one-KrCfQbRx.mjs → cloudforce-one-D2dzA7VD.mjs} +1 -1
- package/dist/{command-C4_lMRkw.mjs → command-B6ustzcW.mjs} +1 -1
- package/dist/{command-DqOU7Ql2.mjs → command-BC_nezLE.mjs} +1 -1
- package/dist/{command-CJ3ldWrA.mjs → command-BORazCDG.mjs} +1 -1
- package/dist/{command-DONwHpqZ.mjs → command-BwcAuPBr.mjs} +1 -1
- package/dist/{command-HW7k43qu.mjs → command-C2HYwGn_.mjs} +1 -1
- package/dist/{command-NqM0lo4a.mjs → command-CQhD3Q1t.mjs} +1 -1
- package/dist/{command-DHODgfFZ.mjs → command-D5FrTb2N.mjs} +1 -1
- package/dist/{command-D2XkyO1e.mjs → command-DoXuskBZ.mjs} +1 -1
- package/dist/{command-bwVDyMv4.mjs → command-Xqidhyr_.mjs} +1 -1
- package/dist/{command-BQbZw4Kx.mjs → command-aeKPI1bt.mjs} +1 -1
- package/dist/{command-yzqs4m83.mjs → command-b1KxgQwf.mjs} +1 -1
- package/dist/{command-DdYnSf-8.mjs → command-iwrZ2Sb1.mjs} +1 -1
- package/dist/{command-DIIaZx_f.mjs → command-n7QausoH.mjs} +1 -1
- package/dist/{command-BVct0Dvr.mjs → command-s15KaL-x.mjs} +1 -1
- package/dist/{command-CyOdBNur.mjs → command-ycXauMSv.mjs} +1 -1
- package/dist/{completions-0YKvIyBT.mjs → completions-BAUSggys.mjs} +1 -1
- package/dist/{connector-interrupts-CsunbRsr.mjs → connector-interrupts-D9tI84Fk.mjs} +1 -1
- package/dist/{connector-telemetry-events-DmQPD7xC.mjs → connector-telemetry-events-Bs9wLYwc.mjs} +1 -1
- package/dist/{connector-telemetry-snapshots-C62iHjC9.mjs → connector-telemetry-snapshots-CbwE4lrE.mjs} +1 -1
- package/dist/{connectors-Bg0MU6ZT.mjs → connectors-LyJN1htu.mjs} +1 -1
- package/dist/{containers-BiA_bpPR.mjs → containers-CKs7ZyZq.mjs} +2 -2
- package/dist/{content-scan-4SA2nacB.mjs → content-scan-BQRz7C7Z.mjs} +1 -1
- package/dist/{context-BGm5_wTT.mjs → context-DlFhI9cN.mjs} +1 -1
- package/dist/{cps-WDmD3V5I.mjs → cps-DYlXx89C.mjs} +1 -1
- package/dist/{csam-scanner-Rmy-hBEA.mjs → csam-scanner-BFANxGD-.mjs} +1 -1
- package/dist/{custom-csrs-D-lvkyRV.mjs → custom-csrs-BX4aCeof.mjs} +1 -1
- package/dist/{custom-hostnames-B5BQX5m6.mjs → custom-hostnames-BRYABKN3.mjs} +1 -1
- package/dist/{custom-nameservers-CZrRjcjx.mjs → custom-nameservers-CP1Vf1TD.mjs} +1 -1
- package/dist/{custom-pages-CWwjtfbj.mjs → custom-pages-BNL69ToU.mjs} +1 -1
- package/dist/{d1-N81q-FAr.mjs → d1-D4AZsUKn.mjs} +1 -1
- package/dist/{delegate-livNdiwK.mjs → delegate-BKlomUk6.mjs} +1 -1
- package/dist/delegate.mjs +1 -1
- package/dist/{deploy-Ok4ncy06.mjs → deploy-LbXgSfAd.mjs} +1 -1
- package/dist/{deploy-context-B_lLfxt7.mjs → deploy-context-BYw6gbl-.mjs} +9 -9
- package/dist/{deploy-input-JZlEJwKB.mjs → deploy-input-BFWpjDVr.mjs} +1 -1
- package/dist/{dev-DxbkJkzc.mjs → dev-DaFSd8WC.mjs} +1 -1
- package/dist/{diagnostics-DlJzpO8b.mjs → diagnostics-Dk3pyWx_.mjs} +1 -1
- package/dist/disk-cache-nbuwH1Dh.mjs +2 -0
- package/dist/{dist-BxhwE-W1.mjs → dist-DwxlJ9Ms.mjs} +4 -1
- package/dist/{dls-5OXuxLAB.mjs → dls-DU6EdhQK.mjs} +1 -1
- package/dist/{dns-Burep9O7.mjs → dns-3QDtCu6f.mjs} +1 -1
- package/dist/{dns-firewall-hUHaQ0DE.mjs → dns-firewall-Bbrr_0_a.mjs} +1 -1
- package/dist/{docs-BFVK88kB.mjs → docs-lLLKcLr_.mjs} +1 -1
- package/dist/{dry-run-qsnRlRk6.mjs → dry-run-mrA7FFLR.mjs} +1 -1
- package/dist/{durable-objects-D6R8S2Dk.mjs → durable-objects-DPf1DMeq.mjs} +1 -1
- package/dist/{email-auth--2KCzZNA.mjs → email-auth-DOlEoi8q.mjs} +1 -1
- package/dist/{email-routing-DzaExfVf.mjs → email-routing-D56SPGty.mjs} +1 -1
- package/dist/{email-security-DwQJszzy.mjs → email-security-CSawx0kD.mjs} +1 -1
- package/dist/{email-sending-mQd2qB-o.mjs → email-sending-CgFi0cLA.mjs} +1 -1
- package/dist/{errors-C_bGcR0X.mjs → errors-CilNjDVk.mjs} +1 -1
- package/dist/{field-extractors-MVOizTlB.mjs → field-extractors-FvIgySB4.mjs} +1 -1
- package/dist/{firewall-DtSIlkfL.mjs → firewall-BrTvywhW.mjs} +1 -1
- package/dist/{flagship-9E5gwNki.mjs → flagship-BGFN1Epo.mjs} +1 -1
- package/dist/{fraud-DjqhVJdf.mjs → fraud-DzK6OIO3.mjs} +1 -1
- package/dist/{google-tag-gateway-BM5GmCZa.mjs → google-tag-gateway-Cd9v8A7Z.mjs} +1 -1
- package/dist/{healthchecks-CEZ5f3XJ.mjs → healthchecks-Cm7EHaBA.mjs} +1 -1
- package/dist/{hyperdrive-Da8hCcUw.mjs → hyperdrive-CVaSt0qX.mjs} +1 -1
- package/dist/{iam-BK6N7NdQ.mjs → iam-CWN62Mi4.mjs} +1 -1
- package/dist/{images-3bCWE6Ml.mjs → images-Bo_pdvQC.mjs} +1 -1
- package/dist/index.mjs +1 -1
- package/dist/{init-BgCF9K8h.mjs → init-Dwmpc_S-.mjs} +1 -1
- package/dist/{intel-BQ58CJLt.mjs → intel-CQFYeGEA.mjs} +1 -1
- package/dist/{interactive-JBA3qOUa.mjs → interactive-DCbIwYxy.mjs} +1 -1
- package/dist/{internal-CWPz0sBF.mjs → internal-CYrPZ9IX.mjs} +1 -1
- package/dist/{ips-3WYegiVW.mjs → ips-jTSzoqMU.mjs} +1 -1
- package/dist/{k2-Bc_hjmiv.mjs → k2-utE2lCYd.mjs} +1 -1
- package/dist/{kv-DbShBhhg.mjs → kv-Cdh5hHte.mjs} +1 -1
- package/dist/{lazy-command-CbGyEqFK.mjs → lazy-command-QoHlmXHW.mjs} +1 -1
- package/dist/{leaked-credential-checks-DgPefxP9.mjs → leaked-credential-checks-CqApscD3.mjs} +1 -1
- package/dist/{live-BTtMv1a6.mjs → live-hZgMkXJf.mjs} +1 -1
- package/dist/{load-balancers-C2hg52WA.mjs → load-balancers-w_4Uz9Gi.mjs} +1 -1
- package/dist/login-BBSJytOt.mjs +2 -0
- package/dist/{login-DiR-buzS.mjs → login-CS3KxVbk.mjs} +2 -2
- package/dist/{logpush-CitvUX-J.mjs → logpush-C76I5dgN.mjs} +1 -1
- package/dist/{logs-CfWHu4Ir.mjs → logs-B5aCYVCv.mjs} +1 -1
- package/dist/{magic-network-monitoring-gU6yzzML.mjs → magic-network-monitoring-CGf7cVQ9.mjs} +1 -1
- package/dist/{magic-transit-B3JY9u5o.mjs → magic-transit-CN5noqOR.mjs} +1 -1
- package/dist/{managed-defense-C_EQ-NYp.mjs → managed-defense-DAGr0UGm.mjs} +1 -1
- package/dist/{managed-transforms-DIGl6JkM.mjs → managed-transforms-_SuwzZ-5.mjs} +1 -1
- package/dist/{mcp-DqhQJVaz.mjs → mcp-CzedsjOf.mjs} +1 -1
- package/dist/{mesh-DXVZBNDC.mjs → mesh-DXX1S3pX.mjs} +1 -1
- package/dist/{migrate-CmXyk9vX.mjs → migrate-CvRQ4x3_.mjs} +1 -1
- package/dist/{monetization-CWg-mySr.mjs → monetization-8nt9PYln.mjs} +1 -1
- package/dist/{network-jtgq5eb4.mjs → network-CaiRDY2e.mjs} +1 -1
- package/dist/{network-interconnects-DhfKL5tG.mjs → network-interconnects-Ad6JbAVd.mjs} +1 -1
- package/dist/{o11y-eYYs59X9.mjs → o11y-DD2Hfnzi.mjs} +1 -1
- package/dist/{oauth-BgDZMd72.mjs → oauth-BUcV_xbm.mjs} +1 -1
- package/dist/{oauth-V37G-PaV.mjs → oauth-CQRlNgt5.mjs} +1 -1
- package/dist/{observability-CB72eC4T.mjs → observability-BzKBUUSf.mjs} +1 -1
- package/dist/{ohttp-gateway-K9ToEft8.mjs → ohttp-gateway-Sej9-GCm.mjs} +1 -1
- package/dist/{organizations-BllV7l_c.mjs → organizations-DwYsCbYD.mjs} +1 -1
- package/dist/{output-hFMAotFl.mjs → output-PRKYaJuo.mjs} +1 -1
- package/dist/package-DXaRIx2f.mjs +2 -0
- package/dist/{page-rules-BVmi-ZFW.mjs → page-rules-CjufEmIt.mjs} +1 -1
- package/dist/{pages-5spcBpX1.mjs → pages-Dj0Cdf3G.mjs} +2 -2
- package/dist/{pay-per-crawl-BgsdGcBi.mjs → pay-per-crawl-DPVlluRA.mjs} +1 -1
- package/dist/{pay-per-use-CzmI1kEA.mjs → pay-per-use-DhuLjaoo.mjs} +1 -1
- package/dist/{pipelines-CbtmLRxt.mjs → pipelines-D2pM69oq.mjs} +12 -10
- package/dist/{precursor-Dk8YOKf_.mjs → precursor-DzuA1m8D.mjs} +1 -1
- package/dist/{previews-Bv1HMMtO.mjs → previews-CHHd5Rx7.mjs} +1 -1
- package/dist/{progress-DE_G09u2.mjs → progress-AML-AVs4.mjs} +1 -1
- package/dist/prompt-Bnon9lfK.mjs +4 -0
- package/dist/{queues-DGCYUr4g.mjs → queues-GDwznw0o.mjs} +1 -1
- package/dist/{r2-DtCk-Nfi.mjs → r2-B3Xkb0S4.mjs} +49 -49
- package/dist/{radar-1CwqOsMZ.mjs → radar-fBT7VIO2.mjs} +1 -1
- package/dist/{raw-fetch-DhlyWQtk.mjs → raw-fetch-0T1SwPa1.mjs} +1 -1
- package/dist/{ready-CcoEA7M7.mjs → ready-BkXNDNTd.mjs} +1 -1
- package/dist/{realtime-DFUxwIG5.mjs → realtime-B7mR3XtY.mjs} +1 -1
- package/dist/{registrar-Cl1snz8z.mjs → registrar-DOoxlZc7.mjs} +9 -9
- package/dist/{registrar-sandbox-Cne9BVCZ.mjs → registrar-sandbox-DC7xAqqc.mjs} +1 -1
- package/dist/{reporting-D9FC-Z-3.mjs → reporting-DlD7J6Pq.mjs} +1 -1
- package/dist/{request-headers-Bopp5lH_.mjs → request-headers-BEYXy4JN.mjs} +1 -1
- package/dist/{request-tracers-CSSB9_aW.mjs → request-tracers-DYCGkszp.mjs} +1 -1
- package/dist/{resource-sharing-D8yuzJm7.mjs → resource-sharing-D_bUv7E8.mjs} +1 -1
- package/dist/{rules-DzmOQ3MB.mjs → rules-C4cu3_jr.mjs} +1 -1
- package/dist/{rulesets-DsTGcgbc.mjs → rulesets-Bl4mLnXA.mjs} +1 -1
- package/dist/{rum-DrJLI93T.mjs → rum-DE_uJb09.mjs} +1 -1
- package/dist/run-Cg9utScS.mjs +2 -0
- package/dist/{run-CXWkMU3x.mjs → run-DAg7dfIW.mjs} +1 -1
- package/dist/sanitize-DHx5dAJu.mjs +2 -0
- package/dist/{schema-CfZOW8Zw.mjs → schema-BX822YfT.mjs} +1 -1
- package/dist/schema-cache-CTVUtkAl.mjs +3 -0
- package/dist/{schema-flags-DO3kLYBu.mjs → schema-flags-YgeJ6Bey.mjs} +1 -1
- package/dist/{scim-0OufLKru.mjs → scim-Dz4r0fnH.mjs} +1 -1
- package/dist/{secrets-store-BQeLzFxv.mjs → secrets-store-C2GwCUKs.mjs} +1 -1
- package/dist/{security-insights-D2pj8-O-.mjs → security-insights-DZCm5D3U.mjs} +1 -1
- package/dist/{security-txt-SKtgW4n-.mjs → security-txt-Dbi9KxNc.mjs} +1 -1
- package/dist/session-BEsQIuwP.mjs +2 -0
- package/dist/{shared-D_2KLpP3.mjs → shared-DqW2vICA.mjs} +1 -1
- package/dist/{signed-url-CcE2zQ4Y.mjs → signed-url-BhHSAUam.mjs} +1 -1
- package/dist/{smart-shield-Dod9Gs6T.mjs → smart-shield-C2uSFcGN.mjs} +1 -1
- package/dist/{snippets-DrrdpLnS.mjs → snippets-BoaGEAC6.mjs} +1 -1
- package/dist/{spawn-DNf-Ge8d.mjs → spawn-B4y5Urjv.mjs} +1 -1
- package/dist/{spectrum-CHBGZbZF.mjs → spectrum-Bb0KXA8R.mjs} +1 -1
- package/dist/{speed-vOlHyG3v.mjs → speed-zKYgLTHA.mjs} +1 -1
- package/dist/{sql-BCuLxGSf.mjs → sql-pjWozuvl.mjs} +1 -1
- package/dist/src-B8i6_XGg.mjs +133 -0
- package/dist/{ssl-BA_dcVwF.mjs → ssl-C5bg1X0i.mjs} +1 -1
- package/dist/{startup-profile-uh-F0HRS.mjs → startup-profile-CyIelqtC.mjs} +1 -1
- package/dist/startup-profile-Dif7XOsU.mjs +2 -0
- package/dist/{state-CTLznbVs.mjs → state-BI_wSuID.mjs} +1 -1
- package/dist/state-xUh3Z77T.mjs +2 -0
- package/dist/{static-assets-DGDoaJf1.mjs → static-assets-CTv7XwIQ.mjs} +3 -3
- package/dist/{stream-CzlqY8hq.mjs → stream-C_FiNrLV.mjs} +1 -1
- package/dist/string-width-D6-CGlwN.mjs +2 -0
- package/dist/{tags-BLeaslAb.mjs → tags-CXlivF3y.mjs} +1 -1
- package/dist/{telemetry-DF7A5Bpk.mjs → telemetry-CtQWhsmy.mjs} +1 -1
- package/dist/telemetry-DDs3zhdw.mjs +2 -0
- package/dist/{tenant-custom-nameservers-C5rh6jPf.mjs → tenant-custom-nameservers-DBg9Hzvn.mjs} +1 -1
- package/dist/{tenants-CRirmhxS.mjs → tenants-89Q0u5_Q.mjs} +1 -1
- package/dist/{tools-BRjRgZnj.mjs → tools-aVtEAIvu.mjs} +1 -1
- package/dist/{tunnels-nLfIWPYT.mjs → tunnels-CL2fIINH.mjs} +2 -2
- package/dist/{turnstile-CZjXtBCr.mjs → turnstile-D6GtQULo.mjs} +1 -1
- package/dist/ui-CY75N4Tm.mjs +2 -0
- package/dist/{update-check-CXMdVBhW.mjs → update-check-0kpbTLvy.mjs} +1 -1
- package/dist/{update-check-D_Oky9-u.mjs → update-check-D3axIoUi.mjs} +1 -1
- package/dist/update-check-worker.mjs +1 -1
- package/dist/{url-normalization-DTKgJHE8.mjs → url-normalization--iS57OT_.mjs} +1 -1
- package/dist/{url-scanner-9XW3zLaU.mjs → url-scanner-C6AtXGc2.mjs} +1 -1
- package/dist/{user-Bk1BIqZ5.mjs → user-C5vRYIta.mjs} +1 -1
- package/dist/{vectorize-CgOfmWYq.mjs → vectorize-C1Kxb1Ou.mjs} +1 -1
- package/dist/version-pcpa_kv3.mjs +2 -0
- package/dist/{waiting-rooms-C3nTKfK9.mjs → waiting-rooms-BCVZY9vI.mjs} +1 -1
- package/dist/{web-assets-CWU3jrit.mjs → web-assets-D2gXqKZS.mjs} +1 -1
- package/dist/{web3-CRpQ5sl4.mjs → web3-CJDZQCOk.mjs} +1 -1
- package/dist/whoami-2eFTt0-Y.mjs +2 -0
- package/dist/whoami-BEad9QUB.mjs +8 -0
- package/dist/{workers-BZMvamn0.mjs → workers-DzXSJMv9.mjs} +2 -2
- package/dist/{workers-for-platforms-C7F2ev-5.mjs → workers-for-platforms-CvazgrqD.mjs} +2 -2
- package/dist/{workers-vpc-ztEKvWmq.mjs → workers-vpc-DP4QC6UC.mjs} +1 -1
- package/dist/{workflows-Dd88_Nqc.mjs → workflows-BSOj56io.mjs} +1 -1
- package/dist/{wrangler-migration-BzMTJPdI.mjs → wrangler-migration-DZ9Oelof.mjs} +6 -3
- package/dist/{zaraz-BFK0p28R.mjs → zaraz-BnQvKXFy.mjs} +1 -1
- package/dist/{zero-trust-Cdjfp0Ie.mjs → zero-trust-DsslXRub.mjs} +1 -1
- package/dist/{zones-DDn5jk6I.mjs → zones-DQ3SjGsZ.mjs} +1 -1
- package/package.json +14 -13
- package/dist/auth-Czr8ChBB.mjs +0 -2
- package/dist/auth-Dwfa4S3h.mjs +0 -7
- package/dist/build-CCwo_ydV.mjs +0 -2
- package/dist/login-CK3nn9a5.mjs +0 -2
- package/dist/package-oNVeacC9.mjs +0 -2
- package/dist/prompt-D274Im1O.mjs +0 -4
- package/dist/run-C5yPsiO2.mjs +0 -2
- package/dist/schema-cache-CtqAs0PP.mjs +0 -3
- package/dist/session-COdP8BXD.mjs +0 -2
- package/dist/src-ByCoEqOw.mjs +0 -133
- package/dist/startup-profile-CyQk_f_L.mjs +0 -2
- package/dist/state-B6r-b_-d.mjs +0 -2
- package/dist/telemetry-COlodX5Z.mjs +0 -2
- package/dist/ui-dWsVmFCG.mjs +0 -2
- package/dist/version-CcuBNjqg.mjs +0 -2
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{r as e,t}from"./rolldown-runtime-BNtqjh-B.mjs";import{r as n}from"./chunk-U6NEESU5-DqqRCaWH.mjs";import{a as r,o as i}from"./dotenv-DKRemNCH.mjs";import{o as a}from"./autoconfig-B4tFR6ua.mjs";import{$ as o,A as s,B as c,C as l,E as u,F as d,H as f,I as p,K as m,S as h,T as g,V as _,Z as v,at as y,b,et as x,f as S,n as ee,o as C,ot as te,p as w,q as T,r as ne,u as E,x as re,y as ie}from"./dist-BxhwE-W1.mjs";import{D,M as ae,N as O,O as oe,S as se,T as ce,_ as le,a as ue,d as de,g as fe,h as pe,i as me,j as he,l as ge,m as _e,n as ve,p as ye,r as be,s as k,t as xe,v as Se,w as Ce,y as we}from"./chunk-AAQI36FL-e6E5HW1g.mjs";import{n as Te,r as Ee,t as De}from"./project-settings-D_S-UC8I.mjs";import{a as Oe,c as ke,i as Ae,o as A,r as je,s as Me,t as Ne}from"./chunk-DSGVRFIS-Cj7pO-YQ.mjs";import{t as Pe}from"./log-Brx-wjJW.mjs";import{t as Fe}from"./context-BGm5_wTT.mjs";import{t as Ie}from"./auth-token-CE3Wa5-b.mjs";import{C as Le,D as Re,E as ze,S as Be,T as Ve,_ as He,a as Ue,b as We,c as Ge,f as Ke,g as qe,i as Je,l as Ye,r as Xe,t as Ze,u as Qe,x as $e,y as et}from"./interactive-JBA3qOUa.mjs";import{C as tt,D as nt,_ as rt,a as it,c as at,g as ot,i as st,m as ct,n as lt,o as ut,r as dt,w as ft,x as pt,y as mt}from"./deploy-context-B_lLfxt7.mjs";import{c as ht}from"./build-yQOzZg6Z.mjs";import{createRequire as gt}from"node:module";import{setTimeout as _t}from"node:timers/promises";import{createReadStream as vt,mkdirSync as yt,readFileSync as bt,writeFileSync as xt}from"node:fs";import*as St from"node:path";import Ct,{extname as wt,isAbsolute as Tt,resolve as Et,sep as Dt}from"node:path";import Ot,{URLSearchParams as kt}from"node:url";import*as At from"node:fs/promises";import{access as jt,readFile as Mt,readdir as Nt,stat as Pt,writeFile as Ft}from"node:fs/promises";import j from"node:assert";import{TextDecoder as It,isDeepStrictEqual as Lt}from"node:util";import{Blob as Rt}from"node:buffer";import{gzipSync as zt}from"node:zlib";import{createHash as Bt}from"node:crypto";import{execSync as Vt}from"node:child_process";import Ht from"node:readline";import{BUILD_OUTPUT_ROOT as Ut,cleanBuildOutputDir as Wt,writeAssets as Gt,writeRootConfig as Kt,writeWorkerConfig as qt}from"@cloudflare/build-output-utils";import{hash as Jt}from"blake3-wasm";import{InputSettingsSchema as Yt,InputWorkerSchema as Xt,convertToWranglerConfig as Zt,loadAndParseConfig as Qt}from"@cloudflare/config";gt(import.meta.url||(typeof __filename==`string`?__filename:`/`));function $t(e=`2000-01-01`,t){let{hasNodejsAlsFlag:n,hasNodejsCompatFlag:r,hasNoNodejsCompatFlag:i,hasNodejsCompatV2Flag:o,hasNoNodejsCompatV2Flag:s,hasExperimentalNodejsCompatV2Flag:c}=en(t),{isNodejsCompatEnabled:l,isNodejsCompatV2Enabled:u}=a(e,t),d=null;return u?d=`v2`:l?d=`v1`:n&&(d=`als`),{mode:d,isNodejsCompatEnabled:l,isNodejsCompatV2Enabled:u,hasNodejsAlsFlag:n,hasNodejsCompatFlag:r,hasNoNodejsCompatFlag:i,hasNodejsCompatV2Flag:o,hasNoNodejsCompatV2Flag:s,hasExperimentalNodejsCompatV2Flag:c}}n($t,`getNodeCompat`);function en(e){return{hasNodejsAlsFlag:e.includes(`nodejs_als`),hasNodejsCompatFlag:e.includes(`nodejs_compat`),hasNoNodejsCompatFlag:e.includes(`no_nodejs_compat`),hasNodejsCompatV2Flag:e.includes(`nodejs_compat_v2`),hasNoNodejsCompatV2Flag:e.includes(`no_nodejs_compat_v2`),hasExperimentalNodejsCompatV2Flag:e.includes(`experimental:nodejs_compat_v2`)}}n(en,`parseNodeCompatibilityFlags`),gt(import.meta.url||(typeof __filename==`string`?__filename:`/`));function tn(){let e=gt(import.meta.url||__filename),t=e.resolve(`@cspotcode/source-map-support`),n=Symbol.for,r=e.cache[t];try{return Symbol.for=e=>(j.strictEqual(e,`source-map-support/sharedData`),Symbol(e)),delete e.cache[t],e(t)}finally{Symbol.for=n,e.cache[t]=r}}n(tn,`getFreshSourceMapSupport`),gt(import.meta.url||(typeof __filename==`string`?__filename:`/`));var M,N,nn,rn,an,on,sn;function cn(e){M=e.logger,N=e.fetchResult,nn=e.fetchListResult,rn=e.fetchPagedListResult,e.fetchKVGetValue,an=e.confirm,on=e.prompt,sn=e.select}A(cn,`initDeployHelpersContext`);var ln=/* @__PURE__ */ t(((e,t)=>{var n=Object.prototype.hasOwnProperty,r=`~`;function i(){}Object.create&&(i.prototype=Object.create(null),new i().__proto__||(r=!1));function a(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function o(e,t,n,i,o){if(typeof n!=`function`)throw TypeError(`The listener must be a function`);var s=new a(n,i||e,o),c=r?r+t:t;return e._events[c]?e._events[c].fn?e._events[c]=[e._events[c],s]:e._events[c].push(s):(e._events[c]=s,e._eventsCount++),e}function s(e,t){--e._eventsCount===0?e._events=new i:delete e._events[t]}function c(){this._events=new i,this._eventsCount=0}c.prototype.eventNames=function(){var e=[],t,i;if(this._eventsCount===0)return e;for(i in t=this._events)n.call(t,i)&&e.push(r?i.slice(1):i);return Object.getOwnPropertySymbols?e.concat(Object.getOwnPropertySymbols(t)):e},c.prototype.listeners=function(e){var t=r?r+e:e,n=this._events[t];if(!n)return[];if(n.fn)return[n.fn];for(var i=0,a=n.length,o=Array(a);i<a;i++)o[i]=n[i].fn;return o},c.prototype.listenerCount=function(e){var t=r?r+e:e,n=this._events[t];return n?n.fn?1:n.length:0},c.prototype.emit=function(e,t,n,i,a,o){var s=r?r+e:e;if(!this._events[s])return!1;var c=this._events[s],l=arguments.length,u,d;if(c.fn){switch(c.once&&this.removeListener(e,c.fn,void 0,!0),l){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,t),!0;case 3:return c.fn.call(c.context,t,n),!0;case 4:return c.fn.call(c.context,t,n,i),!0;case 5:return c.fn.call(c.context,t,n,i,a),!0;case 6:return c.fn.call(c.context,t,n,i,a,o),!0}for(d=1,u=Array(l-1);d<l;d++)u[d-1]=arguments[d];c.fn.apply(c.context,u)}else{var f=c.length,p;for(d=0;d<f;d++)switch(c[d].once&&this.removeListener(e,c[d].fn,void 0,!0),l){case 1:c[d].fn.call(c[d].context);break;case 2:c[d].fn.call(c[d].context,t);break;case 3:c[d].fn.call(c[d].context,t,n);break;case 4:c[d].fn.call(c[d].context,t,n,i);break;default:if(!u)for(p=1,u=Array(l-1);p<l;p++)u[p-1]=arguments[p];c[d].fn.apply(c[d].context,u)}}return!0},c.prototype.on=function(e,t,n){return o(this,e,t,n,!1)},c.prototype.once=function(e,t,n){return o(this,e,t,n,!0)},c.prototype.removeListener=function(e,t,n,i){var a=r?r+e:e;if(!this._events[a])return this;if(!t)return s(this,a),this;var o=this._events[a];if(o.fn)o.fn!==t||i&&!o.once||n&&o.context!==n||s(this,a);else{for(var c=0,l=[],u=o.length;c<u;c++)(o[c].fn!==t||i&&!o[c].once||n&&o[c].context!==n)&&l.push(o[c]);l.length?this._events[a]=l.length===1?l[0]:l:s(this,a)}return this},c.prototype.removeAllListeners=function(e){var t;return e?(t=r?r+e:e,this._events[t]&&s(this,t)):(this._events=new i,this._eventsCount=0),this},c.prototype.off=c.prototype.removeListener,c.prototype.addListener=c.prototype.on,c.prefixed=r,c.EventEmitter=c,t!==void 0&&(t.exports=c)})),un=_(),dn=/* @__PURE__ */ e(ln(),1),fn=class e extends Error{name=`TimeoutError`;constructor(t,n){super(t,n),Error.captureStackTrace?.(this,e)}};const pn=e=>e.reason??new DOMException(`This operation was aborted.`,`AbortError`);function mn(e,t){let{milliseconds:n,fallback:r,message:i,customTimers:a={setTimeout,clearTimeout},signal:o}=t,s,c,l=new Promise((t,l)=>{if(typeof n!=`number`||Math.sign(n)!==1)throw TypeError(`Expected \`milliseconds\` to be a positive number, got \`${n}\``);if(o?.aborted){l(pn(o));return}if(o&&(c=()=>{l(pn(o))},o.addEventListener(`abort`,c,{once:!0})),e.then(t,l),n===1/0)return;let u=new fn;s=a.setTimeout.call(void 0,()=>{if(r)try{t(r())}catch(e){l(e)}else typeof e.cancel==`function`&&e.cancel(),i===!1?t():i instanceof Error?l(i):(u.message=i??`Promise timed out after ${n} milliseconds`,l(u))},n)}).finally(()=>{l.clear(),c&&o&&o.removeEventListener(`abort`,c)});return l.clear=()=>{a.clearTimeout.call(void 0,s),s=void 0},l}function hn(e,t,n){let r=0,i=e.length;for(;i>0;){let a=Math.trunc(i/2),o=r+a;n(e[o],t)<=0?(r=++o,i-=a+1):i=a}return r}var gn=class{#e=[];enqueue(e,t){let{priority:n=0,id:r}=t??{},i={priority:n,id:r,run:e};if(this.size===0||this.#e[this.size-1].priority>=n){this.#e.push(i);return}let a=hn(this.#e,i,(e,t)=>t.priority-e.priority);this.#e.splice(a,0,i)}setPriority(e,t){let n=this.#e.findIndex(t=>t.id===e);if(n===-1)throw ReferenceError(`No promise function with the id "${e}" exists in the queue.`);let[r]=this.#e.splice(n,1);this.enqueue(r.run,{priority:t,id:e})}dequeue(){return this.#e.shift()?.run}filter(e){return this.#e.filter(t=>t.priority===e.priority).map(e=>e.run)}get size(){return this.#e.length}},_n=class extends dn.default{#e;#t;#n=0;#r;#i=!1;#a=!1;#o;#s=0;#c=0;#l;#u;#d;#f;#p=0;#m;#h;#g=1n;#_=/* @__PURE__ */ new Map;timeout;constructor(e){if(super(),e={carryoverIntervalCount:!1,intervalCap:1/0,interval:0,concurrency:1/0,autoStart:!0,queueClass:gn,...e},!(typeof e.intervalCap==`number`&&e.intervalCap>=1))throw TypeError(`Expected \`intervalCap\` to be a number from 1 and up, got \`${e.intervalCap?.toString()??``}\` (${typeof e.intervalCap})`);if(e.interval===void 0||!(Number.isFinite(e.interval)&&e.interval>=0))throw TypeError(`Expected \`interval\` to be a finite number >= 0, got \`${e.interval?.toString()??``}\` (${typeof e.interval})`);if(this.#e=e.carryoverIntervalCount??e.carryoverConcurrencyCount??!1,this.#t=e.intervalCap===1/0||e.interval===0,this.#r=e.intervalCap,this.#o=e.interval,this.#d=new e.queueClass,this.#f=e.queueClass,this.concurrency=e.concurrency,e.timeout!==void 0&&!(Number.isFinite(e.timeout)&&e.timeout>0))throw TypeError(`Expected \`timeout\` to be a positive finite number, got \`${e.timeout}\` (${typeof e.timeout})`);this.timeout=e.timeout,this.#h=e.autoStart===!1,this.#M()}get#v(){return this.#t||this.#n<this.#r}get#y(){return this.#p<this.#m}#b(){this.#p--,this.#p===0&&this.emit(`pendingZero`),this.#E(),this.emit(`next`)}#x(){this.#O(),this.#D(),this.#u=void 0}get#S(){let e=Date.now();if(this.#l===void 0){let t=this.#s-e;if(t<0){if(this.#c>0){let t=e-this.#c;if(t<this.#o)return this.#C(this.#o-t),!0}this.#n=this.#e?this.#p:0}else return this.#C(t),!0}return!1}#C(e){this.#u===void 0&&(this.#u=setTimeout(()=>{this.#x()},e))}#w(){this.#l&&=(clearInterval(this.#l),void 0)}#T(){this.#u&&=(clearTimeout(this.#u),void 0)}#E(){if(this.#d.size===0)return this.#w(),this.emit(`empty`),this.#p===0&&(this.#T(),this.emit(`idle`)),!1;let e=!1;if(!this.#h){let t=!this.#S;if(this.#v&&this.#y){let n=this.#d.dequeue();this.#t||(this.#n++,this.#N()),this.emit(`active`),this.#c=Date.now(),n(),t&&this.#D(),e=!0}}return e}#D(){this.#t||this.#l!==void 0||(this.#l=setInterval(()=>{this.#O()},this.#o),this.#s=Date.now()+this.#o)}#O(){this.#n===0&&this.#p===0&&this.#l&&this.#w(),this.#n=this.#e?this.#p:0,this.#k(),this.#N()}#k(){for(;this.#E(););}get concurrency(){return this.#m}set concurrency(e){if(!(typeof e==`number`&&e>=1))throw TypeError(`Expected \`concurrency\` to be a number from 1 and up, got \`${e}\` (${typeof e})`);this.#m=e,this.#k()}async#A(e){return new Promise((t,n)=>{e.addEventListener(`abort`,()=>{n(e.reason)},{once:!0})})}setPriority(e,t){if(typeof t!=`number`||!Number.isFinite(t))throw TypeError(`Expected \`priority\` to be a finite number, got \`${t}\` (${typeof t})`);this.#d.setPriority(e,t)}async add(e,t={}){return t.id??=(this.#g++).toString(),t={timeout:this.timeout,...t},new Promise((n,r)=>{let i=Symbol(`task-${t.id}`);this.#d.enqueue(async()=>{this.#p++,this.#_.set(i,{id:t.id,priority:t.priority??0,startTime:Date.now(),timeout:t.timeout});try{try{t.signal?.throwIfAborted()}catch(e){throw this.#t||this.#n--,this.#_.delete(i),e}let r=e({signal:t.signal});t.timeout&&(r=mn(Promise.resolve(r),{milliseconds:t.timeout,message:`Task timed out after ${t.timeout}ms (queue has ${this.#p} running, ${this.#d.size} waiting)`})),t.signal&&(r=Promise.race([r,this.#A(t.signal)]));let a=await r;n(a),this.emit(`completed`,a)}catch(e){r(e),this.emit(`error`,e)}finally{this.#_.delete(i),queueMicrotask(()=>{this.#b()})}},t),this.emit(`add`),this.#E()})}async addAll(e,t){return Promise.all(e.map(async e=>this.add(e,t)))}start(){return this.#h&&(this.#h=!1,this.#k()),this}pause(){this.#h=!0}clear(){this.#d=new this.#f,this.#P()}async onEmpty(){this.#d.size!==0&&await this.#j(`empty`)}async onSizeLessThan(e){this.#d.size<e||await this.#j(`next`,()=>this.#d.size<e)}async onIdle(){(this.#p!==0||this.#d.size!==0)&&await this.#j(`idle`)}async onPendingZero(){this.#p!==0&&await this.#j(`pendingZero`)}async onRateLimit(){this.isRateLimited||await this.#j(`rateLimit`)}async onRateLimitCleared(){this.isRateLimited&&await this.#j(`rateLimitCleared`)}async onError(){return new Promise((e,t)=>{let n=e=>{this.off(`error`,n),t(e)};this.on(`error`,n)})}async#j(e,t){return new Promise(n=>{let r=()=>{(!t||t())&&(this.off(e,r),n())};this.on(e,r)})}get size(){return this.#d.size}sizeBy(e){return this.#d.filter(e).length}get pending(){return this.#p}get isPaused(){return this.#h}#M(){this.#t||(this.on(`add`,()=>{this.#d.size>0&&this.#N()}),this.on(`next`,()=>{this.#N()}))}#N(){this.#t||this.#a||(this.#a=!0,queueMicrotask(()=>{this.#a=!1,this.#P()}))}#P(){let e=this.#i,t=!this.#t&&this.#n>=this.#r&&this.#d.size>0;t!==e&&(this.#i=t,this.emit(t?`rateLimit`:`rateLimitCleared`))}get isRateLimited(){return this.#i}get isSaturated(){return this.#p===this.#m&&this.#d.size>0||this.isRateLimited&&this.#d.size>0}get runningTasks(){return[...this.#_.values()].map(e=>({...e}))}};const vn=[`B`,`kB`,`MB`,`GB`,`TB`,`PB`,`EB`,`ZB`,`YB`],yn=[`B`,`KiB`,`MiB`,`GiB`,`TiB`,`PiB`,`EiB`,`ZiB`,`YiB`],bn=[`b`,`kbit`,`Mbit`,`Gbit`,`Tbit`,`Pbit`,`Ebit`,`Zbit`,`Ybit`],xn=[`b`,`kibit`,`Mibit`,`Gibit`,`Tibit`,`Pibit`,`Eibit`,`Zibit`,`Yibit`],Sn=(e,t,n)=>{let r=e;return typeof t==`string`||Array.isArray(t)?r=e.toLocaleString(t,n):(t===!0||n!==void 0)&&(r=e.toLocaleString(void 0,n)),r};function Cn(e,t){if(!Number.isFinite(e))throw TypeError(`Expected a finite number, got ${typeof e}: ${e}`);t={bits:!1,binary:!1,space:!0,...t};let n=t.bits?t.binary?xn:bn:t.binary?yn:vn,r=t.space?` `:``;if(t.signed&&e===0)return` 0${r}${n[0]}`;let i=e<0,a=i?`-`:t.signed?`+`:``;i&&(e=-e);let o;if(t.minimumFractionDigits!==void 0&&(o={minimumFractionDigits:t.minimumFractionDigits}),t.maximumFractionDigits!==void 0&&(o={maximumFractionDigits:t.maximumFractionDigits,...o}),e<1)return a+Sn(e,t.locale,o)+r+n[0];let s=Math.min(Math.floor(t.binary?Math.log(e)/Math.log(1024):Math.log10(e)/3),n.length-1);e/=(t.binary?1024:1e3)**s,o||(e=e.toPrecision(3));let c=Sn(Number(e),t.locale,o),l=n[s];return a+c+r+l}var wn=i();gt(import.meta.url||(typeof __filename==`string`?__filename:`/`));var Tn=Ae({"../../node_modules/.pnpm/ignore@5.3.1/node_modules/ignore/index.js"(e,t){function n(e){return Array.isArray(e)?e:[e]}A(n,`makeArray`);var r=``,i=` `,a=`\\`,o=/^\s+$/,s=/(?:[^\\]|^)\\$/,c=/^\\!/,l=/^\\#/,u=/\r?\n/g,d=/^\.*\/|^\.+$/,f=`/`,p=`node-ignore`;typeof Symbol<`u`&&(p=Symbol.for(`node-ignore`));var m=p,h=/* @__PURE__ */ A((e,t,n)=>Object.defineProperty(e,t,{value:n}),`define`),g=/([0-z])-([0-z])/g,_=/* @__PURE__ */ A(()=>!1,`RETURN_FALSE`),v=/* @__PURE__ */ A(e=>e.replace(g,(e,t,n)=>t.charCodeAt(0)<=n.charCodeAt(0)?e:r),`sanitizeRange`),y=/* @__PURE__ */ A(e=>{let{length:t}=e;return e.slice(0,t-t%2)},`cleanRangeBackSlash`),b=[[/^\uFEFF/,()=>r],[/\\?\s+$/,e=>e.indexOf(`\\`)===0?i:r],[/\\\s/g,()=>i],[/[\\$.|*+(){^]/g,e=>`\\${e}`],[/(?!\\)\?/g,()=>`[^/]`],[/^\//,()=>`^`],[/\//g,()=>`\\/`],[/^\^*\\\*\\\*\\\//,()=>`^(?:.*\\/)?`],[/^(?=[^^])/,/* @__PURE__ */ A(function(){return/\/(?!$)/.test(this)?`^`:`(?:^|\\/)`},`startingReplacer`)],[/\\\/\\\*\\\*(?=\\\/|$)/g,(e,t,n)=>t+6<n.length?`(?:\\/[^\\/]+)*`:`\\/.+`],[/(^|[^\\]+)(\\\*)+(?=.+)/g,(e,t,n)=>t+n.replace(/\\\*/g,`[^\\/]*`)],[/\\\\\\(?=[$.|*+(){^])/g,()=>a],[/\\\\/g,()=>a],[/(\\)?\[([^\]/]*?)(\\*)($|\])/g,(e,t,n,r,i)=>t===a?`\\[${n}${y(r)}${i}`:i===`]`&&r.length%2==0?`[${v(n)}${r}]`:`[]`],[/(?:[^*])$/,e=>/\/$/.test(e)?`${e}$`:`${e}(?=$|\\/$)`],[/(\^|\\\/)?\\\*$/,(e,t)=>`${t?`${t}[^/]+`:`[^/]*`}(?=$|\\/$)`]],x=/* @__PURE__ */ Object.create(null),S=/* @__PURE__ */ A((e,t)=>{let n=x[e];return n||(n=b.reduce((t,n)=>t.replace(n[0],n[1].bind(e)),e),x[e]=n),t?new RegExp(n,`i`):new RegExp(n)},`makeRegex`),ee=/* @__PURE__ */ A(e=>typeof e==`string`,`isString`),C=/* @__PURE__ */ A(e=>e&&ee(e)&&!o.test(e)&&!s.test(e)&&e.indexOf(`#`)!==0,`checkPattern`),te=/* @__PURE__ */ A(e=>e.split(u),`splitPattern`),w=class{static{A(this,`IgnoreRule`)}constructor(e,t,n,r){this.origin=e,this.pattern=t,this.negative=n,this.regex=r}},T=/* @__PURE__ */ A((e,t)=>{let n=e,r=!1;e.indexOf(`!`)===0&&(r=!0,e=e.substr(1)),e=e.replace(c,`!`).replace(l,`#`);let i=S(e,t);return new w(n,e,r,i)},`createRule`),ne=/* @__PURE__ */ A((e,t)=>{throw new t(e)},`throwError`),E=/* @__PURE__ */ A((e,t,n)=>ee(e)?e?!E.isNotRelative(e)||n(`path should be a \`path.relative()\`d string, but got "${t}"`,RangeError):n(`path must not be empty`,TypeError):n(`path must be a string, but got \`${t}\``,TypeError),`checkPath`),re=/* @__PURE__ */ A(e=>d.test(e),`isNotRelative`);E.isNotRelative=re,E.convert=e=>e;var ie=class{static{A(this,`Ignore`)}constructor({ignorecase:e=!0,ignoreCase:t=e,allowRelativePaths:n=!1}={}){h(this,m,!0),this._rules=[],this._ignoreCase=t,this._allowRelativePaths=n,this._initCache()}_initCache(){this._ignoreCache=/* @__PURE__ */ Object.create(null),this._testCache=/* @__PURE__ */ Object.create(null)}_addPattern(e){if(e&&e[m])this._rules=this._rules.concat(e._rules),this._added=!0;else if(C(e)){let t=T(e,this._ignoreCase);this._added=!0,this._rules.push(t)}}add(e){return this._added=!1,n(ee(e)?te(e):e).forEach(this._addPattern,this),this._added&&this._initCache(),this}addPattern(e){return this.add(e)}_testOne(e,t){let n=!1,r=!1;return this._rules.forEach(i=>{let{negative:a}=i;r===a&&n!==r||a&&!n&&!r&&!t||i.regex.test(e)&&(n=!a,r=a)}),{ignored:n,unignored:r}}_test(e,t,n,r){let i=e&&E.convert(e);return E(i,e,this._allowRelativePaths?_:ne),this._t(i,t,n,r)}_t(e,t,n,r){if(e in t)return t[e];if(r||=e.split(f),r.pop(),!r.length)return t[e]=this._testOne(e,n);let i=this._t(r.join(f)+f,t,n,r);return t[e]=i.ignored?i:this._testOne(e,n)}ignores(e){return this._test(e,this._ignoreCache,!1).ignored}createFilter(){return e=>!this.ignores(e)}filter(e){return n(e).filter(this.createFilter())}test(e){return this._test(e,this._testCache,!0)}},D=/* @__PURE__ */ A(e=>new ie(e),`factory`);if(D.isPathValid=/* @__PURE__ */ A(e=>E(e&&E.convert(e),e,_),`isPathValid`),D.default=D,t.exports=D,typeof process<`u`&&(process.env&&process.env.IGNORE_TEST_WIN32||process.platform===`win32`)){E.convert=/* @__PURE__ */ A(e=>/^\\\\\?\\/.test(e)||/["<>|\u0000-\u001F]+/u.test(e)?e:e.replace(/\\/g,`/`),`makePosix`);let e=/^[a-z]:\//i;E.isNotRelative=t=>e.test(t)||re(t)}}}),En=Ae({"../../node_modules/.pnpm/heap@0.2.7/node_modules/heap/lib/heap.js"(e,t){(function(){var n,r,i=Math.floor,a,o,s,c,l,u,d=Math.min,f,p,m,h,g;r=/* @__PURE__ */ A(function(e,t){return e<t?-1:+(e>t)},`defaultCmp`),u=/* @__PURE__ */ A(function(e,t,n,a,o){var s;if(n??=0,o??=r,n<0)throw Error(`lo must be non-negative`);for(a??=e.length;n<a;)s=i((n+a)/2),o(t,e[s])<0?a=s:n=s+1;return[].splice.apply(e,[n,n-n].concat(t)),t},`insort`),s=/* @__PURE__ */ A(function(e,t,n){return n??=r,e.push(t),h(e,0,e.length-1,n)},`heappush`),o=/* @__PURE__ */ A(function(e,t){var n,i;return t??=r,n=e.pop(),e.length?(i=e[0],e[0]=n,g(e,0,t)):i=n,i},`heappop`),l=/* @__PURE__ */ A(function(e,t,n){var i;return n??=r,i=e[0],e[0]=t,g(e,0,n),i},`heapreplace`),c=/* @__PURE__ */ A(function(e,t,n){var i;return n??=r,e.length&&n(e[0],t)<0&&(i=[e[0],t],t=i[0],e[0]=i[1],g(e,0,n)),t},`heappushpop`),a=/* @__PURE__ */ A(function(e,t){var n,a,o,s,c,l;for(t??=r,s=function(){l=[];for(var t=0,n=i(e.length/2);0<=n?t<n:t>n;0<=n?t++:t--)l.push(t);return l}.apply(this).reverse(),c=[],a=0,o=s.length;a<o;a++)n=s[a],c.push(g(e,n,t));return c},`heapify`),m=/* @__PURE__ */ A(function(e,t,n){var i;if(n??=r,i=e.indexOf(t),i!==-1)return h(e,0,i,n),g(e,i,n)},`updateItem`),f=/* @__PURE__ */ A(function(e,t,n){var i,o,s,l,u;if(n??=r,o=e.slice(0,t),!o.length)return o;for(a(o,n),u=e.slice(t),s=0,l=u.length;s<l;s++)i=u[s],c(o,i,n);return o.sort(n).reverse()},`nlargest`),p=/* @__PURE__ */ A(function(e,t,n){var i,s,c,l,f,p,m,h,g;if(n??=r,t*10<=e.length){if(c=e.slice(0,t).sort(n),!c.length)return c;for(s=c[c.length-1],m=e.slice(t),l=0,p=m.length;l<p;l++)i=m[l],n(i,s)<0&&(u(c,i,0,null,n),c.pop(),s=c[c.length-1]);return c}for(a(e,n),g=[],f=0,h=d(t,e.length);0<=h?f<h:f>h;0<=h?++f:--f)g.push(o(e,n));return g},`nsmallest`),h=/* @__PURE__ */ A(function(e,t,n,i){var a,o,s;for(i??=r,a=e[n];n>t&&(s=n-1>>1,o=e[s],i(a,o)<0);)e[n]=o,n=s;return e[n]=a},`_siftdown`),g=/* @__PURE__ */ A(function(e,t,n){var i,a,o,s,c;for(n??=r,a=e.length,c=t,o=e[t],i=2*t+1;i<a;)s=i+1,s<a&&!(n(e[i],e[s])<0)&&(i=s),e[t]=e[i],t=i,i=2*t+1;return e[t]=o,h(e,c,t,n)},`_siftup`),n=function(){e.push=s,e.pop=o,e.replace=l,e.pushpop=c,e.heapify=a,e.updateItem=m,e.nlargest=f,e.nsmallest=p;function e(e){this.cmp=e??r,this.nodes=[]}return A(e,`Heap`),e.prototype.push=function(e){return s(this.nodes,e,this.cmp)},e.prototype.pop=function(){return o(this.nodes,this.cmp)},e.prototype.peek=function(){return this.nodes[0]},e.prototype.contains=function(e){return this.nodes.indexOf(e)!==-1},e.prototype.replace=function(e){return l(this.nodes,e,this.cmp)},e.prototype.pushpop=function(e){return c(this.nodes,e,this.cmp)},e.prototype.heapify=function(){return a(this.nodes,this.cmp)},e.prototype.updateItem=function(e){return m(this.nodes,e,this.cmp)},e.prototype.clear=function(){return this.nodes=[]},e.prototype.empty=function(){return this.nodes.length===0},e.prototype.size=function(){return this.nodes.length},e.prototype.clone=function(){var t=new e;return t.nodes=this.nodes.slice(0),t},e.prototype.toArray=function(){return this.nodes.slice(0)},e.prototype.insert=e.prototype.push,e.prototype.top=e.prototype.peek,e.prototype.front=e.prototype.peek,e.prototype.has=e.prototype.contains,e.prototype.copy=e.prototype.clone,e}(),(function(n,r){return typeof define==`function`&&define.amd?define([],r):typeof e==`object`?t.exports=r():n.Heap=r()})(this,function(){return n})}).call(e)}}),Dn=Ae({"../../node_modules/.pnpm/heap@0.2.7/node_modules/heap/index.js"(e,t){t.exports=En()}}),On=Ae({"../../node_modules/.pnpm/@ewoudenberg+difflib@0.1.0/node_modules/@ewoudenberg/difflib/lib/difflib.js"(e){(function(){var t,n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S=[].indexOf;({floor:h,max:_,min:v}=Math),n=Dn(),p=Me(`assert`),c=/* @__PURE__ */ A(function(e,t){return t?2*e/t:1},`_calculateRatio`),s=/* @__PURE__ */ A(function(e,t){var n,r,i,a,o;for([i,a]=[e.length,t.length],n=r=0,o=v(i,a);0<=o?r<o:r>o;n=0<=o?++r:--r){if(e[n]<t[n])return-1;if(e[n]>t[n])return 1}return i-a},`_arrayCmp`),f=/* @__PURE__ */ A(function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},`_has`),o=/* @__PURE__ */ A(function(e){for(var t,n=0,r=e.length;n<r;n++)if(t=e[n],t)return!0;return!1},`_any`),a=class{static{A(this,`SequenceMatcher`)}constructor(e,t=``,n=``,r=!0){this.isjunk=e,this.autojunk=r,this.a=this.b=null,this.setSeqs(t,n)}setSeqs(e,t){return this.setSeq1(e),this.setSeq2(t)}setSeq1(e){if(e!==this.a)return this.a=e,this.matchingBlocks=this.opcodes=null}setSeq2(e){if(e!==this.b)return this.b=e,this.matchingBlocks=this.opcodes=null,this.fullbcount=null,this._chainB()}_chainB(){var e=this.b,t,n,r,i,a,o,s,c,l,u,d;for(this.b2j=t=/* @__PURE__ */ new Map,r=s=0,c=e.length;s<c;r=++s)n=e[r],t.has(n)||t.set(n,[]),i=t.get(n),i.push(r);return o=/* @__PURE__ */ new Map,a=this.isjunk,a&&t.forEach(function(e,n){if(a(n))return o.set(n,!0),t.delete(n)}),d=/* @__PURE__ */ new Map,l=e.length,this.autojunk&&l>=200&&(u=h(l/100)+1,t.forEach(function(e,n){if(e.length>u)return d.set(n,!0),t.delete(n)})),this.isbjunk=function(e){return o.has(e)},this.isbpopular=function(e){return d.has(e)}}findLongestMatch(e,t,n,r){var i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x;for([i,a,o,d]=[this.a,this.b,this.b2j,this.isbjunk],[s,c,l]=[e,n,0],p={},u=g=b=e,x=t;b<=x?g<x:g>x;u=b<=x?++g:--g){for(y={},m=[],o.has(i[u])&&(m=o.get(i[u])),v=0,_=m.length;v<_;v++)if(f=m[v],!(f<n)){if(f>=r)break;h=y[f]=(p[f-1]||0)+1,h>l&&([s,c,l]=[u-h+1,f-h+1,h])}p=y}for(;s>e&&c>n&&!d(a[c-1])&&i[s-1]===a[c-1];)[s,c,l]=[s-1,c-1,l+1];for(;s+l<t&&c+l<r&&!d(a[c+l])&&i[s+l]===a[c+l];)l++;for(;s>e&&c>n&&d(a[c-1])&&i[s-1]===a[c-1];)[s,c,l]=[s-1,c-1,l+1];for(;s+l<t&&c+l<r&&d(a[c+l])&&i[s+l]===a[c+l];)l++;return[s,c,l]}getMatchingBlocks(){var e,t,n,r,i,a,o,c,l,u,d,f,p,m,h,g,_,v,y,b,x;if(this.matchingBlocks)return this.matchingBlocks;for([h,g]=[this.a.length,this.b.length],b=[[0,h,0,g]],v=[];b.length;)[t,e,r,n]=b.pop(),[i,c,d]=x=this.findLongestMatch(t,e,r,n),d&&(v.push(x),t<i&&r<c&&b.push([t,i,r,c]),i+d<e&&c+d<n&&b.push([i+d,e,c+d,n]));for(v.sort(s),a=l=f=0,y=[],m=0,_=v.length;m<_;m++)[o,u,p]=v[m],a+f===o&&l+f===u?f+=p:(f&&y.push([a,l,f]),[a,l,f]=[o,u,p]);return f&&y.push([a,l,f]),y.push([h,g,0]),this.matchingBlocks=y}getOpcodes(){var e,t,n,r,i,a,o,s,c,l;if(this.opcodes)return this.opcodes;for(r=i=0,this.opcodes=t=[],s=this.getMatchingBlocks(),a=0,o=s.length;a<o;a++)[e,n,c]=s[a],l=``,r<e&&i<n?l=`replace`:r<e?l=`delete`:i<n&&(l=`insert`),l&&t.push([l,r,e,i,n]),[r,i]=[e+c,n+c],c&&t.push([`equal`,e,r,n,i]);return t}getGroupedOpcodes(e=3){var t=this.getOpcodes(),n,r,i,a,o,s,c,l,u,d;for(t.length||(t=[[`equal`,0,1,0,1]]),t[0][0]===`equal`&&([d,i,a,o,s]=t[0],t[0]=[d,_(i,a-e),a,_(o,s-e),s]),t[t.length-1][0]===`equal`&&([d,i,a,o,s]=t[t.length-1],t[t.length-1]=[d,i,v(a,i+e),o,v(s,o+e)]),u=e+e,r=[],n=[],c=0,l=t.length;c<l;c++)[d,i,a,o,s]=t[c],d===`equal`&&a-i>u&&(n.push([d,i,v(a,i+e),o,v(s,o+e)]),r.push(n),n=[],[i,o]=[_(i,a-e),_(o,s-e)]),n.push([d,i,a,o,s]);return n.length&&(n.length!==1||n[0][0]!==`equal`)&&r.push(n),r}ratio(){var e,t,n,r=0,i=this.getMatchingBlocks();for(e=0,t=i.length;e<t;e++)n=i[e],r+=n[2];return c(r,this.a.length+this.b.length)}quickRatio(){var e,t,n,r,i,a,o,s,l,u,d;if(!this.fullbcount)for(this.fullbcount=n={},u=this.b,r=0,i=u.length;r<i;r++)t=u[r],n[t]=(n[t]||0)+1;for(n=this.fullbcount,e={},s=0,d=this.a,o=0,a=d.length;o<a;o++)t=d[o],l=f(e,t)?e[t]:n[t]||0,e[t]=l-1,l>0&&s++;return c(s,this.a.length+this.b.length)}realQuickRatio(){var e,t;return[e,t]=[this.a.length,this.b.length],c(v(e,t),e+t)}},g=/* @__PURE__ */ A(function(e,t,r=3,i=.6){var o,c,l,u,d,f,p,m,h;if(!(r>0))throw Error(`n must be > 0: (${r})`);if(!(0<=i&&i<=1))throw Error(`cutoff must be in [0.0, 1.0]: (${i})`);for(d=[],p=new a,p.setSeq2(e),o=0,c=t.length;o<c;o++)h=t[o],p.setSeq1(h),p.realQuickRatio()>=i&&p.quickRatio()>=i&&p.ratio()>=i&&d.push([p.ratio(),h]);for(d=n.nlargest(d,r,s),f=[],u=0,l=d.length;u<l;u++)[m,h]=d[u],f.push(h);return f},`getCloseMatches`),l=/* @__PURE__ */ A(function(e,t){var n,r;for([n,r]=[0,e.length];n<r&&e[n]===t;)n++;return n},`_countLeading`),t=class{static{A(this,`Differ`)}constructor(e,t){this.linejunk=e,this.charjunk=t}compare(e,t){var n,r,i,o,s=new a(this.linejunk,e,t),c,l,u,d,f,p=[],m,h=s.getOpcodes(),g;for(l=0,u=h.length;l<u;l++){switch([g,r,n,o,i]=h[l],g){case`replace`:c=this._fancyReplace(e,r,n,t,o,i);break;case`delete`:c=this._dump(`-`,e,r,n);break;case`insert`:c=this._dump(`+`,t,o,i);break;case`equal`:c=this._dump(` `,e,r,n);break;default:throw Error(`unknow tag (${g})`)}for(m=0,d=c.length;m<d;m++)f=c[m],p.push(f)}return p}_dump(e,t,n,r){var i,a,o,s,c=[];for(i=a=o=n,s=r;o<=s?a<s:a>s;i=o<=s?++a:--a)c.push(`${e} ${t[i]}`);return c}_plainReplace(e,t,n,r,i,a){var o,s,c,l,u,d,f,m,h,g;for(p(t<n&&i<a),a-i<n-t?(o=this._dump(`+`,r,i,a),g=this._dump(`-`,e,t,n)):(o=this._dump(`-`,e,t,n),g=this._dump(`+`,r,i,a)),f=[],h=[o,g],c=0,l=h.length;c<l;c++)for(s=h[c],m=0,u=s.length;m<u;m++)d=s[m],f.push(d);return f}_fancyReplace(e,t,n,r,i,o){var s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee,C,te,w,T,ne,E,re,ie,D,ae,O,oe,se,ce,le,ue,de,fe,pe,me,he,ge,_e,ve,ye,be,k,xe;for([p,x]=[.74,.75],b=new a(this.charjunk),[S,ee]=[null,null],oe=[],te=w=fe=i,pe=o;fe<=pe?w<pe:w>pe;te=fe<=pe?++w:--w)for(g=r[te],b.setSeq2(g),C=se=me=t,he=n;me<=he?se<he:se>he;C=me<=he?++se:--se)c=e[C],c===g?S===null&&([S,ee]=[C,te]):(b.setSeq1(c),b.realQuickRatio()>p&&b.quickRatio()>p&&b.ratio()>p&&([p,m,h]=[b.ratio(),C,te]));if(p<x){if(S===null){for(ge=this._plainReplace(e,t,n,r,i,o),ce=0,E=ge.length;ce<E;ce++)O=ge[ce],oe.push(O);return oe}[m,h,p]=[S,ee,1]}else S=null;for(_e=this._fancyHelper(e,t,m,r,i,h),le=0,re=_e.length;le<re;le++)O=_e[le],oe.push(O);if([s,f]=[e[m],r[h]],S===null){for(d=y=``,b.setSeqs(s,f),ve=b.getOpcodes(),ue=0,ie=ve.length;ue<ie;ue++)switch([xe,l,u,_,v]=ve[ue],[T,ne]=[u-l,v-_],xe){case`replace`:d+=Array(T+1).join(`^`),y+=Array(ne+1).join(`^`);break;case`delete`:d+=Array(T+1).join(`-`);break;case`insert`:y+=Array(ne+1).join(`+`);break;case`equal`:d+=Array(T+1).join(` `),y+=Array(ne+1).join(` `);break;default:throw Error(`unknow tag (${xe})`)}for(ye=this._qformat(s,f,d,y),de=0,D=ye.length;de<D;de++)O=ye[de],oe.push(O)}else oe.push(` `+s);for(be=this._fancyHelper(e,m+1,n,r,h+1,o),k=0,ae=be.length;k<ae;k++)O=be[k],oe.push(O);return oe}_fancyHelper(e,t,n,r,i,a){var o=[];return t<n?o=i<a?this._fancyReplace(e,t,n,r,i,a):this._dump(`-`,e,t,n):i<a&&(o=this._dump(`+`,r,i,a)),o}_qformat(e,t,n,r){var i,a=[];return i=v(l(e,` `),l(t,` `)),i=v(i,l(n.slice(0,i),` `)),i=v(i,l(r.slice(0,i),` `)),n=n.slice(i).replace(/\s+$/,``),r=r.slice(i).replace(/\s+$/,``),a.push(`- `+e),n.length&&a.push(`? ${Array(i+1).join(` `)}${n}
|
|
2
|
+
import{r as e,t}from"./rolldown-runtime-BNtqjh-B.mjs";import{r as n}from"./chunk-U6NEESU5-DqqRCaWH.mjs";import{a as r,o as i}from"./dotenv-DKRemNCH.mjs";import{o as a}from"./autoconfig-DoLQ5ct8.mjs";import{$ as o,A as s,B as c,C as l,E as u,F as d,H as f,I as p,K as m,S as h,T as g,V as _,Z as v,at as y,b,et as x,f as S,n as ee,o as C,ot as te,p as w,q as T,r as ne,u as E,x as re,y as ie}from"./dist-DwxlJ9Ms.mjs";import{D,M as ae,N as O,O as oe,S as se,T as ce,_ as le,a as ue,d as de,g as fe,h as pe,i as me,j as he,l as ge,m as _e,n as ve,p as ye,r as be,s as k,t as xe,v as Se,w as Ce,y as we}from"./chunk-AAQI36FL-e6E5HW1g.mjs";import{n as Te,r as Ee,t as De}from"./project-settings-D_S-UC8I.mjs";import{a as Oe,c as ke,i as Ae,o as A,r as je,s as Me,t as Ne}from"./chunk-DSGVRFIS-CeCM3XGQ.mjs";import{t as Pe}from"./log-Brx-wjJW.mjs";import{t as Fe}from"./context-DlFhI9cN.mjs";import{t as Ie}from"./auth-token-D9MnaZ-L.mjs";import{C as Le,D as Re,E as ze,S as Be,T as Ve,_ as He,a as Ue,b as We,c as Ge,f as Ke,g as qe,i as Je,l as Ye,r as Xe,t as Ze,u as Qe,x as $e,y as et}from"./interactive-DCbIwYxy.mjs";import{C as tt,D as nt,_ as rt,a as it,c as at,g as ot,i as st,m as ct,n as lt,o as ut,r as dt,w as ft,x as pt,y as mt}from"./deploy-context-BYw6gbl-.mjs";import{c as ht}from"./build-DiEXOgHH.mjs";import{createRequire as gt}from"node:module";import{setTimeout as _t}from"node:timers/promises";import{createReadStream as vt,mkdirSync as yt,readFileSync as bt,writeFileSync as xt}from"node:fs";import*as St from"node:path";import Ct,{extname as wt,isAbsolute as Tt,resolve as Et,sep as Dt}from"node:path";import Ot,{URLSearchParams as kt}from"node:url";import*as At from"node:fs/promises";import{access as jt,readFile as Mt,readdir as Nt,stat as Pt,writeFile as Ft}from"node:fs/promises";import j from"node:assert";import{TextDecoder as It,isDeepStrictEqual as Lt}from"node:util";import{Blob as Rt}from"node:buffer";import{gzipSync as zt}from"node:zlib";import{createHash as Bt}from"node:crypto";import{execSync as Vt}from"node:child_process";import Ht from"node:readline";import{BUILD_OUTPUT_ROOT as Ut,cleanBuildOutputDir as Wt,writeAssets as Gt,writeRootConfig as Kt,writeWorkerConfig as qt}from"@cloudflare/build-output-utils";import{hash as Jt}from"blake3-wasm";import{InputSettingsSchema as Yt,InputWorkerSchema as Xt,convertToWranglerConfig as Zt,loadAndParseConfig as Qt}from"@cloudflare/config";gt(import.meta.url||(typeof __filename==`string`?__filename:`/`));function $t(e=`2000-01-01`,t){let{hasNodejsAlsFlag:n,hasNodejsCompatFlag:r,hasNoNodejsCompatFlag:i,hasNodejsCompatV2Flag:o,hasNoNodejsCompatV2Flag:s,hasExperimentalNodejsCompatV2Flag:c}=en(t),{isNodejsCompatEnabled:l,isNodejsCompatV2Enabled:u}=a(e,t),d=null;return u?d=`v2`:l?d=`v1`:n&&(d=`als`),{mode:d,isNodejsCompatEnabled:l,isNodejsCompatV2Enabled:u,hasNodejsAlsFlag:n,hasNodejsCompatFlag:r,hasNoNodejsCompatFlag:i,hasNodejsCompatV2Flag:o,hasNoNodejsCompatV2Flag:s,hasExperimentalNodejsCompatV2Flag:c}}n($t,`getNodeCompat`);function en(e){return{hasNodejsAlsFlag:e.includes(`nodejs_als`),hasNodejsCompatFlag:e.includes(`nodejs_compat`),hasNoNodejsCompatFlag:e.includes(`no_nodejs_compat`),hasNodejsCompatV2Flag:e.includes(`nodejs_compat_v2`),hasNoNodejsCompatV2Flag:e.includes(`no_nodejs_compat_v2`),hasExperimentalNodejsCompatV2Flag:e.includes(`experimental:nodejs_compat_v2`)}}n(en,`parseNodeCompatibilityFlags`),gt(import.meta.url||(typeof __filename==`string`?__filename:`/`));function tn(){let e=gt(import.meta.url||__filename),t=e.resolve(`@cspotcode/source-map-support`),n=Symbol.for,r=e.cache[t];try{return Symbol.for=e=>(j.strictEqual(e,`source-map-support/sharedData`),Symbol(e)),delete e.cache[t],e(t)}finally{Symbol.for=n,e.cache[t]=r}}n(tn,`getFreshSourceMapSupport`),gt(import.meta.url||(typeof __filename==`string`?__filename:`/`));var M,N,nn,rn,an,on,sn;function cn(e){M=e.logger,N=e.fetchResult,nn=e.fetchListResult,rn=e.fetchPagedListResult,e.fetchKVGetValue,an=e.confirm,on=e.prompt,sn=e.select}A(cn,`initDeployHelpersContext`);var ln=/* @__PURE__ */ t(((e,t)=>{var n=Object.prototype.hasOwnProperty,r=`~`;function i(){}Object.create&&(i.prototype=Object.create(null),new i().__proto__||(r=!1));function a(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function o(e,t,n,i,o){if(typeof n!=`function`)throw TypeError(`The listener must be a function`);var s=new a(n,i||e,o),c=r?r+t:t;return e._events[c]?e._events[c].fn?e._events[c]=[e._events[c],s]:e._events[c].push(s):(e._events[c]=s,e._eventsCount++),e}function s(e,t){--e._eventsCount===0?e._events=new i:delete e._events[t]}function c(){this._events=new i,this._eventsCount=0}c.prototype.eventNames=function(){var e=[],t,i;if(this._eventsCount===0)return e;for(i in t=this._events)n.call(t,i)&&e.push(r?i.slice(1):i);return Object.getOwnPropertySymbols?e.concat(Object.getOwnPropertySymbols(t)):e},c.prototype.listeners=function(e){var t=r?r+e:e,n=this._events[t];if(!n)return[];if(n.fn)return[n.fn];for(var i=0,a=n.length,o=Array(a);i<a;i++)o[i]=n[i].fn;return o},c.prototype.listenerCount=function(e){var t=r?r+e:e,n=this._events[t];return n?n.fn?1:n.length:0},c.prototype.emit=function(e,t,n,i,a,o){var s=r?r+e:e;if(!this._events[s])return!1;var c=this._events[s],l=arguments.length,u,d;if(c.fn){switch(c.once&&this.removeListener(e,c.fn,void 0,!0),l){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,t),!0;case 3:return c.fn.call(c.context,t,n),!0;case 4:return c.fn.call(c.context,t,n,i),!0;case 5:return c.fn.call(c.context,t,n,i,a),!0;case 6:return c.fn.call(c.context,t,n,i,a,o),!0}for(d=1,u=Array(l-1);d<l;d++)u[d-1]=arguments[d];c.fn.apply(c.context,u)}else{var f=c.length,p;for(d=0;d<f;d++)switch(c[d].once&&this.removeListener(e,c[d].fn,void 0,!0),l){case 1:c[d].fn.call(c[d].context);break;case 2:c[d].fn.call(c[d].context,t);break;case 3:c[d].fn.call(c[d].context,t,n);break;case 4:c[d].fn.call(c[d].context,t,n,i);break;default:if(!u)for(p=1,u=Array(l-1);p<l;p++)u[p-1]=arguments[p];c[d].fn.apply(c[d].context,u)}}return!0},c.prototype.on=function(e,t,n){return o(this,e,t,n,!1)},c.prototype.once=function(e,t,n){return o(this,e,t,n,!0)},c.prototype.removeListener=function(e,t,n,i){var a=r?r+e:e;if(!this._events[a])return this;if(!t)return s(this,a),this;var o=this._events[a];if(o.fn)o.fn!==t||i&&!o.once||n&&o.context!==n||s(this,a);else{for(var c=0,l=[],u=o.length;c<u;c++)(o[c].fn!==t||i&&!o[c].once||n&&o[c].context!==n)&&l.push(o[c]);l.length?this._events[a]=l.length===1?l[0]:l:s(this,a)}return this},c.prototype.removeAllListeners=function(e){var t;return e?(t=r?r+e:e,this._events[t]&&s(this,t)):(this._events=new i,this._eventsCount=0),this},c.prototype.off=c.prototype.removeListener,c.prototype.addListener=c.prototype.on,c.prefixed=r,c.EventEmitter=c,t!==void 0&&(t.exports=c)})),un=_(),dn=/* @__PURE__ */ e(ln(),1),fn=class e extends Error{name=`TimeoutError`;constructor(t,n){super(t,n),Error.captureStackTrace?.(this,e)}};const pn=e=>e.reason??new DOMException(`This operation was aborted.`,`AbortError`);function mn(e,t){let{milliseconds:n,fallback:r,message:i,customTimers:a={setTimeout,clearTimeout},signal:o}=t,s,c,l=new Promise((t,l)=>{if(typeof n!=`number`||Math.sign(n)!==1)throw TypeError(`Expected \`milliseconds\` to be a positive number, got \`${n}\``);if(o?.aborted){l(pn(o));return}if(o&&(c=()=>{l(pn(o))},o.addEventListener(`abort`,c,{once:!0})),e.then(t,l),n===1/0)return;let u=new fn;s=a.setTimeout.call(void 0,()=>{if(r)try{t(r())}catch(e){l(e)}else typeof e.cancel==`function`&&e.cancel(),i===!1?t():i instanceof Error?l(i):(u.message=i??`Promise timed out after ${n} milliseconds`,l(u))},n)}).finally(()=>{l.clear(),c&&o&&o.removeEventListener(`abort`,c)});return l.clear=()=>{a.clearTimeout.call(void 0,s),s=void 0},l}function hn(e,t,n){let r=0,i=e.length;for(;i>0;){let a=Math.trunc(i/2),o=r+a;n(e[o],t)<=0?(r=++o,i-=a+1):i=a}return r}var gn=class{#e=[];enqueue(e,t){let{priority:n=0,id:r}=t??{},i={priority:n,id:r,run:e};if(this.size===0||this.#e[this.size-1].priority>=n){this.#e.push(i);return}let a=hn(this.#e,i,(e,t)=>t.priority-e.priority);this.#e.splice(a,0,i)}setPriority(e,t){let n=this.#e.findIndex(t=>t.id===e);if(n===-1)throw ReferenceError(`No promise function with the id "${e}" exists in the queue.`);let[r]=this.#e.splice(n,1);this.enqueue(r.run,{priority:t,id:e})}dequeue(){return this.#e.shift()?.run}filter(e){return this.#e.filter(t=>t.priority===e.priority).map(e=>e.run)}get size(){return this.#e.length}},_n=class extends dn.default{#e;#t;#n=0;#r;#i=!1;#a=!1;#o;#s=0;#c=0;#l;#u;#d;#f;#p=0;#m;#h;#g=1n;#_=/* @__PURE__ */ new Map;timeout;constructor(e){if(super(),e={carryoverIntervalCount:!1,intervalCap:1/0,interval:0,concurrency:1/0,autoStart:!0,queueClass:gn,...e},!(typeof e.intervalCap==`number`&&e.intervalCap>=1))throw TypeError(`Expected \`intervalCap\` to be a number from 1 and up, got \`${e.intervalCap?.toString()??``}\` (${typeof e.intervalCap})`);if(e.interval===void 0||!(Number.isFinite(e.interval)&&e.interval>=0))throw TypeError(`Expected \`interval\` to be a finite number >= 0, got \`${e.interval?.toString()??``}\` (${typeof e.interval})`);if(this.#e=e.carryoverIntervalCount??e.carryoverConcurrencyCount??!1,this.#t=e.intervalCap===1/0||e.interval===0,this.#r=e.intervalCap,this.#o=e.interval,this.#d=new e.queueClass,this.#f=e.queueClass,this.concurrency=e.concurrency,e.timeout!==void 0&&!(Number.isFinite(e.timeout)&&e.timeout>0))throw TypeError(`Expected \`timeout\` to be a positive finite number, got \`${e.timeout}\` (${typeof e.timeout})`);this.timeout=e.timeout,this.#h=e.autoStart===!1,this.#M()}get#v(){return this.#t||this.#n<this.#r}get#y(){return this.#p<this.#m}#b(){this.#p--,this.#p===0&&this.emit(`pendingZero`),this.#E(),this.emit(`next`)}#x(){this.#O(),this.#D(),this.#u=void 0}get#S(){let e=Date.now();if(this.#l===void 0){let t=this.#s-e;if(t<0){if(this.#c>0){let t=e-this.#c;if(t<this.#o)return this.#C(this.#o-t),!0}this.#n=this.#e?this.#p:0}else return this.#C(t),!0}return!1}#C(e){this.#u===void 0&&(this.#u=setTimeout(()=>{this.#x()},e))}#w(){this.#l&&=(clearInterval(this.#l),void 0)}#T(){this.#u&&=(clearTimeout(this.#u),void 0)}#E(){if(this.#d.size===0)return this.#w(),this.emit(`empty`),this.#p===0&&(this.#T(),this.emit(`idle`)),!1;let e=!1;if(!this.#h){let t=!this.#S;if(this.#v&&this.#y){let n=this.#d.dequeue();this.#t||(this.#n++,this.#N()),this.emit(`active`),this.#c=Date.now(),n(),t&&this.#D(),e=!0}}return e}#D(){this.#t||this.#l!==void 0||(this.#l=setInterval(()=>{this.#O()},this.#o),this.#s=Date.now()+this.#o)}#O(){this.#n===0&&this.#p===0&&this.#l&&this.#w(),this.#n=this.#e?this.#p:0,this.#k(),this.#N()}#k(){for(;this.#E(););}get concurrency(){return this.#m}set concurrency(e){if(!(typeof e==`number`&&e>=1))throw TypeError(`Expected \`concurrency\` to be a number from 1 and up, got \`${e}\` (${typeof e})`);this.#m=e,this.#k()}async#A(e){return new Promise((t,n)=>{e.addEventListener(`abort`,()=>{n(e.reason)},{once:!0})})}setPriority(e,t){if(typeof t!=`number`||!Number.isFinite(t))throw TypeError(`Expected \`priority\` to be a finite number, got \`${t}\` (${typeof t})`);this.#d.setPriority(e,t)}async add(e,t={}){return t.id??=(this.#g++).toString(),t={timeout:this.timeout,...t},new Promise((n,r)=>{let i=Symbol(`task-${t.id}`);this.#d.enqueue(async()=>{this.#p++,this.#_.set(i,{id:t.id,priority:t.priority??0,startTime:Date.now(),timeout:t.timeout});try{try{t.signal?.throwIfAborted()}catch(e){throw this.#t||this.#n--,this.#_.delete(i),e}let r=e({signal:t.signal});t.timeout&&(r=mn(Promise.resolve(r),{milliseconds:t.timeout,message:`Task timed out after ${t.timeout}ms (queue has ${this.#p} running, ${this.#d.size} waiting)`})),t.signal&&(r=Promise.race([r,this.#A(t.signal)]));let a=await r;n(a),this.emit(`completed`,a)}catch(e){r(e),this.emit(`error`,e)}finally{this.#_.delete(i),queueMicrotask(()=>{this.#b()})}},t),this.emit(`add`),this.#E()})}async addAll(e,t){return Promise.all(e.map(async e=>this.add(e,t)))}start(){return this.#h&&(this.#h=!1,this.#k()),this}pause(){this.#h=!0}clear(){this.#d=new this.#f,this.#P()}async onEmpty(){this.#d.size!==0&&await this.#j(`empty`)}async onSizeLessThan(e){this.#d.size<e||await this.#j(`next`,()=>this.#d.size<e)}async onIdle(){(this.#p!==0||this.#d.size!==0)&&await this.#j(`idle`)}async onPendingZero(){this.#p!==0&&await this.#j(`pendingZero`)}async onRateLimit(){this.isRateLimited||await this.#j(`rateLimit`)}async onRateLimitCleared(){this.isRateLimited&&await this.#j(`rateLimitCleared`)}async onError(){return new Promise((e,t)=>{let n=e=>{this.off(`error`,n),t(e)};this.on(`error`,n)})}async#j(e,t){return new Promise(n=>{let r=()=>{(!t||t())&&(this.off(e,r),n())};this.on(e,r)})}get size(){return this.#d.size}sizeBy(e){return this.#d.filter(e).length}get pending(){return this.#p}get isPaused(){return this.#h}#M(){this.#t||(this.on(`add`,()=>{this.#d.size>0&&this.#N()}),this.on(`next`,()=>{this.#N()}))}#N(){this.#t||this.#a||(this.#a=!0,queueMicrotask(()=>{this.#a=!1,this.#P()}))}#P(){let e=this.#i,t=!this.#t&&this.#n>=this.#r&&this.#d.size>0;t!==e&&(this.#i=t,this.emit(t?`rateLimit`:`rateLimitCleared`))}get isRateLimited(){return this.#i}get isSaturated(){return this.#p===this.#m&&this.#d.size>0||this.isRateLimited&&this.#d.size>0}get runningTasks(){return[...this.#_.values()].map(e=>({...e}))}};const vn=[`B`,`kB`,`MB`,`GB`,`TB`,`PB`,`EB`,`ZB`,`YB`],yn=[`B`,`KiB`,`MiB`,`GiB`,`TiB`,`PiB`,`EiB`,`ZiB`,`YiB`],bn=[`b`,`kbit`,`Mbit`,`Gbit`,`Tbit`,`Pbit`,`Ebit`,`Zbit`,`Ybit`],xn=[`b`,`kibit`,`Mibit`,`Gibit`,`Tibit`,`Pibit`,`Eibit`,`Zibit`,`Yibit`],Sn=(e,t,n)=>{let r=e;return typeof t==`string`||Array.isArray(t)?r=e.toLocaleString(t,n):(t===!0||n!==void 0)&&(r=e.toLocaleString(void 0,n)),r};function Cn(e,t){if(!Number.isFinite(e))throw TypeError(`Expected a finite number, got ${typeof e}: ${e}`);t={bits:!1,binary:!1,space:!0,...t};let n=t.bits?t.binary?xn:bn:t.binary?yn:vn,r=t.space?` `:``;if(t.signed&&e===0)return` 0${r}${n[0]}`;let i=e<0,a=i?`-`:t.signed?`+`:``;i&&(e=-e);let o;if(t.minimumFractionDigits!==void 0&&(o={minimumFractionDigits:t.minimumFractionDigits}),t.maximumFractionDigits!==void 0&&(o={maximumFractionDigits:t.maximumFractionDigits,...o}),e<1)return a+Sn(e,t.locale,o)+r+n[0];let s=Math.min(Math.floor(t.binary?Math.log(e)/Math.log(1024):Math.log10(e)/3),n.length-1);e/=(t.binary?1024:1e3)**s,o||(e=e.toPrecision(3));let c=Sn(Number(e),t.locale,o),l=n[s];return a+c+r+l}var wn=i();gt(import.meta.url||(typeof __filename==`string`?__filename:`/`));var Tn=Ae({"../../node_modules/.pnpm/ignore@5.3.1/node_modules/ignore/index.js"(e,t){function n(e){return Array.isArray(e)?e:[e]}A(n,`makeArray`);var r=``,i=` `,a=`\\`,o=/^\s+$/,s=/(?:[^\\]|^)\\$/,c=/^\\!/,l=/^\\#/,u=/\r?\n/g,d=/^\.*\/|^\.+$/,f=`/`,p=`node-ignore`;typeof Symbol<`u`&&(p=Symbol.for(`node-ignore`));var m=p,h=/* @__PURE__ */ A((e,t,n)=>Object.defineProperty(e,t,{value:n}),`define`),g=/([0-z])-([0-z])/g,_=/* @__PURE__ */ A(()=>!1,`RETURN_FALSE`),v=/* @__PURE__ */ A(e=>e.replace(g,(e,t,n)=>t.charCodeAt(0)<=n.charCodeAt(0)?e:r),`sanitizeRange`),y=/* @__PURE__ */ A(e=>{let{length:t}=e;return e.slice(0,t-t%2)},`cleanRangeBackSlash`),b=[[/^\uFEFF/,()=>r],[/\\?\s+$/,e=>e.indexOf(`\\`)===0?i:r],[/\\\s/g,()=>i],[/[\\$.|*+(){^]/g,e=>`\\${e}`],[/(?!\\)\?/g,()=>`[^/]`],[/^\//,()=>`^`],[/\//g,()=>`\\/`],[/^\^*\\\*\\\*\\\//,()=>`^(?:.*\\/)?`],[/^(?=[^^])/,/* @__PURE__ */ A(function(){return/\/(?!$)/.test(this)?`^`:`(?:^|\\/)`},`startingReplacer`)],[/\\\/\\\*\\\*(?=\\\/|$)/g,(e,t,n)=>t+6<n.length?`(?:\\/[^\\/]+)*`:`\\/.+`],[/(^|[^\\]+)(\\\*)+(?=.+)/g,(e,t,n)=>t+n.replace(/\\\*/g,`[^\\/]*`)],[/\\\\\\(?=[$.|*+(){^])/g,()=>a],[/\\\\/g,()=>a],[/(\\)?\[([^\]/]*?)(\\*)($|\])/g,(e,t,n,r,i)=>t===a?`\\[${n}${y(r)}${i}`:i===`]`&&r.length%2==0?`[${v(n)}${r}]`:`[]`],[/(?:[^*])$/,e=>/\/$/.test(e)?`${e}$`:`${e}(?=$|\\/$)`],[/(\^|\\\/)?\\\*$/,(e,t)=>`${t?`${t}[^/]+`:`[^/]*`}(?=$|\\/$)`]],x=/* @__PURE__ */ Object.create(null),S=/* @__PURE__ */ A((e,t)=>{let n=x[e];return n||(n=b.reduce((t,n)=>t.replace(n[0],n[1].bind(e)),e),x[e]=n),t?new RegExp(n,`i`):new RegExp(n)},`makeRegex`),ee=/* @__PURE__ */ A(e=>typeof e==`string`,`isString`),C=/* @__PURE__ */ A(e=>e&&ee(e)&&!o.test(e)&&!s.test(e)&&e.indexOf(`#`)!==0,`checkPattern`),te=/* @__PURE__ */ A(e=>e.split(u),`splitPattern`),w=class{static{A(this,`IgnoreRule`)}constructor(e,t,n,r){this.origin=e,this.pattern=t,this.negative=n,this.regex=r}},T=/* @__PURE__ */ A((e,t)=>{let n=e,r=!1;e.indexOf(`!`)===0&&(r=!0,e=e.substr(1)),e=e.replace(c,`!`).replace(l,`#`);let i=S(e,t);return new w(n,e,r,i)},`createRule`),ne=/* @__PURE__ */ A((e,t)=>{throw new t(e)},`throwError`),E=/* @__PURE__ */ A((e,t,n)=>ee(e)?e?!E.isNotRelative(e)||n(`path should be a \`path.relative()\`d string, but got "${t}"`,RangeError):n(`path must not be empty`,TypeError):n(`path must be a string, but got \`${t}\``,TypeError),`checkPath`),re=/* @__PURE__ */ A(e=>d.test(e),`isNotRelative`);E.isNotRelative=re,E.convert=e=>e;var ie=class{static{A(this,`Ignore`)}constructor({ignorecase:e=!0,ignoreCase:t=e,allowRelativePaths:n=!1}={}){h(this,m,!0),this._rules=[],this._ignoreCase=t,this._allowRelativePaths=n,this._initCache()}_initCache(){this._ignoreCache=/* @__PURE__ */ Object.create(null),this._testCache=/* @__PURE__ */ Object.create(null)}_addPattern(e){if(e&&e[m])this._rules=this._rules.concat(e._rules),this._added=!0;else if(C(e)){let t=T(e,this._ignoreCase);this._added=!0,this._rules.push(t)}}add(e){return this._added=!1,n(ee(e)?te(e):e).forEach(this._addPattern,this),this._added&&this._initCache(),this}addPattern(e){return this.add(e)}_testOne(e,t){let n=!1,r=!1;return this._rules.forEach(i=>{let{negative:a}=i;r===a&&n!==r||a&&!n&&!r&&!t||i.regex.test(e)&&(n=!a,r=a)}),{ignored:n,unignored:r}}_test(e,t,n,r){let i=e&&E.convert(e);return E(i,e,this._allowRelativePaths?_:ne),this._t(i,t,n,r)}_t(e,t,n,r){if(e in t)return t[e];if(r||=e.split(f),r.pop(),!r.length)return t[e]=this._testOne(e,n);let i=this._t(r.join(f)+f,t,n,r);return t[e]=i.ignored?i:this._testOne(e,n)}ignores(e){return this._test(e,this._ignoreCache,!1).ignored}createFilter(){return e=>!this.ignores(e)}filter(e){return n(e).filter(this.createFilter())}test(e){return this._test(e,this._testCache,!0)}},D=/* @__PURE__ */ A(e=>new ie(e),`factory`);if(D.isPathValid=/* @__PURE__ */ A(e=>E(e&&E.convert(e),e,_),`isPathValid`),D.default=D,t.exports=D,typeof process<`u`&&(process.env&&process.env.IGNORE_TEST_WIN32||process.platform===`win32`)){E.convert=/* @__PURE__ */ A(e=>/^\\\\\?\\/.test(e)||/["<>|\u0000-\u001F]+/u.test(e)?e:e.replace(/\\/g,`/`),`makePosix`);let e=/^[a-z]:\//i;E.isNotRelative=t=>e.test(t)||re(t)}}}),En=Ae({"../../node_modules/.pnpm/heap@0.2.7/node_modules/heap/lib/heap.js"(e,t){(function(){var n,r,i=Math.floor,a,o,s,c,l,u,d=Math.min,f,p,m,h,g;r=/* @__PURE__ */ A(function(e,t){return e<t?-1:+(e>t)},`defaultCmp`),u=/* @__PURE__ */ A(function(e,t,n,a,o){var s;if(n??=0,o??=r,n<0)throw Error(`lo must be non-negative`);for(a??=e.length;n<a;)s=i((n+a)/2),o(t,e[s])<0?a=s:n=s+1;return[].splice.apply(e,[n,n-n].concat(t)),t},`insort`),s=/* @__PURE__ */ A(function(e,t,n){return n??=r,e.push(t),h(e,0,e.length-1,n)},`heappush`),o=/* @__PURE__ */ A(function(e,t){var n,i;return t??=r,n=e.pop(),e.length?(i=e[0],e[0]=n,g(e,0,t)):i=n,i},`heappop`),l=/* @__PURE__ */ A(function(e,t,n){var i;return n??=r,i=e[0],e[0]=t,g(e,0,n),i},`heapreplace`),c=/* @__PURE__ */ A(function(e,t,n){var i;return n??=r,e.length&&n(e[0],t)<0&&(i=[e[0],t],t=i[0],e[0]=i[1],g(e,0,n)),t},`heappushpop`),a=/* @__PURE__ */ A(function(e,t){var n,a,o,s,c,l;for(t??=r,s=function(){l=[];for(var t=0,n=i(e.length/2);0<=n?t<n:t>n;0<=n?t++:t--)l.push(t);return l}.apply(this).reverse(),c=[],a=0,o=s.length;a<o;a++)n=s[a],c.push(g(e,n,t));return c},`heapify`),m=/* @__PURE__ */ A(function(e,t,n){var i;if(n??=r,i=e.indexOf(t),i!==-1)return h(e,0,i,n),g(e,i,n)},`updateItem`),f=/* @__PURE__ */ A(function(e,t,n){var i,o,s,l,u;if(n??=r,o=e.slice(0,t),!o.length)return o;for(a(o,n),u=e.slice(t),s=0,l=u.length;s<l;s++)i=u[s],c(o,i,n);return o.sort(n).reverse()},`nlargest`),p=/* @__PURE__ */ A(function(e,t,n){var i,s,c,l,f,p,m,h,g;if(n??=r,t*10<=e.length){if(c=e.slice(0,t).sort(n),!c.length)return c;for(s=c[c.length-1],m=e.slice(t),l=0,p=m.length;l<p;l++)i=m[l],n(i,s)<0&&(u(c,i,0,null,n),c.pop(),s=c[c.length-1]);return c}for(a(e,n),g=[],f=0,h=d(t,e.length);0<=h?f<h:f>h;0<=h?++f:--f)g.push(o(e,n));return g},`nsmallest`),h=/* @__PURE__ */ A(function(e,t,n,i){var a,o,s;for(i??=r,a=e[n];n>t&&(s=n-1>>1,o=e[s],i(a,o)<0);)e[n]=o,n=s;return e[n]=a},`_siftdown`),g=/* @__PURE__ */ A(function(e,t,n){var i,a,o,s,c;for(n??=r,a=e.length,c=t,o=e[t],i=2*t+1;i<a;)s=i+1,s<a&&!(n(e[i],e[s])<0)&&(i=s),e[t]=e[i],t=i,i=2*t+1;return e[t]=o,h(e,c,t,n)},`_siftup`),n=function(){e.push=s,e.pop=o,e.replace=l,e.pushpop=c,e.heapify=a,e.updateItem=m,e.nlargest=f,e.nsmallest=p;function e(e){this.cmp=e??r,this.nodes=[]}return A(e,`Heap`),e.prototype.push=function(e){return s(this.nodes,e,this.cmp)},e.prototype.pop=function(){return o(this.nodes,this.cmp)},e.prototype.peek=function(){return this.nodes[0]},e.prototype.contains=function(e){return this.nodes.indexOf(e)!==-1},e.prototype.replace=function(e){return l(this.nodes,e,this.cmp)},e.prototype.pushpop=function(e){return c(this.nodes,e,this.cmp)},e.prototype.heapify=function(){return a(this.nodes,this.cmp)},e.prototype.updateItem=function(e){return m(this.nodes,e,this.cmp)},e.prototype.clear=function(){return this.nodes=[]},e.prototype.empty=function(){return this.nodes.length===0},e.prototype.size=function(){return this.nodes.length},e.prototype.clone=function(){var t=new e;return t.nodes=this.nodes.slice(0),t},e.prototype.toArray=function(){return this.nodes.slice(0)},e.prototype.insert=e.prototype.push,e.prototype.top=e.prototype.peek,e.prototype.front=e.prototype.peek,e.prototype.has=e.prototype.contains,e.prototype.copy=e.prototype.clone,e}(),(function(n,r){return typeof define==`function`&&define.amd?define([],r):typeof e==`object`?t.exports=r():n.Heap=r()})(this,function(){return n})}).call(e)}}),Dn=Ae({"../../node_modules/.pnpm/heap@0.2.7/node_modules/heap/index.js"(e,t){t.exports=En()}}),On=Ae({"../../node_modules/.pnpm/@ewoudenberg+difflib@0.1.0/node_modules/@ewoudenberg/difflib/lib/difflib.js"(e){(function(){var t,n,r,i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S=[].indexOf;({floor:h,max:_,min:v}=Math),n=Dn(),p=Me(`assert`),c=/* @__PURE__ */ A(function(e,t){return t?2*e/t:1},`_calculateRatio`),s=/* @__PURE__ */ A(function(e,t){var n,r,i,a,o;for([i,a]=[e.length,t.length],n=r=0,o=v(i,a);0<=o?r<o:r>o;n=0<=o?++r:--r){if(e[n]<t[n])return-1;if(e[n]>t[n])return 1}return i-a},`_arrayCmp`),f=/* @__PURE__ */ A(function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},`_has`),o=/* @__PURE__ */ A(function(e){for(var t,n=0,r=e.length;n<r;n++)if(t=e[n],t)return!0;return!1},`_any`),a=class{static{A(this,`SequenceMatcher`)}constructor(e,t=``,n=``,r=!0){this.isjunk=e,this.autojunk=r,this.a=this.b=null,this.setSeqs(t,n)}setSeqs(e,t){return this.setSeq1(e),this.setSeq2(t)}setSeq1(e){if(e!==this.a)return this.a=e,this.matchingBlocks=this.opcodes=null}setSeq2(e){if(e!==this.b)return this.b=e,this.matchingBlocks=this.opcodes=null,this.fullbcount=null,this._chainB()}_chainB(){var e=this.b,t,n,r,i,a,o,s,c,l,u,d;for(this.b2j=t=/* @__PURE__ */ new Map,r=s=0,c=e.length;s<c;r=++s)n=e[r],t.has(n)||t.set(n,[]),i=t.get(n),i.push(r);return o=/* @__PURE__ */ new Map,a=this.isjunk,a&&t.forEach(function(e,n){if(a(n))return o.set(n,!0),t.delete(n)}),d=/* @__PURE__ */ new Map,l=e.length,this.autojunk&&l>=200&&(u=h(l/100)+1,t.forEach(function(e,n){if(e.length>u)return d.set(n,!0),t.delete(n)})),this.isbjunk=function(e){return o.has(e)},this.isbpopular=function(e){return d.has(e)}}findLongestMatch(e,t,n,r){var i,a,o,s,c,l,u,d,f,p,m,h,g,_,v,y,b,x;for([i,a,o,d]=[this.a,this.b,this.b2j,this.isbjunk],[s,c,l]=[e,n,0],p={},u=g=b=e,x=t;b<=x?g<x:g>x;u=b<=x?++g:--g){for(y={},m=[],o.has(i[u])&&(m=o.get(i[u])),v=0,_=m.length;v<_;v++)if(f=m[v],!(f<n)){if(f>=r)break;h=y[f]=(p[f-1]||0)+1,h>l&&([s,c,l]=[u-h+1,f-h+1,h])}p=y}for(;s>e&&c>n&&!d(a[c-1])&&i[s-1]===a[c-1];)[s,c,l]=[s-1,c-1,l+1];for(;s+l<t&&c+l<r&&!d(a[c+l])&&i[s+l]===a[c+l];)l++;for(;s>e&&c>n&&d(a[c-1])&&i[s-1]===a[c-1];)[s,c,l]=[s-1,c-1,l+1];for(;s+l<t&&c+l<r&&d(a[c+l])&&i[s+l]===a[c+l];)l++;return[s,c,l]}getMatchingBlocks(){var e,t,n,r,i,a,o,c,l,u,d,f,p,m,h,g,_,v,y,b,x;if(this.matchingBlocks)return this.matchingBlocks;for([h,g]=[this.a.length,this.b.length],b=[[0,h,0,g]],v=[];b.length;)[t,e,r,n]=b.pop(),[i,c,d]=x=this.findLongestMatch(t,e,r,n),d&&(v.push(x),t<i&&r<c&&b.push([t,i,r,c]),i+d<e&&c+d<n&&b.push([i+d,e,c+d,n]));for(v.sort(s),a=l=f=0,y=[],m=0,_=v.length;m<_;m++)[o,u,p]=v[m],a+f===o&&l+f===u?f+=p:(f&&y.push([a,l,f]),[a,l,f]=[o,u,p]);return f&&y.push([a,l,f]),y.push([h,g,0]),this.matchingBlocks=y}getOpcodes(){var e,t,n,r,i,a,o,s,c,l;if(this.opcodes)return this.opcodes;for(r=i=0,this.opcodes=t=[],s=this.getMatchingBlocks(),a=0,o=s.length;a<o;a++)[e,n,c]=s[a],l=``,r<e&&i<n?l=`replace`:r<e?l=`delete`:i<n&&(l=`insert`),l&&t.push([l,r,e,i,n]),[r,i]=[e+c,n+c],c&&t.push([`equal`,e,r,n,i]);return t}getGroupedOpcodes(e=3){var t=this.getOpcodes(),n,r,i,a,o,s,c,l,u,d;for(t.length||(t=[[`equal`,0,1,0,1]]),t[0][0]===`equal`&&([d,i,a,o,s]=t[0],t[0]=[d,_(i,a-e),a,_(o,s-e),s]),t[t.length-1][0]===`equal`&&([d,i,a,o,s]=t[t.length-1],t[t.length-1]=[d,i,v(a,i+e),o,v(s,o+e)]),u=e+e,r=[],n=[],c=0,l=t.length;c<l;c++)[d,i,a,o,s]=t[c],d===`equal`&&a-i>u&&(n.push([d,i,v(a,i+e),o,v(s,o+e)]),r.push(n),n=[],[i,o]=[_(i,a-e),_(o,s-e)]),n.push([d,i,a,o,s]);return n.length&&(n.length!==1||n[0][0]!==`equal`)&&r.push(n),r}ratio(){var e,t,n,r=0,i=this.getMatchingBlocks();for(e=0,t=i.length;e<t;e++)n=i[e],r+=n[2];return c(r,this.a.length+this.b.length)}quickRatio(){var e,t,n,r,i,a,o,s,l,u,d;if(!this.fullbcount)for(this.fullbcount=n={},u=this.b,r=0,i=u.length;r<i;r++)t=u[r],n[t]=(n[t]||0)+1;for(n=this.fullbcount,e={},s=0,d=this.a,o=0,a=d.length;o<a;o++)t=d[o],l=f(e,t)?e[t]:n[t]||0,e[t]=l-1,l>0&&s++;return c(s,this.a.length+this.b.length)}realQuickRatio(){var e,t;return[e,t]=[this.a.length,this.b.length],c(v(e,t),e+t)}},g=/* @__PURE__ */ A(function(e,t,r=3,i=.6){var o,c,l,u,d,f,p,m,h;if(!(r>0))throw Error(`n must be > 0: (${r})`);if(!(0<=i&&i<=1))throw Error(`cutoff must be in [0.0, 1.0]: (${i})`);for(d=[],p=new a,p.setSeq2(e),o=0,c=t.length;o<c;o++)h=t[o],p.setSeq1(h),p.realQuickRatio()>=i&&p.quickRatio()>=i&&p.ratio()>=i&&d.push([p.ratio(),h]);for(d=n.nlargest(d,r,s),f=[],u=0,l=d.length;u<l;u++)[m,h]=d[u],f.push(h);return f},`getCloseMatches`),l=/* @__PURE__ */ A(function(e,t){var n,r;for([n,r]=[0,e.length];n<r&&e[n]===t;)n++;return n},`_countLeading`),t=class{static{A(this,`Differ`)}constructor(e,t){this.linejunk=e,this.charjunk=t}compare(e,t){var n,r,i,o,s=new a(this.linejunk,e,t),c,l,u,d,f,p=[],m,h=s.getOpcodes(),g;for(l=0,u=h.length;l<u;l++){switch([g,r,n,o,i]=h[l],g){case`replace`:c=this._fancyReplace(e,r,n,t,o,i);break;case`delete`:c=this._dump(`-`,e,r,n);break;case`insert`:c=this._dump(`+`,t,o,i);break;case`equal`:c=this._dump(` `,e,r,n);break;default:throw Error(`unknow tag (${g})`)}for(m=0,d=c.length;m<d;m++)f=c[m],p.push(f)}return p}_dump(e,t,n,r){var i,a,o,s,c=[];for(i=a=o=n,s=r;o<=s?a<s:a>s;i=o<=s?++a:--a)c.push(`${e} ${t[i]}`);return c}_plainReplace(e,t,n,r,i,a){var o,s,c,l,u,d,f,m,h,g;for(p(t<n&&i<a),a-i<n-t?(o=this._dump(`+`,r,i,a),g=this._dump(`-`,e,t,n)):(o=this._dump(`-`,e,t,n),g=this._dump(`+`,r,i,a)),f=[],h=[o,g],c=0,l=h.length;c<l;c++)for(s=h[c],m=0,u=s.length;m<u;m++)d=s[m],f.push(d);return f}_fancyReplace(e,t,n,r,i,o){var s,c,l,u,d,f,p,m,h,g,_,v,y,b,x,S,ee,C,te,w,T,ne,E,re,ie,D,ae,O,oe,se,ce,le,ue,de,fe,pe,me,he,ge,_e,ve,ye,be,k,xe;for([p,x]=[.74,.75],b=new a(this.charjunk),[S,ee]=[null,null],oe=[],te=w=fe=i,pe=o;fe<=pe?w<pe:w>pe;te=fe<=pe?++w:--w)for(g=r[te],b.setSeq2(g),C=se=me=t,he=n;me<=he?se<he:se>he;C=me<=he?++se:--se)c=e[C],c===g?S===null&&([S,ee]=[C,te]):(b.setSeq1(c),b.realQuickRatio()>p&&b.quickRatio()>p&&b.ratio()>p&&([p,m,h]=[b.ratio(),C,te]));if(p<x){if(S===null){for(ge=this._plainReplace(e,t,n,r,i,o),ce=0,E=ge.length;ce<E;ce++)O=ge[ce],oe.push(O);return oe}[m,h,p]=[S,ee,1]}else S=null;for(_e=this._fancyHelper(e,t,m,r,i,h),le=0,re=_e.length;le<re;le++)O=_e[le],oe.push(O);if([s,f]=[e[m],r[h]],S===null){for(d=y=``,b.setSeqs(s,f),ve=b.getOpcodes(),ue=0,ie=ve.length;ue<ie;ue++)switch([xe,l,u,_,v]=ve[ue],[T,ne]=[u-l,v-_],xe){case`replace`:d+=Array(T+1).join(`^`),y+=Array(ne+1).join(`^`);break;case`delete`:d+=Array(T+1).join(`-`);break;case`insert`:y+=Array(ne+1).join(`+`);break;case`equal`:d+=Array(T+1).join(` `),y+=Array(ne+1).join(` `);break;default:throw Error(`unknow tag (${xe})`)}for(ye=this._qformat(s,f,d,y),de=0,D=ye.length;de<D;de++)O=ye[de],oe.push(O)}else oe.push(` `+s);for(be=this._fancyHelper(e,m+1,n,r,h+1,o),k=0,ae=be.length;k<ae;k++)O=be[k],oe.push(O);return oe}_fancyHelper(e,t,n,r,i,a){var o=[];return t<n?o=i<a?this._fancyReplace(e,t,n,r,i,a):this._dump(`-`,e,t,n):i<a&&(o=this._dump(`+`,r,i,a)),o}_qformat(e,t,n,r){var i,a=[];return i=v(l(e,` `),l(t,` `)),i=v(i,l(n.slice(0,i),` `)),i=v(i,l(r.slice(0,i),` `)),n=n.slice(i).replace(/\s+$/,``),r=r.slice(i).replace(/\s+$/,``),a.push(`- `+e),n.length&&a.push(`? ${Array(i+1).join(` `)}${n}
|
|
3
3
|
`),a.push(`+ `+t),r.length&&a.push(`? ${Array(i+1).join(` `)}${r}
|
|
4
4
|
`),a}},i=/* @__PURE__ */ A(function(e,t=/^\s*#?\s*$/){return t.test(e)},`IS_LINE_JUNK`),r=/* @__PURE__ */ A(function(e,t=` `){return S.call(t,e)>=0},`IS_CHARACTER_JUNK`),d=/* @__PURE__ */ A(function(e,t){var n=e+1,r=t-e;return r===1?`${n}`:(r||n--,`${n},${r}`)},`_formatRangeUnified`),x=/* @__PURE__ */ A(function(e,t,{fromfile:n,tofile:r,fromfiledate:i,tofiledate:o,n:s,lineterm:c}={}){var l,u,f,p,m,h,g,_,v,y,b,x,S,ee,C,te,w,T,ne,E,re,ie,D,ae,O,oe,se,ce,le;for(n??=``,r??=``,i??=``,o??=``,s??=3,c??=`
|
|
5
5
|
`,T=[],se=!1,D=new a(null,e,t).getGroupedOpcodes(),y=0,x=D.length;y<x;y++)for(m=D[y],se||(se=!0,p=i?` ${i}`:``,le=o?` ${o}`:``,T.push(`--- ${n}${p}${c}`),T.push(`+++ ${r}${le}${c}`)),[f,b]=[m[0],m[m.length-1]],l=d(f[1],b[2]),u=d(f[3],b[4]),T.push(`@@ -${l} +${u} @@${c}`),ne=0,S=m.length;ne<S;ne++)if([ce,h,g,_,v]=m[ne],ce===`equal`)for(ae=e.slice(h,g),E=0,ee=ae.length;E<ee;E++)w=ae[E],T.push(` `+w);else{if(ce===`replace`||ce===`delete`)for(O=e.slice(h,g),re=0,C=O.length;re<C;re++)w=O[re],T.push(`-`+w);if(ce===`replace`||ce===`insert`)for(oe=t.slice(_,v),ie=0,te=oe.length;ie<te;ie++)w=oe[ie],T.push(`+`+w)}return T},`unifiedDiff`),u=/* @__PURE__ */ A(function(e,t){var n=e+1,r=t-e;return r||n--,r<=1?`${n}`:`${n},${n+r-1}`},`_formatRangeContext`),m=/* @__PURE__ */ A(function(e,t,{fromfile:n,tofile:r,fromfiledate:i,tofiledate:s,n:c,lineterm:l}={}){var d,f,p,m,h,g,_,v,y,b,x,S,ee,C,te,w,T,ne,E,re,ie,D,ae,O,oe,se,ce,le,ue,de;for(n??=``,r??=``,i??=``,s??=``,c??=3,l??=`
|
|
@@ -96,7 +96,7 @@ ${e}`)}p.set(c,l)}a.push([o,l])}f.push([t.class_name,Object.fromEntries(a)])}ret
|
|
|
96
96
|
|
|
97
97
|
Refer to https://developers.cloudflare.com/workers/platform/limits/#worker-startup-time for more details`;try{let e=await r(t),a=await u(n,`startup-profile`,!1),o=Ct.join(a.path,`worker.cpuprofile`),s=Ct.relative(n??process.cwd(),o);await Ft(o,JSON.stringify(e)),i+=eo`
|
|
98
98
|
|
|
99
|
-
A CPU Profile of your Worker's startup phase has been written to ${s} - load it into the Chrome DevTools profiler (or directly in VSCode) to view a flamegraph.`}catch(e){M.debug(`An error occurred while trying to locally profile the Worker: ${e}`)}return i}A(ro,`diagnoseStartupError`);async function io(e){let{analyseBundle:t}=await import(`./startup-profile-
|
|
99
|
+
A CPU Profile of your Worker's startup phase has been written to ${s} - load it into the Chrome DevTools profiler (or directly in VSCode) to view a flamegraph.`}catch(e){M.debug(`An error occurred while trying to locally profile the Worker: ${e}`)}return i}A(ro,`diagnoseStartupError`);async function io(e){let{analyseBundle:t}=await import(`./startup-profile-Dif7XOsU.mjs`);return t(e)}A(io,`analyseBundleLazily`);function ao(e){let t=Object.entries(e);if(t.length===0)return null;t.sort(([,e],[,t])=>t.bytesInOutput-e.bytesInOutput);let n=t.slice(0,5);return[``,`Here are the ${n.length} largest dependencies included in your script:`,``,...n.map(([e,t])=>`- ${e} - ${(t.bytesInOutput/1024).toFixed(2)} KiB`),``,`If these are unnecessary, consider removing them`,``].join(`
|
|
100
100
|
`)}A(ao,`getOffendingDependenciesMessage`);function oo(e){return e instanceof me&&`code`in e&&e.code===10027}A(oo,`errIsScriptSize`);function so(e){return e instanceof me&&!!(`code`in e&&e.code===10021&&/startup/i.test(e.notes[0]?.text))}A(so,`errIsStartupErr`);var co=200;function lo(e){let t=e.replace(/[.+?^${}()|[\]\\]/g,`\\$&`).replace(/\*/g,`.*`);return RegExp(`^${t}$`)}A(lo,`globPatternToRegExp`);function uo(e,t){return t.some(t=>lo(t).test(e))}A(uo,`isExcludedPackage`);async function fo(e,t){let n=Ct.join(e,`package.json`);try{await jt(n)}catch{return}try{let r=await Mt(n,`utf-8`),i=ce(r,n),a={...i.dependencies,...i.devDependencies},o=[];for(let[n,r]of Object.entries(a)){if(o.length>=co)break;if(r.startsWith(`workspace:`)||r.startsWith(`catalog:`)||r.startsWith(`file:`)||r.startsWith(`link:`)||t?.length&&uo(n,t))continue;let i=l(n,e);i&&o.push({name:n,packageJsonVersion:r,installedVersion:i})}return o.length>0?o:void 0}catch(e){M.debug(`Failed to collect package dependencies: ${e instanceof Error?e.message:e}`);return}}A(fo,`collectPackageDependencies`);function po(e,t){if(typeof e!=`object`||!e)throw new ae(`The contents of "${t}" is not valid. It should be a JSON object of string values.`,{telemetryMessage:`secret bulk file invalid contents`});let n=Object.entries(e);for(let[e,r]of n)if(r!=null&&typeof r!=`string`)throw new ae(`The value for "${e}" in "${t}" is not null or a "string" instead it is of type "${typeof r}"`,{telemetryMessage:`secret bulk file invalid value type`});return!0}A(po,`validateFileSecrets`),class extends Error{static{A(this,`NoInputError`)}constructor(){super(`No input provided`),this.name=`NoInputError`}};async function mo(e,t=!1,n=wn.parse){let r,i,a;if(e){i=`file`;let t=Ct.resolve(e),o=oe(t);try{r=se(o),a=`json`}catch{if(r=n(o),a=`dotenv`,Object.keys(r).length===0)throw new O(`The contents of "${e}" is not valid.`,{telemetryMessage:`secret bulk invalid input`})}}else{i=`stdin`;try{let e=Ht.createInterface({input:process.stdin}),t=[];for await(let n of e)t.push(n);let i=t.join(`
|
|
101
101
|
`);try{r=se(i),a=`json`}catch(e){if(r=n(i),a=`dotenv`,Object.keys(r).length===0)throw e}}catch{return}}return po(r,e??`piped input`),t||(r=Object.fromEntries(Object.entries(r).filter(e=>e[1]!=null))),{content:r,secretSource:i,secretFormat:a}}A(mo,`parseBulkInputToObject`);function ho(e){if(e){let t=e,n=`hint`in t?t.hint:void 0;return!n&&t.mode===`off`?void 0:n||t.mode===`smart`?{mode:`smart`,hint:n}:`region`in t&&t.region?{mode:`targeted`,region:t.region}:`host`in t&&t.host?{mode:`targeted`,host:t.host}:`hostname`in t&&t.hostname?{mode:`targeted`,hostname:t.hostname}:void 0}}A(ho,`parseConfigPlacement`);var go=class{constructor(e,t,n,r,i,a){this.type=e,this.bindingName=t,this.binding=n,this.idField=r,this.complianceConfig=i,this.accountId=a}static{A(this,`ProvisionResourceHandler`)}inherit(){this.binding[this.idField]=be}connect(e){this.binding[this.idField]=e}getResolvedIdentifier(){let e=this.binding[this.idField];return typeof e==`string`&&e.length>0?e:void 0}hasConfiguredResourceIdentifier(){let e=this.binding[this.idField];return typeof e==`string`&&e.length>0||this.name!==void 0}async provision(e){let t=await this.create(e);this.connect(t)}isFullySpecified(){return!1}async isConnectedToExistingResource(){return!1}async shouldProvision(e){if(!this.isFullySpecified()){if(await this.canInherit(e))this.inherit();else{let e=await this.isConnectedToExistingResource();return!e||(typeof e==`string`&&this.connect(e),!1)}}return!1}},_o=class extends go{static{A(this,`R2Handler`)}get name(){return this.binding.bucket_name}async create(e){return await $o(this.complianceConfig,this.accountId,e,void 0,this.binding.jurisdiction),e}constructor(e,t,n,r){super(`r2_bucket`,e,t,`bucket_name`,n,r)}inherit(){this.binding.bucket_name??=be}canInherit(e){return!!e?.bindings.find(e=>e.type===this.type&&e.name===this.bindingName&&e.jurisdiction===this.binding.jurisdiction&&(!this.binding.bucket_name||this.binding.bucket_name===e.bucket_name))}async isConnectedToExistingResource(){if(j(typeof this.binding.bucket_name!=`symbol`),!this.binding.bucket_name)return!1;try{return await Qo(this.complianceConfig,this.accountId,this.binding.bucket_name,this.binding.jurisdiction),!0}catch(e){if(!(e instanceof xe&&e.code===10006))throw e;return!1}}},vo=class extends go{static{A(this,`AISearchNamespaceHandler`)}get name(){return this.binding.namespace}async create(e){return await ts(this.complianceConfig,this.accountId,e),e}constructor(e,t,n,r){super(`ai_search_namespace`,e,t,`namespace`,n,r)}canInherit(e){return!!e?.bindings.find(e=>e.type===this.type&&e.name===this.bindingName&&(!this.binding.namespace||this.binding.namespace===e.namespace))}async isConnectedToExistingResource(){return j(typeof this.binding.namespace!=`symbol`),this.binding.namespace?await es(this.complianceConfig,this.accountId,this.binding.namespace)!==null:!1}},yo=class extends go{static{A(this,`AgentMemoryNamespaceHandler`)}get name(){return this.binding.namespace}async create(e){return await rs(this.complianceConfig,this.accountId,e),e}constructor(e,t,n,r){super(`agent_memory`,e,t,`namespace`,n,r)}canInherit(e){return!!e?.bindings.find(e=>e.type===this.type&&e.name===this.bindingName&&(!this.binding.namespace||this.binding.namespace===e.namespace))}async isConnectedToExistingResource(){return j(typeof this.binding.namespace!=`symbol`),this.binding.namespace?await ns(this.complianceConfig,this.accountId,this.binding.namespace)!==null:!1}},bo=class extends go{static{A(this,`QueueHandler`)}get name(){return this.binding.queue_name}async create(e){return await N(this.complianceConfig,`/accounts/${this.accountId}/queues`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({queue_name:e})}),e}constructor(e,t,n,r){super(`queue`,e,t,`queue_name`,n,r)}canInherit(e){let t=e?.bindings.find(e=>e.type===this.type&&e.name===this.bindingName&&(!this.binding.queue_name||this.binding.queue_name===e.queue_name));return t?.type===this.type?this.binding.delivery_delay!==void 0||this.binding.raw!==void 0?(this.connect(t.queue_name),!1):!0:!1}async isConnectedToExistingResource(){return j(typeof this.binding.queue_name!=`symbol`),this.binding.queue_name?(await rn(this.complianceConfig,`/accounts/${this.accountId}/queues`,{},new URLSearchParams({name:this.binding.queue_name}))).some(e=>e.queue_name===this.binding.queue_name):!1}},xo=class extends go{static{A(this,`DispatchNamespaceHandler`)}get name(){return this.binding.namespace}async create(e){return await N(this.complianceConfig,`/accounts/${this.accountId}/workers/dispatch/namespaces`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({name:e})}),e}constructor(e,t,n,r){super(`dispatch_namespace`,e,t,`namespace`,n,r)}canInherit(e){let t=e?.bindings.find(e=>e.type===this.type&&e.name===this.bindingName&&(!this.binding.namespace||this.binding.namespace===e.namespace));return t?.type===this.type?this.binding.outbound===void 0||(this.connect(t.namespace),!1):!1}async isConnectedToExistingResource(){return j(typeof this.binding.namespace!=`symbol`),this.binding.namespace?(await Go(this.complianceConfig,this.accountId)).some(e=>e.namespace_name===this.binding.namespace):!1}},So=class extends go{static{A(this,`FlagshipHandler`)}get name(){}async create(e){return(await N(this.complianceConfig,`/accounts/${this.accountId}/flagship/apps`,{method:`POST`,headers:{"Content-Type":`application/json`},body:JSON.stringify({name:e})})).id}constructor(e,t,n,r){super(`flagship`,e,t,`app_id`,n,r)}canInherit(e){return!!e?.bindings.find(e=>e.type===this.type&&e.name===this.bindingName)}isFullySpecified(){return!!this.binding.app_id}},Co=class extends go{static{A(this,`KVHandler`)}get name(){}async create(e){return await Uo(this.complianceConfig,this.accountId,e)}constructor(e,t,n,r){super(`kv_namespace`,e,t,`id`,n,r)}canInherit(e){return!!e?.bindings.find(e=>e.type===this.type&&e.name===this.bindingName)}isFullySpecified(){return!!this.binding.id}},wo=class extends go{constructor(e,t,n,r,i,a){super(`d1`,e,t,`database_id`,n,r),this.d1ListCommand=i,this.d1DeleteCommand=a}static{A(this,`D1Handler`)}get name(){return this.binding.database_name}async create(e){return(await qo(this.complianceConfig,this.accountId,e,this.d1ListCommand,this.d1DeleteCommand,this.binding.jurisdiction)).uuid}throwIfJurisdictionMismatch(e){let t=this.binding.jurisdiction;if(!t||t===e.jurisdiction)return;let n=e.jurisdiction??`default`,r=e.jurisdiction?`set "jurisdiction" to "${e.jurisdiction}"`:`remove "jurisdiction"`;throw new O(eo`
|
|
102
102
|
D1 database "${e.name}" (${e.uuid}) is in jurisdiction "${n}", but the "${this.bindingName}" binding specifies jurisdiction "${t}".
|
|
@@ -357,7 +357,7 @@ ${Object.entries(i).map(([e,t])=>` ${f.cyan(e)} ${f.dim(b(t.type))}`).join(`
|
|
|
357
357
|
Parts of your Worker that depend on these bindings may not work correctly in the Preview. If this is not intentional, add Preview-safe values to the ${f.cyan(`previews`)} field.
|
|
358
358
|
|
|
359
359
|
Configuration: https://developers.cloudflare.com/workers/previews/configuration/
|
|
360
|
-
Resources: https://developers.cloudflare.com/workers/previews/resources/`)}A(WO,`logMissingPreviewsBindingsWarning`);async function GO(e,t,n,r){if(!(r||await an(`Worker "${n}" does not exist yet. Would you like to create it for this Preview?`,{defaultValue:!0,fallbackValue:!0})))throw new O(`Cannot create a Preview because the Worker "${n}" does not exist.`,{telemetryMessage:`preview command parent worker not created`});r||M.log(`\u{1F300} Creating new Worker "${n}"...`);let i=e.routes??(e.route?[e.route]:[]),{workers_dev:a,preview_urls:o}=ei(e.workers_dev,e.preview_urls,i);await HD(e,t,n,a,o??a)}A(GO,`provisionParentWorker`);async function KO(e,t,n,i,a,o,s,c=!1,l=/* @__PURE__ */ new Map){let u;t.secretsFile&&(u=(await mo(t.secretsFile,!1,r))?.content);let d=t.name;if(!d&&(d=tO(),!d))throw new O(`Could not determine Preview name. No git branch detected. Please provide a Preview name using --name <preview-name>.`,{telemetryMessage:`preview command missing preview name`});let f=d,p=t.ignoreBaseConfig,m=!t.tag&&nO()?rO():void 0,h=!t.message&&nO()?iO():void 0,g=sO(),_=pO(),v=aO(),y=null;try{y=await UD(n,e,s,f)}catch(r){if(Yn(r))await GO(n,e,s,t.json??!1);else if(!(r instanceof Error&&`code`in r&&r.code===10025))throw r}let b=!y,x=SO(n),S;b?(S=await WD(n,e,s,{name:d,...x},{ignoreBaseConfig:p}),c&&x.tail_consumers!==void 0&&(S=await GD(n,e,s,f,{tail_consumers:x.tail_consumers}))):S=Object.keys(x).length>0?await GD(n,e,s,f,x):y;let{scopedContainerConfig:ee,normalisedContainerConfig:C}=await kO(n,s,S.slug,o,l),te=await IO(n,i,e,s,S.id,{message:t.message??h,tag:t.tag??m,repositoryUrl:g,pullRequest:_,commitSha:v,assetsOptions:a,secrets:u,cliVars:t.cliVars,isNewPreview:b}),w=await YD(n,e,s,S.id,te);for(let e of Object.values(w.env??{}))e.type===`secret_text`&&delete e.text;if(C.length>0&&ee&&o.deployPreviewContainers)try{await o.deployPreviewContainers(ee,C,w,e,{quiet:t.json===!0,localImageReferences:l})}catch(e){throw M.warn(`The preview "${S.name}" was created, but its containers did not come up. Its Durable Objects have no container backing them until the containers are applied successfully.`),e}if(t.json)M.log(JSON.stringify({preview:S,deployment:w},null,2));else{let t=o.productionBindingsExpectedInPreview??{};Object.keys(t).length>0&&WO(t,(await ZD(n,e,s)).env,te.env??{}),M.log(RO(n,S,w,b,_,o.deployCommand,o.previewCommand)),UO(n,S,w,o.deployCommand,o.previewCommand)}return{preview:S,deployment:w,isNewPreview:b}}A(KO,`runPreview`);async function qO(e,t,n,r,i,a){return KO(e,t,n,r,i,a,mO(t,n))}A(qO,`preview`);async function JO(e,t,n,r){let{workerConfig:i,rootConfig:a,buildResult:o,assets:s}=n;if(CO(a),i.triggers?.length)throw new O("Preview uploads from Build Output don't support the `triggers` field.",{telemetryMessage:`preview build output triggers not supported`});if(i.
|
|
360
|
+
Resources: https://developers.cloudflare.com/workers/previews/resources/`)}A(WO,`logMissingPreviewsBindingsWarning`);async function GO(e,t,n,r){if(!(r||await an(`Worker "${n}" does not exist yet. Would you like to create it for this Preview?`,{defaultValue:!0,fallbackValue:!0})))throw new O(`Cannot create a Preview because the Worker "${n}" does not exist.`,{telemetryMessage:`preview command parent worker not created`});r||M.log(`\u{1F300} Creating new Worker "${n}"...`);let i=e.routes??(e.route?[e.route]:[]),{workers_dev:a,preview_urls:o}=ei(e.workers_dev,e.preview_urls,i);await HD(e,t,n,a,o??a)}A(GO,`provisionParentWorker`);async function KO(e,t,n,i,a,o,s,c=!1,l=/* @__PURE__ */ new Map){let u;t.secretsFile&&(u=(await mo(t.secretsFile,!1,r))?.content);let d=t.name;if(!d&&(d=tO(),!d))throw new O(`Could not determine Preview name. No git branch detected. Please provide a Preview name using --name <preview-name>.`,{telemetryMessage:`preview command missing preview name`});let f=d,p=t.ignoreBaseConfig,m=!t.tag&&nO()?rO():void 0,h=!t.message&&nO()?iO():void 0,g=sO(),_=pO(),v=aO(),y=null;try{y=await UD(n,e,s,f)}catch(r){if(Yn(r))await GO(n,e,s,t.json??!1);else if(!(r instanceof Error&&`code`in r&&r.code===10025))throw r}let b=!y,x=SO(n),S;b?(S=await WD(n,e,s,{name:d,...x},{ignoreBaseConfig:p}),c&&x.tail_consumers!==void 0&&(S=await GD(n,e,s,f,{tail_consumers:x.tail_consumers}))):S=Object.keys(x).length>0?await GD(n,e,s,f,x):y;let{scopedContainerConfig:ee,normalisedContainerConfig:C}=await kO(n,s,S.slug,o,l),te=await IO(n,i,e,s,S.id,{message:t.message??h,tag:t.tag??m,repositoryUrl:g,pullRequest:_,commitSha:v,assetsOptions:a,secrets:u,cliVars:t.cliVars,isNewPreview:b}),w=await YD(n,e,s,S.id,te);for(let e of Object.values(w.env??{}))e.type===`secret_text`&&delete e.text;if(C.length>0&&ee&&o.deployPreviewContainers)try{await o.deployPreviewContainers(ee,C,w,e,{quiet:t.json===!0,localImageReferences:l})}catch(e){throw M.warn(`The preview "${S.name}" was created, but its containers did not come up. Its Durable Objects have no container backing them until the containers are applied successfully.`),e}if(t.json)M.log(JSON.stringify({preview:S,deployment:w},null,2));else{let t=o.productionBindingsExpectedInPreview??{};Object.keys(t).length>0&&WO(t,(await ZD(n,e,s)).env,te.env??{}),M.log(RO(n,S,w,b,_,o.deployCommand,o.previewCommand)),UO(n,S,w,o.deployCommand,o.previewCommand)}return{preview:S,deployment:w,isNewPreview:b}}A(KO,`runPreview`);async function qO(e,t,n,r,i,a){return KO(e,t,n,r,i,a,mO(t,n))}A(qO,`preview`);async function JO(e,t,n,r){let{workerConfig:i,rootConfig:a,buildResult:o,assets:s}=n;if(CO(a),i.triggers?.length)throw new O("Preview uploads from Build Output don't support the `triggers` field.",{telemetryMessage:`preview build output triggers not supported`});if((i.experimental?.streamingTailConsumers?.length??0)>0)throw new O(`Preview uploads from Build Output don't support streaming tail consumers.`,{telemetryMessage:`preview build output streaming tail consumer not supported`});if(i.unsafe?.capnp!==void 0||Object.keys(i.unsafe?.metadata??{}).length>0)throw new O(`Preview uploads from Build Output don't support unsafe metadata or Cap'n Proto schemas.`,{telemetryMessage:`preview build output unsafe settings not supported`});let{buildContext:c,...l}=a,{manifest:u,...d}=i,f=Zt({...l,worker:d,containers:[]}),p=EO(n.containers,f.exports),m=TO(n.containers,p);if(p.length>0&&(r?.getNormalizedContainerOptions===void 0||r.deployPreviewContainers===void 0))throw new O(`Preview uploads from Build Output with Containers require container deployment callbacks.`,{telemetryMessage:`preview build output container callbacks missing`});let h=o&&{...o,mainModuleName:i.manifest?.mainModule},g=vO(f),_={...S,account_id:e,compliance_region:f.compliance_region,name:i.name,compatibility_date:f.compatibility_date,compatibility_flags:f.compatibility_flags??[],exports:f.exports??{},limits:f.limits,cache:f.cache,placement:f.placement,observability:f.observability,logpush:f.logpush,workers_dev:!1,preview_urls:!0,previews:{containers:p,tail_consumers:f.tail_consumers??(i.tailConsumers===void 0?void 0:[]),unsafe:{bindings:Object.entries(g).map(([e,t])=>({name:e,...t}))}},assets:f.assets},v=s&&{...s,_headers:s._headers??ji(Ct.join(s.directory,`_headers`)),_redirects:s._redirects??ji(Ct.join(s.directory,`_redirects`)),assetConfig:{html_handling:f.assets?.html_handling,not_found_handling:f.assets?.not_found_handling,base_path:f.assets?.base_path},run_worker_first:f.assets?.run_worker_first};return KO(e,{...t,ignoreBaseConfig:!1},_,h,v,r??{getNormalizedContainerOptions:void 0,deployPreviewContainers:void 0},i.name,!0,m)}A(JO,`previewBuildOutput`);async function YO(e,t,n){let r=mO(t,n),i=t.name;if(!i){if(i=tO(),!i)throw new O(`Could not determine Preview name. No git branch detected. Please provide a Preview name using --name <preview-name>.`,{telemetryMessage:`preview delete command missing preview name`});M.log(`Using git branch "${i}" as Preview name.`)}!t.skipConfirmation&&!await an(`Are you sure you want to delete the Preview "${i}" for Worker "${r}"?
|
|
361
361
|
This will delete all deployments associated with this Preview.`)?M.log(`Aborted.`):(await KD(n,e,r,i),M.log(`
|
|
362
362
|
\u2728 Preview "${i}" deleted successfully.`))}A(YO,`previewDelete`);var XO={topLeft:`╭`,topRight:`╮`,bottomLeft:`╰`,bottomRight:`╯`,horizontal:`─`,vertical:`│`,bottomLeftWithConnector:`┬`,connectorRight:`┤`};function ZO(e){return e.replace(/\x1b\[[0-9;]*m/g,``)}A(ZO,`stripAnsi`);function QO(e){return ZO(e).length}A(QO,`visibleLength`);function $O(e,t){let n=QO(e);return e+` `.repeat(Math.max(0,t-n))}A($O,`padToVisibleWidth`);function ek(e,t={}){let n=[...e,...t.footerLines??[]],r=Math.max(...n.map(e=>QO(e)),0),i=r+4,a=XO.horizontal.repeat(i-2),o=`${XO.topLeft}${a}${XO.topRight}`,s=t.connectToChild?`${XO.bottomLeft}${XO.horizontal}${XO.bottomLeftWithConnector}${XO.horizontal.repeat(i-4)}${XO.bottomRight}`:`${XO.bottomLeft}${a}${XO.bottomRight}`;return[o,...n.map(e=>{let t=$O(e,r);return`${XO.vertical} ${t} ${XO.vertical}`}),s].join(`
|
|
363
363
|
`)}A(ek,`drawBox`);function tk(e,t={}){let n=t.indent??` `,r=[...e,...t.footerLines??[]],i=r.length>0?Math.max(...r.map(e=>QO(e))):0,a=i+4,o=XO.horizontal.repeat(a-2),s=`${XO.topLeft}${o}${XO.topRight}`,c=`${XO.bottomLeft}${o}${XO.bottomRight}`,l=r.map(e=>{let t=$O(e,i);return`${XO.vertical} ${t} ${XO.vertical}`}),u=t.connectorLineIndex??Math.floor(l.length/2),d=[];return d.push(`${n}${XO.vertical}`),d.push(`${n}${XO.vertical} ${s}`),l.forEach((e,t)=>{t===u?d.push(`${n}${XO.bottomLeft}${XO.horizontal}${XO.connectorRight}${e.slice(1)}`):t<u?d.push(`${n}${XO.vertical} ${e}`):d.push(`${n} ${e}`)}),d.push(`${n} ${c}`),d.join(`
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{i as t,n}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{i as t,n}from"./auth-cj71dGxS.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{a as i,t as a}from"./context-DlFhI9cN.mjs";import{t as o}from"./local-B3zt9PXR.mjs";import{t as s}from"./output-PRKYaJuo.mjs";import{t as c}from"./progress-AML-AVs4.mjs";import{t as l}from"./run-DAg7dfIW.mjs";import"./telemetry-DDs3zhdw.mjs";import{a as u,n as d}from"./prompt-Bnon9lfK.mjs";import{c as f,i as p,o as m,r as h,t as g}from"./body-parser-HN91kAf0.mjs";import{n as _,t as v}from"./input-validation-D7z60HJH.mjs";import{n as y,t as b}from"./raw-fetch-0T1SwPa1.mjs";var ee={method:`POST`,path:t=>e`/accounts/${t.account_id}/stream/keys`};function te(e){return e.usage(`$0 stream keys create
|
|
3
3
|
|
|
4
4
|
Creates an RSA private key in PEM and JWK formats. Key files are only displayed once after creation. Keys are created, used, and deleted independently of videos, and every key can sign any video.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const ne={command:`create`,describe:`Create signing keys`,builder:te,handler:async e=>l({command:`stream keys create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){let e=await i();r({command:`cf stream keys create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/stream/keys`,pathParams:{},bodyKind:`none`});return}let t=await n(e),l=e.local?o:await a();e.accountId=l;let u=await c(`Creating`,async()=>t.send(ee,{account_id:l}));s(u,{successLabel:`Created`})})};var re={method:`DELETE`,path:t=>e`/accounts/${t.account_id}/stream/keys/${t.identifier}`};function ie(e){return e.usage(`$0 stream keys delete <identifier>
|
|
5
5
|
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import{n as e}from"./ansi-styles-kSC6bEIq.mjs";const t=[161,161,164,164,167,168,170,170,173,174,176,180,182,186,188,191,198,198,208,208,215,216,222,225,230,230,232,234,236,237,240,240,242,243,247,250,252,252,254,254,257,257,273,273,275,275,283,283,294,295,299,299,305,307,312,312,319,322,324,324,328,331,333,333,338,339,358,359,363,363,462,462,464,464,466,466,468,468,470,470,472,472,474,474,476,476,593,593,609,609,708,708,711,711,713,715,717,717,720,720,728,731,733,733,735,735,768,879,913,929,931,937,945,961,963,969,1025,1025,1040,1103,1105,1105,8208,8208,8211,8214,8216,8217,8220,8221,8224,8226,8228,8231,8240,8240,8242,8243,8245,8245,8251,8251,8254,8254,8308,8308,8319,8319,8321,8324,8364,8364,8451,8451,8453,8453,8457,8457,8467,8467,8470,8470,8481,8482,8486,8486,8491,8491,8531,8532,8539,8542,8544,8555,8560,8569,8585,8585,8592,8601,8632,8633,8658,8658,8660,8660,8679,8679,8704,8704,8706,8707,8711,8712,8715,8715,8719,8719,8721,8721,8725,8725,8730,8730,8733,8736,8739,8739,8741,8741,8743,8748,8750,8750,8756,8759,8764,8765,8776,8776,8780,8780,8786,8786,8800,8801,8804,8807,8810,8811,8814,8815,8834,8835,8838,8839,8853,8853,8857,8857,8869,8869,8895,8895,8978,8978,9312,9449,9451,9547,9552,9587,9600,9615,9618,9621,9632,9633,9635,9641,9650,9651,9654,9655,9660,9661,9664,9665,9670,9672,9675,9675,9678,9681,9698,9701,9711,9711,9733,9734,9737,9737,9742,9743,9756,9756,9758,9758,9792,9792,9794,9794,9824,9825,9827,9829,9831,9834,9836,9837,9839,9839,9886,9887,9919,9919,9926,9933,9935,9939,9941,9953,9955,9955,9960,9961,9963,9969,9972,9972,9974,9977,9979,9980,9982,9983,10045,10045,10102,10111,11094,11097,12872,12879,57344,63743,65024,65039,65533,65533,127232,127242,127248,127277,127280,127337,127344,127373,127375,127376,127387,127404,917760,917999,983040,1048573,1048576,1114109],n=[12288,12288,65281,65376,65504,65510],r=[4352,4447,8986,8987,9001,9002,9193,9196,9200,9200,9203,9203,9725,9726,9748,9749,9776,9783,9800,9811,9855,9855,9866,9871,9875,9875,9889,9889,9898,9899,9917,9918,9924,9925,9934,9934,9940,9940,9962,9962,9970,9971,9973,9973,9978,9978,9981,9981,9989,9989,9994,9995,10024,10024,10060,10060,10062,10062,10067,10069,10071,10071,10133,10135,10160,10160,10175,10175,11035,11036,11088,11088,11093,11093,11904,11929,11931,12019,12032,12245,12272,12287,12289,12350,12353,12438,12441,12543,12549,12591,12593,12686,12688,12773,12783,12830,12832,12871,12880,42124,42128,42182,43360,43388,44032,55203,63744,64255,65040,65049,65072,65106,65108,65126,65128,65131,94176,94180,94192,94198,94208,101589,101631,101662,101760,101874,110576,110579,110581,110587,110589,110590,110592,110882,110898,110898,110928,110930,110933,110933,110948,110951,110960,111355,119552,119638,119648,119670,126980,126980,127183,127183,127374,127374,127377,127386,127488,127490,127504,127547,127552,127560,127568,127569,127584,127589,127744,127776,127789,127797,127799,127868,127870,127891,127904,127946,127951,127955,127968,127984,127988,127988,127992,128062,128064,128064,128066,128252,128255,128317,128331,128334,128336,128359,128378,128378,128405,128406,128420,128420,128507,128591,128640,128709,128716,128716,128720,128722,128725,128728,128732,128735,128747,128748,128756,128764,128992,129003,129008,129008,129292,129338,129340,129349,129351,129535,129648,129660,129664,129674,129678,129734,129736,129736,129741,129756,129759,129770,129775,129784,131072,196605,196608,262141],i=(e,t)=>{let n=0,r=Math.floor(e.length/2)-1;for(;n<=r;){let i=Math.floor((n+r)/2),a=i*2;if(t<e[a])r=i-1;else if(t>e[a+1])n=i+1;else return!0}return!1},a=19968,[o,s]=/* #__PURE__ */ c(r);function c(e){let t=e[0],n=e[1];for(let r=0;r<e.length;r+=2){let i=e[r],o=e[r+1];if(a>=i&&a<=o)return[i,o];o-i>n-t&&(t=i,n=o)}return[t,n]}const l=e=>e<161||e>1114109?!1:i(t,e),u=e=>e<12288||e>65510?!1:i(n,e),d=e=>e>=o&&e<=s?!0:e<4352||e>262141?!1:i(r,e);function f(e){if(!Number.isSafeInteger(e))throw TypeError(`Expected a code point, got \`${typeof e}\`.`)}function p(e,{ambiguousAsWide:t=!1}={}){return f(e),u(e)||d(e)||t&&l(e)?2:1}const m=new Intl.Segmenter,h=/[^\p{Default_Ignorable_Code_Point}\p{Control}\p{Format}\p{Nonspacing_Mark}\p{Enclosing_Mark}\p{Surrogate}]/v,g=/\p{Spacing_Mark}/v,_=/^\p{RGI_Emoji}$/v,v=/^[\d#*]\u20E3$/,y=/\p{Extended_Pictographic}/gu;function b(e){if(e.length>50)return!1;if(v.test(e))return!0;if(e.includes(``)){let t=e.match(y);return t!==null&&t.length>=2}return!1}function x(e){let t=e.search(h);return t===-1?void 0:e.slice(t)}function S(e){return e>=4352&&e<=4447||e>=43360&&e<=43388}function C(e){return e>=4448&&e<=4519||e>=55216&&e<=55238}function w(e){return e>=4520&&e<=4607||e>=55243&&e<=55291}function T(e){return S(e)||C(e)||w(e)}function E(e,t){let n=[];for(let t of e)h.test(t)&&n.push(t.codePointAt(0));if(n.length===0)return;let r=0;for(let e=0;e<n.length;e++){let i=n[e];if(!T(i)){if(r===0)return;for(let i=e;i<n.length;i++)r+=p(n[i],t);return r}S(i)&&C(n[e+1])?(r+=2,e+=w(n[e+2])?2:1):r+=p(i,t)}return r}function D(e,t){let n=0,r=!0;for(let i of e)r?r=!1:(g.test(i)||i>=``&&i<=``)&&(n+=p(i.codePointAt(0),t));return n}function O(t,n={}){if(typeof t!=`string`||t.length===0)return 0;let{ambiguousIsNarrow:r=!0,countAnsiEscapeCodes:i=!1}=n,a=t;if(!i&&(a.includes(`\x1B`)||a.includes(``))&&(a=e(a)),a.length===0)return 0;if(/^[\u0020-\u007E]*$/.test(a))return a.length;let o=0,s={ambiguousAsWide:!r};for(let{segment:e}of m.segment(a)){let t=x(e);if(t===void 0)continue;if(_.test(e)||b(e)){o+=2;continue}let n=E(t,s);if(n!==void 0){o+=n;continue}let r=t.codePointAt(0);o+=p(r,s),o+=D(t,s)}return o}export{p as n,O as t};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{i as e,n as t}from"./auth-
|
|
2
|
+
import{i as e,n as t}from"./auth-cj71dGxS.mjs";import{t as n}from"./path-DRw6Y-nd.mjs";import{c as r,r as i,t as a}from"./body-parser-HN91kAf0.mjs";import{t as o}from"./dry-run-mrA7FFLR.mjs";import{a as s,i as c,t as l}from"./context-DlFhI9cN.mjs";import{n as u}from"./input-validation-D7z60HJH.mjs";import{t as d}from"./local-B3zt9PXR.mjs";import{t as f}from"./output-PRKYaJuo.mjs";import{t as p}from"./run-DAg7dfIW.mjs";import{t as m}from"./progress-AML-AVs4.mjs";import{a as h,i as g,n as _}from"./prompt-Bnon9lfK.mjs";import"./telemetry-DDs3zhdw.mjs";import"./api-Dnt6lRJG.mjs";function v(e){return e.usage(`$0 tags account-resources delete
|
|
3
3
|
|
|
4
4
|
Removes all tags from a specific account or zone-level resource.
|
|
5
5
|
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{a as e,n as t,r as n,t as r}from"./lifecycle-oud60haK.mjs";import{a as i,c as a,d as o,f as s,i as c,n as l,o as u,p as d,r as f,s as p,t as m,u as h}from"./run-
|
|
2
|
+
import{a as e,n as t,r as n,t as r}from"./lifecycle-oud60haK.mjs";import{a as i,c as a,d as o,f as s,i as c,n as l,o as u,p as d,r as f,s as p,t as m,u as h}from"./run-DAg7dfIW.mjs";import{r as g}from"./sanitization-DkVWMHkc.mjs";import{t as _}from"./telemetry-DDs3zhdw.mjs";export{c as TELEMETRY_ENV_VAR,i as TELEMETRY_POLICY_DATE,_ as UNKNOWN_COMMAND_EVENT,r as allTelemetryDispatchesSettled,t as beginTelemetryRun,u as getBannerLastShown,p as getDeviceId,f as getTelemetryDispatcher,a as getTelemetryFromEnv,h as isFirstUsage,n as markCommandReported,o as resolveTelemetry,m as runWithTelemetry,g as sanitizeArgs,s as setBannerLastShown,d as setTelemetryPermission,e as wasCommandReported,l as withTelemetry};
|
package/dist/{tenant-custom-nameservers-C5rh6jPf.mjs → tenant-custom-nameservers-DBg9Hzvn.mjs}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{r as n,t as r}from"./body-parser-HN91kAf0.mjs";import{t as i}from"./dry-run-mrA7FFLR.mjs";import{n as a}from"./input-validation-D7z60HJH.mjs";import{t as o}from"./run-DAg7dfIW.mjs";import{t as s}from"./output-PRKYaJuo.mjs";import{t as c}from"./progress-AML-AVs4.mjs";import{a as l,n as u}from"./prompt-Bnon9lfK.mjs";import"./telemetry-DDs3zhdw.mjs";var d={method:`POST`,path:t=>e`/tenants/${t.tenant_id}/custom_ns`,body:`json`};function f(e){return e.usage(`$0 tenant-custom-nameservers create <tenant-id>
|
|
3
3
|
|
|
4
4
|
Adds a custom nameserver for a tenant.`).positional(`tenant-id`,{type:`string`,description:`Tenant identifier tag.`,demandOption:!0}).option(`ns-name`,{type:`string`,description:`The FQDN of the name server.`}).option(`ns-set`,{type:`number`,description:`The number of the set that this name server belongs to.`,default:1}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const p={command:`create <tenant-id>`,describe:`Add Tenant Custom Nameserver`,builder:f,handler:async e=>o({command:`tenant-custom-nameservers create`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){i({command:`cf tenant-custom-nameservers create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/tenants/${e[`tenant-id`]==null?`<tenant-id>`:encodeURIComponent(String(e[`tenant-id`]))}/custom_ns`,pathParams:{"tenant-id":String(e[`tenant-id`]??``)},bodyKind:`json`,body:e.body===void 0?r({ns_name:a(e[`ns-name`],`ns-name`,`text`),ns_set:e[`ns-set`]}):n(e.body)});return}let o=e.body===void 0?void 0:n(e.body),u=await t(e);if(e.body!==void 0){let t=o,n=await c(`Creating`,async()=>u.send(d,{body:t,tenant_id:e[`tenant-id`]}));s(n,{successLabel:`Created`});return}e[`ns-name`]===void 0&&(e[`ns-name`]=await l(`ns-name`,`The FQDN of the name server.`));let f=r({ns_name:a(e[`ns-name`],`ns-name`,`text`),ns_set:e[`ns-set`]}),p=await c(`Creating`,async()=>u.send(d,{body:f,tenant_id:e[`tenant-id`]}));s(p,{successLabel:`Created`})})};var m={method:`DELETE`,path:t=>e`/tenants/${t.tenant_id}/custom_ns/${t.custom_ns_id}`};function h(e){return e.usage(`$0 tenant-custom-nameservers delete <custom-ns-id>
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{t as n}from"./dry-run-mrA7FFLR.mjs";import{t as r}from"./output-PRKYaJuo.mjs";import{t as i}from"./progress-AML-AVs4.mjs";import{t as a}from"./run-DAg7dfIW.mjs";import"./telemetry-DDs3zhdw.mjs";var o={method:`GET`,path:t=>e`/tenants/${t.tenant_id}/accounts`,query:[`account_pubname`,`account_pubname.startsWith`,`account_pubname.endsWith`,`account_pubname.contains`,`name`,`name.startsWith`,`name.endsWith`,`name.contains`,`status`,`order_by`,`direction`,`include_total`,`page_token`,`page_size`],joined:[`account_pubname`,`account_pubname.startsWith`,`account_pubname.endsWith`,`account_pubname.contains`,`name`,`name.startsWith`,`name.endsWith`,`name.contains`,`status`,`order_by`,`direction`,`include_total`,`page_token`,`page_size`]};function s(e){return e.usage("$0 tenants accounts list\n\nLists all Cloudflare accounts across this tenant's hierarchy using the legacy Account response shape. Use `GET /organizations/{organization_id}/accounts` to list only accounts immediately attached to a specific Organization using the modern Account response shape. Use `page_token` and `page_size` for cursor pagination.").option(`tenant-id`,{type:`string`,description:`The ID of the tenant whose accounts to list.`,demandOption:!0}).option(`account-pubname`,{type:`string`,description:`(case-sensitive) Filter the list of accounts to where the account_pubname is equal to
|
|
3
3
|
a particular string.`}).option(`account-pubname-starts-with`,{type:`string`,description:`(case-insensitive) Filter the list of accounts to where the account_pubname starts with
|
|
4
4
|
a particular string.`}).option(`account-pubname-ends-with`,{type:`string`,description:`(case-insensitive) Filter the list of accounts to where the account_pubname ends with
|
|
5
5
|
a particular string.`}).option(`account-pubname-contains`,{type:`string`,description:`(case-insensitive) Filter the list of accounts to where the account_pubname contains
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{n as e,t}from"./metadata-Df5kCWJv.mjs";import{t as n}from"./output-
|
|
2
|
+
import{n as e,t}from"./metadata-Df5kCWJv.mjs";import{t as n}from"./output-PRKYaJuo.mjs";function r(e){return e.replace(/[\s-]+/g,`_`)}function i(e){let t={type:e.type,description:e.description};return`default`in e&&e.default!==void 0&&(t.default=e.default),e.enum&&e.enum.length>0&&(t.enum=e.enum),t}function a(e){let t={},n=[];for(let r of e.arguments)t[r.name]=i(r),r.required&&n.push(r.name);for(let r of e.options)t[r.name]=i(r),r.required&&n.push(r.name);return{name:r(e.command),description:e.description,inputSchema:{type:`object`,properties:t,required:n}}}const o={command:`tools`,describe:!1,builder:e=>e,handler:async r=>{let i=e(import.meta.url,`commands.json`,t)?.commands??null;if(i===null){console.error(`Warning: Command metadata file not found. Run the build to generate it.`),n({version:`1.0`,tools:[]});return}let o={version:`1.0`,tools:i.map(a)};n(o)}};export{o as default};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{n as e}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{n as e}from"./auth-cj71dGxS.mjs";import{t}from"./path-DRw6Y-nd.mjs";import{t as n}from"./dry-run-mrA7FFLR.mjs";import{t as r}from"./local-B3zt9PXR.mjs";import{t as i}from"./output-PRKYaJuo.mjs";import{a,t as o}from"./context-DlFhI9cN.mjs";import{t as s}from"./progress-AML-AVs4.mjs";import"./telemetry-DDs3zhdw.mjs";import{o as c,r as l,t as u}from"./body-parser-HN91kAf0.mjs";import{t as d}from"./run-DAg7dfIW.mjs";import{n as f}from"./input-validation-D7z60HJH.mjs";import{a as p,n as m}from"./prompt-Bnon9lfK.mjs";import{t as h}from"./create-DmLDMvrj.mjs";import{t as g}from"./get-3XNn0upb.mjs";import{t as _}from"./lazy-command-QoHlmXHW.mjs";import{t as v}from"./hand-written-dry-run-B82fRl2N.mjs";var ee={method:`GET`,path:e=>t`/accounts/${e.account_id}/cfd_tunnel/${e.tunnel_id}/configurations`};function y(e){return e.usage(`$0 tunnels config get <tunnel-id>
|
|
3
3
|
|
|
4
4
|
Retrieves the configuration for a remotely managed Cloudflare Tunnel.`).positional(`tunnel-id`,{type:`string`,description:`UUID of the tunnel.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const te={command:`get <tunnel-id>`,describe:`Get Tunnel configuration`,builder:y,handler:async t=>d({command:`tunnels config get`,classification:{safeFlags:[`dry-run`]}},t,async()=>{if(t.dryRun){let e=await a();n({command:`cf tunnels config get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/cfd_tunnel/${t[`tunnel-id`]==null?`<tunnel-id>`:encodeURIComponent(String(t[`tunnel-id`]))}/configurations`,pathParams:{"tunnel-id":String(t[`tunnel-id`]??``)},bodyKind:`none`});return}let c=await e(t),l=t.local?r:await o();t.accountId=l;let u=await s(`Loading`,async()=>c.send(ee,{account_id:l,tunnel_id:t[`tunnel-id`]}));i(u,{successLabel:`Loaded`})})};var b={method:`PUT`,path:e=>t`/accounts/${e.account_id}/cfd_tunnel/${e.tunnel_id}/configurations`,body:`json`};function x(e){return e.usage(`$0 tunnels config update <tunnel-id>
|
|
5
5
|
|
|
@@ -24,4 +24,4 @@ Lists and filters all types of Tunnels in an account.`).option(`name`,{type:`str
|
|
|
24
24
|
|
|
25
25
|
Creates a short-lived management token for the requested Tunnel management resources, such as streaming logs. Treat the token as a secret.`).positional(`tunnel-id`,{type:`string`,description:`UUID of the tunnel.`,demandOption:!0}).option(`resources`,{type:`string`,array:!0,description:`The resources field`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const Z={command:`create <tunnel-id>`,describe:`Get a Cloudflare Tunnel management token`,builder:X,handler:async t=>d({command:`tunnels management-token create`,classification:{safeFlags:[`dry-run`]}},t,async()=>{if(t.dryRun){let e=await a();n({command:`cf tunnels management-token create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/cfd_tunnel/${t[`tunnel-id`]==null?`<tunnel-id>`:encodeURIComponent(String(t[`tunnel-id`]))}/management`,pathParams:{"tunnel-id":String(t[`tunnel-id`]??``)},bodyKind:`json`,body:t.body===void 0?u({resources:t.resources}):l(t.body)});return}let c=t.body===void 0?void 0:l(t.body),d=await e(t),f=t.local?r:await o();if(t.accountId=f,t.body!==void 0){let e=c,n=await s(`Creating`,async()=>d.send(h,{body:e,account_id:f,tunnel_id:t[`tunnel-id`]}));i(n,{successLabel:`Created`});return}if(t.resources===void 0)throw Error(`--resources is required (or pass --body with this field set).`);let p=u({resources:t.resources}),m=await s(`Creating`,async()=>d.send(h,{body:p,account_id:f,tunnel_id:t[`tunnel-id`]}));i(m,{successLabel:`Created`})})},Q={command:`management-token`,describe:`Operations for management-token`,builder:e=>e.command(Z).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};function ne(e){return e.usage(`$0 tunnels token get <tunnel-id>
|
|
26
26
|
|
|
27
|
-
Retrieves the token used to run cloudflared and associate it with a specific Cloudflare Tunnel. Treat the token as a secret.`).positional(`tunnel-id`,{type:`string`,description:`UUID of the tunnel.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const re={command:`get <tunnel-id>`,describe:`Get a Cloudflare Tunnel token`,builder:ne,handler:async t=>d({command:`tunnels token get`,classification:{safeFlags:[`dry-run`]}},t,async()=>{if(t.dryRun){let e=await a();n({command:`cf tunnels token get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/cfd_tunnel/${t[`tunnel-id`]==null?`<tunnel-id>`:encodeURIComponent(String(t[`tunnel-id`]))}/token`,pathParams:{"tunnel-id":String(t[`tunnel-id`]??``)},bodyKind:`none`});return}let c=await e(t),l=t.local?r:await o();t.accountId=l;let u=await s(`Loading`,async()=>c.send(g,{account_id:l,tunnel_id:t[`tunnel-id`]}));i(u,{successLabel:`Loaded`})})},ie={command:`token`,describe:`Operations for token`,builder:e=>e.command(re).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var ae=_(`diag`,`Create a diagnostic report from a local cloudflared instance.`,()=>import(`./command-
|
|
27
|
+
Retrieves the token used to run cloudflared and associate it with a specific Cloudflare Tunnel. Treat the token as a secret.`).positional(`tunnel-id`,{type:`string`,description:`UUID of the tunnel.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const re={command:`get <tunnel-id>`,describe:`Get a Cloudflare Tunnel token`,builder:ne,handler:async t=>d({command:`tunnels token get`,classification:{safeFlags:[`dry-run`]}},t,async()=>{if(t.dryRun){let e=await a();n({command:`cf tunnels token get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/cfd_tunnel/${t[`tunnel-id`]==null?`<tunnel-id>`:encodeURIComponent(String(t[`tunnel-id`]))}/token`,pathParams:{"tunnel-id":String(t[`tunnel-id`]??``)},bodyKind:`none`});return}let c=await e(t),l=t.local?r:await o();t.accountId=l;let u=await s(`Loading`,async()=>c.send(g,{account_id:l,tunnel_id:t[`tunnel-id`]}));i(u,{successLabel:`Loaded`})})},ie={command:`token`,describe:`Operations for token`,builder:e=>e.command(re).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var ae=_(`diag`,`Create a diagnostic report from a local cloudflared instance.`,()=>import(`./command-aeKPI1bt.mjs`),{command:`tunnels diag`,recordArgs:!1}),oe=_(`login`,`Authorize cloudflared and download an origin certificate for locally managed tunnels.`,()=>import(`./command-s15KaL-x.mjs`),{command:`tunnels login`,recordArgs:!1}),$=_(`quick-start <url>`,`Expose a local URL with a temporary trycloudflare.com tunnel. The tunnel remains active until cf exits.`,()=>import(`./command-B6ustzcW.mjs`),{command:`tunnels quick-start`,recordArgs:!1}),se=_(`ready`,`Check the /ready endpoint exposed by a local cloudflared instance.`,()=>import(`./command-C2HYwGn_.mjs`),{command:`tunnels ready`,recordArgs:!1}),ce=_(`run [tunnel]`,`Run a named Cloudflare Tunnel using the cf-managed cloudflared binary.`,()=>import(`./command-Xqidhyr_.mjs`),{command:`tunnels run`,recordArgs:!1}),le=_(`tail [tunnel-id]`,`Stream logs from a remote cloudflared instance.`,()=>import(`./command-DoXuskBZ.mjs`),{command:`tunnels tail`,recordArgs:!1});const ue={command:`tunnels`,describe:`tunnels`,builder:e=>e.command(L).command(B).command(v(ae,`preview`)).command(U).command(K).command(Y).command(v(oe,`preview`)).command(v($,`preview`)).command(v(se,`preview`)).command(v(ce,`preview`)).command(v(le,`preview`)).command(C).command(A).command(P).command(Q).command(ie).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};export{ue as default};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{r as n,t as r}from"./body-parser-HN91kAf0.mjs";import{a as i,t as a}from"./context-DlFhI9cN.mjs";import{t as o}from"./dry-run-mrA7FFLR.mjs";import{n as s}from"./input-validation-D7z60HJH.mjs";import{t as c}from"./local-B3zt9PXR.mjs";import{t as l}from"./run-DAg7dfIW.mjs";import{t as u}from"./output-PRKYaJuo.mjs";import{t as d}from"./progress-AML-AVs4.mjs";import{a as f,i as p,n as m}from"./prompt-Bnon9lfK.mjs";import"./telemetry-DDs3zhdw.mjs";var h={method:`POST`,path:t=>e`/accounts/${t.account_id}/challenges/widgets`,query:[`page`,`per_page`,`order`,`direction`,`filter`],body:`json`};function g(e){return e.usage(`$0 turnstile widgets create
|
|
3
3
|
|
|
4
4
|
Creates a Turnstile widget for an account.`).option(`page`,{type:`number`,description:`Page number of paginated results.`}).option(`per-page`,{type:`number`,description:`Number of items per page.`}).option(`order`,{type:`string`,description:`Field to order widgets by.`,choices:[`id`,`sitekey`,`name`,`created_on`,`modified_on`]}).option(`direction`,{type:`string`,description:`Direction to order widgets.`,choices:[`asc`,`desc`]}).option(`filter`,{type:`string`,description:"Filter widgets by field. The `name` field uses case-insensitive\nsubstring matching; `sitekey` uses exact matching.\nFormat: `field:value`\n\nSupported fields:\n- `name` - Filter by widget name (e.g., `filter=name:login-form`)\n- `sitekey` - Filter by sitekey (e.g., `filter=sitekey:0x4AAA`)\n\nReturns 400 Bad Request if the field is unsupported or format is invalid.\nAn empty filter value returns all results."}).option(`bot-fight-mode`,{type:`boolean`,description:`If bot_fight_mode is set to \`true\`, Cloudflare issues computationally
|
|
5
5
|
expensive challenges in response to malicious bots (ENT only).
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
export{n as getUpdateNotice,r as maybeStartBackgroundUpdateCheck}from"./update-check-
|
|
2
|
+
export{n as getUpdateNotice,r as maybeStartBackgroundUpdateCheck}from"./update-check-D3axIoUi.mjs";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{r as e,t}from"./rolldown-runtime-BNtqjh-B.mjs";import{a as n}from"./cf-
|
|
2
|
+
import{r as e,t}from"./rolldown-runtime-BNtqjh-B.mjs";import{a as n}from"./cf-QIG83e0V.mjs";import{r,t as i}from"./gt-BV-jij5q.mjs";import{n as a}from"./version-pcpa_kv3.mjs";import{closeSync as o,mkdirSync as s,openSync as c,readFileSync as l,renameSync as u,statSync as d,unlinkSync as f,writeFileSync as p}from"node:fs";import{dirname as m,join as h}from"node:path";import{fileURLToPath as g}from"node:url";import{spawn as _}from"node:child_process";var v=/* @__PURE__ */ t(((e,t)=>{let n=r();t.exports=(e,t)=>new n(e,t).major})),y=/* @__PURE__ */ t(((e,t)=>{let n=r();t.exports=(e,t,r=!1)=>{if(e instanceof n)return e;try{return new n(e,t)}catch(e){if(!r)return null;throw e}}})),b=/* @__PURE__ */ t(((e,t)=>{let n=y();t.exports=(e,t)=>{let r=n(e,t);return r&&r.prerelease.length?r.prerelease:null}})),x=/* @__PURE__ */ t(((e,t)=>{let n=y();t.exports=(e,t)=>{let r=n(e,t);return r?r.version:null}})),S=/* @__PURE__ */ e(i(),1),C=/* @__PURE__ */ e(v(),1),w=/* @__PURE__ */ e(b(),1),T=/* @__PURE__ */ e(x(),1);const E=864e5;function D(e){return(0,w.default)(e)?.includes(`beta`)?`beta`:`latest`}function O(e=a){return h(n(),`cache`,`update-check-${D(e)}.json`)}function k(e=O()){try{let t=JSON.parse(l(e,`utf8`));if(typeof t!=`object`||!t||Array.isArray(t))return{};let n=t;return{lastAttemptedAt:typeof n.lastAttemptedAt==`number`&&Number.isFinite(n.lastAttemptedAt)?n.lastAttemptedAt:void 0,lastSuccessfulAt:typeof n.lastSuccessfulAt==`number`&&Number.isFinite(n.lastSuccessfulAt)?n.lastSuccessfulAt:void 0,latestVersion:typeof n.latestVersion==`string`&&(0,T.default)(n.latestVersion)?n.latestVersion:void 0}}catch{return{}}}function A(e,t=O()){let n=`${t}.${process.pid}.tmp`;try{return s(m(t),{recursive:!0}),p(n,`${JSON.stringify(e)}\n`,{encoding:`utf8`,mode:384}),u(n,t),!0}catch{try{f(n)}catch{}return!1}}function j(e,t,n){let r=`${e}.lock`,i;try{s(m(e),{recursive:!0});try{i=c(r,`wx`,384)}catch{try{if(t-d(r).mtimeMs<=5e3)return;f(r),i=c(r,`wx`,384)}catch{return}}return n()}catch{return}finally{if(i!==void 0)try{o(i),f(r)}catch{}}}function M(e,t){if(!(0,T.default)(e)||!t.latestVersion||!(0,S.default)(t.latestVersion,e))return;let n=(0,C.default)(t.latestVersion)>(0,C.default)(e);return{latestVersion:t.latestVersion,isMajor:n}}function N(e,t=O(e)){return M(e,k(t))}function P(){let e=import.meta.url.endsWith(`.ts`),t=new URL(e?`../update-check-worker.ts`:`./update-check-worker.mjs`,import.meta.url),n=e?[...process.execArgv,g(t)]:[g(t)];_(process.execPath,n,{detached:!0,stdio:`ignore`,windowsHide:!0}).unref()}function F(e={}){let t=e.cachePath??O(e.currentVersion??a),n=e.now??Date.now();if(j(t,n,()=>{let e=k(t);return e.lastAttemptedAt!==void 0&&n-e.lastAttemptedAt<864e5?!1:A({...e,lastAttemptedAt:n},t)}))try{(e.spawnWorker??P)()}catch{}}async function I(e,t,n,r){if(!(0,T.default)(t))return{status:`failed`};let i=await r(`https://registry.npmjs.org/${encodeURIComponent(e)}/${n}`,{headers:{accept:`application/json`,"user-agent":`cf-cli/${a}`},signal:AbortSignal.timeout(3e3)});if(!i.ok)return{status:`failed`};let o=await i.json();if(typeof o!=`object`||!o||Array.isArray(o))return{status:`failed`};let s=o;return s.name!==e||typeof s.version!=`string`||!(0,T.default)(s.version)?{status:`failed`}:(0,S.default)(s.version,t)?{status:`update-available`,latest:s.version}:{status:`up-to-date`}}async function L(e={}){let t=e.currentVersion??a,n=e.cachePath??O(t),r=e.now??Date.now();try{let i=await(e.check??((t,n,r)=>I(t,n,r,e.fetch??globalThis.fetch)))(`cf`,t,`latest`);if(i.status===`failed`)return;let a=i.status===`update-available`?i.latest:t;if(!(0,T.default)(a))return;A({...k(n),latestVersion:a,lastSuccessfulAt:r},n)}catch{}}export{L as i,N as n,F as r,E as t};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{i as e}from"./update-check-
|
|
2
|
+
import{i as e}from"./update-check-D3axIoUi.mjs";await e();export{};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{i as n}from"./context-DlFhI9cN.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{t as i}from"./output-PRKYaJuo.mjs";import{t as a}from"./progress-AML-AVs4.mjs";import{t as o}from"./run-DAg7dfIW.mjs";import{i as s,n as c}from"./prompt-Bnon9lfK.mjs";import"./telemetry-DDs3zhdw.mjs";import{r as l,t as u}from"./body-parser-HN91kAf0.mjs";import{n as d}from"./input-validation-D7z60HJH.mjs";var f={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/url_normalization`,response:!1};function p(e){return e.usage(`$0 url-normalization delete
|
|
3
3
|
|
|
4
4
|
Deletes the URL Normalization settings.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`force`,{type:`boolean`,alias:`f`,description:`Skip confirmation (useful in scripts and CI)`,default:!1})}const m={command:`delete`,describe:`Delete URL Normalization settings`,builder:p,handler:async e=>o({command:`url-normalization delete`,classification:{safeFlags:[`dry-run`,`force`],shortFlagAliases:{f:{canonical:`force`,type:`boolean`}}}},e,async()=>{if(e.dryRun){r({command:`cf url-normalization delete`,method:`DELETE`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/url_normalization`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let o=await t(e),s=await n({zone:e.zone},o,{quiet:e.quiet});if(e.zoneId=s,!await c({force:!!e.force}))return;let l=await a(`Deleting`,async()=>o.send(f,{zone_id:s}));i(l,{successLabel:`Deleted`})})};var h={method:`GET`,path:t=>e`/zones/${t.zone_id}/url_normalization`};function g(e){return e.usage(`$0 url-normalization get
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{n as e}from"./auth-
|
|
2
|
+
import{n as e}from"./auth-cj71dGxS.mjs";import{t}from"./path-DRw6Y-nd.mjs";import{t as n}from"./dry-run-mrA7FFLR.mjs";import{t as r}from"./local-B3zt9PXR.mjs";import{a as i,t as a}from"./context-DlFhI9cN.mjs";import{t as o}from"./progress-AML-AVs4.mjs";import{n as s,t as c}from"./raw-fetch-0T1SwPa1.mjs";import"./telemetry-DDs3zhdw.mjs";import{t as l}from"./run-DAg7dfIW.mjs";import"./api-Dnt6lRJG.mjs";import{i as u,r as d,t as f}from"./body-parser-HN91kAf0.mjs";import{t as p}from"./output-PRKYaJuo.mjs";import{n as m}from"./input-validation-D7z60HJH.mjs";import{a as h}from"./prompt-Bnon9lfK.mjs";function g(e){return e.usage("$0 url-scanner responses get <response-id>\n\nReturns the raw response of the network request. Find the `response_id` in the `data.requests.response.hash`.").positional(`response-id`,{type:`string`,description:`Response hash.`,demandOption:!0}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const _={command:`get <response-id>`,describe:`Get raw response`,builder:g,handler:async t=>l({command:`url-scanner responses get`,classification:{safeFlags:[`dry-run`]}},t,async()=>{if(t.dryRun){let e=await i();n({command:`cf url-scanner responses get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/urlscanner/v2/responses/${t[`response-id`]==null?`<response-id>`:encodeURIComponent(String(t[`response-id`]))}`,pathParams:{"response-id":String(t[`response-id`]??``)},bodyKind:`none`});return}await e(t);let l=t.local?r:await a();t.accountId=l;let u=await o(`Loading`,async()=>c(`/accounts/${l}/urlscanner/v2/responses/${encodeURIComponent(String(t[`response-id`]))}`,{method:`GET`,local:t.local===!0,persistTo:t.persistTo}));s(u.toString(`utf-8`))})},v={command:`responses`,describe:`Raw HTTP response data captured during URL scans`,builder:e=>e.command(_).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var y={method:`POST`,path:e=>t`/accounts/${e.account_id}/urlscanner/v2/bulk`,body:`json`,errors:{400:`BadRequestError`,429:`TooManyRequestsError`}};function b(e){return e.usage(`$0 url-scanner scans bulk-create
|
|
3
3
|
|
|
4
4
|
Submit URLs to scan. Check limits at https://developers.cloudflare.com/security-center/investigate/scan-limits/ and take into account scans submitted in bulk have lower priority and may take longer to finish.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`List of urls to scan (up to a 100).`})}const x={command:`bulk-create`,describe:`Bulk create URL Scans`,builder:b,handler:async t=>l({command:`url-scanner scans bulk-create`,classification:{safeFlags:[`dry-run`]}},t,async()=>{if(t.dryRun){let e=await i();n({command:`cf url-scanner scans bulk-create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${e??`<account-id>`}/urlscanner/v2/bulk`,pathParams:{},bodyKind:`json`,body:t.body===void 0?void 0:d(t.body)});return}if(t.body===void 0)throw Error(`--body is required for this command. Pass --body '<json>' or --body @path/to/file.json.`);let s=t.body===void 0?void 0:d(t.body),c=await e(t),l=t.local?r:await a();if(t.accountId=l,t.body!==void 0){let e=s,t=await o(`Creating`,async()=>c.send(y,{body:e,account_id:l}));p(t,{successLabel:`Created`})}})};var S={method:`POST`,path:e=>t`/accounts/${e.account_id}/urlscanner/v2/scan`,body:`json`,errors:{400:`BadRequestError`,409:`ConflictError`,429:`TooManyRequestsError`}};function C(e){return e.usage(`$0 url-scanner scans create
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import{n as e,o as t}from"./auth-
|
|
2
|
+
import{n as e,o as t}from"./auth-cj71dGxS.mjs";import{t as n}from"./path-DRw6Y-nd.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{t as i}from"./output-PRKYaJuo.mjs";import{t as a}from"./progress-AML-AVs4.mjs";import"./telemetry-DDs3zhdw.mjs";import{i as o,o as s,r as c,t as l}from"./body-parser-HN91kAf0.mjs";import{n as u}from"./input-validation-D7z60HJH.mjs";import{t as d}from"./run-DAg7dfIW.mjs";import{a as f,i as p,n as m}from"./prompt-Bnon9lfK.mjs";import"./api-Dnt6lRJG.mjs";import{t as ee}from"./get-CRKvqCu6.mjs";import{t as te}from"./verify-BCuWaO-L.mjs";var h={method:`GET`,path:()=>`/user/audit_logs`,query:[`id`,`export`,`action.type`,`actor.ip`,`actor.email`,`since`,`before`,`zone.name`,`direction`,`per_page`,`page`,`hide_user_logs`]};function ne(e){return e.usage(`$0 user audit-logs list
|
|
3
3
|
|
|
4
4
|
Gets a list of audit logs for a user account. Can be filtered by who made the change, on which zone, and the timeframe of the change.`).option(`id`,{type:`string`,description:`Finds a specific log by its ID.`}).option(`export`,{type:`boolean`,description:`Indicates that this request is an export of logs in CSV format.`}).option(`action-type`,{type:`string`,description:`Filters by the action type.`}).option(`actor-ip`,{type:`string`,description:`Filters by the IP address of the request that made the change by specific IP address or valid CIDR Range.`}).option(`actor-email`,{type:`string`,description:`Filters by the email address of the actor that made the change.`}).option(`since`,{type:`string`,description:`Since`}).option(`before`,{type:`string`,description:`Before`}).option(`zone-name`,{type:`string`,description:`Filters by the name of the zone associated to the change.`}).option(`direction`,{type:`string`,description:`Changes the direction of the chronological sorting.`,choices:[`desc`,`asc`]}).option(`per-page`,{type:`number`,description:`Sets the number of results to return per page.`}).option(`page`,{type:`number`,description:`Defines which page of results to return.`}).option(`hide-user-logs`,{type:`boolean`,description:`Indicates whether or not to hide user level audit logs.`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const re={command:`list`,describe:`Get user audit logs`,builder:ne,handler:async t=>d({command:`user audit-logs list`,classification:{safeFlags:[`export`,`direction`,`hide-user-logs`,`dry-run`]}},t,async()=>{let n={id:t.id,export:t.export,"action.type":t[`action-type`],"actor.ip":t[`actor-ip`],"actor.email":t[`actor-email`],since:t.since,before:t.before,"zone.name":t[`zone-name`],direction:t.direction,per_page:t[`per-page`],page:t.page,hide_user_logs:t[`hide-user-logs`]};if(t.dryRun){r({command:`cf user audit-logs list`,method:`GET`,url:`https://api.cloudflare.com/client/v4/user/audit_logs`,pathParams:{},query:n,bodyKind:`none`});return}let o=await e(t),s=await a(`Loading`,async()=>o.send(h,n));i(s,{successLabel:`Loaded`})})},ie={command:`audit-logs`,describe:`Operations for audit-logs`,builder:e=>e.command(re).demandCommand(1,`Please specify a subcommand`),handler:()=>{}};var ae={method:`GET`,path:()=>`/user/billing/history`,query:[`page`,`per_page`,`order`,`occurred_at`,`type`,`action`]};function oe(e){return e.usage(`$0 user billing history list
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{i as t,n}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{i as t,n}from"./auth-cj71dGxS.mjs";import{i as r,r as i,t as a}from"./body-parser-HN91kAf0.mjs";import{a as o,t as s}from"./context-DlFhI9cN.mjs";import{t as c}from"./dry-run-mrA7FFLR.mjs";import{n as l,t as u}from"./input-validation-D7z60HJH.mjs";import{t as d}from"./local-B3zt9PXR.mjs";import{t as f}from"./run-DAg7dfIW.mjs";import{t as p}from"./output-PRKYaJuo.mjs";import{t as m}from"./progress-AML-AVs4.mjs";import{a as h,i as g,n as _}from"./prompt-Bnon9lfK.mjs";import"./telemetry-DDs3zhdw.mjs";var v={method:`POST`,path:t=>e`/accounts/${t.account_id}/vectorize/v2/indexes`,body:`json`};function y(e){return e.usage(`$0 vectorize create
|
|
3
3
|
|
|
4
4
|
Creates and returns a new Vectorize Index.`).option(`index-config-dimensions`,{type:`number`,description:`Specifies the number of dimensions for the index`}).option(`index-config-metric`,{type:`string`,description:`Specifies the type of metric to use calculating distance.`,choices:[`cosine`,`euclidean`,`dot-product`]}).coerce(`index-config-metric`,e=>l(e,`index-config-metric`,`text`)).option(`index-config-preset`,{type:`string`,description:`Specifies the preset to use for the index.`,choices:[`@cf/baai/bge-small-en-v1.5`,`@cf/baai/bge-base-en-v1.5`,`@cf/baai/bge-large-en-v1.5`,`openai/text-embedding-ada-002`,`cohere/embed-multilingual-v2.0`]}).coerce(`index-config-preset`,e=>l(e,`index-config-preset`,`text`)).option(`description`,{type:`string`,description:`Specifies the description of the index.`}).option(`name`,{type:`string`,description:`The name field`}).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`}).conflicts(`index-config-dimensions`,[`index-config-preset`]).implies(`index-config-dimensions`,[`index-config-metric`]).conflicts(`index-config-metric`,[`index-config-preset`]).implies(`index-config-metric`,[`index-config-dimensions`]).conflicts(`index-config-preset`,[`index-config-dimensions`,`index-config-metric`])}const b={command:`create`,describe:`Create Vectorize Index`,builder:y,handler:async e=>f({command:`vectorize create`,classification:{safeFlags:[`index-config-metric`,`index-config-preset`,`dry-run`]}},e,async()=>{if(e.dryRun){let t=await o();c({command:`cf vectorize create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/accounts/${t??`<account-id>`}/vectorize/v2/indexes`,pathParams:{},bodyKind:`json`,body:e.body===void 0?a({config:{dimensions:e[`index-config-dimensions`],metric:e[`index-config-metric`],preset:e[`index-config-preset`]},description:l(e.description,`description`,`text`),name:l(e.name,`name`,`text`)}):i(e.body)});return}let t=e.body===void 0?void 0:i(e.body),r=await n(e),u=e.local?d:await s();if(e.accountId=u,e.body!==void 0){let e=t,n=await m(`Creating`,async()=>r.send(v,{body:e,account_id:u}));p(n,{successLabel:`Created`});return}e.name===void 0&&(e.name=await h(`name`,`The name field`));let f=a({config:{dimensions:e[`index-config-dimensions`],metric:e[`index-config-metric`],preset:e[`index-config-preset`]},description:l(e.description,`description`,`text`),name:l(e.name,`name`,`text`)}),g=await m(`Creating`,async()=>r.send(v,{body:f,account_id:u}));p(g,{successLabel:`Created`})})};var x={method:`POST`,path:t=>e`/accounts/${t.account_id}/vectorize/v2/indexes/${t.index_name}/delete_by_ids`,body:`json`};function S(e){return e.usage(`$0 vectorize delete-by-ids <index-name>
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{t as n}from"./dry-run-mrA7FFLR.mjs";import{a as r,i,t as a}from"./context-DlFhI9cN.mjs";import{t as o}from"./local-B3zt9PXR.mjs";import{t as s}from"./output-PRKYaJuo.mjs";import{t as c}from"./progress-AML-AVs4.mjs";import{t as l}from"./run-DAg7dfIW.mjs";import"./telemetry-DDs3zhdw.mjs";import{o as u,r as d,t as f}from"./body-parser-HN91kAf0.mjs";import{n as p}from"./input-validation-D7z60HJH.mjs";import{a as m,i as h,n as g}from"./prompt-Bnon9lfK.mjs";var _={method:`GET`,path:t=>e`/${t.account_or_zone}/${t.account_or_zone_id}/waiting_rooms`,query:[`page`,`per_page`]};function ee(e){return e.usage(`$0 waiting-rooms account-waiting-rooms list
|
|
3
3
|
|
|
4
4
|
Lists waiting rooms for account or zone.
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{i as n}from"./context-DlFhI9cN.mjs";import{t as r}from"./dry-run-mrA7FFLR.mjs";import{t as i}from"./output-PRKYaJuo.mjs";import{t as a}from"./progress-AML-AVs4.mjs";import{t as o}from"./run-DAg7dfIW.mjs";import"./telemetry-DDs3zhdw.mjs";import{i as s,r as c,t as l}from"./body-parser-HN91kAf0.mjs";import{n as u}from"./input-validation-D7z60HJH.mjs";import{a as d,i as f,n as p}from"./prompt-Bnon9lfK.mjs";var m={method:`GET`,path:t=>e`/zones/${t.zone_id}/api_gateway/discovery`};function h(e){return e.usage(`$0 web-assets discovery get
|
|
3
3
|
|
|
4
4
|
Returns the latest API operations discovered from zone traffic, rendered as OpenAPI schemas.`).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1})}const ee={command:`get`,describe:`Export discovered API operations as OpenAPI schemas`,builder:h,handler:async e=>o({command:`web-assets discovery get`,classification:{safeFlags:[`dry-run`]}},e,async()=>{if(e.dryRun){r({command:`cf web-assets discovery get`,method:`GET`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/api_gateway/discovery`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`none`});return}let o=await t(e),s=await n({zone:e.zone},o,{quiet:e.quiet});e.zoneId=s;let c=await a(`Loading`,async()=>o.send(m,{zone_id:s}));i(c,{successLabel:`Loaded`})})};var g={method:`PATCH`,path:t=>e`/zones/${t.zone_id}/api_gateway/discovery/operations`,body:`json`};function te(e){return e.usage(`$0 web-assets discovery operations bulk-edit
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-
|
|
2
|
+
import"./api-Dnt6lRJG.mjs";import{t as e}from"./path-DRw6Y-nd.mjs";import{n as t}from"./auth-cj71dGxS.mjs";import{i as n}from"./context-DlFhI9cN.mjs";import{o as r,r as i,t as a}from"./body-parser-HN91kAf0.mjs";import{t as o}from"./dry-run-mrA7FFLR.mjs";import{n as s}from"./input-validation-D7z60HJH.mjs";import{t as c}from"./run-DAg7dfIW.mjs";import{t as l}from"./output-PRKYaJuo.mjs";import{t as u}from"./progress-AML-AVs4.mjs";import{a as d,i as f,n as p}from"./prompt-Bnon9lfK.mjs";import"./telemetry-DDs3zhdw.mjs";var m={method:`POST`,path:t=>e`/zones/${t.zone_id}/web3/hostnames`,body:`json`};function h(e){return e.usage(`$0 web3 hostnames create
|
|
3
3
|
|
|
4
4
|
Create Web3 Hostname`).option(`description`,{type:`string`,description:`Specify an optional description of the hostname.`}).option(`dnslink`,{type:`string`,description:`Specify the DNSLink value used if the target is ipfs.`}).option(`name`,{type:`string`,description:`Specify the hostname that points to the target gateway via CNAME.`}).option(`target`,{type:`string`,description:`Specify the target gateway of the hostname.`,choices:[`ethereum`,`ipfs`,`ipfs_universal_path`]}).coerce(`target`,e=>s(e,`target`,`text`)).option(`dry-run`,{type:`boolean`,description:`Validate and show what would happen without executing`,default:!1}).option(`body`,{type:`string`,description:`Raw JSON request body (bypasses individual flags)`})}const g={command:`create`,describe:`Create Web3 Hostname`,builder:h,handler:async e=>c({command:`web3 hostnames create`,classification:{safeFlags:[`target`,`dry-run`]}},e,async()=>{if(e.dryRun){o({command:`cf web3 hostnames create`,method:`POST`,url:`https://api.cloudflare.com/client/v4/zones/${e.zone??e.zoneId??`<zone>`}/web3/hostnames`,pathParams:{"zone-id":String(e.zone??e[`zone-id`]??``)},bodyKind:`json`,body:e.body===void 0?a({description:s(e.description,`description`,`text`),dnslink:s(e.dnslink,`dnslink`,`text`),name:s(e.name,`name`,`text`),target:e.target}):i(e.body)});return}let r=e.body===void 0?void 0:i(e.body),c=await t(e),p=await n({zone:e.zone},c,{quiet:e.quiet});if(e.zoneId=p,e.body!==void 0){let e=r,t=await u(`Creating`,async()=>c.send(m,{body:e,zone_id:p}));l(t,{successLabel:`Created`});return}e.name===void 0&&(e.name=await d(`name`,`Specify the hostname that points to the target gateway via CNAME.`)),e.target===void 0&&(e.target=await f(`target`,`Specify the target gateway of the hostname.`,[`ethereum`,`ipfs`,`ipfs_universal_path`]));let h=a({description:s(e.description,`description`,`text`),dnslink:s(e.dnslink,`dnslink`,`text`),name:s(e.name,`name`,`text`),target:e.target}),g=await u(`Creating`,async()=>c.send(m,{body:h,zone_id:p}));l(g,{successLabel:`Created`})})};var _={method:`DELETE`,path:t=>e`/zones/${t.zone_id}/web3/hostnames/${t.identifier}`,body:`json`};function v(e){return e.usage(`$0 web3 hostnames delete <identifier>
|
|
5
5
|
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import{d as e,l as t}from"./chunk-Q5KVZMHK-Bjvrcihk.mjs";import{r as n}from"./theme-BGHWSKCw.mjs";import{t as r}from"./agent-context-Dtyy4aKL.mjs";import{t as i}from"./auth-token-D9MnaZ-L.mjs";import{i as a}from"./blocks-DK5qAzLe.mjs";import{n as o}from"./interactive-wQM7Blhm.mjs";import{f as s,i as c,o as l,r as u,t as d}from"./oauth-BUcV_xbm.mjs";import{t as f}from"./output-PRKYaJuo.mjs";import{r as p}from"./session-BEsQIuwP.mjs";import"./ui-CY75N4Tm.mjs";import{t as m}from"./string-width-D6-CGlwN.mjs";import{t as h}from"./log-Brx-wjJW.mjs";import{t as g}from"./sanitize-DHx5dAJu.mjs";import{n as _,t as v}from"./disk-cache-nbuwH1Dh.mjs";import{t as y}from"./cf-QIG83e0V.mjs";const b=`oauth-scopes`;function x(e){if(!Array.isArray(e))return;let t=[];for(let n of e){let{id:e,name:r,category:i}=n??{};typeof e==`string`&&t.push({id:e,name:typeof r==`string`?r:e,...typeof i==`string`&&{category:i}})}return t.length>0?t:void 0}function S(e){return new Map(e.map(e=>[e.id,e]))}async function C(e){let t=v(b,[],864e5,x);if(t)return S(t);let[n,{default:r}]=await Promise.all([e(),import(`./list-4MfEFwJN.mjs`)]),i=await n.send(r),a=x(typeof i==`object`&&i&&`result`in i?i.result:i);if(!a)throw Error(`the API returned an unexpected scope catalogue`);return _(b,[],a),S(a)}const w={account_and_billing:`Account & Billing`,ai_and_machine_learning:`AI & Machine Learning`,analytics_and_logs:`Analytics & Logs`,app_security:`App Security`,cache_and_performance:`Cache & Performance`,cloudflare_one_and_zero_trust:`Cloudflare One / Zero Trust`,developer_platform:`Developer Platform`,dns_and_zones:`DNS & Zones`,email_and_messaging:`Email & Messaging`,media:`Media`,network_services:`Network Services`,other:`Other`,rules_and_configuration:`Rules & Configuration`},T=`Uncategorized`,E=[`Other`,T],D=new Set(y),O=/* @__PURE__ */ new Set([`read`,`metadata_read`]),k=/^(.+)([.:])([^.:]+)$/;function A(e){return w[e]??e.split(`_`).map(e=>e===`and`?`&`:e.charAt(0).toUpperCase()+e.slice(1)).join(` `)}function j(e,t){return E.indexOf(e)-E.indexOf(t)||e.localeCompare(t)}function M(e){return e.some(e=>k.test(e))}function N(e,t){let n=/* @__PURE__ */ new Map;for(let r of e){let e=k.exec(r);if(!e?.[1]||!e[3])continue;let i=t.get(r),a=i?.category?A(i.category):T,o=n.get(a)??[];o.push({scope:r,resource:e[1],action:e[3]}),n.set(a,o)}return n}function P(e,t,n){let r=t.get(e)??[],i=n.get(e)?.length??0,a=r.filter(({scope:e})=>D.has(e)).length,o=r.length-a,s=i>0?[`${a}/${i}`]:[];return o>0&&s.push(`${o} custom`),s.join(` + `)}function F(e,t){let r=N(e,t),i=N(y,t),a=[...r.keys()].sort(j);if(a.length===0)return``;let o=Math.max(...a.map(e=>e.length));return a.map(e=>`${n.bold(n.info(e.padEnd(o)))} ${n.muted(P(e,r,i))}`).join(`
|
|
3
|
+
`)}const I=e=>` ${e.toLowerCase().replace(/[^a-z0-9]+/g,` `)}`,L=e=>e.toLowerCase().replaceAll(`_`,`-`);function R(e,t){return I(e).includes(I(t).trimEnd())}function z(e){let t=/* @__PURE__ */ new Set([T]);for(let{category:n}of e.values())n&&t.add(A(n));return[...t].sort(j)}function B(e,t,{product:r=``,filter:i=``}={}){let a=N(e,t),o=N(y,t),s=[];for(let e of[...a.keys()].sort(j)){if(!R(e,r))continue;let t=(a.get(e)??[]).filter(({scope:e})=>L(e).includes(L(i)));if(t.length===0)continue;let c=[`${n.bold(n.info(e))} ${n.muted(`(${P(e,a,o)})`)}`],l=/* @__PURE__ */ new Map,u=[...t].sort((e,t)=>Number(!O.has(e.action))-Number(!O.has(t.action))||e.action.localeCompare(t.action));for(let{scope:e,resource:t,action:r}of u){let i=(O.has(r)?n.muted(r):n.warning(r))+(D.has(e)?``:n.muted(` (custom)`));l.set(t,(l.get(t)??/* @__PURE__ */ new Set).add(i))}let d=Math.max(...[...l.keys()].map(e=>e.length));for(let[e,t]of[...l].sort(([e],[t])=>e.localeCompare(t)))c.push(` ${e.padEnd(d)} ${[...t].join(`, `)}`);s.push(c.join(`
|
|
4
|
+
`))}return s.join(`
|
|
5
|
+
|
|
6
|
+
`)}const V={"--profile":`selected by --profile`,CLOUDFLARE_AUTH_PROFILE:`selected by CLOUDFLARE_AUTH_PROFILE`,directory:`activated for this directory`,default:`default profile`},H=`Use --json to see all information in a JSON object.`;function U(e,t){if(!e.authenticated)return`Not authenticated`;if(e.tokenValid===!1)return`Not authenticated (API token disabled or expired)`;let r=t===`oauth`?`OAuth`:`API Token`;if(e.tokenValid===null)return`Unable to verify authentication via ${r}`;let i=e.email?`${n.bold(n.info(g(e.email)))} ${n.muted(`via ${r}`)}`:n.muted(`via ${r} (email unavailable)`);return`${n.bold(`Authenticated`)}\n${i}`}async function W({result:e,method:t,tokenVariable:r,accountsAvailable:i},a){let o=[U(e,t)],s=g(e.profile.name);if(e.profile.name!=="default"&&o.push(`Active profile: ${n.bold(s)} ${n.muted(`(${V[e.profile.source]}${e.profile.overridden?`; overridden by ${g(r??`environment API token`)}`:``})`)}`),!e.authenticated)console.log(o.join(`
|
|
7
|
+
`)),h.warn(t===`oauth`?`Could not refresh your OAuth credentials. Check your connection or log in again.`:`Log in to authenticate with Cloudflare.`,e.profile.name==="default"?`cf auth login${t===`oauth`?` --force`:``}`:`cf auth create ${s}`),h.info(H);else{if(o.push(``,n.bold(`Accounts`)),!i)o.push(`Unavailable; could not list accounts with these credentials`);else if(e.accounts.length===0)o.push(`No accessible accounts`);else{let t=[...e.accounts].sort((e,t)=>e.name.localeCompare(t.name)||e.id.localeCompare(t.id)).map(({name:e,id:t})=>({name:g(e),id:g(t)})),r=Math.max(...t.map(({name:e})=>m(e)));for(let{name:e,id:i}of t){let t=` `.repeat(r-m(e));o.push(`${n.bold(n.info(e))}${t} ${n.muted(i)}`)}}if(t===`api-token`)o.push(``,`Scopes: API token permissions are not available here`);else if(e.scopes===void 0)o.push(``,`Scopes: Not recorded for this OAuth login`);else if(o.push(``,n.bold(`OAuth scopes (${e.scopes.length} granted)`)),!M(e.scopes))o.push(` No product scopes granted`);else try{let t=await C(async()=>{let{createCommandClient:e}=await import(`./auth-CXR2vsII.mjs`);return e(a)});o.push(F(e.scopes,t))}catch{o.push(` Product grouping unavailable; could not load the scope catalogue`)}console.log(o.join(`
|
|
8
|
+
`)),t===`oauth`&&e.scopes&&M(e.scopes)&&h.info(`View granted permissions by product or list every scope:`,`cf auth scopes <product>`,`cf auth scopes --all`),h.info(H)}}function G(t,n){return{name:u(),source:t.profile?`--profile`:e()?`CLOUDFLARE_AUTH_PROFILE`:l().bindings.getProfileForDirectory(process.cwd())?`directory`:`default`,overridden:n}}const K={command:`whoami`,describe:`Show current user and authentication status`,builder:e=>e.option(`json`,{type:`boolean`,description:`Show full JSON (default for CI, non-interactive runs and agents; use --no-json for a summary)`}).middleware(()=>p(),!0),handler:async e=>{if(e[`temporary-account`]||e[`event-code`]!==void 0)throw Error(`--temporary-account and --event-code are not supported by cf auth whoami.`);let n=t(),l=n?process.env.CLOUDFLARE_API_TOKEN?`CLOUDFLARE_API_TOKEN`:`CF_API_TOKEN`:void 0,u=n?void 0:s(),p=G(e,!!n),m=e.json??(o(process.stdout)||r().isAgentic),h=n?`api-token`:u?.oauth_token?`oauth`:`none`,g;g=n?`${l} environment variable`:u?.oauth_token?`OAuth token from ${c()}`:`none`;try{await i()}catch{let t={result:{authenticated:!1,error:`Not logged in`,profile:p},method:h,tokenVariable:l,accountsAvailable:!1};m?f(t.result,{highlight:!1}):await W(t,e),g===`none`&&r().isAgentic&&console.error(a('Ask the user: "I can put this online for 60 minutes without you signing in. To keep it, complete the temporary-account claim before it expires. Would you like me to deploy it that way?" (https://developers.cloudflare.com/workers/platform/claim-deployments/) If they agree, run `cf deploy --temporary-account`.'));return}let{createCommandClient:_}=await import(`./auth-CXR2vsII.mjs`),{default:v}=await import(`./get-BTisquA3.mjs`),{default:y}=await import(`./verify-B9ILCohg.mjs`),b=await _(e),x,S=[],[C,w,T]=await Promise.allSettled([n?b.send(y):Promise.resolve(void 0),b.send(v),d()]);if(C.status===`rejected`&&process.env.DEBUG&&console.error(`Token verification error:`,C.reason),w.status===`fulfilled`){let e=w.value;e&&`email`in e&&typeof e.email==`string`&&(x=e.email)}else process.env.DEBUG&&console.error(`User lookup error:`,w.reason);T.status===`fulfilled`?S=T.value:process.env.DEBUG&&console.error(`Account lookup error:`,T.reason);let E=null;C.status===`fulfilled`&&[`active`,`disabled`,`expired`].includes(C.value?.status??``)?E=C.value?.status===`active`:(w.status===`fulfilled`||T.status===`fulfilled`)&&(E=!0);let D={authenticated:!0,authSource:g,tokenValid:E,...x&&{email:x},accounts:S,profile:p},O=n?void 0:s();O?.oauth_token&&(D.scopes=O.scopes,D.expiresAt=O.expiration_time),m?f(D,{highlight:!1}):await W({result:D,method:h,tokenVariable:l,accountsAvailable:T.status===`fulfilled`},e)}};export{M as a,F as i,z as n,R as o,B as r,C as s,K as t};
|