Shopify events and variables
The complete reference for what fires an automation and what data you can put in a template.
Who can do this
- Developer
- Owner
- Admin
- Agent
Before you start
- A connected Shopify store.
- A checkout that captures the customer's phone number. Without one there is no number to message and events go nowhere.
Triggers
Boldally listens to these Shopify webhooks. They are registered automatically on install; there is nothing to configure in Shopify.
| Shopify event | Automation trigger | Fires when |
|---|---|---|
orders/create | Order placed | A customer places a new order |
orders/paid | Order paid | Payment is captured |
orders/fulfilled | Order fulfilled | The whole order is marked fulfilled |
orders/partially_fulfilled | Order partially fulfilled | Part of the order ships |
orders/edited | Order edited | The order's contents are edited |
orders/cancelled | Order cancelled | The order is cancelled |
refunds/create | Order refunded | A refund is issued |
fulfillments/create | Shipment created | A shipment is created and tracking added |
fulfillments/update | Shipment updated | Carrier status changes. Only sends on out for delivery and delivered; an automation can be scoped to one of them. |
checkouts/create, checkouts/update | Abandoned checkout | A checkout is started but not completed. Sent after your chosen delay, and cancelled if the order comes through. |
Which variable groups each trigger exposes
| Trigger | Groups available |
|---|---|
| Order placed / paid / fulfilled / partially fulfilled / edited / cancelled | Customer, Order, Shipping address, Items, Shipping method, Discount, Shipping carrier |
| Order refunded | All of the above, plus Refund |
| Shipment created / updated | All order groups, plus Shipment |
| Abandoned checkout | Customer, Checkout |
The groups
Customer
| Variable | Example |
|---|---|
| First name | Priya |
| Last name | Sharma |
| Full name | Priya Sharma |
| priya@example.com | |
| Phone | +919876543210 |
| Lifetime orders | 7 |
| Lifetime spend | 12,499.00 |
| Tags | vip, repeat |
Order
| Variable | Example |
|---|---|
| Order number | #1042 |
| Order number (numeric) | 1042 |
| Order status link | https://shop.example.com/…/orders/abc |
| Total | 1,299.00 |
| Subtotal | 1,199.00 |
| Items total | 999.00 |
| Tax | 100.00 |
| Total discounts | 150.00 |
| Currency | INR |
| Payment status | paid |
| Payment method | Cash on Delivery (COD) |
| Fulfillment status | fulfilled |
| Order note | Leave at door |
| Order tags | prepaid, festive |
| Cancel reason | customer |
| Source | web |
Shipping address
| Variable | Example |
|---|---|
| Recipient name | Priya Sharma |
| Recipient first name | Priya |
| Recipient last name | Sharma |
| Recipient phone | +919876543210 |
| Company | Acme Co. |
| Address line 1 | 12 MG Road |
| Address line 2 | Apt 3B |
| City | Bengaluru |
| State / province | Karnataka |
| Country | India |
| Postal code | 560001 |
Items
First item fields refer to the first product on the order. To list every product, use Combine.
| Variable | Example |
|---|---|
| Number of items | 3 |
| First item name | Cotton T-Shirt |
| First item variant | Large / Black |
| First item quantity | 2 |
| First item SKU | TSHIRT-L-BLK |
| First item price | 999.00 |
| First item brand | JELLICO |
Shipping method
| Variable | Example |
|---|---|
| Shipping method | Standard |
| Shipping cost | 0.00 |
Discount
| Variable | Example |
|---|---|
| Discount code | WELCOME20 |
| Discount amount | 200.00 |
Shipping carrier
These describe the first shipment only. If an order can ship in more than one box, use Combine → Shipments instead, or the customer gets one tracking number for a parcel that arrived in three.
| Variable | Example |
|---|---|
| Tracking number | AWB123456789 |
| Carrier | Delhivery |
| Tracking URL | https://track.example.com/AWB123 |
Shipment
Shipment created and Shipment updated only.
| Variable | Example |
|---|---|
| Status | delivered |
| Tracking number | AWB123456789 |
| Carrier | Delhivery |
| Tracking URL | https://track.example.com/AWB123 |
Refund
Order refunded only.
| Variable | Example |
|---|---|
| Refund amount | 299.00 |
| Currency | INR |
| Refund note | Item out of stock |
Checkout
Abandoned checkout only.
| Variable | Example |
|---|---|
| Recovery link | https://shop.example.com/cart/c/abc123 |
| Cart total | 1,299.00 |
| Cart subtotal | 1,199.00 |
| Currency | INR |
| Number of items | 2 |
| First item name | Cotton T-Shirt |
| First item quantity | 1 |
| First item SKU | TSHIRT-L-BLK |
| Discount code | WELCOME20 |
Combine a list into one variable
Instead of "first item", collapse a whole list into a single variable, for a receipt-style line:
2× Cotton T-Shirt · 998.00, 1× Baseball Cap · 299.00
What can be combined, by trigger:
| List | Available on | Example |
|---|---|---|
| Products | All order and checkout triggers | 2× Cotton T-Shirt · 998.00 |
| Shipments | Order fulfilled, partially fulfilled, Shipment created, Shipment updated | Delhivery AWB123456, BlueDart AWB998877 |
| Items in this shipment | Shipment created, Shipment updated | 2× Cotton T-Shirt, 1× Baseball Cap |
| Refunded items | Order refunded | 1× Baseball Cap |
| Discount codes | All order and checkout triggers | WELCOME20 200.00, FREESHIP 50.00 |
| Checkout notes | All order triggers | Alternate phone: +919812345678 |
| Taxes | All order triggers | CGST 9% 45.00, SGST 9% 45.00 |
Per product you can include: quantity, name, variant, line total, unit price, brand, SKU.
:::note Unit price vs line total
Unit price is what one costs (499.00). Line total is what the customer
actually paid for that line: price × quantity, minus any discount on it
(998.00). Line total is the default, because it is the one that adds up to the
order's subtotal.
:::
Styles
| Style | Result |
|---|---|
| Comma | 2× Cotton T-Shirt, 1× Baseball Cap |
| Bullet | 2× Cotton T-Shirt · 1× Baseball Cap |
| Dash | 2× Cotton T-Shirt — 1× Baseball Cap |
| Bulleted | • 2× Cotton T-Shirt • 1× Baseball Cap |
| Numbered | 1) 2× Cotton T-Shirt 2) 1× Baseball Cap |
You can cap the list with Max items, which appends +N more.
:::info Why lists are always on one line WhatsApp does not allow a line break inside a variable; Meta rejects the message outright. A variable that could add line breaks would let a template be rearranged after approval, so the rule protects the approval. Addresses are the exception, because they have a fixed number of lines. :::
Addresses
A variable cannot contain a line break, so a multiline address is built one line per placeholder:
Ship to:
{{2}}
{{3}}
{{4}}
| Placeholder | Pick | Renders |
|---|---|---|
{{2}} | Line 1, street | 12 MG Road, Apt 3B |
{{3}} | Line 2, city, state, PIN | Bengaluru, Karnataka 560001 |
{{4}} | Line 3, country | India |
Or pick Full address (one line) for a single variable:
12 MG Road, Apt 3B, Bengaluru, Karnataka 560001, India.
Blank parts are cleaned up rather than leaving stray punctuation, so an order
with no "Apt 3B" renders 12 MG Road, not 12 MG Road,.
:::caution Orders with no shipping address Digital products and POS sales have no address, and every address line falls back to a dash. If that is possible in your store, put a condition on Address line 1 before the message and send a different template when it is empty. :::
Checking a binding before you go live
Two tools, in this order:
- Variable inspector on SettingsIntegrations → Shopify shows what each variable resolves to for your store.
- Test mode on the automation, with a test-contact tag, runs the whole thing against a real order without messaging customers. See testing automations.
Related
- Automations
- Building the automation these variables feed.
- Template variables
- How placeholders and parameters fit together.