Write items in bulk
Up to 25 sets and deletes in one call, in one scope.
Not a transaction. Each operation succeeds or fails on its own and is reported separately; the call returns 200 even when some failed. Check every entry's ok — treating a 200 as "all 25 landed" is the mistake this endpoint invites.
Authorization
AuthorizationheaderrequiredBearer YOUR_API_KEY. Create a key in the dashboard.
Path parameters
collectionstringrequiredCollection name.
Query parameters
scopestringWhich scope to address:
contact:<contactId>,conversation:<conversationId>, or omitted for the project scope.Note the asymmetry with
POST /v1/memoryandPOST /v1/memory/search, which take the scope in the request BODY asscopepluscontactId/conversationId. Every other Memory endpoint takes it here.
Body
application/json
opsobject[]requiredLimitsmin items 1 · max items 254 properties
opstringrequiredOne ofsetdeletekeystringrequiredvalueanyThe document, for
set.ttlSecondsintegerLimitsmin 60 · max 63072000
Responses
200Every operation was attempted. Inspect each result.
resultsobject[]requiredOne entry per submitted operation, in order. Check every
ok: the call returns 200 even when some operations failed.4 properties
keystringrequiredokbooleanrequiredrevintegerNew revision, on a successful
set.errorstringWhy this operation failed. Present when
okis false.
400Invalid body, scope, or more than 25 operations.
codestringrequiredmessagestringrequireddetailsobject
401Unauthorized.
codestringrequiredmessagestringrequireddetailsobject
404Collection not found.
codestringrequiredmessagestringrequireddetailsobject
429The plan's monthly unit quota is spent.
codestringrequiredmessagestringrequireddetailsobject