References
project.devices()

devices

This class provides access to the features associated to device. Simply get a reference to the device class by calling devices() method with the project object. This is illustrated as below

// Get reference to the devices class
// by calling the device method
var devices = project.devices();

Now once you got the reference to the devices class, you can simply use all the features by calling the respective methods.