Send or cancel a purchase order
Admin and branch manager. Moves an order to SENT or CANCELLED and writes an audit entry. A status that is neither, or an order already received or cancelled, is refused with 400.
PUT
/api/v1/purchase-orders/{purchaseOrderId}/statusAuthorization
AuthorizationBearer token (JWT) · headerrequiredJWT from POST /api/v1/auth/login sent as Authorization Bearer.
Path parameters
purchaseOrderIdstringrequiredThe purchase order being moved.
Request body
requiredapplication/jsonstatusstringrequiredResponses
200
The new status
idstringrequiredstatusstringrequired400
status is neither SENT nor CANCELLED, the PO is already received, or it is already cancelled
detailstringrequired401
Not authenticated
detailstringrequired403
Access forbidden for this role
detailstringrequired404
PO not found
detailstringrequired