Documentation
Sign inGet started

List threads

GET
/v1/email/threads
curl -X GET "https://us1.platform.bird.com/v1/email/threads" \
  -H "Authorization: Bearer $TOKEN" \
  --url-query "label=urgent" \
  --url-query "limit=25"
Returns a paginated list of conversations across the workspace's mailboxes, most recently active first. Filter by mailbox, linked contact, label, or last-activity time. before and after filter by time; to page through results pass the response cursors back as starting_after or ending_before.
查询参数
mailbox_id
string
Filter to conversations in a specific mailbox.
contact_id
string
Filter to conversations linked to a specific contact.
label
string
Filter to conversations carrying this label.
unread
boolean
When true, only conversations with unread messages are returned.
after
string
Filter to conversations whose most recent message is at or after this time. This is a time filter, not a cursor.
before
string
Filter to conversations whose most recent message is at or before this time. This is a time filter, not a cursor.
limit
integer
Maximum number of items to return per page.
starting_after
string
Cursor from the next_cursor field of a previous list response. Returns items immediately after the cursor position in the current sort order.
ending_before
string
Cursor from the prev_cursor field of a previous list response. Returns items immediately before the cursor position in the current sort order.
响应载荷
data
array of object
必填
显示子属性
data.id
string
必填
Thread ID.
data.mailbox_id
string
必填
Mailbox this conversation belongs to.
data.channel
string
必填
Channel this conversation lives on. Always email.
data.contact_id
nullable string
必填
Contact linked to this conversation, or null when none is linked.
data.subject
nullable string
必填
Subject of the conversation, taken from its first message. Null when that message had no subject.
data.participants
array of string
必填
Addresses that appear on the retained messages in this conversation, including the mailbox's own address.
data.message_count
integer
必填
Number of retained messages in this conversation, both directions.
data.unread_count
integer
必填
Number of retained received messages in the inbox that are still unread.
data.last_message_at
string
必填
When the most recent retained message in this conversation was received or sent.
data.last_direction
string
必填
Direction of the most recent message — inbound for a received message, outbound for a sent one.
data.labels
array of string
必填
Labels applied to this conversation. A thread carries at most 20 labels.
data.created_at
string
必填
When the thread was created.
data.updated_at
string
必填
When the thread last changed.
next_cursor
nullable string
必填
Cursor for the next page. Pass back as starting_after to advance forward. Null when no next page exists.
prev_cursor
nullable string
必填
Cursor for the previous page. Pass back as ending_before to step backward. Null when no previous page exists.
refresh_cursor
nullable string
必填
Refresh anchor. Pass back as ending_before later to fetch items that have appeared since this response. Non-null whenever data is non-empty; null only on an empty page. Distinct from prev_cursor.