Quantcast
Channel: Configuration - Home Assistant Community
Viewing all articles
Browse latest Browse all 109599

Consuming mqtt_statestream

$
0
0

So mqtt_statestream provides a really simple way to publish all (or some) entities to MQTT, with options for also publishing attributes and last changed timestamps. However, it surprised me that there’s not a similar “client” component for this functionality to consume easily consume these entities on another HA instance.

What I want to do is simply to “mirror” some sensors from one HA instance on another, with (at least) the state/value and last changed timestamps available.

So far, I have publishing the states using mqtt_statestream, and consuming them using mqtt platform sensors. Is that the best way to go? mqtt_statestream is able to publish attributes/timestamps, but it does so on separate topics that are not picked up by the mqtt sensors. I see there’s a json_attribute_template on the mqtt sensors, but of course the attributes aren’t published as json, so I don’t see how that’s going to work.

It seems to me this is harder than it could be. Am I on the right track? What’s the best way to get the timestamps copied over together with the state? Thanks!

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 109599

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>