Reject Order

Reports that the POS will not fulfil the order.

failure_code is the outcome the ordering channel is told, and is what the channel
maps onto its own reject vocabulary — always send the code that describes what
actually happened. info is the one line a channel shows a human.

A request that omits failure_code is still accepted, but only so that callers not
yet on this contract keep working: their reason and info are normalised onto a
canonical code on a best-effort basis. That tolerance is deprecated — send the code.

A channel fails an order over to another acceptance mechanism unless
store_explicitly_declined_order is true, so send that flag only for a fulfillable
order a person at the store deliberately turned down. Every automatic failure —
an offline POS, a timeout, a menu or payload problem — leaves it false.

Name the offending items in item_metadata whenever the code is about specific
items. The ids are resolved back to the ordering channel's own item ids, so a
channel can tell the customer which item was the problem.

Rejecting an order is idempotent, and cannot contradict an accepted one: a repeat
call refreshes the recorded detail, and an order already accepted or cancelled
answers 409.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…

Used by the Point-of-Sale to reject an order once it has been processed.

The order should be rejected with an appropriate reason.

Path Params
string
required

order_id

Body Params
string
enum
required

Canonical reason the order was not fulfilled. Relayed to the ordering channel.

string

Top line message relayed to the ordering channel. Keep it fit for a person to read, and put diagnostic detail in pos_raw_response.

boolean

True only when a human deliberately declined a fulfillable order. Tells the channel to suppress its failover. Defaults to false.

item_metadata
object

The items the POS could not accept, named by its own ids.

string

The POS's own response body, kept verbatim for troubleshooting and never relayed to a channel. Trimmed to 8000 characters.

string

Short label for the rejection, for troubleshooting. Relayed to the channel only when info is absent.

Responses

400

bad request when the failure code or an item error type is not a canonical one

401

not authorized

404

not found when no order carries the guid

409

conflict when the order's outcome is already settled

Language
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json