Handlebars Powered

TemplatesThatScaleWithYou

Design once, deliver everywhere. Sendivent's template engine supports rich personalization, conditional logic, and real-time preview across all channels.

Rich Personalization

Insert user data, format dates, and build dynamic content with Handlebars helpers.

Multi-Channel Support

Same template syntax works across email, SMS, Slack, and push notifications.

Live Preview

See exactly what users will receive before you send.

No Deploy Required

Update templates through the dashboard without code changes.

Version History

Track changes and rollback to previous versions instantly.

Conditional Logic

Show different content based on user attributes or payload data.

See it in action

Handlebars
<!-- Email template with personalization -->
<h1>Welcome, {{user.name}}!</h1>

{{#if user.meta.isPremium}}
  <p>Thanks for choosing our Premium plan!</p>
{{else}}
  <p>Start your free trial today.</p>
{{/if}}

<p>Your account was created on {{formatDate createdAt "MMMM D, YYYY"}}</p>

The Power of Smart Templates

Templates are the bridge between your application and your users. Sendivent's template engine makes it easy to create personalized, professional notifications without touching code every time content changes.

Handlebars: Simple Yet Powerful

Handlebars templates use a straightforward syntax that's readable and maintainable:

Hello {{user.name}},

Your order #{{payload.orderNumber}} has shipped!

Tracking: {{payload.trackingNumber}}
Carrier: {{payload.carrier}}

Expected delivery: {{formatDate payload.estimatedDelivery "dddd, MMMM D"}}

Built-In Helpers

Sendivent includes helpers for common formatting needs:

Helper Example Output
formatDate {{formatDate date "MMM D"}} "Jan 15"
formatCurrency {{formatCurrency amount "USD"}} "$99.00"
uppercase {{uppercase status}} "SHIPPED"
lowercase {{lowercase text}} "hello"
pluralize {{pluralize count "item"}} "3 items"

Conditional Content

Show different content based on user attributes or payload data:

{{#if user.meta.isVip}}
  <p>As a VIP member, you get priority support!</p>
{{/if}}

{{#unless payload.isFree}}
  <p>Total charged: {{formatCurrency payload.amount "USD"}}</p>
{{/unless}}

{{#eq user.language "es"}}
  <p>¡Gracias por tu compra!</p>
{{else}}
  <p>Thanks for your purchase!</p>
{{/eq}}

Channel-Specific Templates

Each notification channel has its own template, optimized for that medium:

Email Templates

  • Full HTML support with inline CSS
  • Automatic plain-text version generation
  • Subject line personalization
  • Preview text (preheader) support

SMS Templates

  • Character count tracking
  • Smart link shortening
  • Unicode/emoji support
  • Segment calculation

Slack Templates

  • Block Kit formatting
  • Button and action support
  • Channel or DM delivery
  • Rich media attachments

Template Management

Dashboard Editor

Our visual editor makes template management simple:

  1. Syntax highlighting for Handlebars expressions
  2. Live preview with sample data
  3. Error detection before saving
  4. Test send to your own channels

Version Control

Every template change is tracked:

  • View the full history of changes
  • Compare any two versions
  • Rollback with one click
  • See who made each change

No Code Deploys

Update notification content without engineering involvement:

  • Marketing can update copy
  • Support can fix typos
  • Product can A/B test messaging
  • All without a code deploy

Advanced Features

Template Inheritance

Create base templates and extend them:

{{!-- base-email.hbs --}}
<html>
  <body>
    {{> header}}
    {{{body}}}
    {{> footer}}
  </body>
</html>

Partials

Reuse common elements across templates:

{{!-- In any template --}}
{{> order-summary order=payload.order}}
{{> cta-button text="Track Order" url=payload.trackingUrl}}

Data Transformations

Transform data before rendering:

{{!-- Format array of items --}}
{{#each payload.items}}
  - {{this.name}}: {{formatCurrency this.price "USD"}}
{{/each}}

{{!-- Calculate totals --}}
Subtotal: {{formatCurrency (sum payload.items "price") "USD"}}

Frequently asked questions

What template language do you use?

We use Handlebars, a widely-adopted templating language. If you've used Mustache templates, you'll feel right at home.

Can I use HTML in email templates?

Yes, email templates support full HTML with inline CSS. We also handle automatic plain-text generation for accessibility.

How do I test templates before sending?

Use our live preview feature in the dashboard, or send test notifications to yourself with sample data.

Can templates access user metadata?

Yes, all user fields including custom metadata are available in templates via the user object.

Ready to get started?

Experience templates that scale with you with Sendivent's powerful API.