Laravel create rest API authentication ( Register, login,list) using sanctum with postman

Опубликовано: 22 Февраль 2026
на канале: GHANSHYAM NAKIYA
3,739
31

#laravel #api #token #laravelapi #register #login #sanctum #restapi #authentication

Tutorial 2 API crud available    • Laravel creat rest CRUD API with postman t...  

Laravel Sanctum provides a featherweight authentication system for mobile applications, and simple, token based APIs. Sanctum allows each user of your application to generate multiple API tokens for their account.

You may install Laravel Sanctum via the Composer package manager:
composer require laravel/sanctum

Next, you should publish the Sanctum configuration and migration files using the vendor:publish Artisan command.

php artisan vendor:publish --provider="Laravel\Sanctum\SanctumServiceProvider"

Finally, you should run your database migrations. Sanctum will create one database table in which to store API tokens:
php artisan migrate