> ## Documentation Index
> Fetch the complete documentation index at: https://docs.qoder.com/llms.txt
> Use this file to discover all available pages before exploring further.

# 列出 Memory 版本

> 列出 Store 中 memory 的版本历史。

`GET /api/v1/cloud/memory_stores/{memory_store_id}/memory_versions`

列出版本快照。每次创建、更新或删除都会产生一个版本。列表响应不包含 `content`。

## 路径参数

| 参数                | 说明                              |
| ----------------- | ------------------------------- |
| `memory_store_id` | Memory Store ID（`memstore_...`） |

## 请求头

| 头部              | 必选 | 说明             |
| --------------- | -- | -------------- |
| `Authorization` | 是  | `Bearer <PAT>` |

## 查询参数

| 参数          | 类型     | 必选 | 说明                 |
| ----------- | ------ | -- | ------------------ |
| `memory_id` | string | 否  | 仅返回指定 memory 的版本记录 |

## 示例请求

```bash theme={null}
curl "https://api.qoder.com/api/v1/cloud/memory_stores/memstore_xxx/memory_versions?memory_id=mem_xxx" \
  -H "Authorization: Bearer $QODER_PAT"
```

## 示例响应

```json theme={null}
{
  "data": [
    {
      "id": "memver_...",
      "type": "memory_version",
      "memory_store_id": "memstore_...",
      "memory_id": "mem_...",
      "path": "decisions/arch-choice.md",
      "content_size_bytes": 46,
      "content_sha256": "a1b2c3...",
      "operation": "updated",
      "redacted": false,
      "created_at": "2026-05-18T09:30:00.000Z"
    }
  ],
  "has_more": false,
  "first_id": "memver_...",
  "last_id": "memver_..."
}
```

## 错误码

| HTTP | type                   | 触发条件                 |
| ---- | ---------------------- | -------------------- |
| 401  | `authentication_error` | 缺少或无效的认证令牌           |
| 404  | `not_found_error`      | 指定的 Memory Store 不存在 |

完整错误信封说明详见 [错误参考](/zh/cloud-agents/api/conventions/errors)。
