v1

latestOpenAPI 3.0.02026-07-24378968.5 KB
Chat

/chat/{id}/messages

Retrieve all messages by passing a specific chat

get/chat/{id}/messages

Path parameters

idstring required

Query parameters

pagenumber

Number of the page

limitnumber

Limit of items per page. MAX = 100, MIN = 1

propertystring required

Name of the property to sort

direction'asc' | 'desc' required

'asc' or 'desc' to order the result

Headers

octa-agent-emailstring

Response

idstring required

Message identifier

chatIdstring required

Chat identifier

timestring date-time required

Message sending date

type'public' | 'internal' required

Indicate whether the message is intended for internal or public communication

bodystring required

Message content

readAtstring date-time

Date the message was read

status'sending' | 'sended' | 'received' | 'read' | 'error' | 'deleted' | 'scheduled' | 'spam' required

Message status

quotedobject

Message that was quoted

externalLinkstring

External links sent in the message

errorSourcestring

Source of the error (e.g. "meta", "platform") when status is "error"

errorCodestring

Error code returned by the provider (e.g. Meta/WhatsApp) when status is "error"

errorMessagestring

Detailed error message from the provider when status is "error"

Example response

[
  {
    "sentBy": {
      "phoneContacts": {
        "number": "119999999999",
        "countryCode": "55"
      }
    },
    "mentions": [
      {
        "phoneContacts": {
          "number": "119999999999",
          "countryCode": "55"
        }
      }
    ]
  }
]