Returns a flat array across the profile's Instagram, Facebook, and WhatsApp
conversations, oldest first by occurredAt. Uses the
aggregate response contract.
Before answering, Adeli refreshes each Instagram and Facebook account from Meta at most once a minute. A read inside that minute returns the history Adeli has stored, which incoming messages keep current as they arrive, so polling more often does not reach Meta more often.
Pass accountId and a conversationKey to read one conversation instead, a
page at a time. Each page holds the conversation's newest limit messages
before cursor, oldest first within the page, and nextCursor points at the
next, older page — null once you reach the start of the conversation.
Conversation pages are read from the history Adeli has stored, which Meta's
webhooks keep current, so they do not wait on a provider refresh.
Pass a storyId to get every reply to one of the account's Instagram
stories. A reply carries that id in story.id. Each reply's sender is the
person to message back with Send an Instagram message.
Their reply opens Instagram's 24-hour messaging window, so follow up within a
day.
Query parameters
platform"instagram" | "facebook" | "whatsapp"- Return one provider's messages only.
facebookcovers every connected Facebook Page's Messenger conversations. Anything else, includingtiktokandyoutube, returns422 unsupported_platform. accountIduuid- Narrow to one connected account.
profileIduuid- Required unless you pass accountId, which names its profile. If you pass both, they must agree.
conversationKeystring- One conversation: a message's
conversationKey. RequiresaccountId; without it the response is400 invalid_request. cursorstring- The previous page's
nextCursor, to read older messages. RequiresconversationKey. limitinteger- Messages per conversation page, 1–100. Defaults to 50. Requires
conversationKey. storyIdstring- Only the inbound messages that replied to this Instagram story: a message's
story.id. Instagram only, so it can't be combined with anotherplatformor withconversationKey(400 invalid_request). Never served from the cache below.
Message fields
idstring- Adeli's identifier for this message.
providerIdstring | null- The provider's message id.
direction"inbound" | "outbound"- Relative to the connected account.
type"text" | "template" | "unsupported"unsupportedcovers media and other payloads Adeli does not normalize.senderstring | null- Set on inbound messages — the provider-scoped participant id (an IGSID on Instagram, a PSID on Facebook).
recipientstring | null- Set on outbound messages.
statusstring- Provider delivery state, such as
receivedorsent. occurredAtISO 8601- When the provider recorded the message. Sort on this.
conversationKeystring | null- The platform, a colon, and the counterparty's id — the IGSID, PSID, or WhatsApp number as digits without
+— such asinstagram:17841400000000001. WithaccountIdit names the conversation, on inbound and outbound messages alike. storyobject | null- Set when an Instagram message replies to one of the account's stories (
type: "reply") or mentions the account in someone else's story (type: "mention"), with the story'sidandurl. Theurlstops working when the story expires.nullon every other message. A story is recorded for replies Adeli stores from the time it started keeping them, and for the most recent messages of each conversation when it refreshes.
Response fields with conversationKey
nextCursorstring | null- Pass as
cursorfor the next, older page.nullwhen there are no older messages. Absent withoutconversationKey.
If a provider sync fails, Adeli still returns the messages it has already
persisted and reports the failure in errors, which makes the response 207.
Complete responses may be 15 seconds old
After authenticating and authorizing the requested profile or account, Adeli
may replay a complete 200 response from its internal cache for 15
seconds. Accepted sends and verified incoming message, status, and delete
changes normally invalidate affected entries sooner, but cache failures leave
the 15-second TTL as the fallback freshness bound. Partial and error responses
are never cached. Public responses remain Cache-Control: private, no-store,
so browsers and CDNs do not store message data. Polling more frequently is not
a force-refresh mechanism.
Errors — 401 unauthorized, 400 invalid_request,
422 unsupported_platform, 404 profile_not_found, 404 account_not_found,
502 provider_error.