Consultar contadores de chats
GET /chat/totalcount
Retorna contadores totais e não lidos por estado, etiqueta e atendente. Os arrays são retornados vazios quando ainda não há etiquetas ou atendentes.
Autenticação
[
{
"token": []
}
]
{
"token": {
"name": "token",
"type": "apiKey",
"in": "header"
}
}
Respostas
{
"200": {
"description": "Contadores atuais dos chats",
"content": {
"application/json": {
"schema": {
"type": "object",
"required": [
"total_chats",
"open_chats",
"archived_chats",
"group_chats",
"blocked_chats",
"label_counts",
"attendant_counts"
],
"properties": {
"total_chats": {
"type": "object",
"required": [
"total",
"unread"
],
"properties": {
"total": {
"type": "integer",
"format": "int64"
},
"unread": {
"type": "integer",
"format": "int64"
}
}
},
"open_chats": {
"type": "object",
"required": [
"total",
"unread"
],
"properties": {
"total": {
"type": "integer",
"format": "int64"
},
"unread": {
"type": "integer",
"format": "int64"
}
}
},
"archived_chats": {
"type": "object",
"required": [
"total",
"unread"
],
"properties": {
"total": {
"type": "integer",
"format": "int64"
},
"unread": {
"type": "integer",
"format": "int64"
}
}
},
"group_chats": {
"type": "object",
"required": [
"total",
"unread"
],
"properties": {
"total": {
"type": "integer",
"format": "int64"
},
"unread": {
"type": "integer",
"format": "int64"
}
}
},
"blocked_chats": {
"type": "object",
"required": [
"total",
"unread"
],
"properties": {
"total": {
"type": "integer",
"format": "int64"
},
"unread": {
"type": "integer",
"format": "int64"
}
}
},
"label_counts": {
"type": "array",
"items": {
"type": "object",
"required": [
"id",
"labelid",
"name",
"total",
"unread"
],
"properties": {
"id": {
"type": "string"
},
"labelid": {
"type": "string"
},
"name": {
"type": "string"
},
"total": {
"type": "integer",
"format": "int64"
},
"unread": {
"type": "integer",
"format": "int64"
}
}
}
},
"attendant_counts": {
"type": "array",
"items": {
"type": "object",
"required": [
"id",
"name",
"total",
"unread"
],
"properties": {
"id": {
"type": "string"
},
"name": {
"type": "string"
},
"total": {
"type": "integer",
"format": "int64"
},
"unread": {
"type": "integer",
"format": "int64"
}
}
}
}
}
}
}
}
},
"401": {
"description": "Token inválido ou ausente"
},
"500": {
"description": "Sessão indisponível"
}
}