API: entities
GET /api/v1/entities
Section titled “GET /api/v1/entities”List Entity Types
Auth: Authorization: Bearer <token> required
Responses:
| Code | Meaning | Body |
|---|---|---|
200 | Successful Response | array of EntityInfo |
401 | Missing or invalid authentication credentials | ErrorResponse |
GET /api/v1/entities/{name}
Section titled “GET /api/v1/entities/{name}”List Records
List entity records — paginated, sortable, filterable.
Any query param that is not a control param (limit/offset/sort/
include_meta) is read as a column filter: col (equals), col_like
(ILIKE), col_from/col_to (range). Large JSON/text columns are
truncated to a preview stub; ?include_meta=true adds the runtime schema.
Auth: Authorization: Bearer <token> required
| Parameter | In | Required | Type | Description |
|---|---|---|---|---|
name | path | yes | string | |
limit | query | no | integer | |
offset | query | no | integer | |
sort | query | no | string | null | |
include_meta | query | no | boolean | |
include_deleted | query | no | boolean |
Responses:
| Code | Meaning | Body |
|---|---|---|
200 | Successful Response | EntityListResponse |
401 | Missing or invalid authentication credentials | ErrorResponse |
422 | Validation Error | HTTPValidationError |
POST /api/v1/entities/{name}
Section titled “POST /api/v1/entities/{name}”Create Record
Auth: Authorization: Bearer <token> required
| Parameter | In | Required | Type | Description |
|---|---|---|---|---|
name | path | yes | string | |
Idempotency-Key | header | no | string | Optional. |
Request body: application/json
Responses:
| Code | Meaning | Body |
|---|---|---|
201 | Successful Response | object |
401 | Missing or invalid authentication credentials | ErrorResponse |
422 | Validation Error | HTTPValidationError |
POST /api/v1/entities/{name}/bulk-delete
Section titled “POST /api/v1/entities/{name}/bulk-delete”Bulk Delete
Delete many rows — PROD rows without approval are blocked.
Auth: Authorization: Bearer <token> required
| Parameter | In | Required | Type | Description |
|---|---|---|---|---|
name | path | yes | string | |
x-prod-approval | header | no | string | null | Production guard. |
Idempotency-Key | header | no | string | Optional. |
Request body: application/json — schema BulkDeleteRequest
| Field | Type | Required | Description |
|---|---|---|---|
guids | array of integer | yes |
Example:
{ "guids": [ 31567, 31568 ]}Responses:
| Code | Meaning | Body |
|---|---|---|
200 | Successful Response | BulkDeleteResponse |
401 | Missing or invalid authentication credentials | ErrorResponse |
422 | Validation Error | HTTPValidationError |
POST /api/v1/entities/{name}/bulk-export
Section titled “POST /api/v1/entities/{name}/bulk-export”Bulk Export
Export selected rows as a downloadable JSON file.
Auth: Authorization: Bearer <token> required
| Parameter | In | Required | Type | Description |
|---|---|---|---|---|
name | path | yes | string | |
Idempotency-Key | header | no | string | Optional. |
Request body: application/json — schema BulkExportRequest
| Field | Type | Required | Description |
|---|---|---|---|
format | string | no | |
guids | array of integer | yes |
Responses:
| Code | Meaning | Body |
|---|---|---|
200 | Successful Response | object |
401 | Missing or invalid authentication credentials | ErrorResponse |
422 | Validation Error | HTTPValidationError |
GET /api/v1/entities/{name}/count
Section titled “GET /api/v1/entities/{name}/count”Count Records
Row count for an entity, cached in-process for 30s.
Auth: Authorization: Bearer <token> required
| Parameter | In | Required | Type | Description |
|---|---|---|---|---|
name | path | yes | string |
Responses:
| Code | Meaning | Body |
|---|---|---|
200 | Successful Response | EntityCountResponse |
401 | Missing or invalid authentication credentials | ErrorResponse |
422 | Validation Error | HTTPValidationError |
DELETE /api/v1/entities/{name}/{guid}
Section titled “DELETE /api/v1/entities/{name}/{guid}”Delete Record
Delete a row — soft (deleted_at) for soft-deletable entities.
Auth: Authorization: Bearer <token> required
| Parameter | In | Required | Type | Description |
|---|---|---|---|---|
name | path | yes | string | |
guid | path | yes | integer | |
x-prod-approval | header | no | string | null | Production guard. |
Idempotency-Key | header | no | string | Optional. |
Responses:
| Code | Meaning | Body |
|---|---|---|
204 | Successful Response | — |
401 | Missing or invalid authentication credentials | ErrorResponse |
422 | Validation Error | HTTPValidationError |
GET /api/v1/entities/{name}/{guid}
Section titled “GET /api/v1/entities/{name}/{guid}”Read Record
Read one full row + runtime schema for the row drawer.
Auth: Authorization: Bearer <token> required
| Parameter | In | Required | Type | Description |
|---|---|---|---|---|
name | path | yes | string | |
guid | path | yes | integer |
Responses:
| Code | Meaning | Body |
|---|---|---|
200 | Successful Response | RowResponse |
401 | Missing or invalid authentication credentials | ErrorResponse |
422 | Validation Error | HTTPValidationError |
PATCH /api/v1/entities/{name}/{guid}
Section titled “PATCH /api/v1/entities/{name}/{guid}”Update Record
Partial update — PROD-guarded and audit-logged.
Auth: Authorization: Bearer <token> required
| Parameter | In | Required | Type | Description |
|---|---|---|---|---|
name | path | yes | string | |
guid | path | yes | integer | |
x-prod-approval | header | no | string | null | Production guard. |
Idempotency-Key | header | no | string | Optional. |
Request body: application/json
Responses:
| Code | Meaning | Body |
|---|---|---|
200 | Successful Response | object |
401 | Missing or invalid authentication credentials | ErrorResponse |
422 | Validation Error | HTTPValidationError |
GET /api/v1/entities/{name}/{guid}/audit
Section titled “GET /api/v1/entities/{name}/{guid}/audit”Read Audit
Audit trail for one row, projected from lifecycle_log.
Latest first. A multi-field edit is expanded into one event per field.
Auth: Authorization: Bearer <token> required
| Parameter | In | Required | Type | Description |
|---|---|---|---|---|
name | path | yes | string | |
guid | path | yes | integer | |
limit | query | no | integer |
Responses:
| Code | Meaning | Body |
|---|---|---|
200 | Successful Response | array of AuditEvent |
401 | Missing or invalid authentication credentials | ErrorResponse |
422 | Validation Error | HTTPValidationError |
GET /api/v1/entities/{name}/{guid}/field/{field}
Section titled “GET /api/v1/entities/{name}/{guid}/field/{field}”Read Field
Read one field’s full, untruncated value — lazy JSON load.
Auth: Authorization: Bearer <token> required
| Parameter | In | Required | Type | Description |
|---|---|---|---|---|
name | path | yes | string | |
guid | path | yes | integer | |
field | path | yes | string |
Responses:
| Code | Meaning | Body |
|---|---|---|
200 | Successful Response | FieldResponse |
401 | Missing or invalid authentication credentials | ErrorResponse |
422 | Validation Error | HTTPValidationError |
POST /api/v1/entities/{name}/{guid}/restore
Section titled “POST /api/v1/entities/{name}/{guid}/restore”Restore Record
Restore a soft-deleted row — clears deleted_at a).
Auth: Authorization: Bearer <token> required
| Parameter | In | Required | Type | Description |
|---|---|---|---|---|
name | path | yes | string | |
guid | path | yes | integer | |
x-prod-approval | header | no | string | null | Production guard. |
Idempotency-Key | header | no | string | Optional. |
Responses:
| Code | Meaning | Body |
|---|---|---|
200 | Successful Response | object |
401 | Missing or invalid authentication credentials | ErrorResponse |
422 | Validation Error | HTTPValidationError |