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%
Find a file
2026-05-13 00:22:23 +01:00
bot.py chore: increase inactivity threshold to 14 days and simplify chat list retrieval logic 2026-05-12 23:40:57 +01:00
CHANGELOG.md refactor: reduce inactivity threshold to 7 days and clean up bounce reports 2026-05-12 11:40:53 +01:00
database.py feat: implement a 30-day grace period for new groups before reporting inactive members 2026-05-07 11:58:35 +01:00
docker-compose.yml chore: configure persistent database paths and bouncer data directory in docker-compose 2026-05-07 11:30:59 +01:00
Dockerfile feat: implement Delta Chat bouncer bot to report inactive group members 2026-05-07 10:54:02 +01:00
icon.png chore: update application icon asset 2026-05-07 13:41:16 +01:00
README.md refactor: reduce inactivity threshold to 7 days and clean up bounce reports 2026-05-12 11:40:53 +01:00
requirements.txt feat: add bot avatar, improve initialization documentation, and print QR code to logs 2026-05-07 11:19:47 +01:00
set_admin.py feat: implement Delta Chat bouncer bot to report inactive group members 2026-05-07 10:54:02 +01:00
update.sh feat: add backup remote support and robust branch detection to update script 2026-05-13 00:22:23 +01:00

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

  1. Clone the repository:

    git clone https://github.com/mrgluek/deltachat_bouncer
    cd deltachat_bouncer
    
  2. 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
    
  3. Start the Bot:

    docker compose up -d
    docker compose logs -f
    

    Note: If it's a new account, a QR code will be printed to the logs for linking your Delta Chat device.

  4. Claim Admin Ownership: Send /initadmin to 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:

  1. Stop the bot: docker compose stop bot
  2. Add relay: docker compose run --rm bot python bot.py init transport backup-email@example.com password
  3. Start the bot: docker compose up -d

Support & Development

If you find this bot useful, consider supporting its development: