n3xt0r/laravel-passport-authorization-core
Core components for building OAuth2 authorization flows with Laravel Passport. Provides reusable helpers and abstractions to standardize consent/approval handling and authorization logic, making it easier to implement custom Passport authorization endpoints and UI.
Laravel Passport Authorization Core provides a domain model and use cases for structured access control on top of Laravel Passport.
Instead of implicit authorization scattered across your codebase, it offers an explicit permission model: **resources ** (user, invoice, report) + actions (read, create, delete) stored in the database as queryable facts. You implement enforcement however you need—middleware, policies, guards, custom logic.
Single source of truth. No opinions about how you validate.
resource:action in the databaseResources: Entities needing permission control (user, invoice, report, etc.)
Actions: Operations you control. Global (list, read, create, update, delete) or resource-specific
(export, approve).
Grants: Permissions assigned to any OAuthenticatable entity (User, Client, ServiceAccount, or custom).
resource_id + action_id: which permission?context_client_id (optional): in context of which client?Use Cases: Encapsulated business logic to manage permissions (see Usecase Overview).
composer require n3xt0r/laravel-passport-authorization-core
php artisan vendor:publish --tag=passport-authorization-core-config
This package is the domain core for Filament Passport UI:
Actively developed. Feedback and contributions welcome.
How can I help you explore Laravel packages today?