Multicontainer API for download status

I have just upgraded to use the multi-container resin. This has overall been a very easy update, however, I am looking to access the current state of my main container using the node-sdk. I am only able to access the device model which returns the status of the device as “Idle”. I can see that now the containers can be downloaded separately the device is idle however for our testing systems we wait for the device to finish downloading updates in order to begin tests.

Is there an unofficial API that I can use in order to access the state of the containers running on the device? I am happy to add authorisation tokens where needed in order to make this call manually.

Thanks in advance

From looking at the network requests from the dashboard the following is the cURL command to access the download status of the containers running on the device. To use this for your own device please change RESIN_TOKEN and DEVICE_UUID.

curl  --header 'authorization: Bearer RESIN_TOKEN' \

I imagine that a lot of this can be shortened

I’ve opened an issue to track this:

1 Like

And there’s ongoing work around support for multicontainer in the SDK being tracked under

1 Like

Hi @hpgmiskin, this does actually exist in the SDK, it’s just only available on the beta release, which supports multicontainer, but isn’t totally completed yet. To use this, you need to install with:

npm install resin-sdk@beta

and then use resin.models.device.getWithServiceDetails()

Note that the MC SDK is still in a state of flux though: some features aren’t yet complete (notably including environment variables), and you’ll want to pin a specific release, as there may be breaking changes before the final release.