An email message header that we can rely on to store information into it, no matter what Mail Client or response type (forward or reply)

Viewed 321

I'm trying to set a message header to distinguish some emails when they get back to the Mailing System (Exchange Server) and process them programmatically. everything is fine, however, I cannot find the right message header which is related to my purpose (informative/tag), and also is not removed by some mail clients (such as MS Outlook). I tried Xref header as it's mentioned in StackOverflow by people, however it's removed from the message after you reply with an Outlook Windows Client. I have read the Message Header guidelines but it seems whatever which is free to use (for instance, is not used by the MTAs such as sender, message-id, etc) will be removed by mail clients on reply or forward.

I have tried Xref, Injection-Info, X-Disclaimer (which is a custom header) with no luck. the only option that worked was the References Header, that still holds my initial value after replied, however, a Message-ID is also appended into it (which seems fair since the header is somehow reflecting the ID as it is described in the guidelines).

I want to discuss what Message Header a programmer can really rely on for tracking purposes when sending an email, regardless of which Mail Client (Outlook, Thunderbird, e.g.) is used or how the mail was responded (forward, reply, e.g.)

1 Answers

After months of researching, I noticed that it is what it is. clients always remove additional headers, for a lot of reasons, especially privacy. so there's no way for a tracker to use a Header. I thought later it makes sense! that's why marketers always use Tracking links. So, the final answer is to use any header, that is preserved during transactions by all the clients, which is the References header. all you need to do is to parse the header value and extract your own custom value.

Hope this helps another me!

Related