Tutorials

We'll walk you through adding personalized referral program messaging to your Mailjet emails.

When you connect your GrowSurf campaign to Mailjet, you can easily embed a referral program into your Mailjet emails. Check out the examples below, each with ready-made code snippets that you can copy/paste and customize to your liking.

Example 1

Display a static image in your email.

What it looks like

Copy/paste this HTML code into your Mailjet email

Customize the contents

  1. At line 11 replace PrismJar with your own brand name.

  2. At line 12, replace #1673df with your own brand color.

  3. At line 15, replace the text [[data:grsf_share_url]]%0AJoin%20PrismJar%20and%20we%20both%20get%20$10%20 with your own.

    1. Make sure to encode the message using a tool like https://www.url-encode-decode.com

    2. Make sure to include [[data:grsf_share_url]] only to the encoded message

  4. At line 17, replace the text Join%20PrismJar%20and%20we%20both%20get%20$5%20 with your own

    1. Make sure to encode the message using a tool like https://www.url-encode-decode.com

Example 2

Display a static image in your email.

What it looks like

Copy/paste this HTML code into your Mailjet email

Customize the contents

  1. At line 15, replace #e87b3c with your own brand color.

  2. At line 15, replace YOUR_CAMPAIGN_ID with your GrowSurf campaign ID (e.g, p9josq)

    1. If you set up a custom domain for your GrowSurf Referral Portal, replace the entire https://grow.surf/YOUR_CAMPAIGN_ID instead with your Referral Portal URL (e.g, https://refer.yourwebsite.com).

Example 3

Display static images in email.

What it looks like

Copy/paste this HTML code into your Mailjet email

Customize the contents

  1. At line 5, replace all instances of Cointech with your own brand name.

  2. At lines 6, 21, 30, 39, and 47, replace #4f46e5 with your own brand color.

  3. At lines 6 and 47, replace YOUR_CAMPAIGN_ID with your GrowSurf campaign ID (e.g, p9josq)

    1. If you set up a custom domain for your GrowSurf Referral Portal, replace the entire https://grow.surf/YOUR_CAMPAIGN_ID instead with your Referral Portal URL (e.g, https://refer.yourwebsite.com).

Example 4

Display a static image in your email.

What it looks like

Copy/paste this HTML code into your Mailjet email

Customize the contents

  1. At line 5, replace LearnEd with your own brand name.

  2. At line 19, replace YOUR_CAMPAIGN_ID with your GrowSurf campaign ID (e.g, p9josq)

    1. If you set up a custom domain for your GrowSurf Referral Portal, replace the entire https://grow.surf/YOUR_CAMPAIGN_ID instead with your Referral Portal URL (e.g, https://refer.yourwebsite.com).

  3. At line 19, replace #ee1152 with your own brand color.

Example 5

Display a static image in your email.

What it looks like

Copy/paste this HTML code into your Mailjet email

Customize the contents

  1. At line 19, replace #094a83 with your own brand color.

  2. At line 19, replace YOUR_CAMPAIGN_ID with your GrowSurf campaign ID (e.g, p9josq)

    1. If you set up a custom domain for your GrowSurf Referral Portal, replace the entire https://grow.surf/YOUR_CAMPAIGN_ID instead with your Referral Portal URL (e.g, https://refer.yourwebsite.com).

Example 6

Display a static image in your email.

What it looks like

Copy/paste this HTML code into your Mailjet email

Customize the contents

  1. At lines 7 and 12, replace Sips with your own brand name.

  2. At line 27, replace the text Hey!%20Do%20you%20love%20wine?%20So%20do%20I. with your own.

    1. Make sure to encode the message using a tool like https://www.url-encode-decode.com

  3. At line 33, replace the text [[data:grsf_share_url]]%0AHey!%20Do%20you%20love%20wine?%20So%20do%20I. with your own

    1. Make sure to encode the message using a tool like https://www.url-encode-decode.com

    2. Make sure to include [[data:grsf_share_url]] only to the encoded message

Example 7

Display a static image in your email.

What it looks like

Copy/paste this HTML code into your Mailjet email

Customize the contents

  1. At line 4, replace all instances of PrismJar with your own brand name.

  2. At line 8, replace #1673df with your own brand color.

  3. At line 8, replace YOUR_CAMPAIGN_ID with your GrowSurf campaign ID (e.g, p9josq)

    1. If you set up a custom domain for your GrowSurf Referral Portal, replace the entire https://grow.surf/YOUR_CAMPAIGN_ID instead with your Referral Portal URL (e.g, https://refer.yourwebsite.com).

  4. At line 12, replace https://growsurf-blog.s3.us-west-2.amazonaws.com/email-examples/boy-and-girl-giving-high-five-to-each-other.png with your own image.

Example 8

Display static images in your email.

What it looks like

Copy/paste this HTML code into your Mailjet email

Customize the contents

  1. At lines 5 and 24, replace all instances of Cointech with your own brand name.

  2. At lines 6 and 42, replace YOUR_CAMPAIGN_ID with your GrowSurf campaign ID (e.g, p9josq)

    1. If you set up a custom domain for your GrowSurf Referral Portal, replace the entire https://grow.surf/YOUR_CAMPAIGN_ID instead with your Referral Portal URL (e.g, https://refer.yourwebsite.com).

  3. At lines 6 and 42, replace #4f46e5 with your own brand color.

  4. At line 22, replace https://growsurf-blog.s3.us-west-2.amazonaws.com/illustrations/GrowSurf-steps-1.png with your own image.

  5. At line 27, replace https://growsurf-blog.s3.us-west-2.amazonaws.com/illustrations/GrowSurf-profiles-4.png with your own image.

  6. At line 32, replace https://growsurf-blog.s3.us-west-2.amazonaws.com/illustrations/GrowSurf-steps-2.png with your own image.

Example 9

Display a static image in your email.

What it looks like

Copy/paste this HTML code into your Mailjet email

Customize the contents

  1. At line 20, replace all instances of Evening Stew with your own brand name.

  2. At lines 25, 30, and 35, replace #8E4CED with your own brand color.

  3. At line 25 and 35, replace YOUR_CAMPAIGN_ID with your GrowSurf campaign ID (e.g, p9josq)

    1. If you setup a custom domain for your GrowSurf Referral Portal, replace the entire https://grow.surf/YOUR_CAMPAIGN_ID instead with your Referral Portal URL (e.g, https://refer.yourwebsite.com).

  4. At line 35, because [[data:grsf_next_milestone]]is used, make sure that any milestone rewards you have in your GrowSurf campaign have Next Milestone values set (see image. Note: This only applies to milestone rewards).

Example 10

Display different reward images based on how many referrals the participant has made.

What it looks like

Copy/paste this HTML code into your Mailjet email

Customize the contents

  1. At lines 9, 41, and 46, replace #8E4CED with your own brand color.

  2. At line 46, replace YOUR_CAMPAIGN_ID with your GrowSurf campaign ID (e.g, p9josq)

    1. If you setup a custom domain for your GrowSurf Referral Portal, replace the entire https://grow.surf/YOUR_CAMPAIGN_ID instead with your Referral Portal URL (e.g, https://refer.yourwebsite.com).

  3. At line 35, replace https://growsurf-blog.s3-us-west-2.amazonaws.com/eveningstew/0-won.png with your own image based on[[data:grsf_total_referral_count]]. In this example, you would display any one of these five images at a given time:

    1. If [[data:grsf_total_referral_count]] <3, then display this image.

    2. If [[data:grsf_total_referral_count]] >=3 and <5, then display this image.

    3. If [[data:grsf_total_referral_count]] >=5 and <10, then display this image.

    4. If [[data:grsf_total_referral_count]] >=10 and <20, then display this image.

    5. If [[data:grsf_total_referral_count]] >=20, then display this image.

  4. At line 51, because [[data:grsf_next_milestone]] is used, make sure that any milestone rewards you have in your GrowSurf campaign have Next Milestone values set (see image. Note: This only applies to milestone rewards).

Example 11

Display a GIF image with rotating rewards in your email.

What it looks like

Copy/paste this HTML code into your Mailjet email

Customize the contents

  1. At lines 10 and 21, replace Evening Stew with your own brand name.

  2. At line 21, replace all instances of#8E4CED with your own brand color.

  3. At line 21, replace YOUR_CAMPAIGN_ID with your GrowSurf campaign ID (e.g, p9josq)

    1. If you setup a custom domain for your GrowSurf Referral Portal, replace the entire https://grow.surf/YOUR_CAMPAIGN_ID instead with your Referral Portal URL (e.g, https://refer.yourwebsite.com).

  4. At line 15, replace https://growsurf-blog.s3-us-west-2.amazonaws.com/eveningstew/rewards-inline.png with your own GIF image (you can use a tool like https://ezgif.com/maker).

Example 12

Display a static image in your email.

What it looks like

Copy/paste this HTML code into your Mailjet email

Customize the contents

  1. At lines 10 and 15, replace Husto with your own brand name.

  2. At lines 20 and 30, replace #F46A54 with your own brand color.

  3. At line 30, replace YOUR_CAMPAIGN_ID with your GrowSurf campaign ID (e.g, p9josq)

    1. If you setup a custom domain for your GrowSurf Referral Portal, replace the entire https://grow.surf/YOUR_CAMPAIGN_ID instead with your Referral Portal URL (e.g, https://refer.yourwebsite.com).

Example 13

Display a static image with text next to it.

What it looks like

Copy/paste this HTML code into your Mailjet email

Customize the contents

  1. At line 8, replace the entire https://husto.com?grsf=abc123 instead with your Referral Portal URL (e.g, https://refer.yourwebsite.com).

  2. At line 8, replace #F46A54 with your own brand color.

Last updated

Was this helpful?