[
    {
        "id": "58d5fcf204887c3d",
        "type": "tab",
        "label": "Уведомления VK",
        "disabled": false,
        "info": "",
        "env": []
    },
    {
        "id": "0c534fc42d16031b",
        "type": "group",
        "z": "58d5fcf204887c3d",
        "name": "2. Уведомлений сработки выключателей и реле",
        "style": {
            "label": true,
            "color": "#3f3f3f"
        },
        "nodes": [
            "6aca1adccf0a533b",
            "f9066c0e81986225",
            "4d09375a0402ea4d",
            "e765702ac444f8f1",
            "b5912ddc9f6e447a"
        ],
        "x": 74,
        "y": 239,
        "w": 952,
        "h": 122
    },
    {
        "id": "14c5436d87779733",
        "type": "group",
        "z": "58d5fcf204887c3d",
        "name": "3. Уведомление о привышении температуры выше 28С с интервалом 5 минут",
        "style": {
            "label": true,
            "color": "#3f3f3f"
        },
        "nodes": [
            "fed881673c05619d",
            "15e70bfa42876127",
            "79bf127fecb95fca",
            "09d041283ba787b5",
            "fbeb265dd2102c33"
        ],
        "x": 74,
        "y": 399,
        "w": 952,
        "h": 82
    },
    {
        "id": "2a0a528db2134a9a",
        "type": "group",
        "z": "58d5fcf204887c3d",
        "name": "4. Уведомление о понижении температуры ниже 24С  с интервалом 5 минут",
        "style": {
            "label": true,
            "color": "#3f3f3f"
        },
        "nodes": [
            "0cfdaa0c600345b8",
            "d056ced190e4e1a7",
            "d9635e12bedb851f",
            "5284fcfb89b2db9a",
            "a30d7b52ea081bef"
        ],
        "x": 74,
        "y": 519,
        "w": 952,
        "h": 82
    },
    {
        "id": "5103e8076c146e72",
        "type": "group",
        "z": "58d5fcf204887c3d",
        "name": "5. Уведомление о срабтки датчика протечки",
        "style": {
            "label": true,
            "color": "#3f3f3f"
        },
        "nodes": [
            "df9be2a8d1e58d9b",
            "6067110991b22d17",
            "402a5247bb696a0b",
            "f6d2f7dff17dab73",
            "cb0b0bb968e403f6",
            "bc946ad636e44f6c"
        ],
        "x": 74,
        "y": 639,
        "w": 952,
        "h": 122
    },
    {
        "id": "dba09455739388a6",
        "type": "group",
        "z": "58d5fcf204887c3d",
        "name": "1. Отпраквка сообщение в VK",
        "style": {
            "label": true,
            "color": "#3f3f3f"
        },
        "nodes": [
            "9f3e7782ec0a5e34",
            "c09091938764e4ef",
            "f62a10437590d6e2"
        ],
        "x": 74,
        "y": 119,
        "w": 572,
        "h": 82
    },
    {
        "id": "323da4276b23fa6e",
        "type": "group",
        "z": "58d5fcf204887c3d",
        "name": "6. Уведомление о срабтки датчика отурытия двери",
        "style": {
            "label": true,
            "color": "#3f3f3f"
        },
        "nodes": [
            "f55a170e4abbb3b3",
            "d6d19e8636a5490a",
            "6819581bdab4faae",
            "7bc329d046952d10",
            "f9d021f3d6c2db3b",
            "1143d3d19c8c977d"
        ],
        "x": 74,
        "y": 779,
        "w": 952,
        "h": 122
    },
    {
        "id": "8d3b59a5400ffb15",
        "type": "group",
        "z": "58d5fcf204887c3d",
        "name": "7. Блок проверки настроек",
        "style": {
            "label": true,
            "color": "#3f3f3f"
        },
        "nodes": [
            "b90eeeed3544c96e",
            "d597a25262cedb4a",
            "77598d7aa718e79f"
        ],
        "x": 74,
        "y": 939,
        "w": 652,
        "h": 82
    },
    {
        "id": "6aca1adccf0a533b",
        "type": "event-state",
        "z": "58d5fcf204887c3d",
        "g": "0c534fc42d16031b",
        "name": "Освещение на улице",
        "server": "8641e3648f77492c",
        "list": "",
        "category": "switch",
        "device": "0x08ddebfffed07eef",
        "state": "power",
        "x": 200,
        "y": 300,
        "wires": [
            [
                "4d09375a0402ea4d"
            ]
        ]
    },
    {
        "id": "f9066c0e81986225",
        "type": "switch",
        "z": "58d5fcf204887c3d",
        "g": "0c534fc42d16031b",
        "name": "Выясняем ВКЛ/ВЫКЛ",
        "property": "payload",
        "propertyType": "msg",
        "rules": [
            {
                "t": "cont",
                "v": "on",
                "vt": "str"
            },
            {
                "t": "cont",
                "v": "off",
                "vt": "str"
            }
        ],
        "checkall": "true",
        "repair": false,
        "outputs": 2,
        "x": 610,
        "y": 300,
        "wires": [
            [
                "e765702ac444f8f1"
            ],
            [
                "b5912ddc9f6e447a"
            ]
        ]
    },
    {
        "id": "4d09375a0402ea4d",
        "type": "rbe",
        "z": "58d5fcf204887c3d",
        "g": "0c534fc42d16031b",
        "name": "",
        "func": "rbe",
        "gap": "",
        "start": "",
        "inout": "out",
        "septopics": true,
        "property": "payload",
        "topi": "topic",
        "x": 390,
        "y": 300,
        "wires": [
            [
                "f9066c0e81986225"
            ]
        ]
    },
    {
        "id": "fed881673c05619d",
        "type": "function",
        "z": "58d5fcf204887c3d",
        "g": "14c5436d87779733",
        "name": "Температура в доме",
        "func": "var temp = msg.payload[0].state.temperature.temperature\n\nmsg.payload = {}\n    msg.payload.text = \"Температура в доме превысела 28 °C. Сейчас \" + temp + \" °C.\"\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 820,
        "y": 440,
        "wires": [
            [
                "fbeb265dd2102c33"
            ]
        ]
    },
    {
        "id": "15e70bfa42876127",
        "type": "switch",
        "z": "58d5fcf204887c3d",
        "g": "14c5436d87779733",
        "name": ">= 28C",
        "property": "payload[0].state.temperature.temperature",
        "propertyType": "msg",
        "rules": [
            {
                "t": "gte",
                "v": "28",
                "vt": "num"
            }
        ],
        "checkall": "true",
        "repair": false,
        "outputs": 1,
        "x": 600,
        "y": 440,
        "wires": [
            [
                "fed881673c05619d"
            ]
        ]
    },
    {
        "id": "79bf127fecb95fca",
        "type": "get-devices",
        "z": "58d5fcf204887c3d",
        "g": "14c5436d87779733",
        "name": "t студия",
        "server": "bbb98c6fe0bc04f3",
        "category": "all",
        "device": "0xa4c13801aa73ffff",
        "x": 400,
        "y": 440,
        "wires": [
            [
                "15e70bfa42876127"
            ]
        ]
    },
    {
        "id": "09d041283ba787b5",
        "type": "inject",
        "z": "58d5fcf204887c3d",
        "g": "14c5436d87779733",
        "name": "",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "300",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "",
        "payloadType": "date",
        "x": 210,
        "y": 440,
        "wires": [
            [
                "79bf127fecb95fca"
            ]
        ]
    },
    {
        "id": "0cfdaa0c600345b8",
        "type": "switch",
        "z": "58d5fcf204887c3d",
        "g": "2a0a528db2134a9a",
        "name": "<= 24C",
        "property": "payload[0].state.temperature.temperature",
        "propertyType": "msg",
        "rules": [
            {
                "t": "lte",
                "v": "24",
                "vt": "num"
            }
        ],
        "checkall": "true",
        "repair": false,
        "outputs": 1,
        "x": 600,
        "y": 560,
        "wires": [
            [
                "a30d7b52ea081bef"
            ]
        ]
    },
    {
        "id": "d056ced190e4e1a7",
        "type": "get-devices",
        "z": "58d5fcf204887c3d",
        "g": "2a0a528db2134a9a",
        "name": "t студия",
        "server": "bbb98c6fe0bc04f3",
        "category": "temperatureSensor",
        "device": "0xa4c13801aa73ffff",
        "x": 400,
        "y": 560,
        "wires": [
            [
                "0cfdaa0c600345b8"
            ]
        ]
    },
    {
        "id": "d9635e12bedb851f",
        "type": "inject",
        "z": "58d5fcf204887c3d",
        "g": "2a0a528db2134a9a",
        "name": "",
        "props": [
            {
                "p": "payload"
            },
            {
                "p": "topic",
                "vt": "str"
            }
        ],
        "repeat": "300",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "payload": "",
        "payloadType": "date",
        "x": 210,
        "y": 560,
        "wires": [
            [
                "d056ced190e4e1a7"
            ]
        ]
    },
    {
        "id": "5284fcfb89b2db9a",
        "type": "link out",
        "z": "58d5fcf204887c3d",
        "g": "2a0a528db2134a9a",
        "name": "link out 20",
        "mode": "link",
        "links": [
            "c09091938764e4ef"
        ],
        "x": 985,
        "y": 560,
        "wires": []
    },
    {
        "id": "df9be2a8d1e58d9b",
        "type": "function",
        "z": "58d5fcf204887c3d",
        "g": "5103e8076c146e72",
        "name": "Ой-ой, протечка",
        "func": "msg.payload = {}\n    msg.payload.text = \"На кухне обнаружена протечка.\"\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 830,
        "y": 680,
        "wires": [
            [
                "bc946ad636e44f6c"
            ]
        ]
    },
    {
        "id": "6067110991b22d17",
        "type": "switch",
        "z": "58d5fcf204887c3d",
        "g": "5103e8076c146e72",
        "name": "Статус протечки",
        "property": "payload",
        "propertyType": "msg",
        "rules": [
            {
                "t": "cont",
                "v": "true",
                "vt": "str"
            },
            {
                "t": "cont",
                "v": "false",
                "vt": "str"
            }
        ],
        "checkall": "true",
        "repair": false,
        "outputs": 2,
        "x": 590,
        "y": 700,
        "wires": [
            [
                "df9be2a8d1e58d9b"
            ],
            [
                "f6d2f7dff17dab73"
            ]
        ]
    },
    {
        "id": "402a5247bb696a0b",
        "type": "event-state",
        "z": "58d5fcf204887c3d",
        "g": "5103e8076c146e72",
        "name": "Протечка на кухне",
        "server": "bbb98c6fe0bc04f3",
        "list": "",
        "category": "waterLeakDetector",
        "device": "0x8c73dafffe85063d",
        "state": "water-leak",
        "x": 190,
        "y": 700,
        "wires": [
            [
                "cb0b0bb968e403f6"
            ]
        ]
    },
    {
        "id": "f6d2f7dff17dab73",
        "type": "function",
        "z": "58d5fcf204887c3d",
        "g": "5103e8076c146e72",
        "name": "Теперь уже сухо",
        "func": "msg.payload = {}\n    msg.payload.text = \"На кухне теперь сухо.\"\nreturn msg;\n",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 830,
        "y": 720,
        "wires": [
            [
                "bc946ad636e44f6c"
            ]
        ]
    },
    {
        "id": "cb0b0bb968e403f6",
        "type": "rbe",
        "z": "58d5fcf204887c3d",
        "g": "5103e8076c146e72",
        "name": "",
        "func": "rbe",
        "gap": "",
        "start": "",
        "inout": "out",
        "septopics": true,
        "property": "payload",
        "topi": "topic",
        "x": 390,
        "y": 700,
        "wires": [
            [
                "6067110991b22d17"
            ]
        ]
    },
    {
        "id": "bc946ad636e44f6c",
        "type": "link out",
        "z": "58d5fcf204887c3d",
        "g": "5103e8076c146e72",
        "name": "link out 21",
        "mode": "link",
        "links": [
            "c09091938764e4ef"
        ],
        "x": 985,
        "y": 700,
        "wires": []
    },
    {
        "id": "e765702ac444f8f1",
        "type": "vk-sender",
        "z": "58d5fcf204887c3d",
        "g": "0c534fc42d16031b",
        "name": "MSG: Свет включен",
        "config": "365cf3235516d0cf",
        "peer_id": "7500512",
        "text": "Свет на улице включен.",
        "x": 900,
        "y": 280,
        "wires": [
            []
        ]
    },
    {
        "id": "b5912ddc9f6e447a",
        "type": "vk-sender",
        "z": "58d5fcf204887c3d",
        "g": "0c534fc42d16031b",
        "name": "MSG: Свет выключен",
        "config": "365cf3235516d0cf",
        "peer_id": "7500512",
        "text": "Свет на улице выключен.",
        "x": 900,
        "y": 320,
        "wires": [
            []
        ]
    },
    {
        "id": "c09091938764e4ef",
        "type": "link in",
        "z": "58d5fcf204887c3d",
        "g": "dba09455739388a6",
        "name": "VK-OUT",
        "links": [
            "5284fcfb89b2db9a",
            "bc946ad636e44f6c",
            "fbeb265dd2102c33",
            "1143d3d19c8c977d"
        ],
        "x": 115,
        "y": 160,
        "wires": [
            [
                "f62a10437590d6e2"
            ]
        ]
    },
    {
        "id": "9f3e7782ec0a5e34",
        "type": "vk-sender",
        "z": "58d5fcf204887c3d",
        "g": "dba09455739388a6",
        "name": "MSG-VK: Отправка сообщений",
        "config": "365cf3235516d0cf",
        "peer_id": "7500512",
        "text": "",
        "x": 480,
        "y": 160,
        "wires": [
            []
        ]
    },
    {
        "id": "a30d7b52ea081bef",
        "type": "function",
        "z": "58d5fcf204887c3d",
        "g": "2a0a528db2134a9a",
        "name": "Температура в доме",
        "func": "var temp = msg.payload[0].state.temperature.temperature\n\nmsg.payload = {}\n    msg.payload.text = \"Температура в доме меньше 24 °C. Сейчас \" + temp + \" °C.\"\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 820,
        "y": 560,
        "wires": [
            [
                "5284fcfb89b2db9a"
            ]
        ]
    },
    {
        "id": "f62a10437590d6e2",
        "type": "delay",
        "z": "58d5fcf204887c3d",
        "g": "dba09455739388a6",
        "name": "",
        "pauseType": "delay",
        "timeout": "5",
        "timeoutUnits": "seconds",
        "rate": "1",
        "nbRateUnits": "1",
        "rateUnits": "second",
        "randomFirst": "1",
        "randomLast": "5",
        "randomUnits": "seconds",
        "drop": false,
        "allowrate": false,
        "outputs": 1,
        "x": 230,
        "y": 160,
        "wires": [
            [
                "9f3e7782ec0a5e34"
            ]
        ]
    },
    {
        "id": "fbeb265dd2102c33",
        "type": "link out",
        "z": "58d5fcf204887c3d",
        "g": "14c5436d87779733",
        "name": "link out 17",
        "mode": "link",
        "links": [
            "c09091938764e4ef"
        ],
        "x": 985,
        "y": 440,
        "wires": []
    },
    {
        "id": "bc4d861c4182d5e8",
        "type": "comment",
        "z": "58d5fcf204887c3d",
        "name": "ОТПРАВКА УВЕДОМЛЕНИЙ В VK",
        "info": "",
        "x": 220,
        "y": 60,
        "wires": []
    },
    {
        "id": "f55a170e4abbb3b3",
        "type": "function",
        "z": "58d5fcf204887c3d",
        "g": "323da4276b23fa6e",
        "name": "Дверь открыта",
        "func": "msg.payload = {}\n    msg.payload.text = \"Дверь в дом открыта.\"\nreturn msg;",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 820,
        "y": 820,
        "wires": [
            [
                "1143d3d19c8c977d"
            ]
        ]
    },
    {
        "id": "d6d19e8636a5490a",
        "type": "switch",
        "z": "58d5fcf204887c3d",
        "g": "323da4276b23fa6e",
        "name": "Статус открытия",
        "property": "payload",
        "propertyType": "msg",
        "rules": [
            {
                "t": "cont",
                "v": "true",
                "vt": "str"
            },
            {
                "t": "cont",
                "v": "false",
                "vt": "str"
            }
        ],
        "checkall": "true",
        "repair": false,
        "outputs": 2,
        "x": 590,
        "y": 840,
        "wires": [
            [
                "f55a170e4abbb3b3"
            ],
            [
                "7bc329d046952d10"
            ]
        ]
    },
    {
        "id": "6819581bdab4faae",
        "type": "event-state",
        "z": "58d5fcf204887c3d",
        "g": "323da4276b23fa6e",
        "name": "Протечка открытия",
        "server": "bbb98c6fe0bc04f3",
        "list": "",
        "category": "contactSensor",
        "device": "0xa4c1380c37f4ffff",
        "state": "contact",
        "x": 190,
        "y": 840,
        "wires": [
            [
                "f9d021f3d6c2db3b"
            ]
        ]
    },
    {
        "id": "7bc329d046952d10",
        "type": "function",
        "z": "58d5fcf204887c3d",
        "g": "323da4276b23fa6e",
        "name": "Дверь закрыта",
        "func": "msg.payload = {}\nmsg.payload.text = \"Дверь в доме закрыта.\"\nreturn msg;\n",
        "outputs": 1,
        "timeout": 0,
        "noerr": 0,
        "initialize": "",
        "finalize": "",
        "libs": [],
        "x": 820,
        "y": 860,
        "wires": [
            [
                "1143d3d19c8c977d"
            ]
        ]
    },
    {
        "id": "f9d021f3d6c2db3b",
        "type": "rbe",
        "z": "58d5fcf204887c3d",
        "g": "323da4276b23fa6e",
        "name": "",
        "func": "rbe",
        "gap": "",
        "start": "",
        "inout": "out",
        "septopics": true,
        "property": "payload",
        "topi": "topic",
        "x": 390,
        "y": 840,
        "wires": [
            [
                "d6d19e8636a5490a"
            ]
        ]
    },
    {
        "id": "1143d3d19c8c977d",
        "type": "link out",
        "z": "58d5fcf204887c3d",
        "g": "323da4276b23fa6e",
        "name": "link out 18",
        "mode": "link",
        "links": [
            "c09091938764e4ef"
        ],
        "x": 985,
        "y": 840,
        "wires": []
    },
    {
        "id": "b90eeeed3544c96e",
        "type": "vk-sender",
        "z": "58d5fcf204887c3d",
        "g": "8d3b59a5400ffb15",
        "name": "MSG: Свет включен",
        "config": "365cf3235516d0cf",
        "peer_id": "852221922",
        "text": "Тестовое сообщение",
        "x": 400,
        "y": 980,
        "wires": [
            [
                "77598d7aa718e79f"
            ]
        ]
    },
    {
        "id": "d597a25262cedb4a",
        "type": "inject",
        "z": "58d5fcf204887c3d",
        "g": "8d3b59a5400ffb15",
        "name": "",
        "props": [],
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": 0.1,
        "topic": "",
        "x": 180,
        "y": 980,
        "wires": [
            [
                "b90eeeed3544c96e"
            ]
        ]
    },
    {
        "id": "77598d7aa718e79f",
        "type": "debug",
        "z": "58d5fcf204887c3d",
        "g": "8d3b59a5400ffb15",
        "name": "debug 66",
        "active": true,
        "tosidebar": true,
        "console": false,
        "tostatus": false,
        "complete": "false",
        "statusVal": "",
        "statusType": "auto",
        "x": 620,
        "y": 980,
        "wires": []
    },
    {
        "id": "8641e3648f77492c",
        "type": "api-server",
        "name": "iHost 23",
        "ip": "192.168.31.23",
        "ipaddr": "",
        "token": "6f2e3720-4bcc-4c71-bbe2-588b7c53553c"
    },
    {
        "id": "bbb98c6fe0bc04f3",
        "type": "api-server",
        "name": "iHostLocal",
        "ip": "127.0.0.1",
        "ipaddr": "",
        "token": "8785ae3b-c31f-40b4-87fd-5551836df332"
    },
    {
        "id": "365cf3235516d0cf",
        "type": "vk-config",
        "name": "VK",
        "token": "vk1.a.MDfhUnk5hCavSLkzgFAk0jn04f_mQ7prRCD18LV-NjEbubCvl5DAClFv-gV3PwMjVZBWLXCK-DgPNfWMTG8z-eFcdEDTm7xudRQ8Re5IUsHgZgN7jGSD_DDGnkGzPJIg90A51N9cTV6nlcABX98NVFcwG-squLb1qoeIeYTZtzrokBMVFVH1qkj8s_YSL7f_cfgCcOICbsyo_3jV8R-dgQ",
        "secret": "",
        "apiVersion": "5.199"
    },
    {
        "id": "7294bb7c6b2f5397",
        "type": "global-config",
        "env": [],
        "modules": {
            "node-red-contrib-ewelink-cube": "1.3.7",
            "@and-rom/node-red-contrib-vk-io-bot": "1.2.5"
        }
    }
]