A 'TemplateModel' is required when using a template to send an email.
SimonVillage opened this issue · 2 comments
SimonVillage commented
I am getting this error for templates not using any template model
This message is using a Postmark template.
Alias: "password_change"
Model:
{
}
Use the #prerender method on this object to contact the Postmark API to pre-render the template.
Cheers,
Your friends at Postmark
Postmark::ApiInputError: A 'TemplateModel' is required when using a template to send an email.
SimonHausdorf commented
as a workaround
self.template_model = { tmp_fix: '' }
can be used
nickhammond commented
Hey @SimonHausdorf,
Sorry about that, I've updated the wiki article to mention that a template model should be specified. A TemplateModel is a required attribute, here's a bit more information around our template syntax if you're curious.