Skip to main content

List Memory Versions

Lists historical versions of a memory store in reverse creation order. The current memory does not need to exist.

Prerequisites

Endpoint and authentication configured. For details, see Overview and authentication.

Endpoint

GET /memory_stores/{memory_store_id}/memory_versions

Path parameters

FieldRequiredTypeDescription
memory_store_idYesstringMemory store ID

Query parameters

FieldRequiredTypeDescription
memory_idNostringOnly returns versions of this memory; omit to return versions of the whole store
operationNocreated / modified / deletedFilters by the operation that produced the version
created_at.gteNostringLower bound of the version creation time (inclusive), ISO 8601 UTC
created_at.lteNostringUpper bound of the version creation time (inclusive), ISO 8601 UTC
viewNobasic / fullbasic excludes bodies (default); full returns unredacted bodies
limitNointegerPage size. basic: 1-100, default 20; full: 1-20
pageNostringPagination cursor. Keep all query conditions and limit unchanged when paging

Request example

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

Response example

{
  "data": [
    {
      "id": "memver_xxx",
      "type": "memory_version",
      "memory_store_id": "memstore_xxx",
      "memory_id": "mem_xxx",
      "operation": "modified",
      "path": "/notes/project.md",
      "content": "# Project Conventions\nThe default development environment is staging.\nChanges require regression tests.\n",
      "content_sha256": "a1b2c3d4e5f60718293a4b5c6d7e8f90a1b2c3d4e5f60718293a4b5c6d7e8f90",
      "content_size_bytes": 68,
      "created_at": "2026-09-17T08:30:00Z"
    }
  ],
  "next_page": null
}

Response fields

FieldTypeDescription
dataarray<object>Array of versions; bodies are included when view=full and not redacted
idstring
typestring
memory_store_idstring
memory_idstring
operationcreated / modified / deleted
pathstring
contentstring
content_sha256string
content_size_bytesinteger
redacted_atstring | null
created_atstring
next_pagestring | nullCursor for the next page; absent when there is no more data

Error codes

HTTP statusError codeDescription
400invalid_request_errorInvalid parameters, path, limit, or pagination cursor
401InvalidApiKeyAPI key missing, invalid, or expired
403permission_errorInsufficient identity or resource access permissions
404not_found_errorResource does not exist or does not belong to the current workspace
Flow Agent API
Sandbox API
RAG API
Long-term Memory
ParseX API
Security API
Framework Integration