Databases
List databases
Lists all databases registered for the project.
At a glance
| Item | Value |
|---|---|
| Method | GET |
| Path | /v1/projects/{project_id}/databases |
| Auth | Authorization: Bearer <token-or-api-key> |
Quick request
Use this as a starting point. Replace the placeholder IDs and set PGBEAM_TOKEN if the endpoint requires auth.
curl -X GET \
"$PGBEAM_API_URL/v1/projects/<project_id>/databases" \
-H "Authorization: Bearer $PGBEAM_TOKEN"AuthorizationBearer <token>
JWT issued by Better Auth. Verified via JWKS.
In: header
Path Parameters
project_id*string
Unique project identifier (prefixed, e.g. prj_xxx).
Match
^[a-zA-Z0-9_.-]+$Query Parameters
page_size?integer
Maximum number of items to return (1-100, default 20).
Default
20Range
1 <= value <= 100page_token?string
Opaque token for cursor-based pagination.
Match
^[a-zA-Z0-9_.-]+$Response Body
application/json
application/json
application/json
application/json
application/json
application/json
curl -X GET "https://api.pgbeam.com/v1/projects/string/databases"{
"databases": [
{
"id": "db_01h455vb4pex5vsknk084sn02q",
"project_id": "string",
"connection_string": "postgresql://myuser:YOUR_PASSWORD@myproject.aws.pgbeam.app:5432/mydb",
"host": "db.example.com",
"port": 5432,
"name": "string",
"username": "string",
"ssl_mode": "disable",
"role": "primary",
"pool_region": "us-east-1",
"cache_config": {
"enabled": true,
"ttl_seconds": 60,
"max_entries": 10000,
"swr_seconds": 30
},
"pool_config": {
"pool_size": 10,
"min_pool_size": 1,
"pool_mode": "session",
"max_active": 200
},
"created_at": "2019-08-24T14:15:22Z",
"updated_at": "2019-08-24T14:15:22Z"
}
],
"next_page_token": "string"
}{
"error": {
"code": "string",
"message": "string"
}
}{
"error": {
"code": "string",
"message": "string"
}
}{
"error": {
"code": "string",
"message": "string"
}
}{
"error": {
"code": "string",
"message": "string"
}
}{
"error": {
"code": "string",
"message": "string"
}
}