← All N8N workflows
AI & researchAgentFilterIfLM Chat OllamaManual Trigger

Auto Categorise Outlook Emails with AI

Configured with Agent, Filter, LM Chat Ollama, Markdown, and additional nodes. Review the connections and setup before adapting this template.

Workflow preview
TriggerWhen clicking ‘Testworkflow’Manual TriggerAI & modelsOllama Chat Model1LM Chat OllamaMessagingMicrosoft Outlook10Microsoft OutlookMessagingMicrosoft Outlook12Microsoft OutlookRoutingLoop Over Items1Loop Over ItemsMessagingMicrosoft Outlook13Microsoft OutlookMessagingMicrosoft Outlook15Microsoft OutlookMessagingMicrosoft Outlook16Microsoft OutlookMessagingMicrosoft Outlook17Microsoft OutlookMessagingMicrosoft Outlook18Microsoft OutlookMessagingMicrosoft Outlook19Microsoft OutlookTransformMarkdown1MarkdownTransformvarEmal1Edit FieldsMessagingMicrosoft Outlook20Microsoft OutlookMessagingMicrosoft Outlook21Microsoft OutlookRoutingFilter1FilterRoutingIf1IfMessagingMicrosoft Outlook22Microsoft OutlookTransformCatch Errors1Edit FieldsTransformvarJSON1Edit FieldsMessagingMicrosoft Outlook23Microsoft OutlookTransformvarID & Category1Edit FieldsMessagingMicrosoft Outlook MoveMessage1Microsoft OutlookAI & modelsAI Agent1AgentTransformMerge1MergeRoutingSwitch1Switch

Node categories in this workflow

  • Trigger
  • AI & models
  • Messaging
  • Routing
  • Transform

Icons describe general node roles, inferred from node types. Inspect the parameters for the configured action.

Drag to pan; use + and − to zoom. Reconstructed from the exported node positions; nothing runs here. Dashed lines represent non-main connections. Full node names and notes appear below.

How it works

The exported workflow contains the following configured nodes. Their connections are shown above; inspect the JSON for the complete logic, expressions, and external actions.

Workflow node names, types, and operations
NodeCategoryTypeOperation
When clicking ‘Test workflow’TriggerManual TriggerSee node parameters
Ollama Chat Model1AI & modelsLM Chat OllamaSee node parameters
Microsoft Outlook10MessagingMicrosoft Outlookmove
Microsoft Outlook12MessagingMicrosoft Outlookupdate
Loop Over Items1RoutingLoop Over ItemsSee node parameters
Microsoft Outlook13MessagingMicrosoft Outlookupdate
Microsoft Outlook15MessagingMicrosoft Outlookmove
Microsoft Outlook16MessagingMicrosoft Outlookupdate
Microsoft Outlook17MessagingMicrosoft Outlookmove
Microsoft Outlook18MessagingMicrosoft Outlookupdate
Microsoft Outlook19MessagingMicrosoft Outlookmove
Markdown1TransformMarkdownSee node parameters
varEmal1TransformEdit FieldsSee node parameters
Microsoft Outlook20MessagingMicrosoft Outlookupdate
Microsoft Outlook21MessagingMicrosoft Outlookupdate
Filter1RoutingFilterSee node parameters
If1RoutingIfSee node parameters
Microsoft Outlook22MessagingMicrosoft Outlookupdate
Catch Errors1TransformEdit FieldsSee node parameters
varJSON1TransformEdit FieldsSee node parameters
Microsoft Outlook23MessagingMicrosoft OutlookgetAll
varID & Category1TransformEdit FieldsSee node parameters
Microsoft Outlook Move Message1MessagingMicrosoft Outlookmove
AI Agent1AI & modelsAgentSee node parameters
Merge1TransformMergeSee node parameters
Switch1RoutingSwitchSee node parameters

Setup

  1. Download the JSON and import it into an isolated n8n instance. Leave the workflow inactive.
  2. Connect your own credentials through n8n’s credential store. Replace REPLACE_WITH_* values with your resource identifiers.
  3. Inspect API destinations, Code nodes, database queries, file paths, and outbound actions.
  4. Run with synthetic data and harmless destinations. Enable triggers only after checking the actual outputs.

Requirements

An n8n instance with the listed node types and compatible versions. Service-connected workflows may require accounts, credentials, or paid APIs.

Credential types declared in the source

None declared. HTTP requests and Code nodes may still need configuration.

Workflow notes

Auto Categorise Outlook Emails with AI

Auto Categorise Outlook Emails with AI

Built by Wayne Simpson at nocodecreative.io

Watch Set Up Video 👇

Watch Set Up Video 👇

Markdown1

Converts the body of the email to markdown

varEmal1

Set email fields

If1

Checks if the email has been read

Outlook Business with filters

Outlook Business with filters

Filters:

flag/flagStatus eq 'notFlagged' and not categories/any()

These filters ensure we do not process flagged emails or email that already have a category set.

Sanitise Email

Sanitise Email

Removes HTML and useless information in preparation for the AI Agent

Modify Categories

Modify Categories

Edit this to customise category selection

Convert to JSON

Convert to JSON

  • Ensures the Agent output to converted to JSON
  • Catches any errors and continues processing
Switch Categories

Switch Categories

Ensure your categories match the varID & Category Edit Fields node

Auto Categorise Outlook Emails with AI

Auto Categorise Outlook Emails with AI

Purpose and structure

This folder contains the Auto Categorise Outlook Emails with AI workflow. Its executable nodes use agent, filter, if, lmChatOllama, manualTrigger, markdown, merge, microsoftOutlook, set, splitInBatches, switch. The table and connection map below are derived from the JSON, not an inferred guarantee of behavior.

Setup

Import inactive. Configure your own credentials and replace REPLACE_WITH_* values. Review external destinations and Code nodes before running.

Entry points

When clicking ‘Test workflow’

Verification

Sanitized source candidate; not runtime-tested. This overview is generated from node metadata. Read the folder README for the connection map, credential types, and license.

Attribution

https://github.com/Zie619/n8n-workflows/blob/94007c1445d9258a7da116646b79473e7c7c3282/workflows/Filter/0595_Filter_Manual_Send_Triggered.json MIT; preserve source notices.

Canvas section labels

These name areas of the original canvas; they do not include explanatory instructions.

  • Set Categories
  • Move to Folders
  • Check if email has been read

More in AI & research