Dunwich API Reference
Data Structures
This API uses the following data structures:
shared.DebeziumEvent
Type: object
Properties
| Property | Type | Required | Description |
|---|---|---|---|
after | object | false | Row data after change (for create/update) |
before | object | false | Row data before change (for update/delete) |
op | string | false | "c" (create), "u" (update), "d" (delete), "r" (read/snapshot) |
source | object | false | Metadata about the change (db/table info, log coords, etc) |
ts_ms | integer | false | Event timestamp in ms |
shared.IngestionBatch
Type: object
Properties
| Property | Type | Required | Description |
|---|---|---|---|
items | array<shared.IngestionItem> | false |
shared.IngestionItem
Type: object
Properties
| Property | Type | Required | Description |
|---|---|---|---|
data | object | false | |
op | shared.OperationType | false | |
schema | string | false | |
table | string | false | |
timestamp | string | false |
shared.OperationType
Type: string
Enum Values:
-
INSERT -
UPDATE -
DELETE
shared.TableColumn
Type: object
Properties
| Property | Type | Required | Description |
|---|---|---|---|
columnID | integer(int64) | false | |
encrypted | boolean | false | |
hashed | boolean | false | |
hidden | boolean | false | |
key | boolean | false | |
name | string | false | |
nullable | boolean | false | |
timestamp | boolean | false | |
type | string | false |
shared.TableSchema
Type: object
Properties
| Property | Type | Required | Description |
|---|---|---|---|
approved | boolean | false | |
columnNames | array<string> | false | |
columns | object | false | |
keys | array<string> | false | |
schema | string | false | |
table | string | false |
API Endpoints
/health
GET /health
Summary: Health
Description: Performs health check
Tags: System
Request
Responses
200 - OK
/v1/batch/ingest
POST /v1/batch/ingest
Summary: Batch ingest items
Description: Accepts an array of ingestion items in a batch payload
Tags: ingest
Request
Parameters:
| Name | In | Type | Required | Description |
|---|---|---|---|---|
batch | body | shared.IngestionBatch | true | Batch of ingestion items |
Responses
200 - OK
Schema:
{"additionalProperties":{"type":"string"},"type":"object"}
400 - Bad Request
Schema:
{"additionalProperties":{"type":"string"},"type":"object"}
/v1/debezium/event
POST /v1/debezium/event
Summary: Ingest Debezium formatted records
Description: Accepts an debezium event
Tags: ingest debezium
Request
Parameters:
| Name | In | Type | Required | Description |
|---|---|---|---|---|
event | body | shared.DebeziumEvent | true | Debezium event payload |
Responses
200 - OK
Schema:
{"additionalProperties":{"type":"string"},"type":"object"}
400 - Bad Request
Schema:
{"additionalProperties":{"type":"string"},"type":"object"}
/v1/ingest
POST /v1/ingest
Summary: Ingest a single item
Description: Accepts a JSON payload describing one ingestion operation
Tags: ingest
Request
Parameters:
| Name | In | Type | Required | Description |
|---|---|---|---|---|
item | body | shared.IngestionItem | true | Ingestion item payload |
Responses
200 - OK
Schema:
{"additionalProperties":{"type":"string"},"type":"object"}
400 - Bad Request
Schema:
{"additionalProperties":{"type":"string"},"type":"object"}
/v1/schema/{schema}/{table}
GET /v1/schema/{schema}/{table}
Summary: Get table schema
Description: Returns the JSON-encoded schema definition for the requested table
Tags: schema
Request
Parameters:
| Name | In | Type | Required | Description |
|---|---|---|---|---|
schema | path | string | true | Database schema name |
table | path | string | true | Table name |
Responses
200 - OK
Returns: shared.TableSchema
400 - Bad Request
Schema:
{"additionalProperties":{"type":"string"},"type":"object"}
/version
GET /version
Summary: Version
Description: Returns current version
Tags: System
Request
Responses
200 - OK