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 “Start” button at the bottom of the screen to start @BotFather (Figure 4).

 @BotFather start
Figure 4. @BotFather start

The bot will offer a list of commands that can be used to control it. Click on the /newbot command to create a new chat bot (Figure 5).

 @BotFather command list
Figure 5. @BotFather command list

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

Bot creation, the name of the chatbot is being entered
Figure 6. Bot creation, the name of the chatbot is being entered

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”.

New bot has been created. Telegram immediately sends a link (t.me/bot_username) and a token to it. This is a special key from the bot, with which it can be connected to third-party services (Figure 7). Save the token, you will need it to further configure sending notifications to Telegram.

Bot creation
Figure 7. Bot creation

Recommendations for configuring a bot can be viewed using the /help command.

Connecting a chat bot to the Service#

To connect a bot to the VL NOTIFIER, follow these steps.

In the .env configuration file, in the TELEGRAM_BOT_TOKEN= parameter, specify the token of the created bot where notifications will be sent. ve

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 of the channel using 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