Skip to content

Pulling user profile data

If a Connected Content response contains user profile fields (within a Liquid personalization tag), these values must be defined earlier in the message via Liquid, before the Connected Content call in order to render the Liquid passback properly.

Similarly, the :rerender flag must be included in the request. Note that the :rerender flag is only one level deep, meaning that it will not apply to any nested Connected Content tags.

For personalization, Braze pulls user profile fields before passing that field to Liquid—so if the response from Connected Content has user profile fields, it must be defined beforehand.

For example, if this were the Connected Content call:

1
2
Hi ${first_name},
{% connected_content https://examplewebsite.com :rerender %}

And the Connected Content response is Your language is ${language}, the content displayed in this scenario will be Hi Jon, your language is. The language itself will not be templated. This is because Braze needs to know what fields to retrieve from the user before we make the Connected Content call.

In order to render the Liquid passback properly, you must put the ${language} tag anywhere in the request, as shown in the following code snippet. The Liquid preprocessor will know to grab the “language” attribute from the user to have it ready for templating the response.

1
"Hi ${first_name}, {% connected_content https://examplewebsite.com?language=${language} :rerender %}
HOW HELPFUL WAS THIS PAGE?
New Stuff!