HomeyAPI~ManagerNotifications

Methods

async getNotifications(optsopt) → {Promise.<Object.<string, HomeyAPI.ManagerNotifications.Notification>>}

Required OAuth scopes:
- homey.notifications.readonly

Parameters:
Name Type Attributes Description
opts object <optional>
Named parameters
Properties
Name Type Attributes Description
filter HomeyAPI.ManagerNotifications.Notification <optional>
A response filter (Using a filter will bypass all caches, use sparingely)
Returns:
Promise.<Object.<string, HomeyAPI.ManagerNotifications.Notification>> - Successful response

async getNotification(optsopt) → {Promise.<HomeyAPI.ManagerNotifications.Notification>}

Required OAuth scopes:
- homey.notifications.readonly

Parameters:
Name Type Attributes Description
opts object <optional>
Named parameters
Properties
Name Type Description
id string
Returns:
Promise.<HomeyAPI.ManagerNotifications.Notification> - Successful response

async deleteNotification(optsopt) → {Promise.<void>}

Required OAuth scopes:
- homey.notifications

Parameters:
Name Type Attributes Description
opts object <optional>
Named parameters
Properties
Name Type Description
id string
Returns:
Promise.<void> - Successful response

async setNotificationRead(optsopt) → {Promise.<void>}

Required OAuth scopes:
- homey.notifications.readonly

Parameters:
Name Type Attributes Description
opts object <optional>
Named parameters
Properties
Name Type Description
id string
Returns:
Promise.<void> - Successful response

async deleteNotifications(optsopt) → {Promise.<void>}

Required OAuth scopes:
- homey.notifications

Parameters:
Name Type Attributes Description
opts object <optional>
Named parameters
Properties
Name Type Attributes Description
ownerUri string <optional>
Returns:
Promise.<void> - Successful response

async getOwners(optsopt) → {Promise.<void>}

Required OAuth scopes:
- homey.notifications.readonly

Parameters:
Name Type Attributes Description
opts object <optional>
Named parameters
Returns:
Promise.<void> - Successful response

async setOwnerEnabled(optsopt) → {Promise.<void>}

Required OAuth scopes:
- homey.notifications

Parameters:
Name Type Attributes Description
opts object <optional>
Named parameters
Properties
Name Type Description
uri string
enabled boolean
Returns:
Promise.<void> - Successful response

async setOwnerPush(optsopt) → {Promise.<void>}

Required OAuth scopes:
- homey.notifications

Parameters:
Name Type Attributes Description
opts object <optional>
Named parameters
Properties
Name Type Description
uri string
push boolean
Returns:
Promise.<void> - Successful response

destroy()

Unsubscribes to realtime events, clear all caches, and remove all event listeners for this manager and it's managed objects

Events

notification.create

Fired when a managed Notification is created
Parameters:
Name Type Description
notification HomeyAPI.ManagerNotifications.Notification The affected Notification

notification.update

Fired when a managed Notification is changed
Parameters:
Name Type Description
notification HomeyAPI.ManagerNotifications.Notification The affected Notification

notification.delete

Fired when a managed Notification has been deleted
Parameters:
Name Type Description
notification HomeyAPI.ManagerNotifications.Notification The affected Notification

Classes

Error

Notification