PHPackages                             taitai42/stklog-laravel - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Logging &amp; Monitoring](/categories/logging)
4. /
5. taitai42/stklog-laravel

ActiveLibrary[Logging &amp; Monitoring](/categories/logging)

taitai42/stklog-laravel
=======================

Stklog php package for laravel

v1.5(8y ago)0954bsdPHPPHP ~5.6|~7.0

Since May 11Pushed 8y ago1 watchersCompare

[ Source](https://github.com/taitai42/stklog-laravel)[ Packagist](https://packagist.org/packages/taitai42/stklog-laravel)[ Docs](https://github.com/taitai42/stklog-laravel)[ RSS](/packages/taitai42-stklog-laravel/feed)WikiDiscussions master Synced yesterday

READMEChangelog (7)Dependencies (1)Versions (10)Used By (0)

stklog-laravel
==============

[](#stklog-laravel)

This package is a stklog wrapper to send your log to stklog. please check stklog.io for more information on how to get your project\_key

Install
-------

[](#install)

Via Composer

```
$ composer require taitai42/stklog-laravel
```

add the service provider to your `config/app.php` file

```
'providers' => [
    ...,
    \taitai42\Stklog\StklogServiceProvider::class,
  ],
```

publish the config file :

```
php artisan vendor:publish
```

you can optionnally use the provided stklog middleware that will log all of your request to your app. to do so add this line in your kernel.php file :

```
protected $middleware = [
 ...,

 taitai42\Stklog\Middleware\StklogMiddleware::class,
];
```

Usage
-----

[](#usage)

stklog-laravel package will automatically overwrite the log interface of your laravel app, meaning you can simply use your normal logging way and everything will be forwarded to stklog

you can also declare your own stack by using the stack repository :

```
// use taitai42\Stklog\Model\StackRepository;

StackRepository::stack('incoming request', null, $request->headers->all());
Log::info("parsing request ...");

```

You can also use this handler outside laravel, to do so simply add the new handler with the transport of your choice to your monolog instance :

```
