Webhook alerts enables you to integrate WebGazer into your existing stack. You can build all kind of interesting stuff like creating a ticket on the incident management tool of your choice or getting notifications on custom platforms you use.
You can add a webhook alert under the Alerts section.
Choose your alert schedule
When an incident starts or ends if you want to get two notifications, one at the start and one at the end of an incident
When an incident starts if you want to get a notification only at the start of an incident
When an incident ends if you want to get a notification only at the end of an incident
Choose when you want to get an alert
Immediately, if you want to get an alert when an incident is registered
If it lasts, if you want to get an alert if the incident continues for more than a certain time duration
Click Add Alert
Now, an HTTP POST request is fired consistent with your alert preferences when an incident occurs.
š” Learn more about alerts on e-mail alerts, Slack alerts, SMS/phone call alerts.
An HTTP POST request with JSON payload will hit the URL set, when an incident starts (or X minutes later, if you set so) and end.
incident.started_at
and incident.ended_at
are combined date and times in ISO 8601 format.
The request will have these headers set:
Content-Type: application/json
User-Agent: WebGazer/1.0 (+https://www.webgazer.io)
Here is an example request body for a started incident notification:
{
"source": "GAZERS",
"source_id": 42,
"period": {
"state": "DOWN",
"started_at": "2018-10-21T06:44:29.614354+00:00",
"ended_at": null
},
"description": "Heads up: Gazer Aperture Science is down!"
}
And this example is for an ended incident notification:
{
"source": "GAZERS",
"source_id": 42,
"period": {
"state": "UP",
"started_at": "2018-10-21T06:44:29.614354+00:00",
"ended_at": "2018-10-21T06:45:28.781799+00:00"
},
"description": "Phew: Gazer Aperture Science has recovered."
}
The source of the incident.
Possible values: GAZERS, PULSES
The ID of the affected gazer or pulse.
State, start and end data of the relevant period.
State data of the relevant period.
Possible values: WAITING, UP, DOWN, UNDERPERFORMING, PAUSED
Start date/time of the relevant period in ISO 8601 format.
End date/time of the relevant period in ISO 8601 format.
A short, human-readable message for the notification.