phpinnacle / casus
Exception recording and inspection for Laravel Filament applications.
Requires
- php: ^8.4
- filament/filament: ^4.0|^5.0
- phiki/phiki: ^2.2
- phpinnacle/tempo: ^1.0
- spatie/laravel-package-tools: ^1.92
This package is auto-updated.
Last update: 2026-09-01 15:41:19 UTC
README
Casus is an application exception recorder and Filament exception browser. It stores reportable failures with request context and gives authorized panel users a searchable interface for inspecting stack traces and request data.
Features
- Automatic integration with Laravel's exception reporting pipeline.
- Captures exception class, message, code, file, line, trace and occurrence count.
- Captures HTTP method, URL, IP address, request headers and request body when available.
- Groups repeated failures and updates their latest occurrence.
- Filament resource with syntax-highlighted exception details.
- Configurable retention using Laravel's prunable model support.
- Optional separate database connection and tenant association.
- Policy-backed view and delete permissions.
Requirements
- PHP 8.4 or later
- Laravel 13
- Filament 5
Installation
composer require phpinnacle/casus
php artisan vendor:publish --tag="phpinnacle-casus-migrations"
php artisan migrate
Publish the configuration when you need to customize navigation, retention, connection or tenancy:
php artisan vendor:publish --tag="phpinnacle-casus-config"
Registering the plugin
use Filament\Panel; use PHPinnacle\Casus\CasusPlugin; public function panel(Panel $panel): Panel { return $panel->plugin(CasusPlugin::make()); }
Casus registers the Exceptions resource in that panel. Access is controlled by ExceptionPolicy; your authenticated user must support the permissions expected by the application.
Configuration
return [ 'navigation' => [ 'exception' => ['icon' => 'phosphor-bug', 'sort' => 1000], ], 'prune' => 30, 'connection' => null, 'tenancy' => null, ];
pruneis the number of days retained by the model's prunable query.connectionselects a database connection for exception records;nulluses Laravel's default.tenancymay define a tenant model and default tenant identifier.
Schedule Laravel's model pruning command if automatic retention is required:
use Illuminate\Support\Facades\Schedule; Schedule::command('model:prune')->daily();
Never expose the resource to untrusted users: request bodies, headers and traces can contain sensitive operational data.
Testing
composer test
Changelog
See CHANGELOG for recent changes.
License
The MIT License (MIT). See License File.