Skip to main content

Classify emails and send replies with GPT-4o and gotoHuman for supervision

Workflow preview

Workflow preview
100%
Classify emails and send replies with GPT-4o and gotoHuman for supervision preview
Open on n8n.io

Important notice

This workflow is provided as-is. Please review and test before using in production.

1. Workflow Overview

Let AI classify your incoming emails and draft replies. Use gotoHuman to approve emails before they are sent out. It also lets you manually edit the draft or even ...

Best for

  • Ticket Management automation workflows
  • Multimodal AI automation workflows
  • advanced n8n builders looking for reusable templates

Tools used

@n8n/n8n-nodes-langchain.lmchatopenai, n8n-nodes-base.gmailtrigger, @n8n/n8n-nodes-langchain.agent, n8n-nodes-base.noop, n8n-nodes-base.set, @n8n/n8n-nodes-langchain.outputparserstructured, n8n-nodes-base.switch, @gotohuman/n8n-nodes-gotohuman.gotohuman

Source and attribution

This workflow is cataloged by N8N Workflows and links back to its original n8n.io source page by gotoHuman.

Original n8n.io source

1.1 Workflow description

Title
Classify emails and send replies with GPT-4o and gotoHuman for supervision
Workflow name
Classify emails and send replies with GPT-4o and gotoHuman for supervision

Let AI classify your incoming emails and draft replies. Use gotoHuman to approve emails before they are sent out. It also lets you manually edit the draft or even ask for a retry.

How it works

  1. The workflow is triggered for each new email which gets passed to an AI classification agent. It assigns the email to one of the categories defined in the prompt (Customer Support, Sales opportunity, Promo, Personal,...). The agent also determines whether a reply is needed and if it is important.
  2. If a reply is needed, we ask the AI Email Writer to draft a response. Even if it is missing context it can help us draft an outline for the response.
  3. The email draft is sent to gotoHuman where the reviewer can manually edit it or ask to regenerate it with the option to even edit the prompt (Retries loop back to the AI Email Writer node)
  4. Approved email replies are automatically sent from the workflow

How to set up

  1. Most importantly, install the gotoHuman node before importing this template! (Just add the node to a blank canvas before importing)
  2. Set up your credentials for gotoHuman, OpenAI, and Gmail
  3. In gotoHuman, select and create the pre-built review template "Email agent" or import the ID: v81wzxwYoFYvWpmuIBgX
  4. Select this template in the gotoHuman node

Requirements

You need accounts for

  • gotoHuman (human supervision)
  • OpenAI (classification, drafting)
  • Gmail

How to customize

  • Change the predefined categories in the prompt of the AI classification agent
  • Provide the AI Email Writer with more context to create replies. Consider adding tools that allow the agent to fetch more infos about clients, your calendar, FAQs for your product,...

1.2 Logical Blocks

This catalog entry is organized from the workflow JSON. The node-level section below shows the executable blocks available for review before importing the template.

2. Block-by-Block Analysis

Block 1 - OpenAI Chat Model

Type / Role
@n8n/n8n-nodes-langchain.lmChatOpenAi - lmChatOpenAi
Config choices
Version 1.2

Block 2 - OpenAI Chat Model2

Type / Role
@n8n/n8n-nodes-langchain.lmChatOpenAi - lmChatOpenAi
Config choices
Version 1.2

Block 3 - New Email

Type / Role
n8n-nodes-base.gmailTrigger - gmailTrigger
Config choices
Version 1.2

Block 4 - AI Classifier

Type / Role
@n8n/n8n-nodes-langchain.agent - agent
Config choices
Version 2.2

Block 5 - AI Email Writer

Type / Role
@n8n/n8n-nodes-langchain.agent - agent
Config choices
Version 2.2

Block 6 - No reply

Type / Role
n8n-nodes-base.noOp - noOp
Config choices
Version 1

Block 7 - Set Prompt

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 8 - Set (edited) prompt

Type / Role
n8n-nodes-base.set - set
Config choices
Version 3.4

Block 9 - Structured Output

Type / Role
@n8n/n8n-nodes-langchain.outputParserStructured - outputParserStructured
Config choices
Version 1.3

Block 10 - Structured Output1

Type / Role
@n8n/n8n-nodes-langchain.outputParserStructured - outputParserStructured
Config choices
Version 1.3

Block 11 - Needs Human Attention?

Type / Role
n8n-nodes-base.switch - switch
Config choices
Version 3.2

Block 12 - Not important

Type / Role
n8n-nodes-base.noOp - noOp
Config choices
Version 1

Block 13 - gotoHuman: Human review

Type / Role
@gotohuman/n8n-nodes-gotohuman.gotoHuman - gotoHuman
Config choices
Version 1

Block 14 - Human response

Type / Role
n8n-nodes-base.switch - switch
Config choices
Version 3.2

Block 15 - Reply to thread

Type / Role
n8n-nodes-base.gmail - gmail
Config choices
Version 2.1

Block 16 - Sticky Note

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 17 - Sticky Note1

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 18 - Sticky Note2

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 19 - Sticky Note3

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 20 - Sticky Note4

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 21 - Sticky Note5

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 22 - Sticky Note6

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 23 - Sticky Note7

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

Block 24 - Sticky Note8

Type / Role
n8n-nodes-base.stickyNote - stickyNote
Config choices
Version 1

3. Summary Table

Workflow Classify emails and send replies with GPT-4o and gotoHuman for supervision
Complexity advanced
Nodes 24
Categories Ticket Management, Multimodal AI
Author gotoHuman
Published 12 Aug 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/7301/7301.json as the source template for this automation.

  2. 2. Import the template into n8n

    Open n8n, import the downloaded JSON, and review each node before activating the workflow.

  3. 3. Configure credentials and variables

    Replace placeholder credentials, API keys, webhook URLs, account IDs, and environment-specific values with your own settings.

  4. 4. Test with sample data

    Run the workflow manually or in a staging workspace, inspect node output, and confirm downstream systems receive the expected data.

  5. 5. Activate and monitor

    Enable the workflow only after testing, then monitor executions, errors, and rate limits during the first production runs.

5. General Notes & Resources

Review imported nodes carefully before activation. This catalog entry is intended to help you inspect the workflow structure, understand required services, and find related templates faster.

Node names, credentials, schedules, webhook paths, and external service limits may need adjustment for your workspace.

Frequently asked questions

What does Classify emails and send replies with GPT-4o and gotoHuman for supervision do?

Let AI classify your incoming emails and draft replies. Use gotoHuman to approve emails before they are sent out. It also lets you manually edit the draft or even ...

What do I need before importing this workflow?

Review the workflow JSON, configure any required credentials in n8n, and test the automation in a safe workspace before using it in production.

Can I customize this workflow?

Yes. Use the block-by-block analysis and the downloadable JSON to inspect each node, then adjust credentials, prompts, schedules, filters, or destinations for your Ticket Management, Multimodal AI use case.