Add personalization
- Topics:
- Personalization
CREATED FOR:
- Intermediate
- Developer
The personalization editor is the centerpiece of the personalization in Journey Optimizer. It is available in every context where you need to define personalization like emails, push and offers.
In the personalization editor interface, you can select, arrange, customize and validate all the data to create a customized personalization for your content.
Where can I add personalization
You can add personalization in Journey Optimizer in every fields with the
Messages
In messages, personalization can be added at different locations in your messages, such as the Subject line field.
It can also be added in other sections of your content. For example, for push notifications, personalization can be added in Title, Body, Custom sound, Badges and Custom data fields.
Email Designer
When editing email content in the Email Designer, you can add personalization in text blocks and in URLs using the icon in the contextual tool bar.
Offers
You can add personalization when using text-type content in your offers’ representations. Learn how to create personalized offers
URLs
Journey Optimizer also allows you to personalize URLs in your message. Personalized URLs take recipients to specific pages of a website, or to a personalized microsite, depending on the profile attributes. URL personalization is available for these types of links: External link, Unsubscription link and Opt-Out.
https://www.adobe.com/users/{{profile.person.name.lastName}}
https://www.adobe.com/users?uid={{profile.person.name.firstName}}
https://www.adobe.com/usera?uid={{context.journey.technicalProperties.journeyUID}}
https://www.adobe.com/users?uid={{profile.person.crmid}}&token={{context.token}}
Personalization sources
The left part of the screen displays a domain selector that lets you select the source for personalization. Available sources are:
- Profile attributes : lists all the references associated to the profile schema described in Adobe Experience Platform Data Model (XDM) documentation.
- Audiences : lists all the audiences created in Adobe Experience Platform Segmentation service. More information on segmentation available here.
- Offer decisions : lists all the offers associated to a specific placement. Select the placement then insert the offers in your content. For a complete documentation on how to manage offers, refer to this section.
- Contextual attributes : when a channel action activity (Email, push, SMS) is used in a journey or campaign, contextual attributes related to events and properties are available for personalization. An exemple of personalization leveraging contextual attributes is presented in this section.
Add personalization
The central workspace is where you build your personalization syntax. To use an attribute to personalize your message, locate it into the left navigation pane and click the +
button to add it into the expression.
The ellipsis menu next to the +
icon allows you to get more details for each attribute and to add your most frequently used attributes to favorites. Attributes added to favorites are accessible from the Favorites menu in the left navigation pane.
Additionally, you can define default fallback text that will display if a string-type profile attribute is empty. To do this, click the ellipsis button next to the attribute and select Insert with fallback text. Write the text that should display by default if the attribute’s value is empty for a profile then click Add.
In the following example, the personalization editor lets you select the profiles that have their birthday today then complete the customization by inserting a specific offer corresponding to this day.
Tools for expression editing
The central workspace provides various tools to help you write your personalization expression.
Available options are:
-
Find / Find and replace: Search through your expression and automatically replace portions of code.
-
Undo / Redo: Undo / Redo the last operation.
-
Auto complete: Automatically suggests and completes code as you type. This feature is available only for HTML and Text formats and supports Profile and Context attributes. If disabled via the toggle, the editor will provide native HTML code auto-completion instead.
-
HTML / JSON / Text: Identify the format of your code. This allows the system to adapt the validation and auto complete feature based on the selected language.
-
Validate: Check the syntax of your expression. Learn more in this section.
-
Save as fragment: Save your expression as an expression fragment. Learn more in this section
-
Font size: Adjusts the font size for the contents inside the editor for better readability.
-
Word wrap: Enables or disables word wrapping, allowing long expressions to be displayed on a single line or wrapped within the editor. Options include:
- Off (Default) - No word wrapping. Long lines extend beyond the editor view and require horizontal scrolling.
- On - Wraps lines at the width of the editor.
- Word wrap column - Wraps lines when a line characters reach 80 characters.
- Bounded - Wraps lines at either the editor width or at 80 characters, whichever is smaller.
In the navigation pane, additional features are available to help you build your personalization expression.
-
Helper functions - Helper functions allow you to perform operations on data, such as calculations, data formatting or conversions, conditions, and manipulate them in the context of personalization. Learn more on available helper functions
-
Favorites - Attributes that you have added to favorites display in this list. This allows you to quickly access to your most frequency used items. To add an attribute to your favorites, click the ellipsis menu and choose Add to favorites.
-
Conditions - Leverage conditional rules created in the library to add dynamic content into your messages. This allows you to create multiple variants of your message based on conditions. Learn how to create dynamic content
-
Fragments - Leverage expression fragments that have been created or saved to the current sandbox. A fragment is a reusable component that can be referenced across Journey Optimizer campaigns and journeys. This functionality allows to prebuild multiple custom content blocks that can be used by marketing users to quickly assemble contents in an improved design process. Learn how to use expression fragments for personalization
Once your personalization expression is ready, you need to have it validated by the personalization editor. Learn more in this section.
Validation mechanisms
The validation of your expression is automatically executed when you click on the Add button to close the editor window. You can also use the Validate button to check your personalization syntax.
Expand the section below to see common errors that may occur when validating personalization.
- Path “XYZ” not found
When trying to reference a field that is not defined in the schema.
In this case firstName1 is not defined as attribute in the profile schema:
{{profile.person.name.firstName1}}
- Type mismatch for variable “XYZ”. Expected array. Found string.
When trying to iterate over a string instead of array.
In this case product is not an array:
{{each profile.person.name.firstName as |product|}}
{{product.productName}}
{{/each}}
- Invalid handlebars syntax. Found
‘[XYZ}}’
When invalid handlebars syntax is used.
Handlebars expressions are surrounded with {{expression}}
{{[profile.person.name.firstName}}
- Invalid segment definition
No segment definition found for 988afe9f0-d4ae-42c8-a0be-8d90e66e151
For offers, specific errors may occur. Expand the section below for more details:
The errors related to offers integration in an Email or Push message have the following pattern :
Offer.<offerType>.[PlacementID].[ActivityID].<offer-attribute>
The validation is performed during personalization content validation in the personalization editor.
Resource with id activityID and type OfferActivity not found
Image: deliveryURL, linkURL
Text: content
HTML: content