Skip to content

Instantly share code, notes, and snippets.

@zorca
Created June 26, 2020 06:57
Show Gist options
  • Save zorca/db35cfceeb260d18ffab14a5e4bb67f3 to your computer and use it in GitHub Desktop.
Save zorca/db35cfceeb260d18ffab14a5e4bb67f3 to your computer and use it in GitHub Desktop.
Route::middleware([
'tenant-api',
InitializeTenancyByRequestData::class,
PreventAccessFromCentralDomains::class,
])->group(function () {
Route::get('tenants/current', 'TenantController@show');
Route::post('users/token', 'UserController@token');
Route::middleware(['auth:sanctum'])->group(function () {
Route::get('users/current', 'UserController@show');
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment