---
updatedAt: 2026-07-08T15:26:35.000Z
agentTools:
  projectIndex: https://pt-developers.kommo.com/llms.txt
---

# Obter mensagens de uma conversa

Este método permite obter as mensagens de uma conversa.

**Limitações**

* O método está disponível de acordo com as permissões/direitos do usuário.
* O método está disponível para contas nos planos: **Teste**, **Pro**, **Empresarial** e **Técnico**.
* O método requer o <Anchor target="_blank" href="https://pt-developers.kommo.com/docs/permiss%C3%B5es">escopo</Anchor> de integração `Histórico de chats externos`

**Cabeçalho do tipo de dados quando a requisição é bem-sucedida**<br />Content-Type: application/hal+json

**Cabeçalho do tipo de dados no caso de erro**<br />Content-Type: application/problem+json

## Parâmetros de resposta

| Parâmetro               | Tipo de dado   | Descrição                                                                                                                               |
| :---------------------- | :------------- | :-------------------------------------------------------------------------------------------------------------------------------------- |
| id                      | string         | ID da mensagem                                                                                                                          |
| chat\_id                | string         | ID do chat                                                                                                                              |
| type                    | string         | Direção da mensagem. Valores possíveis: `incoming`, `outgoing`                                                                          |
| message\_type           | string         | Tipo de conteúdo da mensagem. Valores possíveis: `text`, `contact`, `file`, `video`, `picture`, `voice`, `audio`, `sticker`, `location` |
| author                  | obj            | Objeto do autor da mensagem                                                                                                             |
| author\[id]             | string         | ID do autor                                                                                                                             |
| author\[type]           | string         | Tipo de autor. Valores possíveis: `internal` (Usuário Kommo), `external` (Cliente), `bot` (Bot da Kommo)                                |
| author\[name]           | string         | Nome de exibição do autor                                                                                                               |
| author\[avatar\_url]    | string         | URL do avatar do autor                                                                                                                  |
| author\[user\_id]       | int            | ID do usuário da Kommo. Será retornado somente quando `author[type]: internal`                                                          |
| recipient               | obj            | Objeto do destinatário da mensagem                                                                                                      |
| recipient\[id]          | string         | ID do destinatário                                                                                                                      |
| recipient\[type]        | string \| null | Tipo de destinatário. Valores possíveis: `external` (Cliente)                                                                           |
| recipient\[name]        | string         | Nome de exibição do destinatário                                                                                                        |
| recipient\[avatar\_url] | string         | URL do avatar do destinatário                                                                                                           |
| text                    | string         | Texto da mensagem. Vazio em caso de mensagens sem texto content                                                                         |
| created\_at             | int            | Momento da criação da mensagem no formato Unix Timestamp (segundos)                                                                     |
| sec\_created\_at        | int            | Momento da criação da mensagem no formato Unix Timestamp (milissegundos)                                                                |
| origin                  | string         | Canal de chat da mensagem.                                                                                                              |
| delivery\_status        | string         | Status de entrega da mensagem. Valores possíveis: `sent`, `delivered`, `error`                                                          |
| attachment              | obj \| null    | Objeto anexado                                                                                                                          |
| attachment\[type]       | string         | Tipo de anexo                                                                                                                           |
| attachment\[link]       | string         | URL ou caminho do arquivo anexado                                                                                                       |
| attachment\[file\_name] | string         | Nome do arquivo anexado                                                                                                                 |

<br />

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "referencias-de-api-da-kommo",
    "version": "1.1"
  },
  "servers": [
    {
      "url": "https://{subdomain}.kommo.com",
      "variables": {
        "subdomain": {
          "default": "subdomain"
        }
      }
    }
  ],
  "components": {
    "securitySchemes": {
      "sec0": {
        "type": "oauth2",
        "flows": {}
      }
    }
  },
  "security": [
    {
      "sec0": []
    }
  ],
  "paths": {
    "/api/v4/talks/{talk_id}/messages": {
      "get": {
        "responses": {
          "200": {
            "description": "Requisição bem-sucedida",
            "content": {
              "application/hal+json": {
                "examples": {
                  "Requisição bem-sucedida": {
                    "summary": "Requisição bem-sucedida",
                    "value": "{\n  \"_page\": 1,\n  \"_links\": {\n    \"self\": {\n      \"href\": \"https://subdomain.kommo.com/api/v4/talks/123/messages?page=1&limit=250\"\n    }\n  },\n  \"_embedded\": {\n    \"messages\": [\n      {\n        \"id\": \"213sda-308d-417b-das2-2b9c345b439c\",\n        \"chat_id\": \"bb64b9c5-fd21-l9l2-999e-8908e8ad8c41\",\n        \"type\": \"outgoing\",\n        \"message_type\": \"picture\",\n        \"author\": {\n          \"id\": \"231babf6-daa8-42a5-8cf5-3e918b84e859\",\n          \"type\": \"external\",\n          \"name\": \"John\",\n          \"avatar_url\": \"http://amojo.kommo.com/attachments/profiles/c06bf32a-das2-2231-k8i2-78db178474bd/image-100-100.jpg\"\n        },\n        \"recipient\": {\n          \"id\": \"c06bf32a-b6e6-4261-a150-78db178474bd\",\n          \"type\": \"external\",\n          \"name\": \"John\",\n          \"avatar_url\": \"http://amojo.kommo.com/attachments/profiles/c06bf32a-das2-2231-k8i2-78db178474bd/image-100-100.jpg\"\n        },\n        \"text\": \"Hello\",\n        \"created_at\": 1762446507,\n        \"sec_created_at\": 1762446507538,\n        \"origin\": \"kommo_origin\",\n        \"delivery_status\": \"delivered\",\n        \"attachment\": {\n          \"type\": \"picture\",\n          \"link\": \"https://drive-c.kommo.com/download/1d7dff1e-dw12-5996-8dda-7c55db97f528/76ec5d70-daw1-23f2-b368-b285372c1449/5d526004-dbef-4c8e-9474-64e542201089/data.png\",\n          \"file_name\": \"data.png\"\n        }\n      }\n    ]\n  }\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "_page": {
                      "type": "integer",
                      "example": 1,
                      "default": 0
                    },
                    "_links": {
                      "type": "object",
                      "properties": {
                        "self": {
                          "type": "object",
                          "properties": {
                            "href": {
                              "type": "string",
                              "example": "https://subdomain.kommo.com/api/v4/talks/123/messages?page=1&limit=250"
                            }
                          }
                        }
                      }
                    },
                    "_embedded": {
                      "type": "object",
                      "properties": {
                        "messages": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "id": {
                                "type": "string",
                                "example": "213sda-308d-417b-das2-2b9c345b439c"
                              },
                              "chat_id": {
                                "type": "string",
                                "example": "bb64b9c5-fd21-l9l2-999e-8908e8ad8c41"
                              },
                              "type": {
                                "type": "string",
                                "example": "outgoing"
                              },
                              "message_type": {
                                "type": "string",
                                "example": "picture"
                              },
                              "author": {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "string",
                                    "example": "231babf6-daa8-42a5-8cf5-3e918b84e859"
                                  },
                                  "type": {
                                    "type": "string",
                                    "example": "external"
                                  },
                                  "name": {
                                    "type": "string",
                                    "example": "John"
                                  },
                                  "avatar_url": {
                                    "type": "string",
                                    "example": "http://amojo.kommo.com/attachments/profiles/c06bf32a-das2-2231-k8i2-78db178474bd/image-100-100.jpg"
                                  }
                                }
                              },
                              "recipient": {
                                "type": "object",
                                "properties": {
                                  "id": {
                                    "type": "string",
                                    "example": "c06bf32a-b6e6-4261-a150-78db178474bd"
                                  },
                                  "type": {
                                    "type": "string",
                                    "example": "external"
                                  },
                                  "name": {
                                    "type": "string",
                                    "example": "John"
                                  },
                                  "avatar_url": {
                                    "type": "string",
                                    "example": "http://amojo.kommo.com/attachments/profiles/c06bf32a-das2-2231-k8i2-78db178474bd/image-100-100.jpg"
                                  }
                                }
                              },
                              "text": {
                                "type": "string",
                                "example": "Hello"
                              },
                              "created_at": {
                                "type": "integer",
                                "example": 1762446507,
                                "default": 0
                              },
                              "sec_created_at": {
                                "type": "integer",
                                "example": 1762446507538,
                                "default": 0
                              },
                              "origin": {
                                "type": "string",
                                "example": "kommo_origin"
                              },
                              "delivery_status": {
                                "type": "string",
                                "example": "delivered"
                              },
                              "attachment": {
                                "type": "object",
                                "properties": {
                                  "type": {
                                    "type": "string",
                                    "example": "picture"
                                  },
                                  "link": {
                                    "type": "string",
                                    "example": "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": {
                                    "type": "string",
                                    "example": "data.png"
                                  }
                                }
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "402": {
            "content": {
              "application/problem+json": {
                "schema": {
                  "type": "object",
                  "properties": {}
                },
                "examples": {
                  "Assinatura expirada": {
                    "summary": "Assinatura expirada",
                    "value": "{\n  \"title\": \"Payment Required\",\n  \"type\": \"https://httpstatus.es/402\",\n  \"status\": 402,\n  \"detail\": \"Pagamento necessário\"\n}"
                  }
                }
              }
            },
            "description": "Pagamento necessário"
          },
          "403": {
            "content": {
              "application/problem+json": {
                "schema": {
                  "type": "object",
                  "properties": {}
                },
                "examples": {
                  "O cliente não possui o escopo necessário": {
                    "summary": "O cliente não possui o escopo necessário",
                    "value": "{\n  \"title\": \"Forbidden\",\n  \"type\": \"https://httpstatus.es/403\",\n  \"status\": 403,\n  \"detail\": \"O cliente não possui o escopo necessário\"\n}"
                  }
                }
              }
            },
            "description": "Proibido"
          },
          "404": {
            "content": {
              "application/problem+json": {
                "schema": {
                  "type": "object",
                  "properties": {}
                },
                "examples": {
                  "Conversa não encontrada": {
                    "summary": "Conversa não encontrada",
                    "value": "{\n  \"title\": \"Not Found\",\n  \"type\": \"https://httpstatus.es/404\",\n  \"status\": 404,\n  \"detail\": \"Entidade requisitada não encontrada\"\n}"
                  }
                }
              }
            },
            "description": "Conversa não encontrada"
          }
        },
        "parameters": [
          {
            "in": "path",
            "name": "talk_id",
            "schema": {
              "type": "integer"
            },
            "required": true,
            "description": "ID da conversa"
          },
          {
            "in": "query",
            "name": "page",
            "schema": {
              "type": "integer"
            },
            "description": "Página de resposta"
          },
          {
            "in": "query",
            "name": "limit",
            "schema": {
              "type": "integer"
            },
            "description": "Número de entidades retornadas por requisição (limite – 250)"
          },
          {
            "in": "query",
            "name": "filter[created_at][from]",
            "schema": {
              "type": "integer"
            },
            "description": "Filtro pela data da mensagem enviada no formato Unix Timestamp. Filtra mensagens à partir desta data."
          },
          {
            "in": "query",
            "name": "filter[created_at][to]",
            "schema": {
              "type": "integer"
            },
            "description": "Filtro pela data da mensagem enviada no formato Unix Timestamp. Filtra mensagens até esta data."
          }
        ],
        "operationId": "get_api-v4-talks-1",
        "summary": "Obter mensagens de uma conversa",
        "description": "Este método permite obter as mensagens de uma conversa."
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true
}
```