sleuren / laravel
Official Sleuren SDK for Laravel
Requires
- php: ^7.4 || ^8.0
- guzzlehttp/guzzle: ^6.0.2 || ^7.0
- illuminate/support: ^6.0 || ^7.0 || ^8.0 || ^9.0 || ^10.0
- nesbot/carbon: ^2.62.1
- symfony/var-dumper: ^5.2|^6.0
Requires (Dev)
- friendsofphp/php-cs-fixer: ^3.4
- mockery/mockery: ^1.3.3 || ^1.4.2
- orchestra/testbench: ^4.0 || ^5.0 || ^6.0 || ^7.0 || ^8.0
- phpunit/phpunit: ^8.5.23 || ^9.5.12 || ^10.0.9
README
Official sleuren SDK for Laravel
The Sleuren Laravel error reporter tracks errors and exceptions that happen during the execution of your application and provides instant notification with detailed information needed to prioritize, identify, reproduce and fix each issue.
Getting started
Install
To install the SDK you will need to be using Composer in your project. To install it please see the docs.
This is Laravel SDK, meaning that all the important code regarding error handling lives here.
composer require sleuren/laravel
Configuration
php artisan vendor:publish --provider="Sleuren\ServiceProvider"
And adjust config file (config/sleuren.php) with your desired settings.
Note: by default only production environments will report errors. To modify this edit your Sleuren configuration.
Next is to add the sleuren driver to the logging.php file:
'channels' => [ // ... 'sleuren' => [ 'driver' => 'sleuren', ], ],
After that you have configured the Utah channel you can add it to the stack section:
'channels' => [ 'stack' => [ 'driver' => 'stack', 'channels' => ['single', 'sleuren'], ], //... ],
Usage
All that is left to do is to define env configuration variable.
SLEUREN_KEY=
SLEUREN_KEY: is your Project API key which you've received when creating a project.
Get the variables from your Sleuren dashboard.
Run this in your terminal to test if everything is working:
php artisan sleuren:test
Documentation
For more information, see the documentation.