{
  "ruleChain": {
    "additionalInfo": null,
    "name": "Root Rule Chain",
    "firstRuleNodeId": null,
    "root": true,
    "debugMode": false,
    "configuration": null
  },
  "metadata": {
    "firstNodeIndex": 2,
    "nodes": [
      {
        "additionalInfo": {
          "layoutX": 824,
          "layoutY": 156
        },
        "type": "org.thingsboard.rule.engine.telemetry.TbMsgTimeseriesNode",
        "name": "SaveTS",
        "debugMode": true,
        "configuration": {
          "defaultTTL": 0
        }
      },
      {
        "additionalInfo": {
          "layoutX": 825,
          "layoutY": 52
        },
        "type": "org.thingsboard.rule.engine.telemetry.TbMsgAttributesNode",
        "name": "save client attributes",
        "debugMode": true,
        "configuration": {
          "scope": "CLIENT_SCOPE"
        }
      },
      {
        "additionalInfo": {
          "layoutX": 347,
          "layoutY": 149
        },
        "type": "org.thingsboard.rule.engine.filter.TbMsgTypeSwitchNode",
        "name": "Message Type Switch",
        "debugMode": false,
        "configuration": {
          "version": 0
        }
      },
      {
        "additionalInfo": {
          "layoutX": 825,
          "layoutY": 266
        },
        "type": "org.thingsboard.rule.engine.action.TbLogNode",
        "name": "Log RPC",
        "debugMode": false,
        "configuration": {
          "jsScript": "return '\\nIncoming message:\\n' + JSON.stringify(msg) + '\\nIncoming metadata:\\n' + JSON.stringify(metadata);"
        }
      },
      {
        "additionalInfo": {
          "layoutX": 825,
          "layoutY": 379
        },
        "type": "org.thingsboard.rule.engine.action.TbLogNode",
        "name": "Log Other",
        "debugMode": false,
        "configuration": {
          "jsScript": "return '\\nIncoming message:\\n' + JSON.stringify(msg) + '\\nIncoming metadata:\\n' + JSON.stringify(metadata);"
        }
      }
    ],
    "connections": [
      {
        "fromIndex": 2,
        "toIndex": 4,
        "type": "Other"
      },
      {
        "fromIndex": 2,
        "toIndex": 1,
        "type": "Post attributes"
      },
      {
        "fromIndex": 2,
        "toIndex": 0,
        "type": "Post telemetry"
      },
      {
        "fromIndex": 2,
        "toIndex": 3,
        "type": "RPC Request"
      }
    ],
    "ruleChainConnections": null
  }
}