I’ve constructed an HTML template, but including the image has resulted in excessively long encoded data. Consequently, I’m unable to send the HTML template via email.
I have tried to reduce the image size and converted into jpg format, but stilll the image binary data is huge, due to that I couldn’t send an email via AWS SES.
Is there a specific size limit enforced by AWS SES for emails? I’m attempting to send an email with a template that exceeds 9.94 KB in size, but it fails to send. However, when the HTML template size is less than 9.94 KB, I’m able to successfully send emails using the AWS SES node.
In theory you could do that with a webhook, but this may not be an optimal solution if you plan to send a lot of emails. For personal/small-scale use this should be fine though.
I’ve explored the solutions you proposed, but I’m facing a challenge with sending binary data of images via email. The images I’m working with are stored locally or accessible via HTTP, but ultimately In the end, it’s been sent as binary data in the email.
Is there a way to embed these images directly into the HTML-formatted email, similar to how we specify image locations in HTML?
For instance:
<img src="image.png">
Could we specify the image location on the server within the HTML code?
Not without a webserver. The user who receives the email will not have access to your local filesystem and needs to have a public URL to fetch the image from.
Using the webhook example I gave above, you could put the webhook’s address into the email template like this:
<img src="http://public.n8n-webhook-address" />
This way, once the recipient opens their email, their email client will do a web request to your n8n instance, it’ll generate the image and return it for display.
Did you try different email clients? It might be that it’s caching the image since it has the same URL every time you send it. To bypass the cache, you can add a ‘cache buster’ to the image URL that’s different each time you send the email, for example by appending
@bartv now I can view updated graph image. Thank you!
But the problem is while loading the images(13kb size) in email, automatically webhook triggered again and receiving another email. How can we avoid these things?