Hi all,
I just want to know how I can connect to ChatGPT through Abacus Ai instead of using the Open Ai node in n8n. I know that I will use an HTTP Request node, but would my ChatGPT API Key be the same as the Abacus ChatGPT API Key? When I have tried this, it doesn’t work, perhaps I’m not filling out the HTTP Request fields properly, this is what I need advice with, please.
This is the workflow, and I only have a FREE ChatGPT account, but I do have an Abacus Ai account that also gives me access to ChatGPT plus other LLM's.
{
"nodes": [
{
"parameters": {
"rule": {
"interval": [
{}
]
}
},
"type": "n8n-nodes-base.scheduleTrigger",
"typeVersion": 1.2,
"position": [
-1720,
-60
],
"id": "07f202c7-7f4a-41cc-8698-2f8e8f8f1141",
"name": "Schedule Trigger"
},
{
"parameters": {
"promptType": "define",
"text": "={{ $json.idea }}",
"hasOutputParser": true,
"messages": {
"messageValues": [
{
"
}
]
},
"batching": {}
},
"type": "@n8n/n8n-nodes-langchain.chainLlm",
"typeVersion": 1.7,
"position": [
-1280,
-60
],
"id": "79dd1f62-ce58-4885-a5f8-6e6da0e6e67a",
"name": "Basic LLM Chain"
},
{
"parameters": {
"model": {
"__rl": true,
"mode": "list",
"value": "gpt-4.1-mini"
},
"options": {}
},
"type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
"typeVersion": 1.2,
"position": [
-1360,
140
],
"id": "13462b72-9d75-4bde-ae0c-33d2fd71a99b",
"name": "OpenAI Chat Model",
"credentials": {
"openAiApi": {
"id": "UjL5iTyh6C8Uy8ow",
"name": "n8n free OpenAI API credits"
}
}
},
{
"parameters": {
"options": {
"numberOfItems": 2
}
},
"type": "@n8n/n8n-nodes-langchain.outputParserItemList",
"typeVersion": 1,
"position": [
-1160,
160
],
"id": "ae0f6479-0ee1-4ba1-b258-674c7c16d8a4",
"name": "Item List Output Parser"
},
{
"parameters": {
"content": "## Prompt Idea Generator",
"height": 460,
"width": 840
},
"type": "n8n-nodes-base.stickyNote",
"typeVersion": 1,
"position": [
-1760,
-160
],
"id": "c2d7a1b6-de21-4fac-a4b1-888762165ce8",
"name": "Sticky Note"
},
{
"parameters": {
"documentId": {
"__rl": true,
"value": "1AdmTJARRGArG1SGAZcMtz_nFAr_Hd72L6zOKgbSVOas",
"mode": "list",
"cachedResultName": "My Copy of the - VIRAL REEL GENERATOR",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1AdmTJARRGArG1SGAZcMtz_nFAr_Hd72L6zOKgbSVOas/edit?usp=drivesdk"
},
"sheetName": {
"__rl": true,
"value": "gid=0",
"mode": "list",
"cachedResultName": "Sheet1",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1AdmTJARRGArG1SGAZcMtz_nFAr_Hd72L6zOKgbSVOas/edit#gid=0"
},
"filtersUI": {
"values": [
{
"lookupColumn": "production",
"lookupValue": "for production"
}
]
},
"options": {
"returnFirstMatch": true
}
},
"type": "n8n-nodes-base.googleSheets",
"typeVersion": 4.6,
"position": [
-1500,
-60
],
"id": "3ae09291-f79d-4847-9377-fb971a47bc1e",
"name": "Google Sheets",
"credentials": {
"googleSheetsOAuth2Api": {
"id": "WEtp91V1TeQK5i4I",
"name": "Google Sheets account"
}
}
},
{
"parameters": {
"modelId": {
"__rl": true,
"value": "gpt-4o-mini",
"mode": "list",
"cachedResultName": "GPT-4O-MINI"
},
"messages": {
"values": [
{
"."
}
]
},
"options": {}
},
"type": "@n8n/n8n-nodes-langchain.openAi",
"typeVersion": 1.8,
"position": [
-700,
-260
],
"id": "9bc1ee7a-2dc9-48b4-8f29-8840941f3838",
"name": "Message a model",
"credentials": {
"openAiApi": {
"id": "UjL5iTyh6C8Uy8ow",
"name": "n8n free OpenAI API credits"
}
}
},
{
"parameters": {
"content": "## Prompt Generator",
"height": 280,
"width": 400
},
"type": "n8n-nodes-base.stickyNote",
"typeVersion": 1,
"position": [
-780,
-360
],
"id": "4450a39a-1540-4a21-b994-38b1367aee0a",
"name": "Sticky Note1"
},
{
"parameters": {
"content": "## Image Generator",
"height": 280,
"width": 620
},
"type": "n8n-nodes-base.stickyNote",
"typeVersion": 1,
"position": [
-340,
-360
],
"id": "5c8b7fc4-6a2c-4535-9b84-b73e5b32eae3",
"name": "Sticky Note2"
},
{
"parameters": {
"content": "## Merge & Deliver Final Video",
"height": 320,
"width": 880
},
"type": "n8n-nodes-base.stickyNote",
"typeVersion": 1,
"position": [
-840,
-20
],
"id": "a2f36f68-59ed-41dd-bb3d-6e9eb39c12d2",
"name": "Sticky Note4"
},
{
"parameters": {
"method": "POST",
"url": "https://api.piapi.ai/api/v1/task",
"sendHeaders": true,
"headerParameters": {
"parameters": [
{
"name": "X-API-Key",
"value": "e1f903c86bda6f0fedcefa9c63a245723b9814b448d35ca174c755cae3df633a"
}
]
},
"sendBody": true,
"contentType": "raw",
"rawContentType": "application/json",
"body": "={ \"model\": \"Qubico/flux1-dev\", \"task_type\": \"txt2img\", \"input\": { \"prompt\": \"{{ $json.message.content }}\", \"width\": 540, \"height\": 960 } }",
"options": {}
},
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4.2,
"position": [
-260,
-260
],
"id": "4e622a83-277d-4906-a506-dca11d412192",
"name": "HTTP Request"
},
{
"parameters": {
"amount": 2
},
"type": "n8n-nodes-base.wait",
"typeVersion": 1.1,
"position": [
-80,
-260
],
"id": "b6783ff0-5907-4112-bc8f-f8f0cee7bde1",
"name": "Wait",
"webhookId": "5f2008b3-849d-4a5c-bdbd-89ed50892e29"
},
{
"parameters": {
"url": "=https://api.piapi.ai/api/v1/task/{{ $json.data.task_id }}",
"sendHeaders": true,
"headerParameters": {
"parameters": [
{
"name": "X-API-Key",
"value": "e1f903c86bda6f0fedcefa9c63a245723b9814b448d35ca174c755cae3df633a"
}
]
},
"options": {}
},
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4.2,
"position": [
80,
-260
],
"id": "f6ea2168-7a33-4efc-96aa-938ba755e168",
"name": "HTTP Request1"
},
{
"parameters": {
"method": "POST",
"url": "=https://api.piapi.ai/api/v1/task",
"sendHeaders": true,
"headerParameters": {
"parameters": [
{
"name": "X-API-Key",
"value": "e1f903c86bda6f0fedcefa9c63a245723b9814b448d35ca174c755cae3df633a"
}
]
},
"sendBody": true,
"contentType": "raw",
"rawContentType": "application/json",
"body": "={\n \"model\": \"kling\",\n \"mode\": \"std\",\n \"task_type\": \"video_generation\",\n \"input\": {\n \"prompt\": \"{{ $json.data.input.prompt }}\",\n \"negative_prompt\": \"bad quality\",\n \"cfg_scale\": 0.65,\n \"duration\": 5,\n \"image_url\": \"{{ $json.data.output.image_url }}\",\n \"camera_control\": {\n \"type\": \"simple\",\n \"config\": {\n \"horizontal\": 0,\n \"vertical\": 0,\n \"pan\": 0,\n \"tilt\": 0,\n \"roll\": 0,\n \"zoom\": 0\n }\n }\n },\n \"config\": {}\n}",
"options": {}
},
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4.2,
"position": [
380,
-260
],
"id": "99c7cf53-3f1c-403e-883e-b0c19572646c",
"name": "HTTP Request2"
},
{
"parameters": {
"amount": 3
},
"type": "n8n-nodes-base.wait",
"typeVersion": 1.1,
"position": [
560,
-260
],
"id": "489b30ed-2566-4e76-97e0-0acdf2e3d15a",
"name": "Wait1",
"webhookId": "7bd7f28b-f088-44f7-949f-12cc005d3514"
},
{
"parameters": {
"url": "=https://api.piapi.ai/api/v1/task/{{ $json.data.task_id }}",
"sendHeaders": true,
"headerParameters": {
"parameters": [
{
"name": "X-API-Key",
"value": "e1f903c86bda6f0fedcefa9c63a245723b9814b448d35ca174c755cae3df633a"
}
]
},
"options": {}
},
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4.2,
"position": [
740,
-260
],
"id": "e8a8c72f-38d7-4ee2-bfd6-b537d32bcb20",
"name": "HTTP Request3"
},
{
"parameters": {
"content": "## Auto Publish",
"height": 320,
"width": 940
},
"type": "n8n-nodes-base.stickyNote",
"typeVersion": 1,
"position": [
200,
-20
],
"id": "887fb9c2-f94f-4977-ad81-3e1a7565f632",
"name": "Sticky Note5"
},
{
"parameters": {
"method": "POST",
"url": "https://api.elevenlabs.io/v1/sound-generation",
"sendHeaders": true,
"headerParameters": {
"parameters": [
{
"name": "xi-api-key",
"value": "=sk_530ef84cc135589ecaf7d0cc54c780bde7171923147c090d"
}
]
},
"sendBody": true,
"contentType": "raw",
"rawContentType": "=application/json",
"body": "={\n \"text\": \"no voice, ambient music for this person {{ $('Google Sheets').item.json.idea }}\",\n \"duration_seconds\": 5,\n \"prompt_influence\": 0.75\n}",
"options": {}
},
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4.2,
"position": [
1020,
-260
],
"id": "ba33832d-0cbe-4d1b-9731-c7652e4284e1",
"name": "HTTP Request4"
},
{
"parameters": {
"name": "={{ $json.data.task_id }}.mp3",
"driveId": {
"__rl": true,
"mode": "list",
"value": "My Drive"
},
"folderId": {
"__rl": true,
"value": "1IdCGjYjXfaj-kvLxISPJbpTfiNM8Vau9",
"mode": "list",
"cachedResultName": "n8n",
"cachedResultUrl": "https://drive.google.com/drive/folders/1IdCGjYjXfaj-kvLxISPJbpTfiNM8Vau9"
},
"options": {}
},
"type": "n8n-nodes-base.googleDrive",
"typeVersion": 3,
"position": [
1260,
-260
],
"id": "7fe082f8-4852-4b61-a9f9-0cdcf117846a",
"name": "Upload file",
"credentials": {
"googleDriveOAuth2Api": {
"id": "Zrvu1FqW4VtdPSJQ",
"name": "Google Drive account 2"
}
}
},
{
"parameters": {
"operation": "share",
"fileId": {
"__rl": true,
"value": "={{ $json.id }}",
"mode": "id"
},
"permissionsUi": {
"permissionsValues": {
"role": "writer",
"type": "anyone",
"allowFileDiscovery": true
}
},
"options": {}
},
"type": "n8n-nodes-base.googleDrive",
"typeVersion": 3,
"position": [
1460,
-260
],
"id": "eaea12a7-dadb-481a-935c-3e6b0150a32c",
"name": "Share file",
"credentials": {
"googleDriveOAuth2Api": {
"id": "Zrvu1FqW4VtdPSJQ",
"name": "Google Drive account 2"
}
}
},
{
"parameters": {
"content": "## Video Generator",
"height": 280,
"width": 620
},
"type": "n8n-nodes-base.stickyNote",
"typeVersion": 1,
"position": [
320,
-360
],
"id": "44d433ad-d8e4-4104-a93b-5b48cf902573",
"name": "Sticky Note6"
},
{
"parameters": {
"mode": "combine",
"combineBy": "combineByPosition",
"numberInputs": 4,
"options": {}
},
"type": "n8n-nodes-base.merge",
"typeVersion": 3.2,
"position": [
-760,
80
],
"id": "36a5c7d1-537b-48f1-b699-2dad16fcdf5a",
"name": "Merge"
},
{
"parameters": {
"jsCode": "return [\n {\n scene_titles: items.map(item => item.json.response?.text ?? null),\n video_urls: items.map(item => item.json.data?.output?.video_url ?? null),\n sound_urls: items.map(item => item.json.webContentLink ?? null)\n }\n];"
},
"type": "n8n-nodes-base.code",
"typeVersion": 2,
"position": [
-580,
100
],
"id": "4b2eec06-d179-4bfe-b032-055b5de16936",
"name": "Code"
},
{
"parameters": {
"method": "POST",
"url": "https://api.creatomate.com/v1/renders",
"sendHeaders": true,
"headerParameters": {
"parameters": [
{
"name": "Authorization",
"value": "Bearer 12dc0ad30b30407caf38859f64b3f0c917f0b775b184c81723b1686148bc159d4e4a6ff15ae4ad982f0ff9fad5c860c2"
},
{
"name": "Content-Type",
"value": "application/json"
}
]
},
"sendBody": true,
"contentType": "raw",
"rawContentType": "application/json",
"body": "={\n \"template_id\": \"5df9616e-5054-410a-b080-b4b63c295d6a\",\n \"modifications\": {\n \"Audio-1.source\": \"{{ $json.sound_urls[0] }}\",\n \"Audio-2.source\": \"{{ $json.sound_urls[1] }}\",\n \"Audio-3.source\": \"{{ $json.sound_urls[2] }}\",\n \"Audio-4.source\": \"{{ $json.sound_urls[3] }}\",\n \"Audio-5.source\": \"{{ $json.sound_urls[4] }}\",\n \n \"Video-1.source\": \"{{ $json.video_urls[0] }}\",\n \"Video-2.source\": \"{{ $json.video_urls[1] }}\",\n \"Video-3.source\": \"{{ $json.video_urls[2] }}\",\n \"Video-4.source\": \"{{ $json.video_urls[3] }}\",\n \"Video-5.source\": \"{{ $json.video_urls[4] }}\",\n \n \"Text-1.text\": \"{{ $('Google Sheets').first().json.idea }}\",\n \"Text-2.text\": \"{{ $json.scene_titles[1] }}\",\n \"Text-3.text\": \"{{ $json.scene_titles[2] }}\",\n \"Text-4.text\": \"{{ $json.scene_titles[3] }}\",\n \"Text-5.text\": \"{{ $json.scene_titles[4] }}\"\n }\n}",
"options": {}
},
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4.2,
"position": [
-400,
100
],
"id": "1639c743-9441-4090-be42-f44747944dd9",
"name": "Render Video",
"executeOnce": true
},
{
"parameters": {
"operation": "update",
"documentId": {
"__rl": true,
"value": "1AdmTJARRGArG1SGAZcMtz_nFAr_Hd72L6zOKgbSVOas",
"mode": "list",
"cachedResultName": "My Copy of the - VIRAL REEL GENERATOR",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1AdmTJARRGArG1SGAZcMtz_nFAr_Hd72L6zOKgbSVOas/edit?usp=drivesdk"
},
"sheetName": {
"__rl": true,
"value": "gid=0",
"mode": "list",
"cachedResultName": "Sheet1",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1AdmTJARRGArG1SGAZcMtz_nFAr_Hd72L6zOKgbSVOas/edit#gid=0"
},
"columns": {
"mappingMode": "defineBelow",
"value": {
"id": "={{ $('Google Sheets').first().json.id }}",
"production": "done",
"publishing": "for publishing",
"final_output": "={{ $json.url }}"
},
"matchingColumns": [
"id"
],
"schema": [
{
"id": "id",
"displayName": "id",
"required": false,
"defaultMatch": true,
"display": true,
"type": "string",
"canBeUsedToMatch": true,
"removed": false
},
{
"id": "idea",
"displayName": "idea",
"required": false,
"defaultMatch": false,
"display": true,
"type": "string",
"canBeUsedToMatch": true
},
{
"id": "caption",
"displayName": "caption",
"required": false,
"defaultMatch": false,
"display": true,
"type": "string",
"canBeUsedToMatch": true
},
{
"id": "production",
"displayName": "production",
"required": false,
"defaultMatch": false,
"display": true,
"type": "string",
"canBeUsedToMatch": true
},
{
"id": "environment_prompt",
"displayName": "environment_prompt",
"required": false,
"defaultMatch": false,
"display": true,
"type": "string",
"canBeUsedToMatch": true
},
{
"id": "publishing",
"displayName": "publishing",
"required": false,
"defaultMatch": false,
"display": true,
"type": "string",
"canBeUsedToMatch": true
},
{
"id": "final_output",
"displayName": "final_output",
"required": false,
"defaultMatch": false,
"display": true,
"type": "string",
"canBeUsedToMatch": true
},
{
"id": "row_number",
"displayName": "row_number",
"required": false,
"defaultMatch": false,
"display": true,
"type": "string",
"canBeUsedToMatch": true,
"readOnly": true,
"removed": true
}
],
"attemptToConvertTypes": false,
"convertFieldsToString": false
},
"options": {}
},
"type": "n8n-nodes-base.googleSheets",
"typeVersion": 4.6,
"position": [
-180,
100
],
"id": "bb79519a-c775-4e9d-8259-6bdb3a103d65",
"name": "Update row in sheet",
"credentials": {
"googleSheetsOAuth2Api": {
"id": "WEtp91V1TeQK5i4I",
"name": "Google Sheets account"
}
}
},
{
"parameters": {
"rule": {
"interval": [
{}
]
}
},
"type": "n8n-nodes-base.scheduleTrigger",
"typeVersion": 1.2,
"position": [
260,
100
],
"id": "d8bf1846-e1ae-4ec7-ad34-f76d21a9cd07",
"name": "Schedule Trigger1"
},
{
"parameters": {
"documentId": {
"__rl": true,
"value": "1AdmTJARRGArG1SGAZcMtz_nFAr_Hd72L6zOKgbSVOas",
"mode": "list",
"cachedResultName": "My Copy of the - VIRAL REEL GENERATOR",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1AdmTJARRGArG1SGAZcMtz_nFAr_Hd72L6zOKgbSVOas/edit?usp=drivesdk"
},
"sheetName": {
"__rl": true,
"value": "gid=0",
"mode": "list",
"cachedResultName": "Sheet1",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1AdmTJARRGArG1SGAZcMtz_nFAr_Hd72L6zOKgbSVOas/edit#gid=0"
},
"filtersUI": {
"values": [
{
"lookupColumn": "publishing",
"lookupValue": "for publishing"
}
]
},
"options": {
"returnFirstMatch": true
}
},
"type": "n8n-nodes-base.googleSheets",
"typeVersion": 4.6,
"position": [
480,
100
],
"id": "e3f4da37-07d4-4bd8-9e13-8021efe836eb",
"name": "Get row(s) in sheet",
"credentials": {
"googleSheetsOAuth2Api": {
"id": "WEtp91V1TeQK5i4I",
"name": "Google Sheets account"
}
}
},
{
"parameters": {
"url": "={{ $json.final_output }}",
"options": {}
},
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4.2,
"position": [
700,
100
],
"id": "fc923de8-c91c-4deb-a1ed-ac378cfd74a5",
"name": "HTTP Request5"
},
{
"parameters": {
"resource": "video",
"operation": "upload",
"title": "={{ $json.idea }}",
"regionCode": "GB",
"options": {
"description": "={{ $json.caption }}"
}
},
"type": "n8n-nodes-base.youTube",
"typeVersion": 1,
"position": [
920,
100
],
"id": "aef08ef2-ed65-4ca2-bfe3-af189832ad3a",
"name": "Upload a video"
}
],
"connections": {
"Schedule Trigger": {
"main": [
[
{
"node": "Google Sheets",
"type": "main",
"index": 0
}
]
]
},
"Basic LLM Chain": {
"main": [
[
{
"node": "Message a model",
"type": "main",
"index": 0
},
{
"node": "Merge",
"type": "main",
"index": 0
}
]
]
},
"OpenAI Chat Model": {
"ai_languageModel": [
[
{
"node": "Basic LLM Chain",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"Item List Output Parser": {
"ai_outputParser": [
[
{
"node": "Basic LLM Chain",
"type": "ai_outputParser",
"index": 0
}
]
]
},
"Google Sheets": {
"main": [
[
{
"node": "Basic LLM Chain",
"type": "main",
"index": 0
}
]
]
},
"Message a model": {
"main": [
[
{
"node": "HTTP Request",
"type": "main",
"index": 0
}
]
]
},
"HTTP Request": {
"main": [
[
{
"node": "Wait",
"type": "main",
"index": 0
}
]
]
},
"Wait": {
"main": [
[
{
"node": "HTTP Request1",
"type": "main",
"index": 0
}
]
]
},
"HTTP Request1": {
"main": [
[
{
"node": "HTTP Request2",
"type": "main",
"index": 0
}
]
]
},
"HTTP Request2": {
"main": [
[
{
"node": "Wait1",
"type": "main",
"index": 0
}
]
]
},
"Wait1": {
"main": [
[
{
"node": "HTTP Request3",
"type": "main",
"index": 0
}
]
]
},
"HTTP Request3": {
"main": [
[
{
"node": "HTTP Request4",
"type": "main",
"index": 0
},
{
"node": "Merge",
"type": "main",
"index": 1
}
]
]
},
"HTTP Request4": {
"main": [
[
{
"node": "Upload file",
"type": "main",
"index": 0
}
]
]
},
"Upload file": {
"main": [
[
{
"node": "Share file",
"type": "main",
"index": 0
},
{
"node": "Merge",
"type": "main",
"index": 2
}
]
]
},
"Share file": {
"main": [
[
{
"node": "Merge",
"type": "main",
"index": 3
}
]
]
},
"Merge": {
"main": [
[
{
"node": "Code",
"type": "main",
"index": 0
}
]
]
},
"Code": {
"main": [
[
{
"node": "Render Video",
"type": "main",
"index": 0
}
]
]
},
"Render Video": {
"main": [
[
{
"node": "Update row in sheet",
"type": "main",
"index": 0
}
]
]
},
"Schedule Trigger1": {
"main": [
[
{
"node": "Get row(s) in sheet",
"type": "main",
"index": 0
}
]
]
},
"Get row(s) in sheet": {
"main": [
[
{
"node": "HTTP Request5",
"type": "main",
"index": 0
}
]
]
},
"HTTP Request5": {
"main": [
[
{
"node": "Upload a video",
"type": "main",
"index": 0
}
]
]
}
},
"pinData": {},
"meta": {
"templateCredsSetupCompleted": true,
"instanceId": "4bec997bcf0cf339c2d302642ba335a3e450393086bab424e708dff21a1f11e9"
}
}
Share the output returned by the last node
Information on your n8n setup
- n8nVersion: 1.100.1
- platform: docker (cloud)
- nodeJsVersion: 22.16.0
- database: sqlite
- executionMode: regular
- concurrency: 5
- license: community
- consumerId: 00000000-0000-0000-0000-000000000000