Access this instance at HomeyAPIV3Cloud.zones
.
Extends
Classes
Methods
connect
(async) connect(): Promise.<void>Connect to the realtime namespace.
Returns
Promise.<void>
createZone
(async) createZone(opts): Promise.<HomeyAPIV3Cloud.ManagerZones.Zone>Scopes
homey.zone
HTTP
POST /api/manager/zones/zone
Parameters
Name | Type | Description |
---|---|---|
opts
|
object | |
zone
|
object | |
name
|
string | |
icon
|
string | |
parent
|
string | |
|
||
|
Returns
Promise.<HomeyAPIV3Cloud.ManagerZones.Zone>
deleteZone
(async) deleteZone(opts)Scopes
homey.zone
HTTP
DELETE /api/manager/zones/zone/:id
Parameters
Name | Type | Description |
---|---|---|
opts
|
object | |
id
|
string | |
|
disconnect
(async) disconnect(): Promise.<void>Disconnect from the realtime namespace.
Returns
Promise.<void>
getState
(async) getState(): Promise.<any>Scopes
homey.system.readonly
HTTP
GET /api/manager/zones/state
Returns
Promise.<any>
getZones
(async) getZones(): Promise.<HomeyAPIV3Cloud.ManagerZones.Zone>Scopes
-
HTTP
GET /api/manager/zones/zone
Returns
Promise.<HomeyAPIV3Cloud.ManagerZones.Zone>
isConnected
isConnected(): BooleanIf this manager's namespace is connected to Socket.io.
Returns
Boolean
updateZone
(async) updateZone(opts): Promise.<HomeyAPIV3Cloud.ManagerZones.Zone>Scopes
homey.zone
HTTP
PUT /api/manager/zones/zone/:id
Parameters
Name | Type | Description |
---|---|---|
opts
|
object | |
id
|
string | |
zone
|
object | |
name
|
string
<optional> |
|
icon
|
string
<optional> |
|
parent
|
string
<optional> |
|
|
||
|
Returns
Promise.<HomeyAPIV3Cloud.ManagerZones.Zone>
Events
zone.create
.on('zone.create')Parameters
Name | Type | Description |
---|---|---|
zone
|
HomeyAPIV3Cloud.ManagerZones.Zone |
zone.delete
.on('zone.delete')Parameters
Name | Type | Description |
---|---|---|
zone
|
HomeyAPIV3Cloud.ManagerZones.Zone |
zone.update
.on('zone.update')Parameters
Name | Type | Description |
---|---|---|
zone
|
HomeyAPIV3Cloud.ManagerZones.Zone |