Skip to main content

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.

POST /v1/memory_stores/{memory_store_id}/memories Creates a new memory entry in the specified Memory Store.

Path parameters

ParameterTypeRequiredDescription
memory_store_idstringYesMemory Store ID with the memstore_ prefix

Headers

HeaderRequiredDescription
AuthorizationYesBearer $QODER_PAT
Content-TypeYesapplication/json

Request body

FieldTypeRequiredDescription
pathstringYesRelative path (must not start with /)
contentstringYesMemory content (text)

Example request

curl -X POST "https://openapi.qoder.sh/api/v1/cloud/memory_stores/memstore_xxx/memories" \
  -H "Authorization: Bearer $QODER_PAT" \
  -H "Content-Type: application/json" \
  -d '{
    "path": "notes/meeting.md",
    "content": "Meeting notes content..."
  }'

Example response

HTTP 201 Created Returns the created MemoryEntry object.
{
  "id": "mem_019e3bb965a671fca51bde1cf8d87de0",
  "type": "memory",
  "store_id": "memstore_019e3bb93b7074f9a5130d39ddcca90f",
  "path": "notes/meeting.md",
  "content": "Meeting notes content...",
  "size": 11,
  "content_sha256": "64ec88ca00b268e5ba1a35678a1b5316d212f4f366b2477232534a8aeca37f3c",
  "version": 1,
  "metadata": {},
  "created_at": "2026-05-18T15:34:26.494349Z",
  "updated_at": "2026-05-18T15:34:26.494349Z"
}

Response fields

FieldTypeDescription
idstringUnique identifier with the mem_ prefix
typestringAlways "memory"
store_idstringOwning Memory Store ID
pathstringRelative path
contentstringMemory content
sizeint64Content size in bytes
content_sha256stringContent SHA-256 hash
versionint64Version number (starts at 1)
metadataobjectCustom metadata
created_atstringCreation time (ISO 8601)
updated_atstringLast update time (ISO 8601)

Errors

HTTPTypeTrigger
400invalid_request_errorInvalid request parameters (e.g., path starts with /)
401TOKEN_INVALIDMissing or invalid authentication token
404not_found_errorMemory Store does not exist
409conflict_errorAn entry with the same path already exists in this store

Error response examples

path starts with /:
{
  "error": {
    "message": "Field 'path' must be a relative path (cannot start with '/').",
    "type": "invalid_request_error"
  },
  "type": "error"
}
Path conflict:
{
  "error": {
    "message": "Version or state conflict.",
    "type": "conflict_error"
  },
  "type": "error"
}

Notes

  • path must be a relative path; it cannot start with /.
  • A store cannot contain two entries with the same path (returns 409).
  • The initial version is 1.
  • The server computes size and content_sha256.
  • Creating an entry also produces a version record with action: "created".
See Errors for the full error envelope.