Download the PHP package xlite-dev/filament-impersonate without Composer
On this page you can find all versions of the php package xlite-dev/filament-impersonate. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download xlite-dev/filament-impersonate
More information about xlite-dev/filament-impersonate
Files in xlite-dev/filament-impersonate
Package filament-impersonate
Short Description Switch between accounts in Filament: impersonate users, linked sub-accounts with password-confirmed escalation, and one-click developer logins. The panel UI of packstub/account-switcher.
License MIT
Homepage https://github.com/packstub/filament-account-switcher
Informations about the package filament-impersonate
Filament Account Switcher
Switch between accounts in a Filament panel without signing out — safely, in production. The panel UI of Account Switcher for Laravel, which does the same in any Laravel app.

Features
- Linked accounts: work from a low-privilege account and switch up to admin only when you need it.
- Impersonation: an action for your users table, a banner with Switch back, rules on your model.
- Developer logins: one-click sign-in buttons for your seeded accounts, on the login page and in the "Switch to" menu (searchable, tagged, or any account in the database), only in the environments you allow.
- Audit trail: every switch logged with who, why, from where and any context you attach, plus events and a
log()call for switches made elsewhere. - Configurable per panel: turn each feature on or off, add your own rules, move the banner.
- Dark mode and translations: built from Filament components, every string in a language file.
Formerly xlite-dev/filament-impersonate — see the upgrade guide.
Compatibility
| Plugin | Filament | Laravel | PHP |
|---|---|---|---|
4.1+ (with packstub/account-switcher 1.x) |
4.x, 5.x | 12.x, 13.x | 8.2+ |
| 4.0 | 4.x, 5.x | 12.x, 13.x | 8.2+ |
3.x (xlite-dev/filament-impersonate) |
4.x, 5.x | 9.x – 12.x | 8.1+ |
Installation
Add the trait to your user model and the plugin to your panel:
Only need impersonation and developer logins? Add ->withoutDatabase() to the plugin and skip the install command: no migrations, no trait (without migrations).
Full walkthrough: Installation.
Linked accounts
Link the accounts one person owns. A Switch to menu next to the user menu lists them with their label and e-mail.

Switching down to a lower-privilege account is one click. Switching up asks for the target account's password, so a compromised daily session can never reach the admin account on its own.

The Linked accounts page (in the user menu) links an existing account, creates a sub-account, renames links and sets the per-link password rule.

Read more: Linked accounts · Security model.
Impersonation
Drop ImpersonateAction into your users table or a page header. It is hidden for records the current user may not impersonate, based on canImpersonate() / canBeImpersonated() on your model.

While impersonating, a banner stays visible on every page with a Switch back button and a ⋮ menu for your own links. With Filament Session Replay on the panel the menu offers Session replays: switch back and land on that person's recordings.

Read more: Impersonation.
Developer logins
One-click sign-in for the accounts you seed, shown under the login form. They only render in the environments listed in the config (local by default), whatever the panel says.

Read more: Developer logins.
Configuration
Read more: Configuration — the config file, events, the switch log and the AccountSwitcher facade.
Documentation
The same pages live in the docs/ directory of this repository.
Testing
Changelog
See the changelog.
Security vulnerabilities
Please e-mail [email protected] rather than opening a public issue.
Credits
License
MIT. See the license file.
All versions of filament-impersonate with dependencies
filament/filament Version ^4.0 || ^5.0
illuminate/contracts Version ^12.0 || ^13.0
packstub/account-switcher Version ^1.1
spatie/laravel-package-tools Version ^1.92