Skip to content

Dynamic Consistency Boundary (DCB)

DCB APIs, types, and error responses

This is the reference for DCB in DeltaBase. No fluff, just facts.

POST /event-stores/{eventStoreName}/events

Section titled “POST /event-stores/{eventStoreName}/events”

Streamless append with an optional append condition.

Request:

{
"events": [
{
"type": "UserRegistered",
"data": { "userId": "u1", "username": "alice" },
"tags": ["username:alice"]
}
],
"condition": {
"failIfEventsMatch": {
"items": [
{ "types": ["UserRegistered"], "tags": ["username:alice"] }
]
},
"after": 123
}
}

Response:

{
"lastPosition": 456
}

Read events by query (types and/or tags).

Request:

{
"query": {
"items": [
{ "types": ["UserRegistered"], "tags": ["username:alice"] }
]
},
"after": 0,
"limit": 1000
}

Response:

{
"events": [
{
"eventId": "...",
"type": "UserRegistered",
"data": { "userId": "u1", "username": "alice" },
"tags": ["username:alice"],
"streamId": "__dcb__",
"streamPosition": 1,
"globalPosition": 456,
"schemaVersion": "0.0.1",
"transactionId": "0",
"createdAt": "2026-02-04T20:00:00Z"
}
],
"lastPosition": 456
}

streamId is included for compatibility. For DCB events it is a reserved internal value. Treat it as an implementation detail.

Opaque string. Commas are forbidden.

{ "items": [ { "types": ["A"], "tags": ["t1", "t2"] } ] }
  • Types are OR within a query item
  • Tags are AND within a query item
  • Query items are OR across the query
{
"failIfEventsMatch": { "items": [ ... ] },
"after": 123
}
{
"error": "Append condition failed",
"details": "...",
"conflictingPositions": [456],
"afterPosition": 123
}
  • Tags must not contain commas.
  • The reserved stream id __dcb__ is not allowed in stream endpoints.