What's the best way to throttle the number of calls to an API in babashka?
I have a sequence of calls to make from babashka to an API, but I'm not allowed to just (run! #(cmd! %) command-collection)
because the server will deny my calls if I execute them too fast. What's the best way to interleave
my commands with something like a pause for x milliseconds?
off the top of my head 😛
(interleave [call1 call2 ...] (cycle [#(Thread/sleep 1000)]))
Nice ... going to try that 🤓
Yep, with a slight variation to fit my context, it works, thanks!