Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Select an option

  • Save wyukawa/390c70f976106c542dbc29225bd5c07a to your computer and use it in GitHub Desktop.

Select an option

Save wyukawa/390c70f976106c542dbc29225bd5c07a to your computer and use it in GitHub Desktop.
$ curl -s http://localhost:9093/api/v1/alerts/groups | jq "."
{
"data": null,
"status": "success"
}
$ curl -s http://localhost:9093/api/v1/alerts/groups | jq "."
{
"data": [
{
"blocks": [
{
"alerts": [
{
"silenced": 1,
"inhibited": false,
"generatorURL": "http://localhost:9090/graph#%5B%7B%22expr%22%3A%22up%20%3D%3D%200%22%2C%22tab%22%3A0%7D%5D",
"endsAt": "0001-01-01T00:00:00Z",
"startsAt": "2016-05-05T14:31:38.808+09:00",
"annotations": {
"summary": "Instance localhost:9100 down",
"description": "localhost:9100 of job node has been down for more than 5 minutes."
},
"labels": {
"severity": "page",
"monitor": "codelab-monitor",
"job": "node",
"instance": "localhost:9100",
"alertname": "InstanceDown"
}
}
],
"routeOpts": {
"repeatInterval": 1.08e+13,
"groupInterval": 3e+11,
"groupWait": 3e+10,
"groupBy": [
"alertname",
"cluster"
],
"receiver": "team-X-mails"
}
}
],
"labels": {
"alertname": "InstanceDown"
}
}
],
"status": "success"
}
$ curl -s http://localhost:9093/api/v1/alerts/groups | jq "."
{
"data": [
{
"blocks": null,
"labels": {
"alertname": "InstanceDown"
}
}
],
"status": "success"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment