A collaborative project with Matt Stein that adds MQTT as a communication channel for Claude Code. MQTT is the backbone of the Hive - it's how agents talk to each other, how Home Assistant routes voice commands, and how the YouTube Voice app will coordinate multi-agent conversations.
What It Is
An MCP channel server that bridges Claude Code sessions to an MQTT broker. Each agent subscribes to topics and publishes messages through standard MQTT, enabling:
- Inter-agent communication - Agents send tasks, share context, and coordinate via MQTT topics
- Home Assistant integration - HA publishes events, agents subscribe and respond
- YouTube Voice sessions - The Mac app publishes Paul's speech, agents reply on the same topic
- Any external system - Anything that can publish MQTT can reach an agent
How It Works
The MQTT MCP server runs as a channel inside Claude Code. It connects to an MQTT broker and:
- Subscribes to configured topics
- Incoming messages arrive as
<channel source="mqtt"> events in the agent's context
- Agent can publish replies via the
publish or reply tools
- Supports request/reply pattern with correlation IDs for synchronous exchanges
Paul's Fork
Paul's fork (paulmona/claude-code-mqtt) adds:
- Configurable topic prefix (MQTT_TOPIC_PREFIX) for namespace isolation
- Correlation ID request/reply for synchronous agent-to-agent messaging
- CI pipeline with CodeQL and Dependabot
- Security hardening