Wrangler Hyperdrive PlanetScale signature provisions billed databases
Introduced 2026-08-25 · score 0.96
HOW TO USE IT
When creating a PlanetScale Postgres database billed to Cloudflare, pipe Wrangler’s experimental signed authorization into `pscale database create` with the documented flags. Use `pscale` v0.313.0 or newer, as stated in the release note.
npx wrangler hyperdrive planetscale signature | \
pscale database create <name> \
--org <org> \
--engine postgresql \
--cloudflare-billing @- \
--format jsonWHY THIS HELPS
Create a PlanetScale Postgres database billed to a Cloudflare account from a coding workflow.
REQUIREMENTS AND LIMITATIONS
- Version: 4.126.0
- Availability: Experimental; interface may change.
- <name> (required): Name of the database to create.
- --org <org> (required): Organization for the database. The PlanetScale database docs say create requires `--org` or `PLANETSCALE_ORG`.
- --engine postgresql (required): Selects Postgres; the CLI defaults to `mysql` (Vitess).
- --cloudflare-billing @- (required): Passes Cloudflare billing proof to `database create`; `@-` reads it from stdin.
- --format json: Formats CLI output as JSON; the release note recommends it when output is consumed by an agent.
- Prerequisite: Use `pscale` v0.313.0 or newer.
- Prerequisite: Wrangler’s signature command is experimental.
- Requires `pscale` v0.313.0 or newer.
- `pscale database create` defaults to Vitess; pass `--engine postgresql` for a Postgres database.
- Wrangler authorizes the Cloudflare billing side only; PlanetScale credentials stay between the user and `pscale`.
- The signed token authorizes creating a database billed to the Cloudflare account; treat it as a credential and do not share it.
- Piping the token is recommended over passing it as a command line argument.
FIRST-PARTY EVIDENCE
- https://github.com/cloudflare/workers-sdk/releases/tag/wrangler%404.126.0
- https://planetscale.com/docs/cli/database
- https://github.com/planetscale/cli/blob/main/AGENTS.md
- https://developers.cloudflare.com/workers/wrangler/commands/hyperdrive/
Check the installed version and the source before using it. Entry JSON