API: Work Orders + Operations + Receipts
Purpose: core orchestration entities and execution evidence streams.Work Orders
GET /api/work-ordersPOST /api/work-ordersGET /api/work-orders/:idPATCH /api/work-orders/:idPOST /api/work-orders/:id/start(canonical manager-engine start)
Create work order example
Work order start example
PATCH /api/work-orders/:id blocks non-manager attempts to set state=active with:
- status
400 - code
MANAGER_CONTROLLED_STATE
Operations
GET /api/operationsGET /api/operations/:idPATCH /api/operations/:idGET /api/operations/:id/stories
POST /api/operations is removed for manual use and returns:
- status
410 - code
MANAGER_CONTROLLED_OPERATION_GRAPH
PATCH /api/operations/:id rejects non-manager status transitions with:
- status
403 - code
MANAGER_CONTROLLED_OPERATION_STATUS
Approvals + Activities
- approvals:
/api/approvals,/api/approvals/:id,/api/approvals/batch - activity feed:
/api/activities
Receipts
GET /api/receiptsPOST /api/receiptsPATCH /api/receipts/:id/appendPATCH /api/receipts/:id/finalizeGET /api/stream/receipts/:id(see streaming page)
Error patterns
404for missing work order/operation/receipt ids400for invalid transition or manager-controlled work-order activation403for manager-controlled operation status transitions410for manager-controlled operation graph creation500repository/internal failure