How can Home Assistant consume jobs from an external system? #47
Notifications
Due Date
No due date set.
Blocks
Reference: bobby/hapi#47
Reference in new issue
Block a user
Part of #44
Question
What mechanisms does Home Assistant offer for receiving or pulling commands from an external system? Cover MQTT integration (and RabbitMQ's MQTT plugin), AMQP (any integration?), REST/RESTful command polling, webhooks, WebSocket API, and custom integrations (HACS/custom_components). For each: direction of connection (HA-initiated vs inbound), auth, reliability/acknowledgement semantics, and maintenance burden.
Answer
clean_start=True, from the core source). A broker therefore can't queue jobs for HA while it is offline, whichever broker is used. QoS 1 only covers delivery on a live connection.mqtt.publishand liveness viahomeassistant/status.rest_commandcallbacks (30 s polling, clunky YAML).return_response, long-lived Bearer token.resultper commandid, plus event subscriptions.Implication for #55: if the private link exists, hAPI calling HA's REST or WebSocket API is the simplest bridge (no broker, no HA-side code). If HA must initiate, MQTT to Mosquitto is the supported path. RabbitMQ is only worth it if hAPI wants AMQP for its own reasons.
Context pointer
Branch
research/ha-job-consumption. Findings (with sources and a comparison table): https://git.bobbypalko.com/bobby/hapi/src/branch/research/ha-job-consumption/docs/research/ha-job-consumption.md