将SmartBill的PDF发票导出到Google Drive
中级
这是一个Finance领域的自动化工作流,包含 15 个节点。主要使用 If, Set, Code, Wait, GoogleDrive 等节点。 将SmartBill的PDF发票导出到Google Drive
前置要求
- •Google Drive API 凭证
- •可能需要目标 API 的认证凭证
分类
工作流预览
可视化展示节点连接关系,支持缩放和平移
导出工作流
复制以下 JSON 配置到 n8n 导入,即可使用此工作流
{
"meta": {
"instanceId": "e122e4b90b0dc212c47b42e306cb84c993d082784105d7fe578eca9a9d068de0",
"templateCredsSetupCompleted": true
},
"nodes": [
{
"id": "119111b6-92a8-4a54-8830-2a12a0d4eec8",
"name": "当点击\"执行工作流\"时",
"type": "n8n-nodes-base.manualTrigger",
"position": [
-580,
-60
],
"parameters": {},
"typeVersion": 1
},
{
"id": "bf0767db-8dd2-4f83-a27f-37c1160916d4",
"name": "Smartbill获取发票PDF",
"type": "n8n-nodes-base.httpRequest",
"position": [
1640,
-60
],
"parameters": {},
"typeVersion": 4.1
},
{
"id": "f8bd05d5-0d7e-4db8-9f07-070e4d48af3b",
"name": "设置数据",
"type": "n8n-nodes-base.set",
"position": [
-300,
-60
],
"parameters": {},
"typeVersion": 3.4
},
{
"id": "57999d68-71d4-4d3c-968a-50c1f20cb010",
"name": "设置MIME类型",
"type": "n8n-nodes-base.code",
"position": [
1900,
-60
],
"parameters": {},
"typeVersion": 2
},
{
"id": "61771345-4562-4c4b-b00d-db8fb0b80f1e",
"name": "便签",
"type": "n8n-nodes-base.stickyNote",
"position": [
-80,
-180
],
"parameters": {},
"typeVersion": 1
},
{
"id": "d3d8feb2-cda6-4c78-b96c-7c8938b23bb7",
"name": "便签 1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-360,
-520
],
"parameters": {},
"typeVersion": 1
},
{
"id": "ee617dbb-effb-4671-b23b-152058edd76f",
"name": "设置默认文件夹名称",
"type": "n8n-nodes-base.code",
"position": [
-20,
-60
],
"parameters": {},
"notesInFlow": false,
"typeVersion": 2
},
{
"id": "15da1268-7ea0-444a-ac79-3d6ec0057b80",
"name": "搜索云端硬盘文件夹",
"type": "n8n-nodes-base.googleDrive",
"position": [
200,
-60
],
"parameters": {},
"typeVersion": 3,
"alwaysOutputData": true
},
{
"id": "d63071eb-ca34-4eb7-8da1-5c8172f4f7fe",
"name": "如果存在",
"type": "n8n-nodes-base.if",
"position": [
420,
-60
],
"parameters": {},
"typeVersion": 2.2
},
{
"id": "7cec08c1-737e-4178-92ea-11914821e2ef",
"name": "创建云端硬盘文件夹",
"type": "n8n-nodes-base.googleDrive",
"position": [
680,
80
],
"parameters": {},
"typeVersion": 3
},
{
"id": "78532c10-0c70-4c8c-9b93-bdcb3e80dbce",
"name": "设置循环",
"type": "n8n-nodes-base.code",
"position": [
1160,
-60
],
"parameters": {},
"typeVersion": 2
},
{
"id": "93bc581c-0624-4fdd-ba06-e0ff3836ea53",
"name": "遍历项目",
"type": "n8n-nodes-base.splitInBatches",
"position": [
1380,
-60
],
"parameters": {},
"typeVersion": 3
},
{
"id": "40d272e8-458f-4946-916e-4eaf9960d4f0",
"name": "上传文件到Google Drive",
"type": "n8n-nodes-base.googleDrive",
"position": [
2140,
-60
],
"parameters": {},
"typeVersion": 3
},
{
"id": "08d5a34a-3e6c-4bfd-bc3e-0cbfedf9d715",
"name": "等待一秒",
"type": "n8n-nodes-base.wait",
"position": [
2380,
-40
],
"webhookId": "fc3f4340-3fc1-4b8a-9f3d-41dccbfb8347",
"parameters": {},
"typeVersion": 1.1
},
{
"id": "a1dca3c1-b9ce-443b-b942-908ab10c1610",
"name": "设置文件夹ID",
"type": "n8n-nodes-base.set",
"position": [
920,
-60
],
"parameters": {},
"typeVersion": 3.4
}
],
"pinData": {},
"connections": {
"SetData": {
"main": [
[
{
"node": "Set Default Folder Name",
"type": "main",
"index": 0
}
]
]
},
"Set mime": {
"main": [
[
{
"node": "Upload file to Google Drive",
"type": "main",
"index": 0
}
]
]
},
"If exists": {
"main": [
[
{
"node": "Set Folder ID",
"type": "main",
"index": 0
}
],
[
{
"node": "Create Drive Folder",
"type": "main",
"index": 0
}
]
]
},
"Wait a sec": {
"main": [
[
{
"node": "Loop Over Items",
"type": "main",
"index": 0
}
]
]
},
"Set the loop": {
"main": [
[
{
"node": "Loop Over Items",
"type": "main",
"index": 0
}
]
]
},
"Set Folder ID": {
"main": [
[
{
"node": "Set the loop",
"type": "main",
"index": 0
}
]
]
},
"Loop Over Items": {
"main": [
[],
[
{
"node": "Smartbill get invoice pdf",
"type": "main",
"index": 0
}
]
]
},
"Create Drive Folder": {
"main": [
[
{
"node": "Set Folder ID",
"type": "main",
"index": 0
}
]
]
},
"Search Drive Folder": {
"main": [
[
{
"node": "If exists",
"type": "main",
"index": 0
}
]
]
},
"Set Default Folder Name": {
"main": [
[
{
"node": "Search Drive Folder",
"type": "main",
"index": 0
}
]
]
},
"Smartbill get invoice pdf": {
"main": [
[
{
"node": "Set mime",
"type": "main",
"index": 0
}
]
]
},
"Upload file to Google Drive": {
"main": [
[
{
"node": "Wait a sec",
"type": "main",
"index": 0
}
]
]
},
"When clicking \"Execute Workflow\"": {
"main": [
[
{
"node": "SetData",
"type": "main",
"index": 0
}
]
]
}
}
}常见问题
如何使用这个工作流?
复制上方的 JSON 配置代码,在您的 n8n 实例中创建新工作流并选择「从 JSON 导入」,粘贴配置后根据需要修改凭证设置即可。
这个工作流适合什么场景?
中级 - 财务
需要付费吗?
本工作流完全免费,您可以直接导入使用。但请注意,工作流中使用的第三方服务(如 OpenAI API)可能需要您自行付费。
相关工作流推荐
(Tung) OCR发票提取到电子表格副本
自动发票和收据OCR到Google表格 - 支持云端硬盘、Gmail和Telegram触发
If
Set
Code
+10
25 节点Daniel Ng
财务
API架构提取器
API架构提取器
If
Set
Code
+22
88 节点Polina Medvedieva
工程
使用 Gemini AI 和 Airtable 从图片生成 Shopify 产品列表
使用 Gemini AI 和 Airtable 从图片生成 Shopify 产品列表
If
Set
Code
+16
33 节点MANISH KUMAR
内容创作
Gemini_NanoBanana_模板
使用 Fal.ai 模型(nano-banana、WAN2.2、Veo3)从 Google Sheets 生成 UGC 广告
If
Set
Code
+13
36 节点Jaruphat J.
内容创作
(Duc)深度研究市场模板
集成PerplexityAI研究和OpenAI内容的多层级WordPress博客生成器
If
Set
Xml
+28
132 节点Daniel Ng
人工智能
使用 Google Drive 和 Meta Graph API 从 Google Sheets 上传视频和图片广告到 Meta Ads Manager
从 Google Sheets 和 Google Drive 上传视频和图片广告到 Meta Ads Manager
If
Set
Code
+11
42 节点Daniel Setzermann
社交媒体