I’m having problems with rate limits on Binance API Documentation. Even though my response header X-SAPI-USED-UID-WEIGHT-1M
sais 90000 I’m still getting 429 with body {"code":-1003,"msg":"Too many requests; current request has limited."}
. I know this endpoint has quite a heavy weight but 90000 means I should be able to do 1 more request not get 429. Anybody has same problem? Any idea what I’m doing wrong?
The weight check considers the weight usage of the current request. Therefore, if you already consumed 90000 out of 120000, a request of another 90000 will pass the thresold and return a 429 response.
ok let me be more precise 90K was in the response header that already had 429 status and according to my observations, Binance increases weight used regardless of HTTP response status. So that would indicate 90K usage AFTER processing of request that somehow ended up with 429?
Also, it’s a SAPI UID endpoint so shouldn’t it have 180K per UID per minute?
Update with additional details
My bot has been doing rate limited calls to this endpoint, basically 1 request every 36s, printing out request and response HTTP headers each time. I’ve done a request at HH:mm:28, result was 200 X-SAPI-USED-UID-WEIGHT-1M
header 90K. Next request has been done at HH:mm:04 resulting with 429 and X-SAPI-USED-UID-WEIGHT-1M
header 90K. Header checks out, as a 0 s mark has passed so weight has been set to 0, but 429?