HelpDesk 工作流
高级
这是一个Internal Wiki, AI Chatbot领域的自动化工作流,包含 25 个节点。主要使用 If, Slack, Webhook, GmailTool, GoogleDocsTool 等节点。 基于AI的Slack内部帮助台,集成GPT-4o和邮件升级
前置要求
- •Slack Bot Token 或 Webhook URL
- •HTTP Webhook 端点(n8n 会自动生成)
- •Google 账号和 Gmail API 凭证
- •Google Sheets API 凭证
- •OpenAI API Key
使用的节点 (25)
工作流预览
可视化展示节点连接关系,支持缩放和平移
导出工作流
复制以下 JSON 配置到 n8n 导入,即可使用此工作流
{
"id": "UVicuO5jaXNi4v7p",
"meta": {
"instanceId": "0c0152906db501342bff43248e195ce72d840c2129116cc346a96ce2be086bbd",
"templateCredsSetupCompleted": true
},
"name": "HelpDesk 工作流",
"tags": [],
"nodes": [
{
"id": "1b51fec7-a603-4e45-bff6-5921f1c62c9b",
"name": "发送初始消息",
"type": "n8n-nodes-base.slack",
"position": [
2640,
540
],
"webhookId": "5fcad12d-52dc-428e-b4cb-b1da006110a2",
"parameters": {
"text": "=:alert: I'm on it {{ $json.real_name }}! checking my data...one second please.....",
"select": "channel",
"channelId": {
"__rl": true,
"mode": "id",
"value": "={{ $('Webhook3').item.json.body.event.channel }}"
},
"otherOptions": {
"includeLinkToWorkflow": false
}
},
"credentials": {
"slackApi": {
"id": "",
"name": "Slack account"
}
},
"typeVersion": 2.1
},
{
"id": "65d12dcc-c8c5-4726-8c37-7ed4a6f57989",
"name": "发送消息",
"type": "n8n-nodes-base.slack",
"position": [
3600,
520
],
"webhookId": "e5d44cc2-1567-4308-b318-da5bd75507ba",
"parameters": {
"text": "={{ $('AI Agent2').item.json.output }}",
"select": "channel",
"channelId": {
"__rl": true,
"mode": "id",
"value": "={{ $('Webhook3').item.json.body.event.channel }}"
},
"otherOptions": {
"mrkdwn": false,
"botProfile": {
"imageValues": {
"icon_emoji": ":robot_face:",
"profilePhotoType": "emoji"
}
},
"includeLinkToWorkflow": false
}
},
"credentials": {
"slackApi": {
"id": "",
"name": "Slack account"
}
},
"typeVersion": 2.1
},
{
"id": "99129c7e-d07f-4bd6-a087-5e585cc1ccea",
"name": "便签 3",
"type": "n8n-nodes-base.stickyNote",
"position": [
2800,
260
],
"parameters": {
"color": 6,
"width": 488,
"height": 404,
"content": ""
},
"typeVersion": 1
},
{
"id": "739c1571-8c76-4040-af67-1e7bf1161938",
"name": "便签 4",
"type": "n8n-nodes-base.stickyNote",
"position": [
2380,
260
],
"parameters": {
"color": 2,
"width": 417,
"height": 437,
"content": ""
},
"typeVersion": 1
},
{
"id": "d708dbde-891a-49ae-b18a-d1b5ec422aff",
"name": "便签6",
"type": "n8n-nodes-base.stickyNote",
"position": [
2700,
740
],
"parameters": {
"color": 6,
"width": 365,
"height": 559,
"content": ""
},
"typeVersion": 1
},
{
"id": "b78f98ca-cd14-4a92-88e4-296e5f5dee47",
"name": "便签7",
"type": "n8n-nodes-base.stickyNote",
"position": [
2140,
880
],
"parameters": {
"color": 5,
"width": 545,
"height": 279,
"content": ""
},
"typeVersion": 1
},
{
"id": "0109acf3-ef56-4f03-8d63-6f57b1712b58",
"name": "OpenAI 聊天模型3",
"type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
"position": [
2540,
920
],
"parameters": {
"model": "gpt-4o",
"options": {}
},
"credentials": {
"openAiApi": {
"id": "",
"name": "OpenAi account"
}
},
"typeVersion": 1
},
{
"id": "c1a090b9-48c1-4f1d-8792-419f5b1a08ae",
"name": "### 替换 Airtable 连接",
"type": "n8n-nodes-base.stickyNote",
"position": [
1280,
260
],
"parameters": {
"color": 2,
"width": 455,
"height": 497,
"content": ""
},
"typeVersion": 1
},
{
"id": "03c655bd-2598-41c2-992d-c8fc96089327",
"name": "Webhook3",
"type": "n8n-nodes-base.webhook",
"position": [
1400,
580
],
"webhookId": "",
"parameters": {
"path": "",
"options": {
"noResponseBody": true
},
"httpMethod": "POST"
},
"typeVersion": 2
},
{
"id": "a45eaaff-cdd0-4b16-b28d-27ad9f3fb887",
"name": "departmentsEmails2",
"type": "n8n-nodes-base.googleSheetsTool",
"position": [
3680,
1000
],
"parameters": {
"options": {},
"sheetName": {
"__rl": true,
"mode": "list",
"value": "gid=0",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1mmF1uXpQS0O28KcVAzcvrIaoMbJGS3norTWXbrstDg8/edit#gid=0",
"cachedResultName": "Sheet1"
},
"documentId": {
"__rl": true,
"mode": "list",
"value": "1mmF1uXpQS0O28KcVAzcvrIaoMbJGS3norTWXbrstDg8",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1mmF1uXpQS0O28KcVAzcvrIaoMbJGS3norTWXbrstDg8/edit?usp=drivesdk",
"cachedResultName": "departmentsEmails"
}
},
"credentials": {
"googleSheetsOAuth2Api": {
"id": "",
"name": "Google Sheets account"
}
},
"typeVersion": 4.6
},
{
"id": "2fd2ee04-692a-4556-9018-9c9cbc4a5b29",
"name": "AI 代理2",
"type": "@n8n/n8n-nodes-langchain.agent",
"position": [
2920,
520
],
"parameters": {
"text": "={{ $('Webhook3').item.json.body.event.blocks[0].elements[0].elements[0].text }}",
"options": {
"systemMessage": "=Role:\nYou are a helpful assistant that must strictly follow the instructions below.\n\nInstructions:\n\n- Before doing anything, check if the question is related to one of the topics mentioned in the `HeadersList` tool or similar to the header topic.\n 1- if not, then reply directly that you cant help with that.\n 2- if yes use the `Handbook` tool check twice if answer exists then go further with the below instructions.\n- Use `user_question` as the user's original inquiry when composing an email.\n\n- Use only the `Handbook` tool info.\n- This is your only source of truth.\n- Do not use general knowledge, memory, or assumptions.\n\nAnswering Rules:\n\n1. Read the `Handbook` content carefully before answering.\n2. If the answer exists, respond using only that information.\n3. If not found, reply as follows:\n - if HR or policy related (e.g. benefits, leave, remote work):\n > Unfortunately I can't help you with that. Would you like me to send an email to the HR department to update our policy?\n\n - if technical related (e.g. tools, devices..etc):\n > Unfortunately I can't help you with that. It seems like an IT or Technical question. Would you like me to notify the IT department about your issue?\n\n - if Other topics:\n > Unfortunately I can't help you with that. It's not a HR related question.\n\n4. Never send an email unless the user confirm that.\n\nEmail Logic:\n\n- If user says no, ask if you can help with something else.\n- If user says yes:\n 1. Add to the email subject:\n - “Question regarding Company Policy/ IT”\n 2. Use the `departmentsemails2` tool to get the contact's full name and email.\n 3. Write a professional HTML email including:\n - The questioner's name: {{ $('Slack4').item.json.real_name }} and Their original question.\n - A note asking to update documentation ,or if updated get the email address of the IT department from `departmentsemails2` and tell him to send the updates to that email address."
},
"promptType": "define"
},
"typeVersion": 2
},
{
"id": "68a4720c-8ea6-4189-a1b6-4d3d76ce7743",
"name": "Slack4",
"type": "n8n-nodes-base.slack",
"position": [
2480,
540
],
"webhookId": "2f23a022-42c2-4b66-9142-91ca0b152fb3",
"parameters": {
"user": {
"__rl": true,
"mode": "id",
"value": "={{ $('Webhook3').item.json.body.event.user }}"
},
"resource": "user",
"operation": "getProfile"
},
"credentials": {
"slackApi": {
"id": "",
"name": "Slack account"
}
},
"typeVersion": 2.3
},
{
"id": "2583abdd-542c-433f-9ad7-5034f50d5128",
"name": "便签",
"type": "n8n-nodes-base.stickyNote",
"position": [
3080,
740
],
"parameters": {
"color": 5,
"width": 300,
"height": 420,
"content": ""
},
"typeVersion": 1
},
{
"id": "da772f0b-3d1f-4626-8ec1-4d5b15017f4f",
"name": "便签 5",
"type": "n8n-nodes-base.stickyNote",
"position": [
3400,
740
],
"parameters": {
"color": 4,
"width": 500,
"height": 400,
"content": ""
},
"typeVersion": 1
},
{
"id": "0eb87a3f-ff47-4207-8f6b-6de8122f6aaa",
"name": "Handbook",
"type": "n8n-nodes-base.googleDocsTool",
"position": [
3220,
1020
],
"parameters": {
"operation": "get",
"documentURL": ""
},
"credentials": {
"googleDocsOAuth2Api": {
"id": "",
"name": ""
}
},
"typeVersion": 2
},
{
"id": "8f53b025-8563-42e6-b1f8-a879a82843f5",
"name": "无操作,不执行任何操作",
"type": "n8n-nodes-base.noOp",
"position": [
2440,
740
],
"parameters": {},
"typeVersion": 1
},
{
"id": "e263978a-a326-4f06-ac55-8bb0b282de11",
"name": "Simple Memory2",
"type": "@n8n/n8n-nodes-langchain.memoryBufferWindow",
"position": [
2840,
1180
],
"parameters": {
"sessionKey": "={{ $('Webhook3').item.json.body.event.channel }}",
"sessionIdType": "customKey"
},
"typeVersion": 1.3
},
{
"id": "7f1b762f-5a37-400c-ba1b-b29627202173",
"name": "发送电子邮件",
"type": "n8n-nodes-base.gmailTool",
"position": [
4060,
1020
],
"webhookId": "f4435dbb-cd87-430c-ae2b-982d9ee888f4",
"parameters": {
"sendTo": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('To', ``, 'string') }}",
"message": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Message', ``, 'string') }}",
"options": {
"appendAttribution": false
},
"subject": "={{ /*n8n-auto-generated-fromAI-override*/ $fromAI('Subject', ``, 'string') }}"
},
"credentials": {
"gmailOAuth2": {
"id": "",
"name": ""
}
},
"typeVersion": 2.1
},
{
"id": "e0f87e17-ef31-4a54-80f0-34248f791cb9",
"name": "删除初始消息",
"type": "n8n-nodes-base.slack",
"position": [
3380,
520
],
"webhookId": "e9c00bf9-f666-4bf8-802f-9adca0b51928",
"parameters": {
"select": "channel",
"channelId": {
"__rl": true,
"mode": "id",
"value": "={{ $('Send Initial Message').item.json.channel }}"
},
"operation": "delete",
"timestamp": "={{ $('Send Initial Message').item.json[\"message_timestamp\"] }}"
},
"credentials": {
"slackApi": {
"id": "",
"name": "Slack account"
}
},
"typeVersion": 2.1
},
{
"id": "50b7ad06-c426-42f0-99f1-8b67e7ee5771",
"name": "便签8",
"type": "n8n-nodes-base.stickyNote",
"position": [
1740,
260
],
"parameters": {
"color": 5,
"width": 640,
"height": 500,
"content": ""
},
"typeVersion": 1
},
{
"id": "fbd12874-c160-4049-9a0d-b931a4d10307",
"name": "是机器人吗?",
"type": "n8n-nodes-base.if",
"position": [
1800,
580
],
"parameters": {
"options": {},
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "dfde27bf-8d61-4ea6-9e7e-6280508c4156",
"operator": {
"type": "object",
"operation": "notExists",
"singleValue": true
},
"leftValue": "={{ $json.body.event.bot_profile }}",
"rightValue": ""
},
{
"id": "809f8f96-1012-43f7-82a0-a037bce19809",
"operator": {
"type": "object",
"operation": "notExists",
"singleValue": true
},
"leftValue": "={{ $json.body.event.previous_message.bot_profile }}",
"rightValue": ""
},
{
"id": "4f238cc2-aea3-40fa-8b35-264cabb65c65",
"operator": {
"type": "string",
"operation": "notExists",
"singleValue": true
},
"leftValue": "={{ $json.body.event.bot_id }}",
"rightValue": ""
}
]
}
},
"typeVersion": 2.2
},
{
"id": "6484a188-e5d4-4584-94a4-f2bf2a2e4028",
"name": "便签 2",
"type": "n8n-nodes-base.stickyNote",
"position": [
3320,
260
],
"parameters": {
"color": 2,
"width": 511,
"height": 431,
"content": ""
},
"typeVersion": 1
},
{
"id": "8cc71213-9b70-42e5-91c1-1300a3423fb0",
"name": "便签1",
"type": "n8n-nodes-base.stickyNote",
"position": [
3940,
760
],
"parameters": {
"color": 3,
"width": 340,
"height": 420,
"content": ""
},
"typeVersion": 1
},
{
"id": "d1fc8d25-e337-4e54-b1c3-48203e4467b2",
"name": "HeadersList",
"type": "n8n-nodes-base.googleSheetsTool",
"position": [
3620,
1420
],
"parameters": {
"options": {},
"sheetName": {
"__rl": true,
"mode": "list",
"value": "gid=0",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1I9zDnOvsJIxbR6IgYDPQFYcAONqDfKoH5jVsD2Otvv8/edit#gid=0",
"cachedResultName": "Sheet1"
},
"documentId": {
"__rl": true,
"mode": "list",
"value": "1I9zDnOvsJIxbR6IgYDPQFYcAONqDfKoH5jVsD2Otvv8",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/1I9zDnOvsJIxbR6IgYDPQFYcAONqDfKoH5jVsD2Otvv8/edit?usp=drivesdk",
"cachedResultName": "n8n / Helpdesk / Header list"
}
},
"credentials": {
"googleSheetsOAuth2Api": {
"id": "",
"name": "Google Sheets account"
}
},
"typeVersion": 4.6
},
{
"id": "0b86c875-b559-4cde-a13e-3b6de7780ab6",
"name": "便签10",
"type": "n8n-nodes-base.stickyNote",
"position": [
3400,
1160
],
"parameters": {
"color": 4,
"width": 500,
"height": 400,
"content": ""
},
"typeVersion": 1
}
],
"active": true,
"pinData": {},
"settings": {
"executionOrder": "v1"
},
"versionId": "63459a43-609a-45c6-ab4f-a0ca6705ed53",
"connections": {
"Bot?": {
"main": [
[
{
"node": "Slack4",
"type": "main",
"index": 0
}
],
[
{
"node": "No Operation, do nothing",
"type": "main",
"index": 0
}
]
]
},
"Slack4": {
"main": [
[
{
"node": "Send Initial Message",
"type": "main",
"index": 0
}
]
]
},
"Handbook": {
"ai_tool": [
[
{
"node": "AI Agent2",
"type": "ai_tool",
"index": 0
}
]
]
},
"Webhook3": {
"main": [
[
{
"node": "Bot?",
"type": "main",
"index": 0
}
]
]
},
"AI Agent2": {
"main": [
[
{
"node": "Delete Initial Message",
"type": "main",
"index": 0
}
]
]
},
"Send Email": {
"ai_tool": [
[
{
"node": "AI Agent2",
"type": "ai_tool",
"index": 0
}
]
]
},
"HeadersList": {
"ai_tool": [
[
{
"node": "AI Agent2",
"type": "ai_tool",
"index": 0
}
]
]
},
"Simple Memory2": {
"ai_memory": [
[
{
"node": "AI Agent2",
"type": "ai_memory",
"index": 0
}
]
]
},
"OpenAI Chat Model3": {
"ai_languageModel": [
[
{
"node": "AI Agent2",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"departmentsEmails2": {
"ai_tool": [
[
{
"node": "AI Agent2",
"type": "ai_tool",
"index": 0
}
]
]
},
"Send Initial Message": {
"main": [
[
{
"node": "AI Agent2",
"type": "main",
"index": 0
}
]
]
},
"Delete Initial Message": {
"main": [
[
{
"node": "Send Message",
"type": "main",
"index": 0
}
]
]
}
}
}常见问题
如何使用这个工作流?
复制上方的 JSON 配置代码,在您的 n8n 实例中创建新工作流并选择「从 JSON 导入」,粘贴配置后根据需要修改凭证设置即可。
这个工作流适合什么场景?
高级 - 内部知识库, AI 聊天机器人
需要付费吗?
本工作流完全免费,您可以直接导入使用。但请注意,工作流中使用的第三方服务(如 OpenAI API)可能需要您自行付费。
相关工作流推荐
在可视化参考库中探索n8n节点
在可视化参考库中探索n8n节点
If
Ftp
Set
+93
113 节点I versus AI
其他
构建用于Slack候选人评估的AI驱动聊天机器人
AI简历分析与候选人评估:Slack和Google表格集成
If
Code
Slack
+12
29 节点Trung Tran
AI 聊天机器人
创建具有GPT-4o聊天界面和可视化报告的交互式Snowflake数据浏览器
创建具有GPT-4o聊天界面和可视化报告的交互式Snowflake数据浏览器
If
Set
Webhook
+11
28 节点Mark Shcherbakov
内部知识库
Slack AI 聊天机器人:上下文感知,回复提及和私信
Slack AI 聊天机器人:上下文感知,回复提及和私信
If
Set
Slack
+9
19 节点Theo Marcadet
内部知识库
高级多代理AI个人助手(250+任务能力,WhatsApp + GPT)
高级多代理AI个人助手(250+任务能力,WhatsApp + GPT)
Set
Switch
Whats App
+26
213 节点Electrabot
个人效率
基于AI的WhatsApp销售机器人,带Google Sheets查询功能
使用DeepSeek AI、Google Sheets和Gmail通知自动化WhatsApp销售
If
Webhook
Gmail Tool
+7
10 节点Ahmed Saadawi
客户培育