It seems that they were flipped.
Laravel 7 api is first https://github.com/laravel/laravel/blob/7.x/app/Providers/RouteServiceProvider.php
public function map()
{
$this->mapApiRoutes();
$this->mapWebRoutes();
//
}
Laravel 8 web is first https://github.com/laravel/laravel/blob/master/app/Providers/RouteServiceProvider.php
$this->routes(function () {
Route::middleware('web')
->group(base_path('routes/web.php'));
Route::prefix('api')
->middleware('api')
->group(base_path('routes/api.php'));
});
I am sure you can just swap them back