How pull the latest builds for test runs?

Hi everyone.
We’re currently setting up our automation suite using webdriver.io with appium. Using Javascript.

I have a question about how is the best way to handle keeping the app your testing up to date without having to manually grab the latest apk/app file from app center for example?

We’re using app center and I notice from their API documentation they do have https://openapi.appcenter.ms/#/distribute/releases_getLatestByUser which returns a download_url. Is it possible to call this in our project and update the path in our config file with this download_url?

If it was me I would write a setup method to run before calling Appium. You could do this in Javascript, or you could invoke a helper like Gulp to do this:

https://gulpjs.com/

Full disclosure: We do this at my work, which is a Ruby shop, so we use helper Rake. I do not use Javascript and would not be able to supply code examples.