Hello,
I'd like to move api to a dedicated subdomain. Currently I have the following in Routes/api.php
Route::domain(config('domains.api'))->group(function () {
Route::post('/checkout/create', [CheckoutController::class, 'create'])->name('api.checkout.create');
});
For reference config('domains.api') is "linked" to config/domains.php
return [
'app' => env('DOMAIN_APP', 'xxx.com'),
'api' => env('DOMAIN_API', 'api.xxx.com'),
//other code
];
Actually everything works with https://api.xxx.com/api/checkout/create. I'd like to use https://api.xxx.com/checkout/create.
Thanks,
Simon