Orders
Get an order
Read one order as the venue has it now.
/public/v1/orders/{orderId}Poll it to follow an order, or rely on the webhook, which sends this same body whenever it changes. An order is readable by any key of the venue it was placed at, and by a headquarter's key at any of its branches. An order nobody placed through the API, one at another venue and one that does not exist all answer 404.
status is worked out from the order's lines and its bill on every read; what each value means is under the fields. paymentStatus follows what is paid at the venue; the customer pays the totals.remaining amount there.
A dine-in order that joined a bill that was already open comes back as the whole bill, with the lines other people ordered on it.
Parameters
orderIdstring · uuidPath parameterrequiredThe order's id, from the answer to placing it.
Accept-LanguagestringHeaderThe language of userMessage in an error: tr (the default), en, de, fr, it, es, ar or ru. The first language in the header decides, without its region (en-US reads as en) and without weighing q values; a language Cibusy does not offer is answered in Turkish. It does not choose the language of a menu: that is lang on the menu call.
Responses
The order.
The X-Api-Key header is missing (PUBLIC_API_KEY_MISSING), or the key is invalid or has been revoked (PUBLIC_API_KEY_INVALID).
PUBLIC_API_SCOPE_MISSING: the key was not made with the "Can send orders" permission.
PUBLIC_API_ORDER_NOT_FOUND.
The key's budget of about 120 requests a minute is spent; wait Retry-After seconds.
Retry-AfterSeconds to wait. The next one-minute window opens within it.
The data of a successful answer
An order placed through the API, as the venue has it right now. The same body GET /orders/{orderId} returns and the webhook's order.updated event carries. Money is in Turkish lira, VAT included, rounded to two decimals.
idstring · uuidThe order's id. Use it with GET /orders/{orderId}.
numberintegerThe number the venue calls the order by, counted from 1 within the venue. Show it to the customer; it is the one printed on the kitchen ticket. Unique within one venue only.
venueIdstring · uuidThe venue the order was placed at.
typestringHow the order reaches the diner.
DineIn- At a table: the round is added to the table's open bill, or opens one.
Takeaway- Takeaway: the customer collects it at the venue.
Delivery- Delivery: the venue brings it to the customer.
statusstringWhere the order has got to, worked out from the order's lines and its bill on every read.
Received- The venue has the order and the kitchen has not started.
Preparing- The kitchen has started on at least one line.
Ready- Every line is ready or already served.
Served- Every line on it is served.
OnTheWay- A delivery has left the venue.
Completed- The venue closed the bill.
Cancelled- The order was voided, or every line on it was struck off.
paymentStatusstringHow much of the bill has been paid at the venue.
Unpaid- Nothing has been paid at the venue.
PartiallyPaid- Part of the bill has been paid.
Paid- The bill is settled.
tableobjectnullableThe table, for a dine-in order. null for a takeaway or a delivery.
Fields of Order table
idstring · uuidThe table's id, as GET /venues/{venueId}/tables lists it.
namestringThe table's name.
customerobjectnullableWho the order is for, for a takeaway or a delivery. null for a dine-in order, and for an order nobody took the customer's details for.
Fields of Customer details
namestringnullableThe customer's name.
phonestringnullableThe customer's phone number, in international form.
addressstringnullableWhere a delivery goes.
paymentMethodstringnullableHow the customer said they would pay, if they said. null otherwise.
Cash- Cash.
Card- Card.
MealCard- Meal card.
notestringnullableThe note for the kitchen the order was placed with. null when there was none.
linesobject[]Every line on the order, including lines other people put on a table's bill and lines since cancelled. For a dine-in order that joined a bill that was already open, the lines of the whole bill are here: the addedLineIds of the placement answer say which of them that call wrote.
Fields of Order line
idstring · uuidThe line's id. Stays the same for as long as the line is on the order.
productIdstring · uuidThe product, as the menu lists it.
productNamestringThe product's name in the venue's own words.
portionIdstring · uuidnullableThe portion ordered, as the menu lists it.
portionNamestringnullableThe portion's name as it read when the order was placed.
quantityintegerHow many of it.
unitPricenumberThe price of one unit, extras included, as it was when the order was placed.
totalnumberWhat the line comes to: unitPrice × quantity, before campaigns. 0 for a cancelled line and for one the venue gave away.
statusstringWhere the line has got to in the kitchen.
Pending- Waiting in the kitchen.
Preparing- Being prepared.
Ready- Ready.
Served- Served.
Cancelled- Cancelled. The lines of a cancelled order read this way too.
extrasobject[]The extras on each unit.
Fields of Line extra
idstring · uuidThe extra, as the menu lists it.
namestringThe extra's name.
pricenumberWhat it cost per unit when the order was placed.
removedIngredientsobject[]The ingredients left out of each unit.
Fields of Removed ingredient
idstring · uuidThe ingredient, as the menu lists it.
namestringThe ingredient's name.
notestringnullableThe note for the kitchen about this line. null when there was none.
orderedAtstring · date-timeWhen the line was put on the order, in UTC.
totalsobjectWhat the order comes to, and how much of it is paid.
Fields of Totals
subtotalnumberThe lines at menu price with their extras, before campaigns. Cancelled lines are not counted.
discountnumberWhat the venue's campaigns and discounts take off.
serviceFeenumberThe venue's service fee, charged on the food after campaigns. 0 when the venue charges none.
totalnumberWhat the order comes to.
paidnumberHow much of it has been paid at the venue.
remainingnumberHow much is still owed. 0 once the bill is paid.
currencystringThe currency of every amount, an ISO 4217 code. Always TRY.
createdAtstring · date-timeWhen the order was placed, in UTC.
closedAtstring · date-timenullableWhen the venue closed the order, in UTC. null while it is open, and for a cancelled order.