Our new XMPP MUC BanBot
Blog post from: Thu, 05 Mar 2026@creme@pleroma.envs.net has
built a nice MUC BanBot
for XMPP with a lot of neat features to keep the Multi-User-Chat rooms
in order. This bot is certainly useful for other XMPP server admins
too. So we have more control and generally more safety in the envs.net XMPP chat rooms.
#envs
#xmpp
#muc
#bot
#chat
Blogpost
Keeping your visitors safe!
The XMPP MUC BanBot allows centralized administration from a designated admin room and protects multiple chat rooms from unwanted users.
Admin commands from the admin room
These commands are issued by the room admins in the designated admin room for the bot.
| Command | Description | Example |
|---|---|---|
| !help | - Shows help text for the bot | !help |
| !ban <nick|JID> [comment] | - permanently ban user from protected rooms | !ban fab You're out! |
| !tempban <nick|JID> <10m|2h|1d> [comment] | - temporarily ban a user from protected rooms | !tempban fab 5m Cool Down! |
| !unban <nick|JID> | - unban a permanently or temporarily banned user from protected rooms | !unban fab |
| !bansearch <query> | - search bans by nick, domain or JID | !bansearch envs.net |
| !banlist | - show list of temporarily active and permanent bans | !banlist |
| !reloadconfig | - Reload config.py and update settings like 'SHOW_BAN_IN_MUC'. | !reloadconfig |
| !room add <room> | - Add room to the protected list and DB | !room add room@muc.example.com |
| !room remove <room> | - Remove room from protected list and DB | !room remove room@muc.example.com |
| !room list | - List all currently protected rooms. | !room list |
| !sync | - Let the bot rejoin rooms and enforce active bans | !sync |
| !syncadmins | - Update list of admins | !syncadmins |
| !syncbans | - Sync bans from/to rooms with the bot's database | !syncbans |
| !status | - Show bot status | !status |
| !whoami | - Shows your affiliation | !whoami |
| !why <nick|JID> | - Show the reason for a ban | !why fab |
Public commands for participants
These commands can be executed by the participants of protected rooms.
| Command | Description | Example |
|---|---|---|
| !help | - Shows help text for the bot | !help |
| !banlist | - show list of temporarily active bans | !banlist |
| !why <nick|JID> | - Show the reason for a ban | !why fab |
Description
As you see, with these commands you can permanently or temporarily ban people who can't behave, are bothering other room participants or generally don't follow the room rules in all protected rooms.
Temporary bans will automatically be lifted when the time set for the ban has passed.
All bans, temporary and permanent can be lifted by the channel admins of protected channels at any time. There are also the different !sync commands to keep the bot's database in sync with the rooms, bans and admins.
Conclusion
With the MUC BanBot we have an excellent tool to keep trolls out of our chatrooms. And also especially the !tempban function can be used to take some speed out of heated discussions. All in all, an excellent piece of software for XMPP server administrators.
Best wishes,
~dan