- A simple telegram bot that can send messages to a channel or group
- Python 3.10 or higher
- Telegram Bot Token
- Virtual Environment
- Docker (optional)
- Create a virtual environment
virtualenv venv- Activate the virtual environment
source venv/bin/activate- Install dependencies
pip install -r requirements.txt- Create .env file in the
/appdirectory and add the following (replace<your-telegram-bot-token>with your telegram bot token) How to get a telegram bot token: https://sendpulse.com/knowledge-base/chatbot/telegram/create-telegram-chatbot#create-bot
TELEGRAM_BOT_TOKEN=<your-telegram-bot-token>- Run the bot
python main.py- Go to your telegram bot and send a message to it
- Available commands:
/hello- sends a hello message/clock- sends the current time/timer {seconds}- sets a timer for the specified seconds