BETA: Please note that the current endpoints are considered beta. It is possible there may be changes before these endpoints are finalised.
Bills
Push a bill
Push a bill
post /organizations/{organizationId}/locations/{locationId}/billsParameters
| Name | Type | In | Description |
|---|---|---|---|
organizationId | string | path | Organization ID |
locationId | string | path | Location ID |
Request Body
PushBillRequestBody
{
"bill": {
"balance": 4000,
"billRef": "A-54313002",
"completedAt": "2021-08-04T04:38:00Z",
"createdAt": "2021-08-04T04:38:00Z",
"currency": "NZD",
"isClosed": false,
"items": [
{
"amount": 10000,
"name": "Bacon and Egg roll",
"quantity": 1,
"subItems": {
"amount": 100,
"name": "subItem1"
},
"type": "ITEM"
},
{
"amount": -1000,
"name": "Credits",
"quantity": 1,
"type": "ADJUSTMENT"
},
{
"amount": -1000,
"name": "Discount",
"quantity": 1,
"type": "DISCOUNT"
}
],
"payments": [
{
"name": "Cash",
"tip": 0,
"total": 2000
},
{
"name": "Card",
"tip": 0,
"total": 1000
},
{
"name": "App-Payment",
"tip": 1500,
"total": 3000
}
],
"placeRef": "4",
"tax": 300,
"tipsAllowed": true,
"total": 7000,
"updatedAt": "2021-08-04T04:38:00Z"
}
}Responses
204: No Content response.
400: invalid_item_quantity: Bad Request response.
Accept a bill payment
Used to signal a payment has been processed by your integration.
post /organizations/{organizationId}/locations/{locationId}/bills/{billId}/payment/{paymentId}/acceptParameters
| Name | Type | In | Description |
|---|---|---|---|
organizationId | string | path | Organization ID |
locationId | string | path | Location ID |
billId | string | path | |
paymentId | string | path | Payment ID |
Responses
204: No Content response.
Reject a bill payment
Used to signal a payment was unable to be processed by your integration.
post /organizations/{organizationId}/locations/{locationId}/bills/{billId}/payment/{paymentId}/rejectParameters
| Name | Type | In | Description |
|---|---|---|---|
organizationId | string | path | Organization ID |
locationId | string | path | Location ID |
billId | string | path | |
paymentId | string | path | Payment ID |
Request Body
RejectBillPaymentRequestBody
{
"reason": "The bill is fully paid."
}Responses
204: No Content response.
Models
Bill
| Name | Type | Description |
|---|---|---|
| completedAt | string | (optional) When the bill was completed. |
| createdAt | string | When the bill was created. |
| updatedAt | string | When the bill was last updated. |
| balance | integer | Balance remaining on this bill. Total, minus any payments already made on the bill. |
| billRef | string | The bill ID is the identifier for this bill from a non-LOKE system, the remote service's bill ID. |
| currency | string(enum) | "AUD", "SGD", "GBP", "NZD", "USD" |
| isClosed | boolean | Bill is closed or not. A bill can be closed before being completed if needed. |
| placeRef | string | (optional) The service reference (table number, room number, QR code, etc) |
| tax | integer | (optional) Tax amount included on bill. |
| tipsAllowed | boolean | (optional) Can tips be attached to this bill. |
| total | integer | Total amount that must be paid on this bill, excluding payments. Inclusive of any tax. The total must equal the sum of the items. |
| items | BillItem[] | List of items associated with this bill. NOTE: may include discounts. |
| payments | BillPayment[] | Any existing payments made on this bill. |
BillItem
| Name | Type | Description |
|---|---|---|
| id | string | (optional) ID of the product item. |
| name | string | Display name of the product on this line item. |
| amount | integer | The tax inclusive unit price of one item.
The price is represented in the lowest denomination (e.g., cents).
For discounts this should be negative.
Excludes the price of subItems. |
| quantity | integer | The quantity of items ordered. Quantity must be 1 or more. |
| tax | integer | (optional) The included tax for one item.
The tax is represented in the lowest denomination (e.g., cents).
For discounts this should be negative.
Excluded the tax from subItems. |
| type | string(enum) | Use item for products on the bill, discount for reductions applied, adjustments for additional charges (ie: weekend surcharge). "item", "discount", "adjustment" |
| subItems | BillSubItem[] | (optional) |
BillSubItem
| Name | Type | Description |
|---|---|---|
| name | string | Display name of the option, variation, combo choice, etc. |
| amount | integer | The tax inclusive cost of a single instance of this sub-item. |
BillPayment
| Name | Type | Description |
|---|---|---|
| name | string | Method of payment or payment label. |
| refId | string | (optional) A reference to the record of this payment to another system. |
| payment | integer | (optional) Amount actually paid by the user, including tips. |
| tip | integer | (optional) Tip included in in this payment. |
| total | integer | The total amount paid on this payment instance.
Inclusive of tips and loyalty credit.
Successful payments should be listed as a positive integer.
Reversals as a negative integer. |
PushBillRequestBody
| Name | Type | Description |
|---|---|---|
| bill | Bill |
RejectBillPaymentRequestBody
| Name | Type | Description |
|---|---|---|
| reason | string | (optional) A human readable reason the bill payment is rejected. |