Skip to content

Telegram notifications#

To send notifications to Telegram, you need to create a bot and add it to the chat or group where you want to send notifications.

Creating a chat bot#

Telegram has its own official bot called @BotFather to create chat bots. Enter its name in the search bar and select the bot shown below (Figure 3).

 @BotFather
Figure 3. @BotFather

Click the Open button at the bottom of the screen to launch and select Create a New Bot (Figure 4).

 @BotFather start
Figure 4. @BotFather start

Enter the name of the new bot in the line. This name will be displayed in the group where the bot will be added.

Entering the name of the chatbot
Figure 6. Entering the name of the chatbot

Enter a username for the new bot (Figure 6). Using it, users will be able to find it in Telegram. Username must be unique and end with a word “bot”.

Click Create Bot, and the new chatbot is created. Telegram immediately displays a link to it: t.me/bot_nickname and a token—a special key for the chatbot that can be used to connect it to third-party services (Figure 7). Save the token; you'll need it to further configure notification sending in Telegram.

Bot token
Figure 7. Bot token

Connecting a chat bot to the Service#

To connect a bot to the VL NOTIFIER, specify the token of the bot where notifications will be sent in the .env configuration file in the TELEGRAM_BOT_TOKEN= parameter.

Adding a chat bot to a Telegram channel#

Add the created bot to the channel or chat where notifications will be sent. The bot must have rights (administrator rights) to send messages to the channel. The channel must be public.

Configuring notifications sending in the web interface#

To configure sending notifications to Telegram when working with the Service, follow these steps.

In the “Notifications” section, create a new notification by clicking the “Add” button (Figure 8).

Creating a notification in the web interface
Figure 8. Creating a notification in the web interface

Specify the chat_id of the channel to which you want to send notifications from the bot (Figure 9). You can find out the chat_id via the @username_to_id_bot.

Editing of notification parameters is performed by clicking the button in the line.

Editing a Telegram notification in the web interface
Figure 9. Editing a Telegram notification in the web interface