Setup
- Add or edit a bot in the web UI
- Enable Proxy mode
- Set Backend URL to the webhook endpoint (e.g.,
https://legacy-bot.example.com/webhook) - Optionally set Secret Token (sent as
X-Telegram-Bot-Api-Secret-Tokenheader) - Save
Automatic setup via API proxy
If your backend uses the API proxy (/tgapi/), you can skip manual configuration entirely. When your backend calls setWebhook through the proxy, BotMux automatically:
- Registers the bot (if not already known) by calling Telegram’s
getMe - Sets the webhook URL as the bot’s backend URL
- Enables proxy mode
- Starts polling Telegram and forwarding updates to your backend
http://your-botmux:8080/tgapi/bot{TOKEN}/setWebhook and it will configure itself with no manual steps.
Similarly, calling deleteWebhook through the proxy disables forwarding and clears the backend URL.
Webhook responses
The backend can respond with a webhook-style reply — JSON with amethod field — and BotMux will proxy it back to the Telegram API.
Health monitoring
- Automatic health checks every 60 seconds
- Status visible in the dashboard
- Manual CHECK WEBHOOK button in bot detail view