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

# Reply to a thread

> Answer a contact by WhatsApp or email from the API or your AI agent: WhatsApp's 24-hour window, email threading, preview before sending.

A reply goes to the contact of the thread, as a member of your team (the user of the API key or of the agent's
connection). It is the same send as typing in the inbox.

## Choose the channel

Pass `channel: "whatsapp"` or `"email"`. Without it, Minimo answers on the channel of the contact's **last WhatsApp
or email message**.

> [tab] WhatsApp
>
> WhatsApp allows **free text only within 24 hours** of the contact's last WhatsApp message. The reply is checked
> before sending: outside the window you get `WHATSAPP_WINDOW_CLOSED` with the moment the window closed, and nothing
> is sent. To write to that contact, send an approved [WhatsApp template](https://docs.minimo.it/api-reference/messaging-channels/whatsapp/send-template.md)
> (your agent uses `minimo_whatsapp_campaign_send-from-template`).
>
> The reply goes out from the number the conversation is on.

> [tab] Email
>
> The reply goes to the address of the contact's last email (or the contact's email), **in the same email thread**,
> from your workspace's sender. The subject defaults to `Re: <subject of their last email>`; pass `subject` to change it.
> If the contact never emailed in this thread, `subject` is required.

## Preview first

Every reply can be checked before it goes out:

* **AI agent:** `minimo_inbox_reply` without `confirm` returns the preview (recipient, channel, subject, WhatsApp window,
  effects) and sends nothing. The agent shows it to you and calls again with `confirm: true` only after your OK.
* **API:** `POST /reply` with `"dryRun": true` returns the same preview. Without `dryRun` the reply is sent.

## What happens when you reply

* **The AI pauses on that conversation.** A WhatsApp reply from a person hands the conversation over: the AI stops
  answering this contact (it comes back after the assistant's pause time, or when you [turn it back on](https://docs.minimo.it/product/inbox/ai-handover.md)).

* **The thread is assigned to you** if nobody had it.

* **No double sends.** The same text sent in the same thread in the last 10 minutes is not sent again: the answer is
  `sent: false` with `duplicateOf`, the id of the message already sent. Two calls at the same moment cannot both send
  (the second gets `REPLY_IN_PROGRESS`). A send that failed can be retried.

* MCP: `minimo_inbox_reply`

* API: [`POST /public/v1/inbox/threads/{threadId}/reply`](https://docs.minimo.it/api-reference/inbox/reply)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.