alerting/integrations:telegram-update (#90105)

* alerting/integrations:telegram-update

* Update docs/sources/alerting/configure-notifications/manage-contact-points/integrations/configure-telegram.md

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>

* Update docs/sources/alerting/configure-notifications/manage-contact-points/integrations/configure-telegram.md

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>

---------

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
This commit is contained in:
antonio 2024-07-05 10:18:15 +02:00 committed by GitHub
parent e299621766
commit 8bc8b4b31f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 15 additions and 25 deletions

View File

@ -31,6 +31,11 @@ refs:
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/manage-contact-points/integrations/configure-email/
- pattern: /docs/grafana-cloud/
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/manage-contact-points/integrations/configure-email/
discord:
- pattern: /docs/grafana/
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/manage-contact-points/integrations/configure-discord/
- pattern: /docs/grafana-cloud/
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/manage-contact-points/integrations/configure-discord/
telegram:
- pattern: /docs/grafana/
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/manage-contact-points/integrations/configure-telegram/
@ -56,6 +61,11 @@ refs:
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/manage-contact-points/integrations/configure-slack/
- pattern: /docs/grafana-cloud/
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/manage-contact-points/integrations/configure-slack/
teams:
- pattern: /docs/grafana/
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/configure-notifications/manage-contact-points/integrations/configure-teams/
- pattern: /docs/grafana-cloud/
destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/manage-contact-points/integrations/configure-teams/
external-alertmanager:
- pattern: /docs/grafana/
destination: /docs/grafana/<GRAFANA_VERSION>/alerting/set-up/configure-alertmanager/
@ -144,13 +154,13 @@ The following table lists the contact point integrations supported by Grafana.
| Alertmanager | `prometheus-alertmanager` |
| Cisco Webex Teams | `webex` |
| DingDing | `dingding` |
| Discord | `discord` |
| [Discord](ref:discord) | `discord` |
| [Email](ref:email) | `email` |
| Google Chat | `googlechat` |
| [Grafana Oncall](ref:oncall) | `oncall` |
| Kafka REST Proxy | `kafka` |
| Line | `line` |
| Microsoft Teams | `teams` |
| [Microsoft Teams](ref:teams) | `teams` |
| Opsgenie | `opsgenie` |
| [Pagerduty](ref:pagerduty) | `pagerduty` |
| Pushover | `pushover` |

View File

@ -29,7 +29,7 @@ For longer messages, we recommend using an alternative contact method.
### Telegram bot API token and chat ID
To integrate Grafana with Telegram, you need to obtain a Telegram **bot API token** and a **chat ID** (i.e., the ID of the Telegram chat where you want to receive the alert notifications).
To integrate Grafana with Telegram, you need to get a Telegram **bot API token** and a **chat ID** (the ID of the Telegram chat where you want to receive the alert notifications). To complete the integration, use the browser version of Telegram.
### Set up your Telegram bot
@ -49,29 +49,9 @@ Add the bot to a group chat by following the steps below. Once the bot is added
1. In the Telegram app, **open a group or start a new one**.
1. Search and **add the bot to the group**.
1. **Interact with the bot** by sending a dummy message that starts with "`/`". E.g. `/hola @bot_name`.
1. Copy the **chat ID** from the URL in your browser's address bar. It should look like this: `https://web.telegram.org/a/#-4266674385`.
{{< figure src="/media/blog/telegram-grafana-alerting/telegram-screenshot.png" alt="A screenshot that shows a message to a Telegram bot." >}}
1. To obtain the **chat ID**, send an [HTTP request](https://core.telegram.org/bots/api#getupdates) to the bot. Copy the below URL and replace `{your_bot_api_token}` with your bot API token.
```
https://api.telegram.org/bot{your_bot_api_token}/getUpdates
```
1. **Paste the URL in your browser**.
1. If the request is successful, it will return a response in JSON format.
```
...
"chat": {
"id": -4065678900,
"title": "Tony and Hello world bot",
"type": "group",
...
```
1. Copy the value of the `“id”` that appears under `“chat”`.
The chat ID is the sequence of numbers that follows the `#` symbol. For example: `-4266674385`.
## Procedure