I want to use Laravel Spark to create different licenses for an API. I want to limit the API calls per month and also per hour/minute. For example the Basic License will allow 10 000 monthly api calls but I also want to limit the API calls per hour/minute for the same account. Can this be done with laravel spark?
Tag: throttling
preventing abuse of API service usage
I am planning on using Laravel in my next web project, for the backend. Using the Laravel’s built-in functionality I will build an API service. So my main concern now – is about the security of such service. Laravel’s API throttling middleware seems to be an easy to use solution, but it doesn’t quite have the flexibility that I need.
How do I throttle my site’s API users?
The legitimate users of my site occasionally hammer the server with API requests that cause undesirable results. I want to institute a limit of no more than say one API call every 5 seconds or n calls per minute (haven’t figured out the exact limit yet). I could obviously log every API call in a DB and do the calculation