个性化反馈摘要生成器
高级
这是一个Support Chatbot, AI Summarization领域的自动化工作流,包含 26 个节点。主要使用 If, Code, Gmail, Slack, Webhook 等节点。 使用OpenAI处理客户反馈,生成PDF报告,发送Gmail和Slack通知
前置要求
- •Google 账号和 Gmail API 凭证
- •Slack Bot Token 或 Webhook URL
- •HTTP Webhook 端点(n8n 会自动生成)
- •Google Sheets API 凭证
- •OpenAI API Key
工作流预览
可视化展示节点连接关系,支持缩放和平移
导出工作流
复制以下 JSON 配置到 n8n 导入,即可使用此工作流
{
"id": "",
"meta": {
"instanceId": "",
"templateCredsSetupCompleted": false
},
"name": "个性化反馈摘要生成器",
"tags": [
{
"id": "feedback",
"name": "Feedback"
},
{
"id": "ai",
"name": "AI"
},
{
"id": "automation",
"name": "Automation"
},
{
"id": "pdf",
"name": "PDF Generation"
},
{
"id": "email",
"name": "Email"
}
],
"nodes": [
{
"id": "1673a4f2-dac3-4a2f-89cf-8c95d02c0fc6",
"name": "便签 - 凭据设置1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-7264,
-880
],
"parameters": {
"color": 7,
"width": 389,
"height": 656,
"content": "## 🔐 需要设置凭据"
},
"typeVersion": 1
},
{
"id": "4959077e-1f6a-43f8-ad2c-30bd0baa7c8f",
"name": "便签 - 触发器1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-6160,
-864
],
"parameters": {
"color": 7,
"width": 392,
"height": 657,
"content": "## 步骤 1:WEBHOOK 触发器"
},
"typeVersion": 1
},
{
"id": "14577162-c367-452e-8fcc-0d444ea3ce14",
"name": "Webhook - 接收反馈1",
"type": "n8n-nodes-base.webhook",
"position": [
-6032,
-368
],
"webhookId": "feedback-webhook-trigger",
"parameters": {
"path": "feedback-submission",
"options": {},
"httpMethod": "POST",
"responseMode": "responseNode"
},
"typeVersion": 2
},
{
"id": "4457ca3c-f600-407e-aa74-562cbb6ffe4d",
"name": "便签 - 清理数据1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-5744,
-656
],
"parameters": {
"color": 7,
"width": 392,
"height": 449,
"content": "## 步骤 2:数据清理"
},
"typeVersion": 1
},
{
"id": "525aaa53-9a12-4379-8baa-47c91cabc443",
"name": "清理和标准化数据1",
"type": "n8n-nodes-base.code",
"position": [
-5664,
-368
],
"parameters": {
"jsCode": "// Get input data\nconst items = $input.all();\nconst cleanedItems = [];\n\nfor (const item of items) {\n const data = item.json;\n \n // Access the body object where the actual form data is\n const formData = data.body || data;\n \n // Normalize and clean data\n const cleaned = {\n name: formData.name?.trim() || 'Anonymous',\n email: formData.email?.trim().toLowerCase() || '',\n rating: parseInt(formData.rating) || 0,\n comments: formData.comments?.trim() || 'No comments provided',\n suggestions: formData.suggestions?.trim() || 'No suggestions provided',\n timestamp: new Date().toISOString(),\n submissionId: `FB-${Date.now()}-${Math.random().toString(36).substr(2, 9)}`\n };\n \n // Validate email format\n const emailRegex = /^[^\\s@]+@[^\\s@]+\\.[^\\s@]+$/;\n if (cleaned.email && !emailRegex.test(cleaned.email)) {\n cleaned.email = '';\n cleaned.hasValidEmail = false;\n } else {\n cleaned.hasValidEmail = true;\n }\n \n cleanedItems.push({ json: cleaned });\n}\n\nreturn cleanedItems;"
},
"typeVersion": 2
},
{
"id": "bee6365c-320f-426d-b90d-d421e15e2c4a",
"name": "便签 - AI 分析1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-5328,
-816
],
"parameters": {
"color": 7,
"width": 408,
"height": 609,
"content": "## 步骤 3:AI 分析"
},
"typeVersion": 1
},
{
"id": "7359e419-7366-4629-b78d-9b3e6eb8e963",
"name": "生成 AI 摘要1",
"type": "@n8n/n8n-nodes-langchain.openAi",
"position": [
-5168,
-368
],
"parameters": {
"modelId": {
"__rl": true,
"mode": "list",
"value": "gpt-3.5-turbo",
"cachedResultName": "GPT-3.5-TURBO"
},
"options": {},
"messages": {
"values": [
{
"content": "=Analyze this feedback:\n\nName: {{ $json.name }}\nRating: {{ $json.rating }}/5\nComments: {{ $json.comments }}\nSuggestions: {{ $json.suggestions }}"
},
{
"role": "system",
"content": "=You are a feedback analysis assistant. You MUST respond with ONLY valid JSON, no other text.\n\nAnalyze the feedback and return this exact structure:\n{\n \"sentiment\": \"Positive\" or \"Neutral\" or \"Negative\",\n \"highlights\": [\"highlight 1\", \"highlight 2\", \"highlight 3\"],\n \"suggestions\": [\"suggestion 1\", \"suggestion 2\"],\n \"summary\": \"2-3 sentence summary\"\n}\n\nDo not include any text outside the JSON structure. Respond with valid JSON only."
}
]
}
},
"credentials": {
"openAiApi": {
"id": "YOUR_OPENAI_CREDENTIAL_ID",
"name": "OpenAI API"
}
},
"typeVersion": 1.3
},
{
"id": "176eab7c-6456-459b-b295-1b4952562509",
"name": "便签 - 解析响应1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-4896,
-816
],
"parameters": {
"color": 7,
"width": 360,
"height": 593,
"content": "## 步骤 4:解析 AI 响应"
},
"typeVersion": 1
},
{
"id": "c4deea1d-d92a-4afa-9cb1-ff35adb28393",
"name": "解析 AI 响应1",
"type": "n8n-nodes-base.code",
"position": [
-4736,
-368
],
"parameters": {
"jsCode": "const items = $input.all();\nconst outputItems = [];\n\nfor (let i = 0; i < items.length; i++) {\n const feedbackData = $node[\"Clean & Normalize Data1\"].json;\n const aiResponse = items[i].json.message.content;\n \n let aiAnalysis;\n \n try {\n // Clean the response - remove any markdown code blocks if present\n let cleanedResponse = aiResponse.trim();\n \n // Remove markdown code block markers if they exist\n cleanedResponse = cleanedResponse.replace(/```json\\n?/g, '');\n cleanedResponse = cleanedResponse.replace(/```\\n?/g, '');\n cleanedResponse = cleanedResponse.trim();\n \n // Parse the JSON\n aiAnalysis = JSON.parse(cleanedResponse);\n \n // Validate that we have all required fields\n if (!aiAnalysis.sentiment || !aiAnalysis.highlights || !aiAnalysis.suggestions || !aiAnalysis.summary) {\n throw new Error(\"Missing required fields in AI response\");\n }\n \n console.log(\"Successfully parsed AI response as JSON\");\n \n } catch (e) {\n console.log(\"Failed to parse as JSON, using fallback:\", e.message);\n \n // Fallback: Extract data intelligently from text\n let sentiment = \"Neutral\";\n const lowerResponse = aiResponse.toLowerCase();\n \n if (lowerResponse.includes(\"positive\") || \n lowerResponse.includes(\"great\") || \n lowerResponse.includes(\"excellent\")) {\n sentiment = \"Positive\";\n } else if (lowerResponse.includes(\"negative\") || \n lowerResponse.includes(\"poor\") || \n lowerResponse.includes(\"disappointed\")) {\n sentiment = \"Negative\";\n }\n \n // Create fallback structure\n aiAnalysis = {\n sentiment: sentiment,\n highlights: [\n feedbackData.comments || \"Customer provided feedback\",\n `Rating: ${feedbackData.rating}/5 stars`\n ],\n suggestions: [feedbackData.suggestions || \"No specific suggestions\"],\n summary: aiResponse.substring(0, 300)\n };\n }\n \n // Sentiment color mapping\n const sentimentColors = {\n 'Positive': '#10b981',\n 'Neutral': '#f59e0b',\n 'Negative': '#ef4444'\n };\n \n // Build output object\n outputItems.push({\n json: {\n ...feedbackData,\n aiSummary: aiAnalysis.summary,\n sentiment: aiAnalysis.sentiment,\n sentimentColor: sentimentColors[aiAnalysis.sentiment] || '#6b7280',\n highlights: Array.isArray(aiAnalysis.highlights) ? aiAnalysis.highlights : [aiAnalysis.highlights],\n aiSuggestions: Array.isArray(aiAnalysis.suggestions) ? aiAnalysis.suggestions : [aiAnalysis.suggestions]\n }\n });\n}\n\nreturn outputItems;"
},
"typeVersion": 2
},
{
"id": "6c726077-7bca-4b66-864d-79074e097c2b",
"name": "便签 - HTML 生成1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-4512,
-1008
],
"parameters": {
"color": 7,
"width": 424,
"height": 785,
"content": "## 步骤 5:构建 HTML 报告"
},
"typeVersion": 1
},
{
"id": "35382397-13ee-46d0-9eaf-41aae3e4cce9",
"name": "构建 HTML 报告1",
"type": "n8n-nodes-base.code",
"position": [
-4320,
-368
],
"parameters": {
"jsCode": "const data = $json;\n\n// Generate star rating HTML\nconst starRating = '★'.repeat(data.rating) + '☆'.repeat(5 - data.rating);\n\n// Format highlights list\nconst highlightsList = data.highlights.map(h => `<li>${h}</li>`).join('');\n\n// Format AI suggestions list\nconst suggestionsList = data.aiSuggestions.length > 0 \n ? data.aiSuggestions.map(s => `<li>${s}</li>`).join('')\n : '<li>No additional suggestions</li>';\n\n// Generate complete HTML document\nconst html = `\n<!DOCTYPE html>\n<html lang=\"en\">\n<head>\n <meta charset=\"UTF-8\">\n <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">\n <title>Feedback Report - ${data.name}</title>\n <style>\n * {\n margin: 0;\n padding: 0;\n box-sizing: border-box;\n }\n \n body {\n font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;\n background: #f9fafb;\n padding: 40px 20px;\n line-height: 1.6;\n }\n \n .container {\n max-width: 800px;\n margin: 0 auto;\n background: white;\n border-radius: 12px;\n box-shadow: 0 4px 6px rgba(0, 0, 0, 0.07);\n overflow: hidden;\n }\n \n .header {\n background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);\n color: white;\n padding: 40px;\n text-align: center;\n }\n \n .header h1 {\n font-size: 32px;\n margin-bottom: 8px;\n font-weight: 700;\n }\n \n .header p {\n opacity: 0.9;\n font-size: 16px;\n }\n \n .content {\n padding: 40px;\n }\n \n .user-info {\n border-bottom: 2px solid #e5e7eb;\n padding-bottom: 24px;\n margin-bottom: 24px;\n }\n \n .user-name {\n font-size: 28px;\n font-weight: 700;\n color: #111827;\n margin-bottom: 8px;\n }\n \n .user-email {\n color: #6b7280;\n font-size: 15px;\n margin-bottom: 8px;\n }\n \n .submission-id {\n color: #9ca3af;\n font-size: 12px;\n font-family: 'Courier New', monospace;\n }\n \n .rating-section {\n margin: 24px 0;\n text-align: center;\n padding: 24px;\n background: #f9fafb;\n border-radius: 8px;\n }\n \n .stars {\n font-size: 40px;\n color: #fbbf24;\n letter-spacing: 6px;\n margin-bottom: 12px;\n }\n \n .rating-text {\n font-size: 18px;\n color: #374151;\n font-weight: 600;\n margin-bottom: 12px;\n }\n \n .sentiment-badge {\n display: inline-block;\n padding: 10px 20px;\n border-radius: 24px;\n font-weight: 600;\n font-size: 15px;\n color: white;\n text-transform: uppercase;\n letter-spacing: 0.5px;\n }\n \n .section {\n margin: 32px 0;\n }\n \n .section-title {\n font-size: 20px;\n font-weight: 700;\n color: #111827;\n margin-bottom: 16px;\n display: flex;\n align-items: center;\n }\n \n .section-title::before {\n content: '';\n width: 4px;\n height: 28px;\n background: #667eea;\n margin-right: 12px;\n border-radius: 2px;\n }\n \n .section-content {\n color: #374151;\n line-height: 1.8;\n font-size: 16px;\n }\n \n .feedback-box {\n background: #f9fafb;\n padding: 24px;\n border-radius: 8px;\n border-left: 4px solid #667eea;\n margin: 16px 0;\n }\n \n .feedback-box strong {\n color: #111827;\n display: block;\n margin-bottom: 8px;\n font-size: 14px;\n text-transform: uppercase;\n letter-spacing: 0.5px;\n }\n \n ul {\n list-style: none;\n padding-left: 0;\n }\n \n ul li {\n padding: 12px 0;\n padding-left: 32px;\n position: relative;\n color: #374151;\n line-height: 1.6;\n }\n \n ul li::before {\n content: '●';\n color: #667eea;\n font-weight: bold;\n font-size: 24px;\n position: absolute;\n left: 0;\n top: 8px;\n }\n \n .footer {\n background: #f9fafb;\n padding: 32px 40px;\n text-align: center;\n color: #6b7280;\n font-size: 14px;\n border-top: 1px solid #e5e7eb;\n }\n \n .footer p {\n margin: 4px 0;\n }\n \n .footer strong {\n color: #111827;\n }\n \n @media print {\n body {\n padding: 0;\n background: white;\n }\n \n .container {\n box-shadow: none;\n }\n }\n </style>\n</head>\n<body>\n <div class=\"container\">\n <div class=\"header\">\n <h1>📊 Feedback Report</h1>\n <p>AI-Powered Customer Feedback Analysis</p>\n </div>\n \n <div class=\"content\">\n <!-- User Information -->\n <div class=\"user-info\">\n <div class=\"user-name\">${data.name}</div>\n <div class=\"user-email\">${data.email || 'No email provided'}</div>\n <div class=\"submission-id\">Submission ID: ${data.submissionId}</div>\n </div>\n \n <!-- Rating and Sentiment -->\n <div class=\"rating-section\">\n <div class=\"stars\">${starRating}</div>\n <div class=\"rating-text\">${data.rating} out of 5 stars</div>\n <div class=\"sentiment-badge\" style=\"background-color: ${data.sentimentColor};\">\n ${data.sentiment} Feedback\n </div>\n </div>\n \n <!-- AI Summary -->\n <div class=\"section\">\n <div class=\"section-title\">AI Summary</div>\n <div class=\"section-content\">${data.aiSummary}</div>\n </div>\n \n <!-- Key Highlights -->\n <div class=\"section\">\n <div class=\"section-title\">Key Highlights</div>\n <ul>${highlightsList}</ul>\n </div>\n \n <!-- Original Feedback -->\n <div class=\"section\">\n <div class=\"section-title\">Original Feedback</div>\n <div class=\"feedback-box\">\n <strong>Comments</strong>\n ${data.comments}\n </div>\n <div class=\"feedback-box\">\n <strong>Suggestions</strong>\n ${data.suggestions}\n </div>\n </div>\n \n <!-- AI Recommendations -->\n ${data.aiSuggestions.length > 0 ? `\n <div class=\"section\">\n <div class=\"section-title\">Recommended Actions</div>\n <ul>${suggestionsList}</ul>\n </div>\n ` : ''}\n </div>\n \n <div class=\"footer\">\n <p><strong>Report Generated:</strong> ${new Date(data.timestamp).toLocaleString('en-US', { \n weekday: 'long', \n year: 'numeric', \n month: 'long', \n day: 'numeric',\n hour: '2-digit',\n minute: '2-digit'\n })}</p>\n <p style=\"margin-top: 16px;\">Thank you for your valuable feedback! 🙏</p>\n </div>\n </div>\n</body>\n</html>\n`;\n\n// Return the HTML content along with all data\nreturn [{\n json: {\n ...data,\n htmlContent: html\n }\n}];"
},
"typeVersion": 2
},
{
"id": "06215d6b-d83c-4ef6-9560-6bad2005f079",
"name": "便签 - PDF 生成1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-4064,
-784
],
"parameters": {
"color": 7,
"width": 376,
"height": 561,
"content": "## 步骤 6:生成 PDF"
},
"typeVersion": 1
},
{
"id": "d10efd0f-df5c-43f1-b744-4287a0d32a02",
"name": "便签 - 处理 PDF1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-3664,
-688
],
"parameters": {
"color": 7,
"width": 392,
"height": 465,
"content": "## 步骤 7:合并 PDF 元数据"
},
"typeVersion": 1
},
{
"id": "ede437b3-bbcc-4ac4-8848-d92d7a351cf8",
"name": "处理 PDF 响应1",
"type": "n8n-nodes-base.code",
"position": [
-3552,
-368
],
"parameters": {
"jsCode": "const items = $input.all();\nconst previousData = $node[\"Build HTML Report1\"].json;\nconst pdfInfo = items[0].json; // This is the output from HTML to PDF node\n\nreturn [{\n json: {\n ...previousData,\n pdfUrl: pdfInfo.pdf_url,\n pdfFileSize: pdfInfo.file_size_bytes,\n pdfDeletionDate: pdfInfo.file_deletion_date,\n pdfFileName: `Feedback-Report-${previousData.submissionId}.pdf`,\n pdfReady: true\n }\n}];"
},
"typeVersion": 2
},
{
"id": "8f4b800d-8889-46c8-8fb0-234d4728f6b4",
"name": "便签 - 电子邮件验证1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-3232,
-672
],
"parameters": {
"color": 7,
"width": 392,
"height": 434,
"content": "## 步骤 8:电子邮件验证检查"
},
"typeVersion": 1
},
{
"id": "171bdb6d-4c98-49d9-9928-0f7c11a0eb57",
"name": "检查有效电子邮件1",
"type": "n8n-nodes-base.if",
"position": [
-3136,
-368
],
"parameters": {
"options": {},
"conditions": {
"options": {
"version": 1,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "1668e9a2-47cc-4a7b-8dd2-29de8771f4c5",
"operator": {
"type": "boolean",
"operation": "true",
"singleValue": true
},
"leftValue": "={{ $json.hasValidEmail }}",
"rightValue": ""
}
]
}
},
"typeVersion": 2
},
{
"id": "70c0fcc0-cb4b-4ffc-8a5a-bab1f0e71c3e",
"name": "邮件用户报告1",
"type": "n8n-nodes-base.gmail",
"position": [
-2688,
-384
],
"webhookId": "email-webhook",
"parameters": {
"sendTo": "={{ $json.email }}",
"message": "=<div style=\"font-family: Arial, sans-serif; max-width: 600px; margin: 0 auto; padding: 20px;\">\n <div style=\"text-align: center; margin-bottom: 32px;\">\n <h1 style=\"color: #667eea; margin: 0; font-size: 28px;\">Thank You for Your Feedback! 🎉</h1>\n </div>\n \n <p style=\"font-size: 16px; line-height: 1.6;\">Hi <strong>{{ $json.name }}</strong>,</p>\n \n <p style=\"font-size: 16px; line-height: 1.6;\">Thank you for taking the time to share your thoughts with us. Your feedback is invaluable in helping us improve our services.</p>\n \n <div style=\"background: linear-gradient(135deg, #667eea15 0%, #764ba215 100%); padding: 24px; border-radius: 12px; margin: 32px 0; border-left: 4px solid {{ $json.sentimentColor }};\">\n <p style=\"margin: 0; font-size: 16px;\"><strong>📊 Your Rating:</strong>{{ $json.rating }}/5</p>\n <p style=\"margin: 12px 0 0 0; font-size: 16px;\"><strong>💭 Sentiment:</strong> <span style=\"color: {{ $json.sentimentColor }}; font-weight: 700;\">{{ $json.sentiment }}</span></p>\n </div>\n \n <div style=\"background: #f9fafb; padding: 20px; border-radius: 8px; margin: 24px 0;\">\n <p style=\"margin: 0 0 12px 0; font-weight: 600; color: #111827;\">📄 Your Personalized Feedback Report</p>\n <p style=\"margin: 0 0 16px 0; font-size: 14px; line-height: 1.6; color: #6b7280;\">We've prepared a detailed AI-powered analysis of your feedback including key highlights, sentiment analysis, and recommended actions.</p>\n <a href=\"{{ $json.pdfUrl }}\" style=\"display: inline-block; background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); color: white; padding: 14px 28px; border-radius: 8px; text-decoration: none; font-weight: 600; font-size: 16px;\">📥 Download Your Report</a>\n <p style=\"margin: 12px 0 0 0; font-size: 12px; color: #9ca3af;\">⏰ Report available until: {{ $json.pdfDeletionDate }}</p>\n </div>\n \n <div style=\"background: white; border: 1px solid #e5e7eb; padding: 20px; border-radius: 8px; margin: 24px 0;\">\n <p style=\"margin: 0 0 8px 0; font-weight: 600; color: #111827;\">✨ Your Report Includes:</p>\n <ul style=\"margin: 0; padding-left: 20px; line-height: 1.8; color: #374151;\">\n <li>AI-generated summary of your feedback</li>\n <li>Key highlights and main points</li>\n <li>Sentiment analysis with visual indicators</li>\n <li>Actionable recommendations based on your input</li>\n <li>Complete feedback history</li>\n </ul>\n </div>\n \n <p style=\"font-size: 16px; line-height: 1.6;\">If you have any questions or would like to discuss your feedback further, please don't hesitate to reach out. We're here to help!</p>\n \n <div style=\"margin-top: 40px; padding-top: 24px; border-top: 2px solid #e5e7eb;\">\n <p style=\"margin: 0; font-size: 16px;\">Warm regards,</p>\n <p style=\"margin: 4px 0 0 0; font-size: 18px; font-weight: 700; color: #667eea;\">The Team</p>\n </div>\n \n <div style=\"margin-top: 32px; padding: 20px; background: #f9fafb; border-radius: 8px; text-align: center;\">\n <p style=\"margin: 0; font-size: 12px; color: #6b7280;\">Submission ID: <code style=\"background: #e5e7eb; padding: 2px 8px; border-radius: 4px; font-family: monospace;\">{{ $json.submissionId }}</code></p>\n <p style=\"margin: 8px 0 0 0; font-size: 12px; color: #9ca3af;\">Generated on {{ new Date($json.timestamp).toLocaleString() }}</p>\n </div>\n</div>",
"options": {},
"subject": "Your Feedback Summary Report – Thank You for Sharing!"
},
"credentials": {
"gmailOAuth2": {
"id": "YOUR_GMAIL_CREDENTIAL_ID",
"name": "Gmail OAuth2"
}
},
"typeVersion": 2.1
},
{
"id": "f9b4ca97-21e0-4a4f-9b42-43e1390a87c8",
"name": "便签 - 记录数据1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-2480,
-768
],
"parameters": {
"color": 7,
"width": 424,
"height": 546,
"content": "## 步骤 10:记录到 Google Sheets"
},
"typeVersion": 1
},
{
"id": "1d12b1e5-a8cb-436a-8a7f-4e093faaf42b",
"name": "记录反馈数据1",
"type": "n8n-nodes-base.googleSheets",
"position": [
-2336,
-384
],
"parameters": {
"columns": {
"value": {
"Name": "={{ $('Check Valid Email1').item.json.name }}",
"Email": "={{ $('Check Valid Email1').item.json.email }}",
"Rating": "={{ $('Check Valid Email1').item.json.rating }}",
"PDF URL": "={{ $('Check Valid Email1').item.json.pdfUrl }}",
"Comments": "={{ $('Check Valid Email1').item.json.comments }}",
"Sentiment": "={{ $('Check Valid Email1').item.json.sentiment }}",
"Timestamp": "={{ $('Check Valid Email1').item.json.timestamp }}",
"AI Summary": "={{ $('Check Valid Email1').item.json.aiSummary }}",
"Email Sent": "={{ $('Check Valid Email1').item.json.hasValidEmail ? 'Yes' : 'No' }}",
"Suggestions": "={{ $('Check Valid Email1').item.json.suggestions }}",
"Submission ID": "={{ $('Check Valid Email1').item.json.submissionId }}",
"PDF Available Until": "={{ $('Check Valid Email1').item.json.pdfDeletionDate }}"
},
"schema": [
{
"id": "Submission ID",
"type": "string",
"display": true,
"removed": false,
"required": false,
"displayName": "Submission ID",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Timestamp",
"type": "string",
"display": true,
"required": false,
"displayName": "Timestamp",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Name",
"type": "string",
"display": true,
"required": false,
"displayName": "Name",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Email",
"type": "string",
"display": true,
"required": false,
"displayName": "Email",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Rating",
"type": "string",
"display": true,
"required": false,
"displayName": "Rating",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Sentiment",
"type": "string",
"display": true,
"required": false,
"displayName": "Sentiment",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Comments",
"type": "string",
"display": true,
"required": false,
"displayName": "Comments",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Suggestions",
"type": "string",
"display": true,
"required": false,
"displayName": "Suggestions",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "AI Summary",
"type": "string",
"display": true,
"required": false,
"displayName": "AI Summary",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "PDF Available Until",
"type": "string",
"display": true,
"required": false,
"displayName": "PDF Available Until",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "PDF URL",
"type": "string",
"display": true,
"removed": false,
"required": false,
"displayName": "PDF URL",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Email Sent",
"type": "string",
"display": true,
"required": false,
"displayName": "Email Sent",
"defaultMatch": false,
"canBeUsedToMatch": true
}
],
"mappingMode": "defineBelow",
"matchingColumns": [
"Submission ID"
],
"attemptToConvertTypes": false,
"convertFieldsToString": false
},
"options": {},
"operation": "appendOrUpdate",
"sheetName": {
"__rl": true,
"mode": "list",
"value": "gid=0",
"cachedResultUrl": "",
"cachedResultName": "Sheet1"
},
"documentId": {
"__rl": true,
"mode": "list",
"value": "YOUR_GOOGLE_SHEET_ID",
"cachedResultUrl": "",
"cachedResultName": "Feedback Log"
}
},
"credentials": {
"googleSheetsOAuth2Api": {
"id": "YOUR_GOOGLE_SHEETS_CREDENTIAL_ID",
"name": "Google Sheets OAuth2"
}
},
"typeVersion": 4.4
},
{
"id": "c0c1f555-140d-448f-ba78-399971e374a6",
"name": "便签 - 团队提醒1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-2032,
-800
],
"parameters": {
"color": 7,
"width": 520,
"height": 578,
"content": "## 步骤 11:SLACK 团队通知"
},
"typeVersion": 1
},
{
"id": "6deba6a0-a406-4865-8254-694ab11bd1e0",
"name": "通知团队1",
"type": "n8n-nodes-base.slack",
"position": [
-1920,
-384
],
"webhookId": "slack-webhook",
"parameters": {
"text": "=🆕 *New Feedback Received!*\n\n*Customer:* {{ $json.Name }}\n*Email:* {{ $json.Email }}\n*Rating:* {{ $json.Rating }}/5 ⭐\n*Sentiment:* {{ $json.Sentiment }}\n\n*AI Summary:*\n{{ $json['AI Summary'] }}\n\n*Key Highlights:*\n- {{ $('Check Valid Email1').item.json.highlights[0] }}\n- {{ $('Check Valid Email1').item.json.highlights[1] }}\n\n*Recommended Actions:*\n- {{ $('Check Valid Email1').item.json.aiSuggestions[0] }}\n- {{ $('Check Valid Email1').item.json.aiSuggestions[1] }}\n\n📄 *View Full Report:* {{ $json['PDF URL'] }}\n\n_Submission ID: {{ $json['Submission ID'] }}_\n_✅ Logged to tracking sheet_",
"select": "channel",
"channelId": {
"__rl": true,
"mode": "list",
"value": "YOUR_SLACK_CHANNEL_ID",
"cachedResultName": "feedback-notifications"
},
"otherOptions": {}
},
"credentials": {
"slackApi": {
"id": "YOUR_SLACK_CREDENTIAL_ID",
"name": "Slack API"
}
},
"typeVersion": 2.2
},
{
"id": "a569c084-e6ac-4ca0-8060-f952fa7e0589",
"name": "便签 - 最终响应1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-1472,
-864
],
"parameters": {
"color": 7,
"width": 568,
"height": 642,
"content": "## 步骤 12:WEBHOOK 响应"
},
"typeVersion": 1
},
{
"id": "3b59493a-e441-49ac-9627-9dd157254c3f",
"name": "发送成功响应1",
"type": "n8n-nodes-base.respondToWebhook",
"position": [
-1184,
-384
],
"parameters": {
"options": {
"responseCode": 200
},
"respondWith": "json",
"responseBody": "={\n \"success\": true,\n \"message\": \"Thank you for your feedback! We've sent you a detailed report via email.\",\n \"data\": {\n \"submissionId\": \"={{ $('Log Feedback Data1').item.json['Submission ID'] }}\",\n \"name\": \"={{ $('Log Feedback Data1').item.json.Name }}\",\n \"email\": \"={{ $('Log Feedback Data1').item.json.Email }}\",\n \"rating\": \"={{ $('Log Feedback Data1').item.json.Rating }}\",\n \"sentiment\": \"={{ $('Log Feedback Data1').item.json.Sentiment }}\",\n \"emailSent\": \"={{ $('Check Valid Email1').item.json.hasValidEmail }}\",\n \"reportUrl\": \"={{ $('Check Valid Email1').item.json.pdfUrl }}\",\n \"reportAvailableUntil\": \"={{ $('Check Valid Email1').item.json.pdfDeletionDate }}\"\n } \n}\n"
},
"typeVersion": 1.1
},
{
"id": "0fc941d8-3ae3-4334-aaad-456b75177c35",
"name": "便签 - 测试指南1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-6768,
-880
],
"parameters": {
"color": 7,
"width": 549,
"height": 600,
"content": "## 🚀 测试您的工作流"
},
"typeVersion": 1
},
{
"id": "749a54d2-50ac-40ab-b3a0-792e9fdc4387",
"name": "HTML 转 PDF1",
"type": "n8n-nodes-htmlcsstopdf.htmlcsstopdf",
"position": [
-3936,
-368
],
"parameters": {
"html_content": "={{ $json.htmlContent }}"
},
"credentials": {
"htmlcsstopdfApi": {
"id": "YOUR_HTML_TO_PDF_CREDENTIAL_ID",
"name": "HTML to PDF API"
}
},
"typeVersion": 1
},
{
"id": "f210d49f-ebe2-4e23-823e-e29412a330e8",
"name": "便签",
"type": "n8n-nodes-base.stickyNote",
"position": [
-2800,
-528
],
"parameters": {
"color": 7,
"width": 288,
"height": 304,
"content": "## 步骤 9:邮件用户报告"
},
"typeVersion": 1
}
],
"active": false,
"pinData": {},
"settings": {
"executionOrder": "v1"
},
"versionId": "",
"connections": {
"HTML to PDF1": {
"main": [
[
{
"node": "Process PDF Response1",
"type": "main",
"index": 0
}
]
]
},
"Notify Team1": {
"main": [
[
{
"node": "Send Success Response1",
"type": "main",
"index": 0
}
]
]
},
"Build HTML Report1": {
"main": [
[
{
"node": "HTML to PDF1",
"type": "main",
"index": 0
}
]
]
},
"Check Valid Email1": {
"main": [
[
{
"node": "Email User Report1",
"type": "main",
"index": 0
}
]
]
},
"Email User Report1": {
"main": [
[
{
"node": "Log Feedback Data1",
"type": "main",
"index": 0
}
]
]
},
"Log Feedback Data1": {
"main": [
[
{
"node": "Notify Team1",
"type": "main",
"index": 0
}
]
]
},
"Parse AI Response1": {
"main": [
[
{
"node": "Build HTML Report1",
"type": "main",
"index": 0
}
]
]
},
"Generate AI Summary1": {
"main": [
[
{
"node": "Parse AI Response1",
"type": "main",
"index": 0
}
]
]
},
"Process PDF Response1": {
"main": [
[
{
"node": "Check Valid Email1",
"type": "main",
"index": 0
}
]
]
},
"Clean & Normalize Data1": {
"main": [
[
{
"node": "Generate AI Summary1",
"type": "main",
"index": 0
}
]
]
},
"Webhook - Receive Feedback1": {
"main": [
[
{
"node": "Clean & Normalize Data1",
"type": "main",
"index": 0
}
]
]
}
}
}常见问题
如何使用这个工作流?
复制上方的 JSON 配置代码,在您的 n8n 实例中创建新工作流并选择「从 JSON 导入」,粘贴配置后根据需要修改凭证设置即可。
这个工作流适合什么场景?
高级 - 客服机器人, AI 摘要总结
需要付费吗?
本工作流完全免费,您可以直接导入使用。但请注意,工作流中使用的第三方服务(如 OpenAI API)可能需要您自行付费。
相关工作流推荐
会议纪要和行动项跟踪器
基于AI的会议纪要:使用GPT-4、任务分配和多渠道分发
If
Set
Code
+10
38 节点Jitesh Dugar
内容创作
客户入职工作流
使用PDF、Trello、Slack、Gmail和Airtable简化客户入职流程
If
Code
Gmail
+10
22 节点Jitesh Dugar
内容创作
客户支持工单工作流自动化
使用GPT-4、PDF和Google Drive将支持工单转换为AI文档
If
Set
Code
+8
28 节点Jitesh Dugar
内容创作
基于GPT-4的智能招聘与候选人互动系统
基于GPT-4的AI招聘系统,用于简历筛选与自动外联
If
Code
Wait
+8
30 节点Marth
人力资源
有发票附件?
使用 GPT-4o 欺诈检测和 QuickBooks 自动提取并审批发票
If
Code
Gmail
+9
22 节点Jitesh Dugar
家长同意自动化
使用电子邮件验证、PDF生成和Google Drive自动化学校旅行同意书
If
Code
Gmail
+7
22 节点Jitesh Dugar
文档提取
工作流信息
难度等级
高级
节点数量26
分类2
节点类型10
作者
Jitesh Dugar
@jiteshdugarAI Automation Specialist - OpenAI, CRM & Automation Expert with a solid understanding of various tools that include Zapier, Make, Zoho CRM, Hubspot, Google Sheets, Airtable, Pipedrive, Google Analytics, and more.
外部链接
在 n8n.io 查看 →
分享此工作流