---
title: "Get Messages"
method: GET
path: "/threads/{thread_id}/messages"
tags: ["Messages"]
---

# Get Messages

`GET /threads/{thread_id}/messages`

## Request

- Base URL: `https://api.puppeteerai.com`
- URL: `https://api.puppeteerai.com/threads/{thread_id}/messages`
- Auth: none declared. Required headers: `Authorization`

Retrieve messages from a thread using cursor-based pagination.

## Path parameters

- `thread_id` string, required

## Query parameters

- `cursor` string, nullable: Base64-encoded pagination cursor. If not provided, returns the latest 20 messages.
- `reverse` boolean: Controls the direction of message retrieval. When false (default), returns messages older than the cursor. When true, returns messages newer than the cursor.

## Headers

- `Authorization` string, required

## Response `200`

Successful Response

- CursorMessagesResponse
  - `messages` CursorMessageModel[], required: List of messages.
    - `message_id` string, required: Unique identifier of the message.
    - `role` string, required: The role of the sender, either "user" or "AI".
    - `message` string, required: The message text.
    - `conversation_id` integer, required: ID of the conversation this message belongs to.
    - `timestamp` integer, required: Unix timestamp (seconds) when the message was sent.
    - `extras` object, nullable: Additional metadata attached to the message.
    - `conversation_end_time` string, nullable: ISO timestamp the parent conversation ended at, or null if still active.
  - `pagination` RoutersConversationsCursorPagination, required
    - `cursor` string, nullable, required: Base64-encoded cursor for the next batch of messages. Null if no more results.
  - `is_locked` boolean: True when the access link locks on conversation end and the latest conversation has ended. The widget must disable input and hide the ended conversation's history.

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/getpuppeteer/apis/puppeteer-core-api.md) - [All operations](https://skmtc.dev/getpuppeteer/apis/puppeteer-core-api/llms.txt) - [OpenAPI document](https://skmtc.dev/getpuppeteer/apis/puppeteer-core-api/revisions/94b4e928b42f?raw)
