Decision REST API
Decisions do not currently have a standalone execution endpoint. They are surfaced indirectly through command execution and directly through metadata endpoints.
Decision Metadata
Section titled “Decision Metadata”| Method | Route |
|---|---|
GET | /api/dereg/decisions |
GET | /api/dereg/decisions/{name} |
GET | /api/dereg/decisions/{name}/emits |
These endpoints return Arrow IPC from:
meta_decisionsmeta_decision_emits
Decision Execution Model
Section titled “Decision Execution Model”Decisions are executed indirectly when a command is posted to:
POST /api/aggregates/{agg}/execute/{command}The server:
- Resolves the command to a registered decision
- Confirms that decision belongs to
{agg} - Executes the resulting
EXECUTEstatement
Creating Decisions
Section titled “Creating Decisions”Decisions can be registered through the optional schema API:
| Method | Route |
|---|---|
POST | /api/deql/create |
Payload example:
{ "deql": "CREATE DECISION Promote FOR Employee ON COMMAND PromoteEmployee EMIT AS SELECT EVENT EmployeePromoted (new_grade := :new_grade);"}- There is no standalone
POST /api/decisions/{name}/executeroute. - Inspect workflows are exposed through aggregate inspect table endpoints, not direct decision HTTP endpoints.