Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

Telegram bot for automatically banning spammers in Telegram chats. Can generate captcha, reports and has integration with LLM.

License

NotificationsYou must be signed in to change notification settings

PlugFox/vixen

Repository files navigation

CheckoutBuildDockerHubLicense: MIT

Telegram Vixen Bot is a bot for automatically banning spammers in Telegram chats.Written in Dart that helps prevent spam in Telegram groupsby generating and sending CAPTCHA challenges to new users with a virtual keyboard.It automatically deletes initial messages from unverified users and supports multiple blocking modes.

✨ Features

  • CAPTCHA Verification: Requires new users to complete a CAPTCHA before they can send messages.
  • Blocking Modes: Supports different verification and restriction mechanisms.
  • Admin API: Provides an API for managing bot settings and operations.
  • SQLite Storage: Stores persistent data in an SQLite database.
  • Group-Specific Monitoring: Watches only designated groups.
  • Metrics Support: Tracks bot performance and user activity.
  • Flexible Configuration: Configurable via command-line arguments,.env file, or environment variables.
  • Cross-Platform: Runs on Windows, macOS, and Linux, Docker. AMD64 and ARM64 architectures are supported.
  • Combot Anti-Spam: Checks messages with Combot Anti-Spam API.
  • Reports: Sends reports about activity in the chat.
  • Summary: Sends a summary of the chat activity for the last 24 hours.
  • Clown Reactions: Reacts to messages with a clown emoji.
  • Open-Source: Available under the MIT License.

🛡️ Manages the following chats

🚀 Getting Started

The bot supports configuration via command-line arguments, environment variables, or a.env file.

💻 Minimum System Requirements

To run the Telegram Vixen Bot, ensure your system meets the following minimum requirements:

  • Operating System: Windows, macOS, or a recent Linux distribution
  • Processor: x86_64 or ARM64
  • Memory: 128 MB RAM
  • Storage: 100 MB available space
  • Docker: (Optional) For running the bot in a containerized environment

🔧 Install Dependencies

Ensure you haveDart SDK installed. Then, run:

dart pub getdart run build_runner build --delete-conflicting-outputs

▶ Run the Bot

You can start the bot using command-line arguments:

dart run bin/vixen.dart --token=123:ABC-DEF --chats=123,-456,-789 --secret=1234567890

Or set the configuration using environment variables:

export CONFIG_TOKEN="123:ABC-DEF"export CONFIG_CHATS="123,-456,-789"export CONFIG_SECRET="1234567890"dart run bin/vixen.dart

Alternatively, create a.env file:

echo"token=123:ABC-DEF"> .envecho"chats=123,-456,-789">> .envecho"secret=1234567890">> .env

Then, start the bot:

dart run bin/vixen.dart

⚙️ Configuration

ArgumentEnvironmentDescriptionDefault
-t--tokenCONFIG_TOKEN(Required) Telegram bot token
-c--chatsCONFIG_CHATSComma-separated list of chat IDs
-s--secretCONFIG_SECRETSecret admin API key
-d--dbCONFIG_DBPath to the SQLite database filedata/vixen.db
-a--addressCONFIG_ADDRESSAddress to bind the server to0.0.0.0
-p--portCONFIG_PORTPort to bind the server to8080
-v--verboseCONFIG_VERBOSELogs:all/debug/info/warn/errorwarn
--offsetCONFIG_OFFSETOffset for Telegram updates-
--casCONFIG_CASCheck messages with Combot Anti-Spamon
--report-hourCONFIG_REPORT-HOURThe hour to send daily report17
--openai-keyCONFIG_OPENAI-KEYOpenAI API key for summarization
--openai-urlCONFIG_OPENAI-URLOpenAI API endpoint
--openai-modelCONFIG_OPENAI-MODELOpenAI modelgpt-4o-mini
--clownCONFIG_CLOWNChance of clown reaction0

To see all available options, run:

dart run bin/vixen.dart --help

🏗️ Building

🛠️ How to compile

dart pub getdart run build_runner build --delete-conflicting-outputsdart compile exe bin/vixen.dart -o vixen.run

🐋 How to Docker

docker build -t vixen:latest.docker compose up

📝 Contributers

🤝 Funding

If you want to support the development of our library, there are several ways you can do it:

We appreciate any form of support, whether it's a financial donation or just a star on GitHub. It helps us to continue developing and improving our library. Thank you for your support!

📜 License

This project is licensed underThe MIT License.


[8]ページ先頭

©2009-2025 Movatter.jp