This workflow follows the Execute Workflow Trigger → HTTP Request recipe pattern — see all workflows that pair these two integrations.
The workflow JSON
Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →
{
"name": "Delivery :: NewCust :: AddContacts",
"nodes": [
{
"parameters": {
"inputSource": "passthrough"
},
"type": "n8n-nodes-base.executeWorkflowTrigger",
"typeVersion": 1.1,
"position": [
-800,
-128
],
"id": "ae7fd953-4ed4-4f89-8d97-445729036ab8",
"name": "When Executed by Another Workflow"
},
{
"parameters": {
"assignments": {
"assignments": [
{
"id": "30d455b7-a49d-4c97-bd98-ff057159558b",
"name": "customer_name",
"value": "={{ $json.subject.split(':')[2].trim() }}",
"type": "string"
},
{
"id": "3e8a7f07-e611-4305-a2bb-ce3ca9d4f6cf",
"name": "customer_phone",
"value": "={{ $json.subject.split(':')[1].trim() }}",
"type": "string"
},
{
"id": "b1ff4785-d09b-4fe6-b9cd-0d65bd3175a5",
"name": "customer_id",
"value": "={{ $json.subject.split(':')[0].trim() }}",
"type": "string"
}
]
},
"options": {}
},
"type": "n8n-nodes-base.set",
"typeVersion": 3.4,
"position": [
-592,
-128
],
"id": "3eda8aab-4929-4685-abee-98b38a812e14",
"name": "Edit Fields"
},
{
"parameters": {
"content": "## Updated\n**Google Contacts now uses HTTP Request + env var refresh token**\n**No more OAuth expiry issues**\n",
"height": 320
},
"type": "n8n-nodes-base.stickyNote",
"position": [
-736,
-400
],
"typeVersion": 1,
"id": "073cbb07-af05-4a43-9f4b-4ae8e7dfe371",
"name": "Sticky Note"
},
{
"parameters": {
"method": "POST",
"url": "=https://live-mt-server.wati.io/5171/api/v1/addContact/91{{ $json.customer_phone.trim() }}",
"sendQuery": true,
"queryParameters": {
"parameters": [
{
"name": "sourceType",
"value": "Wati"
}
]
},
"sendHeaders": true,
"headerParameters": {
"parameters": [
{
"name": "accept",
"value": "*/*"
},
{
"name": "Authorization",
"value": "<redacted-credential>"
},
{
"name": "Content-Type",
"value": "application/json-patch+json"
}
]
},
"sendBody": true,
"specifyBody": "json",
"jsonBody": "={\n \"name\": \"{{ $json.customer_id.trim() }} {{ $json.customer_name.trim() }} \",\n \"customParams\": [\n {\n \"name\": \"customer_id\",\n \"value\": \"{{ $json.customer_id.trim() }}\"\n },\n {\n \"name\": \"customer_name\",\n \"value\": \"{{ $json.customer_name.trim() }}\"\n }\n\n ]\n}",
"options": {}
},
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4.2,
"position": [
-384,
-128
],
"id": "132a27ce-f91e-42c3-ab70-d4d2b253675c",
"name": "WATI Contacts",
"retryOnFail": false
},
{
"parameters": {
"jsCode": "const response = await fetch('https://oauth2.googleapis.com/token', {\n method: 'POST',\n headers: { 'Content-Type': 'application/x-www-form-urlencoded' },\n body: new URLSearchParams({\n client_id: $env.GOOGLE_CLIENT_ID,\n client_secret: $env.GOOGLE_CLIENT_SECRET,\n refresh_token: $env.GOOGLE_CONTACTS_REFRESH_TOKEN,\n grant_type: 'refresh_token'\n })\n});\n\nconst data = await response.json();\n\nreturn [{\n json: {\n ...$input.first().json,\n access_token: data.access_token\n }\n}];"
},
"type": "n8n-nodes-base.code",
"typeVersion": 2,
"position": [
-160,
-256
],
"id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"name": "Get Google Token"
},
{
"parameters": {
"method": "POST",
"url": "https://people.googleapis.com/v1/people:createContact",
"sendHeaders": true,
"headerParameters": {
"parameters": [
{
"name": "Authorization",
"value": "=Bearer {{ $json.access_token }}"
},
{
"name": "Content-Type",
"value": "application/json"
}
]
},
"sendBody": true,
"specifyBody": "json",
"jsonBody": "={\n \"names\": [{\n \"givenName\": \"{{ $('Edit Fields').item.json.customer_id }}\",\n \"familyName\": \"{{ $('Edit Fields').item.json.customer_name }}\"\n }],\n \"phoneNumbers\": [{\n \"value\": \"91{{ $('Edit Fields').item.json.customer_phone.trim() }}\",\n \"type\": \"mobile\"\n }],\n \"emailAddresses\": [{\n \"value\": \"aruvadaiorganic@gmail.com\",\n \"type\": \"home\"\n }]\n}",
"options": {}
},
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4.2,
"position": [
80,
-256
],
"id": "b2c3d4e5-f6a7-8901-bcde-f12345678901",
"name": "Create Google Contact",
"retryOnFail": false,
"onError": "continueErrorOutput"
},
{
"parameters": {
"amount": 1,
"unit": "days"
},
"type": "n8n-nodes-base.wait",
"typeVersion": 1.1,
"position": [
320,
-320
],
"id": "86dd719c-abf8-4495-b8d4-888a1e5ae8b1",
"name": "Wait"
},
{
"parameters": {
"jsCode": "const response = await fetch('https://oauth2.googleapis.com/token', {\n method: 'POST',\n headers: { 'Content-Type': 'application/x-www-form-urlencoded' },\n body: new URLSearchParams({\n client_id: $env.GOOGLE_CLIENT_ID,\n client_secret: $env.GOOGLE_CLIENT_SECRET,\n refresh_token: $env.GOOGLE_CONTACTS_REFRESH_TOKEN,\n grant_type: 'refresh_token'\n })\n});\n\nconst data = await response.json();\n\nreturn [{\n json: {\n ...$input.first().json,\n access_token: data.access_token\n }\n}];"
},
"type": "n8n-nodes-base.code",
"typeVersion": 2,
"position": [
560,
-336
],
"id": "c3d4e5f6-a7b8-9012-cdef-123456789012",
"name": "Get Google Token1"
},
{
"parameters": {
"method": "POST",
"url": "https://people.googleapis.com/v1/people:createContact",
"sendHeaders": true,
"headerParameters": {
"parameters": [
{
"name": "Authorization",
"value": "=Bearer {{ $json.access_token }}"
},
{
"name": "Content-Type",
"value": "application/json"
}
]
},
"sendBody": true,
"specifyBody": "json",
"jsonBody": "={\n \"names\": [{\n \"givenName\": \"{{ $('Edit Fields').item.json.customer_id }}\",\n \"familyName\": \"{{ $('Edit Fields').item.json.customer_name }}\"\n }],\n \"phoneNumbers\": [{\n \"value\": \"91{{ $('Edit Fields').item.json.customer_phone.trim() }}\",\n \"type\": \"mobile\"\n }],\n \"emailAddresses\": [{\n \"value\": \"aruvadaiorganic@gmail.com\",\n \"type\": \"home\"\n }]\n}",
"options": {}
},
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4.2,
"position": [
800,
-336
],
"id": "d4e5f6a7-b8c9-0123-defa-234567890123",
"name": "Create Google Contact1"
},
{
"parameters": {
"method": "POST",
"url": "https://whatsapp-api.aruvadaiorganic.com/api/v1/send",
"sendHeaders": true,
"headerParameters": {
"parameters": [
{
"name": "Authorization",
"value": "<redacted-credential>"
},
{
"name": "Content-Type",
"value": "application/json"
}
]
},
"sendBody": true,
"bodyParameters": {
"parameters": [
{
"name": "to",
"value": "120363404238669120@g.us"
},
{
"name": "message",
"value": "N8N Google Contacts Error"
}
]
},
"options": {}
},
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4.2,
"position": [
80,
-128
],
"id": "82e6c11c-77b8-42b5-b1b7-c49cdaff1833",
"name": "SEND TO IMPORTANT ALERT"
}
],
"connections": {
"When Executed by Another Workflow": {
"main": [
[
{
"node": "Edit Fields",
"type": "main",
"index": 0
}
]
]
},
"Edit Fields": {
"main": [
[
{
"node": "WATI Contacts",
"type": "main",
"index": 0
}
]
]
},
"WATI Contacts": {
"main": [
[
{
"node": "Get Google Token",
"type": "main",
"index": 0
}
]
]
},
"Get Google Token": {
"main": [
[
{
"node": "Create Google Contact",
"type": "main",
"index": 0
}
]
]
},
"Create Google Contact": {
"main": [
[
{
"node": "Wait",
"type": "main",
"index": 0
}
],
[
{
"node": "SEND TO IMPORTANT ALERT",
"type": "main",
"index": 0
}
]
]
},
"Wait": {
"main": [
[
{
"node": "Get Google Token1",
"type": "main",
"index": 0
}
]
]
},
"Get Google Token1": {
"main": [
[
{
"node": "Create Google Contact1",
"type": "main",
"index": 0
}
]
]
}
},
"active": true,
"settings": {
"executionOrder": "v1",
"binaryMode": "separate",
"callerPolicy": "workflowsFromSameOwner",
"errorWorkflow": "ddO7dDvDhlbewEs1",
"saveDataSuccessExecution": "all"
},
"versionId": "f9cbf844-c561-46a7-8531-f5c07ea79bdf",
"meta": {
"templateCredsSetupCompleted": true
},
"id": "cPALVyXxZde8E7yS",
"tags": []
}
For the full experience including quality scoring and batch install features for each workflow upgrade to Pro
About this workflow
Delivery :: NewCust :: AddContacts. Uses executeWorkflowTrigger, httpRequest. Event-driven trigger; 10 nodes.
Source: https://gist.github.com/sathisra/306c0bbc8de7b362f1c4381d551db8e1 — original creator credit. Request a take-down →
Related workflows
Workflows that share integrations, category, or trigger type with this one. All free to copy and import.
02_LLM_Pipeline v1.0. Uses executeWorkflowTrigger, httpRequest, seaTable. Event-driven trigger; 65 nodes.
This template is a powerful, reusable utility for managing stateful, long-running processes. It allows a main workflow to be paused indefinitely at "checkpoints" and then be resumed by external, async
Upload files from any source to your account Kommo or AmoCRM with a simple and reusable workflow. It can split a large file into small ones and upload chunks. Works for Kommo and amoCRM There are 3 re
Remixed Backup your workflows to GitHub from Solomon's work. Check out his templates.
Remixed Backup your workflows to GitHub from Solomon's work. Check out his templates.