🔨
Ban Member
mod.banThe Mod SquadModerationPermanently bans a user. Unlike Kick, they cannot rejoin. Optionally deletes their recent messages (1–7 days). Use with care — you can always Unban later if needed.
When to use this
- →Set 'Delete messages days' to 1 to clean up spam without wiping older legit history
- →You can ban users who aren't in the server — just provide their ID
- →Always wire the Error port for graceful failure handling
On the canvas
This is what Ban Member looks like when you place it on your flow. Each field below is something you configure in the inspector panel.
🔨Moderation
Ban Member
mod.banuserIdrequired
{{user.id}}
reason
Repeated rule violations
deleteMessageDays
0 (0–7 days)
output
error
Config fields
| Field | Type | Req | What it does |
|---|---|---|---|
userId{{user.id}} | text | yes | Who to ban 👤 |
reasonRepeated rule violations | text | — | Reason 📋 |
deleteMessageDays0 (0–7 days) | number | — | Delete their recent messages (days) 🗑️ |
Output ports
outputBan applied
errorFailed — permissions or role hierarchy issue
📐
In TypeScript, this would be…
Not something you need to write — just a look at what Kitcord does for you.
TypeScript
try {
await guild.members.ban(userId, {
reason,
deleteMessageSeconds: deleteMessageDays * 24 * 60 * 60,
});
} catch {
// Error port
}More Moderation pieces