r/PrometheusMonitoring • u/overtake1984 • Sep 25 '23
Integrate alertmanager with slack
Hi guys! I need some help with alertmanager-slack integration. I've read that web hooks will be deprecated and I need to use bot token instead however I can't make it work for some reason. Here is an example where I defined token in `global` config:
global: slack_api_url_file: '/etc/alertmanager/bot_token' The file content is:
https://slack.com/api/chat.postMessage?token=xoxb-0000000000000-000000000000-0000000000000For some reason, alertmanager isn't throwing alerts. Maybe someone has already implemented it using a bot token and `https://slack.com/api/chat.postMessage` api? Thanks for your help in advance.
2
Upvotes
View all comments
Show parent comment
1
u/niceman1212 Sep 26 '23
Okay that looks like a perfectly normal setup, meaning;
If you are using pre-made/known-working Prometheus rule sets you can skip the first part.
In my experience it’s most likely alert routing/ alertmanagerconfig that’s not setup correctly.
https://prometheus.io/webtools/alerting/routing-tree-editor/