group(function () { Route::get('bots/form/{element}', 'BotsAPIController@form'); Route::resource('bots', 'BotsAPIController'); }); if (Trans::isMultilingual()) { Route::group( [ 'prefix' => '{trans}', 'where' => ['trans' => Trans::keys('|')], ], function () { // Guard routes for bots Route::prefix('{guard}/bot')->group(function () { Route::get('bots/form/{element}', 'BotsAPIController@form'); Route::apiResource('bots', 'BotsAPIController'); }); // Public routes for bots Route::get('bot/Bots', 'BotsPublicController@getBots'); } ); }