The workflow JSON
Copy or download the full n8n JSON below. Paste it into a new n8n workflow, add your credentials, activate. Full import guide →
{
"name": "04 - Ticketing System Integration",
"nodes": [
{
"parameters": {
"path": "create-ticket",
"responseMode": "responseNode",
"options": {
"rawBody": true
}
},
"id": "webhook-trigger",
"name": "Webhook Trigger",
"type": "n8n-nodes-base.webhook",
"typeVersion": 1,
"position": [
250,
300
]
},
{
"parameters": {
"functionCode": "// Extract response data\nconst responseData = $input.first().json.responseData;\nreturn [{ json: responseData }];"
},
"id": "extract-data",
"name": "Extract Data",
"type": "n8n-nodes-base.code",
"typeVersion": 2,
"position": [
450,
300
]
},
{
"parameters": {
"resource": "ticket",
"operation": "create",
"subject": "={{ $json.subject }}",
"comment": "=**Original Customer Email:**\nFrom: {{ $json.fromName }} ({{ $json.from }})\nDate: {{ $json.receivedAt }}\n\n{{ $json.originalBody }}\n\n---\n\n**AI-Generated Response:**\n{{ $json.generatedResponse }}\n\n---\n\n**Classification:**\n- Urgency: {{ $json.urgency }}\n- Category: {{ $json.category }}\n- Sentiment: {{ $json.sentiment }}\n- Language: {{ $json.language }}",
"additionalFields": {
"priority": "={{ $json.urgency === 'high' ? 'urgent' : $json.urgency === 'medium' ? 'high' : 'normal' }}",
"tags": "={{ $json.category }},ai-generated,{{ $json.sentiment }}",
"customFields": "={{ JSON.stringify({ emailId: $json.emailId, requiresApproval: $json.requiresApproval }) }}"
}
},
"id": "create-zendesk-ticket",
"name": "Create Zendesk Ticket",
"type": "n8n-nodes-base.zendesk",
"typeVersion": 1,
"position": [
650,
200
],
"credentials": {
"zendeskApi": {
"name": "<your credential>"
}
}
},
{
"parameters": {
"method": "POST",
"url": "=https://{{ $env.FRESHDESK_DOMAIN }}/api/v2/tickets",
"authentication": "genericCredentialType",
"genericAuthType": "httpBasicAuth",
"sendBody": true,
"specifyBody": "json",
"jsonBody": "={\n \"subject\": \"{{ $json.subject }}\",\n \"description\": \"**Original Customer Email:**\\nFrom: {{ $json.fromName }} ({{ $json.from }})\\n\\n{{ $json.originalBody }}\\n\\n---\\n\\n**AI-Generated Response:**\\n{{ $json.generatedResponse }}\",\n \"email\": \"{{ $json.from }}\",\n \"priority\": {{ $json.urgency === 'high' ? 3 : $json.urgency === 'medium' ? 2 : 1 }},\n \"status\": 2,\n \"tags\": [\"{{ $json.category }}\", \"ai-generated\", \"{{ $json.sentiment }}\"]\n}",
"options": {}
},
"id": "create-freshdesk-ticket",
"name": "Create Freshdesk Ticket",
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4,
"position": [
650,
400
],
"credentials": {
"httpBasicAuth": {
"name": "<your credential>"
}
}
},
{
"parameters": {
"functionCode": "// Route to appropriate ticketing system\nconst ticketingSystem = process.env.TICKETING_SYSTEM || 'zendesk';\nconst data = $input.first().json;\n\nif (ticketingSystem === 'zendesk') {\n return [[{ json: data }], []];\n} else if (ticketingSystem === 'freshdesk') {\n return [[], [{ json: data }]];\n} else {\n // Default to zendesk\n return [[{ json: data }], []];\n}"
},
"id": "route-ticketing",
"name": "Route to Ticketing System",
"type": "n8n-nodes-base.code",
"typeVersion": 2,
"position": [
450,
300
]
},
{
"parameters": {
"functionCode": "// Combine ticket data with response data\nconst responseData = $input.first().json;\nconst ticketData = responseData.ticket || responseData;\n\n// Extract ticket ID based on system\nlet ticketId = ticketData.id || ticketData.ticket?.id;\nlet ticketUrl = '';\n\nconst ticketingSystem = process.env.TICKETING_SYSTEM || 'zendesk';\n\nif (ticketingSystem === 'zendesk') {\n ticketUrl = `https://${process.env.ZENDESK_SUBDOMAIN}.zendesk.com/agent/tickets/${ticketId}`;\n} else if (ticketingSystem === 'freshdesk') {\n ticketUrl = `https://${process.env.FRESHDESK_DOMAIN}/a/tickets/${ticketId}`;\n}\n\nconst combinedData = {\n ...responseData,\n ticketId: ticketId,\n ticketUrl: ticketUrl,\n ticketCreatedAt: new Date().toISOString()\n};\n\nreturn [{ json: combinedData }];"
},
"id": "combine-ticket-data",
"name": "Combine Ticket Data",
"type": "n8n-nodes-base.code",
"typeVersion": 2,
"position": [
850,
300
]
},
{
"parameters": {
"method": "POST",
"url": "={{ $env.N8N_BASE_URL }}/webhook/review-response",
"authentication": "genericCredentialType",
"genericAuthType": "httpHeaderAuth",
"sendBody": true,
"bodyParameters": {
"parameters": [
{
"name": "ticketData",
"value": "={{ $json }}"
}
]
},
"options": {}
},
"id": "send-to-review",
"name": "Send to Review Workflow",
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 4,
"position": [
1050,
300
],
"credentials": {
"httpHeaderAuth": {
"name": "<your credential>"
}
}
},
{
"parameters": {
"respondWith": "json",
"responseBody": "={{ { success: true, ticketId: $json.ticketId, ticketUrl: $json.ticketUrl } }}"
},
"id": "respond-webhook",
"name": "Respond to Webhook",
"type": "n8n-nodes-base.respondToWebhook",
"typeVersion": 1,
"position": [
1250,
300
]
},
{
"parameters": {
"content": "## Ticketing System Integration\\n\\nThis workflow:\\n1. Receives response data from LLM workflow\\n2. Routes to appropriate ticketing system\\n3. Creates ticket with email and AI response\\n4. Sends to review workflow\\n\\n**Supported Systems:**\\n- Zendesk\\n- Freshdesk\\n- Linear (add custom node)\\n- Jira (add custom node)\\n\\n**Configuration:**\\nSet TICKETING_SYSTEM in .env",
"height": 400,
"width": 300
},
"id": "sticky-note",
"name": "Sticky Note",
"type": "n8n-nodes-base.stickyNote",
"typeVersion": 1,
"position": [
240,
500
]
}
],
"connections": {
"Webhook Trigger": {
"main": [
[
{
"node": "Extract Data",
"type": "main",
"index": 0
}
]
]
},
"Extract Data": {
"main": [
[
{
"node": "Route to Ticketing System",
"type": "main",
"index": 0
}
]
]
},
"Route to Ticketing System": {
"main": [
[
{
"node": "Create Zendesk Ticket",
"type": "main",
"index": 0
}
],
[
{
"node": "Create Freshdesk Ticket",
"type": "main",
"index": 0
}
]
]
},
"Create Zendesk Ticket": {
"main": [
[
{
"node": "Combine Ticket Data",
"type": "main",
"index": 0
}
]
]
},
"Create Freshdesk Ticket": {
"main": [
[
{
"node": "Combine Ticket Data",
"type": "main",
"index": 0
}
]
]
},
"Combine Ticket Data": {
"main": [
[
{
"node": "Send to Review Workflow",
"type": "main",
"index": 0
}
]
]
},
"Send to Review Workflow": {
"main": [
[
{
"node": "Respond to Webhook",
"type": "main",
"index": 0
}
]
]
}
},
"settings": {
"executionOrder": "v1"
}
}
Credentials you'll need
Each integration node will prompt for credentials when you import. We strip credential IDs before publishing — you'll add your own.
httpBasicAuthhttpHeaderAuthzendeskApi
For the full experience including quality scoring and batch install features for each workflow upgrade to Pro
About this workflow
04 - Ticketing System Integration. Uses zendesk, httpRequest. Webhook trigger; 9 nodes.
Source: https://github.com/Yasc-ine/ai-customer-support-n8n/blob/0f5cc550ae8476b0ef1871c65b04d3323b79f54b/workflows/04-ticketing.json — original creator credit. Request a take-down →
Related workflows
Workflows that share integrations, category, or trigger type with this one. All free to copy and import.
Portfolio Orchestrator. Uses httpRequest. Webhook trigger; 59 nodes.
jump-section: Comment Fix Pipeline. Uses httpRequest. Webhook trigger; 24 nodes.
GitHub Issues Router (Linear / Jira / ClickUp). Uses stickyNote, httpRequest, respondToWebhook. Webhook trigger; 23 nodes.
Form to CRM Lead Router (Pipedrive / HubSpot / Salesforce). Uses stickyNote, httpRequest, respondToWebhook. Webhook trigger; 22 nodes.
Calendly to CRM Sync (Pipedrive / HubSpot / Salesforce). Uses stickyNote, httpRequest, respondToWebhook. Webhook trigger; 22 nodes.