Escalate Freshdesk bug tickets to Linear issues
Every 15 minutes, any Freshdesk ticket tagged as a bug is filed as a Linear issue and linked back, so engineering picks it up without support double entering.
Build me a code workflow that runs on a cron every 15 minutes and escalates new Freshdesk bug tickets into Linear issues, then closes the loop back on the Freshdesk ticket so it never gets escalated twice.
Step 1. Find new bug tickets. Call Freshdesk Filter Tickets with a Lucene-style query that matches open tickets tagged as bugs that have not already been escalated. Use a query like tag:"bug" AND status:2 AND NOT tag:"escalated-to-linear" (status 2 is Freshdesk's "open"). Page through results if there are more than 30.
Step 2. For each matching ticket, call Freshdesk View Ticket to load the full body and requester information. Include the requester so we have their name and email.
Step 3. Create a Linear issue with Linear Create Issue. Use the Freshdesk ticket subject as the issue title. The description should be Markdown and include: the ticket body, the requester's name and email, and a link back to the Freshdesk ticket in the form https://<subdomain>.freshdesk.com/a/tickets/<ticketId>. Map priority as urgent -> 1, high -> 2, medium -> 3, low -> 4 (Linear priorities: 0 No Priority, 1 Urgent, 2 High, 3 Normal, 4 Low). Let the user configure which Linear team the issue goes into when they set the workflow up.
Step 4. Close the loop on Freshdesk in two calls. First, call Freshdesk Add Note to Ticket with private set to true and a short body containing the new Linear issue URL, so agents can see the link but the customer cannot. Second, call Freshdesk Update Ticket to add the tag "escalated-to-linear" to the existing tags array (do not overwrite the current tags, merge into them). This guard tag is what the Filter Tickets query in Step 1 excludes, so the same ticket cannot be escalated twice.
Requirements: this is a deterministic code workflow, not an agent. Iterate over the matched tickets in a plain loop. If Linear Create Issue fails for one ticket, keep going with the others and log the error rather than halting the whole run. Do not add the escalated-to-linear tag or the note unless the Linear issue was actually created.
Inputs the user should be able to configure: the Linear team (required), an optional Linear label to apply to all created issues, the cron cadence (default every 15 minutes), and optionally the Freshdesk tag that means "bug" in case a team uses a different label.
Additional information
What does this prompt do?
- Checks Freshdesk every 15 minutes for open tickets tagged as bugs that have not already been sent to engineering.
- Files each one as a new Linear issue with the ticket subject, the full description, the reporter's info, and a link back to the Freshdesk ticket.
- Maps the ticket's priority so urgent bugs stay urgent in Linear and low priority stays low.
- Posts the new Linear link as a private note on the Freshdesk ticket and adds a follow-up tag so the same ticket never gets escalated twice.
What do I need to use this?
- A Freshdesk account with permission to read tickets, add private notes, and edit tags.
- A Linear workspace, and the team you want new bug issues created in.
- A "bug" tag applied to Freshdesk tickets you want engineering to see.
How can I customize it?
- Change how often the check runs. Fifteen minutes is a good default, but hourly or every few minutes both work.
- Adjust which Freshdesk tags or statuses count as "ready to escalate," for example limiting it to urgent bugs only.
- Pick the Linear team, and optionally a default label or assignee, so new issues land in the right place.
- Change how Freshdesk priorities line up with Linear priorities if your team uses a different scale.
Frequently asked questions
Will the same ticket get escalated more than once?
Where does the Linear link show up on the Freshdesk ticket?
What if a ticket is retagged from bug to something else later?
Can I choose which Linear team the issues get filed into?
Do I need Freshdesk on a paid plan for this?
Related templates
Stop double entering bug reports.
Connect Freshdesk and Linear once, and Geni escalates new bug tickets into Linear every 15 minutes.