How delivery works
When something loyalty-related happens, Habit queues an event and a background job delivers it to:- Shopify Flow — if the shop has an active Habit session and the payload is valid
- Your webhook URL — if one is saved in Settings
Events are only queued when the member has an email address on file. Guests without email are skipped silently.
Shopify Flow
Habit registers seven triggers in Shopify Flow. Install the free Shopify Flow app if you do not already have it.1
Open Flow
In Shopify admin, go to Apps → Flow.
2
Create a workflow
Click Create workflow, choose a Habit trigger, then add actions — for example send email through Klaviyo, Omnisend, or Shopify Email when those apps are connected to Flow.
3
Use customer and order data
Every trigger includes a customer reference. Order-related triggers also include an order reference, so you can branch on
customer.email, order.name, and other Flow variables.Available triggers
Fields sent to Flow
Each trigger sends a fixed set of fields. In Flow’s editor, reference them as template variables (for example{{ customer.email }} or custom fields like {{ Points }}).
Points earned
Tier upgraded
Referral sent / Referral welcome bonus
Points redeemed
Points expiring soon
Points expired
A workflow only runs after you create and turn it on in Flow. Installing Habit does not send emails by itself — you choose the trigger and actions.
Optional webhook
Set Optional notification webhook URL in Settings → Notifications. Habit sends aPOST request with Content-Type: application/json.
The webhook runs alongside Flow, not instead of it.
Request format
Habit expects a 2xx response within 10 seconds. Non-2xx responses are retried with exponential backoff (up to 8 attempts).
eventName values
properties by event
Habit: Points Earned
Habit: Tier Upgraded
Habit: Referral Sent / Habit: Referral Welcome Bonus
Habit: Points Redeemed
Habit: Points Expiring Soon
Habit: Points Expired
Troubleshooting
I created a Flow workflow but nothing happens
I created a Flow workflow but nothing happens
Confirm the workflow is On, the trigger matches the action you expect (for example Points earned after a test order), and the customer on that order has an email. Flow only receives events Habit successfully emits — check that Habit is installed and the shop is on an active trial or paid plan.
My webhook never receives events
My webhook never receives events
Confirm the URL is HTTPS, returns 2xx within 10 seconds, and is saved in Settings → Notifications. Leave the field blank to disable the webhook. Flow and the webhook are independent — turning off the webhook does not affect Flow.
Can I use Klaviyo?
Can I use Klaviyo?
Yes — connect Klaviyo to Shopify Flow and add a Klaviyo action to a Habit trigger workflow. You do not need to install the Klaviyo Shopify app or paste API keys into Habit.