added support to query devices and repos from devices