Laravel: different api rate limits for different paths
问题 I need to setup different rate limits for different paths. Foe example: On path /users I want to have rate limit of 60 requests per minute, while for path /stats I want to have rate limit of only 5 requests per minute. I tried with next approach Route::group(['middleware' => ['auth', 'throttle:60']], function(){ Route::get('users', 'User@list'); }); Route::group(['middleware' => ['auth', 'throttle:5']], function(){ Route::get('stats', 'User@stats'); }); Somehow, last rate limit is applied.