---
search:
  tags:
    - database-services
    - POST
seo:
  description: >-
    Fail the Patroni leader over to a node. Reference for the POST
    /api/v1/database-services/{id}/patroni/failover endpoint in the TimescaleDB
    Enterprise API.
sidebar:
  label: Fail over to a node
  badge: POST
title: Fail over to a node
type: openapi-operation
---
Fail the Patroni leader over to a node.

`POST /api/v1/database-services/{id}/patroni/failover`

**Request body** (`application/json`, required)

- `server_id` (string)

Request body example:

```json
{
  "server_id": "string"
}
```

**Responses**

- `200` — OK
- `default` — Error

Response example, 200:

```json
{
  "error": "string",
  "extensions_error": "string",
  "extensions_workflow_id": "string",
  "message": "string",
  "status": "ok"
}
```
