error status 401 error unauthenticated laravel passport
问题 This is my first time implementing laravel passport This is my config/auth.php 'guards' => [ 'web' => [ 'driver' => 'session', 'provider' => 'users', ], 'api' => [ 'driver' => 'passport', 'provider' => 'users', ], ], and this is where my routes/api.php that are guarded by auth:api Route::group(['middleware' => ['auth:api']], function () { Route::resource('users','Users\AdminUsersController')->except([ 'create', 'edit' ]); }); and this is how I fetch the api fetchUsers: async function(page_url