I’m trying to get this json response to be split in single items with the SplitinBatches node. But all items are somehow one item instead of 4 single items. How would I get this working?
{
"nodes": [
{
"parameters": {
"functionCode": "return [\n{\n\t\"json\": [{\n\t\t\"24\": {\n\t\t\t\"quantity\": 1,\n\t\t\t\"sku\": \"SKU1\",\n\t\t\t\"lastModified\": \"2020-10-30T00:28:14+00:00\"\n\t\t},\n\t\t\"25\": {\n\t\t\t\"quantity\": 10,\n\t\t\t\"sku\": \"SKU2\",\n\t\t\t\"lastModified\": \"2020-10-30T00:28:17+00:00\"\n\t\t},\n \t\"28\": {\n\t\t\t\"quantity\": 8,\n\t\t\t\"sku\": \"SKU24\",\n\t\t\t\"lastModified\": \"2020-10-30T00:28:17+00:00\"\n\t\t},\n \t\"29\": {\n\t\t\t\"quantity\": 4,\n\t\t\t\"sku\": \"SKU13\",\n\t\t\t\"lastModified\": \"2020-10-31T00:24:17+00:00\"\n\t\t}\n\t}]\n}\n];"
},
"name": "Function1",
"type": "n8n-nodes-base.function",
"typeVersion": 1,
"position": [
530,
300
]
},
{
"parameters": {
"batchSize": 1,
"options": {}
},
"name": "SplitInBatches1",
"type": "n8n-nodes-base.splitInBatches",
"typeVersion": 1,
"position": [
760,
300
]
}
],
"connections": {
"Function1": {
"main": [
[
{
"node": "SplitInBatches1",
"type": "main",
"index": 0
}
]
]
}
}
}