Skip to main content

Automated email replies with GPT-4o, Outlook, and GoToHuman approval

Workflow preview

Workflow preview
100%
Automated email replies with GPT-4o, Outlook, and GoToHuman approval preview
Open on n8n.io

Important notice

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

1. Workflow Overview

This n8n workflow reads emails from your Outlook inbox, drafts AI powered replies using OpenAI, and routes them through the gotoHuman node for human approval before replying automatically. Key Fe...

Best for

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

Tools used

n8n-nodes-base.stickynote, @n8n/n8n-nodes-langchain.toolthink, @n8n/n8n-nodes-langchain.outputparserstructured, @n8n/n8n-nodes-langchain.lmchatopenai, n8n-nodes-base.manualtrigger, n8n-nodes-base.code, @n8n/n8n-nodes-langchain.agent, n8n-nodes-base.microsoftoutlook

Source and attribution

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

Original n8n.io source

1.1 Workflow description

Title
Automated email replies with GPT-4o, Outlook, and GoToHuman approval
Workflow name
Automated email replies with GPT-4o, Outlook, and GoToHuman approval

This n8n workflow reads emails from your Outlook inbox, drafts AI-powered replies using OpenAI, and routes them through the gotoHuman node for human approval before replying automatically.


✅ Key Features

  • Reads Outlook emails from today only (excluding those from your own address).
  • AI-generated replies crafted using OpenAI based on the subject and body of the email.
  • Community node integration: Uses the gotoHuman node for human review and approval of replies before sending.
  • Safe sending: Only approved responses are automatically sent back via Outlook.
  • Expandable: Can be easily modified to:
    • Send drafts instead of full replies
    • Include additional email filters
    • Trigger at intervals or via webhook

🧠 Nodes Used

  • Microsoft Outlook – Fetch and reply to emails
  • OpenAI – Generates smart reply text
  • gotoHuman – Human-in-the-loop approval system
  • Loop Over Items, IF, Code, and Set nodes for processing logic
  • Manual Trigger – For testing

🔧 Setup Instructions

1. Connect APIs

  • Outlook OAuth2:

    • Go to Azure Portal
    • Register an app
    • Add Mail.Read, Mail.Send scopes
    • Set redirect URI: https://api.n8n.cloud/oauth2-credential/callback
    • Paste credentials in n8n credential manager
  • OpenAI API:

    • Create account at OpenAI
    • Create an API Key
    • Add it to n8n credentials
  • gotoHuman API:

    • Go to https://gotoHuman.ai and sign in
    • Create a review template (e.g., “Email Responses”)
    • Copy the Template ID and API key into n8n credentials

🪜 Workflow Steps Overview

1. Trigger

Use the Manual Trigger to test or schedule execution with a cron node.

2. Filter Emails from Today

A Code node outputs today's date in the proper yyyy-mm-dd format.

const today = new Date();
today.setHours(0, 0, 0, 0);
return [{ json: { searchQuery: `received:${today.toISOString().split('T')[0]}` } }];

3. Search and Filter Outlook Messages

  • Uses the Outlook node with a search query like:
    received:2025-08-06 -from:[email protected] (Update to your email)

4. Generate AI Response

  • Text prompt to OpenAI:

    subject: {{ $json.subject }}  
    body: {{ $json.body.content }}
    
  • System prompt:
    > You are a personal assistant helping respond to emails. I am an AI automation expert specializing in helping small and medium-size businesses automate processes. Create a short response to the email. Sign the email as Robert Breen.

5. Review with gotoHuman

  • Submit AI output for human approval using the gotoHuman node.
  • The output schema should match the Review Template fields (e.g., "email", "OriginalEmail").

6. IF Node Decision

  • If status is approved, send reply
  • If not, return to loop for revision or skip

✏️ Customization Ideas

  • ✉️ Send only drafts by skipping the "reply" step and storing results.
  • 🕒 Schedule the workflow with a Cron trigger for automation.
  • 🔎 Add label filters or subject keywords for advanced targeting.

🔗 External Links


💬 Need More Help?

If you'd like help customizing this or building similar automations, reach out:

Robert Breen
AI & Automation Consultant
🌐 https://ynteractive.com
📧 [email protected]
🔗 LinkedIn


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 - Sticky Note

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

Block 2 - Tool: Inject Creativity

Type / Role
@n8n/n8n-nodes-langchain.toolThink - toolThink
Config choices
Version 1

Block 3 - Parser: Extract JSON from Idea

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

Block 4 - openai

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

Block 5 - Sticky Note1

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

Block 6 - Sticky Note3

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

Block 7 - Test

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

Block 8 - Output Today's Date

Type / Role
n8n-nodes-base.code - code
Config choices
Version 2

Block 9 - AI Agent: Create caption for linkedin

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

Block 10 - Sticky Note2

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

Block 11 - Microsoft Outlook

Type / Role
n8n-nodes-base.microsoftOutlook - microsoftOutlook
Config choices
Version 2

Block 12 - gotoHuman

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

Block 13 - Loop Over Items

Type / Role
n8n-nodes-base.splitInBatches - splitInBatches
Config choices
Version 3

Block 14 - Microsoft Outlook1

Type / Role
n8n-nodes-base.microsoftOutlook - microsoftOutlook
Config choices
Version 2

Block 15 - If

Type / Role
n8n-nodes-base.if - if
Config choices
Version 2.2

3. Summary Table

Workflow Automated email replies with GPT-4o, Outlook, and GoToHuman approval
Complexity advanced
Nodes 15
Categories Ticket Management, AI Chatbot
Author Robert Breen
Published 06 Aug 2025

4. Reproducing the Workflow from Scratch

  1. 1. Download the workflow JSON

    Use the JSON export at /data/workflows/7049/7049.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 Automated email replies with GPT-4o, Outlook, and GoToHuman approval do?

This n8n workflow reads emails from your Outlook inbox, drafts AI powered replies using OpenAI, and routes them through the gotoHuman node for human approval before replying automatically. Key Fe...

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, AI Chatbot use case.