> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs-beta.getzep.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs-beta.getzep.com/_mcp/server.

# List thread messages

GET https://api.getzep.com/api/v4/threads/{thread_uuid}/messages

Reference: https://docs-beta.getzep.com/sdk-reference/thread/list-messages

## Authentication

- `Authorization` header (required) (prefixed with ` Api-Key  `) — Type "Api-Key" followed by a space and the project API key.

## Request

### Path parameters

- `thread_uuid` (string, required) — Thread UUID

### Query parameters

- `limit` (integer, optional) — Page size
- `cursor` (string, optional) — Opaque page cursor
- `order_by` (enum, optional) — Sort field
  - Allowed values: `created_at`
- `order` (enum, optional) — Sort direction: asc or desc
  - Allowed values: `asc`, `desc`

## Response

### 200

OK

- `items` (list of v4.Message, optional) — The messages on this page.
- `next_cursor` (string, optional) — The cursor to pass as the next request's cursor to fetch the following page; absent when no further pages remain.
- `total_size` (integer, optional) — The total number of matching messages, counted at the time of this response. It does not indicate whether more pages remain.

## Errors

### 400 Bad Request Error

Bad Request

- `error` (v4.ErrorBody, optional)

### 401 Unauthorized Error

Unauthorized

- `error` (v4.ErrorBody, optional)

### 404 Not Found Error

Not Found

- `error` (v4.ErrorBody, optional)

## Types

### v4.Message

- `content` (string, optional) — The content of the message.
- `created_at` (string, optional) — The time the message was created.
- `metadata` (map from string to any, optional) — Arbitrary key-value metadata attached to the message.
- `name` (string, optional) — A custom name for the message's sender, for example a specific user or agent name.
- `processed` (boolean, optional) — Whether the message has finished being ingested into the user's graph.
- `role` (enum, optional) — The role of the message's sender: system, assistant, user, function, or tool.
  - Allowed values: `system`, `assistant`, `user`, `function`, `tool`
- `thread_uuid` (string, optional) — The unique identifier of the thread this message belongs to.
- `uuid` (string, optional) — The unique identifier of the message.

### v4.ErrorBody

- `code` (string, optional)
- `details` (map from string to any, optional)
- `message` (string, optional)
- `param` (string, optional)
- `request_id` (string, optional)

## Examples

**Response**

```json
{
  "items": [
    {
      "content": "string",
      "created_at": "string",
      "metadata": {},
      "name": "string",
      "processed": true,
      "role": "system",
      "thread_uuid": "string",
      "uuid": "string"
    }
  ],
  "next_cursor": "string",
  "total_size": 1
}
```