I am trying to restrict usage of a certain endpoint to 10 times per day per user, and I can see how to do it for a certain number of times per minute. Please note that this is within a controller, not as middleware.
$executed = RateLimiter::attempt(
'user-send-test-' . Auth::user()->id,
$perDay = 10,
function () {
// some process
}
);