@builtbyfriends/bwf 0.0.0-stage → 1.9.2
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/AGENTS_TEMPLATE.md +4 -0
- package/LICENSE +22 -0
- package/README.md +48 -2
- package/dist/account-cmd-Ddt8lGeL.mjs +45 -0
- package/dist/agents-BLiMq9E1.mjs +113 -0
- package/dist/application-analysis-C9Ck2Yeg.mjs +1498 -0
- package/dist/application-routing-DbR-W5lG.mjs +25 -0
- package/dist/atomic-write-DA6eD1Kp.mjs +17 -0
- package/dist/auth-BKsUmWbT.d.mts +77 -0
- package/dist/auth-DkvoW5hB.mjs +33 -0
- package/dist/auth-aKyIWkdS.mjs +1 -0
- package/dist/auth-client-6-Ft9i9T.d.mts +5 -0
- package/dist/auth-client-DwCdwKbw.mjs +5 -0
- package/dist/auth-client-react-CJdeErvM.mjs +5 -0
- package/dist/auth-client-react-DvQLe5Zb.d.mts +5 -0
- package/dist/auth-link-CCl-hJol.mjs +26 -0
- package/dist/auth-migrations-DDeifS3v.mjs +206 -0
- package/dist/auth-router-BG74WFUf.mjs +66 -0
- package/dist/auth-xnkmpZUl.mjs +311 -0
- package/dist/base64-ikl9yBy3.mjs +15 -0
- package/dist/better-auth-shared-Br6TNaYJ.mjs +473 -0
- package/dist/better-auth-shared-CsBNvPOU.d.mts +56 -0
- package/dist/build-cmd-BnZezraT.mjs +153 -0
- package/dist/build-output-dir-Clj_unKN.mjs +402 -0
- package/dist/cancel-deploy-DKAj5U1Z.mjs +57 -0
- package/dist/cf-access-Bhz9wX6p.mjs +131 -0
- package/dist/cf-access-CUP5L08W.mjs +67 -0
- package/dist/cf-build-output-DA6uJomQ.mjs +1 -0
- package/dist/cf-build-output-DNQTwMNU.mjs +438 -0
- package/dist/cf-command-values-2kOtxMo1.mjs +26 -0
- package/dist/cf-config-migrate-COOCi4Ge.mjs +330 -0
- package/dist/cf-worker-settings-CIh4t_yG.mjs +41 -0
- package/dist/cli/cli.d.mts +1 -0
- package/dist/cli/cli.mjs +88 -0
- package/dist/cli/cloudflare-operation-process.d.mts +1 -0
- package/dist/cli/cloudflare-operation-process.mjs +1284 -0
- package/dist/cli/env-schema-probe.d.mts +43 -0
- package/dist/cli/env-schema-probe.mjs +165 -0
- package/dist/cli-main-BfYf6fnB.mjs +1846 -0
- package/dist/client-D3D5RM5h.mjs +940 -0
- package/dist/client-VF2Nzc7Z.mjs +1 -0
- package/dist/cloudflare-auth-DzkU9H6r.mjs +152 -0
- package/dist/cloudflare-cmd-Bm6UhzAQ.mjs +59 -0
- package/dist/cloudflare-config-i8yanry0.mjs +186 -0
- package/dist/cloudflare-connect-B4ItSbJi.mjs +55 -0
- package/dist/cloudflare-operations-BcK849ue.mjs +1 -0
- package/dist/cloudflare-operations-DGF7xH7O.mjs +627 -0
- package/dist/cloudflare-process-tThIjEB2.mjs +309 -0
- package/dist/cloudflare-user-output-CqONaAbP.mjs +19 -0
- package/dist/collect-8i0wU63d.mjs +1 -0
- package/dist/collect-C6Blu9yw.mjs +48 -0
- package/dist/config-CN_RFRkS.mjs +86 -0
- package/dist/config-D5G-Tx6o.mjs +1 -0
- package/dist/config-DOaFIK3w.mjs +88 -0
- package/dist/config-entry.d.mts +202 -0
- package/dist/config-entry.mjs +6 -0
- package/dist/config-tNx0HlFv.mjs +516 -0
- package/dist/connect-CSNWKLzB.mjs +84 -0
- package/dist/create-project-B35ux-LA.mjs +126 -0
- package/dist/create-project-tJ1KwNss.mjs +1 -0
- package/dist/database-provider-DkZo4VwN.mjs +5 -0
- package/dist/database-provider.d.mts +25 -0
- package/dist/database-provider.mjs +1 -0
- package/dist/db-SOv4E9wr.mjs +1735 -0
- package/dist/delete-BSKI7V23.mjs +65 -0
- package/dist/deploy-BCSQoKC0.mjs +2 -0
- package/dist/deploy-CWJ3JJs_.mjs +6512 -0
- package/dist/deploy.d.mts +31 -0
- package/dist/deploy.mjs +118 -0
- package/dist/dev-inbox-I0nqTCdf.mjs +216 -0
- package/dist/discover-DJPmQcL5.mjs +36 -0
- package/dist/discover-EVuydEoM.mjs +1 -0
- package/dist/dist-B6eN80gc.mjs +1612 -0
- package/dist/dist-Cp4b1_T9.mjs +1 -0
- package/dist/dist-DMYe8CZJ.mjs +48 -0
- package/dist/dist-STQXl8ck.mjs +1878 -0
- package/dist/domain-BJaAbxuQ.mjs +149 -0
- package/dist/dotenv-4NdUCXbB.mjs +156 -0
- package/dist/drizzle-DqVFXtlc.mjs +306 -0
- package/dist/drizzle-Ds5P0n-S.mjs +1 -0
- package/dist/edge.d.mts +2 -0
- package/dist/edge.mjs +1 -0
- package/dist/email-C_ATvNIG.mjs +2865 -0
- package/dist/email-cloudflare-oXk2G1G3.mjs +854 -0
- package/dist/email-protocol-CZ0bAkI8.mjs +81 -0
- package/dist/email-rIfZgVAB.mjs +742 -0
- package/dist/env-BGTu3KWZ.mjs +73 -0
- package/dist/env-DUyTzroe.mjs +88 -0
- package/dist/env-Dl4Wggec.mjs +71 -0
- package/dist/env-helpers-BX0APszT.mjs +135 -0
- package/dist/env-helpers-U56xuFgL.d.mts +20 -0
- package/dist/env-mask-BsHxq3R8.mjs +46 -0
- package/dist/env-public-Cw_xPi1D.d.mts +119 -0
- package/dist/env-raw-Bo6TtrHU.mjs +41 -0
- package/dist/env-types-Bg-dTh8u.mjs +56 -0
- package/dist/env-validation-BlXzGgLZ.mjs +1 -0
- package/dist/env-validation-DeqFUSKg.mjs +488 -0
- package/dist/fetch-CBgyyhzm.d.mts +87 -0
- package/dist/fetch-error-DmlRM6e4.mjs +264 -0
- package/dist/fetch-stream-2GUN3YN1.mjs +102 -0
- package/dist/fetch-stream-bUXynOyZ.d.mts +32 -0
- package/dist/fetch-tpPiSK10.mjs +25 -0
- package/dist/gen-dc13IRXh.mjs +509 -0
- package/dist/gen-kQqhFyOP.mjs +1 -0
- package/dist/generate-BgtlYpKg.mjs +1 -0
- package/dist/generate-Da9mWKzU.mjs +80 -0
- package/dist/generated-wrangler-config-CoDaaFsA.mjs +17 -0
- package/dist/git-metadata-Cukp5kV5.mjs +82 -0
- package/dist/github-cmd-DT5Onu6E.mjs +690 -0
- package/dist/handler-B_ocHStk.d.mts +279 -0
- package/dist/handler-CNq7aSs1.mjs +161 -0
- package/dist/help-BK35YcRa.mjs +1946 -0
- package/dist/help-DaRezBj7.mjs +1 -0
- package/dist/inbound-CqubE-9T.d.mts +311 -0
- package/dist/inbound-lHugZPuK.mjs +509 -0
- package/dist/index.d.mts +64 -0
- package/dist/index.mjs +4163 -0
- package/dist/info-CLQoCenb.mjs +109 -0
- package/dist/init-CXanf5ck.mjs +2486 -0
- package/dist/limits-CMmYT2l8.d.mts +16 -0
- package/dist/limits-D27Lp6FP.mjs +46 -0
- package/dist/link-DinwJnon.mjs +52 -0
- package/dist/list-B1WAE9Wt.mjs +130 -0
- package/dist/live-KkEeda1Z.d.mts +105 -0
- package/dist/live-saC8barp.mjs +410 -0
- package/dist/load-user-env-g0ahkZcj.mjs +34 -0
- package/dist/local-d1-bUoAtFUe.mjs +103 -0
- package/dist/log-JDnPc0cF.mjs +23 -0
- package/dist/login-BUzyiyHV.mjs +1 -0
- package/dist/login-Dbv_T3Ru.mjs +87 -0
- package/dist/logs-BjMJooJQ.mjs +129 -0
- package/dist/migrate-DjW9_-sS.mjs +1 -0
- package/dist/migrate-DtcfKqPW.mjs +125 -0
- package/dist/migration-handler-22qiuWPq.mjs +469 -0
- package/dist/migration-handler-Bb2BJh6g.d.mts +38 -0
- package/dist/mime-BMUN_QKG.mjs +1004 -0
- package/dist/mysql-migration-sql-CNuBSqdx.mjs +239 -0
- package/dist/neon-CJzQSycr.mjs +52 -0
- package/dist/node-tfv-3v0V.mjs +64 -0
- package/dist/operator-ai-logging-Ay7M4KWw.mjs +121 -0
- package/dist/operator-args-BiGmSlZx.mjs +722 -0
- package/dist/operator-auth-DdYZYEkO.mjs +47 -0
- package/dist/operator-client-DBujdELO.mjs +82 -0
- package/dist/operator-cmd-BsHKYJYt.mjs +1 -0
- package/dist/operator-cmd-DTIkOAnP.mjs +443 -0
- package/dist/output-Bb34lF0w.mjs +173 -0
- package/dist/output-CVolXKC1.mjs +1 -0
- package/dist/package-BX_giUBX.mjs +1444 -0
- package/dist/package-json-DvS6IFRv.mjs +43 -0
- package/dist/pg-DoyPxa_X.mjs +15 -0
- package/dist/picocolors-D1NxSLw-.mjs +71 -0
- package/dist/plan-BHNt1QhK.mjs +1 -0
- package/dist/plan-DX4_-OM5.mjs +58 -0
- package/dist/platform-args-C-DyuCNX.mjs +1 -0
- package/dist/platform-args-CyeQWaZ7.mjs +538 -0
- package/dist/platform-auth-config-BfXqKSyZ.mjs +371 -0
- package/dist/platform-auth-protection-5FR6qoP_.mjs +231 -0
- package/dist/platform-auth-recovery-B5ZlqA8K.mjs +309 -0
- package/dist/platform-cmd-CcFDxtrl.mjs +1 -0
- package/dist/platform-cmd-ChXeBrRH.mjs +193 -0
- package/dist/platform-discovery-Bxg9aZXU.mjs +40 -0
- package/dist/platform-domain-CwatS3cz.mjs +256 -0
- package/dist/platform-lifecycle-0cXTmMsh.mjs +8928 -0
- package/dist/platform-lifecycle-BcoBAMux.mjs +1 -0
- package/dist/platform-management-6Wbdbob5.mjs +1607 -0
- package/dist/platform-management-hhnczOzr.mjs +1 -0
- package/dist/platform-plans-config-CkbUKFpm.mjs +447 -0
- package/dist/platform-recovery-DgIwlqB-.mjs +96 -0
- package/dist/platform-registry-x1m9HBxf.mjs +450 -0
- package/dist/platform-runtime-logs-kkoiYFpF.mjs +72 -0
- package/dist/platform-setup-DX8y_6Kh.mjs +306 -0
- package/dist/prepare-B9mB47T5.mjs +84 -0
- package/dist/prepare-DNIq07so.mjs +13 -0
- package/dist/prepare-LHkyJqxi.mjs +1 -0
- package/dist/project-CC7eN00D.mjs +141 -0
- package/dist/project-DcSd4BeI.mjs +1 -0
- package/dist/project-cmd-BydRwr-x.mjs +109 -0
- package/dist/project-paths-iXHKRTTQ.mjs +159 -0
- package/dist/project-slug-BUy0lmyR.mjs +1 -0
- package/dist/project-slug-CO6ci9XG.mjs +7 -0
- package/dist/project-team-CvdLhDF2.mjs +129 -0
- package/dist/project-token-CwZdUEGu.mjs +70 -0
- package/dist/project-tsconfig-P9X952KG.mjs +98 -0
- package/dist/project-zero-trust-CKDoPdN1.mjs +64 -0
- package/dist/providers-Cd3c7wi0.mjs +64 -0
- package/dist/providers-Df69hb_X.d.mts +5 -0
- package/dist/provision-BA59NCPO.mjs +1 -0
- package/dist/provision-C90fULHJ.mjs +1814 -0
- package/dist/queues-Bc3FsBQT.d.mts +5 -0
- package/dist/r2-conditions-DSLmkiR5.mjs +60 -0
- package/dist/requests-DNhfyF3l.mjs +52 -0
- package/dist/resolve-project-BCsAMDRA.mjs +47 -0
- package/dist/resolve-project-DhU9_lIo.mjs +1 -0
- package/dist/resource-name-DlJ9QXzg.mjs +10 -0
- package/dist/response-HmNjB30w.mjs +29 -0
- package/dist/rollback-wi6WK5T6.mjs +150 -0
- package/dist/rolldown-runtime-uD8oG6U2.mjs +24 -0
- package/dist/route-types-CRWhr93D.mjs +592 -0
- package/dist/route-url-BIDZT78M.mjs +58 -0
- package/dist/route-url-Bla3Upsy.d.mts +42 -0
- package/dist/routes-stub.d.mts +24 -0
- package/dist/routes-stub.mjs +1 -0
- package/dist/routing-assets-CSheDWWM.mjs +54 -0
- package/dist/rpc-DcByS_q0.d.mts +39 -0
- package/dist/rpc-DtxIN9Tv.mjs +19 -0
- package/dist/runner-CPerdjIl.mjs +163 -0
- package/dist/runner-CUNtS5x7.mjs +1 -0
- package/dist/runner-mysql-BjSoQ-mW.mjs +1 -0
- package/dist/runner-mysql-BmTI2EiF.mjs +145 -0
- package/dist/runner-pg-2pjltt0t.mjs +1 -0
- package/dist/runner-pg-mYc75KfH.mjs +61 -0
- package/dist/runtime/ai.d.mts +50 -0
- package/dist/runtime/ai.mjs +455 -0
- package/dist/runtime/auth-client-react.d.mts +2 -0
- package/dist/runtime/auth-client-react.mjs +1 -0
- package/dist/runtime/auth-client.d.mts +2 -0
- package/dist/runtime/auth-client.mjs +1 -0
- package/dist/runtime/auth.d.mts +2 -0
- package/dist/runtime/auth.mjs +1 -0
- package/dist/runtime/better-auth-mysql.d.mts +5 -0
- package/dist/runtime/better-auth-mysql.mjs +21 -0
- package/dist/runtime/better-auth-pg.d.mts +5 -0
- package/dist/runtime/better-auth-pg.mjs +21 -0
- package/dist/runtime/better-auth.d.mts +6 -0
- package/dist/runtime/better-auth.mjs +22 -0
- package/dist/runtime/client-react.d.mts +5 -0
- package/dist/runtime/client-react.mjs +5 -0
- package/dist/runtime/client.d.mts +5 -0
- package/dist/runtime/client.mjs +5 -0
- package/dist/runtime/db-mysql.d.mts +2 -0
- package/dist/runtime/db-mysql.mjs +1 -0
- package/dist/runtime/db-pg.d.mts +2 -0
- package/dist/runtime/db-pg.mjs +1 -0
- package/dist/runtime/db.d.mts +17 -0
- package/dist/runtime/db.mjs +36 -0
- package/dist/runtime/drizzle-arktype.d.mts +1 -0
- package/dist/runtime/drizzle-arktype.mjs +2 -0
- package/dist/runtime/drizzle-valibot.d.mts +1 -0
- package/dist/runtime/drizzle-valibot.mjs +2 -0
- package/dist/runtime/drizzle-zod.d.mts +1 -0
- package/dist/runtime/drizzle-zod.mjs +2 -0
- package/dist/runtime/durable.d.mts +64 -0
- package/dist/runtime/durable.mjs +165 -0
- package/dist/runtime/email/testing.d.mts +108 -0
- package/dist/runtime/email/testing.mjs +268 -0
- package/dist/runtime/email-protocol.d.mts +25 -0
- package/dist/runtime/email-protocol.mjs +1 -0
- package/dist/runtime/email.d.mts +26 -0
- package/dist/runtime/email.mjs +524 -0
- package/dist/runtime/env-public-client.d.mts +19 -0
- package/dist/runtime/env-public-client.mjs +55 -0
- package/dist/runtime/env-public.d.mts +4 -0
- package/dist/runtime/env-public.mjs +277 -0
- package/dist/runtime/env.d.mts +12 -0
- package/dist/runtime/env.mjs +1 -0
- package/dist/runtime/fetch-server.d.mts +6 -0
- package/dist/runtime/fetch-server.mjs +29 -0
- package/dist/runtime/fetch-stream.d.mts +3 -0
- package/dist/runtime/fetch-stream.mjs +3 -0
- package/dist/runtime/fetch.d.mts +2 -0
- package/dist/runtime/fetch.mjs +3 -0
- package/dist/runtime/handler.d.mts +3 -0
- package/dist/runtime/handler.mjs +1 -0
- package/dist/runtime/kv.d.mts +45 -0
- package/dist/runtime/kv.mjs +103 -0
- package/dist/runtime/limits.d.mts +2 -0
- package/dist/runtime/limits.mjs +1 -0
- package/dist/runtime/live-client.d.mts +40 -0
- package/dist/runtime/live-client.mjs +282 -0
- package/dist/runtime/live-server.d.mts +11 -0
- package/dist/runtime/live-server.mjs +419 -0
- package/dist/runtime/live.d.mts +3 -0
- package/dist/runtime/live.mjs +1 -0
- package/dist/runtime/log.d.mts +24 -0
- package/dist/runtime/log.mjs +57 -0
- package/dist/runtime/migration-handler-mysql.d.mts +2 -0
- package/dist/runtime/migration-handler-mysql.mjs +111 -0
- package/dist/runtime/migration-handler-pg.d.mts +2 -0
- package/dist/runtime/migration-handler-pg.mjs +94 -0
- package/dist/runtime/migration-handler.d.mts +2 -0
- package/dist/runtime/migration-handler.mjs +1 -0
- package/dist/runtime/procedure.d.mts +27 -0
- package/dist/runtime/procedure.mjs +36 -0
- package/dist/runtime/procedures.d.mts +24 -0
- package/dist/runtime/procedures.mjs +56 -0
- package/dist/runtime/queues.d.mts +2 -0
- package/dist/runtime/queues.mjs +8 -0
- package/dist/runtime/remote/binding-handler.d.mts +11 -0
- package/dist/runtime/remote/binding-handler.mjs +227 -0
- package/dist/runtime/remote/index.d.mts +12 -0
- package/dist/runtime/remote/index.mjs +467 -0
- package/dist/runtime/response.d.mts +11 -0
- package/dist/runtime/response.mjs +1 -0
- package/dist/runtime/route-url.d.mts +2 -0
- package/dist/runtime/route-url.mjs +1 -0
- package/dist/runtime/routing.d.mts +53 -0
- package/dist/runtime/routing.mjs +425 -0
- package/dist/runtime/rpc-react.d.mts +16 -0
- package/dist/runtime/rpc-react.mjs +50 -0
- package/dist/runtime/rpc.d.mts +2 -0
- package/dist/runtime/rpc.mjs +1 -0
- package/dist/runtime/sandbox-container.d.mts +3 -0
- package/dist/runtime/sandbox-container.mjs +1 -0
- package/dist/runtime/sandbox.d.mts +5 -0
- package/dist/runtime/sandbox.mjs +196 -0
- package/dist/runtime/schema-d1.d.mts +1 -0
- package/dist/runtime/schema-d1.mjs +2 -0
- package/dist/runtime/schema-mysql.d.mts +1 -0
- package/dist/runtime/schema-mysql.mjs +2 -0
- package/dist/runtime/schema-pg.d.mts +1 -0
- package/dist/runtime/schema-pg.mjs +2 -0
- package/dist/runtime/seed.d.mts +34 -0
- package/dist/runtime/seed.mjs +5 -0
- package/dist/runtime/sse-client.d.mts +31 -0
- package/dist/runtime/sse-client.mjs +42 -0
- package/dist/runtime/sse.d.mts +32 -0
- package/dist/runtime/sse.mjs +1 -0
- package/dist/runtime/storage.d.mts +4 -0
- package/dist/runtime/storage.mjs +13 -0
- package/dist/runtime/validator.d.mts +2 -0
- package/dist/runtime/validator.mjs +1 -0
- package/dist/runtime/ws-server.d.mts +26 -0
- package/dist/runtime/ws-server.mjs +297 -0
- package/dist/runtime/ws.d.mts +2 -0
- package/dist/runtime/ws.mjs +108 -0
- package/dist/sandbox-CWDjoEG2.d.mts +50 -0
- package/dist/sandbox-container-BqamdFCx.d.mts +73 -0
- package/dist/sandbox-container-d1AHLpgn.mjs +291 -0
- package/dist/secret-D5XrWshs.mjs +146 -0
- package/dist/skills-Dr3AjuBF.mjs +63 -0
- package/dist/sqlite-validation-CLJXXN93.mjs +24 -0
- package/dist/sse-CxR30yMF.mjs +174 -0
- package/dist/standard-schema-CuDawHOC.d.mts +40 -0
- package/dist/static-asset-marker-mWMX2dLa.mjs +38 -0
- package/dist/subcommand-prompt-B9yUo--u.mjs +370 -0
- package/dist/terminal-log-text-DNsWJREL.mjs +31 -0
- package/dist/types-D7-4tBu7.d.mts +1 -0
- package/dist/untrusted-env-lL7RkYiC.mjs +50 -0
- package/dist/validate-B-zsjhiz.mjs +162 -0
- package/dist/validate-DbqGdPPY.mjs +1 -0
- package/dist/validator-8-NZs2Xr.mjs +168 -0
- package/dist/version-metadata-DPhqnpaa.mjs +23 -0
- package/dist/wrangler-C3uyPadQ.mjs +1 -0
- package/dist/wrangler-TqTvJFWS.mjs +1452 -0
- package/dist/ws-DZRiIpYw.d.mts +137 -0
- package/dist/yarn-pnp-DgWbE7z5.mjs +91 -0
- package/docs/guide/ai.md +273 -0
- package/docs/guide/app-types.md +101 -0
- package/docs/guide/auth.md +255 -0
- package/docs/guide/database/d1.md +86 -0
- package/docs/guide/database/mysql.md +72 -0
- package/docs/guide/database/postgresql.md +94 -0
- package/docs/guide/database.md +454 -0
- package/docs/guide/deployment.md +124 -0
- package/docs/guide/durable-state.md +192 -0
- package/docs/guide/edge/headers.md +47 -0
- package/docs/guide/edge/redirects.md +85 -0
- package/docs/guide/edge/rewrites.md +119 -0
- package/docs/guide/edge/static-assets.md +94 -0
- package/docs/guide/email/domains.md +119 -0
- package/docs/guide/email/receiving.md +142 -0
- package/docs/guide/email/sending.md +262 -0
- package/docs/guide/email.md +23 -0
- package/docs/guide/env-vars.md +115 -0
- package/docs/guide/index.md +37 -0
- package/docs/guide/jobs.md +80 -0
- package/docs/guide/kv.md +100 -0
- package/docs/guide/live.md +181 -0
- package/docs/guide/platform/administration/access.md +165 -0
- package/docs/guide/platform/administration/connected-apps.md +84 -0
- package/docs/guide/platform/administration/email.md +169 -0
- package/docs/guide/platform/administration/operations.md +100 -0
- package/docs/guide/platform/administration/plans.md +156 -0
- package/docs/guide/platform/administration/projects.md +74 -0
- package/docs/guide/platform/administration/zero-trust.md +205 -0
- package/docs/guide/platform/development/local.md +122 -0
- package/docs/guide/platform/development/runtime.md +115 -0
- package/docs/guide/platform/development/schema-ci.md +44 -0
- package/docs/guide/platform/installation/ci.md +62 -0
- package/docs/guide/platform/installation/credentials.md +140 -0
- package/docs/guide/platform/installation/domains.md +120 -0
- package/docs/guide/platform/installation/first-deployment.md +95 -0
- package/docs/guide/platform/installation/maintenance.md +250 -0
- package/docs/guide/platform/installation/prerequisites.md +176 -0
- package/docs/guide/platform/installation/setup.md +300 -0
- package/docs/guide/platform/installation/uninstall.md +110 -0
- package/docs/guide/platform-administration.md +19 -0
- package/docs/guide/platform-development.md +16 -0
- package/docs/guide/procedures.md +48 -0
- package/docs/guide/project-collaboration.md +99 -0
- package/docs/guide/queues.md +149 -0
- package/docs/guide/quickstart.md +129 -0
- package/docs/guide/remote-dev.md +67 -0
- package/docs/guide/sandboxes.md +134 -0
- package/docs/guide/self-hosted-platform.md +45 -0
- package/docs/guide/server-routing.md +283 -0
- package/docs/guide/sse.md +174 -0
- package/docs/guide/storage.md +82 -0
- package/docs/guide/testing.md +64 -0
- package/docs/guide/type-safety.md +270 -0
- package/docs/guide/typed-fetch.md +98 -0
- package/docs/guide/websockets.md +230 -0
- package/docs/index.md +102 -0
- package/docs/integrations/agents.md +38 -0
- package/docs/integrations/cloudflare.md +241 -0
- package/docs/integrations/hono.md +127 -0
- package/docs/reference/api/auth.md +195 -0
- package/docs/reference/api/client.md +90 -0
- package/docs/reference/api/database.md +118 -0
- package/docs/reference/api/deploy.md +63 -0
- package/docs/reference/api/durable.md +47 -0
- package/docs/reference/api/env.md +51 -0
- package/docs/reference/api/handlers.md +189 -0
- package/docs/reference/api/plugin.md +40 -0
- package/docs/reference/api/resources.md +116 -0
- package/docs/reference/api/rewrites.md +111 -0
- package/docs/reference/api/types.md +126 -0
- package/docs/reference/api.md +71 -0
- package/docs/reference/cli/auth.md +87 -0
- package/docs/reference/cli/database.md +159 -0
- package/docs/reference/cli/deploy.md +117 -0
- package/docs/reference/cli/domains.md +42 -0
- package/docs/reference/cli/email.md +145 -0
- package/docs/reference/cli/generate.md +113 -0
- package/docs/reference/cli/github.md +181 -0
- package/docs/reference/cli/platform-config.md +93 -0
- package/docs/reference/cli/platform-email.md +81 -0
- package/docs/reference/cli/platform-installation.md +166 -0
- package/docs/reference/cli/platform-operations.md +90 -0
- package/docs/reference/cli/platform-users.md +159 -0
- package/docs/reference/cli/platform-zero-trust.md +60 -0
- package/docs/reference/cli/platform.md +78 -0
- package/docs/reference/cli/project.md +208 -0
- package/docs/reference/cli/secrets.md +79 -0
- package/docs/reference/cli/setup.md +88 -0
- package/docs/reference/cli.md +115 -0
- package/docs/reference/config.md +478 -0
- package/docs/reference/resource-inference.md +72 -0
- package/docs/reference/structure.md +138 -0
- package/package.json +389 -3
- package/sandbox.Dockerfile +4 -0
- package/schema.json +353 -0
- package/skills/bwf/SKILL.md +100 -0
- package/skills/migrate-vite-cloudflare-to-bwf/SKILL.md +53 -0
- package/templates/assets/bwf.svg +5 -0
- package/templates/assets/icons.svg +49 -0
- package/templates/assets/react.svg +1 -0
- package/templates/assets/stack.svg +35 -0
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { UsageLimitData, UsageLimitData as UsageLimitData$1, readUsageLimit as readUsageLimit$1 } from "@builtbyfriends/edge";
|
|
2
|
+
declare class UsageLimit extends Error {
|
|
3
|
+
override readonly name: string;
|
|
4
|
+
readonly code: "usage_limit";
|
|
5
|
+
readonly resource: UsageLimitData["resource"];
|
|
6
|
+
readonly reason: UsageLimitData["reason"];
|
|
7
|
+
readonly retryAt?: string;
|
|
8
|
+
constructor(data: Omit<UsageLimitData, "code">);
|
|
9
|
+
response(options?: {
|
|
10
|
+
message?: string;
|
|
11
|
+
}): Response;
|
|
12
|
+
getResponse(): Response;
|
|
13
|
+
}
|
|
14
|
+
declare function asUsageLimit(error: unknown): UsageLimit | null;
|
|
15
|
+
declare function limitFromResponse(response: Response, resource: UsageLimitData["resource"]): Promise<UsageLimit | null>;
|
|
16
|
+
export { readUsageLimit$1 as a, limitFromResponse as i, UsageLimitData$1 as n, asUsageLimit as r, UsageLimit as t };
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { readUsageLimit, readUsageLimit as readUsageLimit$1, usageLimitResponse } from "@builtbyfriends/edge";
|
|
2
|
+
// src/runtime/limits.ts
|
|
3
|
+
var UsageLimit = class extends Error {
|
|
4
|
+
name = "UsageLimit";
|
|
5
|
+
code = "usage_limit";
|
|
6
|
+
resource;
|
|
7
|
+
reason;
|
|
8
|
+
retryAt;
|
|
9
|
+
constructor(data) {
|
|
10
|
+
super(data.message);
|
|
11
|
+
this.resource = data.resource;
|
|
12
|
+
this.reason = data.reason;
|
|
13
|
+
this.retryAt = data.retryAt;
|
|
14
|
+
}
|
|
15
|
+
response(options = {}) {
|
|
16
|
+
return usageLimitResponse({
|
|
17
|
+
code: this.code,
|
|
18
|
+
resource: this.resource,
|
|
19
|
+
reason: this.reason,
|
|
20
|
+
message: options.message ?? this.message,
|
|
21
|
+
...this.retryAt ? { retryAt: this.retryAt } : {}
|
|
22
|
+
});
|
|
23
|
+
}
|
|
24
|
+
getResponse() {
|
|
25
|
+
return this.response();
|
|
26
|
+
}
|
|
27
|
+
};
|
|
28
|
+
function asUsageLimit(error) {
|
|
29
|
+
if (error instanceof UsageLimit) return error;
|
|
30
|
+
const data = readUsageLimit(error);
|
|
31
|
+
return data ? new UsageLimit(data) : null;
|
|
32
|
+
}
|
|
33
|
+
async function limitFromResponse(response, resource) {
|
|
34
|
+
if (response.status !== 429) return null;
|
|
35
|
+
const data = readUsageLimit(await response.clone().json().catch(() => null));
|
|
36
|
+
if (data) return new UsageLimit(data);
|
|
37
|
+
const retry = response.headers.get("retry-after");
|
|
38
|
+
const retryTime = retry === null ? NaN : /^\d+$/.test(retry) ? Date.now() + Number(retry) * 1e3 : Date.parse(retry);
|
|
39
|
+
return new UsageLimit({
|
|
40
|
+
resource,
|
|
41
|
+
reason: "rate_limit",
|
|
42
|
+
message: `${resource === "ai" ? "AI" : "Service"} is temporarily unavailable because its usage limit was reached.`,
|
|
43
|
+
...Number.isFinite(retryTime) ? { retryAt: new Date(retryTime).toISOString() } : {}
|
|
44
|
+
});
|
|
45
|
+
}
|
|
46
|
+
export { readUsageLimit$1 as i, asUsageLimit as n, limitFromResponse as r, UsageLimit as t };
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { H as outro, L as log, O as cancel } from "./dist-STQXl8ck.mjs";
|
|
2
|
+
import { c as getToken, s as getSiteDomain } from "./auth-xnkmpZUl.mjs";
|
|
3
|
+
import { r as PlatformClient } from "./client-D3D5RM5h.mjs";
|
|
4
|
+
import { a as promptProjectSelection, r as promptAndCreateProject } from "./create-project-B35ux-LA.mjs";
|
|
5
|
+
import { f as import_picocolors, m as printSuccess } from "./output-Bb34lF0w.mjs";
|
|
6
|
+
import { l as writeProjectConfig, r as readProjectConfig, t as attachSelectedPlatform } from "./project-CC7eN00D.mjs";
|
|
7
|
+
import { a as resolveProjectBySlug } from "./resolve-project-BCsAMDRA.mjs";
|
|
8
|
+
// src/cli/link.ts
|
|
9
|
+
function projectLabel(slug, root, url) {
|
|
10
|
+
if (url) return url;
|
|
11
|
+
const domain = getSiteDomain(root);
|
|
12
|
+
return domain.endsWith(".workers.dev") ? `${import_picocolors.default.blue(slug)} (workers.dev)` : `${import_picocolors.default.blue(slug)}.${domain}`;
|
|
13
|
+
}
|
|
14
|
+
async function runLink(root, slug) {
|
|
15
|
+
console.log();
|
|
16
|
+
const existing = readProjectConfig(root);
|
|
17
|
+
if (existing) {
|
|
18
|
+
log.warn(`Already linked to ${projectLabel(existing.slug, root)}`);
|
|
19
|
+
outro("To re-link, delete .bwf/project.json and run again.");
|
|
20
|
+
return;
|
|
21
|
+
}
|
|
22
|
+
const token = getToken(root);
|
|
23
|
+
if (!token) {
|
|
24
|
+
cancel("No auth token found. Run `bwf account login` first.");
|
|
25
|
+
process.exit(1);
|
|
26
|
+
}
|
|
27
|
+
const client = new PlatformClient(token, { root });
|
|
28
|
+
const projects = await client.listProjects();
|
|
29
|
+
if (slug) {
|
|
30
|
+
const resolved = resolveProjectBySlug(projects, slug);
|
|
31
|
+
if (!resolved) {
|
|
32
|
+
cancel(`project: No project found with slug '${slug}'.`);
|
|
33
|
+
process.exit(1);
|
|
34
|
+
}
|
|
35
|
+
const config = attachSelectedPlatform(resolved, client.apiUrl);
|
|
36
|
+
writeProjectConfig(root, config);
|
|
37
|
+
printSuccess(`Linked to ${projectLabel(config.slug, root, projects.find((project) => project.id === config.projectId)?.url)}`);
|
|
38
|
+
return;
|
|
39
|
+
}
|
|
40
|
+
const result = await promptProjectSelection(projects, "Select a project:", root, { confirmExisting: true });
|
|
41
|
+
if (result.action === "create") {
|
|
42
|
+
const config = await promptAndCreateProject(root, client);
|
|
43
|
+
printSuccess(`Created and linked to ${projectLabel(config.slug, root)}`);
|
|
44
|
+
return;
|
|
45
|
+
}
|
|
46
|
+
writeProjectConfig(root, attachSelectedPlatform({
|
|
47
|
+
projectId: result.project.id,
|
|
48
|
+
slug: result.project.slug
|
|
49
|
+
}, client.apiUrl));
|
|
50
|
+
printSuccess(`Linked to ${projectLabel(result.project.slug, root, result.project.url)}`);
|
|
51
|
+
}
|
|
52
|
+
export { runLink };
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
import { H as outro, L as log } from "./dist-STQXl8ck.mjs";
|
|
2
|
+
import { c as getToken } from "./auth-xnkmpZUl.mjs";
|
|
3
|
+
import { r as PlatformClient } from "./client-D3D5RM5h.mjs";
|
|
4
|
+
import { _ as tablePrefix, c as formatRelativeTime, f as import_picocolors, h as sanitizeTerminalText, i as dim, o as formatCount } from "./output-Bb34lF0w.mjs";
|
|
5
|
+
import { n as readDeploymentPlatform, r as readProjectConfig } from "./project-CC7eN00D.mjs";
|
|
6
|
+
import { a as resolveProjectBySlug } from "./resolve-project-BCsAMDRA.mjs";
|
|
7
|
+
// src/cli/list.ts
|
|
8
|
+
async function runListCommand(root, slug) {
|
|
9
|
+
console.log();
|
|
10
|
+
const platform = readDeploymentPlatform(root);
|
|
11
|
+
if (platform === "cloudflare") return showCloudflareDeployments(root, slug);
|
|
12
|
+
if (platform === "none") throw new Error("project: Deployment is disabled. Run `bwf init` to choose a platform.");
|
|
13
|
+
const token = getToken(root);
|
|
14
|
+
if (!token) {
|
|
15
|
+
log.error("Not logged in. Run `bwf account login` first.");
|
|
16
|
+
process.exit(1);
|
|
17
|
+
}
|
|
18
|
+
let projectId;
|
|
19
|
+
let projectSlug;
|
|
20
|
+
let client;
|
|
21
|
+
if (slug) {
|
|
22
|
+
client = new PlatformClient(token, { root });
|
|
23
|
+
const projects = await client.listProjects();
|
|
24
|
+
const config = resolveProjectBySlug(projects, slug);
|
|
25
|
+
if (!config) {
|
|
26
|
+
log.error(`project: No project found with slug '${slug}'.`);
|
|
27
|
+
process.exit(1);
|
|
28
|
+
}
|
|
29
|
+
projectId = config.projectId;
|
|
30
|
+
projectSlug = slug;
|
|
31
|
+
} else {
|
|
32
|
+
const linked = readProjectConfig(root);
|
|
33
|
+
if (!linked) {
|
|
34
|
+
log.error("No linked project found. Pass a project name: bwf project status <name>");
|
|
35
|
+
process.exit(1);
|
|
36
|
+
}
|
|
37
|
+
projectId = linked.projectId;
|
|
38
|
+
projectSlug = linked.slug;
|
|
39
|
+
client = new PlatformClient(token, { root });
|
|
40
|
+
}
|
|
41
|
+
await showDeployments(client, projectId, projectSlug);
|
|
42
|
+
}
|
|
43
|
+
async function showCloudflareDeployments(root, slug) {
|
|
44
|
+
if (slug) throw new Error("project: A project name selects a bwf platform project and is not used for direct Cloudflare apps.");
|
|
45
|
+
const { readCloudflareWorkerStatus, resolveCloudflareOperationContext } = await import("./cloudflare-operations-BcK849ue.mjs");
|
|
46
|
+
const status = await readCloudflareWorkerStatus(resolveCloudflareOperationContext(root));
|
|
47
|
+
if (status.versions.length === 0) {
|
|
48
|
+
outro(`No deployments for ${status.workerName}.`);
|
|
49
|
+
return;
|
|
50
|
+
}
|
|
51
|
+
const rows = [...status.versions].reverse().map((version) => ({
|
|
52
|
+
id: version.id,
|
|
53
|
+
status: version.id === status.activeVersionId ? "live" : "available",
|
|
54
|
+
migrations: version.metadata?.migrations ? String(version.metadata.migrations.length) : "-",
|
|
55
|
+
deployed: version.createdAt ? formatRelativeTime(version.createdAt) : "-"
|
|
56
|
+
}));
|
|
57
|
+
const idWidth = Math.max(2, ...rows.map((row) => row.id.length));
|
|
58
|
+
const statusWidth = Math.max(6, ...rows.map((row) => row.status.length));
|
|
59
|
+
const prefix = tablePrefix();
|
|
60
|
+
console.log(prefix);
|
|
61
|
+
console.log(`${prefix}${dim(`${"id".padEnd(idWidth)} ${"status".padEnd(statusWidth)} migrations deployed`)}`);
|
|
62
|
+
for (const row of rows) {
|
|
63
|
+
const renderedStatus = row.status === "live" ? import_picocolors.default.bold(import_picocolors.default.green(row.status)) : dim(row.status);
|
|
64
|
+
console.log(`${prefix}${row.id.padEnd(idWidth)} ${renderedStatus}${"".padEnd(statusWidth - row.status.length)} ${row.migrations.padEnd(10)} ${row.deployed}`);
|
|
65
|
+
}
|
|
66
|
+
outro(`${status.workerName} — ${formatCount(rows.length, "version")}`);
|
|
67
|
+
}
|
|
68
|
+
async function showDeployments(client, projectId, slug) {
|
|
69
|
+
const { deployments, activeDeploymentId, warnings } = await client.listDeployments(projectId);
|
|
70
|
+
for (const warning of warnings ?? []) log.warn(sanitizeTerminalText(warning));
|
|
71
|
+
if (deployments.length === 0) {
|
|
72
|
+
outro(`No deployments for ${slug}.`);
|
|
73
|
+
return;
|
|
74
|
+
}
|
|
75
|
+
const latest = deployments[0];
|
|
76
|
+
if (latest.status === "failed" && latest.error_message) log.error(`project: Latest deploy failed: '${latest.error_message}'.`);
|
|
77
|
+
const rows = deployments.map((d) => formatDeploymentRow(d, activeDeploymentId));
|
|
78
|
+
const idWidth = Math.max(2, ...rows.map((r) => r.id.length));
|
|
79
|
+
const typeWidth = Math.max(4, ...rows.map((r) => r.appType.length));
|
|
80
|
+
const statusWidth = Math.max(6, ...rows.map((r) => r.statusRaw.length));
|
|
81
|
+
const sourceWidth = Math.max(6, ...rows.map((r) => r.source.length));
|
|
82
|
+
const commitWidth = Math.max(6, ...rows.map((r) => r.commit.length));
|
|
83
|
+
const prefix = tablePrefix();
|
|
84
|
+
const header = `${prefix}${dim(`${"id".padEnd(idWidth)} ${"type".padEnd(typeWidth)} ${"status".padEnd(statusWidth)} ${"source".padEnd(sourceWidth)} ${"commit".padEnd(commitWidth)} deployed`)}`;
|
|
85
|
+
const lines = rows.map((row) => `${prefix}${row.id.padEnd(idWidth)} ${row.appType.padEnd(typeWidth)} ${row.statusColored}${"".padEnd(statusWidth - row.statusRaw.length)} ${row.source.padEnd(sourceWidth)} ${row.commit.padEnd(commitWidth)} ${row.deployed}`);
|
|
86
|
+
console.log(prefix);
|
|
87
|
+
console.log(header);
|
|
88
|
+
for (const line of lines) console.log(line);
|
|
89
|
+
outro(`${slug} — ${formatCount(deployments.length, "deployment")}`);
|
|
90
|
+
}
|
|
91
|
+
function computeDisplayStatus(d, activeDeploymentId) {
|
|
92
|
+
if (d.status === "failed") return "failed";
|
|
93
|
+
if (d.status !== "live") return d.status;
|
|
94
|
+
if (d.id === activeDeploymentId) return "live";
|
|
95
|
+
if (d.retained) return "retained";
|
|
96
|
+
return "evicted";
|
|
97
|
+
}
|
|
98
|
+
function colorStatus(status) {
|
|
99
|
+
switch (status) {
|
|
100
|
+
case "live": return import_picocolors.default.bold(import_picocolors.default.green(status));
|
|
101
|
+
case "retained": return dim(import_picocolors.default.green(status));
|
|
102
|
+
case "evicted": return dim(status);
|
|
103
|
+
case "failed":
|
|
104
|
+
case "canceled": return import_picocolors.default.red(status);
|
|
105
|
+
case "canceling": return import_picocolors.default.yellow(status);
|
|
106
|
+
default: return status;
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
function formatDeploymentRow(d, activeDeploymentId) {
|
|
110
|
+
let manifest = null;
|
|
111
|
+
if (d.manifest) try {
|
|
112
|
+
manifest = JSON.parse(d.manifest);
|
|
113
|
+
} catch {}
|
|
114
|
+
const appType = manifest?.type ?? (manifest?.framework ? "framework" : "nosam");
|
|
115
|
+
const source = d.source ?? "-";
|
|
116
|
+
const commit = d.commit ? d.commit.slice(0, 7) : "-";
|
|
117
|
+
const statusRaw = computeDisplayStatus(d, activeDeploymentId);
|
|
118
|
+
const statusColored = colorStatus(statusRaw);
|
|
119
|
+
const deployed = d.deployed_at ? formatRelativeTime(d.deployed_at) : "-";
|
|
120
|
+
return {
|
|
121
|
+
id: d.id,
|
|
122
|
+
appType,
|
|
123
|
+
statusRaw,
|
|
124
|
+
statusColored,
|
|
125
|
+
source,
|
|
126
|
+
commit,
|
|
127
|
+
deployed
|
|
128
|
+
};
|
|
129
|
+
}
|
|
130
|
+
export { runListCommand };
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
import { i as AuthUser } from "./auth-BKsUmWbT.mjs";
|
|
2
|
+
import { i as CloudContext, o as CloudEnv } from "./handler-B_ocHStk.mjs";
|
|
3
|
+
type MaybePromise<T> = T | Promise<T>;
|
|
4
|
+
type LiveControlRequest = {
|
|
5
|
+
connectionId: string;
|
|
6
|
+
operations: Array<LiveControlOperation>;
|
|
7
|
+
};
|
|
8
|
+
type LiveControlOperation = {
|
|
9
|
+
kind: "subscribe";
|
|
10
|
+
id: string;
|
|
11
|
+
topic: string;
|
|
12
|
+
lastEventId?: string;
|
|
13
|
+
} | {
|
|
14
|
+
kind: "unsubscribe";
|
|
15
|
+
id: string;
|
|
16
|
+
};
|
|
17
|
+
type LiveControlErrorCode = "BAD_REQUEST" | "CONNECTION_CLOSED" | "CONNECTION_NOT_FOUND" | "FORBIDDEN" | "INVALID_SUBSCRIPTION_ID" | "INVALID_TOPIC" | "OWNER_MISMATCH" | "SUBSCRIPTION_LIMIT" | "TOPIC_FULL" | "PAYLOAD_TOO_LARGE" | "INTERNAL_ERROR";
|
|
18
|
+
type LiveControlError = {
|
|
19
|
+
code: LiveControlErrorCode;
|
|
20
|
+
message: string;
|
|
21
|
+
};
|
|
22
|
+
type LiveControlOperationResult = {
|
|
23
|
+
ok: true;
|
|
24
|
+
kind: "subscribe" | "unsubscribe";
|
|
25
|
+
id: string;
|
|
26
|
+
topic?: string;
|
|
27
|
+
} | {
|
|
28
|
+
ok: false;
|
|
29
|
+
kind: "subscribe" | "unsubscribe";
|
|
30
|
+
id: string;
|
|
31
|
+
error: LiveControlError;
|
|
32
|
+
};
|
|
33
|
+
type LiveControlResponse = {
|
|
34
|
+
accepted: true;
|
|
35
|
+
connectionId: string;
|
|
36
|
+
results: Array<LiveControlOperationResult>;
|
|
37
|
+
} | {
|
|
38
|
+
accepted: false;
|
|
39
|
+
error: LiveControlError;
|
|
40
|
+
};
|
|
41
|
+
type LiveClientEvent<Data = unknown> = {
|
|
42
|
+
subscriptionId: string;
|
|
43
|
+
topic: string;
|
|
44
|
+
type?: string;
|
|
45
|
+
eventId?: string;
|
|
46
|
+
data: Data;
|
|
47
|
+
};
|
|
48
|
+
type LivePublishOptions = {
|
|
49
|
+
type?: string;
|
|
50
|
+
eventId?: string;
|
|
51
|
+
};
|
|
52
|
+
type LiveConnectOptions = {
|
|
53
|
+
owner?: string | null;
|
|
54
|
+
user?: unknown;
|
|
55
|
+
};
|
|
56
|
+
type LiveControlOptions = LiveConnectOptions;
|
|
57
|
+
type LiveHookContext = {
|
|
58
|
+
request: Request;
|
|
59
|
+
env: CloudEnv["Bindings"];
|
|
60
|
+
user: AuthUser | unknown | null;
|
|
61
|
+
owner: string | null;
|
|
62
|
+
};
|
|
63
|
+
type LiveConnectHookContext = LiveHookContext & {
|
|
64
|
+
connection: {
|
|
65
|
+
id: string;
|
|
66
|
+
};
|
|
67
|
+
};
|
|
68
|
+
type LiveSubscribeHookContext = LiveHookContext & {
|
|
69
|
+
connection: {
|
|
70
|
+
id: string;
|
|
71
|
+
};
|
|
72
|
+
subscription: {
|
|
73
|
+
id: string;
|
|
74
|
+
};
|
|
75
|
+
topic: string;
|
|
76
|
+
lastEventId?: string;
|
|
77
|
+
};
|
|
78
|
+
type LiveStreamOptions = {
|
|
79
|
+
id: string;
|
|
80
|
+
allowAnonymousControl?: boolean;
|
|
81
|
+
identifyConnection?: (ctx: LiveHookContext) => MaybePromise<string | null | undefined>;
|
|
82
|
+
onConnect?: (ctx: LiveConnectHookContext) => MaybePromise<Response | void>;
|
|
83
|
+
/** Decides who can read each topic. Without it, any connection that passes the owner check can subscribe to any topic. Return a Response to reject. */
|
|
84
|
+
onSubscribe?: (ctx: LiveSubscribeHookContext) => MaybePromise<Response | void>;
|
|
85
|
+
limits?: Partial<LiveLimits>;
|
|
86
|
+
};
|
|
87
|
+
type LiveLimits = {
|
|
88
|
+
maxSubscriptionsPerConnection: number;
|
|
89
|
+
maxSubscriptionsPerTopic: number;
|
|
90
|
+
maxOperationsPerControlRequest: number;
|
|
91
|
+
maxQueuedEventsPerConnection: number;
|
|
92
|
+
maxEncodedEventSize: number;
|
|
93
|
+
deliveryAttemptTimeoutMs: number;
|
|
94
|
+
};
|
|
95
|
+
type LiveStream = {
|
|
96
|
+
connect(ctx: CloudContext, options?: LiveConnectOptions): Promise<Response>;
|
|
97
|
+
control(ctx: CloudContext, options?: LiveControlOptions): Promise<Response>;
|
|
98
|
+
publish(topic: string, data: unknown, options?: LivePublishOptions): Promise<void>;
|
|
99
|
+
withEnv(env: unknown): Pick<LiveStream, "publish">;
|
|
100
|
+
};
|
|
101
|
+
declare function __setLiveBindingName(name: string): void;
|
|
102
|
+
declare function __getLiveBindingName(): string;
|
|
103
|
+
declare function __setLiveDev(dev: boolean): void;
|
|
104
|
+
declare function defineLiveStream(options: LiveStreamOptions): LiveStream;
|
|
105
|
+
export { __getLiveBindingName as _, LiveControlErrorCode as a, defineLiveStream as b, LiveControlOptions as c, LiveHookContext as d, LiveLimits as f, LiveSubscribeHookContext as g, LiveStreamOptions as h, LiveControlError as i, LiveControlRequest as l, LiveStream as m, LiveConnectHookContext as n, LiveControlOperation as o, LivePublishOptions as p, LiveConnectOptions as r, LiveControlOperationResult as s, LiveClientEvent as t, LiveControlResponse as u, __setLiveBindingName as v, __setLiveDev as y };
|