Usage
Control-plane API for projects, databases, analytics, onboarding, and platform state.
The PgBeam API is the control plane behind the dashboard and CLI. Use it when you want to automate project creation, database setup, usage reporting, cache configuration, or onboarding from your own tooling.
Base URL: https://api.pgbeam.com
Prefer the CLI?
The PgBeam CLI wraps the same API and is usually the fastest way to explore the platform from a terminal. Reach for the raw API when you need custom automation, CI integration, or your own internal tooling.
What this API is good at
| Area | Use it for |
|---|---|
| Projects | Create, inspect, update, and delete PgBeam projects |
| Databases | Register origin databases, test connectivity, and adjust pool or cache settings |
| Analytics | Read usage, activity, metrics, and query insights |
| Platform | Discover regions, plans, and health |
| Account | Export account data and track onboarding progress |
Authentication
Most endpoints require Authorization: Bearer .... The credential can be
either:
| Credential | How to get it | Header |
|---|---|---|
| Dashboard token | Sign in to the dashboard and reuse the session token in trusted tooling | Authorization: Bearer <token> |
| API key | Create one from the dashboard for scripts, CI, and long-lived automation | Authorization: Bearer <api-key> |
curl -H "Authorization: Bearer <token>" \
https://api.pgbeam.com/v1/projectscurl -H "Authorization: Bearer <api-key>" \
https://api.pgbeam.com/v1/projects/v1/health is public. Everything else in the public API expects auth.
See API Keys for key creation and rotation.
OpenAPI & Codegen
The public spec is available at api.pgbeam.com/openapi.json. It is the source for our SDK and the generated endpoint pages in this section.
Download the spec
curl -o openapi.json https://api.pgbeam.com/openapi.jsonGenerate a client
Feed the spec to your OpenAPI tooling of choice. For example, with openapi-generator:
openapi-generator generate \
-i openapi.json \
-g typescript-fetch \
-o ./generated-clientOfficial TypeScript SDK
If you are working in TypeScript, use the official PgBeam SDK instead of generating a client. It is maintained alongside the API and provides tag-based access, error handling, and full type safety out of the box.
Next steps
- Response Conventions — status codes, pagination, and error envelopes