POST
/api/v1/ingest/{documentType}
Ingest a document directly via its Document_Type. Uses upsert semantics — creates the document if new, merges fields if it already exists.
Request Body
| Field | Type | Required | Description |
|---|---|---|---|
| document | object | Yes | The document payload to ingest |
| versionNo | number | No | Expected version for optimistic concurrency control |
| ttl | number | "infinite" | No | Per-document TTL override (seconds) |
Response — New Document
201 Created
{
"dId": "LIVING-ROOM-01",
"versionNo": 1,
"created": true
}
Response — Updated Document
200 OK
{
"dId": "LIVING-ROOM-01",
"versionNo": 2,
"created": false
}
Errors
400 Bad Request
404 Document_Type not found
409 Version conflict
422 Schema validation failed
Note: D-Id is extracted from the document using the schema's
identityKind annotations. For composed D-Ids (parent-key + primary-key), the response returns an array.