Answer the question
In order to leave comments, you need to log in
How to get data via API that is not available immediately after the call?
I am making applications for registering accounts on one service, and a problem arose: I need confirmation by mail, which does not come immediately in this service, it can come in 5 seconds, maybe in a minute. The Main script must, at a certain interval, contact the module that is trying to receive the code from the mail, and only after receiving this confirmation code, continue the script execution. At the same time, while he is waiting for confirmation from the mail, ~ 10 of the same processes should work. Tell me how to do it, only setInterval comes to mind to make a function call, but then, if successful, it will not be possible to return the code to the level of the scope in which this setIInterval is declared through return.
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question