Back to Zeroclaw

MQTT

docs/book/src/channels/mqtt.md

0.8.31.4 KB
Original Source

MQTT

The mqtt channel subscribes to topics on an MQTT broker and feeds each message into the agent loop or the SOP engine. It is gated by the channel-mqtt build feature.

This is a SOP event source. For trigger syntax and topic matching, see SOP Fan-In: MQTT. This page covers the broker connection.

Configuration

The full field list, derived from the live schema. For a basic subscriber you set broker_url and topics.

{{#config-fields channels.mqtt}}

Full field reference: config reference.

TLS

Set use_tls to match the scheme of broker_url: mqtts:// pairs with use_tls = true, mqtt:// with use_tls = false. A mismatch is the most common connection failure.

Troubleshooting

SymptomLikely causeFix
Connection errors at startupbroker URL and TLS flag disagreePair the scheme with use_tls (mqtt:// with false, mqtts:// with true)
Subscribed but no messagestopic filter does not match the published topicVerify topics and wildcards against what the publisher emits
SOP not startingtopic mismatch or a failing conditionCheck the trigger topic and condition against the payload

See also