Skip to main content
Resolve a saved template’s merge variables against a data object and return the final subject, HTML, and text — without sending anything. Useful for previews and QA. POST /v1/templates/{id}/render This is a pure render: nothing is queued or delivered. To send a template, pass templateId + data to POST /v1/emails instead — the pipeline renders it for you.

Path parameters

string
required
The template id or slug to render.

Body parameters

object
Merge variables, keyed by placeholder name. Nested objects are reachable with dot paths ({{user.name}}). Omit to render with no substitutions.

Request

Response

string
The rendered subject line.
string | null
The rendered HTML body, or null if the template has none.
string | null
The rendered plain-text body, or null.
string[]
Variables referenced by the template but absent from data. They render as empty strings; surface this array in QA to catch gaps.
200 OK
Previewing an unsaved draft. To render a template you haven’t saved yet — e.g. a live editor — use POST /v1/templates/preview, which takes the draft fields inline instead of an id.