drinks-it/monitoring

Miscellaneous monitoring tools

1.1.1 2021-05-17 11:36 UTC

This package is auto-updated.

Last update: 2024-04-19 16:30:24 UTC


README

OPSGENIE_API_KEY env var should be defined, otherwise 'Could not authenticate' error occurrs (safe fail, no exceptions)

Usage:

<?php

require_once __DIR__ . '/vendor/autoload.php';

$ops = new \Monitoring\Alert\Opsgenie();
$desc = <<< MSG
<strong>Alert H1</strong>
<a href="https://www.example.com">Click</a> here
Simple Text is also fine 
you can do some line brakes.
Like
this.
MSG;

var_dump($ops->raise("Alert subject", $desc));