serenity

Purging

Delete messages in bulk, filtered by who sent them or what's in them.

Replace [prefix] with your server's prefix.

Purge

// Syntax
[prefix]purge [amount] [member]

// Example
;purge 50
;purge 50 @member

Deletes the last amount messages in the channel, or only that member's messages among them. Needs Manage Messages for you and for Serenity.

Filtered Purges

Each of these takes an amount and deletes only messages that match:

CommandDeletes
[prefix]purge linksMessages containing a link
[prefix]purge imagesMessages with attachments
[prefix]purge embedsMessages containing an embed
[prefix]purge emotesMessages containing emotes
[prefix]purge mentionsMessages that ping someone
[prefix]purge stickersMessages with stickers
[prefix]purge reactionsStrips reactions, keeps the messages
[prefix]purge webhooksMessages posted by webhooks
;purge links 100
;purge images 50 @member

By Position

// Syntax
[prefix]purge before [message]
[prefix]purge after [message]

// Example
;purge after https://discord.com/channels/.../...

Takes a message link or id and clears everything on that side of it — the way to wipe a raid that started at a known moment without counting messages.

Clear

The clear group is the same idea with different filters:

;clear invites 20      // messages containing a Discord invite
;clear contains scam   // messages containing a word
;clear images 100

Bots

;botclear

Deletes recent bot messages in the channel. [prefix]bc, [prefix]bp and [prefix]botpurge are aliases.

Discord doesn't allow bulk-deleting messages older than 14 days, so no purge command can reach further back than that. Older messages have to go one at a time, by hand.

Purges land in the message log if you have one set up — the full set of deleted messages, not just the ones that happened to be cached.

LoggingEvent logs, moderator history, and protecting cases by role hierarchy.