Route and categorize Gmail emails to Slack with Llama 3 via OpenRouter
This n8n template from [Intuz](https://www.intuz.com/) provides a complete and automated solution to transform your team's inbox management. It acts as an intelligent agent that reads incoming Gmail messages, uses AI ...
Template notes
This n8n template from [Intuz](https://www.intuz.com/) provides a complete and automated solution to transform your team's inbox management.
It acts as an intelligent agent that reads incoming Gmail messages, uses AI to determine their category, and automatically routes them to the correct Slack channel—even creating new channels on the fly for new topics.
Who's this workflow for? - Customer Support Teams - Sales & Lead Management Teams - Operations & Project Management Teams - Any team that uses Slack as a central hub for communication and triaging tasks.
How it works 1. Monitor New Emails: The workflow continuously checks a specified Gmail account for new, unread emails. It automatically filters out spam, drafts, and duplicates.
2. AI Categorization: Each new email's subject and body are sent to an AI model (like Llama 3 via OpenRouter). The AI analyzes the content and assigns a category based on a predefined list (e.g., sales, marketing, accounts, internal).
3. Find or Create Slack Channel: The workflow then checks your Slack workspace to see if a channel corresponding to the AI's category already exists (e.g., sales).
4. Route the Email: - If the channel exists: The workflow posts a formatted summary of the email, a link to the original message in Gmail, and a "Reply" button directly into the existing channel. - If the channel does NOT exist: The workflow automatically creates a new public channel (e.g., new-category), invites a designated user, and then posts the email summary.
Key Requirements to Use This Template