Automation library · Scheduling

Smart email classifier & auto-responder with Azure OpenAI

Started by an arriving email, and works across Gmail, Google Calendar and Telegram. It hands the judgement calls to Azure OpenAI. 22 steps: large, and worth reading before you trust it with anything live.

LargeCalls a model: Azure OpenAI

22 stepsLarge: read it before trusting it with anything live
0Branches: places the flow splits
0Loops or waits
3Services it connects to

The flow

Starts it 1Model 6Logic 2Service 13

The steps in the order they run, from what starts it.

  1. 1Azure OpenAI Chat ModelLm Chat Azure Open AiModel
  2. 2DraftGmail ToolService
  3. 3Get emailsGmail ToolService
  4. 4Google CalendarGoogle Calendar ToolService
  5. 5Gmail TriggerGmail triggerStarts it
  6. 6json schemaOutput Parser StructuredModel
  7. 7Sentiment AnalysisSentiment AnalysisModel
  8. 8important?Sentiment AnalysisModel
  9. 9Draft ReplyAgentModel
  10. 10needs reply?Sentiment AnalysisModel
  11. 11$INPUTS$SetLogic
  12. 12SpamGmailService
  13. 13ImportantGmailService
  14. 14PromotionGmailService
  15. 15NotificationGmailService
  16. 16PersonalGmailService
  17. 17Call requestGmailService
  18. 18Needs ReplyGmailService
  19. 19GmailGmailService
  20. 20Write draftGmailService
  21. 21No Operation, do nothingNo OpLogic
  22. 22TelegramTelegramService

How it's built

Starts on
An arriving email
Steps
22
Size
Large: read it before trusting it with anything live
Connects to
Gmail, Google Calendar, Telegram
Model
Azure OpenAI

Questions

What does it need to run?

An n8n account, plus your own Gmail, Google Calendar and Telegram accounts, and a key for Azure OpenAI. You connect your own accounts after importing it; none are included.

What starts it?

It starts on an arriving email.

Does it use AI?

Yes. It calls Azure OpenAI. Model calls are billed by the provider, not by n8n.

How long does it take to set up?

Take your time. At 22 steps it is large: read it before trusting it with anything live.

How do I import it?

Copy the workflow, open a new workflow in n8n and paste. The steps appear on the canvas, ready for your own accounts.

Before you run it

Nothing here has been tested by us. It is somebody's working automation, read and described from its own steps. Treat the connections it wants as a list of accounts it will touch, and read the 22 steps before you point it at anything that matters.