I want to discuss a task or project
Done! We will get back to you within one business day
Something went wrong. Please try again
Alexander Start:Duck 🦢
@olga_startduck
Write to Telegram
Назад
1k+ участников
Вступить в Telegram
n8n
12.10.2025

AI Cold Email System - Automated cold mailing system with AI analysis of responses

Process description

This automation is a comprehensive system for conducting personalized email campaigns using artificial intelligence. The system consists of two interrelated workflows: the first automates the distribution of personalized commercial offers, the second analyzes customer responses and automatically classifies them by status of interest. AI agents generate unique emails for each customer and analyze their responses, ensuring full automation of the sales funnel at the initial contact stage.

API keys and services:

  1. Google Sheets API - customer database and status accounting
  2. Gmail OAuth2 - sending emails and monitoring incoming messages
  3. OpenAI API (GPT-3.5-Turbo) - generating emails and analyzing responses

System architecture

PART 1: MAILING WORKFLOW

1.1 Manual Trigger - Initiating a mailing list

Purpose: Manual launch of the mass mailing process

Benefits:

  • Full control over shipping times
  • The ability to pre-check the database
  • Protection against accidental launches

1.2 Get row (s) in sheet - Loading customer base

Purpose: Extracting lead data from Google Sheets

Settings:

  • Credentials: Google Sheets account

Data structure:

  • First name - contact person's name
  • Email - shipping address
  • The company's activities - client's business area
  • Status - current interaction status

1.3 Loop Over Items - Sequential Processing

Purpose: Organizing a cycle for personalized delivery to each customer

Settings:

  • Batch Size: 1 (individual processing)
  • Options: Default settings

It is important: Consistent processing prevents Gmail from being blocked for mass mailing and allows you to personalize each email.

1.4 Message a model - AI email generation

Purpose: Creating a unique personalized email for each customer

Settings:

  • Model: gpt-3.5-turbo
  • Temperature: Default (creativity)
  • Max Tokens: Auto

System prompt:

Here's the Client's name: {{$json ['Name']}}

Here are the company's activities: {{$json ['Company activities']}}

Paraphrase and uniquely define the following text for a letter to the client:

[Basic email template with variables for personalization]

Prompt features:

  • Uses customer data for personalization
  • Rephrases the basic template for uniqueness
  • Adapts the offer to the client's industry
  • Preserves the structure and key messages

1.5 Wait — Delay between shipments (optional)

Purpose: Simulating human behavior and preventing spam filters

Settings:

  • Amount: 10 seconds (30-60 seconds recommended)
  • Status: Disabled (can be activated if needed)

1.6 Send a message - Send via Gmail

Purpose: Final sending of the generated email to the client

Settings:

  • To: {{$ ('Get row (s) in sheet') .item.json.email}}
  • Subject: “Collaboration”
  • Body: {{$json.message.content}}
  • Options: HTML formatting enabled

PART 2: RESPONSE ANALYSIS WORKFLOW

2.1 Gmail Trigger — Monitoring Inbox

Purpose: Automatically checking new emails every minute

Settings:

  • Poll Times: Every Minute
  • Filters: All messages (filters can be configured)
  • Credentials: Gmail OAuth2

Optimization: You can set up filters by tags or keywords to process only relevant emails.

2.2 Get row (s) in sheet - Download the reconciliation database

Purpose: Getting an up-to-date customer base to verify senders

Settings: Identical to the settings in the mailing workflow

2.3 Aggregate - Preparing an email list

Purpose: Creating a single array of email addresses for quick verification

Settings:

  • Fields to Aggregate: Email
  • Operation: Collect all values

2.4 Message a model - Extracting sender's email

Purpose: AI extracts a clean email address from the From field

Prompt:

{{$ ('Gmail Trigger') .item.json.from}}

Send as an answer only the email from the text above, without extra characters

The result: Clean email without name and angle brackets

2.5 If - Checking availability in the database

Purpose: Filter only responses from customers from the newsletter

Condition:

  • Left Value: {{$ ('Aggregate') .item.json.email}}
  • Operator: contains
  • Right Value: {{$json.message.content}}

Logic: Only emails from the recipients of our newsletter are processed.

2.6 Message a model1 - Analyzing the tone of the response

Purpose: AI determines customer interest

Prompt:

Analyze the customer's email and send one of two options as an answer

If the customer is interested - INTERESTED

If the client is not interested - REFUSAL

Here's an email: {{$ ('Gmail Trigger') .item.json.snippet}}

The results of the analysis:

  • INTERESTED - potential lead
  • DENIAL - negative answer

2.7 Update row in sheet - Status update

Purpose: Automatic update of customer status in the database

Settings:

  • Operation: Update
  • Matching Column: Email
  • Update Fields:
    • Email: {{$ ('Message a model') .item.json.message.content}}
    • Status: {{$json.message.content}}

Node connection diagram

Workflow 1: Newsletter

Workflow 2: Analyzing Responses

Required services and their configuration

Google Workspace:

  1. Google Sheets setup:
    • Create a “Customer base” table
    • Columns: Name | Email | Company activity | Status
    • Grant N8n access via OAuth2
    • Enable Google Sheets API
  2. Gmail setup:
    • Configure OAuth2 access for N8n

OpenAI setup:

  • Get an API key
  • Set up billing
  • Set usage limits
  • Choose a model (GPT-3.5-Turbo is optimal in terms of price/quality)

N8n setup:

  • Install credentials for all services
  • Configure execution timeout (for large databases)
  • Enable error workflow to monitor failures

System capabilities

Sales automation:

  • Mass personalization - a unique letter to each client
  • Automated lead qualification - AI determines interest
  • Real-time CRM update - statuses are updated instantly
  • Scalability - 10 to 1000+ contacts

AI capabilities:

  • Adaptation to the industry - taking into account the specifics of the client's business
  • Tonal analysis - accurate definition of intentions
  • Content uniqueness - spam filter protection
  • Contextual understanding - analysis of implicit signals

Analytics and control:

  • Tracking statuses - real-time funnel visibility
  • The history of interactions - all communications in one place
  • Performance metrics - conversions, responses, refusals
  • A/B testing - different templates for different segments

Use cases

Scenario 1: Launching a campaign for a new industry

  1. Uploading 50 logistics contacts to Sheets
  2. We launch workflow newsletters
  3. AI adapts the offer to logistics companies
  4. Emails leave with a delay of 45 seconds
  5. After 2 days, answers start coming
  6. The system automatically sets statuses

The result: 50 emails → 15 replies → 8 interested parties → 3 deals

Scenario 2: Follow-up on stakeholders

  1. We filter clients with the “INTERESTED” status in Sheets
  2. Creating a new workflow with a follow-up email
  3. AI generates a more detailed proposal
  4. We send presentations with the attachment

The result: The conversion of interested parties to meetings is 40%

Scenario 3: Reactivating the cold base

  1. We take clients without an answer > 30 days
  2. Let's change the template to a more provocative one
  3. AI adds urgency and exclusivity
  4. We are launching a repeat campaign

The result: Reactivating 15% of the silent base

The result of the system

What happens is:

  • Autonomous sales machine - works 24/7 without human intervention
  • Intelligent SDR - understands the context and adapts
  • Self-learning system - improves with every campaign
  • Transparent funnel - full visibility of the process
  • Scalable tool - from startup to enterprise

Conclusion

This system turns cold email campaigns from routine work into a highly efficient automated process with AI optimization at every stage. The combination of AI-enabled personalization, automated response analysis, and real-time status updates creates unprecedented efficiency in B2B sales, allowing small teams to compete with large sales teams.

Читайте также

No items found.

write to us and we will show you the way to efficiency