n8n Workflow

Merge Data For Multiple Executions

This n8n workflow automates tasks and integrates with various services. Merge Data For Multiple Executions - ready to import and run in your n8n instance.

n8n workflow.json

About This Script

This n8n workflow automates tasks and integrates with various services. Merge Data For Multiple Executions - ready to import and run in your n8n instance.
Features:
  • Custom JavaScript function processing
  • Conditional logic and branching
Source Code
{
    "nodes": [
        {
            "name": "On clicking 'execute'",
            "type": "n8n-nodes-base.manualTrigger",
            "position": [
                270,
                330
            ],
            "parameters": [],
            "typeVersion": 1,
            "id": "7fd55d7b-4151-4997-aab8-425fc7c22c5f"
        },
        {
            "name": "Merge Data",
            "type": "n8n-nodes-base.function",
            "position": [
                1230,
                430
            ],
            "parameters": {
                "functionCode": "const allData = []\n\nlet counter = 0;\ndo {\n  try {\n    const items = $items(\"RSS Feed Read\", 0, counter).map(item => item.json);\n    allData.push.apply(allData, items);\n  } catch (error) {\n    return [{json: {allData}}];  \n  }\n\n  counter++;\n} while(true);\n\n\n"
            },
            "typeVersion": 1,
            "id": "ee97cbd3-d6d0-4c77-ba28-2a913f2926e6"
        },
        {
            "name": "Function",
            "type": "n8n-nodes-base.function",
            "position": [
                470,
                330
            ],
            "parameters": {
                "functionCode": "return [\n  {\n    json: {\n      url: 'https://medium.com/feed/n8n-io',\n    }\n  },\n  {\n    json: {\n      url: 'https://dev.to/feed/n8n',\n    }\n  }\n];"
            },
            "typeVersion": 1,
            "id": "48186d85-a848-4a59-8016-a35c56ab6b5b"
        },
        {
            "name": "RSS Feed Read",
            "type": "n8n-nodes-base.rssFeedRead",
            "position": [
                870,
                330
            ],
            "parameters": {
                "url": "={{$json[\"url\"]}}"
            },
            "typeVersion": 1,
            "id": "f418e0de-370f-430e-b540-945ce37e04aa"
        },
        {
            "name": "SplitInBatches",
            "type": "n8n-nodes-base.splitInBatches",
            "position": [
                670,
                330
            ],
            "parameters": {
                "options": [],
                "batchSize": 1
            },
            "typeVersion": 1,
            "id": "7c302527-509a-4af6-8ec6-7630e73ba6ff"
        },
        {
            "name": "IF",
            "type": "n8n-nodes-base.if",
            "position": [
                1070,
                520
            ],
            "parameters": {
                "conditions": {
                    "boolean": [
                        {
                            "value1": true,
                            "value2": "={{$node[\"SplitInBatches\"].context[\"noItemsLeft\"]}}"
                        }
                    ]
                }
            },
            "typeVersion": 1,
            "id": "9f359272-d146-4eec-b67d-acbc63121d1c"
        }
    ],
    "connections": {
        "IF": {
            "main": [
                [
                    {
                        "node": "Merge Data",
                        "type": "main",
                        "index": 0
                    }
                ],
                [
                    {
                        "node": "SplitInBatches",
                        "type": "main",
                        "index": 0
                    }
                ]
            ]
        },
        "Function": {
            "main": [
                [
                    {
                        "node": "SplitInBatches",
                        "type": "main",
                        "index": 0
                    }
                ]
            ]
        },
        "RSS Feed Read": {
            "main": [
                [
                    {
                        "node": "IF",
                        "type": "main",
                        "index": 0
                    }
                ]
            ]
        },
        "SplitInBatches": {
            "main": [
                [
                    {
                        "node": "RSS Feed Read",
                        "type": "main",
                        "index": 0
                    }
                ]
            ]
        },
        "On clicking 'execute'": {
            "main": [
                [
                    {
                        "node": "Function",
                        "type": "main",
                        "index": 0
                    }
                ]
            ]
        }
    },
    "n8n_version": "1.5.0"
}
Requirements
n8n instance, API credentials for connected services
Tags
#n8n #automation #workflow
Quick Actions
More in n8n Workflows