1.2 KiB
1.2 KiB
Track 15 - Telegram Chat Runbook
Required env
TELEGRAM_BOT_ENABLED=1TELEGRAM_BOT_TOKENTELEGRAM_WEBHOOK_SECRETTELEGRAM_DEFAULT_QUEUE_ID
Optional:
TELEGRAM_BOT_API_BASEwhen running against a stub or proxy
Register the bot webhook
Use Telegram Bot API setWebhook with:
- URL -> your public
telegram-adapter-servicewebhook path:/integrations/telegram/bot/webhook
- secret token ->
TELEGRAM_WEBHOOK_SECRET
Operator workflow
- Open
/operator - Go to the
Telegrampage - Wait for a real inbound bot message
- Select the thread from the left list
- Click
Принять в работу - Reply from the composer
- Close or escalate the thread if needed
Runtime behavior
- one Telegram thread is stored per
chat_id - new inbound messages reuse the same
thread_idandinteraction_id - if the linked interaction was
closed, a new inbound message reactivates it tonew - unsupported inbound Telegram content is stored as a visible system placeholder
QA check
- send one first message from Telegram -> thread appears
- send a second message from the same
chat_id-> same thread is reused - operator claim works
- operator reply appears in the thread and is sent via Bot API