Channel Developers

List of UserChats

List of UserChats in managed state.

Accessible via URL https://api.channel.io/open/v5/user-chats and HTTP GET

Present parameters in query string

Parameter

Example

Required

Description

Parameter type

state

opened

Required

User chat state filter.Available valuesclosed,opened,snoozed(default value:opened).

Query

sortOrder

desc

Required

Sorting order.Available values areasc,desc,both(default value:desc).

Query

since

eyJjaGF0S2V5IjoiZ3Jvn0=

Optional

Encoded key of the first user chat to be retrieved

Query

limit

40

Optional

Restrict the maximum number of user chats to be retrieved.It should be between 1 to 500.Default value is 25.

Query

GET http://api.channel.io/open/v5/user-chats?state=opened&sortOrder=desc&since=eyJjaGF0S2V5IjoiZ3Jvn0=&limit=40

Return a set of UserChat objects.

JSON

The number of user chats retrieved in this endpoint is restricted by the limit query parameter, and is capped to values in the closed interval [1, 500].

Retrieved user chats can be filtered by opened, snoozed, and closed through the state query parameter.

Pagination is supported through the since query parameter along with the next value contained in the root object of the JSON response. Successive queries to this endpoint using the previous next value as the since parameter will ultimately retrieve all user chats.

The since parameter can be left empty to start the list.