Menu
Accedi Crea account
Templates

Reusable templates.

Centralise HTML, subject and variables in versioned templates. Your code only sends the variables.

Syntax

We use a Jinja-like syntax (safe, sandboxed). Variables {{ name }}, conditionals {% if ... %}, loops {% for x in list %}, filters {{ total|currency('EUR') }}, {{ date|date('Y-m-d') }}.

Example: order confirmation

// Template "order_confirmation"
Subject: Order #{{ order.number }} confirmed
HTML:
  

Hi {{ customer.name }},

Your order #{{ order.number }} is confirmed.

    {% for item in order.items %}
  • {{ item.qty }}x {{ item.title }} - {{ item.price|currency('EUR') }}
  • {% endfor %}

Total: {{ order.total|currency('EUR') }}

Call with: POST /v1/messages + template_id, template_vars.

Versioning + A/B

Every template has a current version (the one in production) and historical versions. For A/B tests you activate two variants (A and B) with a percentage split. Delivery, open and click metrics are tracked separately per variant in the panel.

Features