This workflow corresponds to n8n.io template #5684 — we link there as the canonical source.
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 →
{
"meta": {
"templateCredsSetupCompleted": true
},
"nodes": [
{
"id": "a144a8b6-9cf7-4716-9d90-404f06d0e674",
"name": "Nachricht?",
"type": "n8n-nodes-base.if",
"position": [
-1000,
80
],
"parameters": {
"options": {},
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "e7070523-50ab-4562-835e-d29397ab9eed",
"operator": {
"name": "filter.operator.equals",
"type": "string",
"operation": "equals"
},
"leftValue": "={{ $json.body.messages[0].chat_id }}",
"rightValue": "=120363417847196227@g.us"
}
]
}
},
"typeVersion": 2.2
},
{
"id": "f18ad0b2-f720-485d-a049-f415b83ccee2",
"name": "No Operation, do nothing",
"type": "n8n-nodes-base.noOp",
"position": [
-740,
300
],
"parameters": {},
"typeVersion": 1
},
{
"id": "0bac18d6-541c-4c55-ad26-e2d282320959",
"name": "Suche nach WA_ID",
"type": "n8n-nodes-base.airtable",
"position": [
-420,
80
],
"parameters": {
"base": {
"__rl": true,
"mode": "list",
"value": "appREiqyOxTYwsigc",
"cachedResultUrl": "https://airtable.com/appREiqyOxTYwsigc",
"cachedResultName": "WhatsApp Engagement Database"
},
"table": {
"__rl": true,
"mode": "list",
"value": "tblIf7YbtyvUvDNm0",
"cachedResultUrl": "https://airtable.com/appREiqyOxTYwsigc/tblIf7YbtyvUvDNm0",
"cachedResultName": "Table 1"
},
"options": {},
"operation": "search",
"filterByFormula": "={WhatsApp_ID} = {{ $json.body.messages[0].from }}"
},
"typeVersion": 2.1,
"alwaysOutputData": true
},
{
"id": "87d77dce-17f5-4fad-b1f7-fd430ef50bf7",
"name": "+1",
"type": "n8n-nodes-base.code",
"position": [
-100,
80
],
"parameters": {
"jsCode": "var count = $input.first().json.Count; // Aktuellen Wert abrufen\ncount += 1; // Eine 1 dazuaddieren\n\nreturn { Count: count }; // Aktualisierten Wert zur\u00fcckgeben"
},
"typeVersion": 2
},
{
"id": "a755791b-8288-48e6-9175-8beaeaa9ae12",
"name": "Airtable Update",
"type": "n8n-nodes-base.airtable",
"position": [
120,
80
],
"parameters": {
"base": {
"__rl": true,
"mode": "list",
"value": "appREiqyOxTYwsigc",
"cachedResultUrl": "https://airtable.com/appREiqyOxTYwsigc",
"cachedResultName": "WhatsApp Engagement Database"
},
"table": {
"__rl": true,
"mode": "list",
"value": "tblIf7YbtyvUvDNm0",
"cachedResultUrl": "https://airtable.com/appREiqyOxTYwsigc/tblIf7YbtyvUvDNm0",
"cachedResultName": "Table 1"
},
"columns": {
"value": {
"Count": "={{ $json.Count }}",
"WhatsApp_ID": "={{ $('Webhook').item.json.body.messages[0].from }}",
"Last interaction": "={{ $now.format('yyyy.MM.dd') }}"
},
"schema": [
{
"id": "id",
"type": "string",
"display": true,
"removed": false,
"readOnly": true,
"required": false,
"displayName": "id",
"defaultMatch": true
},
{
"id": "WhatsApp_ID",
"type": "string",
"display": true,
"removed": false,
"readOnly": false,
"required": false,
"displayName": "WhatsApp_ID",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Count",
"type": "number",
"display": true,
"removed": false,
"readOnly": false,
"required": false,
"displayName": "Count",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Last interaction",
"type": "string",
"display": true,
"removed": false,
"readOnly": false,
"required": false,
"displayName": "Last interaction",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Raffle vouchers",
"type": "string",
"display": true,
"removed": false,
"readOnly": true,
"required": false,
"displayName": "Raffle vouchers",
"defaultMatch": false,
"canBeUsedToMatch": true
}
],
"mappingMode": "defineBelow",
"matchingColumns": [
"WhatsApp_ID"
],
"attemptToConvertTypes": false,
"convertFieldsToString": false
},
"options": {},
"operation": "update"
},
"typeVersion": 2.1
},
{
"id": "bdfafca3-f8c5-4aeb-b798-d436a7b0d350",
"name": "Webhook",
"type": "n8n-nodes-base.webhook",
"position": [
-1260,
80
],
"parameters": {
"path": "bf830497-e200-47da-a10e-8f710cd3c9f6",
"options": {},
"httpMethod": "POST"
},
"typeVersion": 2
},
{
"id": "fd632f42-dc44-4c83-8bf8-2d323dde3b19",
"name": "Sticky Note1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-160,
-260
],
"parameters": {
"color": 4,
"width": 460,
"height": 500,
"content": "## Existing User (+1) \nAdds a +1 to the message count"
},
"typeVersion": 1
},
{
"id": "5304cedc-9da9-42d2-924f-bece2dbb1e0c",
"name": "Sticky Note2",
"type": "n8n-nodes-base.stickyNote",
"position": [
-460,
-260
],
"parameters": {
"width": 200,
"height": 500,
"content": "## Search for user \nLook up the right Airtable record via WhatsApp ID"
},
"typeVersion": 1
},
{
"id": "7913bb25-8722-4623-9ddf-56812e32503e",
"name": "Switch",
"type": "n8n-nodes-base.switch",
"position": [
-740,
60
],
"parameters": {
"rules": {
"values": [
{
"outputKey": "Text",
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "a483b969-9bfa-440e-8ea6-5cbcb12e2efc",
"operator": {
"type": "string",
"operation": "exists",
"singleValue": true
},
"leftValue": "={{ $json.body.messages[0].text.body }}",
"rightValue": ""
}
]
},
"renameOutput": true
},
{
"outputKey": "Emoji reaction",
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "8145efda-7dd8-4a13-a86a-e7d5e9fc4c36",
"operator": {
"type": "string",
"operation": "exists",
"singleValue": true
},
"leftValue": "={{ $json.body.messages[0].action.emoji }}",
"rightValue": ""
}
]
},
"renameOutput": true
},
{
"outputKey": "voice",
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "3f583714-0223-4815-bf5b-991d7123592a",
"operator": {
"name": "filter.operator.equals",
"type": "string",
"operation": "equals"
},
"leftValue": "={{ $json.body.messages[0].type }}",
"rightValue": "voice"
}
]
},
"renameOutput": true
},
{
"outputKey": "image",
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "cfc50c8d-8ec4-4542-8538-b4d8f15227ff",
"operator": {
"name": "filter.operator.equals",
"type": "string",
"operation": "equals"
},
"leftValue": "={{ $json.body.messages[0].type }}",
"rightValue": "image"
}
]
},
"renameOutput": true
}
]
},
"options": {}
},
"typeVersion": 3.2
},
{
"id": "9af54273-d265-44e4-923d-8960a59efc14",
"name": "Sticky Note4",
"type": "n8n-nodes-base.stickyNote",
"position": [
-760,
-260
],
"parameters": {
"color": 5,
"width": 160,
"height": 500,
"content": "## Text, emoji, voice, image? \nCheck if some of these messages are the ones mentioned."
},
"typeVersion": 1
},
{
"id": "e8504f2e-e164-4045-8846-2c97525ebd73",
"name": "Sticky Note5",
"type": "n8n-nodes-base.stickyNote",
"position": [
-1020,
-260
],
"parameters": {
"color": 6,
"width": 160,
"height": 500,
"content": "## Right group? \nChecks if the message was sent in the right group."
},
"typeVersion": 1
},
{
"id": "08bcd700-ee11-48b9-844b-8b4091277184",
"name": "Sticky Note",
"type": "n8n-nodes-base.stickyNote",
"position": [
-1280,
-260
],
"parameters": {
"color": 7,
"width": 160,
"height": 500,
"content": "## Webhook from Whapi \nCatch the webhook from Whapi when the message is received"
},
"typeVersion": 1
},
{
"id": "4b7c3dbf-8000-4c4a-acbc-2195570a0c5b",
"name": "Sticky Note3",
"type": "n8n-nodes-base.stickyNote",
"position": [
-2680,
-260
],
"parameters": {
"width": 1220,
"height": 1480,
"content": "# Summary of the Workflow: WhatsApp Engagement Tracker\nYour n8n workflow is designed to track and encourage user engagement in a specific WhatsApp group\u2014ideal for SaaS apps, weekly raffles, or gamification. Here\u2019s a structured summary of each step:\n\n## 1. Webhook Reception\nNode: Webhook\n\nFunction: Receives incoming messages from Whapi (WhatsApp API) via webhook.\n\n## 2. Group Filter\nNode: IF (Nachricht?)\n\nFunction: Checks if the message is from the desired WhatsApp group (by comparing chat_id).\n\nRouting:\n\nYes: Proceeds to message type check\n\nNo: Ends workflow (No Operation)\n\n## 3. Message Type Check\nNode: Switch\n\nFunction: Determines if the message is a text, emoji reaction, voice message, or image.\n\nNote: All four types proceed to the next step.\n\n## 4. User Lookup in Airtable\nNode: Suche nach WA_ID\n\nFunction: Searches for the user in the Airtable database using the WhatsApp ID (from).\n\n## 5. Increment Counter\nNode: Code (+1)\n\nFunction: Retrieves the current engagement count (Count) for the user and increments it by 1.\n\n## 6. Airtable Update\nNode: Airtable Update\n\n## Function:\n\nUpdates the engagement counter (Count) in Airtable\n\nSets the \u201cLast interaction\u201d field to the current date\n\nUses WhatsApp ID as the key\n\n## Overall Goal\nThe workflow automatically counts every relevant user interaction (text, emoji, voice, image) in a specific WhatsApp group and stores it in an Airtable database. This allows you to measure engagement and, for example, automatically run weekly raffles or reward the most active users.\n\n## Benefits\nAutomated Tracking: No manual evaluation required\n\nFlexible Expansion: Easily adaptable for new actions, groups, or reward systems\n\nData for Gamification: Encourages engagement through transparency and rewards\n\nTip:\nYou can easily expand this workflow for new message types, additional groups, or extra actions (e.g., auto-notifications for winners).\n"
},
"typeVersion": 1
}
],
"connections": {
"+1": {
"main": [
[
{
"node": "Airtable Update",
"type": "main",
"index": 0
}
]
]
},
"Switch": {
"main": [
[
{
"node": "Suche nach WA_ID",
"type": "main",
"index": 0
}
],
[
{
"node": "Suche nach WA_ID",
"type": "main",
"index": 0
}
],
[
{
"node": "Suche nach WA_ID",
"type": "main",
"index": 0
}
],
[
{
"node": "Suche nach WA_ID",
"type": "main",
"index": 0
}
]
]
},
"Webhook": {
"main": [
[
{
"node": "Nachricht?",
"type": "main",
"index": 0
}
]
]
},
"Nachricht?": {
"main": [
[
{
"node": "Switch",
"type": "main",
"index": 0
}
],
[
{
"node": "No Operation, do nothing",
"type": "main",
"index": 0
}
]
]
},
"Suche nach WA_ID": {
"main": [
[
{
"node": "+1",
"type": "main",
"index": 0
}
]
]
}
}
}
For the full experience including quality scoring and batch install features for each workflow upgrade to Pro
About this workflow
It first filters messages to ensure they come from the correct group, then identifies the message type—text, emoji reaction, voice, or image. The workflow searches for the user in an Airtable database using their WhatsApp ID and increments their message count by one. It updates…
Source: https://n8n.io/workflows/5684/ — 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.
The workflow starts when a webhook receives a POST request from Whapi, notifying that a new participant has joined a WhatsApp group.
Telegram Comms (Polls & Messages to Group Topics). Uses httpRequest. Webhook trigger; 11 nodes.
This template is perfect for community managers, business owners, and WhatsApp group administrators who want to create a welcoming experience for new members. Whether you're running a support group, m
qualiopi. Uses airtable, telegram, emailSend, httpRequest. Webhook trigger; 51 nodes.
This workflow is built for education businesses, course creators, coaching programs, and online academies that use Close CRM for sales and need to automate everything that happens after a deal closes.