Creating Filters
What are filters?
Filters provide a way to, as the name implies, filter what messages are eligible to be starred.
There are 4 types of filters, each with their respective purpose:
-
Age. These are relative to how old the message was when it was starred.
-
Attachments. Attachment filters dictate whether attachments are required, how many are required, etc.
-
Content. Content filters control the content of the message, such as the length, or requiring certain text/patterns to be matched.
-
Date. Date filters require messages to be starred before/after certain dates.
Creating Filters
-
The first thing you need to do is to create a filter.
Let’s create an attachments filter, that requires messages to have at least 2 attachments:
/filters create attachments name my first attachment filter min-attachments 2 -
So far, this filter exists but doesn’t do anything since it hasn’t been added to your server’s settings.
Let’s change that, by adding it to your settings:
/filter add filter my first attachment filter settings Server Settings
That’s it! Messages will now have to have at least 2 attachments in order to be starred.