Skip to content

Instantly share code, notes, and snippets.

Forked from ilap/
Created August 8, 2022 03:31
Show Gist options
  • Save evtuhovdo/882f04edc807228f57566963f5afd628 to your computer and use it in GitHub Desktop.
Save evtuhovdo/882f04edc807228f57566963f5afd628 to your computer and use it in GitHub Desktop.
Grafana Telegram Alert

Config Telegrambot for grafana's alerts.

1. Create bot

Open Telegram and search for @BotFather user and message them the following:


Alright, a new bot. How are we going to call it? Please choose a name for your bot.


Good. Now let's choose a username for your bot. It must end in `bot`. Like this, for example: TetrisBot or tetris_bot.


Done! Congratulations on your new bot. You will find it at You can now add a description, about section and profile picture for your bot, see /help for a list of commands. By the way, when you've finished creating your cool bot, ping our Bot Support if you want a better username for it. Just make sure the bot is fully operational before you do this.

Use this token to access the HTTP API:
Keep your token secure and store it safely, it can be used by anyone to control your bot.

For a description of the Bot API, see this page:

2. Create a Channel and retrieve the channel's chat ID.

  • Create a channel in telegram and name it whatever you like. e.g. MyCardanoMonitoring or similar
  • Invite @BotFather to that channel as admin
  • Type at least one message, this is very important
  • Get the Chat id:<YOUR API TOKE FROM ABOVE>/getUpdates

Config Telegram in Grafana

  • Login to grafana
  • Click to the left Bell icon
  • Add notification channel
  • Select Telegram
  • Enable/disable settings you preger
  • Put Telegram API token to he fiel
  • Add chat ID (it starts with -, and that needs too)
  • Click Test notification
  • Save it.

Add alert

  • Go to dashboard
  • Select "Jormungandr Monitor"
  • Select "Jormungandr Last Block Height", ckicj edit
  • Click Alarm icon
  • Click "Create Alert"
  • Edit the fields, see details below: Screen Shot 2019-12-20 at 8 14 31 pm
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment