PHP code example of hebrahimzadeh / laravel-mattermost-logger
1. Go to this page and download the library: Download hebrahimzadeh/laravel-mattermost-logger 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/ */
hebrahimzadeh / laravel-mattermost-logger example snippets
'mattermost' => [
'driver' => 'custom',
'via' => ThibaudDauce\MattermostLogger\MattermostLogger::class,
'webhook' => env('MATTERMOST_WEBHOOK'),
],
'stack' => [
'driver' => 'stack',
'channels' => ['single', 'mattermost'],
],
logger()->info('Some message', [
'context' => 'Some contex',
'an_array_of_things' => ['foo', 'bar', 'baz'],
]);
// Or
throw new Exception('An exception occured');