ReferenceInbox API
Listar conversas
GET
As conversas com lastMessageAt mais recente vêm primeiro. Para a próxima página, envie pagination.nextCursor como cursor.
bearerheader
AuthorizationBearer <token>Chave gerada em Settings → Developer → API key. Os métodos do Inbox precisam do escopo Inbox. Os métodos de Campaigns precisam do escopo Campaigns.
limit?numberTamanho da página. Padrão 50.
cursor?stringpagination.nextCursor da página anterior (lastMessageAt em ISO).
channelId?stringSó um canal.
status?stringStatus da conversa.
Value in
"OPEN""CLOSED"unread?booleantrue mantém só as conversas com mensagens não lidas.
tab?stringmine_open: abertas e atribuídas a esta chave. unassigned: abertas e sem responsável. all: sem filtro extra de aba.
Value in
"mine_open""unassigned""all"assigneeId?stringSó conversas atribuídas a este usuário.
application/json- response
data*array<>pagination*curl -X GET 'https://api.1msg.io/api/v1/inbox/conversations'{ "data": [ { "id": "string", "channelId": "string", "contactId": "string", "status": "OPEN", "assignedTo": "string", "assignedUser": { "id": "b2bb82f0-2253-4e05-b955-a21f3d699caa", "name": "QA Stage", "avatar": null }, "lastMessageAt": "2019-08-24T14:15:22Z", "isUnread": true, "tags": [ "string" ], "lastMessagePreview": "string", "lastMessageType": "string", "lastMessageDirection": "INBOUND", "lastMessageStatus": "string", "unreadCount": 0, "isBlocked": true, "title": "string", "lastCustomerMessageAt": "2019-08-24T14:15:22Z", "createdAt": "2019-08-24T14:15:22Z", "updatedAt": "2019-08-24T14:15:22Z", "contact": { "id": "string", "phoneNumber": "79001234567", "name": "string", "avatar": "string" }, "channelType": "WABA", "customerPhone": "string" } ], "pagination": { "hasMore": true, "nextCursor": "2019-08-24T14:15:22Z", "limit": 50 }}