Skip to main content
Question

Help needed: Troubleshooting email sender-based automation

  • May 12, 2026
  • 1 reply
  • 14 views

Forum|alt.badge.img+1

I am currently building an automation where I want to check the sender's email address and then automatically route the email to a specific operator. I have also set up rules for the subject line and the free-text field, and these two work perfectly when the system name (which I’ve named 'xxx') is entered.

However, I can't get the automation to work when it has to look at the sender's email address and assign it to a specific operator.

Does anyone know why it isn't working with the sender's email?

<#if 
  (((_card["korteomschrijving"])!"")?contains("xxx")) ||
  (((_card["omschrijving"])!"")?contains("xxx")) || 
  (((_card["notities"])!"")?contains("xxx")) ||
  ((.vars["target"].externalSenderEmail!"")?lower_case?contains("xxxg@xxx.dk"))
>
true
</#if>

1 reply

Joost Oostindie
Forum|alt.badge.img+4

In TOPdesk, FreeMarker is usually quite strict about null handling and property access.
If you were to add parenthesis about the full property access like this ((.vars["target"].externalSenderEmail)!"") it would maybe work?
This would get you to: 
(((.vars["target"].externalSenderEmail)!"")?lower_case?contains("xxxg@xxx.dk"))

Though I suspect this might still not work, if not, I would also try: 
((((.vars["target"].externalSenderEmail)!"")?lower_case)?contains("xxxg@xxx.dk"))

Hope this helps, otherwise I hope you get an error log that you can maybe share!