Last modified December 1, 2022 by Shelly Wolfe

Campaign personalization

Include dynamic, personalized content in your campaigns and create a more relevant and contextual experience for your customers with Swrve’s campaign personalization.

Swrve’s rich customer profile data includes both default and custom user properties that give you a current and detailed picture of your users’ status. These user properties are then available for injecting personalized details into your campaign content, such as a customer’s name, a flight destination city, a favorite team, or a personalized coupon code. The process to create a tailored, personalized experience for your users is now easier than ever!


Prerequisites

The manner by which Swrve personalizes your campaign content depends on the campaign channel and how a campaign is delivered to a user’s device. To make user properties available in triggered campaigns, such as in-app messages or push via API, the Swrve SDK downloads a pre-configured set of user properties that it then uses to personalize the content of a campaign at the moment it’s triggered. Before you can personalize campaigns with realtime properties, you and your development team must complete the following:

  • Upgrade your app to the latest Swrve SDK that supports realtime personalization.
  • Implement custom properties in your app and then configure the realtime user properties you want to use for personalization purposes. For more information, see Manage user properties or contact your CSM at support@swrve.com for assistance.

Image personalization

Swrve supports image personalization in your in-app message campaigns as of iOS SDK version 7.0.0, Android SDK version 8.0.0, and Unity SDK version 8.0.0.


Personalization properties

As explained above, some types of campaigns use any default or custom property that your app sends to Swrve to personalize message content. As soon as Swrve receives the user property, it is immediately available for use in your campaigns. These campaign types include:

  • Scheduled push notifications
  • Triggered push notifications
  • Email
  • SMS

Other campaigns use realtime user properties to download the property values to the user’s device ahead of time and then inject the personalized campaign content at the moment the user triggers the campaign. Realtime user properties are available for use in campaigns as soon as you configure them. These campaign types include:

  • In-app messages
  • Push via API campaigns
  • Embedded campaigns

Additionally, triggered push campaigns also support using the payload values from the campaign trigger event.

Campaign channel Realtime properties Custom properties Trigger event payload values
Scheduled push X
Triggered push X X
Push via API X
In-app messages X
Embedded campaigns X
Email and SMS X

Personalize your campaign content

The process for personalizing your campaigns with user properties is the same, regardless of channel and campaign type. There are two ways to insert a user property in your campaign content:

  • Select the property using the Insert property dialog
  • Manually insert the property as text, using Swrve’s personalization syntax

Insert property dialog

To insert the user property using the Insert property dialog:

  1. On the Content screen of the campaign workflow, move your cursor to the point in the text where you want to insert personalized content and select Insert property.
  2. In the Insert a user property dialog, enter part or all of the custom property name in the Select item box and then select the property from the list of values.
  3. To include fallback text that displays if a user doesn’t have a value for the custom property, select Add custom text and then enter the fallback value. Or select Don’t show if you don’t want the content to display for that user.

The following examples demonstrate how to personalize your campaign content by including the customer’s name or coupon code.

Push notification (Batch and Push via API)

Place your cursor at the point in your text that you want to insert a user property. Select the lightning bolt icon, and then in the user property dialog, select your property from the list. You also have the option to include fallback text that displays if a user doesn't have a value for the selected property.
When testing a scheduled push notification that has personalized campaign content but does not contain fallback values, sample is inserted into the content.

Push notification (Triggered)

Triggered push notifications also include the option to personalize your content with payload values from the campaign trigger event.

To insert a trigger event’s payload value into your push notification content:

  1. In the Insert property dialog, select Trigger event payload values.
  2. In the Select event list, select the event you want to use to trigger the campaign.
  3. Next, in the Payload list, select the payload key you want to use to personalize your content.
  4. Optionally, include fallback text that displays if a user triggers the event without the specified payload key.

Insert event trigger payload value into campaign content.

You must use the same event to trigger your campaign, so once you select a trigger event for personalization, you’re limited to using payloads from the same event. However, there is no limit when personalizing your content with custom properties.

In-app message

Note that while the steps to personalize image URLs and single line text values are the same, the device preview renders personalized single line text and personalized images differently.

Single line text

When personalizing single line text values, the device preview value displays sample as a placeholder value. If you provide a fallback text value, that value replaces sample in the preview.

Place your cursor at the point in your text that you want to insert a user property. Select the lightning bolt icon, and then in the user property dialog, select your property from the list. You also have the option to include fallback text that displays if a user doesn't have a value for the selected property.

Images

When personalizing image URLs, the device preview displays a placeholder image. If you provide a fallback value, Swrve displays that image in the device preview.

Place your cursor at the point in your text that you want to insert a user property. Select the lightning bolt icon, and then in the user property dialog, select your property from the list. You also have the option to include fallback text that displays if a user doesn't have a value for the selected property.

Similarly, if you provide a separate fallback image, that image replaces the placeholder image in the preview.

Drag and drop fallback image file onto fallback image field. This image replaces the placeholder in the device preview.Embedded campaigns

Insert user property and fallback text into JSON content.

Email

Place your cursor at the point in your text that you want to insert a user property. Select the lightning bolt icon, and then in the user property dialog, select your property from the list. You also have the option to include fallback text that displays if a user doesn't have a value for the selected property.

SMS

Place your cursor at the point in your text that you want to insert a user property. Select the lightning bolt icon, and then in the user property dialog, select your property from the list. You also have the option to include fallback text that displays if a user doesn't have a value for the selected property.

Insert as text using Swrve’s personalization syntax

When sending or creating campaigns via API or in bulk, use Swrve’s personalization syntax to include a dynamic user property value in your content:

${user.<custom_property_key>}

To include fallback text that applies if a user doesn’t have a value for the custom property, add a fallback parameter:

${user.<custom_property_key>|fallback="<text>"}


Next steps