A demo project that shows how multiple APIs can be integrated.
- Python 3.10+
- Telegram Bot Token
- Gemini API Key
-
Clone the repository:
git clone https://github.com/Unisami/Telegram-Ai-Bot cd Telegram-Ai-Bot -
Install the required packages:
pip install pyTelegramBotAPI google-generativeai python-dotenv
-
Set up environment variables:
- Add your API keys to the
.envfile.
- Add your API keys to the
-
Run the bot:
python tbot.py
-
Interact with the bot on Telegram. Send
/startor/helpto initiate a conversation. The bot will respond to other messages using Gemini AI.
TELEGRAM_BOT_TOKEN: The token for your Telegram bot, obtained from BotFather.GEMINI_API_KEY: The API key for accessing the Gemini AI model.