Extract email tasks with Gmail, ChatGPT-4o and Supabase
Ready for 3.0What this workflow does
This AI workflow has 8 nodes and runs on a schedule (every minute). Along the way it connects OpenAI, Gmail and Supabase.
How it runs
Trigger: On a schedule (every minute).
- Get Unread Emails from Inbox (Gmail): get many
- Loop Over Items (Loop Over Items (Split in Batches)): loops over the items in batches
- Get Email from Database (Supabase): get
- Check if Email in Database (If): checks a condition and branches into true / false
- Prepare ChatGPT Prompt (Code): runs custom JavaScript code
- Extract Task Detail from Email (OpenAI): uses OpenAI
- Insert Email Detail to Supabase (HTTP Request): calls an HTTP API (POST)
Services it uses
Other OpenAI + Gmail templates (1,623) · Other OpenAI + Supabase templates (149) · Other Supabase + Gmail templates (69)
Before you upgrade to n8n 3.0
Nothing in this workflow is removed in n8n 3.0, so it should import and run after the upgrade.
- Code node: the task timeout drops from 300s to 60s. Test with a realistic data volume.
Nodes used (8)
- Schedule Trigger
n8n-nodes-base.scheduleTrigger - Code
n8n-nodes-base.code - OpenAI
@n8n/n8n-nodes-langchain.openAi - HTTP Request
n8n-nodes-base.httpRequest - Gmail
n8n-nodes-base.gmail - Supabase
n8n-nodes-base.supabase - If
n8n-nodes-base.if - Loop Over Items (Split in Batches)
n8n-nodes-base.splitInBatches
From the author
📩 Gmail → GPT → Supabase | Task Extractor This n8n workflow automates the extraction of actionable tasks from unread Gmail messages using OpenAI's GPT API, stores the resulting task metadata in Supabase, and avoids re-processing previously handled emails.…