Throttling / Blocking based on Path Hits

Hi,
We are currently in the process of moving to Cloudflare and wanted to check on something that we are looking for a solution for, in the mid term while the tools are created by our Development team in the application.

We have certain API’s for our application, however, no current way of monitoring usage and thus stopping access to those API’s or throttling access per website.

Is there a way to do this in Cloudflare? Now I know I can add filewall rules that would log when a certain path is hit, so I am sure the monitoring part if no problem, the question is more about the throttling or blocking based on usage of the API, e.g. 1000 hit per day.

the URL’s would be something like https://customername.domain.com/application or https://shareddnsgroupname.doman.com/customername then the API path after those.

Any help or a point in a direction would be great.
Regards,
Nick

You could look into https://support.cloudflare.com/hc/en-us/articles/115001635128-Configuring-Cloudflare-Rate-Limiting or deploy a custom Worker script.

Overall, and particularly in an API context, you might want to do this on the server-side though as rate limiting might not be flexible enough. Workers could be flexible enough but (just like rate limiting) they’d be a paid feature.

This topic was automatically closed after 30 days. New replies are no longer allowed.