super-admin-org / reporter
Exception reporter for laravel
Requires
- php: ^8.0
- ext-json: *
- illuminate/support: ^8.0|^9.0|^10.0|^11.0|^12.0|^13.0
- super-admin-org/super-admin: ^1.0|^2.0
Requires (Dev)
- orchestra/testbench: ^6.0|^7.0|^8.0|^9.0|^10.0|^11.0
- phpunit/phpunit: ^9.5|^10.0|^11.0|^12.0
Suggests
None
Provides
None
Conflicts
None
Replaces
None
README
Stores reported exceptions in the database and shows them in the admin panel: the request, headers, cookies and the stack trace with source code, plus how often the same problem happened.
Documentation: https://super-admin.org/laravel/extension-reporter/
Requirements: PHP 8.0+, Laravel 8 – 13, Super Admin 1.x.
Installation
composer require super-admin-org/reporter
php artisan vendor:publish --tag=super-admin-reporter # Prism highlighter
php artisan migrate
php artisan admin:import reporter
Send exceptions to it.
Laravel 11 and newer, bootstrap/app.php:
use SuperAdmin\Admin\Reporter\Reporter; ->withExceptions(function (Exceptions $exceptions) { $exceptions->report(function (Throwable $e) { Reporter::report($e); }); })
Laravel 8 – 10, app/Exceptions/Handler.php:
public function register() { $this->reportable(function (Throwable $e) { \SuperAdmin\Admin\Reporter\Reporter::report($e); }); }
Open /admin/exceptions.
Privacy
Passwords, tokens, card numbers, Authorization/Cookie headers and cookie values are never stored; they are replaced by [redacted].
Configuration
// config/admin.php 'extensions' => [ 'reporter' => [ 'table' => 'laravel_exceptions', 'redact' => ['national_id'], // extra request fields to hide 'store_cookies' => false, // true keeps cookie values (except redacted names) 'retention_days' => 30, // used by reporter:prune ], ],
Delete old rows with php artisan reporter:prune (or --days=7), for example daily from the scheduler.
Tests
composer install
composer test
License
Licensed under The MIT License (MIT).