Free automation, built to workOffer ends September 1, 2026.Claim yours

Qualify inbound email leads with AI

Read new Gmail, classify with AI, create CRM records for real leads, and notify sales — an n8n workflow you can import.

Intermediate·~45 min·8 nodes

n8n · Gmail · OpenAI · Airtable · Slack

General Business · Professional Services · Marketing Agencies · SaaS·Sales · Lead Management

What this automation does

Instead of a salesperson opening every inbound email to decide whether it is a lead, this workflow reads the message, asks a model whether it is a sales opportunity, writes only the qualified ones to the CRM, and pings Slack. Newsletters, job ads, and out-of-office replies stay out of the pipeline.

When to use it

Use this workflow if:

  • A shared inbox mixes real enquiries with noise, and someone sorts it by hand.
  • Leads sit in Gmail until a person copies them into the CRM.
  • Qualification rules live in someone’s head, so the bar changes by day.
  • Sales only finds out about an email when they happen to check that label.
  • You want a first-pass classifier before a person spends time on the thread.

Workflow overview

  1. Trigger

    Gmail reports a new message.

  2. Validate

    Sender, subject, and body are extracted into a stable shape.

  3. Process

    The model returns isLead, category, reason, and confidence.

  4. Decision

    Only messages flagged as leads continue.

  5. Action

    Airtable creates the CRM record from the classified email.

  6. Notification

    Slack tells sales who wrote and why it was classified as a lead.

Interactive flow

Pan, zoom, and click a node to inspect it. Use the buttons below the canvas to jump to a step.

n8n workflow JSON

Copy this workflow JSON and import it directly into n8n. You will still need to connect your own credentials and configure the services used by the workflow.

Download JSON

Import this workflow into n8n

  1. Copy or download the workflow JSON from this page.
  2. Open n8n and create a new workflow — or open an empty canvas.
  3. Use Import from File, or paste the JSON via the workflow menu.
  4. Connect your own credentials for every service the workflow uses.
  5. Replace the placeholder IDs, channels, tables, and folder names.
  6. Run a test with a sample payload before you activate it.
  7. Activate the workflow only after the test run looks correct.

Setup requirements

Accounts

  • n8n
  • Gmail
  • OpenAI
  • Airtable
  • Slack

Credentials

  • Gmail OAuth
  • OpenAI API credential in n8n — never in this JSON
  • Airtable personal access token
  • Slack OAuth

Information

  • Which inbox or Gmail label should be scanned
  • Airtable base ID and Leads table fields
  • Slack channel for qualified-lead alerts
  • A short list of examples that are leads vs not, to tune the prompt

Step-by-step

  1. Step 1Watch the inbox

    The Gmail Trigger polls for new mail. Narrow it with a label if this address also receives receipts, newsletters, or support.

  2. Step 2Extract sender and content

    The Set node copies from, subject, body, and message id into fields the rest of the flow can rely on, even if the Gmail payload shape changes.

  3. Step 3Classify with AI

    The OpenAI node returns JSON: whether it is a lead, a category, a one-line reason, and a confidence score. Adjust the prompt to your offer.

  4. Step 4Branch on the result

    True continues to the CRM. False hits a no-op — a good place to add a Gmail label such as “not-a-lead”.

  5. Step 5Create the CRM record and notify

    Qualified messages become Airtable rows and a Slack line so sales does not have to watch the inbox.

Ways to extend this workflow

  • Require a minimum confidence before writing to the CRM; send low-confidence mail to a review channel instead.
  • Add a Gmail label or archive step on the non-lead branch.
  • Extract a company name and domain, then enrich before the CRM write.
  • Draft a first-reply email and hold it for approval instead of notifying only.
  • Route categories (sales vs partnership vs press) to different owners.
  • Log every classification — including skips — so you can audit the prompt.
  • Swap Airtable for Pipedrive or HubSpot using the same classified payload.

Need this customized for your business?

This template is the starting point. If the workflow needs custom logic, several systems, error handling, or production monitoring, Syntropic Ops can design and implement it with you.