Skip to content

Instantly share code, notes, and snippets.

@subzero79
Created April 16, 2018 14:19
Show Gist options
  • Save subzero79/d2a30e3de203352e63234a698efac470 to your computer and use it in GitHub Desktop.
Save subzero79/d2a30e3de203352e63234a698efac470 to your computer and use it in GitHub Desktop.
[
{
"id": "f227ead0.51eac8",
"type": "tab",
"label": "Flow 1",
"disabled": false,
"info": ""
},
{
"id": "d6e49633.dcb3a8",
"type": "server-events",
"z": "f227ead0.51eac8",
"name": "HASrv",
"server": "d5ce5cec.92bc8",
"x": 249,
"y": 513,
"wires": [
[
"74a3b76c.ed1d08"
]
]
},
{
"id": "74a3b76c.ed1d08",
"type": "switch",
"z": "f227ead0.51eac8",
"name": "",
"property": "payload.entity_id",
"propertyType": "msg",
"rules": [
{
"t": "eq",
"v": "binary_sensor.switch_158d0002108072",
"vt": "str"
}
],
"checkall": "true",
"repair": true,
"outputs": 1,
"x": 454,
"y": 511,
"wires": [
[
"696f0d4d.65bb54"
]
]
},
{
"id": "696f0d4d.65bb54",
"type": "switch",
"z": "f227ead0.51eac8",
"name": "Button_3",
"property": "payload.event.click_type",
"propertyType": "msg",
"rules": [
{
"t": "eq",
"v": "single",
"vt": "str"
},
{
"t": "eq",
"v": "double",
"vt": "str"
}
],
"checkall": "true",
"repair": true,
"outputs": 2,
"x": 631,
"y": 510,
"wires": [
[
"592c5403.4472ec"
],
[
"72d1149f.06d34c"
]
]
},
{
"id": "72d1149f.06d34c",
"type": "api-call-service",
"z": "f227ead0.51eac8",
"name": "dining",
"server": "d5ce5cec.92bc8",
"service_domain": "light",
"service": "toggle",
"data": "{\"entity_id\":\"light.dining_table\"}",
"mergecontext": "",
"x": 842,
"y": 543,
"wires": [
[]
],
"icon": "node-red/light.png"
},
{
"id": "592c5403.4472ec",
"type": "api-call-service",
"z": "f227ead0.51eac8",
"name": "downlights",
"server": "d5ce5cec.92bc8",
"service_domain": "light",
"service": "toggle",
"data": "{\"entity_id\":\"light.daddy\"}",
"mergecontext": "",
"x": 843,
"y": 472,
"wires": [
[]
],
"icon": "node-red/light.png"
},
{
"id": "d5ce5cec.92bc8",
"type": "server",
"z": "",
"name": "Home Assistant",
"url": "https://SERVER:8123",
"pass": "PASSWORD"
}
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment