Skip to main content

Retrieve messages for a contact (deprecated — use GET /messages)

GET 

/contacts/messages

deprecated

This endpoint has been deprecated and may be replaced or removed in future versions of the API.

> Deprecated. This endpoint will be removed at the end of 2026. > Use GET /messages instead — it is a > superset of this endpoint (same messageIds and contact-history modes) > and additionally supports filtering by campaignId.


This endpoint supports two modes of operation:


Mode 1 — Fetch specific messages by ID (messageIds provided)

Provide a comma-separated list of up to 20 message IDs to retrieve those exact messages. The response contains only the matched messages ordered oldest-first. No pagination metadata (nextCursor, hasMore) is returned. The channel, channelUserId, contactId, size, and cursor parameters are all ignored when messageIds is present.

Messages that do not exist or belong to a different account are silently excluded. An empty result is a valid HTTP 200 response — it is not an error.

GET /api/v1/contacts/messages?messageIds=msg-uuid-001,msg-uuid-002


Mode 2 — Paginated contact history (messageIds absent)

Retrieve the full message history for a contact using identifiers you already hold — either a channel user ID (e.g. a WhatsApp phone number or Apple Messages opaque ID) or a contact UUID — together with a channel name. The conversation UUID is resolved internally; you never need to know it.

Messages are returned oldest-first per page. Use nextCursor and hasMore in the response envelope to paginate backwards through history.

Exactly one of channelUserId or contactId must be provided — they are mutually exclusive.

Supported channel slugs: WHATSAPP, APPLEMB, VIBER, SMS, TELEGRAM, RBM

GET /api/v1/contacts/messages?channel=WHATSAPP&channelUserId=85291234567&size=20

Request

Responses

Messages retrieved successfully