Lists memory files of a memory store sorted by path, with path-prefix filtering. Keyword search over bodies is not supported.
Prerequisites
Endpoint and authentication configured. For details, see Overview and authentication.
Endpoint
GET /memory_stores/{memory_store_id}/memories
Path parameters
| Field | Required | Type | Description |
|---|---|---|---|
memory_store_id | Yes | string | Memory store ID |
Query parameters
| Field | Required | Type | Description |
|---|---|---|---|
path_prefix | No | string | Directory prefix filter, starting and ending with /, for example /notes/; up to 1024 UTF-8 bytes |
depth | No | 0 / 1 | 0 lists all files recursively (default); 1 lists only the current level and returns sub-directories in prefixes |
view | No | basic / full | basic excludes bodies (default); full includes bodies |
limit | No | integer | Page size. basic: 1-100, default 20; full: 1-20 |
page | No | string | Pagination cursor. Keep all other query parameters and limit unchanged when paging |
Request example
Response example
Response fields
| Field | Type | Description |
|---|---|---|
data | array<object> | Array of memories; basic view excludes content |
id | string | |
type | string | |
memory_store_id | string | |
path | string | |
content | string | |
content_sha256 | string | |
content_size_bytes | integer | |
memory_version_id | string | |
created_at | string | |
updated_at | string | |
prefixes | array<string> | Sub-directory prefixes of the current level when depth=1 |
next_page | string | null | Cursor for the next page; absent when there is no more data |
Error codes
| HTTP status | Error code | Description |
|---|---|---|
| 400 | invalid_request_error | Invalid parameters, path, limit, or pagination cursor |
| 401 | InvalidApiKey | API key missing, invalid, or expired |
| 403 | permission_error | Insufficient identity or resource access permissions |
| 404 | not_found_error | Resource does not exist or does not belong to the current workspace |