Hi @rossko57,
Thanks a lot you for your help. Working example below
Solution was to change as you said onValue to on and offValue to off.
Also to create a Transform .map(in this case filename “sonoff.map”) file with
on={"deviceid":"","data":{"switch":"on"}}
off={"deviceid":"","data":{"switch":"off"}}
UID: http:url:66be259eda
label: Test 3
thingTypeUID: http:url
configuration:
authMode: BASIC
ignoreSSLErrors: false
baseURL: http://192.168.100.45:8081/zeroconf/
delay: 500
stateMethod: POST
refresh: 6
commandMethod: POST
contentType: application/json
timeout: 3000
bufferSize: 2048
channels:
- id: switch_trest
channelTypeUID: http:switch
label: switch_trest
description: ""
configuration:
onValue: on
stateContent: '{"deviceid":"","data":{}}'
commandTransformation: MAP:sonoff.map
offValue: off
stateExtension: info
commandExtension: switch
stateTransformation: JSONPATH:$.data.switch
- id: sonwifi
channelTypeUID: http:string
label: wifi
description: ""
configuration:
stateExtension: info
stateTransformation: JSONPATH:$.data.signalStrength
stateContent: '{"deviceid":"","data":{}}'