post
https://sandbox-api.softpoint.io/interface//locations//app/checkout/pay_and_create_ticket
This API request is used to create a new order (ticket) in a single step for a specific location.
Query Parameters
| Parameter | Required | Description | Example |
|---|---|---|---|
global_on_id | Yes | The global operation ID. | 4 |
user_id | Yes | The user ID performing the operation. | 7 |
flow | Yes | The flow type for the operation. | order |
i18n | No | Language/locale for the request. | en |
Request Body Structure
The body must be a JSON object with the following structure. Below is the detailed description and data type for each field.
| Field | Type | Description |
|---|---|---|
employee_id | integer | ID of the employee creating the order. |
ticket | object | Contains details about the ticket/order. |
ticket.ticket_number | integer | The ticket number (unique identifier for the order). |
ticket.employee_id | integer | Employee ID of the person handling the ticket. |
ticket.employee_id_external | string | External ID for the employee (if available). |
ticket.items | array | A list of items in the ticket. |
ticket.items[].category_id | integer | Category of the item. |
ticket.items[].id | integer | Internal item ID. |
ticket.items[].id_external | string | External item ID. |
ticket.items[].modifiers | array | List of item modifiers (if applicable). |
ticket.items[].price | number | Price of the item. |
ticket.items[].price_per_unit | number | Price per unit of the item. |
ticket.items[].quantity | integer | Quantity of the item ordered. |
ticket.items[].comment | string | Optional comment for the item. |
ticket.items[].name | string | Name of the item. |
ticket.name | string | Name of the ticket/order. |
ticket.order_type_id | integer | ID of the order type (e.g., dine-in, take-out). |
ticket.order_type_id_external | string | External order type ID. |
ticket.revenue_center_id | integer | ID of the revenue center (e.g., specific POS terminal). |
ticket.revenue_center_id_external | string | External revenue center ID. |
ticket.guest_count | integer | Number of guests associated with the ticket. |
ticket.tax | number | Total tax amount for the order. |
ticket.due | number | Amount due for the order (after discounts, taxes, etc.). |
ticket.sub_total | number | Subtotal for the order (before tax and discounts). |
ticket.total | number | Total amount for the order (including tax and discounts). |
payment_type | string | The payment method used (e.g., pay_in_store, third_party). |
payment | object | Payment details if payment_type is third_party. |
olo_info | object | Information for online orders (if applicable). |
olo_info.contact_info | object | Contact information for the customer. |
olo_info.contact_info.first_name | string | Customer's first name. |
olo_info.contact_info.last_name | string | Customer's last name. |
olo_info.contact_info.email | string | Customer's email address. |
olo_info.contact_info.phone | string | Customer's phone number. |
olo_info.contact_info.phone_global_country | integer | Global country code for the phone number. |
olo_info.contact_info.address | string | Customer's address line 1. |
olo_info.contact_info.address2 | string | Customer's address line 2 (optional). |
olo_info.contact_info.zip | string | Customer's zip code. |
olo_info.order_type | string | Type of order (e.g., pickup, delivery). |
olo_info.pickup_datetime | string | Date and time for order pickup (if applicable). |
olo_info.vehicle | object | null |
ticket_name_max_length | integer | Maximum length for the ticket name. |
Third-Party Payment Information
If payment_type is set to third_party, the following fields must also be included inside the payment object:
| Key | Description | Value |
|---|---|---|
card_type | Type of payment card | MC, Visa, Amex, Other, Disco |
base_amount | Base amount of the payment | 1350 |
tip_amount | Amount for tip | 0 |
auto_close | Whether the ticket auto closes after being fully tendered | true |
