Filament Activity Log
Filament Activity Log provides a Filament resource, timeline actions, widgets, exports, and audit-focused helpers on top of spatie/laravel-activitylog.
Install the package with Composer, register AlizHarb\ActivityLog\ActivityLogPlugin::make() in the Filament panel, and run php artisan filament-activity-log:install. Existing applications upgrading to v2 must publish the package migration, migrate, backfill metadata, and run the doctor command.
Use Spatie's LogsActivity trait on models that should be audited. For Spatie v5, make sure the official v5 migration has been completed before relying on this package. Spatie v4 stores changes in properties; Spatie v5 stores them in attribute_changes. This package reads both.
Do not intentionally log passwords, tokens, API keys, secrets, or private keys. The package redacts configured sensitive fields before display, but redaction is a safety layer and not a reason to store secrets in activity logs.
Use the configured risk system to highlight destructive, security-sensitive, and privacy-sensitive activity. Customize filament-activity-log.risk or provide a resolver class when application-specific scoring is required.
UI immutable mode only hides package actions. It does not make the database immutable. Use integrity verification to detect row modification and retain database access controls, backups, and external retention policies.
Configure a global activity query scope for every tenant-separated panel. Mutations and exports are disabled unless explicitly authorized. Restore and revert must also pass the subject model policy.
Activity tables can grow quickly. Keep filters selective, avoid rendering large JSON payloads in table rows, and add database indexes for common filters such as created_at, event, log_name, causer_type/causer_id, and subject_type/subject_id.
Use ActivitiesRelationManager to add model-specific history to resources. Use ActivityLogTimelineTableAction when a compact slide-over timeline is better than navigating to the full resource.