Obter mensagens de uma conversa
Este método permite obter as mensagens de uma conversa.
get/api/v4/talks/{talk_id}/messages
Request
- Base URLhttps://subdomain.kommo.com
- URLhttps://subdomain.kommo.com/api/v4/talks/{talk_id}/messages
- AuthOAuth 2
Path parameters
talk_idinteger required
ID da conversa
Query parameters
pageinteger
Página de resposta
limitinteger
Número de entidades retornadas por requisição (limite – 250)
filter[created_at][from]integer
Filtro pela data da mensagem enviada no formato Unix Timestamp. Filtra mensagens à partir desta data.
filter[created_at][to]integer
Filtro pela data da mensagem enviada no formato Unix Timestamp. Filtra mensagens até esta data.
Response
Requisição bem-sucedida
Example response
{
"_page": 1,
"_links": {
"self": {
"href": "https://subdomain.kommo.com/api/v4/talks/123/messages?page=1&limit=250"
}
},
"_embedded": {
"messages": [
{
"id": "213sda-308d-417b-das2-2b9c345b439c",
"chat_id": "bb64b9c5-fd21-l9l2-999e-8908e8ad8c41",
"type": "outgoing",
"message_type": "picture",
"author": {
"id": "231babf6-daa8-42a5-8cf5-3e918b84e859",
"type": "external",
"name": "John",
"avatar_url": "http://amojo.kommo.com/attachments/profiles/c06bf32a-das2-2231-k8i2-78db178474bd/image-100-100.jpg"
},
"recipient": {
"id": "c06bf32a-b6e6-4261-a150-78db178474bd",
"type": "external",
"name": "John",
"avatar_url": "http://amojo.kommo.com/attachments/profiles/c06bf32a-das2-2231-k8i2-78db178474bd/image-100-100.jpg"
},
"text": "Hello",
"created_at": 1762446507,
"sec_created_at": 1762446507538,
"origin": "kommo_origin",
"delivery_status": "delivered",
"attachment": {
"type": "picture",
"link": "https://drive-c.kommo.com/download/1d7dff1e-dw12-5996-8dda-7c55db97f528/76ec5d70-daw1-23f2-b368-b285372c1449/5d526004-dbef-4c8e-9474-64e542201089/data.png",
"file_name": "data.png"
}
}
]
}
}Changes
No recorded changes to this operation across all 2 revisions of this API.