Merge
Combine outputs from multiple workflow branches using append, object merge, choose-branch, field join, positional zip, or cross join modes.
The Merge node collects outputs from all incoming branches, waits for every branch to complete, and then combines the results using one of six merge strategies. Use it whenever parallel branches reconverge -- for example, after an If/Else, after fetching data from multiple APIs, or after processing items in parallel paths.
Connect two or more upstream nodes to the Merge node. It will not execute until all incoming edges have delivered their data.
Configuration
Merge Mode
| Mode | Behavior |
|---|---|
| Append | Collects all branch outputs into a single flat array. Arrays are spread, scalars are pushed. |
| Combine | Merges all branch outputs into a single object. Later branches overwrite earlier keys on collision. |
| Choose Branch | Uses the output from the first branch that produced a non-empty (non-null) result. |
| Join by Fields | Joins two input arrays by matching key fields, like a SQL JOIN. |
| Combine by Position | Zips two input arrays by index position into merged objects. |
| Cross Join | Produces a cartesian product of two input arrays (capped at 100,000 items). |
Defaults to Append.
Join by Fields Settings
Only shown when Merge Mode is Join by Fields.
| Field | Type | Required | Description |
|---|---|---|---|
| Join Fields | text | Yes | Comma-separated field names to match records between the two inputs (e.g. id, email) |
| Join Type | select | No | Inner (matching only), Left (all from input 1), Right (all from input 2), Full Outer (all from both), or Anti (unmatched from input 1). Defaults to Inner. |
| On Field Clash | select | No | How to handle duplicate keys: Keep Input 1, Keep Input 2, Add _2 suffix, or Deep merge. Defaults to Keep Input 2. |
Clash Handling for Position and Cross Join
Shown when Merge Mode is Combine by Position or Cross Join.
| Field | Type | Required | Description |
|---|---|---|---|
| On Field Clash | select | No | How to handle duplicate keys: Keep Input 1, Keep Input 2, Add _2 suffix, or Deep merge. Defaults to Keep Input 2. |
Output
| Field | Type | Description |
|---|---|---|
| merged | array or object | The combined data. An array for append, join, position, and cross join modes; an object for combine mode; the chosen branch data for choose-branch mode. |
| count | number | Number of source branches that contributed (for append/combine/chooseBranch) or number of result items (for join/position/cross join) |
| sources | array | Node IDs of the branches that provided data |
Example
You run two parallel API calls -- one to fetch users and another to fetch their account details -- and need to combine them by user ID:
- Add two HTTP Request nodes that run in parallel after the trigger.
- Add a Merge node and connect both HTTP Request nodes to it.
- Set Merge Mode to Join by Fields.
- Set Join Fields to
userId. - Set Join Type to Inner.
- Set On Field Clash to Keep Input 2.
The output at nodes.merge_1.merged contains an array of combined user-plus-account objects, matched by userId. Users or accounts without a match in the other input are excluded (inner join).
For a simpler case where you just want all results in one list, use Append mode. For picking whichever parallel branch finishes with data first, use Choose Branch mode.
See the Logic Nodes overview for a full list of available nodes.