Hello, i need to create a sensor that make a get command on a PLC that answer is in Json format, i've tried the REST Custom sensor with a custom template based on the data i need to "read" from the Json, and it's like this:
{ "prtg": { "result": [ { "channel": "allarme_fumo" , "value": 0 }, { "channel": "porta_aperta" , "value": 0 }, { "channel": "allarme_temperatura_prima_soglia", "value": 0 }, { "channel": "allarme_temperatura_seconda_soglia", "value": 0
The Json response is be like this:
{"allarme_fumo":0,"porta_aperta":1,"allarme_temperatura_prima_soglia":0,"allarme_temperatura_seconda_soglia":0,
My problem is PRTG sensor not read the Json result but read the template result, so if the Json have 1 in the response PRTG sensor remain at 0.
how can i write on the template that prtg must go to read the value from the Json?
Add comment