Skip to main content
GET

List messages

Method: GET | Endpoint: /v1/messages Description: List your messages, inbound and outbound, newest first. Use it to catch up after your webhook endpoint was down (see Recover from downtime), or to read a conversation’s history. Authentication: API key in the Authorization header: Authorization: Bearer ib_pk_<64 hex>. Create keys in the dashboard under Settings → API access.

Query parameters

All optional. Filters combine with AND. Any other query parameter, or one given twice, returns 422 validation_error naming it. A misspelt startingAfter is refused instead of quietly returning the first page again. A filter that matches nothing returns an empty page, including a contact_id, conversation_id or chat_guid from another account. Messages stay listed after their contact is deleted or blocked. Rate limit: 120 list requests per 60 seconds per account, across all your API keys and all list endpoints. Over that, you get 429 rate_limited with a Retry-After header; see Rate limits.

Responses

200 OK data holds up to limit messages, newest first: by created_at, then by id for messages recorded in the same microsecond. Each item is exactly what Retrieve a message returns for that message. has_more is true when more messages match; to get them, repeat the request with starting_after set to the id of the last item in data. An empty data comes with has_more: false.
  • direction is inbound or outbound.
  • created_at is when iBubbl recorded the message, in UTC with microseconds. It never changes, which is why the list sorts and filters by it. sent_at is when the message went out or arrived, and can be earlier than created_at for an inbound message.
  • For an inbound message, status is delivered, or read once someone on your account has read it in the dashboard. to is the contact’s number (who sent it), and channel is how it arrived.
401 Unauthorized
Other message values: Authorization Bearer token required, API key required (use Authorization: Bearer ib_pk_…), Invalid API key format, Customer account not found. 403 Forbidden
Your iBubbl account is suspended or cancelled (message is then Account is cancelled). Every API-key endpoint returns this. 422 Unprocessable Entity
validation_error: a query parameter is unknown, repeated or invalid (limit outside 1–100, an ID that isn’t a UUID, a time without a time zone, an unknown direction or status). invalid_cursor: starting_after is a UUID but not the ID of one of your messages. 429 Too Many Requests
Your account made more than 120 list requests in the last 60 seconds. Retry-After is the number of whole seconds until the oldest of them stops counting. Wait that long, then send the same request again; the refused request didn’t count. The limit is checked after the API key, so a bad key is still 401.

Authorizations

Authorization
string
header
required

Bearer API key. Format: Authorization: Bearer ib_pk_<64 hex> (70 characters). Generate keys from Dashboard → Settings → API Access.

Query Parameters

limit
integer
default:50

How many items to return, 1 to 100. Defaults to 50.

Required range: 1 <= x <= 100
starting_after
string<uuid> | null

The id of the last item on the page you already have. Returns the items that come after it, in the same order. Leave it out for the first page. An id that isn't one of yours returns 422 invalid_cursor.

contact_id
string<uuid> | null

Only messages with this contact: the 1:1 conversation, plus group messages they sent or that were addressed to them as the group's primary contact. For one whole conversation, use conversation_id.

conversation_id
string<uuid> | null

Only messages in this conversation (1:1 or group).

chat_guid
string | null

Only messages in the iMessage group with this chat_guid. It changes when a participant is added; the group's conversation_id doesn't.

Minimum string length: 1
direction
enum<string> | null

Only inbound or only outbound messages.

Available options:
inbound,
outbound
status
enum<string> | null

Only messages with this status.

Available options:
queued,
pending,
sent,
delivered,
read,
failed,
expired,
cancelled
created_after
string<date-time> | null

Only messages with created_at strictly after this time. ISO 8601 with a time zone, e.g. 2026-11-10T09:30:00Z; in a query string, write Z or encode + as %2B.

created_before
string<date-time> | null

Only messages with created_at strictly before this time. Same format as created_after.

Response

A page of messages.

data
Message · object[]
required

Up to limit messages, newest first: by created_at, then by id for messages recorded in the same microsecond.

has_more
boolean
required

Whether more messages match after the last one in data. To get them, repeat the request with starting_after set to that message's id.