Combine Node
Combine Node
Article summary
Did you find this summary helpful?
Thank you for your feedback
Combine Node
The combine node takes data from multiple incoming JSON payloads and combines them into one JSON object. The combined JSON will contain all the unique JSON keys that the node has received. There are various options for configuring the output.
Adding a Combine node to your workflow
- First, select your desired solution and navigate to Rayven Workflow.
- Select ‘Functions’ from the left-hand panel.
- Find the Combine node and drag it onto the canvas.
- Connect the Combine node to your desired input node.
- Double click on the Combine node to open its configuration window.
Configuring your Combine node
- Give your node a Name. It’s best to choose something simple that clearly explains the node’s purpose. You must pick a name that has three or more characters.
- 'Hold Data From' can be used to retain data in the Combine node. To configure, enter the comma-separated Node IDs for the data you want to use. You'll need to connect these nodes as an input to your Combine node. The Combine node will hold data from listed Node IDs until data from another node is received.
- Select 'Keep adding data' if you want the data received from each input to be stored and added to each JSON payload that passes through. Note that a new value for the same JSON key will overwrite the previously held value.
- You then need to select a method for combining payloads. Select from the dropdown options:
- 'Combine Latest Received': combines JSON key-value pairs into a single JSON. The JSON values will always be the latest value for each device.
- 'Combine with Same Timestamp': combines JSON key-value pairs into a single JSON where all key-value pairs have the same timestamp.
- Set the node's behavior if an error takes place:
- Continue - Add Error to JSON: The error will appear in the JSON payload.
- Continue - Ignore Error: The error will not appear in the JSON payload.
- Stop - Log Error: The calculation and data flow will pause, and the node will flag the error.
NOTE: You need to use different field names in your combined JSON. In the event of duplicate field names, the latest value received will override the previous value.