HomeyAPI~ManagerDrivers

Methods

async getDrivers(optsopt) → {Promise.<Array.<HomeyAPI.ManagerDrivers.Driver>>}

Required OAuth scopes:
- homey.device.readonly

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

async getDriver(optsopt) → {Promise.<HomeyAPI.ManagerDrivers.Driver>}

Required OAuth scopes:
- homey.device

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

async getPairSessions(optsopt) → {Promise.<Object.<string, HomeyAPI.ManagerDrivers.PairSession>>}

Required OAuth scopes:
- homey.device

Parameters:
Name Type Attributes Description
opts object <optional>
Named parameters
Returns:
Promise.<Object.<string, HomeyAPI.ManagerDrivers.PairSession>> - Successful response

async createPairSession(optsopt) → {Promise.<HomeyAPI.ManagerDrivers.PairSession>}

Required OAuth scopes:
- homey.device

Parameters:
Name Type Attributes Description
opts object <optional>
Named parameters
Properties
Name Type Description
pairsession HomeyAPI.ManagerDrivers.PairSession
Returns:
Promise.<HomeyAPI.ManagerDrivers.PairSession> - Successful response

async getPairSession(optsopt) → {Promise.<HomeyAPI.ManagerDrivers.PairSession>}

Required OAuth scopes:
- homey.device

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

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

Required OAuth scopes:
- homey.device

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

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

Required OAuth scopes:
- homey.device

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

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

Required OAuth scopes:
- homey.device

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

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

Required OAuth scopes:
- homey.device

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

async createPairSessionDevice(optsopt) → {Promise.<HomeyAPI.ManagerDrivers.Device>}

Required OAuth scopes:
- homey.device

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

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

Required OAuth scopes:
- homey.device

Parameters:
Name Type Attributes Description
opts object <optional>
Named parameters
Properties
Name Type Description
id string
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

driver.create

Fired when a managed Driver is created
Parameters:
Name Type Description
driver HomeyAPI.ManagerDrivers.Driver The affected Driver

driver.update

Fired when a managed Driver is changed
Parameters:
Name Type Description
driver HomeyAPI.ManagerDrivers.Driver The affected Driver

driver.delete

Fired when a managed Driver has been deleted
Parameters:
Name Type Description
driver HomeyAPI.ManagerDrivers.Driver The affected Driver

pairsession.create

Fired when a managed PairSession is created
Parameters:
Name Type Description
pairsession HomeyAPI.ManagerDrivers.PairSession The affected PairSession

pairsession.update

Fired when a managed PairSession is changed
Parameters:
Name Type Description
pairsession HomeyAPI.ManagerDrivers.PairSession The affected PairSession

pairsession.delete

Fired when a managed PairSession has been deleted
Parameters:
Name Type Description
pairsession HomeyAPI.ManagerDrivers.PairSession The affected PairSession

Classes

Error

Driver

Device

PairSession