ManagerDevices

Extends

Classes

Methods

connect

(async) connect(): Promise.<void>

Connect to the realtime namespace.

Returns

Promise.<void>

deleteDevice

(async) deleteDevice(opts)

Scopes

homey.device

HTTP

DELETE /api/manager/devices/device/:id

Parameters

Name Type Description
opts
object
id
string
}

disconnect

(async) disconnect(): Promise.<void>

Disconnect from the realtime namespace.

Returns

Promise.<void>

getCapabilities

(async) getCapabilities(): Promise.<HomeyAPIV2.ManagerDevices.Capability>

Scopes

homey.device.readonly

HTTP

GET /api/manager/devices/capability

Returns

getCapability

(async) getCapability(opts): Promise.<HomeyAPIV2.ManagerDevices.Capability>

Scopes

homey.device.readonly

HTTP

GET /api/manager/devices/capability/:uri/:id

Parameters

Name Type Description
opts
object
id
string
uri
string
}

Returns

getDevice

(async) getDevice(opts): Promise.<HomeyAPIV2.ManagerDevices.Device>

Scopes

homey.device.readonly

HTTP

GET /api/manager/devices/device/:id

Parameters

Name Type Description
opts
object
id
string
}

Returns

getDevices

(async) getDevices(): Promise.<HomeyAPIV2.ManagerDevices.Device>

Scopes

homey.device.readonly

HTTP

GET /api/manager/devices/device/

Returns

getDeviceSettingsObj

(async) getDeviceSettingsObj(opts): Promise.<any>

Scopes

homey.device.readonly

HTTP

GET /api/manager/devices/device/:id/settings_obj

Parameters

Name Type Description
opts
object
id
string
}

Returns

Promise.<any>

isConnected

isConnected(): Boolean

If this manager's namespace is connected to Socket.io.

Returns

Boolean

setCapabilityValue

(async) setCapabilityValue(opts): Promise.<any>

Scopes

homey.device.control

HTTP

PUT /api/manager/devices/device/:deviceId/capability/:capabilityId

Parameters

Name Type Description
opts
object
capabilityId
string
deviceId
string
transactionId
* <optional>
opts
* <optional>
value
*
}

Returns

Promise.<any>

setDeviceSettings

(async) setDeviceSettings(opts): Promise.<any>

Scopes

homey.device

HTTP

PUT /api/manager/devices/device/:id/settings

Parameters

Name Type Description
opts
object
id
string
settings
*
}

Returns

Promise.<any>

updateDevice

(async) updateDevice(opts): Promise.<HomeyAPIV2.ManagerDevices.Device>

Scopes

homey.device

HTTP

PUT /api/manager/devices/device/:id

Parameters

Name Type Description
opts
object
id
string
device
*
}

Returns

Events

capability.create

.on('capability.create')

Parameters

Name Type Description
capability
HomeyAPIV2.ManagerDevices.Capability

capability.delete

.on('capability.delete')

Parameters

Name Type Description
capability
HomeyAPIV2.ManagerDevices.Capability

capability.update

.on('capability.update')

Parameters

Name Type Description
capability
HomeyAPIV2.ManagerDevices.Capability

device.create

.on('device.create')

Parameters

Name Type Description
device
HomeyAPIV2.ManagerDevices.Device

device.delete

.on('device.delete')

Parameters

Name Type Description
device
HomeyAPIV2.ManagerDevices.Device

device.update

.on('device.update')

Parameters

Name Type Description
device
HomeyAPIV2.ManagerDevices.Device