Skip to content

Instantly share code, notes, and snippets.

@jonog
Created March 15, 2017 20:59
Show Gist options
  • Select an option

  • Save jonog/32c953aedf03edf71acaef53d89ce785 to your computer and use it in GitHub Desktop.

Select an option

Save jonog/32c953aedf03edf71acaef53d89ce785 to your computer and use it in GitHub Desktop.
{
"checks": [
{
"name": "Demo HTTP Status Check",
"type": "web-ping",
"send_alerts": [
"stderr"
],
"backoff": {
"type": "constant",
"interval": 10
},
"config": {
"address": "http://httpstat.us/200",
"headers": {
"X-Api-Key": "ABCD1234"
}
},
"assertions": [
{
"source": "metadata",
"identifier": "status_code",
"comparison": "==",
"target": "200"
}
]
},
{
"name": "Demo Response Check",
"type": "web-ping",
"send_alerts": [
"stderr"
],
"backoff": {
"type": "linear",
"interval": 10
},
"config": {
"address": "http://httpstat.us/400"
},
"assertions": [
{
"source": "metric",
"identifier": "latency",
"comparison": "less than",
"target": "1100"
},
{
"source": "metadata",
"identifier": "status_code",
"comparison": "==",
"target": "400"
},
{
"source": "text",
"identifier": "",
"comparison": "==",
"target": "400 Bad Request"
}
]
}
],
"notifications": [],
"preferences": {
"notifications": {}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment