> ## Documentation Index
> Fetch the complete documentation index at: https://docs.getnexor.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Update Agent

<span class="badge--patch">PATCH</span> <code class="endpoint-url">/workflows/:id</code>

Rename an agent, edit its description, or **activate/pause** it. Agents are born paused when [created](/docs/en/api/workflows/create-workflow) via the API — this is the only way to turn one on programmatically.

## Path Parameters

| Parameter | Type          | Required | Description |
| --------- | ------------- | -------- | ----------- |
| `id`      | string (uuid) | **Yes**  | Agent ID    |

## Request Body

Provide at least one of the following.

| Field         | Type    | Required | Description                                   |
| ------------- | ------- | -------- | --------------------------------------------- |
| `is_paused`   | boolean | No       | `false` activates the agent, `true` pauses it |
| `name`        | string  | No       | New agent name                                |
| `description` | string  | No       | New agent description                         |

## Responses

### `200` — Updated

```json theme={null}
{
  "success": true,
  "workflow_id": "123e4567-e89b-12d3-a456-426614174000",
  "is_paused": false,
  "pending_runs": 3
}
```

`pending_runs` is only present when activating, and reflects leads whose cadence resumes immediately.

### `400` — Validation error

```json theme={null}
{
  "error": "Invalid input",
  "message": "Provide is_paused, name or description"
}
```

### `400` — Activation blocked

Appointment-goal agents need at least one active meeting type before they can be activated:

```json theme={null}
{
  "error": "Activation blocked",
  "message": "Configure at least one active meeting type before activating this workflow."
}
```

### `401` — Authentication error

See [Authentication](/docs/en/api/authentication).

### `404` — Not found

```json theme={null}
{
  "error": "Not found",
  "message": "Workflow not found"
}
```

### `500` — Internal server error
