Laravel Passport - "Invalid key supplied" Error Solution

By Hardik Savani December 19, 2024 Category : Laravel

In this tips, how to solve "invalid key supplied" error in laravel passport.

Sometimes, when working with REST APIs using Laravel Passport, you might encounter the "invalid key supplied" error. This usually happens because Passport isn't installed or the required keys are missing in the `storage` folder. To resolve this issue, you can run the following commands:

Run the following command:

php artisan passport:install

after that you run this command:

php artisan passport:keys --force

Then you need to give permission:

sudo chmod -R 0777 ./storage

I hope it can help you...

Tags :
Shares