Draft Support Replies with Cited Sources Using Perplexity
An n8n workflow that takes each new support ticket, uses Perplexity to research an accurate answer against your public docs and the live web, and drops a cited draft reply into your helpdesk as an internal note — so agents send correct, sourced answers in a click instead of digging through documentation.
- 1
Catch the new ticket
Add a
Webhooknode and subscribe your helpdesk's 'ticket created' event. Extract the ticket ID, the customer's question and the requester's email with aSetnode. - 2
Research the answer with Perplexity
An
HTTP Requesttosonar-prosends the question with a system prompt to answer only from your docs, usingsearch_domain_filterset to your documentation domain. Ask for a concise answer plus the exact doc URLs used, and an explicit 'not covered' if it can't find it. - 3
Format the draft
A
Codenode builds the internal note: a suggested reply the agent can copy, followed by aSourceslist of the citation URLs so the agent can verify before sending. If the model returned 'not covered', it labels the note so the agent knows to handle it manually. - 4
Post as an internal note
An
HTTP Requestcalls your helpdesk's add-internal-comment endpoint with the ticket ID and the draft. Because it's internal, the customer never sees it — only the agent working the ticket does. - 5
Flag low-confidence tickets
An
IFnode routes 'not covered' tickets to aSlackchannel so a senior agent or the docs owner can jump in. This turns gaps into a backlog of documentation to write, closing the loop over time.
Frequently asked questions
How do I keep answers grounded in MY documentation?
Point Perplexity at your domain. Sonar supports a `search_domain_filter` so you can restrict results to your docs site (and a trusted source or two). The prompt also instructs it to answer only from those sources and to say 'not covered in docs' rather than improvise — which keeps agents from sending confident nonsense.
Does it auto-reply to customers?
No — and that's deliberate. The draft lands as an internal note, not a customer-facing message. An agent reads it, checks the citations, edits if needed, and sends. Support is exactly where an unreviewed AI reply can damage trust, so a human stays in the loop by design.
Which helpdesks does this fit?
Any with an API or n8n node — Zendesk, Freshdesk, Gorgias, Help Scout, Intercom. The example posts an internal note via a generic HTTP Request; swap in your helpdesk's 'add internal comment' endpoint. The trigger is a new-ticket webhook, which every major helpdesk supports.