How to Add Telegram as a Proxmox Notification Channel via Webhook

Posted by

In this guide, you’ll learn how to configure Proxmox to send automatic notifications to a Telegram chat using webhooks. This setup is especially useful for system administrators who want a lightweight, fast, and reliable way to monitor Proxmox events without relying on email-based alerts alone.

Below is a guide on how to add a Telegram Bot as a notification channel for Proxmox via Webhook.

– Create Telegram Bot via Botfather (@BotFather)
– On Proxmox, Go to Datacenter | Notifications | Add | Webhook
– Adjust the following fields

Method/URL:

Method: POST
URL: https://api.telegram.org/bot{{ secrets.token }}/sendMessage

Headers:

Key: Content-Type
Value: application/json

Body:

Fill with the following lines

{
  "chat_id": "{{ secrets.chat_id }}",
  "text": "```{{ escape message }}```"
}

Secrets:

Secrets 1:
Key: token
Value: Telegram Bot Token

Secrets 2:
Key: chat_id
Value: UserID or Group ID

To get User ID or Group ID, you can access https://t.me/infoigbot (@infoigbot). Just type /start or /id

Below is the sample configuration

Click “Test” to ensure that the Telegram notification is successful.

Add Notification-by-Telegram that has been created to Notification Matchers. Select Datacenter | Notifications | Notification Matchers | Modify matcher | Target to notify. Tick “Notification-via-Telegram” then click OK

Below is an example of the notification after performing the VM/CT backup process.

Good Luck 🙂

4 comments

  1. Since the body is JSON, it is worth escaping the message body to avoid errors.
    For example:
    {
    “chat_id”: “{{ secrets.chat_id }}”,
    “text”: “{{ escape message }}”
    }

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.