We have an API that is an interface to a huge database. We sell the access to it as a service, and our clients are then able to get the data.
However, one of our goals is to deny any bot that attempts to access our database faster than a regular user, limiting it to a few requests at once (ie. one per two second).
Currently I am using WebApiThrottle to do this, however I can't figure out how to just "slow down" the requests instead of returning the "Too many requests" error. For example, creating a queue of requests and using something like Thread.Sleep() on then to limit to one per second, or anything like that, instead of immediately returning an error, and actually returning valid data.
Is this a good practice? How can I achieve this?