Learn how to connect your Postmark account to Tabular and how to upload to, update, and use your Tabular emails in Postmark.
Postmark by default performs inlining of CSS in your templates, this results in unwanted changes to Tabular's HTML (because Tabular already performs all necessary inlining and optimisation).
Postmark performs inlining for example when you send a test email or check out the "Preview" in Postmark's user interface, and when you programmatically send out an email with a template (API) using their default settings.
When sending out your email with the template using the Postmark API, you'll have to explicitly set the 'InlineCss' parameter to 'false'. Setting the 'InlineCss' parameter to false fixes the issue that you've experienced of the breaking HTML.
For example, if you're using Postmark's NodeJS library the code would look something like this:
client.sendEmailWithTemplate({
From: "johndoe@email.com",
To: "johndoe@email.com",
TemplateModel: {},
InlineCss: false,
TemplateId: 12345678,
MessageStream: "broadcast",
})
We think it's really unfortunate that Postmark doesn't provide an option to disable CSS inlining when sending a template test email or checking out the "preview", because it doesn't give a realistic preview for when you don't use their inlining. We've had contact with them about this, but the only solution for now is just to always set the 'InlineCss' parameter to false when programmatically sending the email.
You'll have to generate an API token for the server that you wish to send your Tabular emails from. Do this by navigating to your Server in your Postmark app, then click on the API tokens tab. Here you'll be able to retrieve your Server API token, that you'll have to use in a later step.
Read the next section to learn how to upload a Tabular email using your just created Postmark authorization.
Inside your Postmark app, navigate to the Server that relates to the Server API token you've used to connect to Tabular. Click on the Templates tab, this is where you'll find your automatically uploaded Tabular emails.