| Endpoint | Body | Requires |
|---|---|---|
GET /dynamic-fields | — | custom_fields (view) |
POST /dynamic-fields/commands | { type, payload } | admin (edit), plus the tenant’s customFields feature flag |
GET /dynamic-fields returns the tenant’s custom field definitions (each with its type, visible
roles, and editable roles — see Contract Workspace).
POST /dynamic-fields/commands is a single command endpoint rather than one route per action.
type is one of:
CreateField | RenameField | UpdateFieldType | UpdateFieldOptions | DuplicateField |
MoveField | ArchiveFieldShape depends on
type — see @alforse/shared’s DynamicFieldBackendCommand for the
discriminated union if you’re generating requests programmatically.