Skip to content
Advertisement

Post files, but endpoint limits 50 posts per minute

Good afternoon, i’m completely new to coding and i need some help, i splitted a json file into ~2800 smaller json files and need to post to a certain endpoint, however the limit of the endpoint is ~50 files per minute.

Currently i have made this is python :

JavaScript

The file names are json1 -> json2800

Currently it only posts 1 file, and i need to post all 2800 files with a limit of 50 per minute, is there someone who can help out :) ?

Advertisement

Answer

If your code is correct for 1 request, you should be able to do all of them like this :

JavaScript

I recommend you to replace 60/50 (last line) by something like 60/48 for example to be sure there is no problem due do lags

User contributions licensed under: CC BY-SA
10 People found this is helpful
Advertisement