You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Packages register their default policies through this package; apps override them from config ('policies' => [Export::class => AppExportPolicy::class]) or Gate::policy(). Provide a base policy with the standard abilities mapped to permissions (viewAny, view, create, update, delete, restore, forceDelete, plus custom).
Done on next-gen (c50699a). The docs are docs/basic-usage/policies.md.
Decision: package policies are applied in an app->booted() callback, and only where the gate has no policy yet. So Gate::policy() from any app provider wins whatever the provider order, and config('permissions.policies') always wins. ResourcePolicy uses __call for $abilities, so unknown abilities are denied instead of throwing. Tested with fixture package and app providers in tests/Fixtures.
Activity
Add the permission and policy registration API
Document v3 for people and agents; add the Boost guideline and skill
n4ff4h commentedon Nov 4, 2026
Done on
next-gen(c50699a). The docs aredocs/basic-usage/policies.md.Decision: package policies are applied in an
app->booted()callback, and only where the gate has no policy yet. SoGate::policy()from any app provider wins whatever the provider order, andconfig('permissions.policies')always wins.ResourcePolicyuses__callfor$abilities, so unknown abilities are denied instead of throwing. Tested with fixture package and app providers intests/Fixtures.