I am trying to configure the Contact points to receive the alerts using the webhook and POST call.
I am running one app as a docker container in the same where Grafana is running as a docker container.
I have chosen the webhook and POST call for the alerts. I have provided the webhook URL and when I am trying to send the test alert to the webhook it’s give the status code 500 Internal Server error
When I checked the log of my app then I am able to see the logs as follows:
{"time": "2024-04-24 17:09:13,087", "timestamp": "1713978553.087072", "filename": "__main__", "level": "INFO", "line": "36", "message": "{'receiver': '', 'status': 'firing', 'alerts': [{'status': 'firing', 'labels': {'alertname': 'TestAlert', 'instance': 'Grafana'}, 'annotations': {'summary': 'Notification test'}, 'startsAt': '2024-04-24T17:09:13.075544949Z', 'endsAt': '0001-01-01T00:00:00Z', 'generatorURL': '', 'fingerprint': '57c6d9296de2ad39', 'silenceURL': 'http://localhost:3000/alerting/silence/new?alertmanager=grafana&matcher=alertname%3DTestAlert&matcher=instance%3DGrafana', 'dashboardURL': '', 'panelURL': '', 'valueString': "[ metric='foo' labels={instance=bar} value=10 ]"}], 'groupLabels': {}, 'commonLabels': {'alertname': 'TestAlert', 'instance': 'Grafana'}, 'commonAnnotations': {'summary': 'Notification test'}, 'externalURL': 'http://localhost:3000/', 'version': '1', 'groupKey': '{alertname="TestAlert", instance="Grafana"}2024-04-24 17:09:13.075544949 +0000 UTC m=+208509.513153065', 'truncatedAlerts': 0, 'orgId': 1, 'title': '[FIRING:1] (TestAlert Grafana)', 'state': 'alerting', 'message': "**Firing**\n\nValue: [ metric='foo' labels={instance=bar} value=10 ]\nLabels:\n - alertname = TestAlert\n - instance = Grafana\nAnnotations:\n - summary = Notification test\nSilence: http://localhost:3000/alerting/silence/new?alertmanager=grafana&matcher=alertname%3DTestAlert&matcher=instance%3DGrafana\n"}"}
{"time": "2024-04-24 17:09:13,087", "timestamp": "1713978553.087288", "filename": "__main__", "level": "ERROR", "line": "52", "message": "'hS6vE1qNiqQ5XkAapKOb8ACKi7luqgQSjUg84qrf'"}
{"time": "2024-04-24 17:09:25,326", "timestamp": "1713978565.326303", "filename": "__main__", "level": "INFO", "line": "36", "message": "{'receiver': '', 'status': 'firing', 'alerts': [{'status': 'firing', 'labels': {'alertname': 'TestAlert', 'instance': 'Grafana'}, 'annotations': {'summary': 'Notification test'}, 'startsAt': '2024-04-24T17:09:25.315676655Z', 'endsAt': '0001-01-01T00:00:00Z', 'generatorURL': '', 'fingerprint': '57c6d9296de2ad39', 'silenceURL': 'http://localhost:3000/alerting/silence/new?alertmanager=grafana&matcher=alertname%3DTestAlert&matcher=instance%3DGrafana', 'dashboardURL': '', 'panelURL': '', 'valueString': "[ metric='foo' labels={instance=bar} value=10 ]"}], 'groupLabels': {}, 'commonLabels': {'alertname': 'TestAlert', 'instance': 'Grafana'}, 'commonAnnotations': {'summary': 'Notification test'}, 'externalURL': 'http://localhost:3000/', 'version': '1', 'groupKey': '{alertname="TestAlert", instance="Grafana"}2024-04-24 17:09:25.315676655 +0000 UTC m=+208521.753284784', 'truncatedAlerts': 0, 'orgId': 1, 'title': '[FIRING:1] (TestAlert Grafana)', 'state': 'alerting', 'message': "**Firing**\n\nValue: [ metric='foo' labels={instance=bar} value=10 ]\nLabels:\n - alertname = TestAlert\n - instance = Grafana\nAnnotations:\n - summary = Notification test\nSilence: http://localhost:3000/alerting/silence/new?alertmanager=grafana&matcher=alertname%3DTestAlert&matcher=instance%3DGrafana\n"}"}
When I am trying to save the contact point I am getting a different error.
I am a little bit new to Grafana alerting. Could you please help me how to configure the alerts using the webook?
Thanks