AI-Powered Support Ticket Triage: Gmail to Linear Issue Creator - n8n Workflow

Instantly transform incoming Gmail support requests into structured Linear issues using AI triage. This robust n8n workflow automatically assigns priority, labels, and summaries for faster resolution. A vital n8n templates example.

Workflow Preview

Ready to automate?

Download this n8n workflow template and start using it instantly.

Who is this best for?

Support Teams: Organizations needing to automate the initial triage and organization of incoming customer support emails. Developers & Product Managers: Teams using Linear for task management who want immediate, structured issue reporting from customer channels. Automation Specialists: Users looking for advanced examples of how to integrate LangChain AI agents with practical business operations using the n8n node ecosystem. DevOps: Professionals seeking reliable, scheduled systems to convert external communications into actionable project tasks.

Overview

Managing high volumes of support email can be overwhelming, leading to delays in labeling, prioritizing, and assigning issues. This sophisticated n8n workflow solves this by introducing an intelligent AI layer to the process. Once a new email hits your designated support inbox (e.g., [email protected]), this n8n automation takes over.

It utilizes the power of an OpenAI model (gpt-4o-mini) configured as an issue triage assistant. The AI analyzes the email content, generates a concise summary, writes a clean description, and assigns both appropriate labels and a priority level (1-5), ensuring standardized data output via a Structured Output Parser n8n node. This allows the subsequent Linear n8n node to reliably create a perfectly triaged ticket, eliminating manual overhead. This specific n8n templates setup is a massive time-saver for any fast-paced support operation.

How it Works

The entire process is controlled by a scheduled n8n trigger, ensuring regular checks for new support requests.


  1. Scheduled Check: The n8n trigger starts the process, executing hourly to check for new data.

  2. Fetch Gmail Messages: The Gmail n8n node retrieves recent messages based on a defined filter (to:[email protected]).

  3. Deduplication: The 'Mark as Seen' n8n node prevents duplicate processing by tracking message IDs from previous executions, ensuring idempotency for this crucial n8n workflow.

  4. Formatting: The email's HTML body is converted to clean Markdown format for optimal AI ingestion.

  5. AI Triage Agent: The LangChain 'Generate Issue From Support Request' n8n node receives the cleaned email data. A system prompt guides the AI to act as a triage assistant, classifying the request into predefined labels (e.g., Technical, Billing) and assigning a priority (1-5).

  6. Structured Data Output: The AI output is passed through a Structured Output Parser n8n node, which enforces a specific JSON schema, guaranteeing that the required summary, description, labels, and priority fields are present and correctly formatted.

  7. Create Linear Issue: Finally, the Linear n8n node uses the structured data from the AI to create a new issue. The summary becomes the title, the detailed description includes the original reporter's details, and the labels are automatically appended to the issue description for quick filtering in Linear. This robust n8n workflow completes the support cycle.

Installation Guide

To deploy this powerful n8n workflow, follow these steps:


  1. Import: Copy the provided JSON code and import it directly into your n8n instance via the 'Workflows' section.

  2. Credentials Setup: Gmail: You will need credentials for the Gmail n8n node. Ensure the connected account has access to the support inbox and set the filter in the 'Get Recent Messages' node to match your actual support email address (e.g., replacing [email protected]). OpenAI: Set up an OpenAI API key credential. This is required for the 'OpenAI Chat Model' n8n node used for triaging. We recommend using a model like gpt-4o-mini for cost-effectiveness and speed.* Linear: Configure your Linear API token credential for the 'Create Issue in Linear.App' n8n node.

  3. Linear Node Configuration: In the Linear n8n node, ensure you select the correct Team ID and default State ID where new issues should land.

  4. Activation: Once all credentials are set and the necessary parameters are configured, activate the n8n workflow. The schedule n8n trigger will begin monitoring your inbox hourly.

Node Details

This n8n templates solution utilizes several key n8n node types to achieve its goal:

Schedule Trigger: The primary n8n trigger, configured to run the n8n workflow hourly, initiating the sync process.
Gmail (Get Recent Messages): Fetches new emails. Key Configuration: Uses the operation getAll and a filter (q) like to:[email protected] to target specific support emails.
Remove Duplicates (Mark as Seen): Ensures data integrity. Key Configuration: operation: removeItemsSeenInPreviousExecutions based on the unique Gmail message ID ({{ $json.id }}).
Markdown: Converts the email body from HTML to Markdown to provide clean input for the LLM.
Chain LLM (Generate Issue From Support Request): The core AI triage logic. Key Configuration: Uses a detailed system prompt defining roles, labels, and priority levels. The input text includes the reporter's name, email, subject, and converted description.
OpenAI Chat Model: The underlying language model used by the AI agent. Key Configuration: Model: gpt-4o-mini (or similar).
Structured Output Parser: A specialized n8n node that guarantees the AI response conforms to a specific JSON schema (containing labels, priority, summary, and description).
Linear (Create Issue in Linear.App): Creates the final structured ticket. Key Configuration: Maps AI outputs for title ({{ $json.output.summary }}), priorityId ({{ $json.output.priority }}), and dynamically includes the AI-generated labels in the issue description.

Related n8n Workflows

Free

Nodes: 9 Nodes
Updated: December 26 2025
View all
Created by
Jimleuk
Jimleuk

Freelance consultant based in the UK specialising in AI-powered automations. I work with select clients tackling their most challenging projects. For business enquiries, send me an email at [email protected] LinkedIn: https://www.linkedin.com/in/jimleuk/ X/Twitter: https://x.com/jimle_uk

Featured*