Jinja2, which is usually referred to as Jinja, is a fast and secure templating language designed for Python. In Bloomreach Engagement, it enables you to personalize your interaction with your customers. One of its main tools are placeholder values, which then, during template's rendering, get replaced with values present in Bloomreach Engagement.

📘

For example, when using the Jinja for the first name of your customer, the placeholder value -
{{ customer.firstname }} - gets replaced with the first name of your customer, if their name is already stored in Bloomreach Engagement.

Jinja serves as a powerful addition to other personalization tools in Bloomreach Engagement, such as Weblayers, Experiments, and various Campaigns. Combined together, they can help you to make your customers feel that they personally matter to your business.

Where Jinja can be used

  • Weblayers (HTML, CSS, JS)
  • Emails campaigns (Body, Subject line, Sender email, Sender name, Pre-header, UTM parameters)
  • HTML blocks
  • Scenarios such as: all Actions , Operators (Set attribute, Add event, Wait, conditions)
  • Experiments (Change, Insert, HTML)
  • Asset Manager Templates
  • Tag Manager Tags

Where Jinja CANNOT be used

  • Scenarios such as: Triggers , Operators ( AB Split, Label)
  • Surveys
  • Search
  • Filters in analytics (outside of scenarios)

👍

Using Jinja without any previous knowledge

You don't need to worry if you are not experienced with coding. Using Jinja for personalization is fairly simple and more complicated use cases will be covered step by step.

The guides in the subsections will help you understand the following:

  • How to correctly implement templates using Jinja
  • The syntax and basics of Jinja
  • More advanced variables and variable types
  • How to use Jinja to place personal values for each customer
  • How to define macros in Jinja
  • Examples of useful macros

📘

New Jinja use cases

Because Jinja is a very powerful templating language, there are surely plenty of use cases that we have not yet thought of. We would be more than happy if you could share your creative takes on using Jinja in Bloomreach Engagement with us.


Did this page help you?