Skip to main content
Memory Store

列出 Memory Version

按创建时间倒序列出记忆库的历史版本。

前提

已完成 Endpoint 与鉴权配置,详见API 总览与认证。

接口

GET /memory_stores/{memory_store_id}/memory_versions

路径参数

参数必填类型说明
memory_store_id是string记忆库 ID

Query 参数

参数必填类型说明
memory_id否string仅返回该记忆的版本;不传则返回整个记忆库的版本
operation否created / modified / deleted按产生版本的操作类型过滤
created_at.gte否string版本产生时间下界(含),ISO 8601 UTC
created_at.lte否string版本产生时间上界(含),ISO 8601 UTC
view否basic / fullbasic 不含正文(默认);full 返回未擦除的正文
limit否integer单页条数。basic 为 1-100 默认 20;full 为 1-20
page否string分页游标。翻页时保持全部查询条件与 limit 不变

请求示例

curl "$AGENTSTUDIO_URL/memory_stores/memstore_xxx/memory_versions" \
  -H "Authorization: Bearer $DASHSCOPE_API_KEY"

响应

{
  "data": [
    {
      "id": "memver_xxx",
      "type": "memory_version",
      "memory_store_id": "memstore_xxx",
      "memory_id": "mem_xxx",
      "operation": "modified",
      "path": "/notes/project.md",
      "content": "# 项目约定\n默认开发环境为预发环境。\n变更需要补充回归测试。\n",
      "content_sha256": "a1b2c3d4e5f60718293a4b5c6d7e8f90a1b2c3d4e5f60718293a4b5c6d7e8f90",
      "content_size_bytes": 68,
      "created_at": "2026-09-17T08:30:00Z"
    }
  ],
  "next_page": null
}

响应字段

字段类型说明
dataarray<object>版本数组;view=full 且未擦除时包含正文
idstring版本 ID,格式 memver_xxx
typestring固定为 memory_version
memory_store_idstring所属记忆库 ID
memory_idstring对应的记忆 ID
operationcreated / modified / deleted产生该版本的操作类型
pathstring该版本快照中的路径
contentstring该版本正文;已擦除时不含此字段
content_sha256string该版本正文的 SHA256 哈希
content_size_bytesinteger该版本正文的 UTF-8 字节数
redacted_atstring | null正文被擦除的时间;未擦除时省略或为 null
created_atstring版本产生时间,ISO 8601 UTC
next_pagestring | null下一页游标;无更多数据时不含该字段

错误码

状态码错误码说明
400invalid_request_error参数、路径、limit 或分页游标非法
401InvalidApiKeyAPI Key 缺失、错误或失效
403permission_error身份或资源访问权限不足
404not_found_error资源不存在或不属于当前工作空间
Sandbox
Security
RAG
应用调用
长期记忆
ParseX
框架