Skip to main content

Klaviyo flows: Sending reward notifications

Sample Klaviyo flows for detected referred purchases, earned rewards and ineligible purchases.

Written by Adam

ReferralCandy sends out reward notification emails for pending, successful, and ineligible rewards. If you want to send the reward emails via Klaviyo, you can use ReferralCandy events and custom properties to set up your own reward notification flows.

Before you begin setting up flows, we recommend you first read the Klaviyo integration overview and ReferralCandy custom properties articles.

To learn more about flows, read Getting started with flows on the Klaviyo help center.

Campaign-specific properties: each campaign has its own short code. Insert profile properties using Klaviyo's Personalization picker and select the intended campaign. Event variables come from the event that triggered the flow; preview them with a matching event. The short codes and email copy below are examples to adapt, not values to paste unchanged.


Reward notification flows

The flows below cover a referred purchase being detected, a reward being earned, and a referred purchase becoming ineligible. Purchase detection alone does not mean the purchase is approved or a reward is earned. Use RC - Reward pending if you want to notify the advocate specifically that a qualifying referral is in review. It includes reward details and the initial review deadline, but that deadline can change and its coupon code can be None. Choose either a detection notice or a pending-reward notice for this stage to avoid sending both. See the event reference for the fields.

Avoid duplicate emails: set up and test each Klaviyo replacement first. When it is ready to send, open the relevant ReferralCandy campaign's Emails page and turn off only the equivalent Pending reward emails, Successful reward emails or Ineligible reward emails. See campaign email settings.

Successful reward emails also controls referral-progress emails. Turning it off stops both; the three recipes below do not provide a separate referral-progress flow. Account for that before switching it off. Cash payout emails is a separate control. Learn about reward and referral-progress emails.

For each flow: select the metric listed below, then add a Campaign name trigger filter with equals and your intended campaign name (type Text). Events can come from different campaigns, including loyalty campaigns for reward-earned events, so do not leave the referral flow unfiltered. After renaming a campaign, check and update its Klaviyo Campaign name filters to match.

Check Re-entry criteria: choose Allow re-entry if the advocate should receive a notification for each matching event. No re-entry limits a profile to one entry in that flow. Preview with a matching event and profile, check all links and reward details, and test the email before making it live.

For buttons, use the campaign's Portal link property and open the rendered URL in preview. If it is missing, resolve it before sending. click here is button text, not a valid URL fallback.

Referred purchase detected

This recipe uses RC - Purchase referred by profile detected to acknowledge a referred purchase. It is not a confirmation of reward eligibility. Adapt the wording to your review period and reward conditions.

  1. Trigger

    • Metric (API): RC - Purchase referred by profile detected

  2. Email

    • Draft your email content and insert custom properties. Use the short code you've set for your live campaign when using custom properties. Learn more

    • In the email editor, you can utilize the following event variables that are sent together with the event:

      • {{ event|lookup:'Campaign name' }}

      • {{ event.Currency }}

      • {{ event|lookup:'Purchase amount' }}

  3. End

Purchase-detected sample template

Illustrative template: adapt the copy and fields to your campaign. The examples are not active offers.


Great news {{ person|lookup:"RC FREN - Name"|default:'' }}, you referred someone!

Someone you referred made a purchase of {{ event.Currency }} {{ event|lookup:'Purchase amount' }}. It may count towards your reward once it is approved and meets the program's reward conditions.

GET LINK*


*The GET LINK button block uses the link address: {{ person|lookup:"RC [Short code] - Portal link" }}. Make sure to use your campaign short code.

Reward earned email

To send an email notification to an advocate when they earn a reward, replicate the following setup and make tweaks as needed. RC - Reward earned can also fire for a no-reward tier with only Campaign name. That event has no reward details to include in this email. Check the event data before sending: the coupon message below needs Reward type equal to coupon and a usable Coupon code, not a missing value or the text None. Keep events without the required reward data out of the reward-email step.

  1. Trigger

    • Metric (API): RC - Reward earned

  2. Email

    • Draft your email content and insert custom properties. Use the short code you've set for your live campaign when using custom properties. Learn more

    • In the email editor, you can utilize the following event variables that are sent together with the event:

      • {{ event|lookup:'Campaign name' }}

      • {{ event|lookup:'Date earned' }}

      • {{ event|lookup:'Reward type' }}

      • {{ event|lookup:'Coupon code'|default:'' }}

      • {{ event|lookup:'Coupon expiry date' }}

      • {{ event|lookup:'Reward amount' }}

      • {{ event|lookup:'Reward currency' }}

  3. End

Note: Event variables vary depending on which reward type is currently selected for your referral program. Preview using an event for the reward type you intend to send. The sample below matches the image: a 20% coupon reward. Replace the sample percentage with the actual discount for the campaign and reward tier receiving this email. Do not use this percentage wording for a fixed-amount coupon. Coupon code and expiry fields do not apply to every reward type. For cash, store credit or custom rewards, write a matching message using the fields available on that event. Date earned and a populated Coupon expiry date are Unix timestamps. Format them before displaying them in an email. The sample below includes the expiry sentence and hides it when the expiry is missing or None. Preview the rendered date and compare it with the coupon's actual expiry, including its time zone. A coupon without expiry can send the literal text None; a blank-value fallback does not remove that text. Reward issuance can happen after purchase approval, so trigger this email from RC - Reward earned rather than promising a coupon as soon as a purchase is approved.

Coupon reward sample template

Illustrative template: adapt the copy and fields to your campaign. The examples are not active offers.

The image and copy below illustrate the same 20% coupon offer. 20% is sample campaign copy, not an event variable. Replace it with your actual coupon discount. The name, coupon code and expiry are personalized; the expiry line is shown only when an expiry value is present and is not None.

Illustrative coupon-reward email with sample discount, coupon code and expiry date.

Thanks for the referral!

Awesome news, {{ first_name|default:'friend' }}. You've earned a reward for referring friends!


Here's your reward: coupon for a 20% discount: {{ event|lookup:'Coupon code' }}

{% if event|lookup:'Coupon expiry date' and event|lookup:'Coupon expiry date' != 'None' %}

Coupon expires on: {{ event|lookup:'Coupon expiry date'|format_date_string|date:'F d, Y' }}.

{% endif %}

REFER MORE FRIENDS*


*The REFER MORE FRIENDS button block uses the link address:

{{ person|lookup:"RC [Short code] - Portal link" }}. Make sure to use your campaign short code.

The {% if ... %} and {% endif %} tags control the expiry line and do not appear in the sent email. Use Klaviyo's conditional logic in the text editor or an HTML block. Preview with matching reward events both with and without an expiry date. Check the discount, name, code and expiry against the intended offer before sending.

Reward disqualified email

To send an email notification to an advocate when their referred purchase is ineligible, replicate the following setup and make tweaks as needed.

  1. Trigger

    • Metric (API): RC - Purchase referred by profile made ineligible

  2. Email

    • Draft your email content and insert custom properties. Use the short code you've set for your live campaign when using custom properties. Learn more

    • In the email editor, you can utilize the following event variables that are sent together with the event:

      • {{ event|lookup:'Campaign name' }}

      • {{ event.Reason }}

  3. End

Ineligible purchase sample template

Illustrative template: adapt the copy and fields to your campaign. The examples are not active offers.

Illustrative ineligible-referral email with a reason and a button to continue referring.

Sorry to let you know

We are sorry to let you know a recent purchase made by someone you referred has been disqualified for the following reason:

{{ event.Reason }}

Unfortunately that means it no longer counts towards a referral reward.

If you believe this might be an error, let us know.

REFER MORE FRIENDS*


*The REFER MORE FRIENDS button block uses the link address:

{{ person|lookup:"RC [Short code] - Portal link" }}. Make sure to use your campaign short code.


Troubleshooting

If a custom property renders blank in your email, see Why is my Klaviyo email sending a blank referral link (or any blank ReferralCandy custom property)? in the property reference for the diagnostic flow.

Did this answer your question?