Botlegram: Telegram Bot Package for Python¶
- Release v0.0.2
- Based on Telegram Bot API.
- Source code: laplacetw/botlegram
- Stay flexible and keep function naming consistent with the API.
It’s good to use. 🙆♂️
- Quick Start
import botlegram
BOT_TOKEN = "{{your_bot_token}}"
WEBHOOK = "{{your_host}}" + BOT_TOKEN + '/'
bot = botlegram.Bot(BOT_TOKEN, WEBHOOK)
>>> * [Bot] Webhook is already set
Now we have a Telegram bot 🤖
Note
If you’d like to make sure that the Webhook request comes from Telegram, we recommend using a secret path in the URL, e.g. https://www.example.com/<token>. Since nobody else knows your bot’s token, you can be pretty sure it’s from Telegram.