Hi All,
I am trying to connect MS Teams with Grafana using webhooks. I have the webhook URL and I tried using a Powershell script to push a demo payload to Teams using the same webhook.
[Invoke-RestMethod -Method post -ContentType ‘Application/Json’ -Body ‘{“text”:“Connector Test”}’ -Uri https://outlook.office.com/webhook/23654d38-7059-4fed-a20f-3cd753fb9ff4@5af76741-f886-4d20-ad04-775dee0ce762/IncomingWebhook/a40a369a41cc4c659a18085cf0df4c7d/27952bfc-5298-4a25-95aa-8eaa3dad4317]
However, when I use the same webhook details from inside grafana and send test,I get an error.
[t=2020-03-06T12:33:34+0530 lvl=eror msg=“Failed to send alert notifications” logger=context userId=1 orgId=1 uname=admin error=“Post https://outlook.office.com/webhook/23654d38-7059-4fed-a20f-3cd753fb9ff4@5af76741-f886-4d20-ad04-775dee0ce762/IncomingWebhook/a40a369a41cc4c659a18085cf0df4c7d/27952bfc-5298-4a25-95aa-8eaa3dad4317: dial tcp 13.107.18.11:443: connectex: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.”
t=2020-03-06T12:33:34+0530 lvl=eror msg=“Request Completed” logger=context userId=1 orgId=1 uname=admin method=POST path=/api/alert-notifications/test status=500 remote_addr=[::1] time_ms=24831 size=48 referer=http://grafana.staged-by-discourse.com/alerting/notification/5/edit
]
Configuration -
- Grafana - Grafana v6.5.2 (742d165)
- Data source - MSSQL