> For an agent: the map of this documentation is at https://escouade.io/en/mail/docs/llms.txt; every page exists in Markdown, at the same address with `.md` appended.

# `update_draft`

Correct a draft.

Changes a draft's subject, text or HTML as long as it is not approved. The recipient and the inbox do not change (for that: cancel_message, then a new send). Every correction is noted in the log with its author.

## Access

- **Key**: an Escouade Mail key with `send` or `approve`.
- **Space**: any space, verified or not.
- **Changes nothing**: no, it acts.
- **Safe to replay**: yes.

## Parameters

| Parameter | Type | Required | Description |
|---|---|---|---|
| `message_id` | string | yes | The draft (msg_…, see list_drafts). |
| `subject` | string | no | New subject. |
| `text` | string | no | New text. |
| `html` | string | no | New HTML (empty text: removes the HTML version). |

## Call it

```sh
curl -s https://api.subagent.fr/v1/update_draft \
  -H 'Content-Type: application/json' \
  -H 'Authorization: Bearer sak_…' \
  -d '{"message_id": "…"}'
```

The full page in French, with the response fields and every refusal the tool can return: [/mail/docs/reference/update_draft](https://escouade.io/mail/docs/reference/update_draft).
