Im using a AWS Lambda function receving many unexpected signals from several channels and sending request to another API.
the problem is the another API is limiting the number of requests per minute.(if the numer exceed the limit, IP will be banned)
So I want to limit the number of requests per minute sent by the lambda function.
[What I have tried] :
At first, I tried to use 'Concurrency limit', which turns out that it cannot limit the number of call 'per minute'.
Secondly, I tried to get the current number of requests per minute from the another API before actual requests and if the number of requests exceed the limit, then sleep 1minute and send actual requests.
However, getting the current number of requests per minute requires 1 request quarter also. So, if too many signals call the lambda function in one minute, it can cause IP ban as well.
Please help me to solve this problem, I will really appreciate your help. Thanks!