method.exec event

The method.exec event is triggered when a method of a thing with the same key is executed

Form

Parameters

Name Type Required Description
Thing def key String  Yes The Thing definition key that contains the method.
Method Key String Yes The corresponding method key within a thing that will execute this trigger. Both the method key here and in the Thing definition needs to be the same in order for this trigger event to fire. For a detailed example on method.exec event, see Invoking a Trigger from a Method.

Event variables

Name Type Description
$(event.thing.key) String The key of the Thing that initiated this trigger.
$(event.thing.name) String The name of the thing that initiated this trigger.
$(event.defKey) String The Thing definition key.
$(event.methodKey) String The method key.
$(event.params) Object The parameters sent to the trigger.