π Update Order
Endpoint: POST /api/order/update
Description: Blend can update the order status (ACCEPTED, CANCELED, etc.)
Authorization: Required (Authorization: Bearer \<token>
)
π¦ Example Request
{
"order_id": "44456",
"branch_id": "11",
"brand_id": "5000",
"status": "ACCEPTED" // ACCEPTED, PREPARING, CANCELED, REJECTED, TIME_OUT
}
π Field Descriptions
Field | Type | Description |
---|---|---|
order_id | string | The Blend-generated ID of the order to update |
branch_id | string | The branch responsible for the order |
brand_id | string | ID of the brand placing the order |
status | string | New order status: ACCEPTED , PREPARING , CANCELED , REJECTED , TIME_OUT |
π§ Behavior
- Called by Blend when a change in order status needs to be reflected in the POS system.
- The POS should:
- Update internal records with the new status.
- Trigger any internal flows (e.g., printing, refunding, order cancellation).
π§ Example Use Cases
- Admin cancels the order via Blend β status becomes CANCELED.
- Kitchen confirms theyβre preparing the order β Blend pushes PREPARING.
- `Timeout occurred on the delivery app β Blend marks order as TIME_OUT.
β Notes
- The order_id matches the one received in the initial Create Order request.
- If the order does not exist or has already been finalized, the POS may ignore or log it.
- This API allows Blend to remain the single source of truth for order state.
- Return appropriate HTTP codes:
- 200 OK if updated
- 404 if order not found
- 401 if token missing or invalid
Updated about 2 months ago