mirror of
https://github.com/mrgluek/deltachat_bouncer.git
synced 2026-05-13 01:45:56 +02:00
A Delta Chat bot designed to monitor large groups and report users who haven't been seen online for over 30 days.
- Python 94.8%
- Shell 4.4%
- Dockerfile 0.8%
| bot.py | ||
| CHANGELOG.md | ||
| database.py | ||
| docker-compose.yml | ||
| Dockerfile | ||
| icon.png | ||
| README.md | ||
| requirements.txt | ||
| set_admin.py | ||
| update.sh | ||
Delta Chat Bouncer Bot
A professional Delta Chat bot designed to maintain group quality by monitoring inactivity. It automatically scans group members and reports users who haven't been seen online for over 7 days.
Features
- 📊 Daily Status & Inactivity Report: Automatically scans all groups once a day. Posts group statistics (total members, active count), a list of inactive members, and a Top 10 Posters ranking for the last 24 hours.
- 📬 Relay Check (
/relays): Scan for group members using regular mail providers. - 🏆 Activity Ranking (
/top): Show the 10 most active members in the last 24 hours. - 👤 Contact Sharing: Commands like
/relays,/top, and inactivity reports now include/contact<ID>links to quickly get a contact object for any user. - ⏳ 7-Day Grace Period: For new groups, the bot waits 7 days before reporting "never seen" users to avoid false positives.
- 🚀 Manual Check (
/bounce): Anyone can trigger an immediate inactivity check (with a 10-minute cooldown per group). - 🛡️ Secure Administration: Claim ownership with
/initadmin. Admins bypass rate limits and have exclusive control over bot settings and group scanning. - 📱 QR Code Link: Generates a SecureJoin QR code in the logs for easy device linking.
- 🐳 Docker Ready: Easy deployment using Docker Compose.
Setup
-
Clone the repository:
git clone https://github.com/mrgluek/deltachat_bouncer cd deltachat_bouncer -
Initialize Account: Run the initialization command once to set up the bot's email and password:
docker compose run --rm bot python bot.py init bot-email@example.com your_password -
Start the Bot:
docker compose up -d docker compose logs -fNote: If it's a new account, a QR code will be printed to the logs for linking your Delta Chat device.
-
Claim Admin Ownership: Send
/initadminto the bot in a private message to become the administrator.
Commands
/bounce— Trigger an immediate inactivity check in the current group./relays— Find group members using regular mail providers./top— Show the 10 most active members in the last 24 hours./contact<ID>— Get a contact object for the given ID (e.g.,/contact123)./help— Show available commands and bot information (Threshold: 7 days)./donate— Support project development ❤️/initadmin— Claim administrative ownership (private chat only).
Admin Management
You can manually manage the administrator or add backup transports via the server CLI:
Set Administrator
docker compose exec bot python set_admin.py --email your@email.com
Add Backup Relay (Transport)
To ensure the bot stays online even if one mail server is down:
- Stop the bot:
docker compose stop bot - Add relay:
docker compose run --rm bot python bot.py init transport backup-email@example.com password - Start the bot:
docker compose up -d
Support & Development
If you find this bot useful, consider supporting its development:
- GitHub: mrgluek/deltachat_bouncer
- Donations: Use the
/donatecommand in Delta Chat.