Here is another sample. Again I expect HTTP Request to be executed 2 times, but it executes again and again
{
“name”: “Test”,
“nodes”: [
{
“parameters”: {
“jsCode”: “return [\n { json: {\n\t\t\t\t"text": \n\t\t\t\t"Hello, this is my first phrase!",\n\t\t\t\t"voice_id": \n\t\t\t\t"rHWSYoq8UlV0YIBKMryp"\n\t\t\t}\n }, \n { json: \t\t\t{\n\t\t\t\t"text": \n\t\t\t\t"And this is what another character replies",\n\t\t\t\t"voice_id": \n\t\t\t\t"rHWSYoq8UlV0YIBKMryp"\n\t\t\t}\n }\n];”
},
“type”: “n8n-nodes-base.code”,
“typeVersion”: 2,
“position”: [
208,
0
],
“id”: “05e76a5b-50b0-4a4b-b2fa-1b808dc777d8”,
“name”: “Code in JavaScript”
},
{
“parameters”: {
“options”: {
“reset”: true
}
},
“type”: “n8n-nodes-base.splitInBatches”,
“typeVersion”: 3,
“position”: [
416,
0
],
“id”: “4a80600a-686a-470e-b6c0-92043da35493”,
“name”: “Loop Over Items”
},
{
“parameters”: {},
“type”: “n8n-nodes-base.manualTrigger”,
“typeVersion”: 1,
“position”: [
0,
0
],
“id”: “665f2ca8-4d96-4cfa-a65e-2e53f97799e0”,
“name”: “When clicking ‘Execute workflow’”
},
{
“parameters”: {
“method”: “POST”,
“url”: “``https://api.restful-api.dev/objects”``,
“sendBody”: true,
“specifyBody”: “json”,
“jsonBody”: “{\n "name": "Apple MacBook Pro 16",\n "data": {\n "year": 2019,\n "price": 1849.99,\n "CPU model": "Intel Core i9",\n "Hard disk size": "1 TB"\n }\n}”,
“options”: {}
},
“type”: “n8n-nodes-base.httpRequest”,
“typeVersion”: 4.3,
“position”: [
624,
96
],
“id”: “1a20de70-2237-4fd5-ab36-bdc5d1ef4cec”,
“name”: “HTTP Request”
},
{
“parameters”: {
“jsCode”: “console.log($input.first().json.id)\n\nreturn {json: {}};”
},
“type”: “n8n-nodes-base.code”,
“typeVersion”: 2,
“position”: [
832,
96
],
“id”: “5fd47859-7359-4bf2-9169-cc6369ddd4d1”,
“name”: “Code in JavaScript1”
},
{
“parameters”: {
“amount”: 1
},
“type”: “n8n-nodes-base.wait”,
“typeVersion”: 1.1,
“position”: [
1040,
96
],
“id”: “c682217b-3602-456b-80db-4bd5f94c5e0e”,
“name”: “Wait”,
“webhookId”: “d3151442-4846-42ce-be62-f3156733f372”
}
],
“pinData”: {},
“connections”: {
“Code in JavaScript”: {
“main”: [
[
{
“node”: “Loop Over Items”,
“type”: “main”,
“index”: 0
}
]
]
},
“Loop Over Items”: {
“main”: [
,
[
{
“node”: “HTTP Request”,
“type”: “main”,
“index”: 0
}
]
]
},
“When clicking ‘Execute workflow’”: {
“main”: [
[
{
“node”: “Code in JavaScript”,
“type”: “main”,
“index”: 0
}
]
]
},
“HTTP Request”: {
“main”: [
[
{
“node”: “Code in JavaScript1”,
“type”: “main”,
“index”: 0
}
]
]
},
“Code in JavaScript1”: {
“main”: [
[
{
“node”: “Wait”,
“type”: “main”,
“index”: 0
}
]
]
},
“Wait”: {
“main”: [
[
{
“node”: “Loop Over Items”,
“type”: “main”,
“index”: 0
}
]
]
}
},
“active”: false,
“settings”: {
“executionOrder”: “v1”
},
“versionId”: “36ecdff6-3419-43b6-bc3b-e9aaa20a53d5”,
“meta”: {
“templateCredsSetupCompleted”: true,
“instanceId”: “c172a29399dc1695c4e4ebd55e1ca8793799145ee04c4672fbea0a3bdc4ee854”
},
“id”: “H7l9BTWgyu36oEZm”,
“tags”:
}