xitobot is a multi-funcional modular telegram bot with group management features and all sorts of useful tools.
I'm not a professional dev, this is my first big project ever and my first time working with PTB and PyMongo or almost any other Python lib. I took inspiration from @PaulSonOfLars tgbot, once called Marie, now deprecated and replaced by Rose
It's built with Python 3.10.12 using PTB (Python-Telegram-Bot), a really easy-to-use wrapper for the Telgram Bot API.
If you want to learn more about it check the official site's documentation and the Github page which contains kind of a really basic tutorial on how to build your first Telgram Bot using the wrapper.
For database related modules i'm using MongoDB paired with PyMongo to work with the db from Python, but you can use whatever you like the most. All modules that make use of the DB are located in db_modules
Here are the links to the documentation to install Mongo:
- Windows
- Linux Ubuntu (If you're using any other distro check this)
- MacOS
- Docker
You can install all Python dependencies using
pip3 install -r requirements.txt
inside of the root folder of the bot (xitobot)
The bot is based on a config.py file which only contains a class with all the globally needed variables:
- API token
- Base_url
- Base_url_file (required if you're hosting the Telegram Bot API on your machine)
- Database_url
- Load order ...
As the project is still work in progress i can't provide a full list of all the variables that'll be needed, but i'll try to keep this updated. I'll provide a config example of how the config.py should look
Once you've set up everything you need, the database, the config and the dependencies, you can run the bot from the root folder using the following command:
python3 -m xitobot_code
In case you have trouble setting up the bot you can find a bunch of contacts to find me in my profile :)
Good luck!!