Skip to product information

Gmail AI Email Classification with GPT-4o-mini Labels

Gmail AI Email Classification with GPT-4o-mini Labels

 (200+Reviews)
Regular price £36.99
Regular price £36.99 Sale price
SAVE Sold out
Instant Digital Download
Unlimited Downloads
Lifetime Access in Your Account
🔥
128+ Sold
Popular with n8n builders
23 people viewing
High interest right now
9 added today
Fast-moving digital product
Gmail AI Email Classification with GPT-4o-mini Labels

Gmail AI Email Classification with GPT-4o-mini Labels

Regular price £36.99
Regular price £36.99 Sale price
SAVE Sold out

Turn new Gmail emails into labeled, actionable inboxes—automatically

This n8n workflow watches your Gmail for new messages, uses OpenAI (GPT-4o-mini) to classify each email, then automatically applies the matching `Gmail label` based on the predicted category—so your inbox stays organized without manual triage.

What this workflow does

Designed for practical inbox automation, this “lite” build follows a simple pipeline:

  • Triggers every minute when a new email arrives in Gmail.
  • Builds the OpenAI request using a classification prompt, your selected model (GPT-4o-mini), and a mapping of categories to Gmail label IDs.
  • Sends key email details to the OpenAI Chat Completions API: the email subject, sender, and a truncated body.
  • Parses the JSON response to extract category, urgency, and a short summary, defaulting to “noise” if parsing fails.
  • Adds the corresponding Gmail label to the original message based on the returned category.

Use cases

  • Automatically sort inbound leads, support emails, and newsletters into labeled Gmail folders.
  • Reduce inbox backlog by tagging “noise” or low-priority messages without opening them.
  • SaaS operators who want consistent triage rules without maintaining complex filters.

Technical details

  • n8n nodes: Gmail Trigger, Set, HTTP Request, Code, and a Gmail label action (plus notes via Sticky Note).
  • Integrations: Gmail (trigger + apply labels) and OpenAI (Chat Completions) using HTTP Header Auth.
  • Setup requirements: connect Gmail credentials, add your OpenAI API key, create Gmail labels, copy their label IDs, and replace the placeholder values in the category-to-label mapping.

Note: This is the lite version. A fuller build also adds a Google Sheets log, AI-drafted replies to new enquiries, and instant alerts for urgent emails (available at baynhams.gumroad.com/l/inbox-triage).

View full details