This email was not sent because the SMTPAPI header was invalid

SendGrid when trying to send any email apart from plain text email gives me this error. Does anyone know how to fix?

Thank you.

This is what happens when it’s successful when you send only a plain message (no template or no %VAR%.

Just in case anyone else encounters this thread- it took me a whole week to figure out that my Sendgrid dynamic transactional template was INACTIVE !!! I wish Sendgrid would have just thrown an error “this template is inactive”.

To fix this, navigate to your dynamic email templates. click on the 3 vertical dots on the right hand side of the template in question, and then click “Make Active”.

Solved my issues, hope it solves yours!