企业级区块链文档自动化:支持多链交易审计报告并与Google Drive和Notion集成
高级
这是一个Document Extraction, AI Summarization领域的自动化工作流,包含 20 个节点。主要使用 Code, Notion, Webhook, EmailSend, GoogleDrive 等节点。 生成以太坊和Solana区块链审计报告,支持PDF导出至Drive和Notion
前置要求
- •Notion API Key
- •HTTP Webhook 端点(n8n 会自动生成)
- •Google Drive API 凭证
- •可能需要目标 API 的认证凭证
工作流预览
可视化展示节点连接关系,支持缩放和平移
导出工作流
复制以下 JSON 配置到 n8n 导入,即可使用此工作流
{
"id": "qJ787oClYEkl9Kz1",
"meta": {
"instanceId": "b14f5dd921befc4584084cc386aea593f73c7c2b00b50933075d7967a4d1c502",
"templateCredsSetupCompleted": true
},
"name": "企业级区块链文档自动化:支持多链交易审计报告并与 Google Drive 和 Notion 集成",
"tags": [
{
"id": "6Bd5Rth2OTf9nq38",
"name": "blockchain",
"createdAt": "2025-09-13T02:05:07.482Z",
"updatedAt": "2025-09-13T02:05:07.482Z"
},
{
"id": "QOxbZB87U6rb2Fqo",
"name": "solana",
"createdAt": "2025-09-13T02:05:15.567Z",
"updatedAt": "2025-09-13T02:05:15.567Z"
},
{
"id": "IskMuxAEm0XglOir",
"name": "eth",
"createdAt": "2025-09-13T02:05:18.129Z",
"updatedAt": "2025-09-13T02:05:18.129Z"
},
{
"id": "4fhXioaB07FYjgDU",
"name": "audit",
"createdAt": "2025-09-13T02:05:29.474Z",
"updatedAt": "2025-09-13T02:05:29.474Z"
}
],
"nodes": [
{
"id": "b9741788-3c54-4060-85f3-e227c7ed0f9c",
"name": "区块链事件 Webhook",
"type": "n8n-nodes-base.webhook",
"position": [
-448,
240
],
"webhookId": "07f4d8d3-e797-4cb9-9591-01a9f4a951b3",
"parameters": {
"path": "blockchain-transaction",
"options": {},
"httpMethod": "POST",
"responseMode": "responseNode"
},
"typeVersion": 1
},
{
"id": "dfcaa9a6-8eee-432f-ac39-28ca989d1233",
"name": "以太坊交易监控器",
"type": "n8n-nodes-base.httpRequest",
"position": [
-16,
208
],
"parameters": {
"url": "https://api.alchemy.com/v2/{{ $credentials.alchemy.apiKey }}/",
"method": "POST",
"options": {},
"sendBody": true,
"sendHeaders": true,
"authentication": "genericCredentialType",
"bodyParameters": {
"parameters": []
},
"genericAuthType": "httpHeaderAuth",
"headerParameters": {
"parameters": [
{
"name": "Content-Type",
"value": "application/json"
}
]
}
},
"credentials": {
"httpHeaderAuth": {
"id": "BByciG6fcfsvVecy",
"name": "Header Auth account"
}
},
"typeVersion": 3
},
{
"id": "7e3fa61b-7293-493b-87ac-6d334af4a917",
"name": "Solana 交易监控器",
"type": "n8n-nodes-base.httpRequest",
"position": [
-16,
608
],
"parameters": {
"url": "https://api.mainnet-beta.solana.com",
"method": "POST",
"options": {},
"sendBody": true,
"sendHeaders": true,
"bodyParameters": {
"parameters": [
{}
]
},
"headerParameters": {
"parameters": [
{
"name": "Content-Type",
"value": "application/json"
}
]
}
},
"typeVersion": 3
},
{
"id": "fed4d819-3ad5-4c7e-ab53-30bfafa78064",
"name": "交易数据处理器",
"type": "n8n-nodes-base.code",
"position": [
320,
464
],
"parameters": {
"jsCode": "\n// Process blockchain transaction data\nconst processTransactionData = (items) => {\n const processedData = items.map(item => {\n const data = item.json;\n\n // Extract key transaction details\n const transactionData = {\n transactionHash: data.transactionHash || data.signature,\n blockNumber: data.blockNumber || data.slot,\n from: data.from || data.feePayer,\n to: data.to || data.accounts?.[0],\n value: data.value || data.amount,\n gasUsed: data.gasUsed || data.computeUnitsConsumed,\n timestamp: new Date().toISOString(),\n blockchain: data.blockchain || (data.signature ? 'solana' : 'ethereum'),\n contractAddress: data.logs?.[0]?.address || data.programId,\n eventData: data.logs || data.instructions,\n auditTrail: {\n verified: true,\n riskScore: calculateRiskScore(data),\n complianceStatus: checkCompliance(data)\n }\n };\n\n return { json: transactionData };\n });\n\n return processedData;\n};\n\n// Risk scoring algorithm\nconst calculateRiskScore = (data) => {\n let score = 0;\n\n // High value transactions increase risk\n if (parseFloat(data.value || 0) > 1000000) score += 30;\n\n // Unknown addresses increase risk\n if (!data.from || !data.to) score += 20;\n\n // Failed transactions increase risk\n if (data.status === 'failed') score += 40;\n\n // Multiple contract interactions increase risk\n if ((data.logs?.length || 0) > 5) score += 15;\n\n return Math.min(score, 100);\n};\n\n// Compliance check\nconst checkCompliance = (data) => {\n const checks = {\n kycVerified: true, // Placeholder - integrate with KYC service\n sanctionsCheck: true, // Placeholder - integrate with sanctions list\n jurisdictionCompliant: true,\n reportingRequired: parseFloat(data.value || 0) > 10000\n };\n\n return checks;\n};\n\nreturn processTransactionData($input.all());\n"
},
"typeVersion": 2
},
{
"id": "bb5c89d6-a39b-4e31-90be-5116dda92fc9",
"name": "审计报告 PDF 生成器",
"type": "n8n-nodes-base.httpRequest",
"position": [
576,
80
],
"parameters": {
"url": "https://api.apitemplate.io/v2/create",
"method": "POST",
"options": {},
"sendBody": true,
"sendHeaders": true,
"authentication": "genericCredentialType",
"bodyParameters": {
"parameters": [
{}
]
},
"genericAuthType": "httpHeaderAuth",
"headerParameters": {
"parameters": [
{
"name": "Content-Type",
"value": "application/json"
}
]
}
},
"credentials": {
"httpHeaderAuth": {
"id": "BByciG6fcfsvVecy",
"name": "Header Auth account"
}
},
"typeVersion": 3
},
{
"id": "c7929f10-68b8-4a9c-b8fd-b1c0431151be",
"name": "上传至 Google Drive",
"type": "n8n-nodes-base.googleDrive",
"position": [
880,
160
],
"parameters": {
"name": "Blockchain_Audit_Report_{{ $json.transactionHash }}_{{ new Date().toISOString().split('T')[0] }}.pdf",
"driveId": {
"__rl": true,
"mode": "list",
"value": "My Drive"
},
"options": {},
"folderId": {
"__rl": true,
"mode": "list",
"value": "root",
"cachedResultName": "/ (Root folder)"
}
},
"credentials": {
"googleDriveOAuth2Api": {
"id": "NUaKJykQqq5DtSNV",
"name": "Google Drive account"
}
},
"typeVersion": 3
},
{
"id": "3745e197-e37b-40d8-80c0-17044fc62ebf",
"name": "创建 Notion 审计条目",
"type": "n8n-nodes-base.notion",
"position": [
640,
528
],
"parameters": {
"options": {},
"resource": "databasePage",
"databaseId": "{{ $credentials.notion.auditDatabaseId }}"
},
"credentials": {
"notionApi": {
"id": "10FiuTaIn4tHuWTs",
"name": "Notion account"
}
},
"typeVersion": 2
},
{
"id": "6f2845e7-f7de-41dc-b735-f03e21844bd1",
"name": "财务团队通知",
"type": "n8n-nodes-base.emailSend",
"position": [
976,
512
],
"webhookId": "9467f8c6-e08f-4b28-95f5-28c7a4b555aa",
"parameters": {
"options": {
"ccEmail": "compliance@company.com",
"bccEmail": "audit-logs@company.com",
"allowUnauthorizedCerts": false
},
"subject": "🔗 New Blockchain Transaction Audit Report - {{ $json.blockchain }} {{ $json.transactionHash }}",
"toEmail": "finance-team@company.com",
"fromEmail": "blockchain-audit@company.com"
},
"credentials": {
"smtp": {
"id": "bu96rpU9INmI4MC5",
"name": "SMTP account"
}
},
"typeVersion": 2
},
{
"id": "ac0c6ef3-9a21-4d49-bbcf-810f49311d5c",
"name": "智能合约审计追踪",
"type": "n8n-nodes-base.httpRequest",
"position": [
816,
896
],
"parameters": {
"url": "{{ $json.blockchain === 'ethereum' ? 'https://api.etherscan.io/api' : 'https://api.solscan.io/transaction' }}",
"method": "POST",
"options": {},
"sendQuery": true,
"sendHeaders": true,
"queryParameters": {
"parameters": [
{
"name": "module",
"value": "contract"
},
{
"name": "action",
"value": "getabi"
},
{
"name": "address",
"value": "{{ $json.contractAddress }}"
},
{
"name": "apikey",
"value": "{{ $credentials.etherscan.apiKey }}"
}
]
},
"headerParameters": {
"parameters": [
{
"name": "Content-Type",
"value": "application/json"
}
]
}
},
"typeVersion": 3
},
{
"id": "ac1c6c14-0e7f-4141-90be-024e252cd3be",
"name": "Webhook 响应",
"type": "n8n-nodes-base.respondToWebhook",
"position": [
1328,
528
],
"parameters": {
"options": {
"responseCode": 200
}
},
"typeVersion": 1
},
{
"id": "d8780878-0d1c-4b43-9301-80d3365eeba7",
"name": "便签",
"type": "n8n-nodes-base.stickyNote",
"position": [
-672,
144
],
"parameters": {
"width": 400,
"height": 224,
"content": "## 区块链事件 Webhook"
},
"typeVersion": 1
},
{
"id": "c83c59dc-71cb-442a-938a-ca4596a5c102",
"name": "便签1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-224,
80
],
"parameters": {
"width": 336,
"height": 288,
"content": "## 以太坊交易监控器"
},
"typeVersion": 1
},
{
"id": "c308f341-bdde-4676-b2d4-b0e76f002de9",
"name": "便签2",
"type": "n8n-nodes-base.stickyNote",
"position": [
-224,
496
],
"parameters": {
"width": 352,
"height": 272,
"content": "## Solana 交易监控器"
},
"typeVersion": 1
},
{
"id": "5e4e9000-a0b8-479f-afa9-11f18713823d",
"name": "便签3",
"type": "n8n-nodes-base.stickyNote",
"position": [
160,
336
],
"parameters": {
"width": 272,
"height": 272,
"content": "## 交易数据处理器"
},
"typeVersion": 1
},
{
"id": "32923617-6012-4339-9608-7061febff7e4",
"name": "便签4",
"type": "n8n-nodes-base.stickyNote",
"position": [
432,
-48
],
"parameters": {
"width": 272,
"height": 288,
"content": "## 审计报告 PDF 生成器"
},
"typeVersion": 1
},
{
"id": "c5513557-0cb7-4531-bb4d-59defc2fc013",
"name": "便签5",
"type": "n8n-nodes-base.stickyNote",
"position": [
512,
352
],
"parameters": {
"width": 256,
"height": 336,
"content": "## 创建 Notion 审计条目"
},
"typeVersion": 1
},
{
"id": "0ebe6e0d-b48f-469b-906b-66d2443c5f0d",
"name": "便签6",
"type": "n8n-nodes-base.stickyNote",
"position": [
768,
16
],
"parameters": {
"height": 288,
"content": "## 上传至 Google Drive"
},
"typeVersion": 1
},
{
"id": "b30de4ca-a9cc-436b-a3d9-cbab8583a06a",
"name": "便签7",
"type": "n8n-nodes-base.stickyNote",
"position": [
848,
352
],
"parameters": {
"height": 320,
"content": "## 财务团队通知"
},
"typeVersion": 1
},
{
"id": "ceddccac-d4af-410f-a8e9-8606496b9f77",
"name": "便签8",
"type": "n8n-nodes-base.stickyNote",
"position": [
704,
720
],
"parameters": {
"height": 320,
"content": "## 智能合约审计追踪"
},
"typeVersion": 1
},
{
"id": "e679f575-0e94-4ba8-b4a0-b09ed6c83c93",
"name": "便签9",
"type": "n8n-nodes-base.stickyNote",
"position": [
1216,
400
],
"parameters": {
"height": 256,
"content": "## Webhook 响应"
},
"typeVersion": 1
}
],
"active": false,
"pinData": {},
"settings": {
"callerPolicy": "workflowsFromSameOwner",
"executionOrder": "v1",
"executionTimeout": -1
},
"versionId": "36ce51c7-7d40-459c-b3a6-90ca9c2fbe1a",
"connections": {
"Upload to Google Drive": {
"main": [
[
{
"node": "Webhook Response",
"type": "main",
"index": 0
}
]
]
},
"Blockchain Event Webhook": {
"main": [
[
{
"node": "Ethereum Transaction Monitor",
"type": "main",
"index": 0
},
{
"node": "Solana Transaction Monitor",
"type": "main",
"index": 0
}
]
]
},
"Create Notion Audit Entry": {
"main": [
[
{
"node": "Finance Team Notification",
"type": "main",
"index": 0
}
]
]
},
"Finance Team Notification": {
"main": [
[
{
"node": "Webhook Response",
"type": "main",
"index": 0
}
]
]
},
"Audit Report PDF Generator": {
"main": [
[
{
"node": "Upload to Google Drive",
"type": "main",
"index": 0
}
]
]
},
"Smart Contract Audit Trail": {
"main": [
[
{
"node": "Webhook Response",
"type": "main",
"index": 0
}
]
]
},
"Solana Transaction Monitor": {
"main": [
[
{
"node": "Transaction Data Processor",
"type": "main",
"index": 0
}
]
]
},
"Transaction Data Processor": {
"main": [
[
{
"node": "Audit Report PDF Generator",
"type": "main",
"index": 0
},
{
"node": "Create Notion Audit Entry",
"type": "main",
"index": 0
},
{
"node": "Smart Contract Audit Trail",
"type": "main",
"index": 0
}
]
]
},
"Ethereum Transaction Monitor": {
"main": [
[
{
"node": "Transaction Data Processor",
"type": "main",
"index": 0
}
]
]
}
}
}常见问题
如何使用这个工作流?
复制上方的 JSON 配置代码,在您的 n8n 实例中创建新工作流并选择「从 JSON 导入」,粘贴配置后根据需要修改凭证设置即可。
这个工作流适合什么场景?
高级 - 文档提取, AI 摘要总结
需要付费吗?
本工作流完全免费,您可以直接导入使用。但请注意,工作流中使用的第三方服务(如 OpenAI API)可能需要您自行付费。
相关工作流推荐
AI驱动的同行评审作业系统,带自动评分标准生成
使用GPT-4-nano、Slack和邮件通知自动化同行评审分配
Set
Code
Slack
+9
22 节点Cheng Siong Chin
文档提取
AI驱动的活动后报告和摘要生成器
使用GPT-4生成活动后报告,支持邮件发送和数据库存储
Code
Webhook
Postgres
+6
13 节点Oneclick AI Squad
文档提取
交易机器人ICT 2025智能货币概念
使用ICT方法、GPT-4o和Coinbase的自动化加密货币交易机器人
If
Set
Code
+6
15 节点Tegar karunia ilham
杂项
智能求职专家
通过 Gemini AI、Notion 追踪和多平台搜索实现职位申请的自动化
If
Set
Code
+8
16 节点Tegar karunia ilham
内容创作
家长同意自动化
使用电子邮件验证、PDF生成和Google Drive自动化学校旅行同意书
If
Code
Gmail
+7
22 节点Jitesh Dugar
文档提取
自动化客户培育邮件与Notion客户评价收集
使用WhatsApp、GPT-4V和Google Sheets提取并整理收据数据
If
Code
Notion
+7
18 节点Shelly-Ann Davy
发票处理
工作流信息
难度等级
高级
节点数量20
分类2
节点类型8
作者
Tegar karunia ilham
@tegarkaruniailhamHelping business owners & marketers automate their processes with n8n. Specialist in custom workflows, API integrations, and template development. 📈 100+ successful automation projects 🔧 Premium n8n templates available 💡 Free consultation for custom automation Book a consultation for your business digital transformation!"
外部链接
在 n8n.io 查看 →
分享此工作流