GET
View an order
Company space For: Cashier and seller, Manager · Permission: orders.retrieve Part of Take and approve orders.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

order
string
required

Identifier of the order.

Query Parameters

response
enum<string>
default:resource

Response mode. Default resource; none answers 204 No Content.

Available options:
resource
fields
string

Comma-separated JSON keys of the root resource (id is always rendered). Available: id, number, customer_id, customer_name, currency_code, items_net_total, items_tax_total, items_gross_total, discount, charge, order_tax_total, total, discount_applications, status, payment_status, seller_id, cash_register_id, cashier_id, confirmed_cashier_shift_id, confirmed_cash_register_instance_id, completed_at, cancelled_at, rejected_at, approved_by, rejected_by, approved_at, created_at, updated_at, is_credit, credit_detail, rendered_html.

include
string

Comma-separated include paths, each optionally followed by its fields in parentheses: units(id,sku),units.uomUnit(id,name). Max depth 6, max 40 paths. Available: items, items.taxLines, items.allocations, taxLines, payments, seller, cashRegister, cashier.

Response

200 - application/json

Resource.

id

Identifier of the order (27-character KSUID string).

number
integer

Sequential order number inside the company, allocated by the server at creation (last number plus one).

customer_id

Identifier of the customer, or null for an anonymous sale.

customer_name

Customer name kept on the order: copied from the stored customer when customer_id is set, otherwise the free text sent.

currency_code

ISO 4217 currency code of the order, copied from the company settings.

items_net_total
number

Sum of the lines before tax, after discounts, in major units of currency_code (stored in minor units and divided by 10 to the power of the currency exponent).

items_tax_total
number

Sum of the taxes of the lines, in major units of currency_code.

items_gross_total
number

items_net_total plus items_tax_total, in major units of currency_code.

discount
number

Total discount applied to the order, in major units of currency_code.

charge
number

Extra charge added to the order, in major units of currency_code. The server currently always computes 0.

order_tax_total
number

Taxes applied on the whole order rather than on lines, in major units of currency_code.

total
number

Amount to pay: items_gross_total plus order_tax_total plus charge, in major units of currency_code.

discount_applications
any[] | null

Discounts applied to the order, one entry per campaign, code or manual discount, with amounts in major units and the allocation to each item. On create and update it is the computed breakdown (ttc_saving filled); on later reads it is the stored record (ttc_saving is null). Null when none is available.

status

Life-cycle status: pending (waiting for payment), awaiting_approval, approved, unapproved, updating (opened for changes), rejected, completed (cashed) or cancelled. Set by the server.

payment_status

unpaid, partially_paid or paid. Set by the server at confirmation from the payments received against the total; unpaid before.

seller_id

Identifier of the seller record that created the order.

cash_register_id

Identifier of the register of the order: at creation, the seller's register, or for a direct seller the register sent in the request; once confirmed, the cashier's register. Null for a direct seller who sent no register, until confirmation.

cashier_id

Identifier of the cashier record that confirmed the sale. Null until confirmation.

confirmed_cashier_shift_id

Identifier of the register session in which the sale was confirmed. Null until confirmation.

confirmed_cash_register_instance_id

Identifier of the cash register computer used by the register session when the sale was confirmed. Null until confirmation.

completed_at

Time of confirmation, ISO 8601. Null until confirmed.

cancelled_at

Time of cancellation, ISO 8601. Null unless cancelled.

rejected_at

Time the cashier rejected the order, ISO 8601. Cleared when the order returns to pending.

approved_by

Identifier of the agent account or user profile who approved the order. Null when not approved.

rejected_by

Reserved: the reject action does not fill it, so it is normally null.

approved_at

Time of approval, ISO 8601. Null when not approved or after the approval was withdrawn.

created_at

Date and time the record was created (ISO 8601, UTC).

updated_at

Date and time the record was last changed (ISO 8601, UTC).

tax_lines
array

Taxes applied at order level (not on a line). Only present when requested with include.

items
array

Lines of the order. Only present when requested with include.

payments
array

Payments recorded when the sale was confirmed. Empty until then. Only present when requested with include.

seller
object

Summary of the seller record. Only present when requested with include.

cash_register
object | null

Summary of the register. Only present when requested with include.

cashier
object | null

Summary of the cashier who confirmed the sale. Only present when requested with include.

is_credit
boolean

True for a credit sale, where the customer may leave part or all of the total unpaid and owes it as a debt. A credit sale needs a customer.

credit_detail
object | null

Credit sale detail: id, total_amount, remaining_amount, paid_amount (major units), due_date and ask_approval. Null for a cash sale or when the detail is missing. total_amount is set when the order is saved; remaining_amount stays 0 until confirmation, which sets it to the unpaid part.

rendered_html

Invoice rendered at confirmation as HTML. Present only in the response of the confirm action.