langbrain/Python Telegram Bot.md

357 B

Setup WebHook

https://api.telegram.org/bot<bot-token>/setWebhook?url=<webhook-url>

So it your token is 43289:GOOGOOGAGA44 and your FastAPI endpoint is https://bot.foo.bar/webhoot/v1

Then all you have to do is to visit the page:

https://api.telegram.org/bot43289:GOOGOOGAGA44/setWebhook?url=https://bot.foo.bar/webhoot/v1

And it will be set.