Logo
Getting started
    • Overview
    • Authentication
    • Testing
    • Error handling
    • Webhooks
    • Loyalty Tokens
    • Register API
Tutorials
API Reference
TUTORIAL

Order at Table Integration

Introduction

This guide covers how to build a loyalty integration for Order at Table systems. These are typically mobile web applications where customers scan a QR code at their table and order directly from their own device.

Order at Table integrations differ from kiosks and POS systems in several key ways: customers use their own mobile devices, authentication is typically email-based (passwordless), and the experience should feel native to mobile browsing.

In this tutorial

Main Loyalty Flow

This flow covers the complete Order at Table loyalty experience: from displaying offers to non-authenticated users, through login/signup, to redeeming offers and completing orders. Hover over the interactive previews to see which API endpoints are used at each step.

1

Adding Blocks to Page

LOGO
Burgers
Drinks
Sides
Desserts
Krabby PattyThe finest underwater burger
€9,00
Double Krabby PattyTwice the patty, twice the taste
€12,00
Kelp FriesCrispy seaweed fries
€4,50

In an Order at Table integration, customers browse and order from their own mobile device. The loyalty integration should be seamlessly embedded into the ordering experience, with an offers section prominently displayed on the menu page.

For non-authenticated users, show a prompt to join the loyalty program or log in to access their rewards and offers.

Try it: Click the "Start earning rewards now!" banner to simulate a customer wanting to log in.

2

Identifying Customer

Unlike kiosks where customers scan a card, Order at Table integrations typically use email-based authentication. When a customer enters their email, first check if they already exist in the system.

LOGO
Offers
Start earning rewards now!
Join as a member and enjoy exclusive rewards
Burgers
Drinks
Sides
Desserts
Krabby PattyThe finest underwater burger
€9,00
Double Krabby PattyTwice the patty, twice the taste
€12,00
Kelp FriesCrispy seaweed fries
€4,50

Members login

Enjoy member benefits like free rewards and seasonal discounts

Enter email address
Login

Authentication Flow:

Use your own authentication layer if you have your own, otherwise, follow these steps below
  1. Customer enters their email address
  2. Call Find Contact to check if the email exists
  3. If found: Send verification code via Send Contact Verification Email
  4. If not found: Redirect to sign up form
2

Verification Code

For existing customers, send a verification code to their email. This provides a passwordless authentication experience that's secure and user-friendly on mobile devices.

LOGO
Offers
Start earning rewards now!
Join as a member and enjoy exclusive rewards
Burgers
Drinks
Sides
Desserts
Krabby PattyThe finest underwater burger
€9,00
Double Krabby PattyTwice the patty, twice the taste
€12,00
Kelp FriesCrispy seaweed fries
€4,50

Enter verification code

Enter the six-digit code you've received in your email

If your Order at Table system already has its own authentication layer (e.g., customers log in to your app), you can skip this verification step and directly link the session to the customer's contact record using their authenticated email or user ID.

2

Sign Up (New Customers)

For new customers, collect their basic information to create a loyalty account. Keep the form simple to reduce friction.

LOGO
Offers
Start earning rewards now!
Join as a member and enjoy exclusive rewards
Burgers
Drinks
Sides
Desserts
Krabby PattyThe finest underwater burger
€9,00
Double Krabby PattyTwice the patty, twice the taste
€12,00
Kelp FriesCrispy seaweed fries
€4,50

Sign up

We wanna get to know you! Tell us a bit about yourself.

First name*
Last name*
Birthdate
I agree to the Terms and Conditions
Signup

Recommended fields:

  • Email (pre-filled from login attempt - required)
  • First name (optional but highly recommended)
  • Last name (optional but highly recommended)
  • Birthdate (optional - useful for birthday rewards)
  • Terms & Conditions acceptance
3

Showcasing Rewards and Vouchers

Once logged in, the customer sees their available offers directly on the menu page. This includes vouchers and collectable rewards that can be redeemed with their order.

LOGO
Burgers
Drinks
Sides
Desserts
Krabby PattyThe finest underwater burger
€9,00
Kelp FriesCrispy seaweed fries
€4,50

Displaying Offers:

  • Show the customer's current point balance
  • Display available vouchers with expiry dates
  • Show collectable rewards (pre-redeemed rewards)
  • Both vouchers and collectable rewards can be redeemed free of charge
  • Provide a "See all" link to view all available offers
3

All Offers View

The "All offers" screen shows both available offers (vouchers and collectable rewards) and purchasable rewards that customers can redeem with their points.

LOGO
Offers
Start earning rewards now!
Join as a member and enjoy exclusive rewards
Burgers
Drinks
Sides
Desserts
Krabby PattyThe finest underwater burger
€9,00
Double Krabby PattyTwice the patty, twice the taste
€12,00
Kelp FriesCrispy seaweed fries
€4,50
Vouchers

Pre-issued offers that customers receive through promotions, campaigns, or as gifts. Can be redeemed for free.

Collectable Rewards

Rewards that were pre-redeemed (points already deducted) but not yet collected. Can be redeemed for free.

Rewards

Items that customers can purchase with their points. Requires sufficient point balance to redeem.

4

Redeeming Offers

When a customer selects an offer, show a confirmation screen before applying it to their order. This prevents accidental redemptions.

LOGO
Offers
Start earning rewards now!
Join as a member and enjoy exclusive rewards
Burgers
Drinks
Sides
Desserts
Krabby PattyThe finest underwater burger
€9,00
Double Krabby PattyTwice the patty, twice the taste
€12,00
Kelp FriesCrispy seaweed fries
€4,50

Redeem offer

The offer will be added to your order immediately

Free Kelp ShakeExpires 20 September 2025

Do you want to redeem this voucher now?

You can only use this voucher once.

For Order at Table, we recommend the Lock → Redeem approach:

  1. Lock Voucher — reserves the voucher when customer confirms
  2. Customer completes their order and pays
  3. On success: Redeem Voucher
  4. On failure/timeout: Release Voucher (or let it expire automatically)

This prevents vouchers from being permanently consumed if the customer abandons their order.

Applying discounts to the order is often the most complex part of the integration. To enable your Order at Table system to handle this correctly, you'll need to create custom attributes that define the discount logic.

Important: Custom attributes must be created on the correct entity:

  • For Rewards: Create custom attributes on the Rewards entity
  • For Vouchers: Create custom attributes on the Promotions entity (the parent of Vouchers)

Common custom attributes:

  • discount_type - Dropdown: percentage_discount, absolute_discount, or free_item
  • discount_value - Number field (e.g., 100 for 100% off = free item, or 5 for €5 off)
  • product_code - SKU of the specific product
  • category - If the reward applies to any product in a category
4

Offer Applied

After confirming, show a success message and add the discounted item to the customer's basket.

LOGO
Offers
Start earning rewards now!
Join as a member and enjoy exclusive rewards
Burgers
Drinks
Sides
Desserts
Krabby PattyThe finest underwater burger
€9,00
Double Krabby PattyTwice the patty, twice the taste
€12,00
Kelp FriesCrispy seaweed fries
€4,50

Offer redeemed!

Your offer was added to your basket!

5

Finalising the Order

The basket shows all items including any applied offers. Customers can still add more offers before checking out.

LOGO
Offers
Start earning rewards now!
Join as a member and enjoy exclusive rewards
Burgers
Drinks
Sides
Desserts
Krabby PattyThe finest underwater burger
€9,00
Double Krabby PattyTwice the patty, twice the taste
€12,00
Kelp FriesCrispy seaweed fries
€4,50

Basket

Krabby Patty€9,00
1
Kelp Shake
€3,50€0,00
Offer applied: Free Kelp Shake
1
Total€9,00

Basket Display:

  • Show original price crossed out for discounted items
  • Display the offer name that was applied
  • Keep offers section visible for additional redemptions
  • Show updated total reflecting all discounts
6

Order Successful

After successful payment, show the customer how many points they earned from their order.

LOGO

Order successful

Your order was successfully processed, we're preparing it right away.

Points earned:
+18

The response from the Create and Process Order endpoint includes the points earned, which you can display to the customer.

Make sure to call Redeem Voucher and/or Collect Collectable Reward after successful payment to finalize any applied offers.

When creating Orders, the best practice is to create the Order as completely as you can. This includes linking Products and any Leat-actions that may have been undertaken in the Order process (e.g. Reward Redemptions, Voucher Redemptions, Giftcard Transactions etc.). Some best practices to take into account:

  • external_identifier: This is the main identifier from your system, usually a UUID or GUID or some other. It's imperative this is unique across all Orders.
  • order_amount, total_order_amount, total_discount_amount: These are mainly for visual and reference purposes. When Orders are using in Order Actions (to make Points Transactions, for instance), these values will be largely ignored. To account for product-specific exclusions and rules, the order amounts used in calculations and actions will be calculated using the line items, charges and discounts. Still, please ensure these match the content to prevent any confusion.
  • line_items.external_identifier: This is the unique identifier of this line item. Another line item of the same product should have their own unique identifier.
  • line_items.total_amount: The total amount of a line items ought to be the line items' price times the quantity, minus the discount amount. The total amount does not include the total amounts of any sub line items. They are counted separately.
  • line_items.product: For a host of features in Leat, it's imperative the product is linked (if present). The external identifier counts as the main unique identifier of the product, which is of course static for the same product across multiple line items and orders. If no product yet exists for the external identifier, one will be created. However, to fully enable the Product filtering feature, it's highly recommended to create the entire product library, including categories, upon integration installation.
  • line_items.sub_line_items: Line items may include sub line items, like modifiers. Note: the total amounts of the sub line items count separately from the line item's total amount. Example: a line item for a 'Pizza Margherita' with a total amount of 1200 ($12) may include a sub line item for 'Extra Cheese' with a total amount of 200 ($2), which would bring the total order amount to 1400 ($14). The $2 from the sub line item is not included in the total amount on the parent line item. Sub line items are to be linked to products in the same way as their parent line items.
  • line_items.result: This is the 'Leat result' of this line item, if any exists. Examples of this is when a customer buys a Gift card or a Voucher. This would be reflected as a line item on the Order and the resulting Giftcard Transaction (usually created after payment has succeeded) can be linked as a result. Highly recommended to link if present.
  • applied_discounts: If one or more discounts have been applied to the order, these should be added here. Discounts are either applied on an Order level, or on a (Sub)Line Item level. In the latter, the applied discount should also be reflected in the discount amount on the individual (sub) line item(s) and/or charges. In such a case, the specific items should also be linked to the discount via the line items, sub line items and charges parameters.
  • applied_discounts.offer: If the applied discount was the result of a Leat offer (e.g. Reward Redemption, Voucher Redemption etc.), this offer should be added to the discount. Highly recommended to link if present.
  • charges: Charges are costs that are applied after (sub) line items. Examples include gratuity, service charges, shipping, wrapping or taxes (all of these are default Charge Definitions). In the case of taxes, there are only a few use cases in which taxes are to be included as separate charges. Most often, it's preferable to include them in the line items price instead of as separate charges. Charge Definitions are what Products are to Line Items.
  • payments: Currently, only Leat-specific payments can be added here. Payment methods like credit card or cash are not to be sent in. If (part of) the order was paid using Leat payment methods (Giftcards, Prepaid), these should be linked here.

If you have any questions about Orders, please reach out to your partnership manager or contact us at dev@leat.com.

Applying discounts to the order is often the most complex part of the integration. To enable your Order at Table system to handle this correctly, you'll need to create custom attributes that define the discount logic.

Important: Custom attributes must be created on the correct entity:

  • For Rewards: Create custom attributes on the Rewards entity
  • For Vouchers: Create custom attributes on the Promotions entity (the parent of Vouchers)

Common custom attributes:

  • discount_type - Dropdown: percentage_discount, absolute_discount, or free_item
  • discount_value - Number field (e.g., 100 for 100% off = free item, or 5 for €5 off)
  • product_code - SKU of the specific product
  • category - If the reward applies to any product in a category

When an order is cancelled or returned, you'll need to correct the loyalty data. This involves correcting issued points and reversing any redeemed vouchers.

1. Correcting Issued Points

Use the Create and Process Order Return endpoint to subtract points that were originally awarded.

2. Reversing Redeemed Vouchers

Use Reverse Voucher Redemption to restore the voucher to its original state.