Forums

cant make requests

i use Python anywhere to use alpha vantage free API key, and it works fine but when i make the request it says i exceeded the limit of my alpha vantage API key even if i did try to use it in Replit next to test with the exacts same keys, and it worked, and it was only a few minutes later, but what's wired is that i got to the tarpit and there it did work maybe because tarpit uses the spare resources from other places of their servers and maybe alpha vantage has IP rate limiting also and in the tarpit it uses spare resources from multiple servers to run your code (multiple servers usually means multiple IP address) and maybe python anywhere uses shared IP address for multiple users, also if you want to help to give me a solution please read the free API key alpha vantage documentation because you do not just call it like HTTP requests. Any solutions?

If it's working when you are in the tarpit, then it's because being in the tarpit is slowing down the rate that you are making requests. Reduce the rate at which you are making requests to reduce the incidence of that error.

thanks i made a break and it worked but then some hours later i runned the code again with that break and again and got: Thank you for using Alpha Vantage! Our standard API rate limit is 25 requests per day. Ple ase subscribe to any of the premium plans at https://www.alphavantage.co/premium/ to instantly remove all daily rate limits.

but it just worked before and i had made no more than 3 reqests if not 2 or 1 this day

also i alredy added the breaks wich worked once and now stopped working as i just said but why in replit i add nothing and works perfectly, and in other places i did saw that its also per divice or ip request and not only keys so maybe because pythonanyware uses shared ip, any way to make alpha vantage not know im using a shared api, please if you find a way share me the code, please

Then I would think that they have IP-based rate limits and there are other people that are on the same machine making requests that are taking the number of requests over the limit. That is not something we can do anything about.

so then there is no thing to hde to use something like proxy changing or just something to bypass that, please if you figure out tell me how

We do not provide any of that.

I am seeing the similar problem. API works on my localhost but fails with the same rate limit error on pythonanywhere.

If you slow down it might help.