List messages
GET /v1/messages
Returns a page of your workspace’s messages, incoming and outgoing, newest first. Use it to catch up after your webhook endpoint was down.
Needs messages:read.
Query parameters
Section titled “Query parameters”limit integer
How many items to return.
From 1 to 100. Default 25.
cursor string
The next_cursor of the previous page, unchanged. A cursor that was changed, or made for a different sort, is 400 invalid_request.
sort string
created_at lists newest first. updated_at lists oldest change first.
Default created_at.
contact_id string · uuid
Only messages with this contact. A contact of another workspace is 422 invalid_field.
number_id string · uuid
Only messages sent from or to this number. A number of another workspace is 422 invalid_field.
direction string
Only incoming or only outgoing messages.
One of incoming outgoing.
updated_after string · date-time
Only messages changed after this time (RFC 3339). A change shows up about 30 seconds after it’s saved. The list runs oldest change first, so leave sort out or set it to updated_at.
Syncing changes
Section titled “Syncing changes”With sort=updated_at, a message moves to the end of the list each time its status changes. Resume a minute early and skip messages you already have. See Pagination.
Listing doesn't mark messages as read
Section titled “Listing doesn't mark messages as read”The contact gets no read receipt when you list or fetch a message.
Returns
Section titled “Returns”200 A page of message objects. A page of messages.
Errors
Section titled “Errors”Besides the ones every request can get: