use App\Http\Controllers\ApiGatewayController; // The magical proxy route that acts like a real .php file Route::get('v1/{api_slug}', [ApiGatewayController::class, 'handle'])->where('api_slug', '.*\.php$');