When an ECONNREFUSED error is received by the user, how long is the user locked out of the API?
Is there a way to monitor the status of whether I’m blocked or not without sending another API request? How long should I wait before trying any request again?
The limit is reset every 3 seconds, and you can check how many seconds until the next reset at the X-RateLimit-Rese header in the response
If your project is under a free plan and you made over 100.000 requests this month, you can either wait for the next calendar month, or add a credit card
Hey @marvin when you are rate limited though you get a 429 error, not a ECONNREFUSED.
This might mean that there was a network connection issue, either on your end or on Cloudflare’s end.
If that happens again, please be in touch at support@datocms.com with more info to troubleshoot:
are you able to reproduce the bug locally? Or the problem happens only on CI/CD?
can you provide the full timestamp with timezone of the next problem that will happen?
can you provide the exact GraphQL/REST call that is failing?
To mitigate the problem right now you can implement a retry mechanism on top of the GraphQL call, so that if it just fails occasionally you’ll be covered and the full build will go ahead. If instead you are using our JS client, we already do that.