This workflow follows the Gmail → Gmail Trigger 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": "InquiryPilot - Gmail to Sheets and Draft",
"nodes": [
{
"parameters": {
"pollTimes": {
"item": [
{
"mode": "everyMinute"
}
]
},
"filters": {
"labelIds": [
"INBOX"
]
}
},
"id": "gmail-trigger",
"name": "Gmail Trigger",
"type": "n8n-nodes-base.gmailTrigger",
"typeVersion": 1.2,
"position": [
0,
0
],
"credentials": {
"gmailOAuth2": {
"name": "<your credential>"
}
}
},
{
"parameters": {
"method": "POST",
"url": "http://host.docker.internal:8000/api/automation/inquiries",
"sendHeaders": true,
"headerParameters": {
"parameters": [
{
"name": "X-Automation-Key",
"value": "change-this-before-deployment"
}
]
},
"sendBody": true,
"specifyBody": "json",
"jsonBody": "={\"external_id\": $json.id, \"source\": \"gmail\", \"text\": ($json.textPlain || $json.snippet || $json.subject)}",
"options": {
"response": {
"response": {
"neverError": true
}
}
}
},
"id": "analyze",
"name": "Analyze with InquiryPilot",
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4.2,
"position": [
260,
0
]
},
{
"parameters": {
"operation": "append",
"documentId": {
"__rl": true,
"value": "CONNECT_SPREADSHEET",
"mode": "id"
},
"sheetName": {
"__rl": true,
"value": "Leads",
"mode": "name"
},
"columns": {
"mappingMode": "defineBelow",
"value": {
"Name": "={{$json.inquiry.contact_name}}",
"Company": "={{$json.inquiry.company}}",
"Email": "={{$json.inquiry.email}}",
"Intent": "={{$json.inquiry.intent}}",
"Priority": "={{$json.inquiry.priority}}",
"Score": "={{$json.inquiry.lead_score}}",
"Status": "={{$json.inquiry.status}}"
}
},
"options": {}
},
"id": "sheets",
"name": "Append Lead to Google Sheets",
"type": "n8n-nodes-base.googleSheets",
"typeVersion": 4.5,
"position": [
520,
-80
],
"credentials": {
"googleSheetsOAuth2Api": {
"name": "<your credential>"
}
}
},
{
"parameters": {
"resource": "draft",
"subject": "={{'Re: ' + ($node['Gmail Trigger'].json.subject || 'Your inquiry')}}",
"message": "={{$node['Analyze with InquiryPilot'].json.inquiry.reply_draft}}",
"options": {
"sendTo": "={{$node['Analyze with InquiryPilot'].json.inquiry.email}}"
}
},
"id": "draft",
"name": "Create Gmail Draft",
"type": "n8n-nodes-base.gmail",
"typeVersion": 2.1,
"position": [
520,
100
],
"credentials": {
"gmailOAuth2": {
"name": "<your credential>"
}
}
}
],
"connections": {
"Gmail Trigger": {
"main": [
[
{
"node": "Analyze with InquiryPilot",
"type": "main",
"index": 0
}
]
]
},
"Analyze with InquiryPilot": {
"main": [
[
{
"node": "Append Lead to Google Sheets",
"type": "main",
"index": 0
},
{
"node": "Create Gmail Draft",
"type": "main",
"index": 0
}
]
]
}
},
"settings": {
"executionOrder": "v1"
},
"active": false,
"versionId": "00000000-0000-4000-8000-000000000001"
}
Credentials you'll need
Each integration node will prompt for credentials when you import. We strip credential IDs before publishing — you'll add your own.
gmailOAuth2googleSheetsOAuth2Api
For the full experience including quality scoring and batch install features for each workflow upgrade to Pro
About this workflow
InquiryPilot - Gmail to Sheets and Draft. Uses gmailTrigger, httpRequest, googleSheets, gmail. Event-driven trigger; 4 nodes.
Source: https://github.com/nanhe-ai/AI-Freelance-30Day/blob/main/n8n/workflows/inquiry-pilot.json — 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.
This workflow ingests proof-of-delivery and completion documents from Gmail or a webhook, extracts key fields with an OpenRouter vision model, reconciles them against Google Sheets dispatch data, arch
AICARE Email Blast System. Uses googleDrive, httpRequest, googleSheets, gmail. Event-driven trigger; 39 nodes.
An automated n8n workflow that monitors your Gmail inbox, classifies job application emails using a local AI (Ollama), and logs every application — with company, role, and status — to a Google Sheet i
Automatically transform resume submissions into comprehensive candidate profiles with AI-powered parsing, GitHub analysis, and instant team notifications. Monitors Gmail for incoming resume attachment
EnquiryFlow. Uses gmailTrigger, httpRequest, googleSheets, gmail. Event-driven trigger; 12 nodes.