switch:
platform: command_line
switches:
jdchazuo:
friendly_name: 京东插座
command_on: curl -X POST -H "app_identity:WL" -H "Authorization:此处需要按照你的抓包结果来填写" -H "tgt:此处需要按照你的抓包结果来填写" -H "Content-Type:application/json; charset=utf-8" -H "Content-Length:123" -H "Host:gw.smart.jd.com" -H "Connection:Keep-Alive" -H "Accept-Encoding:gzip" -H "User-Agent
khttp/3.11.0" -d '{"json":"{\"feed_id\":347491659196802546,\"command\":[{\"stream_id\":\"Power\",\"current_value\":1}],\"version\":\"2.0\"}"}' "https://gw.smart.jd.com/c/service/integration/v1/controlDevice_v1?hard_platform=Redmi+Note+7&app_version=7.3.0&device_id=此处需要按照你的抓包结果来填写&plat_version=9&channel=jd&plat=Android"
command_off: curl -X POST -H "app_identity:WL" -H "Authorization:此处需要按照你的抓包结果来填写" -H "tgt此处需要按照你的抓包结果来填写" -H "Content-Type:application/json; charset=utf-8" -H "Content-Length:123" -H "Host:gw.smart.jd.com" -H "Connection:Keep-Alive" -H "Accept-Encoding:gzip" -H "User-Agent
khttp/3.11.0" -d '{"json":"{\"feed_id\":347491659196802546,\"command\":[{\"stream_id\":\"Power\",\"current_value\":0}],\"version\":\"2.0\"}"}' 'https://gw.smart.jd.com/c/service/integration/v1/controlDevice_v1?hard_platform=Redmi+Note+7&app_version=7.3.0&device_id=此处需要按照你的抓包结果来填写&plat_version=9&channel=jd&plat=Android'