Caura / docs
API Reference

Memories · Bulk write

POST /api/v1/memories/bulk — write many memories in one request.

Embedding defers by default on this path. Items written without a vector come back with metadata.embedding_pending: true, and until it clears they are reachable by keyword and by the non-semantic list, but do not compete on semantic similarity — so a paraphrase search can miss a memory an exact-words search finds.

POST
/api/v1/memories/bulk

Authorization

APIKeyHeader
headerX-API-Key<token>

Header Parameters

Idempotency-Key?string|null
X-Bulk-Attempt-Id?string|null

Request Body

application/json
  1. body
tenant_id?Tenant Id

Tenant to operate on. Omit it and the tenant is resolved from the credential, which is what a tenant- or agent-scoped key already identifies — no prior /whoami call is needed. Supply it to act on a different tenant your credential may read (and for an admin key, which belongs to no single tenant, it is required).

Default""
fleet_id?string|null
agent_id?string|null
items*array<>
Items1 <= items <= 100
visibility?|null

Response Body

Successful Response

application/json
  1. response

Aggregate response from the bulk-write endpoint.

duplicates rolls up both duplicate_attempt and duplicate_content for top-level metric continuity; per-item detail lives in results. The route returns 200 when everything succeeded and 207 Multi-Status when at least one item is in error — callers must read per-item status and never infer success from a 2xx alone.

created*Created
duplicates*Duplicates
errors*Errors
results*array<>
bulk_ms*Bulk Ms
Example Request
curl -X POST 'https://example.com/api/v1/memories/bulk' \  -H 'Content-Type: application/json' \  -d '{  "items": [    {      "content": "string"    }  ]}'
Example Response
{  "created": 0,  "duplicates": 0,  "errors": 0,  "results": [    {      "index": 0,      "client_request_id": "string",      "status": "created",      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",      "duplicate_of": "15a4136f-d85d-4645-ade9-a6c6085b348c",      "error": "string"    }  ],  "bulk_ms": 0}