8
n8n 中文网amn8n.com

自动保存Instagram潜在客户到Google表格

初级

这是一个Lead Generation, Multimodal AI领域的自动化工作流,包含 4 个节点。主要使用 Code, Webhook, GoogleSheets 等节点。 自动保存Instagram潜在客户到Google表格

前置要求
  • HTTP Webhook 端点(n8n 会自动生成)
  • Google Sheets API 凭证
工作流预览
可视化展示节点连接关系,支持缩放和平移
导出工作流
复制以下 JSON 配置到 n8n 导入,即可使用此工作流
{
  "meta": {
    "instanceId": "2000c64071c20843606b95c63795bb0797c41036047055a6586498e855b96efc",
    "templateCredsSetupCompleted": true
  },
  "nodes": [
    {
      "id": "7da8c35d-17c2-4aff-9d1c-b1d6efaf78e8",
      "name": "设置说明",
      "type": "n8n-nodes-base.stickyNote",
      "position": [
        624,
        272
      ],
      "parameters": {
        "width": 712,
        "height": 508,
        "content": "📋 **需要设置:**"
      },
      "typeVersion": 1
    },
    {
      "id": "10f48b95-3f43-4bda-be11-115dabc5d4ca",
      "name": "Instagram潜在客户Webhook",
      "type": "n8n-nodes-base.webhook",
      "position": [
        672,
        624
      ],
      "webhookId": "instagram-leads-webhook",
      "parameters": {
        "path": "instagram-leads",
        "options": {},
        "httpMethod": "POST"
      },
      "typeVersion": 1
    },
    {
      "id": "a9544025-af6c-427a-985b-c16b286c4be2",
      "name": "标准化潜在客户数据",
      "type": "n8n-nodes-base.code",
      "position": [
        880,
        624
      ],
      "parameters": {
        "jsCode": "// Normalize Instagram lead data\nconst body = $input.first().json.body || $input.first().json;\n\n// Common Instagram lead fields - adapt based on your form structure\nconst normalizedData = {\n  name: body.name || body.full_name || body.firstName + ' ' + body.lastName || 'Unknown',\n  email: body.email || body.email_address || '',\n  phone: body.phone || body.phone_number || '',\n  message: body.message || body.comments || '',\n  source: 'Instagram',\n  timestamp: new Date().toISOString(),\n  raw_data: JSON.stringify(body)\n};\n\nconsole.log('Normalized Instagram Lead Data:', normalizedData);\n\nreturn {\n  json: normalizedData\n};"
      },
      "typeVersion": 2
    },
    {
      "id": "bf561879-cf2f-43d7-b118-6906c8030e35",
      "name": "保存到 Google Sheets",
      "type": "n8n-nodes-base.googleSheets",
      "position": [
        1072,
        624
      ],
      "parameters": {
        "options": {
          "useAppend": true
        },
        "operation": "appendOrUpdate",
        "sheetName": {
          "__rl": true,
          "mode": "list",
          "value": "Sheet1"
        },
        "documentId": {
          "__rl": true,
          "mode": "id",
          "value": "YOUR_GOOGLE_SHEET_ID"
        }
      },
      "typeVersion": 4
    }
  ],
  "pinData": {},
  "connections": {
    "Normalize Lead Data": {
      "main": [
        [
          {
            "node": "Save to Google Sheets",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Instagram Lead Webhook": {
      "main": [
        [
          {
            "node": "Normalize Lead Data",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
常见问题

如何使用这个工作流?

复制上方的 JSON 配置代码,在您的 n8n 实例中创建新工作流并选择「从 JSON 导入」,粘贴配置后根据需要修改凭证设置即可。

这个工作流适合什么场景?

初级 - 潜在客户开发, 多模态 AI

需要付费吗?

本工作流完全免费,您可以直接导入使用。但请注意,工作流中使用的第三方服务(如 OpenAI API)可能需要您自行付费。

工作流信息
难度等级
初级
节点数量4
分类2
节点类型4
难度说明

适合 n8n 新手,包含 1-5 个节点的简单工作流

作者
David Olusola

David Olusola

@dae221

I help ambitious businesses eliminate operational bottlenecks and scale faster with AI automation. My clients typically see 40-60% efficiency gains within 90 days. Currently accepting 3 new projects this quarter - david@daexai.com

外部链接
在 n8n.io 查看

分享此工作流