step by step authenticate using sanctum code example
Example: laravel sanctum auth setup
php artisan vendor:publish --provider="Laravel\Sanctum\SanctumServiceProvider"
php artisan vendor:publish --provider="Laravel\Sanctum\SanctumServiceProvider"