rule-chain-controller

Update Rule Chain Metadata

Updates the rule chain metadata. The metadata object contains information about the rule nodes and their connections.

Available for users with 'TENANT_ADMIN' authority.

post/api/ruleChain/metadata

Request

Query parameters

updateRelatedboolean

Update related rule nodes.

Request body

versioninteger

Version of the Rule Chain

firstNodeIndexinteger required

Index of the first rule node in the 'nodes' list

Example request

{
  "ruleChainId": {
    "id": "784f394c-42b6-435a-983c-b7beff2784f9",
    "entityType": "RULE_CHAIN"
  },
  "nodes": [
    {
      "id": {
        "id": "784f394c-42b6-435a-983c-b7beff2784f9",
        "entityType": "RULE_NODE"
      },
      "createdTime": 1609459200000,
      "ruleChainId": {
        "id": "784f394c-42b6-435a-983c-b7beff2784f9",
        "entityType": "RULE_CHAIN"
      },
      "type": "com.mycompany.iot.rule.engine.ProcessingNode",
      "name": "Process sensor reading",
      "queueName": "Main",
      "configuration": {},
      "externalId": {
        "id": "784f394c-42b6-435a-983c-b7beff2784f9",
        "entityType": "RULE_NODE"
      },
      "additionalInfo": {}
    }
  ],
  "ruleChainConnections": [
    {
      "targetRuleChainId": {
        "id": "784f394c-42b6-435a-983c-b7beff2784f9",
        "entityType": "RULE_CHAIN"
      },
      "additionalInfo": {}
    }
  ]
}

Response

OK

versioninteger

Version of the Rule Chain

firstNodeIndexinteger required

Index of the first rule node in the 'nodes' list

Example response

{
  "ruleChainId": {
    "id": "784f394c-42b6-435a-983c-b7beff2784f9",
    "entityType": "RULE_CHAIN"
  },
  "nodes": [
    {
      "id": {
        "id": "784f394c-42b6-435a-983c-b7beff2784f9",
        "entityType": "RULE_NODE"
      },
      "createdTime": 1609459200000,
      "ruleChainId": {
        "id": "784f394c-42b6-435a-983c-b7beff2784f9",
        "entityType": "RULE_CHAIN"
      },
      "type": "com.mycompany.iot.rule.engine.ProcessingNode",
      "name": "Process sensor reading",
      "queueName": "Main",
      "configuration": {},
      "externalId": {
        "id": "784f394c-42b6-435a-983c-b7beff2784f9",
        "entityType": "RULE_NODE"
      },
      "additionalInfo": {}
    }
  ],
  "ruleChainConnections": [
    {
      "targetRuleChainId": {
        "id": "784f394c-42b6-435a-983c-b7beff2784f9",
        "entityType": "RULE_CHAIN"
      },
      "additionalInfo": {}
    }
  ]
}

Changes

No recorded changes to this operation across all 2 revisions of this API.