With ktor rate limiting is it possible to ignore r...
# ktor
t
With ktor rate limiting is it possible to ignore rate limiting for authorized requests and public ones get rate limited?
r
something like this should work
Copy code
requestKey { call -> 
  call.principal<MyUser>() ?: FreeUser
}

rateLimitter { call, key -> 
  if (key is FreeUser) RateLimiter.default(...) else RateLimiter.Unlimited 
}
t
Ah gotcha, didn't know they provided those to use
thanks!
👍 1