合规报告收集器
中级
这是一个File Management, Multimodal AI领域的自动化工作流,包含 8 个节点。主要使用 Set, Merge, MySql, Function, GoogleDrive 等节点。 基于 Google 表单 → Drive + MySQL 的合规报告收集器
前置要求
- •MySQL 数据库连接信息
- •Google Drive API 凭证
- •Google Sheets API 凭证
工作流预览
可视化展示节点连接关系,支持缩放和平移
导出工作流
复制以下 JSON 配置到 n8n 导入,即可使用此工作流
{
"id": "Un9KXLeARM23XTIQ",
"meta": {
"instanceId": "14e4c77104722ab186539dfea5182e419aecc83d85963fe13f6de862c875ebfa",
"templateCredsSetupCompleted": true
},
"name": "合规报告收集器",
"tags": [],
"nodes": [
{
"id": "c1d13027-17a3-485a-b43b-e7fece0612c6",
"name": "Google Sheets 表单触发器",
"type": "n8n-nodes-base.googleSheetsTrigger",
"position": [
-440,
60
],
"parameters": {
"event": "rowAdded",
"options": {},
"pollTimes": {
"item": [
{
"mode": "everyMinute"
}
]
},
"sheetName": {
"__rl": true,
"mode": "url",
"value": ""
},
"documentId": {
"__rl": true,
"mode": "list",
"value": "1U4MfFW06VMW0gW3fAkGFDvDnomb1j_0E-0lbEkPlli0",
"cachedResultUrl": "",
"cachedResultName": "compliance_report_sheet(Responses)"
}
},
"credentials": {
"googleSheetsTriggerOAuth2Api": {
"id": "WF8FtUtPeBSlrlAC",
"name": "Google Sheets Trigger account 2"
}
},
"typeVersion": 1
},
{
"id": "038c1dae-f38c-4a98-ae1d-5376d81e3332",
"name": "记录到 MySQL",
"type": "n8n-nodes-base.mySql",
"position": [
660,
60
],
"parameters": {
"table": {
"__rl": true,
"mode": "name",
"value": "report_logs"
},
"options": {}
},
"credentials": {
"mySql": {
"id": "YqKBp66liP3vXdbi",
"name": "MySQL account 4"
}
},
"typeVersion": 2.2
},
{
"id": "d644afd6-ad2e-4931-ba17-42c1d635c3fc",
"name": "重命名字段",
"type": "n8n-nodes-base.set",
"position": [
440,
60
],
"parameters": {
"mode": "raw",
"options": {},
"jsonOutput": "=\n{\n \"reporter\": \"{{$json.reporter}}\",\n \"category\": \"{{$json.category}}\",\n \"timestamp\": \"{{$json.timestamp}}\",\n \"folder_id\": \"{{$json.folder_id}}\",\n \"file_name\": \"{{$binary.data.fileName}}\",\n \"mime_type\": \"{{$binary.data.mimeType}}\",\n \"email\": \"{{$json.email}}\",\n \"description\": \"{{$json.description}}\"\n}"
},
"typeVersion": 3.4
},
{
"id": "ba6a2d4c-f548-446f-ab24-20c518e06f86",
"name": "提取 Google Sheets 数据",
"type": "n8n-nodes-base.function",
"notes": "Extract metadata for logging",
"position": [
-220,
60
],
"parameters": {
"functionCode": "// Input: rows from Google Sheets Trigger\nconst rows = $input.all();\nconst out = [];\n\nfor (const item of rows) {\n const j = item.json;\n\n const url = j['Upload Report File'] || '';\n // supports both ?id=... and /d/.../view URLs\n const m =\n url.match(/[?&]id=([^&]+)/) ||\n url.match(/\\/d\\/([a-zA-Z0-9_-]+)/);\n\n out.push({\n json: {\n reporter: j['Reporter Name'] || null,\n category: j['Report Category'] || null,\n timestamp: new Date(j['Timestamp']).toISOString(),\n folder_id: m ? m[1] : null,\n email: j['Email Address'] || null,\n description: j['Description'] || null,\n },\n });\n}\n\nreturn out;\n"
},
"typeVersion": 1
},
{
"id": "efa9cce4-db44-4296-8c76-9bf12ca68d52",
"name": "获取文件上传元数据",
"type": "n8n-nodes-base.googleDrive",
"position": [
0,
60
],
"parameters": {
"fileId": {
"__rl": true,
"mode": "id",
"value": "={{ $json.folder_id }}"
},
"options": {},
"operation": "download"
},
"credentials": {
"googleDriveOAuth2Api": {
"id": "dkusrOXTExpMxEAe",
"name": "Google Drive account 7"
}
},
"typeVersion": 3
},
{
"id": "6abc9f56-0b24-4e47-840f-72ac8421d90c",
"name": "合并表格和文件数据",
"type": "n8n-nodes-base.merge",
"position": [
220,
60
],
"parameters": {
"mode": "combine",
"options": {
"includeUnpaired": true
},
"combineBy": "combineByPosition"
},
"typeVersion": 3.2,
"alwaysOutputData": true
},
{
"id": "779477a4-ecac-4cd5-8b5f-e385da6c64fc",
"name": "便签",
"type": "n8n-nodes-base.stickyNote",
"position": [
-540,
-100
],
"parameters": {
"width": 1400,
"height": 420,
"content": "## 合规报告收集器(Google 表单 → Drive + MySQL)"
},
"typeVersion": 1
},
{
"id": "071841f7-f553-4637-806a-0db0d27e8de4",
"name": "便签1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-540,
380
],
"parameters": {
"width": 1420,
"height": 1240,
"content": "## 功能说明"
},
"typeVersion": 1
}
],
"active": false,
"pinData": {},
"settings": {
"executionOrder": "v1"
},
"versionId": "7f30bbf3-aa3d-462b-b69e-7bf403e3c880",
"connections": {
"Rename Fields": {
"main": [
[
{
"node": "Log to MySQL",
"type": "main",
"index": 0
}
]
]
},
"Merge sheet & file data": {
"main": [
[
{
"node": "Rename Fields",
"type": "main",
"index": 0
}
]
]
},
"Extract googlesheet data": {
"main": [
[
{
"node": "Get file uploaded metadata",
"type": "main",
"index": 0
}
]
]
},
"Get file uploaded metadata": {
"main": [
[
{
"node": "Merge sheet & file data",
"type": "main",
"index": 0
}
]
]
},
"Google Sheets form Trigger": {
"main": [
[
{
"node": "Extract googlesheet data",
"type": "main",
"index": 0
}
]
]
}
}
}常见问题
如何使用这个工作流?
复制上方的 JSON 配置代码,在您的 n8n 实例中创建新工作流并选择「从 JSON 导入」,粘贴配置后根据需要修改凭证设置即可。
这个工作流适合什么场景?
中级 - 文件管理, 多模态 AI
需要付费吗?
本工作流完全免费,您可以直接导入使用。但请注意,工作流中使用的第三方服务(如 OpenAI API)可能需要您自行付费。
相关工作流推荐
自动化SEO健康监控与报告
网站SEO健康分析(Google Sheets、PDF报告和Gmail告警)
If
Set
Code
+8
16 节点WeblineIndia
市场调研
💥 使用Veo 3.1和Blotato自动化AI视频创作与多平台发布 - 视频
使用GPT-4、Veo 3.1和Blotato自动化AI视频创作与多平台发布
Set
Code
Merge
+7
25 节点Dr. Firas
内容创作
用于更智能BRD(业务需求文档)编写的多Agent RAG系统
使用多Agent GPT和Google Workspace生成业务需求文档
Set
Code
Merge
+14
37 节点Trung Tran
AI RAG 检索增强
自动下载 Reddit 表情包到 Google Drive,含重复检测和 Telegram 提醒
自动下载 Reddit 表情包到 Google Drive,包含重复检测和 Telegram 提醒
If
Set
Code
+10
20 节点Vitorio Magalhães
文件管理
使用 HTTP Last-Modified 检查从 Google Sheets 获取职位发布过期和刷新提醒
通过 Google Sheets、HTTP 检查和 Gmail 实现职位发布过期提醒的自动化
If
Set
Code
+6
19 节点WeblineIndia
人力资源
自动化视频上传 → 自动缩略图 → Google Drive
使用 FFmpeg 和 Google Drive 自动化视频上传和缩略图生成
If
Webhook
Google Drive
+5
9 节点WeblineIndia
内容创作
工作流信息
难度等级
中级
节点数量8
分类2
节点类型7
作者
WeblineIndia
@weblineindiaA Leading Software Engineering, Consulting & Outsourcing Services Company in USA & India serving Clients Globally since 1999.
外部链接
在 n8n.io 查看 →
分享此工作流