Skip to main content
Get Unread Count
Returns two aggregate counts across all of the current user’s active conversations: the total number of unread messages and the number of conversations that have at least one unread message. Thread replies are excluded from unread counts. Only main-stream messages are counted.

Query Parameters

string
Service key only, and required with one: the user this request acts as. Their unread counts are returned. A user token always acts as its own user and must not send it (400 chat/acting-user-not-allowed).

Response

number
Total number of unread messages across all conversations.
number
Number of conversations with at least one unread message.

Error Responses

A user token sent actingUserId, even naming its own user. Only a service key names the user it acts as; a user token always acts as its own user.
Returned when a service key names an actingUserId that isn’t a user in this project.
The request sent userId. On this route the user a service key acts as is actingUserId.With a service key:
With a user token, or with no credentials:
A service key sent no actingUserId.