Skip to content

Notification plugins

Vasily Korytov edited this page Jul 17, 2015 · 6 revisions

jsonmon 1.1 or greater supports custom notifications, that is: not only by mail.

In order to use that, you will need to write a plug-in.
Essentialy, that's a script or a program that accepts three arguments:

  1. true or false string: this is the "failed" check value
  2. check's name
  3. more detailed message (if any)

That is: if we have this check:

- name:   localhost
  web:    http://127.0.0.1
  alert:  ./slack

When it fails, we run:
./slack true localhost "Get http://127.0.0.1: dial tcp 127.0.0.1:80: connection refused"

When it comes back, we run:
./slack false localhost

See slack script for a real-world example

Clone this wiki locally