Skip to content

Instantly share code, notes, and snippets.

@SapphoSys
Last active February 5, 2026 08:18
Show Gist options
  • Select an option

  • Save SapphoSys/5314f5f8a6d1b20c24edbf11f59e0dea to your computer and use it in GitHub Desktop.

Select an option

Save SapphoSys/5314f5f8a6d1b20c24edbf11f59e0dea to your computer and use it in GitHub Desktop.
purelymail sieve scripts to counter zendesk spam

sieve scripts

helper scripts for purelymail
you can manage sieve scripts here: https://purelymail.com/manage/accountSieve

move to trash

moves zendesk emails to the junk tab

require ["fileinto", "imap4flags"];

if allof (
    header :contains "X-Zendesk-Priority-Mail" "Verification Email",
    header :contains "Message-ID" "_sprut@zendesk.com",
    header :contains "Auto-Submitted" "auto-generated"
) {
    addflag "\\Seen";
    fileinto "Junk";
    stop;
}

reject

rejects any zendesk spam email from reaching in the first place. saves credits but may encounter false positives here and there

require ["reject"];

if allof (
    header :contains "X-Zendesk-Priority-Mail" "Verification Email",
    header :contains "Message-ID" "_sprut@zendesk.com",
    header :contains "Auto-Submitted" "auto-generated"
) {
    reject "Zendesk spam";
    stop;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment