Get rooms in SmartApp?

Is it possible to get rooms in my SmartApp code? Something like this:

settings.each { k, v ->         
settings.get(k).each {
	it.rooms.each {room ->
		log.debug "room name: ${room.name}"
	}
    }
}

google didn’t find much: https://www.google.com/#safe=active&q=site:docs.smartthings.com+room

I get these values when accessing it.properties, but there is no rooms field:

            [currentStates:[physicalgraph.device.cassandra.DeviceState@77638db6, 
            physicalgraph.device.cassandra.DeviceState@28ece4f6], 
            schedulerFactoryService:physicalgraph.scheduling.SchedulerFactoryService@613a548d, 
            typeAuthor:SmartThings, 
            hub:physicalgraph.app.HubWrapper@3c8526d9, 
            preferences:[:], 
            id:*removed*, 
            supportedCommands:[on, off, poll, configure, setLevel, refresh], 
            eventSvc:physicalgraph.event.EventService@49b98f99, 
            installedSmartApp:Kloee SmartThings Device Management REST Endpoints v2, 
            preferencesWrapper:[:], 
            name:Cree Bulb, 
            network:ZIGBEE, 
            capabilities:[Switch, Polling, Configuration, Switch Level, Refresh, Actuator], 
            device:Cree Bulb, typeSettings:{}, 
            class:class physicalgraph.app.DeviceWrapper, 
            typeName:Cree Bulb, 
            cmdSvc:physicalgraph.device.CommandService@35830406, 
            label:Cree Bulb, supportedAttributes:[switch, level], 
            stateOverrides:[], 
            deviceNetworkId:84D7,
            lastActivity:Thu Jun 23 19:19:39 UTC 2016, 
            displayName:Cree Bulb]

Been asked many, many, many times. Please use the search function :mag:.

Groups and Rooms are currently not available not in the published API.


Thank you. I did search on rooms, but not well enough I guess…

1 Like