Skip to main content
GET
/
api
/
v1
/
messages
List messages
curl --request GET \
  --url http://localhost:{port}/api/v1/messages \
  --header 'Authorization: Bearer <token>'
{
  "data": [
    {
      "id": "<string>",
      "body": "<string>",
      "fromMe": true,
      "timestamp": 123,
      "isStarred": true,
      "isPinned": true,
      "mentions": [
        "<string>"
      ],
      "groupMentions": [
        "<string>"
      ],
      "reactions": [
        {
          "reaction": "<string>",
          "senderId": "<string>",
          "timestamp": 123
        }
      ]
    }
  ],
  "pagination": {
    "total": 123,
    "page": 123,
    "pageSize": 123,
    "totalPages": 123
  }
}

Authorizations

Authorization
string
header
required

JWT token authentication

Query Parameters

chatId
string

Filter messages by chat ID

page
number

Page number

limit
number

Items per page

Response

200 - application/json

Messages retrieved successfully

data
object[]
required

Array of messages

pagination
object
required

Pagination metadata