admin module (edit) and the tenant’s
workflowAutomation feature flag (Team plan and above). Codes must match ^[a-z][a-z0-9_]{1,63}$.
Catalog
GET /contract-config/catalog · requires contract_view (view)
Returns the tenant’s configured contract types and lifecycle templates — this is what backs the
type / typeCode and lifecycleTemplateId / lifecycleStageCode fields on
Contracts.
Contract types
| Endpoint | Body |
|---|---|
POST /contract-config/types | { code, name, category?, description?, enabled?, order?, fieldSchema?, defaultRules?, defaultLifecycleTemplateId? } |
PATCH /contract-config/types/:id | Same fields, all optional |
Lifecycle stages
| Endpoint | Body |
|---|---|
POST /contract-config/lifecycle/templates/:templateId/stages | { code, name, category?, order?, isTerminal?, locksCoreFields?, completionRules?, allowedRoleCodes? } |
PATCH /contract-config/lifecycle/stages/:id | Same fields, all optional |
locksCoreFields is what makes a stage lock core contract fields — see
Workflow.
Lifecycle transitions
| Endpoint | Body |
|---|---|
POST /contract-config/lifecycle/templates/:templateId/transitions | { code, name, fromStageCode, toStageCode, requiredControl?, conditions?, effects?, order?, enabled? } |
PATCH /contract-config/lifecycle/transitions/:id | Same fields, all optional |
requiredControl ties a transition to a workflow control
level (e.g. approve, sign) that the acting role must hold.