Skip to content

Fields API

Field management is app-scoped under /api/apps/{app}/tables/{table}/fields.

GET /api/apps/{app}/tables/{table}/fields

Returns {"fields": [...]}.

POST /api/apps/{app}/tables/{table}/fields
Content-Type: application/json
{
"name": "title",
"type": "text",
"required": true
}

The field is added to the table immediately — no migration needed. The response includes the new field plus the table’s full field list (HTTP 201).

POST /api/apps/{app}/tables/{table}/fields
Content-Type: application/json
{
"name": "budget",
"type": "decimal",
"required": false,
"config": {
"precision": 10,
"scale": 2
}
}

Enum (and multi-select) options live under config.options. Each option may be a plain string or an object with value, label, and color:

POST /api/apps/{app}/tables/{table}/fields
Content-Type: application/json
{
"name": "status",
"type": "enum",
"config": {
"options": ["draft", "active", "completed", "cancelled"]
}
}
POST /api/apps/{app}/tables/{table}/fields
Content-Type: application/json
{
"name": "assigned_to",
"type": "reference",
"config": {
"target_table": "users"
}
}
POST /api/apps/{app}/tables/{table}/fields
Content-Type: application/json
{
"name": "reason",
"type": "text",
"required": false,
"config": {
"conditions": [
{
"when_field": "type",
"operator": "eq",
"value": "bug",
"action": "require"
}
]
}
}

The conditions array makes the field conditionally required when type equals bug. Supported operators: eq, neq, in, not_in, is_empty, is_not_empty, gt, lt, gte, lte, contains, not_contains. Supported actions: show, hide, require.

PUT /api/apps/{app}/tables/{table}/fields/{field}
Content-Type: application/json
{
"display_name": "Project Title",
"required": true
}
DELETE /api/apps/{app}/tables/{table}/fields/{field}

See Field Types for the full list of supported types and their configurations.