Preference Based Dynamic Content

Create dynamic cmapiagn content using user consent preferences

You can create dynamic content that displays different information to users based on their specific consent preferences. This is ideal in scenarios where you need to tailor messages within a single campaign to users with varying consent preferences.

👍

To enable this feature for your project, please contact your account manager. You must also have consent management enabled on your project.

Overview

When you create a campaign, use the consent preference icon shown in the image below to create preference-based dynamic content.

Preference icon used to create preference-based dynamic content

You can then use Twig to set conditional rules for your content. If a user meets the criteria you specify, they see the conditional content. If the user does not meet the criteria, the content is either hidden or alternative content is displayed, depending on your configuration. See use cases below for more information on adding dynamic preference based content.

The location of the preference icon varies depending on the campaign:

  • For single stage campaigns across all channels except email, go to Message Text in the Content tab as shown in the image below.

    Preference icon in single stage campaigns (except email)

  • For single stage email campaigns and multistage campaigns with an email action, open the email builder and select Dynamic Content as shown in the image below. Then click Consent Preferences.

    Adding preferences in email campaigns

📘

Preview for email campaigns

For email campaigns, you can preview how the preference based dynamic content appears in the Preview tab. Select the user for whom the message will render in the User Profile tab.

You can also use the Custom Data tab within the Preview tab to change preference values to 0, 1, or null to see how the message renders for different preferences.

  • For multistage campaigns for all message actions except email, go to the Message section as shown in the image below.

    Preference icon in multistage campaigns

Use Cases

Discount promotions for marketing subscribers

In this example, you want to include a promotion in your monthly email for users subscribed to email promotions. The email content of your campaign would look like this:

Thank you for being a valued customer. This is our monthly update for October.

{% if user.preferences['promotions']['email'] %}
🎉 Exclusive 20% discount just for you! Claim here.
{% endif %}

The general email message is sent to all users:

Thank you for being a valued customer. This is our monthly update for October.

The message displayed to users whose promotions preference is set to true:

Thank you for being a valued customer. This is our monthly update for October.

🎉 Exclusive 20% discount just for you! Claim here.

Conditional content for different subscribers

This example shows how to display newsletter content to subscribers while prompting non-subscribers to sign up.

{% if user.preferences['newsletter']['email'] %}
Here’s this week’s full newsletter content.
{% else %}
You’re currently not subscribed to our newsletter.
Click here to manage your preferences.
{% endif %}

If a user is subscribed to the newsletter, the following message is displayed:

Here’s this week’s full newsletter content.

If they are not subscribed, the following message is displayed:

You’re currently not subscribed to our newsletter.
Click here to manage your preferences.

Send a summary of user preferences

This example shows how to send a summary of current preferences to your users.

Hi, here is a summary of your current communication settings: 

Email Promotions: {{ user.preferences['promotions']['email'] ? 'Yes' : 'No' }} 
SMS Offers: {{ user.preferences['offer']['sms'] ? 'Yes' : 'No' }}

Based on individual user preferences, the message displays either a yes or no for each category. For example, if a user is subscribed to email promotions but opted out of SMS offers, their message would appear as follows:

Hi, here is a summary of your current communication settings:

Email Promotions: Yes
SMS Offers: No