What this workflow does
- Zendesk customer reply (Webhook) receives the ticket ID, subject and requester from a Zendesk trigger.
- Get ticket comments (HTTP Request with your Zendesk credential) reads the thread.
- Find Shopify orders (HTTP Request, Shopify GraphQL Admin API) fetches the customer’s five most recent orders with items, fulfillment status and tracking. If the lookup fails, drafting continues and the note says so.
- Build drafting prompt (Code) stops unless the newest public comment came from the customer, then combines your tone guide, policy summaries, the last eight comments and the order data.
- Draft reply with Claude (HTTP Request) calls the Anthropic Messages API and returns strict JSON: the reply, questions answered, unverified items, sources and a confidence level.
- Parse draft (Code) handles refusals, truncated answers and API errors, catches bracketed notes the model forgot to list, and builds the internal note.
- Draft OK? (If) sends failures to Post drafting exception in Slack.
- Post draft as internal note (Zendesk) adds the draft to the ticket as an internal note, labeled “AI draft, check before sending”.
- Offer one-click send?, Agent approval in Slack, Approved? and Send approved reply give agents a send button for clean, high-confidence drafts only. The workflow waits up to eight hours. Declining or ignoring the message sends nothing.
Before you import
- A current n8n version with a public webhook URL.
- A Zendesk admin who can create webhooks and triggers, plus an API token.
- A Shopify Admin API access token with the
read_ordersscope. Existing custom apps created in the Shopify admin keep working, but since January 1, 2026 new apps must be created in Shopify’s Dev Dashboard, which issues a client ID and secret instead of showing a token. Check how you will get and refresh the token before setting up n8n’s Shopify Access Token credential. - An Anthropic API key. The template uses
claude-opus-5-5for drafting. - A Slack bot in your support and exceptions channels.
Setup
- Import the JSON and connect the Zendesk, Shopify, Anthropic and Slack credentials.
- In Zendesk, create a webhook to the production URL and a trigger for public comments by end users. The JSON body is in the sticky note.
- Replace
REPLACE_WITH_ZENDESK_SUBDOMAIN(two nodes) andREPLACE_WITH_SHOPwith your Zendesk and myshopify subdomains. - In Build drafting prompt, replace
STYLE,REPLACE_WITH_COMPANY_NAMEand the threePOLICIESlines with your real tone guide and policy summaries. - Replace
REPLACE_WITH_SLACK_SUPPORT_CHANNEL_IDandREPLACE_WITH_SLACK_EXCEPTIONS_CHANNEL_ID.
Test it
Open a test ticket from an email address that has a Shopify order and ask “where is my order?”. You should see an internal note within a minute. Then reply as the agent and confirm no new draft appears. Finally, ask about something the order data cannot answer and check that the draft contains a bracketed note and gets no send button.
Make it production-ready
- Pilot with three or four agents for two weeks and review every draft they flag as wrong, not just unhelpful.
- Remove the Slack approval branch entirely if you prefer agents to send every reply from Zendesk.
- Add an n8n error workflow and keep the HTTP retries. Zendesk and Shopify both rate limit by plan.
- Orders older than 60 days need Shopify’s
read_all_ordersscope, which Shopify may require you to request. - Log the draft and the reply actually sent at ticket solve to measure edit size, as the guide describes.
Read the full guide on AI support reply drafting for macro cleanup and pilot design, or ask Lumeor for help connecting Gorgias, Front or your billing system.