2026

WhatsApp Moderation Agent

Several community groups, all with the same problems: people join and nobody greets them, someone gets removed from one group and walks straight into the next one, and every routine action costs an admin their attention.

This is a daemon that holds the account and takes care of all three.

WhatsApp Moderation Agent

One connection, and everything follows from it

WhatsApp allows one linked device per account. That single sentence decides the whole architecture, because it means nothing else can hold a connection while the daemon has one, and a moderation tool you have to disconnect before you can ask it to do anything is not much of a tool.

So the daemon is the only thing that ever connects, and instructions reach it as files. Anything that wants an action writes a small command file into a folder, and the daemon picks it up on its next pass, which means I can tell it what to do without ever having to take the connection off it.

Two details are what make that queue safe rather than merely simple. A command file is deleted before it is executed rather than after, so a crash halfway through an action cannot leave an instruction sitting there to be read and run a second time. And passes never overlap, because some actions are slow enough to still be running when the next one would otherwise start.

The ordinary work

New joiners get a welcome DM, picked at random from several drafts rather than a single one, so a group that gains three members in an evening does not visibly send the same sentence three times. People asking to join are answered before approval instead of after, and whatever they reply comes back attached to their pending request, so whoever approves it reads the answer next to the name.

A blacklist entry removes somebody from every group at once instead of one at a time, and then keeps them out: a blacklisted person who joins again is removed as they arrive. The rest is the routine admin work, removing, adding, deleting a message, rotating an invite link, changing who is allowed to post, all through the same queue.

Adding somebody back is the one action that cannot be promised, because their privacy settings may simply not allow it. When a direct add is refused the daemon sends an invite link instead, which is what an admin would have done anyway.

Knowing which account it is

A moderation bot has to answer one question before it can do anything useful: am I an admin in this group. That turned out to be harder than it sounds, because WhatsApp has been moving to a second identity scheme, and newer groups list their members under an internal id instead of a phone number.

The same account therefore appears as one identity in some groups and a different one in others, and a bot that only recognises itself by its number quietly concludes it has no permissions in precisely the newest groups, which is the least visible way for a tool like this to fail. The daemon holds both identities for itself and matches the member list against either.

Built to stay in good standing

Running this on a real account means the account itself is the thing at risk, so the pacing is not left to whoever is giving the orders. The daemon handles it, and everything it sends stays inside what the platform allows.

Want to know more?

It is part of a bigger private setup. If you would like to find out more about it, contact me.