Skip to main content
Templates are the content block of your notification. In SuprSend, content for all channels (SMS, email, chat, push etc.) is grouped under a single template group for simplified management. Your template can have 2 types of content:
  • Static Content: This remains the same for all users and contains your core message or design.
  • Dynamic Content: These are placeholders for user or tenant-specific information, such as first names, booking amounts, appointment times, and more. The variables are populated dynamically based on the data provided in your workflow or event request.
  • Unified Content Management: Content for all channels is grouped together in a single template, making it easy to manage your content in one place.
  • WYSWYG editors: Designing a template is a piece of cake with drag-and-drop and form editors. Your product managers and designers can take control of content creation without involving developers.
  • Multi-Lingual support: You can add content for multiple languages in a single template and the user will receive notification in their preferred language
  • Create white-labeled notifications for your tenants with ease: You can create tenants for your own company and each of your tenants. Use it to dynamically change your email template styling to match the tenant’s identity.
  • Easy to iterate: You can directly design and store templates on the SuprSend dashboard, decoupling templates from your code.
  • Version control: Each template change is published as a new version, so you can always track historical changes. You can also monitor user engagement for each version and retain the one that performs better. Trigger a test notification on your current live version to see the content preview on your actual device before pushing it to production.
  • Add / Remove channels without touching code: To add any channel to your existing template group, you need to simply design a template for that channel on SuprSend platform and publish it. Notifications will start going through that channel, with no alterations to your existing code.

Create Template

SuprSend’s template designer empowers you to create beautiful templates with easy drag-and-drop editor
1

Create a template

Add a template name and Click on ‘Save’.The new Template will be created, which you can see on the top of ‘Templates’ listing page. Click on the template to start editing.
2

Select the Channel

Select the channel that you want to edit and enable it.
3

Add template content

You can get the detailed guide to design the template for each channel in their respective documents: Push channels: Chat:

Template versions

SuprSend creates a new version every time you publish a template. This is to ensure that you have historical reference to all the changes done in your template. Helps with audit trails and understanding which template content performed better in terms of user engagement.
  • A draft version is created by default. You’ll always do your changes in the draft version and publish the template once finalized.
  • The recent published template will become the live version . All your notifications will be using the live template version.
  • Earlier published versions will become inactive as soon as you publish a new template. You can see inactive template versions by selecting ‘All’ tab from the top right side options.

Adding variable content

SuprSend supports dynamic templating so you can personalize notifications using data from your workflow, user profile, and tenant settings. Templates use two languages:
  • Handlebars — Email, SMS, WhatsApp, and Inbox
  • JSONNET — Slack and MS Teams
To start using dynamic variables, first add sample data in the Mock Data panel of the template editor.

1. Add mock data

Mock data helps you:
  • Define the structure of variables up front, reducing mismatches between the template and actual payload.
  • Get auto-suggestions while designing templates, avoiding typos.
  • Consistently reuse the same variables across all channels within a template.
  • Preview the final rendered notification and send test messages using sample values.
Sample mock data:
{
  "name": "Steve",
  "items": [
    {
      "item": "Jager-Smith Premium",
      "tracking_id": "FMPP14677458796",
      "delivery_date": "22 June, 2023"
    },
    {
      "item": "Winget Women Cap",
      "tracking_id": "FMPP7734374844765",
      "delivery_date": "23 June, 2023"
    }
  ],
  "amount": "$3,249",
  "tracking_link": "https://www.example.com/track"
}

2. Available data types and their syntax

There are four primary sources of dynamic data you can pull into your templates.

Input Payload

This includes:
  • Data from your trigger payload
  • Data added or modified during the workflow via data transform, batch/digest, webhook/fetch, etc.
Referring this data in the template as:
Data TypeHandlebarsJSONNET
Parent level keys{{var1}}data.var1
Nested keys{{var1.var2.var3}}data.var1.var2.var3
Array index{{var1.[0].name}}data.var1[0].name
Keys with capital letters and spaces{{[first_name]}}data['first_name']
Batching data{{$batched_events_count}}data['$batched_events_count']
For more advanced logic or complex functions, refer to the full set of available options in the Handlebars Helpers documentation.
Please wrap URLs or variables that may contain special characters in triple curly braces (e.g., {{{url}}}). Using double braces triggers HTML-escaping in Handlebars, which may alter special characters.

User properties

For per-user personalization, you can use user properties in your templates. These properties are automatically available from each user’s profile and can be referenced using $user, $actor or $recipient variables.
HandlebarsJSONNET
$user.namedata['$user'].name
$recipient.namedata['$recipient'].name
$actor.namedata['$actor'].name

Tenant properties

If you are using tenant branding, you can include tenant properties in your templates to dynamically display details such as logo, address, and colors. The email designer also provides a Tenant component with pre-designed header, footer, and button, making it easier for you to add tenant branding to your templates.
HandlebarsJSONNET
$tenant.namedata['$tenant'].name
$tenant.properties.addressdata['$tenant'].properties.address

Preview and publish

You can see the notification preview on the right side of your editor for most of the channels. Variables in template are replaced with the values from ‘mock data’ for preview For email, preview option is available in the bottom left side menu For Slack, you can click on ‘Load preview’ button to see the preview Once finalized, you can publish the template by clicking on ‘Publish template button on the draft version

Test template

You can send test notifications directly from the template editor page to see how the message will appear on user’s device. To send a test notification,
1

Click on the "Test" button

You can find the Test button on the top right corner.
2

Add Distinct ID

Add the distinct_id of the user, and click on search. It will show all the available channels for the user.
3

Choose the relevant channels

Select those channels on which you’d like to test, and then click on Trigger Test using mock data . This will trigger a test notification.
4

Go to Logs

You can go to the logs in order to monitor the real-time status of your sent notification.
JSON data added in the global “Mock Data” button will be used to render variables in the template. Make sure to add mock data for all the variables added in the template else notifications will fail. ** Defining template in your workflow request ** The serves as a unique identifier for referencing a template in workflows created through API. To copy the slug name, click on the clipboard next to the Template name. ** Edit template name and other details ** You can edit the template description, name, and add tags to the template by clicking on the edit icon next to the its name.
  • We recommend adding your template trigger logic and other relevant notes pertaining to the notification in the description . This is helpful for later reference and note keeping.
  • Tags are used for better organization of the templates on listing page. You can group similar templates using tags. Tags can then be used to filter out templates on listing page and also while fetching templates through API.

Clone template

To avoid designing templates from scratch, you can clone your existing templates and design on top of it.

Adding multiple languages

SuprSend allows you to create notifications in multiple languages in the same template. Once the languages are added, SuprSend will pick the preferred language from user’s profile and send the message as per the user’s preferred language. You can add template languages using Language option from the top-right corner burger menu. For more details, check steps and guidelines on adding language.

Archive template

You can archive your unused templates by clicking on “Archive” option from the top-right corner burger menu. Templates can’t be recovered once archived.

View and filter your template list

All of your active templates will be visible on the template listing page. You can filter your templates by channel, tag, status or just get the templates which were ‘edited by you’. Archived templates can be seen by clicking on Archived tab from the top right side options