GET
/chatkit/threads/{thread_id}/itemsList ChatKit thread items
Lists the items that belong to a ChatKit thread. Use limit, order, after, and before to control the page size, sort order, and position within the thread's item history. The response includes item data, boundary identifiers, and a flag indicating whether more items are available.
- RetriesRetries up to 2×, 500ms backoff, 30s timeout.
thread_idstringrequired
The identifier of the ChatKit thread whose items you want to list.
limitintegeroptional
The maximum number of thread items to return. Must be between 0 and 100. Defaults to 20 when omitted.
orderstringoptional
The creation-time sort order, either `asc` or `desc`. Defaults to `desc` when omitted.
afterstringoptional
The identifier of the thread item after which to start listing results. Defaults to null for the first page.
beforestringoptional
The identifier of the thread item before which to list results. Defaults to null when retrieving the newest results.
200Returns a paginated list object containing thread items, the first and last item identifiers, and a `has_more` flag indicating whether additional items are available.
objectstringrequired
The type of object returned, must be `list`.
dataarray<TheThreadItem>required
A list of items
first_idstringrequired
The ID of the first item in the list.
last_idstringrequired
The ID of the last item in the list.
has_morebooleanrequired
Whether there are more items available.
Error handling
thread_id must identify the thread whose items you want to list. limit must be between 0 and 100, and order must be asc or desc; limit defaults to 20 and order defaults to desc when omitted.