[
    {
        "id": "22b66213.8b6af6",
        "type": "tab",
        "label": "LwM2M Operation Example",
        "disabled": false,
        "info": "In order to deploy this flow, you need to provide the following information to `lwm2m` config node.\n\n- Endpoint ... Client Endpoint Name\n- Server Host ... LwM2M Server Host Name or IP Address\n\nTap each inject node to test *lwm2m client in* and *lwm2m client out* nodes.\nSee `debug` tab for the node output logs and you can find the messages these nodes emit.\n\nThe exec node labeled `fake reboot` will perform `echo` command when `/3/0/4` resource is executed.\nYou can find the output in Node-RED stdout.\n\nThe `catch` node will catch errors thrown by *lwm2m client in* and *lwm2m client out* nodes.\n"
    },
    {
        "id": "545cfccb.b146ec",
        "type": "lwm2m client in",
        "z": "22b66213.8b6af6",
        "name": "Read LwM2M Object Resources",
        "lwm2mClient": "7ef58ae1.09487c",
        "subscribeObjectEvents": false,
        "outputAsObject": false,
        "x": 525,
        "y": 184,
        "wires": [
            [
                "85151c41.5f7298"
            ]
        ]
    },
    {
        "id": "677d1fcd.c59d8",
        "type": "lwm2m client out",
        "z": "22b66213.8b6af6",
        "name": "Write or Execute LwM2M Resources",
        "lwm2mClient": "7ef58ae1.09487c",
        "x": 545,
        "y": 544,
        "wires": []
    },
    {
        "id": "726173e9.ba4574",
        "type": "inject",
        "z": "22b66213.8b6af6",
        "name": "",
        "topic": "^/3/.*",
        "payload": "",
        "payloadType": "str",
        "repeat": "",
        "crontab": "",
        "once": false,
        "x": 145,
        "y": 164,
        "wires": [
            [
                "545cfccb.b146ec"
            ]
        ]
    },
    {
        "id": "e3a86082.89adb8",
        "type": "catch",
        "z": "22b66213.8b6af6",
        "name": "Catch lwm2m client node errors",
        "scope": null,
        "uncaught": true,
        "x": 525,
        "y": 644,
        "wires": [
            [
                "fea1ba9e.e7661"
            ]
        ]
    },
    {
        "id": "85151c41.5f7298",
        "type": "debug",
        "z": "22b66213.8b6af6",
        "name": "Read Results",
        "active": true,
        "console": "false",
        "complete": "payload",
        "x": 785,
        "y": 244,
        "wires": []
    },
    {
        "id": "630ff515.cca4c4",
        "type": "inject",
        "z": "22b66213.8b6af6",
        "name": "",
        "topic": "/3/0/4/execute",
        "payload": "",
        "payloadType": "str",
        "repeat": "",
        "crontab": "",
        "once": false,
        "x": 175,
        "y": 504,
        "wires": [
            [
                "677d1fcd.c59d8"
            ]
        ]
    },
    {
        "id": "fe45894b.a0d82",
        "type": "switch",
        "z": "22b66213.8b6af6",
        "name": "Route executed resource",
        "property": "payload.uri",
        "propertyType": "msg",
        "rules": [
            {
                "t": "eq",
                "v": "/3/0/4",
                "vt": "str"
            }
        ],
        "checkall": "true",
        "outputs": 1,
        "x": 545,
        "y": 424,
        "wires": [
            [
                "273c1a26.e4532e"
            ]
        ],
        "outputLabels": [
            "/3/0/4 reboot"
        ]
    },
    {
        "id": "273c1a26.e4532e",
        "type": "exec",
        "z": "22b66213.8b6af6",
        "command": "echo",
        "addpay": false,
        "append": "##::##::##::##::##::##::##::##::##::##::##::##::",
        "useSpawn": "false",
        "timer": "",
        "oldrc": false,
        "name": "fake reboot",
        "x": 805,
        "y": 464,
        "wires": [
            [],
            [],
            []
        ]
    },
    {
        "id": "42add23b.64f9d4",
        "type": "inject",
        "z": "22b66213.8b6af6",
        "name": "",
        "topic": "/3/0/0",
        "payload": "MyManufacturer",
        "payloadType": "str",
        "repeat": "",
        "crontab": "",
        "once": false,
        "x": 195,
        "y": 584,
        "wires": [
            [
                "677d1fcd.c59d8"
            ]
        ]
    },
    {
        "id": "8a3268b5.55573",
        "type": "inject",
        "z": "22b66213.8b6af6",
        "name": "",
        "topic": "/3/0/0",
        "payload": "",
        "payloadType": "str",
        "repeat": "",
        "crontab": "",
        "once": false,
        "x": 145,
        "y": 244,
        "wires": [
            [
                "545cfccb.b146ec"
            ]
        ]
    },
    {
        "id": "2b2927b6.915a18",
        "type": "inject",
        "z": "22b66213.8b6af6",
        "name": "",
        "topic": "/3/0/4",
        "payload": "not allowed",
        "payloadType": "str",
        "repeat": "",
        "crontab": "",
        "once": false,
        "x": 185,
        "y": 664,
        "wires": [
            [
                "677d1fcd.c59d8"
            ]
        ]
    },
    {
        "id": "fea1ba9e.e7661",
        "type": "debug",
        "z": "22b66213.8b6af6",
        "name": "Error Info.",
        "active": true,
        "console": "false",
        "complete": "payload",
        "x": 795,
        "y": 704,
        "wires": []
    },
    {
        "id": "f8408b83.b48408",
        "type": "inject",
        "z": "22b66213.8b6af6",
        "name": "",
        "topic": "no-such-uri",
        "payload": "",
        "payloadType": "str",
        "repeat": "",
        "crontab": "",
        "once": false,
        "x": 165,
        "y": 404,
        "wires": [
            [
                "545cfccb.b146ec"
            ]
        ]
    },
    {
        "id": "c6fab90a.f5393",
        "type": "comment",
        "z": "22b66213.8b6af6",
        "name": "Read Operation",
        "info": "",
        "x": 155,
        "y": 124,
        "wires": []
    },
    {
        "id": "8c0a4d53.6da948",
        "type": "comment",
        "z": "22b66213.8b6af6",
        "name": "Read Manufacturer",
        "info": "",
        "x": 165,
        "y": 204,
        "wires": []
    },
    {
        "id": "1ed9b967.308c7f",
        "type": "comment",
        "z": "22b66213.8b6af6",
        "name": "Trigger Not Found Error",
        "info": "",
        "x": 175,
        "y": 364,
        "wires": []
    },
    {
        "id": "dbfd6ea5.84f9a",
        "type": "comment",
        "z": "22b66213.8b6af6",
        "name": "Execute Operation",
        "info": "",
        "x": 165,
        "y": 464,
        "wires": []
    },
    {
        "id": "823a8361.8d7d1",
        "type": "comment",
        "z": "22b66213.8b6af6",
        "name": "Write Operation",
        "info": "",
        "x": 155,
        "y": 544,
        "wires": []
    },
    {
        "id": "3dcacd75.9533aa",
        "type": "comment",
        "z": "22b66213.8b6af6",
        "name": "Trigger Method Not Allowed Error",
        "info": "",
        "x": 205,
        "y": 624,
        "wires": []
    },
    {
        "id": "89db1bac.d38368",
        "type": "comment",
        "z": "22b66213.8b6af6",
        "name": "Execute /3/0/4",
        "info": "",
        "x": 815,
        "y": 424,
        "wires": []
    },
    {
        "id": "85520105.663e1",
        "type": "inject",
        "z": "22b66213.8b6af6",
        "name": "",
        "topic": "/3/0/7",
        "payload": "",
        "payloadType": "str",
        "repeat": "",
        "crontab": "",
        "once": false,
        "x": 145,
        "y": 324,
        "wires": [
            [
                "545cfccb.b146ec"
            ]
        ]
    },
    {
        "id": "227b7675.81ad6a",
        "type": "comment",
        "z": "22b66213.8b6af6",
        "name": "Read Multiple Resource",
        "info": "",
        "x": 175,
        "y": 284,
        "wires": []
    },
    {
        "id": "1c5e8915.31dce7",
        "type": "lwm2m client in",
        "z": "22b66213.8b6af6",
        "name": "Subscribe LwM2M Object Events",
        "lwm2mClient": "7ef58ae1.09487c",
        "subscribeObjectEvents": true,
        "x": 535,
        "y": 344,
        "wires": [
            [
                "fe45894b.a0d82",
                "3a48e78.1f32798"
            ]
        ]
    },
    {
        "id": "3a48e78.1f32798",
        "type": "debug",
        "z": "22b66213.8b6af6",
        "name": "Events",
        "active": true,
        "console": "false",
        "complete": "payload",
        "x": 765,
        "y": 304,
        "wires": []
    },
    {
        "id": "2790a1f7.015076",
        "type": "comment",
        "z": "22b66213.8b6af6",
        "name": "Start Operation for Lazy Start",
        "info": "",
        "x": 193,
        "y": 49,
        "wires": []
    },
    {
        "id": "cc674bfc.faaf9",
        "type": "inject",
        "z": "22b66213.8b6af6",
        "name": "",
        "topic": "start",
        "payload": "",
        "payloadType": "str",
        "repeat": "",
        "crontab": "",
        "once": false,
        "onceDelay": "",
        "x": 142,
        "y": 85,
        "wires": [
            [
                "545cfccb.b146ec"
            ]
        ]
    },
    {
        "id": "7ef58ae1.09487c",
        "type": "lwm2m client",
        "z": "22b66213.8b6af6",
        "disabled": false,
        "lazyStart": false,
        "clientName": "",
        "enableDTLS": false,
        "clientPort": "56830",
        "lifetimeSec": "300",
        "reconnectSec": "300",
        "bootstrapIntervalSec": "3600",
        "maxRecvPacketSize": "",
        "requestBootstrap": false,
        "saveProvisionedConfig": false,
        "useIPv4": true,
        "serverHost": "",
        "serverPort": "5683",
        "redirectLwm2mClientLog": false,
        "dumpLwm2mMessages": false,
        "hideSensitiveInfo": true,
        "propagateInternalEvents": false,
        "objects": "{\"32769\":{\"0\":{\"0\":{\"type\":\"STRING\",\"acl\":\"RW\",\"value\":\"abcd\"},\"1\":{\"type\":\"INTEGER\",\"acl\":\"RW\",\"value\":123456},\"2\":true}}}"
    }
]