laravel sanctum assign user token from api route code example
Example 1: snactum laravel
composer require laravel/sanctum
Example 2: sanctum laravel
php artisan vendor:publish --provider="Laravel\Sanctum\SanctumServiceProvider"
composer require laravel/sanctum
php artisan vendor:publish --provider="Laravel\Sanctum\SanctumServiceProvider"