I want to implement long-polling until I get certain data from an API.
For example, let's say we have an API that returns the progress of a process. And I want to call that API until the process is finished.
Is it feasible and if so, how can I implement it?