Filament Discord Logger
Filament settings page for laravel-discord-logger: manage the Discord webhook, level, per-level channels, mentions, deduplication and rate limits from the panel instead of .env.
#Filament Discord Logger
A Filament settings page for laravel-discord-logger: manage the Discord webhook, minimum level, per-level channels, mentions, deduplication and rate limits from the admin panel instead of .env.
Built on top of jeffersongoncalves/laravel-settings-discord-logger, which stores the values with Spatie Laravel Settings and injects them into the logger at runtime.
#Compatibility
| Branch | Filament | Package version |
|---|---|---|
| 1.x | 3.x | ^1.0 |
| 2.x | 4.x | ^2.0 |
| 3.x | 5.x | ^3.0 |
#Installation
composer require jeffersongoncalves/filament-discord-logger:"^3.0"
php artisan migrate
The settings migration seeds every value from your current config, so an app already configured through .env keeps working.
Send logs to the discord channel (registered automatically) from your stack:
// config/logging.php 'stack' => [ 'driver' => 'stack', 'channels' => ['daily', 'discord'], ],
#Usage
Add the plugin to your panel provider:
use JeffersonGoncalves\Filament\DiscordLogger\DiscordLoggerPlugin; public function panel(Panel $panel): Panel { return $panel ->plugins([ DiscordLoggerPlugin::make(), ]); }
Then open Settings > Discord Logger:
| Section | Options |
|---|---|
| Delivery | On/off, webhook URL (empty = keep .env, stored encrypted), minimum level, queue, bot name and avatar |
| Routing & mentions | A webhook per level (e.g. CRITICAL to #alerts) and mentions per level (@here, <@&ROLE_ID>, <@USER_ID>) |
| Message content | Request/job/command context, stacktrace mode, full stacktrace as attachment |
| Noise control | Error grouping, deduplication window and summary, global and per-error rate limits |
Run php artisan discord-logger:test to send a test message to the stored webhook.
#Customization
DiscordLoggerPlugin::make() ->settingsPage(false), // don't register the settings page
#Requirements
- PHP 8.2 or higher
- Filament 5.x
#Testing
composer test
#Changelog
Please see CHANGELOG for more information on what has changed recently.
#Contributing
Please see CONTRIBUTING for details.
#Security Vulnerabilities
Please review our security policy on how to report security vulnerabilities.
#Credits
#License
The MIT License (MIT). Please see License File for more information.