v1

latestOpenAPI 3.0.22026-08-045831103.6 KB
Chats

List chats by channel account

Retrieve a paginated list of chats for a specific channel account. Results are sorted by last_message_at descending.

get/v2/chats/channel-account/{channelAccountId}

Path parameters

channelAccountIdstring uuid required
Example:550e8400-e29b-41d4-a716-446655440000

UUID of the channel account

Query parameters

limitinteger

Max number of rows returned

offsetinteger

Number of rows skipped of the result

pageinteger

Select the page of the result

last_message_at_startstring date-time
Example:2020-01-01T14:15:00.000000+00:00

Filter chats whose last_message_at is greater than or equal to this date (ISO-8601; a bare YYYY-MM-DD is treated as the start of the day)

last_message_at_endstring date-time
Example:2020-01-01T14:15:00.000000+00:00

Filter chats whose last_message_at is less than or equal to this date (ISO-8601). A bare YYYY-MM-DD normalizes to start-of-day, so it excludes that calendar day — pass a full timestamp (e.g. ...T23:59:59Z) to include it.

last_response_at_startstring date-time
Example:2020-01-01T14:15:00.000000+00:00

Filter chats whose last_response_at is greater than or equal to this date (ISO-8601; a bare YYYY-MM-DD is treated as the start of the day)

last_response_at_endstring date-time
Example:2020-01-01T14:15:00.000000+00:00

Filter chats whose last_response_at is less than or equal to this date (ISO-8601). A bare YYYY-MM-DD normalizes to start-of-day, so it excludes that calendar day — pass a full timestamp (e.g. ...T23:59:59Z) to include it.

Headers

api-tokenstring required

API Token

Response

A paginated list of chats

statusinteger

Response status

total_countinteger

Total items based on current filters

pageinteger

Current page

total_pagesinteger

Total pages based on current filters

has_nextboolean

Indicates that has next page

has_previousboolean

Indicates that has previous page

Example response

{
  "status": 200,
  "total_count": 50,
  "page": 1,
  "total_pages": 10,
  "has_next": true,
  "data": [
    {
      "id": "8feade82-d77b-4e8b-9d35-fd43e972b5c8",
      "created_at": "2020-01-01T14:15:00.000000+00:00",
      "contact_id": "8feade82-d77b-4e8b-9d35-fd43e972b5c8",
      "user_id": "8feade82-d77b-4e8b-9d35-fd43e972b5c8",
      "status": "OPEN",
      "unread": true,
      "unseen_count": 3,
      "last_message_at": "2020-01-01T14:15:00.000000+00:00",
      "last_response_at": "2024-01-15T09:00:00.000Z",
      "last_status_at": "2024-01-15T10:30:00.000Z",
      "first_response_at": "2024-01-14T08:00:00.000Z",
      "channel_account_id": "8feade82-d77b-4e8b-9d35-fd43e972b5c8",
      "team_id": "8feade82-d77b-4e8b-9d35-fd43e972b5c8",
      "close_window_at": "2024-01-16T10:30:00.000Z"
    }
  ]
}