API referenceInbox
JavaScript SDK: swarmhit.inbox.chats.messages.list(chatId, params?)
Authorization
bearerAuth AuthorizationBearer <token>
An API key created on the Access tokens page.
In: header
Path Parameters
id*string
Query Parameters
limit?integer
Page size, 1–100.
Range
1 <= value <= 100Default
50offset?integer
Number of records to skip.
Range
0 <= valueDefault
0Response Body
application/json
application/json
application/json
curl -X GET "https://example.com/inbox/chats/string/messages"{ "data": [ { "id": "string", "chatId": "string", "channel": "linkedin", "subject": "string", "deliveredAt": "2019-08-24T14:15:22Z", "readAt": "2019-08-24T14:15:22Z", "messageId": "string", "html": "string", "openedAt": "2019-08-24T14:15:22Z", "clickedAt": "2019-08-24T14:15:22Z", "text": "string", "isFromMe": true, "isEvent": true, "attachments": [ { "type": "image", "url": "string", "name": "string", "mimeType": "string", "size": 0, "voiceNote": true, "durationMs": 0 } ], "at": "2019-08-24T14:15:22Z" } ], "paging": { "limit": 0, "offset": 0 }}Unread messages, replies, favourites and labels GET
**JavaScript SDK:** [`swarmhit.inbox.getCounts(params?)`](/smart-api/sdk/methods#inbox) The Unibox badges, workspace-wide or for one sender (`accountId`) or one channel (`channel`).
List inbox chats GET
**JavaScript SDK:** [`swarmhit.inbox.chats.list(params?)`](/smart-api/sdk/methods#inbox.chats) Ordered by most recent activity. With `replied=true`, ordered by the lead's most recent reply instead. Each thread carries its lead's `label` in the campaign.