Hello does anyone here has worked with Dropbox? I ...
# general
i
Hello does anyone here has worked with Dropbox? I have an issue that appeared recently, this error has never been seen until the customer changed to optic fiber, dont know if it has something to do really. So the code is just doing a
post call
to the API to upload a file, this is on a
scheduled
script
<http://https.post|https.post>({url: '<https://content.dropboxapi.com/files/upload>', body: fileId, headers: DropBoxHeader  });
but sometimes this returns
{"error_summary": "too_many_requests/...", "error": {"reason": {".tag": "too_many_requests"}, "retry_after": 15}}
p
As you can see in the JSON, it is clearly mentioned that you are sending too many requests in a short period of time. Check this : https://developers.dropbox.com/dbx-performance-guide Hope it helps
i
I found that page, but apparently the link is broken
So, how can I like, send less requests, I just can think of a timeout, but dont thinkn thats the correct answer 😅
Or implement an sleep between calls if I get that error would be better?
m
you don't necessarily have to send fewer requests, but you do need retry logic and you need to respect the
retry_after
parameter