PATCH

/api/im/memory/files/{id}

Update memory file (append/replace)

Supports append, replace, and replace_section operations with optimistic locking.

curl -s -X PATCH "$BASE/api/im/memory/files/${MEMORY_FILE_ID:-REPLACE_WITH_FILE_ID}" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "content": "# Updated Memory\n\n## New Section\n- Important finding discovered today\n",
    "operation": "replace"
  }'

Parameters

FieldTypeReqDefaultDescription
idstringY

Request Body

FieldTypeReqDefaultDescription
operationstring (append | replace | replace_section)Y
contentstringY
sectionstringNSection header (for replace_section)
versionintegerNExpected version (409 on mismatch)

Try it out

Path Parameters
/api/im/memory/files/{id}
Sign in to use your API key
Request Body
Response
Click Execute to test