Order Email Data (Standard Context)
This article lists every field in the order context, including the new flow and cart-fee fields, and how to view them for a real order.
Order confirmations, resends, refunds, membership emails and Email ALL Attendees messages all use the order context ({{context}} = order_context). This article covers where to view an order's data, how to open it step by step, and a reference for every order, event, session, ticket, flow, payment and membership field.
Where to find it
https://<web domain>/api/ticket_order/<order id>/context.
Required access: Portal Admin
View an order's data
- Open the order — in the CMS, go to Orders and open the order.
- Select View tickets — from the order's ⋮ menu, then copy the URL. It looks like
https://demo.web.d1tix.com/ticket_order/019a16a6-74f7-fbbd-b910-319e50ac4397. - Add /api and /context —
https://demo.web.d1tix.com/api/ticket_order/019a16a6-74f7-fbbd-b910-319e50ac4397/context. - Find the field you need — match it to the tables below. A field that is missing from the page has no data for that order.
Reference
How the data is nested
An order holds events. Each event holds sessions, and each session holds tickets. Flow orders add a flows list that groups the same events by flow.
order
├─ flows[] (flow orders only)
│ └─ event_templates[] events bought through this flow
├─ event_templates[] every event in the order
├─ direct_event_templates[] events bought outside a flow
│ └─ event_sessions[]
│ ├─ tickets[]
│ └─ tickets_summary[]
├─ cart_fees[]
├─ payments[]
├─ portal, seller, gateway
└─ membership (membership orders only)
All three event lists contain the same event fields. Use {{#each event_templates}} to list every event. Use {{#each flows}} and {{#each direct_event_templates}} to show flow items and other items separately.
Order fields
|
Field |
Description |
Example |
|---|---|---|
|
|
The order's unique ID, also found in the View tickets URL |
|
|
|
Customer-facing order number |
|
|
|
ID of the cart the order came from. The CMS shows the first 8 characters as the cart number |
|
|
|
Order number in barcode format |
|
|
|
QR code image for the order. Use it as an |
— |
|
|
Always |
|
Purchaser fields
|
Field |
Description |
Example |
|---|---|---|
|
|
The purchaser's account ID |
|
|
|
Full name |
|
|
|
First name |
|
|
|
Last name |
|
|
|
Email address |
|
|
|
Sign-in provider |
|
|
|
Fields collected at checkout: |
|
Flow fields (flows[])
|
Field |
Description |
Example |
|---|---|---|
|
|
The flow's unique ID |
|
|
|
Flow name |
|
|
|
Flow description, including its HTML. Use triple braces, |
— |
|
|
Events bought through this flow, with the event fields below |
— |
Event fields (event_templates[], direct_event_templates[], flows[].event_templates[])
|
Field |
Description |
Example |
|---|---|---|
|
|
The event's unique ID, found in the event's CMS URL |
|
|
|
Event name |
|
|
|
Event category |
|
|
|
Venue name |
|
|
|
Venue address |
|
|
|
Order scan code plus the first 8 characters of the event ID |
|
|
|
QR code for the event |
— |
|
|
Purchase date and time, formatted |
|
|
|
Purchase date and time, unformatted. Use it with a date helper to change the format |
|
|
|
Event images: |
|
|
|
Answers to the event's questions, grouped by ticket group name. A group with no answers is empty |
|
|
|
The sessions booked for this event |
— |
Session fields (event_sessions[])
|
Field |
Description |
Example |
|---|---|---|
|
|
Order scan code plus the first 8 characters of the session ID |
|
|
|
QR code for the session |
— |
|
|
Start time |
|
|
|
Start date and time, formatted |
|
|
|
Start date and time, unformatted |
|
|
|
End date and time, unformatted |
|
|
|
One row per ticket |
— |
|
|
One row per ticket type, with counts and totals |
— |
Ticket fields (tickets[])
|
Field |
Description |
Example |
|---|---|---|
|
|
The ticket's unique ID |
|
|
|
The ticket's 10-character scan code, shown under each ticket on the order page |
|
|
|
QR code for the ticket |
— |
|
|
Name entered for this ticket. Uses the purchaser's name if none was entered |
|
|
|
Email entered for this ticket. Only appears when one was entered |
— |
|
|
Ticket type |
|
|
|
Ticket group |
|
|
|
Kind of item: |
|
|
|
|
|
|
|
Currency |
|
|
|
Price before discounts |
|
|
|
Price after discounts |
|
|
|
When a pass becomes valid and expires, formatted. |
|
|
|
The same dates, unformatted. Passes only |
|
|
|
Custom fields set on the ticket group |
— |
Ticket summary fields (tickets_summary[])
|
Field |
Description |
Example |
|---|---|---|
|
|
Number of tickets of this type, not the order total |
|
|
|
Ticket type |
|
|
|
Ticket group |
|
|
|
The flow these tickets were bought through. Flow orders only |
|
|
|
Currency |
|
|
|
One ticket, before and after discounts |
|
|
|
All tickets of this type, before and after discounts |
|
Price fields
When an event sends its own email, these totals cover that event only. Fee fields appear only when the order has that fee.
|
Field |
Description |
Example |
|---|---|---|
|
|
Order total before discounts |
|
|
|
Total discounts |
|
|
|
Order total before fees |
|
|
|
Percentage fees included in the ticket price |
|
|
|
All fees added on top of the ticket price |
|
|
|
Percentage fees added on top |
|
|
|
Fixed fees added on top |
|
|
|
Cart fees, such as a handling fee |
|
|
|
Cart fees before discounts |
|
|
|
Order total |
|
|
|
Amount paid |
|
Cart fee fields (cart_fees[])
|
Field |
Description |
Example |
|---|---|---|
|
|
Fee name |
|
|
|
Fee label as set on the fee |
|
|
|
Fee before discounts |
|
|
|
Fee charged |
|
|
|
Currency |
|
Payment fields
|
Field |
Description |
Example |
|---|---|---|
|
|
Payment gateway |
|
|
|
Gateway receipt details, when the gateway provides them |
— |
|
|
Payment date and time, unformatted |
|
|
|
Payment method name |
|
|
|
|
|
|
|
Amount |
|
|
|
Card brand and last 4 digits. Card payments only |
|
|
|
Payment type |
|
|
|
Checkout rules and discount codes applied. Empty when there are none |
— |
Portal and seller fields
|
Field |
Description |
Example |
|---|---|---|
|
|
Portal name |
|
|
|
Portal web domain |
|
|
|
Portal identifier |
|
|
|
Seller name |
|
|
|
Seller identifier |
|
|
|
Seller settings, such as |
|
Membership fields (membership, membership orders only)
|
Field |
Description |
Example |
|---|---|---|
|
|
Member ID |
|
|
|
QR code for the membership |
— |
|
|
Membership event name |
|
|
|
Membership level |
|
|
|
Expiry date, unformatted |
|
|
|
Every membership the member holds, each with |
— |
Best practices
-
Use the
_rawdates for custom formats. The formatted dates can't be changed. The_rawversions work with date helpers. -
Use
direct_event_templateswithflowsto avoid listing items twice.event_templatesalready includes the flow items. -
Use triple braces for HTML fields.
{{{flow_description}}}keeps bold text and line breaks. Double braces show the tags as text. -
Check
handlerbefore showing pass dates. Timed tickets showN/Aforvalid_fromandvalid_to.