# Give the conversation back to the AI agent

`POST https://app.whatsetter.com/api/v1/leads/{id}/resume`

The mirror of `/handoff`: the AI agent takes the conversation back and
resumes replying to this lead. Equivalent to "réactiver l'IA" in the
dashboard.

Like `/handoff`, the business status is preserved and the call is
idempotent. On an Instagram or Messenger lead it also ends the pause a
person's reply opened (`agent_paused_until` on `GET /conversations`).
Requires scope `leads:write`.

## Parameters

| Name | In | Type | Required | Description |
|---|---|---|---|---|
| `id` | path | string | yes | The WhatSetter lead id (same as `contact.id` on webhooks). |

## Example request

```bash
curl --request POST \
  --url 'https://app.whatsetter.com/api/v1/leads/{id}/resume' \
  --header 'Authorization: Bearer ws_live_…'
```

## Responses

### 200: The agent is active again on this conversation

```json
{
  "data": {
    "id": "",
    "external_reference": "",
    "agent_active": false,
    "manual_override": false,
    "status": "",
    "dashboard_synced": false,
    "updated_at": ""
  }
}
```

### 401: Missing, unknown or revoked API key

```json
{
  "error": {
    "code": "",
    "message": ""
  }
}
```

### 404: Resource not found in this workspace

```json
{
  "error": {
    "code": "",
    "message": ""
  }
}
```

### 409: `invalid_state`: the lead has no conversation yet (not contacted).

```json
{
  "error": {
    "code": "",
    "message": ""
  }
}
```

### 500: Agent control is not configured on this deployment (`internal_error`)

```json
{
  "error": {
    "code": "",
    "message": ""
  }
}
```

### 502: `upstream_error`: the agent-control workflow was unreachable or refused the change. Safe to retry.

```json
{
  "error": {
    "code": "",
    "message": ""
  }
}
```


Source: https://docs.whatsetter.com/api-reference/operations/resumelead/
