Skip to content

Telegram integration

The Telegram integration currently supports the following features:

  • Webhook subscription.
  • Bot flow.
  • Message types:
    • Text: send and receive.
    • Images: send and receive.
    • Attached documents: send only.
  • Agent support.

Please note

Send refers to messages sent from chatbot-integ to the user, while receive refers to messages sent by the user to chatbot-integ.

To complete the integration, a verification token and the ID of the bot to which the webhook will be assigned are required.

When configuring the webhook, the callback URL must be:

https://bot-integ.obmessage.ai/api/v1/telegram/{CUSTOMER_ID}/{BOT_ID}/{PRONE_ID}

The verification token must be registered in the telegram_bot_config table, in the verification_token column, for the corresponding bot. The subscribed column must have the value 0.

Once the subscription is completed, the token is removed from the database and the subscribed column changes to 1 for the bot.

After registering the webhook, go to the Webhook fields section, click Manage, and subscribe to the messages field in the supported API version.

Source

For more information, you can consult the official Telegram Bot API documentation:

https://core.telegram.org/bots/api