PHP code example of spresnac / logcrawler-client

1. Go to this page and download the library: Download spresnac/logcrawler-client 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/ */

    

spresnac / logcrawler-client example snippets


'channels' => [
    //...
    'logcrawler' => [
        'driver' => 'monolog',
        'level' => 'debug',
        'handler' => LogCrawler::class,
        'handler_with' => [
            'host' => config('logcrawler.url'),
            'key' => config('logcrawler.key'),
        ],
    ],
    //...
],

'channels' => [
    //...
    'logcrawler' => [
        'driver' => 'monolog',
        'level' => 'debug',
        'handler' => LogCrawler::class,
        'with' => [
            'host' => config('logcrawler.url'),
            'key' => config('logcrawler.key'),
        ],
    ],
    //...
],

'stack' => [
    'driver' => 'stack',
    'channels' => ['daily', 'logcrawler'],
    'ignore_exceptions' => false,
],

php artisan vendor:publish --tag=logcrawlerclient-config

LOG_CRAWLER_KEY="place_your_key_here"

LOG_CRAWLER_THRESHOLD=<INT>