PHP code example of noxomix / operational-monolog

1. Go to this page and download the library: Download noxomix/operational-monolog library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

noxomix / operational-monolog example snippets


use Monolog\Logger;
use Noxomix\OperationalMonolog\OperationalHandler;

$logger = new Logger('operational');

$handler = new OperationalHandler('your-api-key-here');
$logger->pushHandler($handler);

$logger->info('User signup', ["name" => "Alfredo", "email" => "[email protected]"]);