From 9ea5afd109a8fc0b4aed57e45dde67a4245cb905 Mon Sep 17 00:00:00 2001 From: Paulus Schoutsen Date: Tue, 25 Sep 2018 13:47:12 +0200 Subject: [PATCH] Add unique ID and device info to Nest camera (#16846) * Add unique ID and device info to Nest camera * Remove sw version --- homeassistant/components/camera/nest.py | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/homeassistant/components/camera/nest.py b/homeassistant/components/camera/nest.py index e1d26371984..158123989c0 100644 --- a/homeassistant/components/camera/nest.py +++ b/homeassistant/components/camera/nest.py @@ -62,6 +62,23 @@ class NestCamera(Camera): """Return the name of the nest, if any.""" return self._name + @property + def unique_id(self): + """Return the serial number.""" + return self.device.device_id + + @property + def device_info(self): + """Return information about the device.""" + return { + 'identifiers': { + (nest.DOMAIN, self.device.device_id) + }, + 'name': self.device.name_long, + 'manufacturer': 'Nest Labs', + 'model': "Camera", + } + @property def should_poll(self): """Nest camera should poll periodically."""