How to train Spam Filter (Move to Spam Folder)?


First, thank you for this great piece of software.

We have an activated Spam Filter (on server side) which can block a lot of different spam mails. But we have to train our Spam filter, that it will be hopefully better sometimes and can block a bit more.

For this, on our server it will check once a day all the E-Mails who was put in to the IMAP->Spam folder.

So, what we would need is a possible solution to move all in Zammad manually marked spam E-Mail in to the IMAP spam folder. This could also be made only once a day by cron-job, but I don’t know, how to do this.

Does someone of you have an idea, how we could realize this?
On Zammads end it would be best, if we could just add a tag “spam” to those e-mails.

Best Regards

I’m afraid that Zammad does not provide such a functionality at all.
I don’t think that webhooks will help here too, because you would have to be able to get the original eml which may be a bit too tricky.

Since i am also looking into this.

the raw .eml seems to be available by going for the ticket_article number as returned by

that returns all articles for the ticket. Looks like the first Article of an e-mail ticket is the received e-mail. That article has a field id which can then be used on this undocumented endpoint

wouldn’t that be sufficent?

my idea would be to regulary fetch all tickets marked as spam since the last check and feed them as spam into the spam detector.

and also take all (or just a sample) tickets that are closed and not marked as spam and feed them as ham into the spam detector.

spam detector is rspamd and in zammad i can then rely on the rspamd headers that become useful if trained correctly.

but our zammad instance is super fresh, so it will take a while until this becomes a real thing. But this is the current idea.

Squiddles approach would technically be an option that one could implement.
Just to give my 2 cents.

This topic was automatically closed 120 days after the last reply. New replies are no longer allowed.