Commerce CensusContactRequest access

API / Memory

Write memory

Store a durable fact for a namespace you control. Preferences, constraints, past purchases, rejected options — anything the next session should not have to ask about again.

POST /v1/memory

Request

NameTypeNotes
namespacestringYour scope for one end user or agent.
kindstringpreference | constraint | purchase | rejection | intent.
bodystringThe fact, in plain language.
subjectobjectOptional product_id, brand or category it attaches to.
ttl_daysintOptional expiry. Constraints usually outlive intents.
Request & response
POST /v1/memory
{ "namespace": "user_9f21",
  "kind": "constraint",
  "body": "never recommend anything with a subscription attached",
  "ttl_days": 365 }

→ 201
{ "memory_id": "mem_0c81a", "namespace": "user_9f21" }