Skip to main content

Email Templates

Templating allows users to save commonly used datapoints under a known alias and reuse snippets. The system is build from two parts: The context manager and the email integration.

Context manager

The context manager is an admin tool that allows you to save common global strings for use in templating.

System Contexts

The system provides two contexts by default:

  • system.internal - cannot be edited, contains metadata from the email being generated (from,to). Rarely if ever actually usefull except for debugging and testing
  • system.global - User definebale keys in the root namespace. Items in system-namespaces are injected into the
  • templating context without a prefix.

Custom contexts

You can create arbitrary contexts in the system which will be injected with a common base key. Fo9r example the context mycontext with key hello would be useable as mycontext.hello. This helps reduce the noise on the root level and gives semantic grouping capability.

Naming limitations

Context key names may never contain dots in their names. Keys with a dot will not be saved. Using a minus sign is allowed. Dots in Mustache define object property access. context keys may only contain strings, not objects. We do not support nested contexts.

Templaing for list

You can use all system contexts and user defined static context in you lists if you activate enable templating in the list settings. This can be changed on a per-list absis and defaults to inactive as the more transparent choice.

Bulk-Templating via the WebUI

Administrators get access to the bulk customization system. You can uploads a file based on which you can then send mass templated emails. You can use all sysem and custom contexts as well as all data from your provided context file.

warning

Note that you cannot individually pick emails from the file yet, if you want to exclude someone you need to remove the row before uploading

Basic flow

Step 1: File upload

You must upload a .xlsx file that has at least one column containing only valid emails.

Step 2: Validate fields

You will be shown an overview of the data clumns in the file. Columns marked invalid contain at least one empty cell. You can continue with empty fields, if you reference the value it defaults to undefined which renders as an empty string.

Step 3: Compose message

To compose your message you type subject and body text into the provided fields. In the "preview" section you can select an email address for which you want to see the rendered output.

Step 4: Confirm and send

You will see a full list of addresses that an email will be send to. Clicking "confirm" will then enqueue all emails.

Errors and aditional steps

There are a few steps that are dynamically added if needed:

Pick primary key

If your document contains multiple columns that qualify as primary (no holes, all valid emails) you must manually pick which column to use as primary.

No primary key

If your document has no column that qualifies as primary (all have holes or non-emails) then the process will terminate with an error message.

Confirm external addresses

As an admin you get the fill power of the email engine. You may send to arbitrary targets. If the list contains emails not on the instance allowlist you will have to confirm that this is intended for this operation. This additional friction is intended to prevent accidental data leaks.