wotpy.protocols.mqtt.handlers.action

MQTT handler for Action invocations.

Classes

ActionMQTTHandler(mqtt_server[, qos]) MQTT handler for Action invocations.
class wotpy.protocols.mqtt.handlers.action.ActionMQTTHandler(mqtt_server, qos=2)

Bases: wotpy.protocols.mqtt.handlers.base.BaseMQTTHandler

MQTT handler for Action invocations.

KEY_INPUT = 'input'
KEY_INVOCATION_ID = 'id'
build_action_result_topic(thing, action)

Returns the MQTT topic for Action invocation results.

handle_message(msg)

Listens to all Property request topics and responds to read and write requests.

classmethod to_result_topic(invocation_topic)

Takes an Action invocation MQTT topic and returns the related result topic.

topic_wildcard_invocation

Wildcard topic to subscribe to all Action invocations.

topics

List of topics that this MQTT handler wants to subscribe to.