From The Compiler, 5 Years ago, written in Plain Text.
Embed
  1. define contact {
  2.     contact_name sms
  3.     alias SMS
  4.     [...]
  5.     service_notification_commands notify-service-by-sms
  6.     host_notification_commands notify-host-by-sms
  7.     pager +41XXX
  8. }
  9.  
  10. define host {
  11.     use generic-host, pnp-host
  12.     [...]
  13.     contacts sms
  14. }
  15.  
  16. define command {
  17.     command_name notify-host-by-sms
  18.     command_line /usr/local/bin/twilio.sh "$CONTACTPAGER" "$NOTIFICATIONTYPE$ \"$HOSTNAME$\" $HOSTSTATE$ - $HOSTOUTPUT$"
  19. }