Skip to content

Every 5 minutes

Turn support emails into Linear issues

Each support or feedback email becomes a clear Linear issue with a priority, or a comment on the matching issue if one is already open.

Runs
Every 5 minutes
Apps
Gmail, Linear
AI
Yes, uses the built-in AI allowance
Access
Gmail modify; Linear write

Send this to your assistant

Create a ClickRuntime automation: every 5 minutes, read new Gmail messages labelled Support. Have AI write a title, description and priority, check Linear for a similar open issue, and either create the issue or comment on the existing one.

Paste it into your assistant. It tells you what it will send or change before it runs live.

First time? Adding ClickRuntime to your assistant takes about two minutes.

Why use it

Why teams use this automation

A two-person SaaS team gets bug reports and feature requests by email. The founder reads them between calls, means to copy the good ones into Linear, and often doesn't. Three customers report the same broken export over a week, and each email sits in a different thread. When the engineer finally hears about it, nobody can say how many people were affected or who to tell when it is fixed.

Turning each labelled email into a tidy Linear issue, or a comment on the one that already exists, means customer reports reach the people who fix things the same hour they arrive, and duplicate reports add weight instead of noise.

What you get out of it

  • Reports reach engineering the same hour

    Nobody has to forward or retype an email. The issue appears in Linear minutes after the customer hits send, while the details are fresh.

  • Duplicates become evidence

    When a second customer reports the same problem, it is added as a comment on the existing issue. You can see at a glance how many people a bug affects, which makes prioritising easier.

  • Clean titles from messy emails

    Customers write long, friendly emails with the actual problem in the third paragraph. The issue gets a short title and a focused description, with the original sender noted so you can follow up.

  • A priority to start from

    Each issue arrives with a suggested priority based on what the customer describes. Data loss and outages rise to the top, while wording tweaks wait their turn.

  • Every customer gets an answer

    Because each issue records who reported it, closing the issue tells you exactly who to email back. Customers who reported a bug hear when it is fixed.

How it works

What happens, step by step

  1. Every 5 minutes, ClickRuntime looks for new Gmail messages with your Support label.

  2. AI reads each one and writes a short title, a clear description and a suggested priority.

  3. It searches Linear for a similar open issue and adds a comment there, or creates a new issue if none matches.

  4. The email is then marked as done in Gmail, so the same message is never turned into an issue twice.

Before it runs live

  • Connect Google through your own Google app (a one-time, 10-minute setup), so it works with your own Gmail
  • Connect Linear

What you get

RunsEvery 5 minutes
Turn support emails into Linear issuestoday, 9:00Succeeded
Linear · SupportCSV export times out for workspaces over 10k rows (High). Reported by ops@contoso.com

Build your own

Need it to work differently?

This template is a starting point. Copy the prompt and change it, or describe a different automation from scratch, with your own conditions, more apps or an AI step. Your assistant writes it, tests it and runs it on ClickRuntime.
  • Your own rules

    Conditions, thresholds, filters and exceptions, written the way you'd explain them to a colleague.

  • Any number of apps

    One automation can read from one app and update several others. Over 248 apps are ready, and anything with an API works too.

  • AI where it helps

    Summaries, classification, extraction and drafts use ClickRuntime's built-in AI, with no extra key.

  • On a schedule or on each event

    Runs as often as every 5 minutes, or the moment an app sends an event, and keeps track of what it already handled.

Changes you can ask for

  • Act only on the items that match your own rules, and skip the rest
  • Change what the AI looks for, or how it writes the result
  • Add another app, for example also send it to Slack
  • Combine it with other Gmail and Linear steps into one automation

Under the hood

The code that runs this automation

This is the Python script that runs each time the automation starts. Your AI assistant writes it for you when you send the prompt, and you allow each step in your assistant. To change how the automation works, describe the change to your assistant and it updates the script for you. For every function it can use, see the script reference.
support_emails_in_gmail_become_linear_issues.pyexample
from google.oauth2.credentials import Credentials
from googleapiclient.discovery import build
from clickruntime import on_trigger, credentials, http, ai, report_fetched
TEAM_ID, DONE_LABEL = "your-linear-team-id", "your-processed-label-id"
SCHEMA = {"type": "object", "properties": {"title": {"type": "string"}, "description": {"type": "string"}, "priority": {"type": "integer"}}, "required": ["title", "description", "priority"]}

def linear(query, variables):
    return http.post("https://api.linear.app/graphql", headers={"Authorization": credentials.secret("LINEAR_API_KEY")}, json={"query": query, "variables": variables}).json()["data"]

@on_trigger
def run(event):
    gmail = build("gmail", "v1", credentials=Credentials(credentials.connection("google", "work")), cache_discovery=False)
    msgs = gmail.users().messages().list(userId="me", q="label:support -label:linear-done").execute().get("messages", [])
    report_fetched(len(msgs))
    if not msgs: return {"summary": "Nothing new"}
    for m in msgs:
        msg = gmail.users().messages().get(userId="me", id=m["id"], format="full").execute()
        sender = next(h["value"] for h in msg["payload"]["headers"] if h["name"] == "From")
        try:
            d = ai.generate(f"Support email from {sender}:\n{msg['snippet'][:2000]}", system="Write a Linear issue. Priority 1 urgent to 4 low.", json_schema=SCHEMA).json
        except ai.AIError:
            d = {"title": msg["snippet"][:80], "description": msg["snippet"], "priority": 3}
        found = linear("query($t: String!) { issueSearch(query: $t, first: 1, filter: {state: {type: {nin: [\"completed\", \"canceled\"]}}}) { nodes { id } } }", {"t": d["title"]})["issueSearch"]["nodes"]
        body = f"{d['description']}\n\nReported by {sender}"
        if found:
            linear("mutation($i: CommentCreateInput!) { commentCreate(input: $i) { success } }", {"i": {"issueId": found[0]["id"], "body": body}})
        else:
            linear("mutation($i: IssueCreateInput!) { issueCreate(input: $i) { success } }", {"i": {"teamId": TEAM_ID, "title": d["title"], "description": body, "priority": d["priority"]}})
        gmail.users().messages().modify(userId="me", id=m["id"], body={"addLabelIds": [DONE_LABEL]}).execute()
    return {"summary": f"{len(msgs)} emails handled"}

FAQ

Common questions

Which emails does it pick up?
Only messages carrying your Support label. You can apply the label by hand or with a Gmail filter on your support address, and once handled the email is marked so it is never processed twice.
How does it decide an issue already exists?
It searches your open Linear issues using the suggested title. If a close match turns up, the email is added as a comment there instead of creating a new issue.
Does the customer's email address end up in Linear?
The sender's address is included in the issue or comment so you know whom to reply to. If you prefer, it can be left out and you can find the original in Gmail instead.
What permissions does it need?
Gmail modify; Linear write. Nothing else in your accounts is used.
Does it need AI?
Yes. It uses ClickRuntime's built-in AI, so you don't need an OpenAI or Anthropic key. Every plan includes a monthly AI allowance.
How many runs does it use?
One run each time it checks. Checks that find nothing new and stop right away aren't counted.
Can I change how it works?
Yes. Describe the change to your AI assistant, for example a different schedule, channel or filter. It updates the automation, tests it and tells you what changed.

Set up “Turn support emails into Linear issues” from your assistant

Copy the prompt above, or connect your assistant first. Free plan, no credit card.