Org Database Pool API: schemas
The request and response bodies of the operations in this API.
DbDriverKind
Type: one of "postgres", "mongo", "weaviate"
DbPoolDto
| Property | Type | Required | Description |
|---|
adminUser | string | yes | Cluster administration username. The credential itself is never returned. |
createdAt | string | yes | When the cluster was registered, ISO-8601. |
driverKind | DbDriverKind | yes | |
host | string | yes | |
id | string | yes | Pool id. |
port | number | yes | |
region | string or null | yes | Operator-declared region, or null if none was stated. Always PRESENT — null is the value, not an absence. |
slug | string | yes | Stable operator-facing name, unique across the deployment. |
status | DbPoolStatus | yes | Lifecycle state of the cluster. draining keeps existing databases working while refusing to place NEW ones on it. |
updatedAt | string | yes | When the row last changed, ISO-8601. |
DbPoolDtoDataEnvelope
| Property | Type | Required | Description |
|---|
data | DbPoolDto | yes | |
DbPoolStatus
Lifecycle state of the cluster. draining keeps existing databases working while refusing to place NEW ones on it.
Type: one of "active", "draining", "decommissioned"
ExplorerColumnDto
| Property | Type | Required | Description |
|---|
foreignKeyTarget | string | no | Foreign-key target in string form <schema>.<table>.<column>, when the column references one. |
isPrimaryKey | boolean | no | True when the column is part of the primary key. |
name | string | yes | Column name. |
nullable | boolean | yes | Whether the column accepts NULL. |
typeName | string | yes | PostgreSQL type name (e.g. text, int4). |
typeOid | number | yes | PostgreSQL type OID. |
ExplorerColumnsResponseDto
| Property | Type | Required | Description |
|---|
columns | array of ExplorerColumnDto | yes | |
schema | string | yes | Schema the table belongs to. |
table | string | yes | Table or view the columns belong to. |
ExplorerColumnsResponseDtoDataEnvelope
ExplorerMutateDto
| Property | Type | Required | Description |
|---|
params | array of any | no | Positional parameter bindings ($1, $2, …) — see ExplorerQueryDto. |
schema | string | no | Override schema. Defaults to the org database's canonical schemaName. |
sql | string | yes | Single INSERT/UPDATE/DELETE statement. RETURNING is allowed. |
ExplorerQueryDto
| Property | Type | Required | Description |
|---|
params | array of any | no | Positional parameter bindings ($1, $2, …). Values are passed through to pg without string interpolation — driver-side parameterization is the only allowed user-data injection path. |
schema | string | no | Override schema. When omitted, falls back to the org database's canonical schemaName recorded on OrgDatabase.schemaName. |
sql | string | yes | Single SELECT statement. Multi-statement, CTE-with-mutation, DDL and transactional control are rejected at the AST layer. |
ExplorerQueryResponseDto
| Property | Type | Required | Description |
|---|
columns | array of ExplorerColumnDto | yes | |
durationMs | number | yes | Server-side execution time in milliseconds. |
rowCount | number | yes | Number of rows returned. |
rows | array of array of any | yes | Row values, positionally aligned with columns. |
truncated | boolean | yes | True when the result was cut short by the row limit — the caller is NOT seeing every matching row. |
ExplorerQueryResponseDtoDataEnvelope
ExplorerRowsResponseDto
| Property | Type | Required | Description |
|---|
columns | array of ExplorerColumnDto | yes | |
durationMs | number | yes | Server-side execution time in milliseconds. |
rowCount | number | yes | Number of rows returned. |
rows | array of array of any | yes | Row values, positionally aligned with columns. |
schema | string | yes | Schema the rows came from. |
table | string | yes | Table or view the rows came from. |
truncated | boolean | yes | True when the result was cut short by the row limit — the caller is NOT seeing every matching row. |
ExplorerRowsResponseDtoDataEnvelope
ExplorerSchemasResponseDto
| Property | Type | Required | Description |
|---|
schemas | array of string | yes | Schemas exposed by the database. H1 ships one-schema-per-database, so this is a singleton today. |
ExplorerSchemasResponseDtoDataEnvelope
ExplorerTableDto
| Property | Type | Required | Description |
|---|
kind | one of "table", "view" | yes | Relation kind. |
name | string | yes | Relation name. |
ExplorerTablesResponseDto
| Property | Type | Required | Description |
|---|
schema | string | yes | Schema the relations belong to. |
tables | array of ExplorerTableDto | yes | |
ExplorerTablesResponseDtoDataEnvelope
MigrationRunDto
| Property | Type | Required | Description |
|---|
createdAt | string | yes | ISO-8601. |
databaseId | string | yes | The org database the run applied to. |
exitCode | number or null | yes | |
finishedAt | string or null | yes | ISO-8601. |
id | string | yes | Migration run id. |
output | string or null | yes | Captured runner output. |
planJson | object or null | yes | The typed schema-change plan a raw_sql run applied, kept for audit; null for runners that carry no plan. |
runnerKind | MigrationRunnerKind | yes | |
schemaId | string or null | yes | The schema inside that database, when the run was scoped to one. |
startedAt | string or null | yes | ISO-8601. |
status | MigrationStatus | yes | |
updatedAt | string | yes | ISO-8601. |
workflowId | string or null | yes | |
MigrationRunDtoDataArrayEnvelope
MigrationRunnerKind
Type: one of "prisma", "drizzle", "flyway", "raw_sql"
MigrationStatus
Type: one of "pending", "running", "succeeded", "failed"
OrgDatabaseDto
| Property | Type | Required | Description |
|---|
createdAt | string | yes | |
databaseName | string | yes | |
id | string | yes | |
lastMigratedAt | string or null | no | |
orgId | string | yes | |
poolId | string | yes | |
purpose | OrgDatabasePurpose | yes | |
roles | SchemaRoleNamesDto | yes | Authoritative access-role names the pool created for schemaName. Consumers MUST use these when minting a connection; never re-derive them. |
schemaName | string | yes | |
status | OrgDatabaseStatus | yes | |
updatedAt | string | yes | |
OrgDatabaseDtoDataEnvelope
OrgDatabasePurpose
Type: one of "biome", "app_dev", "app_prod", "system"
OrgDatabaseStatus
Type: one of "provisioning", "active", "migrating", "failed", "archived"
SchemaRoleNamesDto
| Property | Type | Required | Description |
|---|
roRoleName | string | yes | Role name for SchemaRoleKind.ReadOnly (suffix "_ro") — SELECT only on the schema. |
rwRoleName | string | yes | Role name for SchemaRoleKind.ReadWrite (suffix "_rw") — full DML on the schema. |