Skip to main content
Closed for Voting

Email header in emails from Freshdesk that I can use for filtering

Related products:Freshdesk
  • September 21, 2016
  • 4 replies
  • 326 views

My problem: I want to filter emails that our staff ( this applies to both agents and non-agents ) receive from our Freshdesk. I also want this filtering to not be fooled by emails we receive from other Freshdesk installations ( we were glad to discover that some partners also use it ).


Possible solution: Freshdesk could add something in the headers that uniquely identifies an outgoing email as coming from a specific account and indicate the type of email ( notification or not ).


For example, Freshdesk could add an X-Fresdesk-Source custom header.


In this case, if my Freshdesk account is myaccount ( => myaccount.freshdesk.com ) then:


X-Fresdesk-Source: freshdesk_myaccount_notification_agent

means that the email is an agent ( = Agent Notifications tab ) notification from myaccount


X-Fresdesk-Source: freshdesk_myaccount_notification_requester

means that the email is a requester ( = Requester Notifications tab ) notification from myaccount


X-Fresdesk-Source: freshdesk_myaccount_notification_cc

means that the email is a cc ( = CC Notifications tab ) notification from myaccount


X-Fresdesk-Source: freshdesk_myaccount_reply

means that the email is a reply ( = Reply Templates tab ) from myaccount


etc


The list is not complete as it should include, for example, qualifiers for emails generated through ticket watch or rules but it illustrates the idea.


Using this I could then create rules in my Mail Client that use conditions based on  data from that header.


Example:

If I want everything from myaccount moved to a specific folder then I would use this ( partial ) match:

X-Fresdesk-Source: freshdesk_myaccount_

or just freshdesk_myaccount_


If I want all notifications from myaccount moved to a specific folder then I would use this ( partial ) match:

X-Fresdesk-Source: freshdesk_myaccount_notification_

or just freshdesk_myaccount_notification_


I can also be specific and target only agent notification with a full match:

X-Fresdesk-Source: freshdesk_myaccount_notification_agent

or just freshdesk_myaccount_notification_agent


Obviously, any recipient could also benefit from this to categorize Freshdesk generated emails ( ours and from anyone else ).


An added benefit is that since the account is mentioned specifically ( i.e. myaccount ) the filters will not be fooled when processing email from another Freshdesk account ( like the  account of one of our partners or customers ).


PS1: I have though about other ways but none is satisfactory:

- Message-ID: References: Received: and other system headers should not be touched in any way.

- Subject: is not ideal for a number of reasons, including:

  1. Adding this info ( account identifier plus identifiers for notification/reply/etc type ) to the subject of every outgoing email would lead to some very ugly and confusing/intimidating subjects.
  2. Some emails like watch or rule generated ones, have subjects I cannot configure.
  3. When I change a subject, even a little, everyone will have to change their rules. A particularly bad case of that is when someone else is using a subject like mine ( because, for example, they saw our subjects and thought it would be nice to copy them ), forcing me to change everything in order that our rules do not mistake their emails for ours.


PS2: I use the underscore '_' as the separator of qualifiers above ( as in freshdesk_myaccount_notification_agent ) but this is a poor choice. A better choice is some character that myaccount ( the Freshdesk account name ) is not allowed to contain, so that I could reliably process this header if needed.


4 replies

Hello Thanos,


It seems like you are trying to setup filtering rules for email notifications that you are getting from Freshdesk. Could you add these specific tags to your email notification templates and then setup your inbox filters accordingly?


Hope that helps.


Thanks,

Sudha


  • Author
  • Contributor
  • January 9, 2017
Dear Sudha,

I am not sure I understand your suggestion. Do you mean adding some string inside the body of the notification email? If yes, I'd like to avoid that because a filter that matches that string in the body of a notification email will also match any other email that quotes the same body ( like a reply or forward email ).

 


Hello Thanos,


Yes, my solution was to modify the email notifications body to include the specific tag. I think it might be a first step to solving the problem of managing email notifications in your inbox though it may not solve all the edge cases.


I'll review your feedback with my team and keep this thread updated.. 


Thanks,

Sudha


i.cameron
Skilled Expert
Forum|alt.badge.img+2
  • Skilled Expert
  • March 16, 2023

6 years is a long time to wait for an update