提示 #2:使用 Google Sheets 作为 n8n 工作流界面
中级
这是一个AI领域的自动化工作流,包含 6 个节点。主要使用 Set、GoogleSheets、ManualTrigger、SplitInBatches 等节点,结合人工智能技术实现智能自动化。 提示 #2:使用 Google Sheets 作为 n8n 工作流界面
前置要求
- •Google Sheets API 凭证
分类
工作流预览
可视化展示节点连接关系,支持缩放和平移
导出工作流
复制以下 JSON 配置到 n8n 导入,即可使用此工作流
{
"id": "6UxyvEC8t6hfrQvm",
"meta": {
"instanceId": "8981479cb588889c05b145eaed421551d37a4fff11ab279d3f4744a6577c6002",
"templateCredsSetupCompleted": true
},
"name": "Tip #2: Using Google Sheets as UI for your n8n workflow",
"tags": [],
"nodes": [
{
"id": "891425c8-7f09-4a7e-8b18-4ca06a0111b6",
"name": "When clicking ‘Execute workflow’",
"type": "n8n-nodes-base.manualTrigger",
"position": [
0,
50
],
"parameters": {},
"typeVersion": 1
},
{
"id": "6a12b4f8-95f3-4a19-9b4c-091e1a1450a1",
"name": "Sticky Note",
"type": "n8n-nodes-base.stickyNote",
"position": [
0,
-200
],
"parameters": {
"width": 360,
"height": 200,
"content": "## Tip #2: Using Google Sheets as UI for your n8n workflow\nThis is the template with example of how you can add more control on input and output of your n8n workflow. In other words how to add some kind of UI to your n8n workflow.\nMore details in my [N8n Tips blog](https://n8n-tips.blogspot.com/2025/06/tip-2-using-google-sheets-as-ui-for.html)"
},
"typeVersion": 1
},
{
"id": "3567ea8e-c780-4bd2-bc34-5a88b681d9ee",
"name": "Loop Over Items",
"type": "n8n-nodes-base.splitInBatches",
"position": [
440,
50
],
"parameters": {
"options": {}
},
"typeVersion": 3
},
{
"id": "79583f64-4c09-4210-a440-57dbba28dc3c",
"name": "Edit Fields",
"type": "n8n-nodes-base.set",
"position": [
660,
100
],
"parameters": {
"options": {},
"assignments": {
"assignments": [
{
"id": "4a875792-664d-4c97-af72-1252c86cc64a",
"name": "row_number",
"type": "number",
"value": "={{ $json.row_number }}"
},
{
"id": "cd47a508-aad7-4c7c-94cc-15752e8ede05",
"name": "Number",
"type": "number",
"value": "={{ $json.Color.length }}"
},
{
"id": "b67e8c39-f3f9-4614-9b5d-96876cb6a669",
"name": "Status",
"type": "string",
"value": "DONE"
}
]
}
},
"typeVersion": 3.4
},
{
"id": "698a0745-a4cd-4f2f-84e4-e8f5402c5215",
"name": "Read Google Sheets",
"type": "n8n-nodes-base.googleSheets",
"position": [
220,
50
],
"parameters": {
"options": {},
"filtersUI": {
"values": [
{
"lookupValue": "READY",
"lookupColumn": "Status"
}
]
},
"sheetName": {
"__rl": true,
"mode": "list",
"value": "gid=0",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/13xu9zKI8yDqs7971qIq9zDCBCnhYzdVq8pdtnQ9vMkI/edit#gid=0",
"cachedResultName": "Sheet1"
},
"documentId": {
"__rl": true,
"mode": "list",
"value": "13xu9zKI8yDqs7971qIq9zDCBCnhYzdVq8pdtnQ9vMkI",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/13xu9zKI8yDqs7971qIq9zDCBCnhYzdVq8pdtnQ9vMkI/edit?usp=drivesdk",
"cachedResultName": "Tip #2: Using Google Sheets as UI for your n8n workflow"
},
"authentication": "serviceAccount"
},
"credentials": {
"googleApi": {
"id": "FboA3kaXSneJmEGX",
"name": "Google Service Account account"
}
},
"typeVersion": 4.6
},
{
"id": "79f663cc-805a-453a-9e9f-8e8114c47083",
"name": "Update Google Sheets",
"type": "n8n-nodes-base.googleSheets",
"position": [
660,
-100
],
"parameters": {
"columns": {
"value": {},
"schema": [
{
"id": "Color",
"type": "string",
"display": true,
"required": false,
"displayName": "Color",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Status",
"type": "string",
"display": true,
"required": false,
"displayName": "Status",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "Number",
"type": "string",
"display": true,
"required": false,
"displayName": "Number",
"defaultMatch": false,
"canBeUsedToMatch": true
},
{
"id": "row_number",
"type": "string",
"display": true,
"removed": false,
"readOnly": true,
"required": false,
"displayName": "row_number",
"defaultMatch": false,
"canBeUsedToMatch": true
}
],
"mappingMode": "autoMapInputData",
"matchingColumns": [
"row_number"
],
"attemptToConvertTypes": false,
"convertFieldsToString": false
},
"options": {},
"operation": "update",
"sheetName": {
"__rl": true,
"mode": "list",
"value": "gid=0",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/13xu9zKI8yDqs7971qIq9zDCBCnhYzdVq8pdtnQ9vMkI/edit#gid=0",
"cachedResultName": "Sheet1"
},
"documentId": {
"__rl": true,
"mode": "list",
"value": "13xu9zKI8yDqs7971qIq9zDCBCnhYzdVq8pdtnQ9vMkI",
"cachedResultUrl": "https://docs.google.com/spreadsheets/d/13xu9zKI8yDqs7971qIq9zDCBCnhYzdVq8pdtnQ9vMkI/edit?usp=drivesdk",
"cachedResultName": "Tip #2: Using Google Sheets as UI for your n8n workflow"
},
"authentication": "serviceAccount"
},
"credentials": {
"googleApi": {
"id": "FboA3kaXSneJmEGX",
"name": "Google Service Account account"
}
},
"typeVersion": 4.6
}
],
"active": false,
"pinData": {},
"settings": {
"executionOrder": "v1"
},
"versionId": "b35a60f1-c0af-49ff-88d2-ca0f75334d2a",
"connections": {
"Edit Fields": {
"main": [
[
{
"node": "Loop Over Items",
"type": "main",
"index": 0
}
]
]
},
"Loop Over Items": {
"main": [
[
{
"node": "Update Google Sheets",
"type": "main",
"index": 0
}
],
[
{
"node": "Edit Fields",
"type": "main",
"index": 0
}
]
]
},
"Read Google Sheets": {
"main": [
[
{
"node": "Loop Over Items",
"type": "main",
"index": 0
}
]
]
},
"When clicking ‘Execute workflow’": {
"main": [
[
{
"node": "Read Google Sheets",
"type": "main",
"index": 0
}
]
]
}
}
}常见问题
如何使用这个工作流?
复制上方的 JSON 配置代码,在您的 n8n 实例中创建新工作流并选择「从 JSON 导入」,粘贴配置后根据需要修改凭证设置即可。
这个工作流适合什么场景?
这是一个中级难度的工作流,适用于AI等场景。适合有一定经验的用户,包含 6-15 个节点的中等复杂度工作流
需要付费吗?
本工作流完全免费,您可以直接导入使用。但请注意,工作流中使用的第三方服务(如 OpenAI API)可能需要您自行付费。
相关工作流推荐
提示 #1:测试 n8n 子工作流
提示 #1:测试 n8n 子工作流
If
Set
Manual Trigger
+2
6 节点Viktor Klepikovskyi
Building Blocks
来自域名 - Perplexity、Linkedin、网站、Hunter、Airtop的B2B研究公司
AI潜在客户研究员:仅需公司名称和域名,集成ISCP
Set
Wait
Merge
+13
36 节点LukaszB
Sales
销售AI网络研究员
销售用AI网络研究员
Set
Merge
Google Sheets
+9
22 节点Lucas Perret
Sales
AI生成的WordPress文章摘要块
WordPress文章的AI生成摘要块
If
Set
Slack
+14
32 节点Dataki
AI
电话销售循环
AI驱动电话销售自动化,集成Vapi.ai、GPT-4o和Google Sheets
If
Set
Wait
+8
38 节点Amit Mehta
Sales
基于AI的潜在客户信息增强(Bright Data MCP和Google Sheets)
基于AI的潜在客户信息增强:使用Bright Data MCP和Google Sheets
If
Set
Wait
+19
51 节点Cyril Nicko Gaspar
Sales