Write Your First Template
Email templates in Synapse use NLT (Natural Language Template) syntax -- a plain-English way to personalize emails. Instead of writing code, you write something that reads like a sentence. This guide shows you how to create a simple personalized email template.
Step 1: Create a New Template
- In the dashboard sidebar, click Templates.
- Click Create Template in the top right corner.
- Fill in the basic details:
| Field | Example | Description |
|---|---|---|
| Name | Welcome Email | A friendly name for your team |
| Subject | Welcome to our platform, {the user's First Name}! | The email subject line (supports NLT) |
| From Name | PYRX Support | The sender display name |
| From Email | [email protected] | Must use a verified sender domain |
| Reply To | [email protected] | Optional reply address |
Step 2: Write the Email Body
The editor has two panes: the HTML editor on the left and a live preview on the right. As you type, the preview updates in real time with sample data.
Here's a simple template to start with:
Step 3: Add Personalization
NLT expressions are wrapped in curly braces { }. Here are the most common patterns:
Pull in a Contact's Name
This inserts the contact's first name. If the contact doesn't have a first name on file, it will show as blank.
Add a Fallback Value
If the first name is missing, "there" is used instead. So the greeting becomes "Hi there," which is much better than "Hi ,".
Use Trigger Event Data
When your template is used in a flow, you can pull data from the event that triggered the flow:
Use the Variable Picker in the template editor to browse available fields. Click a variable to insert it into your template without having to remember the exact syntax.
Step 4: Add a Simple Conditional
You can show different content to different people. For example:
The conditional checks the contact's data, and only shows the matching section.
Step 5: Preview and Test
- Click the Preview tab to see your template rendered with sample data.
- Use the Test Data panel to change sample values and see how the template behaves with different inputs (missing names, different plans, etc.).
- Click Send Test Email to send a real email to your own address and verify it looks right in your email client.
Always send a test email before using a template in a live flow. Email clients can render HTML differently than the preview pane.
Step 6: Save and Publish
- Click Save Draft to save your work without making it available to flows.
- When you're satisfied, click Publish to make the template available for use in flows.
- Published templates are versioned -- if you edit a published template later, a new version is created.
Common Patterns
Here are a few patterns you'll use often:
Greeting with Fallback
Required Data (Suppress Email if Missing)
If the reference number is missing, the email is not sent at all -- preventing incomplete or confusing messages from reaching the contact.
Formatting Numbers and Dates
For a full reference of NLT syntax including loops, filters, math, and more, see the Templates & NLT section of the Help Center.
Next Steps
Now that you have a template, you can:
- Create a flow that uses this template
- Explore Variables for all the ways to pull in data
- Learn about Conditionals for advanced personalization
- See Template Examples for real-world patterns
Looking for the API?
If you prefer to create and manage templates programmatically, see the Templates API Reference.