Email templates
Render a template preview
POST
Renders the template to HTML without sending it. Pass data to fill its variables, and contactId (an id or external identifier) to render with that contact's properties.
Requires the email-template:write scope.
ApiKeyheader
Authorization<token>Api-Key mc_... — a workspace API key.
identifier*stringapplication/json- body
contactId?stringContact id or external identifier to render as.
data?Values for the template's variables.
application/json- response
html*stringThe rendered HTML.
curl -X POST 'https://api.mailcrate.io/public/email-template/string/render-preview' \ -H 'Authorization: Api-Key <api_key>' \ -H 'Content-Type: application/json' \ -d '{}'Example Response
{ "html": "string"}Push a compiled template bundle POST
Uploads a compiled React Email bundle as the template's new content. This is what `mailcrate push` calls; `changed` in the response is `false` when the bundle was identical to the current one. Requires the `email-template:write` scope.
Update an email template PUT
Requires the `email-template:write` scope.