Projects
Delete a replica
Removes a read replica from a database.
At a glance
| Item | Value |
|---|---|
| Method | DELETE |
| Path | /v1/databases/{database_id}/replicas/{replica_id} |
| 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 DELETE \
"$PGBEAM_API_URL/v1/databases/<database_id>/replicas/<replica_id>" \
-H "Authorization: Bearer $PGBEAM_TOKEN"AuthorizationBearer <token>
JWT issued by Better Auth. Verified via JWKS.
In: header
Path Parameters
database_id*string
Unique database identifier (prefixed, e.g. db_xxx).
Match
^[a-zA-Z0-9_.-]+$replica_id*string
Unique replica identifier (prefixed, e.g. rep_xxx).
Match
^[a-zA-Z0-9_.-]+$Response Body
application/json
application/json
application/json
application/json
application/json
curl -X DELETE "https://api.pgbeam.com/v1/databases/string/replicas/string"Empty
{
"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"
}
}