Every new Airtable lead gets a tailored reply that waits for your approval, so automation helps and nothing goes out unchecked — AI drafts, human decides.

Overview

This system turns an Airtable inbound record into a human-approved sales reply without polling or inbox chaos. When a lead is created with name, email, intent, budget, companyName, projectDescription and timeline, the workflow fires on the Created field, searches past projects via an Airtable Tool for proof, prompts a sales agent to write a concise email whose goal is a second call, normalizes the structured subject and email, and then pauses with Gmail sendAndWait for approval at [email protected]. A Gemini-powered text classifier routes the reply as Approved to send or Declined to a revision loop that rewrites with your feedback and re-enters the same gate.

It is built with n8n Airtable Trigger on Created, Airtable Tool search on app7GDA63cJW112Dz, Sales Agent and Revision Agent on OpenAI GPT-5.6 with Google Gemini for classification, Structured Output Parser for subject and email, Set for normalization, and Gmail sendAndWait plus send for the human gate. One n8n workflow handles the full flow with 14 nodes and two agent tools wired as ai_tool, ai_outputParser and ai_languageModel edges.

Tools and Integrations

Tool Role
n8n Airtable Trigger Watches tblRFFIrD7jqgLhuE on field Created with pollTimes everyMinute, base app7GDA63cJW112Dz, auth airtableTokenApi 54zRR9bQfLLcZb4y. Fires on new record without manual polling
Airtable Tool — Project Database Searches base app7GDA63cJW112Dz table tblgAhhdJHoKszeLM for projects matching scope. Wired as ai_tool to Sales Agent so the agent can pull proof before writing
Sales Agent — @n8n/n8n-nodes-langchain.agent Prompt template with Incoming Lead fields: name, email, intent, budget, companyName, projectDescription, timeline. System message: expert sales for AI agency, brief convincing email, goal is second call, must search Project Database for similar project and share outcome. Signs off as Jim, Dunder AI. Has hasOutputParser true
OpenAI Chat Model — GPT-5.6 Luna Model gpt-5.6-luna via lmChatOpenAi, credentials OpenAI J1XsY3EChVaVis9t. Wired to both Sales Agent and Revision Agent via ai_languageModel
Structured Output Parser — outputParserStructured Schema manual with required subject string and email string. Wired as ai_outputParser to Sales Agent and Revision Agent so output is parseable JSON
Gmail — Get Feedback sendAndWait + Send Email Get Feedback sends to [email protected] subject APPROVAL REQUIRED for New Lead: {{name}} with lead summary plus Subject and Email draft, then waits for freeText response. Send Email sends to lead email {{Airtable Trigger1.fields.email}} with Sales Agent subject and Set Email email, appendAttribution false
Text Classifier — Check Feedback Model gemini-3-flash-preview via Google Gemini Chat Model 2DtKBrbrlfPc9sA2. Categories Approved vs Declined with example phrases: Looks good, Go ahead versus Can we tweak, Needs some changes, Not quite right. Version 1, strict validation
Revision Agent — @n8n/n8n-nodes-langchain.agent Prompt Email: {{Set Email.email}} Feedback from human: {{ $json.data.text }}. System message: expert email writer, revise incoming email based on human feedback, sign off as Jim, Dunder AI, date {{ $now }}. Re-enters Set Email and same gate
n8n Set + Code Set Email stores $json.output.email as email. Compare with Airtable lead fields preserved via expressions

Architecture

graph LR
    A[Airtable Trigger1<br/>tblRFFIrD7jqgLhuE<br/>Created everyMinute] --> B[Sales Agent<br/>AI sales<br/>search Project DB]
    B --> C[Project Database<br/>Airtable Tool<br/>app7GDA63cJW112Dz<br/>tblgAhhdJHoKszeLM]
    C --> B
    B --> D[OpenAI Chat Model<br/>gpt-5.6-luna]
    B --> E[Structured Output Parser<br/>subject + email]
    E --> B
    B --> F[Set Email<br/>email = output.email]
    F --> G[Get Feedback<br/>Gmail sendAndWait<br/>to chiranjeev...<br/>APPROVAL REQUIRED]
    G --> H[Check Feedback<br/>Text Classifier<br/>Gemini 3 flash<br/>Approved vs Declined]
    H -->|Approved| I[Send Email<br/>Gmail to lead.email<br/>subject + email]
    H -->|Declined| J[Revision Agent<br/>Email + human text<br/>rewrite]
    J --> D
    J --> E
    J --> F
    F --> G

    style A fill:#111111,stroke:#111111,color:#ffffff
    style B fill:#111111,stroke:#111111,color:#ffffff
    style C fill:#111111,stroke:#111111,color:#ffffff
    style D fill:#111111,stroke:#111111,color:#ffffff
    style E fill:#111111,stroke:#111111,color:#ffffff
    style F fill:#111111,stroke:#111111,color:#ffffff
    style G fill:#111111,stroke:#111111,color:#ffffff
    style H fill:#111111,stroke:#111111,color:#ffffff
    style I fill:#111111,stroke:#111111,color:#ffffff
    style J fill:#333333,stroke:#333333,color:#ffffff

03_Screenshot_3_Sales_Team_HITL.png

1. Lead Intake and Context

Objective

Capture intent the moment a lead lands in Airtable and add proof from past work so the draft is specific, not generic.

Step by Step Process

Step Node What it does
1 Airtable Trigger1 — airtableTrigger Base app7GDA63cJW112Dz, table tblRFFIrD7jqgLhuE, triggerField Created, pollTimes everyMinute, auth airtableTokenApi 54zRR9bQfLLcZb4y. Fires on a new record without external webhook setup. Position -1600,16. Returns fields: name, email, intent, budget, companyName, projectDescription, timeline
2 Project Database — airtableTool Base app7GDA63cJW112Dz table tblgAhhdJHoKszeLM, operation search. Wired as ai_tool to Sales Agent. Agent decides when to call it to find a similar project to reference. Provides proof that the team can deliver
3 Sales Agent — agent promptType define, text with expressions: Name {{ $json.fields.name }}, Email {{ email }}, Intent {{ intent }}, Budget {{ budget }}, Company Name {{ companyName }}, Project Description {{ projectDescription }}, Timeline {{ timeline }}. System message instructs: act as expert sales for AI agency, convince lead to book second call, retrieve previous projects to share, keep email concise, sign off as Jim, Dunder AI, include {{ $now }}. Position -1408,16
4 OpenAI Chat Model — lmChatOpenAi Model gpt-5.6-luna mode list cachedResult gpt-5.6-luna, credentials J1XsY3EChVaVis9t. Provides language model for both Sales and Revision agents via shared ai_languageModel edge
5 Structured Output Parser — outputParserStructured inputSchema manual JSON: required subject string description subject line, email string description body content. Wired as ai_outputParser to both agents. Guarantees downstream Set can read $json.output.subject and .email

Deliverables

Prompt with lead plus matching project proof captured before any email is written. If no similar project is found the agent still writes but without a case study link.

Output Example

{
  "lead": {
    "name": "Priya Mehta",
    "email": "[email protected]",
    "companyName": "StealthFin",
    "intent": "Automate KYT review",
    "budget": "$12k",
    "timeline": "3 weeks",
    "projectDescription": "Need to flag risky merchants from 4 sources before manual review"
  },
  "toolResult": {
    "projectsSearched": true,
    "matchedProject": "KYT Risk Flagging for PayFlow — reduced review time 62 percent"
  }
}

2. Draft and Human Review

Objective