Modules
Auto-mod
Rules that catch spam, scam links, invites and blocked words by themselves, plus server lockdowns for when things get out of hand.
Auto-mod checks every new and edited message in your server against rules you set up. When a rule catches a message, Dexy does what the rule says: delete it, alert the mods, warn, time out, kick or ban, in the order you pick.
Auto-mod is a module of its own and is on by default, but it does nothing until you add a rule. It also works with the Moderation module turned off: its warnings, timeouts, kicks and bans are still recorded as cases in Moderation's case log, and still posted in the mod log when you have one.
Add your first rule step by step#
- Give Dexy a mod log first, so alerts have somewhere to go: Moderation ▸ Settings ▸ Mod log channel (or
d!modset log #mod-log). The Auto-mod page reminds you while there's none. - Open the dashboard, pick your server and open Auto-mod in the sidebar.
- Under Rules, press Add a rule and pick what the rule should look for, like Invite links or Message spam.
- In the editor, adjust What it catches, then choose What it does: the actions run in the order you list them. Who it skips lets channels and roles off the hook.
- Try it before saving: type a message in Try this rule at the bottom of the editor. Unsaved changes are included, and nothing is posted or kept.
- Press Add rule (or Save rule when you edit one).
Your rules are listed with what they do, whether they're on, and their hits. Click one to edit it, or use its switch to turn it off.
When a rule that alerts or punishes catches a message, the hit is posted in your mod log:
Dexy BOT Today at 9:41 PM
Auto-mod · @Zane in #general Found: freecoins
free coins for everyone, join fluxer.gg/freecoins 🎁
Case #31 · 🤖 Auto-mod
Member: @Zane (1431284724677097803)
Moderator: Dexy (auto-mod)
Reason: Invite links: an invite to another server
Rule: #1 Invite links · in #general
Deleted: 1 message
Then: case #32
Today at 9:41 PM
Try a message against your rules#
At the top of the Auto-mod page there's a box: paste or type a message and Dexy tells you which rules would catch it and why. Nothing you type is posted or kept, and exemptions don't apply to a try.
Before you have rules, d!automod demo followed by any text tries it against Dexy's sample rules instead (the same ones as the website's demo): blocked words, invites, links, phishing, masked links, mentions, capitals, emoji, zalgo, repeated text, spoilers and long messages. Nothing is acted on or kept.
Rule types#
Each rule has one type. In chat, settings are written as key=value after the type; anything you leave out keeps the default shown here.
| Type | Dashboard name | Catches | Settings in chat (default, range) |
|---|---|---|---|
spam | Message spam | Too many messages from one member in a few seconds. The message that crosses the line and every one after it. | 6/5s short form, or messages= (6, 2–50) and seconds= (5, 2–120) |
duplicates | Repeated messages | The same text sent again and again. | 3/60s short form, or count= (3, 2–20) and seconds= (60, 5–3600) |
mentions | Mass mentions | More than a number of different members and roles mentioned at once, or @everyone / @here written without the right to use it. | max= (5, 1–50), everyone=on|off (on) |
caps | Capital letters | Messages written mostly in capitals. Mentions, emojis and links aren't counted. | percent= (70, 50–100), letters= minimum letters before it checks (10, 5–500) |
emoji | Emoji spam | Too many emojis in one message, Unicode and custom (animated too). | max= (10, 1–100) |
lines | Long messages | Too many lines or characters. | lines= (15, 0–200), chars= (0, 0–4000); 0 means not checked, and one of them must be set |
invites | Invite links | Invite links to other Fluxer servers, in every official form. | own=on|off allows your own server's invites and vanity URL (on), allow= extra invite codes to allow (up to 50) |
links | Links | Links to blocked sites, or to any site not on an allow list. | deny=site.com,other.com or allow=site.com,… (up to 200 domains) |
words | Blocked words | Words and phrases from your list, including look-alike spellings. | exact= whole words and phrases, contains= anywhere, even inside words, wildcard= patterns with * and ? |
attachments | Attachments | Too many files, or files of blocked types. | files= most files (0 = not checked, up to 10), block= extensions (a list of risky types like exe and bat by default, up to 50) |
newcomers | New members | New accounts and members posting links, invites, files or mentions. | account= account age in days (7), joined= days in the server (3), messages= messages counted by Stats (0), block=links,invites,attachments,mentions |
zalgo | Zalgo text | Letters stacked with marks to break the chat. | marks= most marks on one character (3, 1–20) |
repetition | Repeated text | One character, word or phrase repeated many times in a row. | chars= (15, 0 or 3–500), words= (6, 0 or 2–50); 0 means not checked, and one of them must be set |
file_spam | File spam | More files than allowed from one member in a few seconds, in any channels. | 5/10s short form, or files= (5, 1–50) and seconds= (10, 2–300) |
phishing | Phishing links | Links to known phishing and scam sites, from a list Dexy keeps up to date. | allow= domains never counted (up to 200) |
link_spam | Link spam | More links than allowed from one member in a few seconds, in any channels. | 4/30s short form, or links= (4, 1–50) and seconds= (30, 2–300) |
mention_spam | Mention spam | More mentions than allowed from one member in a few seconds, in any channels. | 10/30s short form, or mentions= (10, 1–100) and seconds= (30, 2–300) |
spoilers | Spoilers | Spoiler text and files sent as spoilers. | text=on|off (on), files=on|off (on); one must be on |
masked_links | Masked links | Links hidden behind other words, like [click here](https://…). | mode=any|deceptive (any), allow= domains that are fine (up to 200) |
stickers | Stickers | Any sticker, or too many stickers in a few seconds. | mode=any|burst (any); for a burst 3/60s short form, or count= (3, 1–50) and seconds= (60, 5–600) |
A few details worth knowing:
- Links: a listed domain covers its subdomains, so
youtube.comalso coverswww.youtube.com. Each link is judged on its own, so an allowed link never excuses another link in the same message. Invite links are left to theinvitestype. A deny list needs at least one domain; an allow list with no domains blocks every link. - Blocked words: Dexy compares text after folding look-alikes. Invisible characters, accents, fancy and full-width letters, Cyrillic and Greek look-alike letters, leetspeak (
$h1t), spaced-out letters (b a d) and stretched ones (baaad) all match the plain word. A rule holds up to 200 words and patterns, each up to 64 characters. - Attachments: only the last extension counts, so
cute.png.exeis an exe. - New members: a member counts as new while any of the conditions is true; 0 leaves a condition out. The message condition uses Stats' count, so it's skipped while the Stats module is off.
- Zalgo: accented letters carry two marks at most, so normal accents never count.
The newer types are explained one by one under More rule types.
Every rule can also have a name (name=Invite_links, underscores become spaces; up to 50 characters). Without one, it's named after its type.
More rule types#
Repeated text#
Catches a message where one character repeats at least 15 times in a row (aaaaaaaaaaaaaaa, !!!!!!!!!!!!!!!), or one word or short phrase repeats at least 6 times in a row (buy now buy now buy now …). A phrase is up to 4 words.
- Spaces don't count as a repeated character, and neither do mentions, custom emojis or links.
- Capitals and look-alike letters count as the same letter, like for blocked words, so
AaAaAais one run. chars=sets the characters (0, or 3 to 500) andwords=the words (0, or 2 to 50). 0 leaves that one out; one of them must be set.
d!automod add repetition chars=20 words=0 delete
d!automod add repetition chars=20 words=0 delete
File spam#
Catches a member who sends more than 5 files within 10 seconds, counted across every channel, even when each message has only one file. It's separate from the Attachments rule, which looks at one message at a time.
With Delete the message, their other messages with files from those seconds are deleted too, like a spam burst. files= is 1 to 50 and seconds= 2 to 300, or write both at once like 5/10s.
d!automod add file_spam 5/10s delete timeout:10m
d!automod add file_spam 5/10s delete timeout:10m
Phishing links#
Catches links to known phishing and scam sites, subdomains included. Dexy downloads a public, community-maintained list of scam domains seen on chat platforms and refreshes it every 6 hours. Only the list is downloaded: nothing about your messages is ever sent anywhere.
- If the list can't be loaded, the rule doesn't catch anything. There's no built-in guess list.
d!automod,d!automod show,d!diag, the rule editor and the setup check on the Overview page say when the list isn't loaded. - A site on the list by mistake? Add it to the rule's allowed domains (
allow=example.com, up to 200). Subdomains count.
d!automod add phishing delete alert notice=on
d!automod add phishing delete alert notice=on
Link spam#
Catches a member who sends more than 4 links within 30 seconds, across every channel. Each link counts, invite links included. With Delete the message, their other messages with links from those seconds go too. links= is 1 to 50 and seconds= 2 to 300 (4/30s).
Mention spam#
Catches a member who mentions more than 10 members and roles within 30 seconds, across every channel. Each message counts the different members and roles it mentions, and the messages are added up. It's for pings spread over many messages; Mass mentions catches many in one message. mentions= is 1 to 100 and seconds= 2 to 300 (10/30s).
Spoilers#
Catches spoiler text written ||like this|| and files sent as spoilers. Both are on by default; turn one off with text=off or files=off. Spoiler marks inside code blocks don't count, since they don't hide anything.
Masked links#
Catches links hidden behind other words, written [words](https://…). Two modes:
- Every masked link (
mode=any, the default). - Only misleading ones (
mode=deceptive): the words look like a link or a site, but the link goes somewhere else, like[steamcommunity.com](https://scam.example). Words such as "click here" are fine, and so is a link to the site the words name (subdomains count).
Links to the rule's allowed domains (allow=) are always fine. Plain links aren't masked; use the Links rule for those.
d!automod add masked_links mode=deceptive delete alert
d!automod add masked_links mode=deceptive delete alert
Stickers#
Catches any sticker (mode=any, the default), or more than 3 stickers within 60 seconds from one member across every channel (mode=burst, or write 3/60s). count= is 1 to 50 and seconds= 5 to 600. You can't try a sticker in the try box, since stickers can't be typed.
Actions#
Actions run in the order you list them. If a rule has no actions, it deletes the message.
| Action | In chat | What it does |
|---|---|---|
| Delete the message | delete | Removes the message. For spam, the member's other messages from the burst go too. |
| Alert the mods | alert | Posts the hit in the mod log. |
| Warn | warn or warn:2 | A warning worth that many points (1 by default, up to 100). Your warning ladder applies. |
| Time out | timeout:10m | A timeout of that length, from 1 minute to 365 days. |
| Kick | kick | Kicks the member. |
| Ban | ban or ban:1d | Bans for good, or for that long (1 minute to 730 days). |
A rule can have up to 6 actions, each once, and at most one of timeout, kick or ban. A kick or ban stops the actions after it.
d!automod add words exact=badword,slur delete warn then=3/1h:kick
d!automod add words exact=badword,slur delete warn then=3/1h:kick
This rule deletes the message and warns. then=3/1h:kick is escalation: the third hit within an hour also kicks the member, and the count starts again. Escalation takes 2 to 20 hits within 1 to 1,440 minutes, and its action is a warn, timeout, kick or ban. On the dashboard it's Escalate repeat offenders.
What a hit does#
- The rule's hit counter goes up, and Dexy records an auto-mod case. The case reason is the rule's name and why it fired, never the message text.
- When the rule alerts or punishes, the case is posted in the mod log with the member, the channel, what was found and the message quoted. The quote comes from memory at that moment: Dexy never stores the message.
- Warnings, timeouts, kicks and bans go through Moderation, so they're cases of their own, members get the usual DM (see What members are told), and role order is checked like any moderator action.
- Within 10 seconds of a hit, the same rule only deletes that member's messages. A flood makes one case, not fifty.
- Dexy takes at most 15 member actions per server every 10 seconds. Actions over that are skipped and noted on the case.
Notices in the channel#
A rule can tell the member why their message went: a short message in the channel that pings only them and deletes itself after a few seconds. It's off by default. Turn it on in the rule editor under Notice in the channel, or with notice=on.
The notice is the member's mention (the only ping) and one line in a small embed: Message removed when the rule deletes, the rule's name, and the warning points or timeout the hit gave them. It's posted once the rule has acted, so the numbers are what really happened:
Dexy BOT Today at 9:41 PM
@Zane
🛡️ Message removed · Invite links · +1 pt
- Write your own text with
{user}(a mention of the member) and{rule}(the rule's name), up to 200 characters:notice="Hey {user}, no scam links here". It takes the place of Dexy's line; the editor shows a preview. In the detailed style, Dexy's own text is "@member, your message broke a server rule: Rule name." - It stays for 5 seconds by default, 3 to 60 (
notice_for=10s). - It's posted when the rule acts, at most once per member within 10 seconds of a hit, so a flood makes one notice. Nothing is posted in test mode, and at most 5 notices per channel every 10 seconds.
- A notice isn't a warning: add the Warn action for that.
d!automod edit 2 notice="{user}, slow down please" notice_for=8s
d!automod edit 2 notice=off
d!automod edit 2 notice="{user}, slow down please" notice_for=8s
d!automod edit 2 notice=off
How notices look#
One style for every rule's notice, under Auto-mod ▸ How notices look (with a live preview) or with d!automod style. It's free.
| Style | What the channel sees |
|---|---|
| Compact (default) | The member's mention and one line in a small embed. |
| Detailed | The member's mention and an embed: Message removed, the rule's notice text, then the rule and the warning or timeout. |
| Text | One line of plain text after the member's mention. |
On Discord there's a fourth style, Components V2 (d!automod style v2): the detailed notice as one Components V2 card. It still pings only the member.
Custom (d!automod style custom) sends your own Components V2 layout, built on the dashboard under How notices look. The builder works as on the Welcome and Reaction roles pages: containers, sections, text, separators, galleries and link buttons, each opened to change it or dragged to a new place, with Discord's limits counted and a starting layout under Templates. Its placeholders are {user} (the member's mention, the only ping), {rule}, {notice} (the rule's notice text), {action} (Message removed, or Auto-mod), {points} and {total}. Until a layout is built, Custom sends the Components V2 card.
Compact is the notice above. Detailed:
Dexy BOT Today at 9:41 PM
@Ivy
🛡️ Message removed
@Ivy, your message broke a server rule: Invite links.
Rule
Invite links
Warning
+1 point
Text:
Dexy BOT Today at 9:41 PM
@Theo 🛡️ Message removed · Invite links · +1 pt
A rule's own notice text takes the place of Dexy's line (or the embed's text) in every style, and only the member is pinged.
A rule's own log channel#
Each rule can post its alerts, case posts and test-mode hits in a channel of its own instead of the mod log, like a separate scam-alerts channel. In the editor it's Where hits are posted; in chat, log=#channel, and log=off for the mod log again. Warnings, timeouts, kicks and bans the rule leads to are still posted in the mod log.
Dexy needs Send Messages and Embed Links there. d!diag and the setup check on the Overview page say when it can't post.
Where a rule applies#
By default a rule checks every channel and every member. Where it applies in the editor (or d!automod only) narrows that down:
- Only in these channels: the rule checks nowhere else. A category covers every channel in it.
- Only for these roles: the rule checks only members with at least one of them.
Exempt channels and roles still skip the rule, and so does whatever auto-mod ignores everywhere.
d!automod only 3 @New
d!automod only 2 #general #memes
d!automod only 2 clear
d!automod only 3 @New
d!automod only 2 #general #memes
d!automod only 2 clear
Live in Discord
Live in Fluxer
Ignored everywhere#
Channels and roles that no rule checks, on top of each rule's own exemptions: staff channels, a bot channel, a trusted role. On the dashboard it's Ignored everywhere on the Auto-mod page. A category covers every channel in it. See ignored channels and ignored roles.
Who and where a rule skips#
- Exempt channels and roles: a rule can skip channels (a category covers every channel in it) and roles, up to 50 of each.
- Mods: by default, members who can moderate aren't checked. Mods are the owner, members with Administrator, Manage Server, Manage Messages, Moderate Members, Kick Members or Ban Members, and roles with Dexy's Moderate permission. Turn this off per rule if you want mods checked too.
- Ignored everywhere: channels and roles on the Auto-mod page's ignore lists skip every rule (see above).
- Protected roles: members with a protected role are never checked by auto-mod. Set them with
d!modset protector in Moderation settings (see protected roles). - Bots and webhooks are skipped unless a rule checks them too (
--bots, or Check bots and webhooks too).
On the dashboard, all of this is under Who it skips in the rule editor.
d!automod exempt 2 #memes @Trusted
d!automod exempt 2 remove #memes
d!automod exempt 2 mods off
d!automod exempt 2 #memes @Trusted
d!automod exempt 2 remove #memes
d!automod exempt 2 mods off
Live in Discord
Live in Fluxer
Edited messages#
Edits are checked again by rules that look at the text or files, but only when the text or files actually changed. Spam, repeated-message, file, link, mention and sticker-burst rules count new messages only.
Test mode#
Test mode lets a rule run on real messages without acting. Each hit is posted in the mod log as "would have …" (at most once every 10 seconds per member). Nothing is deleted and no case is made. Turn it off once you're happy:
d!automod add links deny=scam.example delete --test
d!automod edit 4 --live
d!automod add links deny=scam.example delete --test
d!automod edit 4 --live
Spam and repeated-message rules need several messages, so a try (in the box or with d!automod test) skips them. In the rule editor, Try this rule checks one rule, unsaved changes included.
Managing rules#
d!automod
d!automod show 2
d!automod edit 2 max=8
d!automod edit 3 delete timeout:1h
d!automod disable 2
d!automod enable 2
d!automod remove 2
d!automod
d!automod show 2
d!automod edit 2 max=8
d!automod edit 3 delete timeout:1h
d!automod disable 2
d!automod enable 2
d!automod remove 2
Rules have numbers (#1, #2 …) shown by d!automod. Editing keeps whatever you leave out, but giving any action replaces the rule's whole action list. then=off removes escalation. Removing a rule keeps its past cases.
Live in Discord
Live in Fluxer
Live in Discord
Live in Fluxer
A server can have up to 25 rules.
Lockdowns#
A lockdown stops members sending messages in every text channel at once, for a raid or a spam wave. Roles that are allowed to send on their own, like your mods, still can.
On the dashboard:
- Open Auto-mod and scroll to Raid protection.
- Under Lockdown, pick how long (from 15 minutes to 6 hours, or until someone ends it) and write a reason if you like.
- Press Lock the server. While it's locked, the same place shows End lockdown.
In chat a lockdown can last up to 7 days; leave the length out and it lasts until someone ends it. Ending it gives each channel its Send Messages permission back exactly as it was. The reason goes in the case and Fluxer's audit log.
To lock only some channels, pick lockdown channels with d!modset lockdown or in Moderation settings (see lockdown channels). Categories cover the text channels in them.
Common setups#
Keep invites to other servers out, but let your partners through:
d!automod add invites allow=partnercode delete alert
d!automod add invites allow=partnercode delete alert
Stop floods and copy-paste spam:
d!automod add spam 6/5s delete timeout:10m
d!automod add duplicates 3/60s delete warn
d!automod add spam 6/5s delete timeout:10m
d!automod add duplicates 3/60s delete warn
Block words, with an escalation for repeat offenders:
d!automod add words exact=badword contains=slur delete warn then=3/1h:timeout:1h
d!automod add words exact=badword contains=slur delete warn then=3/1h:timeout:1h
Stop scam links from brand-new accounts:
d!automod add newcomers account=7 joined=3 block=links,invites delete alert
d!automod add newcomers account=7 joined=3 block=links,invites delete alert
Catch known scam links anywhere, tell the member, and post the hits in their own channel:
d!automod add phishing delete alert notice=on log=#scam-alerts
d!automod add masked_links mode=deceptive delete alert
d!automod add phishing delete alert notice=on log=#scam-alerts
d!automod add masked_links mode=deceptive delete alert
Stop floods of files, links and pings spread over several messages:
d!automod add file_spam 5/10s delete timeout:10m
d!automod add link_spam 4/30s delete
d!automod add mention_spam 10/30s delete timeout:1h
d!automod add file_spam 5/10s delete timeout:10m
d!automod add link_spam 4/30s delete
d!automod add mention_spam 10/30s delete timeout:1h
Who can set it up#
Managing rules needs Manage Server, or a role with Dexy's Moderate permission (see Permissions). Lockdowns need Manage Channels or the Moderate permission.
For Dexy to act, its own role needs the matching permissions:
| Action | Dexy needs |
|---|---|
| Delete | Manage Messages |
| Time out | Moderate Members |
| Kick | Kick Members |
| Ban | Ban Members |
| Lockdown | Manage Roles (it edits channel permissions) |
Commands#
| Command | What it does | Needs |
|---|---|---|
| automod | List this server's auto-mod rules: what each catches, what it does, and whether it's on.add · demo · disable · edit · enable · exempt · ignore · only · remove · show · style · test | Manage Server, or a role with Moderation |
| lockdown | Lock the server's text channels at once (a raid, a flood); optionally it ends by itself.end | Manage Channels, or a role with Moderation |
Full details for each: Auto-mod command reference.
Troubleshooting#
A rule doesn't catch anything. Check that it's on (d!automod show 2), not in test mode, and that the member isn't a mod, in a protected role, or in an exempt channel or role. Try the message with d!automod test.
Nothing shows up in the mod log. Alerts and test-mode posts need a mod log channel: d!modset log #mod-log. Dexy also needs to be able to post there. A rule with its own log channel posts there instead.
The phishing rule never catches anything. Check d!automod show for the rule: if the phishing list isn't loaded, Dexy couldn't download it yet and keeps trying by itself. Links are only caught when their site is on the list.
The message wasn't deleted, or the timeout failed. Dexy is missing a permission from the table above, or the member's highest role isn't below Dexy's. Move Dexy's role above the roles it should act on. Failed actions are listed on the case.
Edits aren't checked. In large servers, Fluxer may not tell Dexy about every edit, so some edited messages are never seen.
Auto-mod is off. If commands say the module is turned off, turn it on with d!modules enable automod.