P
PlanetScale API
Details
- URL
-
https://api.planetscale.com/v1 - Spec
- https://planetscale.com/docs/openapi.yaml
- Docs
- https://planetscale.com/docs/api/reference/getting-started-with-planetscale-api
Authentication
PlanetScale service token pair (service token ID + service token secret) compound discovered Get key ↗
Authorization: <credential> In the PlanetScale dashboard, open Settings → Service tokens, click New service token, create the token, and copy both values shown: the SERVICE_TOKEN_ID and the SERVICE_TOKEN. Then assign the organization/database permissions the token needs. The token secret is only shown once, so save it securely.
Authorization: Bearer <credential> Create an OAuth app in your PlanetScale organization under Settings → OAuth applications as described in OAuth. Fill in the app name, domain, redirect URI, and optional avatar, then save the app and copy its client_id and client_secret (shown once). Configure the scopes your application needs, then run the standard PlanetScale OAuth authorization-code flow to obtain user access tokens.