Message Operations
resource: message — Messenger replies and conversation lists for the Page
send
Sends a Messenger text message via Graph API POST /me/messages.
| Field | Type | Required | Description |
|---|---|---|---|
recipientId | text | ✓ Yes | Page-scoped user ID (PSID) of the recipient. |
messageText | text | ✓ Yes | Message body text (max 4,000 chars). |
Example response:
{
"messageId": "m_AbCdEf...",
"recipientId": "1234567890"
}
24-hour messaging window: Facebook's Messenger Platform only allows a Page to
message a user outside an approved message tag within 24 hours of that user's last message to the
Page. Calling
send outside that window (and without a qualifying tag) returns a Graph API
permission error, not a node-level bug.
PSID, not a Facebook user ID:
recipientId must be the page-scoped ID
Facebook returns for that user in the context of your Page (e.g. from a webhook's sender.id
field) — a generic Facebook profile ID will not work here.
getConversations
Lists Messenger conversations for the Page with cursor pagination.
| Field | Type | Required | Description |
|---|---|---|---|
pageId | text | ✓ Yes | Target Facebook Page ID. |
limit | int | No | Page size. Default 25. |
after | text | No | Cursor from a previous call's nextCursor. |
Example response:
{
"conversations": "{ \"data\": [ { \"id\": \"...\", \"subject\": \"\", \"formatted_message_count\": 3, \"updated_time\": \"...\" } ] }",
"nextCursor": "QVFI...",
"count": 8
}
Fields requested:
id,subject,wallpaper,formatted_message_count,updated_time
— conversations is the raw Graph JSON, following the same pattern as
page.getFeed/post.getComments.