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

# Messenger API

> Send Facebook Messenger messages, read conversations and receive events through the FlowIQ API.

Messenger uses the same organization API key and webhook registration endpoints as WhatsApp. Use the FlowIQ API for all Messenger messages and events, whichever way your Facebook Page is connected to FlowIQ.

## Authentication and recipients

Send `Authorization: Bearer fiq_YOUR_API_KEY` to `https://api.flowiq.live`. The key identifies your organization; no organization ID is needed.

Messages go to an existing Messenger contact: someone who has messaged your Facebook Page. Use either `contact_id` (the FlowIQ contact UUID) or `messenger_id` (the Page-scoped ID, as a string). A name, email address or phone number is not a Messenger recipient ID. Use [Messenger Conversations](https://docs.flowapt.com/flowiq-api-reference/endpoint/messenger-conversations.md) to list contacts and obtain their IDs.

## Messages and history

| Endpoint | Purpose |
| - | - |
| `POST /send-messenger` | Send [text](https://docs.flowapt.com/flowiq-api-reference/endpoint/send-messenger-text.md), [images](https://docs.flowapt.com/flowiq-api-reference/endpoint/send-messenger-image.md), [video](https://docs.flowapt.com/flowiq-api-reference/endpoint/send-messenger-video.md), [audio](https://docs.flowapt.com/flowiq-api-reference/endpoint/send-messenger-audio.md) or [files](https://docs.flowapt.com/flowiq-api-reference/endpoint/send-messenger-file.md) |
| `GET /messenger-conversations` | Read Messenger messages, list contacts or find a contact |
| `GET /conversations?platform=messenger` | Alias for the Messenger conversations endpoint |

Text supports 1–2000 characters. Media requires a public HTTPS URL; send captions as separate text messages. Messenger permissions and the 24-hour messaging window still apply. WhatsApp templates, calls and broadcasts are not supported by these Messenger endpoints.

History comes from messages already stored in the FlowIQ inbox. Reading it does not mark messages as read or import earlier Messenger history. Only Messenger messages are returned, including when a contact also has a WhatsApp or Instagram conversation.

## Webhooks

Use the existing webhook API with `platform: "messenger"`:

```bash theme={null}
curl -X POST "https://api.flowiq.live/set-webhooks" \
  -H "Authorization: Bearer fiq_YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "url": "https://your-server.com/webhooks/messenger",
    "platform": "messenger",
    "type": "all",
    "secret": "a-long-random-signing-secret"
  }'
```

Receive incoming messages, outgoing content, send confirmations and recorded receipt changes. [Messenger Events](https://docs.flowapt.com/flowiq-api-reference/webhooks.md#messenger-events) documents each event and its identifiers. Delivery uses the same authentication options, static headers, HMAC signature verification, delivery log and retries as WhatsApp.

List registrations using `GET /get-webhooks?platform=messenger`, and remove one using `DELETE /set-webhooks` with its `id`. See [Create Webhook](https://docs.flowapt.com/flowiq-api-reference/endpoint/create-webhook.md), [List Webhooks](https://docs.flowapt.com/flowiq-api-reference/endpoint/get-webhooks.md) and [Delete Webhook](https://docs.flowapt.com/flowiq-api-reference/endpoint/delete-webhook.md).


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