Pay & Create Order

Submits an order and creates a ticket at the location. This endpoint finalizes the ordering flow by recording the items, applying totals, and registering the chosen payment method. It supports both deferred payment, where the guest pays in store, and third-party payment, where payment is captured through an external processor.

Request Headers

HeaderRequiredDescription
AuthorizationYesBearer YOUR_ACCESS_TOKEN
Content-TypeYesapplication/json

Request Parameters

Path Parameters

ParameterTypeRequiredDescription
location_idstringYesIdentifier of the location.

Query Parameters

ParameterTypeRequiredDescription
global_on_idintegerYesThe global operation ID.
user_idintegerYesThe user ID performing the operation.
flowstringYesThe flow type for the operation.
i18nstringNoLanguage/locale for the request.

Request Body Fields

FieldTypeRequiredDescription
employee_idintegerYesID of the employee creating the order.
ticketobjectYesContains the ticket (order) details. See ticket object below.
payment_typestringYesPayment method used (for example, pay_in_store).
paymentobjectNoPayment detail. Required when payment_type is third_party. See payment object below.
olo_infoobjectNoOnline ordering information (if applicable). See olo_info object below.
ticket_name_max_lengthintegerNoMaximum allowed length for the ticket name.
loc_processor_codestringNoISO 3166-1 alpha-2 country code identifying the processor to use when an account has multiple processors configured. Examples: us = United States processor, ca = Canada processor.

Object Fields

ticket object

FieldTypeDescription
ticket_numberintegerUnique ticket number.
employee_idintegerID of the employee handling the ticket.
employee_id_externalstringExternal employee ID, if available.
itemsarrayList of items included in the order. See ticket.items[] object below.
namestringName of the ticket/order.
order_type_idintegerOrder type ID (for example, dine-in or takeout).
order_type_id_externalstringExternal order type ID.
revenue_center_idintegerRevenue center or POS terminal ID.
revenue_center_id_externalstringExternal revenue center ID.
guest_countintegerNumber of guests.
guest_idintegerID of the guest linked to the ticket.
taxnumberTotal tax amount.
duenumberAmount due after taxes, discounts, and adjustments.
sub_totalnumberOrder subtotal before taxes and discounts.
totalnumberFinal order total.

ticket.items[] object

FieldTypeDescription
category_idintegerItem category ID.
idintegerInternal item ID.
id_externalstringExternal item ID.
modifiersarrayList of item modifiers, if applicable.
pricenumberTotal price of the item.
price_per_unitnumberPrice per individual unit.
quantityintegerQuantity ordered.
commentstringOptional comment for the item.
namestringItem name.

payment object

Included when payment_type is third_party.

FieldTypeDescription
card_typestringCard brand for a third-party payment.
base_amountintegerBase amount captured, in minor units.
tip_amountintegerTip amount, in minor units.
auto_closebooleanWhether the ticket is closed automatically after payment.

olo_info object

FieldTypeDescription
contact_infoobjectCustomer contact information. See olo_info.contact_info object below.
order_typestringOnline order type (e.g., pickup or delivery).
pickup_datetimestringScheduled pickup date and time, if applicable.
vehicleobject | nullVehicle information, if applicable.

olo_info.contact_info object

FieldTypeDescription
first_namestringCustomer's first name.
last_namestringCustomer's last name.
emailstringCustomer's email address.
phonestringCustomer's phone number.
phone_global_countryintegerInternational country code for the phone number.
addressstringCustomer's primary address line.
address2stringSecondary address line (optional).
zipstringZIP or postal code.

Request Example

The following example uses the pay-in-store flow.

{
  "employee_id": 293,
  "ticket": {
    "ticket_number": 987607656,
    "employee_id": 293,
    "employee_id_external": "15",
    "items": [
      {
        "category_id": 189588,
        "id": 1672955,
        "id_external": "30004",
        "price": 429,
        "quantity": 1,
        "comment": "",
        "name": "FR SILK(SLI)",
        "modifiers": []
      }
    ],
    "name": "Online Order",
    "order_type_id": 38,
    "order_type_id_external": "1",
    "revenue_center_id": 23,
    "revenue_center_id_external": "1",
    "guest_count": 1,
    "tax": 0,
    "sub_total": 758,
    "total": 758,
    "due": 758
  },
  "payment_type": "pay_in_store",
  "ticket_name_max_lenght": 15
}

For a third-party payment, set payment_type to third_party and include a payment object:

{
  "payment_type": "third_party",
  "payment": {
    "card_type": "VISA",
    "base_amount": 1350,
    "tip_amount": 0,
    "auto_close": true
  }
}

cURL Example

curl --request POST \
  --url "https://sandbox-api.softpoint.io/interface/v1/locations/YOUR_LOCATION_ID/app/checkout/pay_and_create_ticket?global_on_id=16&user_id=1&flow=order&i18n=en" \
  --header "Authorization: Bearer YOUR_ACCESS_TOKEN" \
  --header "Content-Type: application/json" \
  --data '{
    "employee_id": 293,
    "ticket": { "employee_id": 293, "items": [], "name": "Online Order", "total": 758, "due": 758 },
    "payment_type": "pay_in_store"
  }'

Success Response

A successful request returns the created ticket. The response includes ticket metadata, a totals object, and embedded employee, order type, revenue center, and item details. The example below is trimmed for brevity.

{
  "id": 1284878,
  "id_external": "419",
  "pos_id": "419",
  "opened_at": "2025-12-09 00:08:24",
  "name": "Eduardo API_A",
  "open": 1,
  "guest_count": 1,
  "ticket_number": 547,
  "totals": {
    "items": 1149,
    "tax": 201,
    "exclusive_tax": 201,
    "sub_total": 1149,
    "total": 1350,
    "paid": 0,
    "due": 1350,
    "grand_total": 1350
  },
  "_embedded": {
    "employee": { "employee_id": 376, "first_name": "ADAM", "last_name": "GAREN", "check_name": "ADAM G." },
    "order_type": { "order_type_id": 38, "name": "RESTAURANT" },
    "revenue_center": { "revenue_center_id": "23", "name": "RESTAURANT" },
    "items": [
      {
        "id": 80292,
        "name": "BURGER",
        "price": 1149,
        "tax": 201,
        "quantity": 1,
        "modifiers": [
          { "id": 38193, "menu_modifier_id": 494915, "name": "HASH BROWNS", "price": 0, "quantity": 1 }
        ]
      }
    ]
  }
}

Response Fields

FieldTypeDescription
idintegerInternal ticket identifier.
id_externalstringExternal ticket identifier.
pos_idstringPoint-of-sale ticket identifier.
opened_atstringTimestamp when the ticket was opened (UTC).
opened_at_localstringLocal timestamp when the ticket was opened.
closed_atstringTimestamp when the ticket was closed; null when still open.
namestringTicket display name.
openintegerIndicates whether the ticket is open. 1 is open, 0 is closed.
guest_countintegerNumber of guests on the ticket.
ticket_numberintegerSequential ticket number.
totalsobjectMonetary totals for the ticket, in minor units.
totals.itemsintegerCombined item price.
totals.taxintegerTotal tax.
totals.sub_totalintegerSubtotal before tax.
totals.totalintegerGrand total.
totals.paidintegerAmount paid so far.
totals.dueintegerAmount still due.
_embedded.employeeobjectEmployee associated with the ticket.
_embedded.order_typeobjectOrder type applied to the ticket.
_embedded.revenue_centerobjectRevenue center applied to the ticket.
_embedded.itemsarrayItems on the ticket, including modifiers.

Error Responses

Pay & Create Order uses the standard error envelope. A missing channel identifier produces error code 10189.

{
  "error": {
    "code": 10189,
    "message": "Invalid global on id.",
    "details": {
      "error": "The parameter global_on_id is required"
    }
  }
}

Status Codes

CodeDescription
200Order created successfully.
400Invalid order contents or payment information.
401Missing or invalid access token, or missing channel identifier.

Workflow Placement

Pay & Create Order is the final submission step in the ordering flow:

  1. Build and price the cart.

  2. Submit the order with the chosen payment type.

  3. Retrieve the ticket to confirm status and totals.

Notes

  • The flow query parameter must be set to order for online ordering.

  • All monetary values are expressed in minor units (cents).

  • Use pay_in_store when the guest will pay at the location, and third_party when payment is captured externally. The payment object is required for third_party.

  • The response reflects the ticket as created; for a pay-in-store order, totals.paid is typically 0 and totals.due equals the total.

Common Mistakes

  • Omitting the flow query parameter or setting it to an unsupported value.

  • Using third_party without supplying the payment object.

  • Omitting global_on_id, which results in error code 10189.

  • Sending amounts in major units (dollars) rather than minor units (cents).

Query Params
integer
integer
string
string
Body Params
Headers
string
enum
Defaults to application/json

Generated from available response content types

Allowed:
Response

Language
Credentials
Bearer
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json
text/plain