Hi,
I’ve been going on and around to get this figured out but I just can’t, so i’ll ask for your help. I’ve hooked up a door/window sensor with my Dresden elektronik RaspBee and I can get readings like the one below if I send a HTTP GET to the specific address. However, I can’t seem to be able to figure it out how to get the value of “open” (true or false) to Openhab.
I’ve tried with REGEX as well, but that was even less success. Any suggestions? Thanks a lot!
item:
String Zigbeetest “Zigbee: [%s]” (gTest) { http="<[http://192.168.0.199:8080/api/BD0AB797F7/sensors/2:60000:JSONPATH($.state[:1].open)]" }
Response:
{
“config”: {
“battery”: 100,
“on”: true,
“reachable”: true,
“temperature”: 2700
},
“ep”: 1,
“etag”: “3104a67e5c9f0e7da47509ea592b17f2”,
“manufacturername”: “LUMI”,
“modelid”: “lumi.sensor_magnet.aq2”,
“name”: “BathroomWindow”,
“state”: {
“lastupdated”: “2018-07-07T06:41:23”,
“open”: true
},
“type”: “ZHAOpenClose”,
“uniqueid”: “00:15:8d:00:02:05:b7:bf-01-0006”
}