charleskoko / sanctum-authentication
This installs Laravel sanctum and generates everything needed for authentication
Installs: 2
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
pkg:composer/charleskoko/sanctum-authentication
This package is auto-updated.
Last update: 2025-12-10 17:12:59 UTC
README
Installation
Sanctum authentication requires Laravel Sanctum. Before installing this package, you must have installed Laravel sanctum and made all configurations.
Package installation.
composer require charleskoko/sanctum-authentication
Then you have to publish the configuration files of Sanctum authentication package using the command vendor:publish Artisan. The Sanctum configuration file will be placed in the config directory of your application:
php artisan vendor:publish --provider="Charleskoko\SanctumAuthentication\SanctumAuthenticationServiceProvider"
Configuration
In the config file sanctumAuthentication.php of Sanctum authentication package, you can modify the following environment variables:
| Variable | ROLE |
|---|---|
| Registration rules | Necessary elements and validations rules for the creation of a user |
| Login rules | Required elements and validation rules allowing the user to connect |
| Login attribute | Attribute to check for the user's connection |
| Api uri | Api url |