SES changing Message-Id Header

1

Hello,

I have a problem with the Message-Id header. It seems to change every time I send or receive a reply, which prevents Hubspot from tracking the responses.

Is there any way to keep the In-Reply-To and References consistent with Message-Id, as Sendgrid, for example, does?

I appreciate your help!

asked a year ago1144 views
4 Answers
1

The Message-ID header is a unique identifier for each email and is intended to change for each new email or reply, as per the Internet Message Format standard (RFC 5322). This is a standard behavior across all email systems, not just Amazon SES, to ensure the uniqueness of each email message.

Unfortunately, you cannot keep the Message-ID header consistent across different emails using Amazon SES or any other email service, as this would violate the email protocol standards and could lead to issues with email delivery and tracking.

If you're using HubSpot for tracking email conversations, consider using the threadId property instead of the Message-ID header. The threadId is designed to keep track of email threads and should remain consistent across all emails in the same conversation.

Alternatively, you could use custom headers to pass information that remains consistent across all your emails. Amazon SES allows you to include custom headers in your email, which could be used to include an identifier that remains consistent.

profile picture
answered a year ago
1

Okay, I got that, but however, I don't have the same problem using Sendgrid. We've got a mailcow instance, using relays.

Here's what a Hubspot Support Team Member said:

So the reason for this is it appears the you are using Amazon SES or Workmail which has a built in feature where the message ID of the email changes when it's sent to the recipient. Because of that, we are unable to reliably identify incoming emails as replies since the In-reply-to and Reference headers do not contain the message ID of the original email we provided to Amazon. The Sequence tool, however, does unenroll anytime the user receives an incoming email from the contact regardless of whether it's a reply or not.

Since this is the case and HubSpot cannot identify the message ID being the same as the email sent to the customer, the email "reply" does not come through as a reply to HubSpot, so it would not log to the email thread and therefore would not log at all, unless you set up email forwarding in your email inbox using the forwarding address here.

Are there any differences between what SES and Sendgrid changes that is not consistent?

answered a year ago
1

Hey,

Thanks for giving me the opportunity to dig into this. I found that for emails sent using Sendgrid relay, the Message-Id looks something like this (packed with numbers):

facsimile-yyyyyy-xxxxxxxxxxxxxxxxxxxxxxxxxx@facsimile.hubspot-networks.net But when we get a reply, the Message-Id changes to the domain of the email provider, here it's Gmail, so it's unique.

long_numbers@mail.gmail.com

However, the In-Reply-To and References hold on to the old Message-Id (the Hubspot one) I used to send. (facsimile-yyyyyy-xxxxxxxxxxxxxxxxxxxxxxxxxx@facsimile.hubspot-networks.net). This is how Hubspot can log my emails, it can recognize it easily.

-- However, I checked emails sent via SES relay. The Message-Id stays almost the same when sent (same pattern): facsimile-yyyyyy-xxxxxxxxxxxxxxxxxxxxxxxxxx@facsimile.hubspot-networks.net. But, sadly, when a reply comes back, the In-Reply-To and References don't keep this one. They change to the Amazon SES domain:

xxxxxxxxxxxxxxxx-adfsdfsfd-aaaa-bbbb-cccc-dafadfadfad-000000@email.amazonses.com

Any ideas on how to maintain the Message-Id in References and In-Reply-To when a reply arrives? I'm only using SES for sending, not receiving (I know they have an incoming mail feature), but we have our own MX.

Thanks!

answered a year ago
0

Hey there, I'm kinda in a similar situation as #OP. Could someone from aws come up with a solution ? I also tried setting custom headers with sendRawEmail and verified that they are truly sent but when trying to reply to the original message the headers are not kept, they are removed. Another option that I could see fit ( just so it will work with any email clients ) is to be able to keep the same references or in-reply-to field values the same. Currently aws ses changes these values every time, even though the email is being sent as a reply. Thanks in advance.

Dorin
answered 4 months ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions