Hello together,
sorry for asking this maybe too simple question but I can´t seem to figure out how to get Data out of an MQTT message. I´m not really expierenced with MQTT so please bear with me. The software I´m running to control all my fans on my water cooled PC has the ability send MQTT messages to my broker. I do receive the messages as expected but don´t know how to handle the received data.
For example here I´m trying to create an MQTT temperature sensor in Home Assistant that shows my water temps. I would like to use this sensor to run certain automations.
The MQTT Message looks like this:
{
"Id": "9990186d-899e-4d31-a680-7eac58f58044",
"Topic": "aquaero",
"Title": "Notification",
"Message": "",
"Data": [
{
"Name": "Wasser",
"Unit": "°C",
"Value": 31.02
}
]
}
I am also able to create the MQTT sensor but fail to get the information thats stored in “Value”. It simply shows nothing.
- platform: mqtt
name: "Wasser"
state_topic: "aquaero"
device_class: "temperature"
qos: 0
value_template: "{{ value_json.Value }}"
unit_of_measurement: '°C'
What am I doing wrong here?
Thanks in advance for your help!
Regards
Stefan