Methods
-
async getVariables(optsopt) → {Object.<string, HomeyAPI.ManagerLogic.Variable>}
-
Required OAuth scopes:
- homey.logic.readonly
Parameters:
Name Type Attributes Description opts
object <optional>
Named parameters Properties
Name Type Attributes Description filter
HomeyAPI.ManagerLogic.Variable <optional>
A response filter (Using a filter will bypass all caches, use sparingely) Returns:
Object.<string, HomeyAPI.ManagerLogic.Variable> - Successful response -
async getVariable(optsopt) → {HomeyAPI.ManagerLogic.Variable}
-
Required OAuth scopes:
- homey.logic.readonly
Parameters:
Name Type Attributes Description opts
object <optional>
Named parameters Properties
Name Type Description id
string Returns:
HomeyAPI.ManagerLogic.Variable - Successful response -
async updateVariable(optsopt) → {HomeyAPI.ManagerLogic.Variable}
-
Required OAuth scopes:
- homey.logic
Parameters:
Name Type Attributes Description opts
object <optional>
Named parameters Properties
Name Type Description id
string variable
HomeyAPI.ManagerLogic.Variable Returns:
HomeyAPI.ManagerLogic.Variable - Successful response -
async deleteVariable(optsopt)
-
Required OAuth scopes:
- homey.logic
Parameters:
Name Type Attributes Description opts
object <optional>
Named parameters Properties
Name Type Description id
string -
async createVariable(optsopt) → {HomeyAPI.ManagerLogic.Variable}
-
Required OAuth scopes:
- homey.logic
Parameters:
Name Type Attributes Description opts
object <optional>
Named parameters Properties
Name Type Description variable
HomeyAPI.ManagerLogic.Variable Returns:
HomeyAPI.ManagerLogic.Variable - Successful response -
async triggerWebhook(optsopt)
-
Parameters:
Name Type Attributes Description opts
object <optional>
Named parameters Properties
Name Type Attributes Description event
object <optional>
tag
object <optional>
-
destroy()
-
Unsubscribes to realtime events, clear all caches, and remove all event listeners for this manager and it's managed objects
Events
-
variable.create
-
Fired when a managed Variable is created
Parameters:
Name Type Description variable
HomeyAPI.ManagerLogic.Variable The affected Variable -
variable.update
-
Fired when a managed Variable is changed
Parameters:
Name Type Description variable
HomeyAPI.ManagerLogic.Variable The affected Variable -
variable.delete
-
Fired when a managed Variable has been deleted
Parameters:
Name Type Description variable
HomeyAPI.ManagerLogic.Variable The affected Variable