Orders tools
All tool areas. Each tool acts within your access.
Orders
cancel_order
Cancel a guest's order at any time, for a recorded reason (a listed one, staff's own words in note, or both): its booking is canceled, or its hold released if it isn't paid yet, so the seats go back on sale; its reminder won't go out, and the guest is emailed (the cancellationEmail setting). For a session that has started or ended the preview warns, names the guests already checked in, doesn't put the seats back on sale, and leaves the guest's email off unless notifyGuest is true (notifyGuest false leaves it off for a future one too). refund is null to refund nothing (the default under a no-refund policy), "refundable" for everything staff can refund (fees sold as non-refundable, such as the service charge, are kept), or an amount in minor units; refunding needs refunds:create. A payment that comes through after an unpaid order is canceled is refunded in full. Can't be undone. Find the order with list_orders. Returns a preview to confirm.
Changes · Members of an organization · Needs bookings:write
Input
orderIdThe order's id, from list_bookings or list_orders
reasonguest_request: the guest asked; session_canceled: the session was called off; duplicate: a second order for the same booking; other (or leave it out): staff's own reason, in note
noteStaff's own reason, or more about the one chosen, in a sentence, for the activity log. Enough on its own (the reason is then other). Never shown to the guest
refundRefund with the cancellation:
refundablefor everything staff can refund, an amount in minor units, or null for nonenotifyGuestWhether the guest is emailed about the cancellation. Left out: yes for a session still to come, no for one that has started or ended (the preview says which)
Output
orderorder.idorder.codeThe booking code guests quote
order.statusorder.cancelReasonorder.cancelNoteStaff's own words. Null without orders:amounts
order.createdAtorder.confirmedAtorder.canceledAtorder.customerorder.customer.idorder.customer.nameThe first name only, without customers:contact
order.customer.emailNull without customers:contact
order.customer.phoneNull without customers:contact, or when there's none
order.customer.contactHiddenTrue when email and phone are hidden from you (you lack customers:contact here). False with a null email or phone means the guest gave none
order.productorder.product.idorder.product.nameorder.locationorder.location.idorder.location.nameorder.location.timeZoneorder.sessionorder.session.idorder.session.startsAtorder.session.whenIn the location's time zone
order.partySizeorder.currencyorder.totalNull without orders:amounts
order.paidNull without orders:amounts
order.refundedRefunded or on its way back. Null without orders:amounts
order.keptFees sold as non-refundable (the service charge) and their tax, kept on staff refunds, as far as the money is still held: 0 once everything paid has come back, refunded or as a credit in its place (a session the operator moved or called off), and none on an order canceled before it was booked. Null without orders:amounts
order.refundableWhat staff can still refund: paid, less refunds, less a credit given in place of a refund (a session moved or called off), less what's kept. Null without orders:amounts
order.refundsorder.refunds[]order.refunds[].idorder.refunds[].amountNull without orders:amounts
order.refunds[].statuspending (on its way), succeeded, failed, or reversed: given as a credit or gift certificate that was voided unused since, so it was taken back and isn't counted as refunded
order.refunds[].reasonorder.refunds[].noteStaff's own words. Null without orders:amounts
order.refunds[].failureReasonorder.refunds[].createdAtorder.refunds[].tenderWhat the refunded payment was made with: card (back to the guest's card), gift_certificate or credit (back to it), or an offline tender (card_terminal, cash, debit, e_transfer, cheque), which staff gave back that way at the desk; a voucher's part is given back as a credit (creditId), and a guest's own refund under the booking's refundDestination as a credit (creditId) or gift certificate (giftCertificateId) instead of back to the card or the desk
order.refunds[].creditIdThe credit this refund became instead of going back where it was paid: a third party's voucher can't be handed back, so its part is a credit (voucher_refunded); a guest's own cancellation or change under refundDestination credit gives one (guest_change). The same credit the booking's credits list shows. Null for every other refund. Always present
order.refunds[].giftCertificateIdThe gift certificate (kind refund) this refund became instead of going back where it was paid: a guest's own cancellation or change under refundDestination gift_certificate. Null for every other refund. Always present
order.refunds[].issuerWho issued the voucher the refunded payment was (such as Costco); null for any other tender, and without orders:amounts. Always present
order.bookingIdNull until it's booked. Always present
order.bookerWho made it: a guest at checkout, or staff. Always present
order.balanceDueWhat's still owing. Above 0 on a staff booking with payment to come, or seats added since: confirmed isn't paid. Null without orders:amounts. Always present
order.overPaidWhat's been paid beyond the total: seats removed, which refunds nothing by itself. Null without orders:amounts. Always present
order.paymentStatusunpaid, partly_paid, paid, over_paid, refunded (all but any kept fee has gone back), or nothing_due, from what's actually been paid. A partial refund stays paid. Null without orders:amounts. Always present
order.staffNoteStaff's own note, never shown to the guest. Null without orders:amounts, or when there's none. Always present
refundsrefunds[]refunds[].idrefunds[].amountNull without orders:amounts
refunds[].statuspending (on its way), succeeded, failed, or reversed: given as a credit or gift certificate that was voided unused since, so it was taken back and isn't counted as refunded
refunds[].reasonrefunds[].noteStaff's own words. Null without orders:amounts
refunds[].failureReasonrefunds[].createdAtrefunds[].tenderWhat the refunded payment was made with: card (back to the guest's card), gift_certificate or credit (back to it), or an offline tender (card_terminal, cash, debit, e_transfer, cheque), which staff gave back that way at the desk; a voucher's part is given back as a credit (creditId), and a guest's own refund under the booking's refundDestination as a credit (creditId) or gift certificate (giftCertificateId) instead of back to the card or the desk
refunds[].creditIdThe credit this refund became instead of going back where it was paid: a third party's voucher can't be handed back, so its part is a credit (voucher_refunded); a guest's own cancellation or change under refundDestination credit gives one (guest_change). The same credit the booking's credits list shows. Null for every other refund. Always present
refunds[].giftCertificateIdThe gift certificate (kind refund) this refund became instead of going back where it was paid: a guest's own cancellation or change under refundDestination gift_certificate. Null for every other refund. Always present
refunds[].issuerWho issued the voucher the refunded payment was (such as Costco); null for any other tender, and without orders:amounts. Always present
list_orders
Find orders (a guest's booking and payment), newest first: by booking code, the customer's email, or session, or filtered by status. Each shows the guest, the session, party size, the total, what's paid, refunded, kept (fees sold as non-refundable), and still refundable, with its refunds. Only orders your grants cover. Without customers:contact the guest is a first name, with no email or phone (and finding by email is refused); without orders:amounts the amounts are null. Page back with before. Use it before cancel_order or refund_order. For a booking's page and its seats, use list_bookings and get_booking; this one is for money: refunds and what's still refundable.
Reads · Members of an organization · Needs bookings:read
Input
codeThe booking code, e.g. EE2EQN
emailThe customer's email; needs customers:contact
sessionIdThe session's id, from list_sessions
statusOnly orders in this state
limitThe most results to return (default 25)
beforeAn order id; returns orders older than it
Output
ordersorders[]orders[].idorders[].codeThe booking code guests quote
orders[].statusorders[].cancelReasonorders[].cancelNoteStaff's own words. Null without orders:amounts
orders[].createdAtorders[].confirmedAtorders[].canceledAtorders[].customerorders[].customer.idorders[].customer.nameThe first name only, without customers:contact
orders[].customer.emailNull without customers:contact
orders[].customer.phoneNull without customers:contact, or when there's none
orders[].customer.contactHiddenTrue when email and phone are hidden from you (you lack customers:contact here). False with a null email or phone means the guest gave none
orders[].productorders[].product.idorders[].product.nameorders[].locationorders[].location.idorders[].location.nameorders[].location.timeZoneorders[].sessionorders[].session.idorders[].session.startsAtorders[].session.whenIn the location's time zone
orders[].partySizeorders[].currencyorders[].totalNull without orders:amounts
orders[].paidNull without orders:amounts
orders[].refundedRefunded or on its way back. Null without orders:amounts
orders[].keptFees sold as non-refundable (the service charge) and their tax, kept on staff refunds, as far as the money is still held: 0 once everything paid has come back, refunded or as a credit in its place (a session the operator moved or called off), and none on an order canceled before it was booked. Null without orders:amounts
orders[].refundableWhat staff can still refund: paid, less refunds, less a credit given in place of a refund (a session moved or called off), less what's kept. Null without orders:amounts
orders[].refundsorders[].refunds[]orders[].refunds[].idorders[].refunds[].amountNull without orders:amounts
orders[].refunds[].statuspending (on its way), succeeded, failed, or reversed: given as a credit or gift certificate that was voided unused since, so it was taken back and isn't counted as refunded
orders[].refunds[].reasonorders[].refunds[].noteStaff's own words. Null without orders:amounts
orders[].refunds[].failureReasonorders[].refunds[].createdAtorders[].refunds[].tenderWhat the refunded payment was made with: card (back to the guest's card), gift_certificate or credit (back to it), or an offline tender (card_terminal, cash, debit, e_transfer, cheque), which staff gave back that way at the desk; a voucher's part is given back as a credit (creditId), and a guest's own refund under the booking's refundDestination as a credit (creditId) or gift certificate (giftCertificateId) instead of back to the card or the desk
orders[].refunds[].creditIdThe credit this refund became instead of going back where it was paid: a third party's voucher can't be handed back, so its part is a credit (voucher_refunded); a guest's own cancellation or change under refundDestination credit gives one (guest_change). The same credit the booking's credits list shows. Null for every other refund. Always present
orders[].refunds[].giftCertificateIdThe gift certificate (kind refund) this refund became instead of going back where it was paid: a guest's own cancellation or change under refundDestination gift_certificate. Null for every other refund. Always present
orders[].refunds[].issuerWho issued the voucher the refunded payment was (such as Costco); null for any other tender, and without orders:amounts. Always present
orders[].bookingIdNull until it's booked. Always present
orders[].bookerWho made it: a guest at checkout, or staff. Always present
orders[].balanceDueWhat's still owing. Above 0 on a staff booking with payment to come, or seats added since: confirmed isn't paid. Null without orders:amounts. Always present
orders[].overPaidWhat's been paid beyond the total: seats removed, which refunds nothing by itself. Null without orders:amounts. Always present
orders[].paymentStatusunpaid, partly_paid, paid, over_paid, refunded (all but any kept fee has gone back), or nothing_due, from what's actually been paid. A partial refund stays paid. Null without orders:amounts. Always present
orders[].staffNoteStaff's own note, never shown to the guest. Null without orders:amounts, or when there's none. Always present
nextBefore
refund_gift_certificate_purchase
Refund a gift certificate purchase to the buyer's card, for a recorded reason: first voids what's left on the certificate (so it can't be spent and refunded both), then refunds amount in minor units, or leave it out for everything it can: what was paid and isn't back yet, up to what the certificate hasn't paid for. What it already paid on bookings stays paid. Managers and front desk are capped per order by the refundCaps setting, as for refund_order. Needs orders:amounts as well as refunds:create where it was sold. Applying a preview of everything is refused if that amount has changed since. Can't be undone. Returns a preview to confirm.
Changes · Members of an organization · Needs refunds:create
Input
orderIdThe order's id, from list_bookings or list_orders
amountMinor units (cents) in the location's currency
reasonguest_request: the buyer asked; duplicate: bought twice; goodwill; other (or leave it out): staff's own reason, in note
noteStaff's own reason, or more about the one chosen, in a sentence, for the activity log. Enough on its own (the reason is then other). Never shown to the guest
Output
orderIdcodeThe purchase's order code
giftCertificategiftCertificate.idgiftCertificate.codeMasked: •••• and its last 4
giftCertificate.statusgiftCertificate.amountMinor units (cents) in the location's currency
giftCertificate.balanceMinor units (cents) in the location's currency
voidedWhat was left on the certificate, voided by this refund
refundsrefunds[]refunds[].idrefunds[].amountNull without orders:amounts
refunds[].statuspending (on its way), succeeded, failed, or reversed: given as a credit or gift certificate that was voided unused since, so it was taken back and isn't counted as refunded
refunds[].reasonrefunds[].noteStaff's own words. Null without orders:amounts
refunds[].failureReasonrefunds[].createdAtrefunds[].tenderWhat the refunded payment was made with: card (back to the guest's card), gift_certificate or credit (back to it), or an offline tender (card_terminal, cash, debit, e_transfer, cheque), which staff gave back that way at the desk; a voucher's part is given back as a credit (creditId), and a guest's own refund under the booking's refundDestination as a credit (creditId) or gift certificate (giftCertificateId) instead of back to the card or the desk
refunds[].creditIdThe credit this refund became instead of going back where it was paid: a third party's voucher can't be handed back, so its part is a credit (voucher_refunded); a guest's own cancellation or change under refundDestination credit gives one (guest_change). The same credit the booking's credits list shows. Null for every other refund. Always present
refunds[].giftCertificateIdThe gift certificate (kind refund) this refund became instead of going back where it was paid: a guest's own cancellation or change under refundDestination gift_certificate. Null for every other refund. Always present
refunds[].issuerWho issued the voucher the refunded payment was (such as Costco); null for any other tender, and without orders:amounts. Always present
refund_order
Refund a guest's order, in full or in part, for a recorded reason, without canceling it: a confirmed booking stays confirmed, its seats stay taken, and its reminder still goes out, even after a full refund (to cancel too, use cancel_order). amount in minor units, or leave it out for everything staff can refund: what was paid, less what's already refunded, less fees sold as non-refundable (the service charge), which an order canceled before it was booked doesn't keep (to retry Lokl's refund of it after a failed one). Applying a preview of everything is refused if that amount has changed since. A refund of the whole order previews line by line, with what's kept. Managers and front desk are capped per order by the refundCaps setting (what they've already refunded on it counts), and it takes orders:amounts as well as refunds:create. The refund goes back to the card through the payment provider, usually within a minute; list_orders shows its status, the guest is emailed when it comes back (the refundEmail setting), and staff who can refund are alerted if it fails. Can't be undone. Returns a preview to confirm.
Changes · Members of an organization · Needs refunds:create
Input
orderIdThe order's id, from list_bookings or list_orders
amountMinor units (cents) in the location's currency
reasonguest_request: the guest asked; session_canceled: the session was called off; service_issue: something went wrong on the night; duplicate: charged twice; goodwill: a gesture; other (or leave it out): staff's own reason, in note
noteStaff's own reason, or more about the one chosen, in a sentence, for the activity log. Enough on its own (the reason is then other). Never shown to the guest
Output
orderorder.idorder.codeThe booking code guests quote
order.statusorder.cancelReasonorder.cancelNoteStaff's own words. Null without orders:amounts
order.createdAtorder.confirmedAtorder.canceledAtorder.customerorder.customer.idorder.customer.nameThe first name only, without customers:contact
order.customer.emailNull without customers:contact
order.customer.phoneNull without customers:contact, or when there's none
order.customer.contactHiddenTrue when email and phone are hidden from you (you lack customers:contact here). False with a null email or phone means the guest gave none
order.productorder.product.idorder.product.nameorder.locationorder.location.idorder.location.nameorder.location.timeZoneorder.sessionorder.session.idorder.session.startsAtorder.session.whenIn the location's time zone
order.partySizeorder.currencyorder.totalNull without orders:amounts
order.paidNull without orders:amounts
order.refundedRefunded or on its way back. Null without orders:amounts
order.keptFees sold as non-refundable (the service charge) and their tax, kept on staff refunds, as far as the money is still held: 0 once everything paid has come back, refunded or as a credit in its place (a session the operator moved or called off), and none on an order canceled before it was booked. Null without orders:amounts
order.refundableWhat staff can still refund: paid, less refunds, less a credit given in place of a refund (a session moved or called off), less what's kept. Null without orders:amounts
order.refundsorder.refunds[]order.refunds[].idorder.refunds[].amountNull without orders:amounts
order.refunds[].statuspending (on its way), succeeded, failed, or reversed: given as a credit or gift certificate that was voided unused since, so it was taken back and isn't counted as refunded
order.refunds[].reasonorder.refunds[].noteStaff's own words. Null without orders:amounts
order.refunds[].failureReasonorder.refunds[].createdAtorder.refunds[].tenderWhat the refunded payment was made with: card (back to the guest's card), gift_certificate or credit (back to it), or an offline tender (card_terminal, cash, debit, e_transfer, cheque), which staff gave back that way at the desk; a voucher's part is given back as a credit (creditId), and a guest's own refund under the booking's refundDestination as a credit (creditId) or gift certificate (giftCertificateId) instead of back to the card or the desk
order.refunds[].creditIdThe credit this refund became instead of going back where it was paid: a third party's voucher can't be handed back, so its part is a credit (voucher_refunded); a guest's own cancellation or change under refundDestination credit gives one (guest_change). The same credit the booking's credits list shows. Null for every other refund. Always present
order.refunds[].giftCertificateIdThe gift certificate (kind refund) this refund became instead of going back where it was paid: a guest's own cancellation or change under refundDestination gift_certificate. Null for every other refund. Always present
order.refunds[].issuerWho issued the voucher the refunded payment was (such as Costco); null for any other tender, and without orders:amounts. Always present
order.bookingIdNull until it's booked. Always present
order.bookerWho made it: a guest at checkout, or staff. Always present
order.balanceDueWhat's still owing. Above 0 on a staff booking with payment to come, or seats added since: confirmed isn't paid. Null without orders:amounts. Always present
order.overPaidWhat's been paid beyond the total: seats removed, which refunds nothing by itself. Null without orders:amounts. Always present
order.paymentStatusunpaid, partly_paid, paid, over_paid, refunded (all but any kept fee has gone back), or nothing_due, from what's actually been paid. A partial refund stays paid. Null without orders:amounts. Always present
order.staffNoteStaff's own note, never shown to the guest. Null without orders:amounts, or when there's none. Always present
refundsrefunds[]refunds[].idrefunds[].amountNull without orders:amounts
refunds[].statuspending (on its way), succeeded, failed, or reversed: given as a credit or gift certificate that was voided unused since, so it was taken back and isn't counted as refunded
refunds[].reasonrefunds[].noteStaff's own words. Null without orders:amounts
refunds[].failureReasonrefunds[].createdAtrefunds[].tenderWhat the refunded payment was made with: card (back to the guest's card), gift_certificate or credit (back to it), or an offline tender (card_terminal, cash, debit, e_transfer, cheque), which staff gave back that way at the desk; a voucher's part is given back as a credit (creditId), and a guest's own refund under the booking's refundDestination as a credit (creditId) or gift certificate (giftCertificateId) instead of back to the card or the desk
refunds[].creditIdThe credit this refund became instead of going back where it was paid: a third party's voucher can't be handed back, so its part is a credit (voucher_refunded); a guest's own cancellation or change under refundDestination credit gives one (guest_change). The same credit the booking's credits list shows. Null for every other refund. Always present
refunds[].giftCertificateIdThe gift certificate (kind refund) this refund became instead of going back where it was paid: a guest's own cancellation or change under refundDestination gift_certificate. Null for every other refund. Always present
refunds[].issuerWho issued the voucher the refunded payment was (such as Costco); null for any other tender, and without orders:amounts. Always present
renew_manage_link
Issue a new manage link for a paid or canceled order, so a link that went to the wrong people stops working: the old one is not found from then on, and every earlier email's link with it. The guest gets the new link by email, unless sendEmail is false (their inbox can't be trusted; they'd need another renewal to get in again). If the old link went to the wrong address, give the right one in deliverTo: the order and its messages move there. Nobody sees the link itself, staff included. It can't be undone, so an old link never comes back: renew again for another one. Returns a preview to confirm.
Changes · Members of an organization · Needs bookings:write
Input
orderIdThe order's id, from list_bookings or list_orders
reasonexposed: the link was shared or leaked; wrong_recipient: it went to the wrong address; guest_request: the guest asked; other: say why in note
noteStaff's own reason, or more about the one chosen, in a sentence, for the activity log. Enough on its own (the reason is then other). Never shown to the guest
deliverToThe right address, if the old link went to a wrong one
sendEmailEmail the new link to the guest (default true)
Output
orderIdcodelinkVersionemailedWhether the new link is emailed. Always present
emailedToWho the new link is emailed to; null when none is sent, or without customers:contact
resend_booking_confirmation
Email a booking's confirmation to its guest again (a lost email): the same message the booking sent at checkout, with the booking's current details and its current manage link. It makes no new manage link (renew_manage_link does), and goes out even when automatic confirmations are off. Refused for a cancelled booking, one that isn't confirmed yet, one with no guest email, and an address that can't be emailed (it bounced, or the guest marked an email as spam). It can't be undone. Needs bookings:write where the booking is; the address is shown only with customers:contact. Returns a preview to confirm.
Changes · Members of an organization · Needs bookings:write
Input
orderIdThe order's id, from list_bookings or list_orders
Output
sentToThe address it was sent to; without customers:contact, the words "the guest's email address"
atWhen it was queued