Access this instance at HomeyAPIV3Local.notifications
.
Extends
Classes
Methods
connect
(async) connect(): Promise.<void>Connect to the realtime namespace.
Returns
Promise.<void>
deleteNotification
(async) deleteNotification(opts)Scopes
homey.notifications
HTTP
DELETE /api/manager/notifications/notification/:id
Parameters
Name | Type | Description |
---|---|---|
opts
|
object | |
id
|
string | |
|
deleteNotifications
(async) deleteNotifications(opts): Promise.<any>Scopes
homey.notifications
HTTP
DELETE /api/manager/notifications/notification
Parameters
Name | Type | Description |
---|---|---|
opts
|
object | |
ownerUri
|
string
<optional> |
|
|
Returns
Promise.<any>
disconnect
(async) disconnect(): Promise.<void>Disconnect from the realtime namespace.
Returns
Promise.<void>
getNotifications
(async) getNotifications(): Promise.<HomeyAPIV3Local.ManagerNotifications.Notification>Scopes
homey.notifications.readonly
HTTP
GET /api/manager/notifications/notification
Returns
getOwners
(async) getOwners(): Promise.<any>Scopes
homey.notifications.readonly
HTTP
GET /api/manager/notifications/owner
Returns
Promise.<any>
getState
(async) getState(): Promise.<any>Scopes
homey.system.readonly
HTTP
GET /api/manager/notifications/state
Returns
Promise.<any>
isConnected
isConnected(): BooleanIf this manager's namespace is connected to Socket.io.
Returns
Boolean
setOwnerEnabled
(async) setOwnerEnabled(opts): Promise.<any>Scopes
homey.notifications
HTTP
PUT /api/manager/notifications/owner/:uri/enabled
Parameters
Name | Type | Description |
---|---|---|
opts
|
object | |
uri
|
string | |
enabled
|
boolean | |
|
Returns
Promise.<any>
setOwnerPush
(async) setOwnerPush(opts): Promise.<any>Scopes
homey.notifications
HTTP
PUT /api/manager/notifications/owner/:uri/push
Parameters
Name | Type | Description |
---|---|---|
opts
|
object | |
uri
|
string | |
push
|
boolean | |
|
Returns
Promise.<any>
Events
notification.create
.on('notification.create')Parameters
Name | Type | Description |
---|---|---|
notification
|
HomeyAPIV3Local.ManagerNotifications.Notification |
notification.delete
.on('notification.delete')Parameters
Name | Type | Description |
---|---|---|
notification
|
HomeyAPIV3Local.ManagerNotifications.Notification |
notification.update
.on('notification.update')Parameters
Name | Type | Description |
---|---|---|
notification
|
HomeyAPIV3Local.ManagerNotifications.Notification |