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

# 列出对话记忆 - GET /v1/workspaces/:workspace_id/chat-memories

> 通过 GET /v1/workspaces/:workspace_id/chat-memories 返回分层对话记忆，可按 layer 过滤。最小角色 viewer。

返回工作空间的分层对话记忆（L0 原子 / L1 场景 / L2 画像 / L3 核心）。可用 `layer` 查询参数按层级过滤。

## 接口

```http theme={null}
GET /v1/workspaces/:workspace_id/chat-memories
```

## 认证

`Authorization: Bearer <jwt>` 或 `X-API-Key <sk_...>`。最小角色：**viewer**。

## 路径参数

<ParamField path="workspace_id" type="string" required>
  工作空间 id。
</ParamField>

## 查询参数

<ParamField query="layer" type="integer">
  仅返回该层级的记忆（0–3）。
</ParamField>

## 响应

响应为一个数组，每个元素为一条对话记忆：

<ResponseField name="id" type="string">
  记忆 id（`cm_...`）。
</ResponseField>

<ResponseField name="workspace_id" type="string">
  所属工作空间 id。
</ResponseField>

<ResponseField name="owner_id" type="string">
  拥有者用户 id。
</ResponseField>

<ResponseField name="session_id" type="string">
  来源会话 id。
</ResponseField>

<ResponseField name="layer" type="integer">
  层级（0 原子 / 1 场景 / 2 画像 / 3 核心）。
</ResponseField>

<ResponseField name="kind" type="string">
  类型（`fact` / `preference` / `constraint` / `event` / `scenario` / `persona`）。
</ResponseField>

<ResponseField name="content" type="string">
  记忆内容。
</ResponseField>

<ResponseField name="visibility" type="string">
  可见性（`private` / `team` / `restricted` / `agent`）。
</ResponseField>

<ResponseField name="created_at" type="string">
  创建时间（RFC3339）。
</ResponseField>

## 示例

<RequestExample>
  ```bash cURL theme={null}
  curl "https://memo.ariacompute.cn/v1/workspaces/ws_01a2b3c4d5e6/chat-memories?layer=3" \
    -H "Authorization: Bearer <jwt>"
  ```
</RequestExample>

<ResponseExample>
  ```json 200 theme={null}
  [
    {
      "id": "cm_01a2b3c4d5e6",
      "workspace_id": "ws_01a2b3c4d5e6",
      "owner_id": "usr_01a2b3c4d5e6",
      "session_id": "sess_01a2b3c4d5e6",
      "layer": 3,
      "kind": "persona",
      "content": "用户是开发者，关注定价与集成。",
      "visibility": "private",
      "created_at": "2026-10-12T09:05:00Z"
    }
  ]
  ```
</ResponseExample>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.