Why do I get something like InternetAddress@... text when trying to get something like user@domain.tld?

This may ocurr when you get an address from one object using the syntax ${ message.from[0] } or similar.

The problem here is that not every internet address stored by distribution is held as a plain string of characters. Sometimes, an internet address is stored in memory in a compound object that holds the internet address and a name. For these, the way of getting those properties is through the address and personal properties, using a syntax like ${ message.from[0].address }.

In scripting engines, the same thing happens. In BeanShell you would write:

sender = message.getFrom()[0].getAddress();

Why do I get an error 'Called an undefined function...' when calling a function like ${ mail:prefixSubject('[mylist] ', message.subject) }?

Make sure that you have imported the correct function plugins and that you are using the correct prefix when calling the funcion.

To import a function plugin, add this at the top of your process configuration:

function prefix="mail" class="org.cid.distribution.plugins.mail.MailFunctions" /