API KEY - Too Many Requests Error code: 429 - {'error': {'message': 'You exceeded your current quota,

hello, I’m trying to finish a code with API KEY for a few days. It seems that ChatGPT does not know how to complete it. I made hundreds of attempts, gave hundreds of explanations, spent about 8 dollars with the API, and still I have the error below. Although I changed the API key.

I recharged 3 minutes ago, I paid another 10 $ for tokens, but I still see this error:

2024-10-30 10:17:33,239 - INFO - HTTP Request: POST https://api.openai.com/v1/chat/completions "HTTP/1.1 429 Too Many Requests" 2024-10-30 10:17:33 33,241 - ERROR - Error correcting the text: Error code: 429 - {'error': {'message': 'You exceeded your current quota, please check your plan and billing details.

For more information on this error, read the docs: https://platform.openai.com/docs/guides/error-codes/api-errors.', 'type': 'insufficient_quota', 'param': None, ' code': 'insufficient_quota'}} 2024-10-30 10:17:33,398 - INFO - HTTP Request: POST https://api.openai.com/v1/chat/completions "HTTP/1.1 429 

Too Many Requests" 2024 -10-30 10:17:33,398 - INFO - Retrying request to /chat/completions in 0.468949 seconds 2024-10-30 10:17:34,032 - INFO - HTTP Request: POST https://api.openai.com/v1 /chat/completions "

HTTP/1.1 429 Too Many Requests" 2024-10-30 10:17:34,032 - INFO - Retrying request to /chat/completions in 0.984310 seconds

Try printing out the actual API key the code is using.
Chances are it wasn’t switched in the first place!

Another explanation is that the account has insufficient balance, but as you stated, you took care of that.

Log your API-Key and see if it is the one you expect it to be. :hugs:

it is working fine now. I believe that I have consumed the number of tokens allocated for a single day.

thanks

1 Like