8
n8n 中文网amn8n.com

使用GPT-4o和Apify为亚马逊卖家自动生成并发布LinkedIn内容

高级

这是一个Content Creation, Multimodal AI领域的自动化工作流,包含 21 个节点。主要使用 If, Wait, Limit, Airtable, LinkedIn 等节点。 使用GPT-4o和Apify为亚马逊卖家自动生成并发布LinkedIn内容

前置要求
  • Airtable API Key
  • LinkedIn API 凭证
  • Google Drive API 凭证
  • 可能需要目标 API 的认证凭证
  • OpenAI API Key
工作流预览
可视化展示节点连接关系,支持缩放和平移
导出工作流
复制以下 JSON 配置到 n8n 导入,即可使用此工作流
{
  "meta": {
    "instanceId": "4e229722e6c43a4914d2d66178b48335adf795d73afbee5b0ea0c52938ef4d8e",
    "templateCredsSetupCompleted": true
  },
  "nodes": [
    {
      "id": "2d694354-6ab0-42fd-abbf-d3085813fd49",
      "name": "创意生成器",
      "type": "@n8n/n8n-nodes-langchain.agent",
      "position": [
        300,
        315
      ],
      "parameters": {},
      "retryOnFail": true,
      "typeVersion": 1.7
    },
    {
      "id": "069571e9-34b1-4220-aa88-65ba507201cc",
      "name": "OpenAI 聊天模型",
      "type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
      "position": [
        320,
        535
      ],
      "parameters": {},
      "typeVersion": 1.2
    },
    {
      "id": "1886d8e4-e430-4893-8d5b-68d72a5b7977",
      "name": "结构化输出解析器",
      "type": "@n8n/n8n-nodes-langchain.outputParserStructured",
      "position": [
        440,
        535
      ],
      "parameters": {},
      "typeVersion": 1.2
    },
    {
      "id": "3aa0419c-2048-4b44-b934-30ba09a3f50a",
      "name": "生成图片",
      "type": "@n8n/n8n-nodes-langchain.openAi",
      "position": [
        660,
        315
      ],
      "parameters": {},
      "typeVersion": 1.8
    },
    {
      "id": "63e0ec06-14af-4459-a25b-51e250591287",
      "name": "定时任务",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        -1680,
        825
      ],
      "parameters": {},
      "typeVersion": 1.2
    },
    {
      "id": "08aba01d-5b18-44c3-b14a-635fa84471ed",
      "name": "获取影响者用户名",
      "type": "n8n-nodes-base.airtable",
      "position": [
        -1460,
        565
      ],
      "parameters": {},
      "typeVersion": 2.1
    },
    {
      "id": "a51c9676-bed8-45b4-b9fb-93d83ca8392d",
      "name": "遍历影响者列表",
      "type": "n8n-nodes-base.splitInBatches",
      "position": [
        -1240,
        565
      ],
      "parameters": {},
      "typeVersion": 3
    },
    {
      "id": "c99639fd-9184-4250-ba44-feb8df421ceb",
      "name": "运行 LinkedIn 爬虫",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -1020,
        315
      ],
      "parameters": {},
      "typeVersion": 4.2
    },
    {
      "id": "e02460ba-9498-462a-bfd9-6dcff8fa6961",
      "name": "等待爬虫完成",
      "type": "n8n-nodes-base.wait",
      "position": [
        -800,
        315
      ],
      "webhookId": "a57e3a3f-84ff-493b-9a5f-b92152dd8ffd",
      "parameters": {},
      "typeVersion": 1.1
    },
    {
      "id": "3b04dd2b-2ced-4d46-9d2f-2b985bcd495f",
      "name": "获取爬虫输出",
      "type": "n8n-nodes-base.httpRequest",
      "position": [
        -580,
        240
      ],
      "parameters": {},
      "typeVersion": 4.2,
      "alwaysOutputData": true
    },
    {
      "id": "04516adb-6912-4e35-9c7a-ecd375cf1c49",
      "name": "如果爬虫响应中存在帖子",
      "type": "n8n-nodes-base.if",
      "position": [
        -360,
        315
      ],
      "parameters": {},
      "typeVersion": 2.2
    },
    {
      "id": "18cf177b-0a97-4d77-8ed2-3cd88a6df662",
      "name": "在 Airtable 中获取最后一条帖子",
      "type": "n8n-nodes-base.airtable",
      "position": [
        -140,
        315
      ],
      "parameters": {},
      "typeVersion": 2.1,
      "alwaysOutputData": true
    },
    {
      "id": "31987011-291e-4311-8beb-df8042f0b33a",
      "name": "如果发现新帖子",
      "type": "n8n-nodes-base.if",
      "position": [
        80,
        315
      ],
      "parameters": {},
      "typeVersion": 2.2
    },
    {
      "id": "4d450009-801d-4403-a014-989811c8e012",
      "name": "上传图片到 Google Drive",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        880,
        315
      ],
      "parameters": {},
      "typeVersion": 3
    },
    {
      "id": "393bef02-9b09-419e-b756-383c75e393f9",
      "name": "创建 Airtable 记录",
      "type": "n8n-nodes-base.airtable",
      "position": [
        1100,
        440
      ],
      "parameters": {},
      "typeVersion": 2.1
    },
    {
      "id": "96aa3ae0-87d0-4135-90f0-8548c9e038be",
      "name": "查找已批准的 LinkedIn 帖子",
      "type": "n8n-nodes-base.airtable",
      "position": [
        -1460,
        825
      ],
      "parameters": {},
      "typeVersion": 2.1
    },
    {
      "id": "7087ff10-6e71-4394-8c88-f2c7cef1cf85",
      "name": "选择一条已批准的帖子",
      "type": "n8n-nodes-base.limit",
      "position": [
        -1240,
        825
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "e213d554-1996-4182-8afc-23cdc95e80c1",
      "name": "从 Drive 下载帖子图片",
      "type": "n8n-nodes-base.googleDrive",
      "position": [
        -1020,
        825
      ],
      "parameters": {},
      "typeVersion": 3
    },
    {
      "id": "08225727-ca9b-4de2-8d60-7dee032f31ff",
      "name": "将帖子发布到 LinkedIn",
      "type": "n8n-nodes-base.linkedIn",
      "position": [
        -800,
        825
      ],
      "parameters": {},
      "typeVersion": 1
    },
    {
      "id": "2db25d96-a6ba-4117-830b-3065396c17d2",
      "name": "在 Airtable 中将帖子标记为已发布",
      "type": "n8n-nodes-base.airtable",
      "position": [
        -580,
        825
      ],
      "parameters": {},
      "typeVersion": 2.1
    },
    {
      "id": "4ac83d58-0a6d-4339-b60e-dcabe5357490",
      "name": "计划触发器",
      "type": "n8n-nodes-base.scheduleTrigger",
      "position": [
        -1680,
        565
      ],
      "parameters": {},
      "typeVersion": 1.2
    }
  ],
  "pinData": {},
  "connections": {
    "Schedule ": {
      "main": [
        [
          {
            "node": "Find Approved LinkedIn Posts",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Generate Image": {
      "main": [
        [
          {
            "node": "Upload Image to Google Drive",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Idea Generator": {
      "main": [
        [
          {
            "node": "Generate Image",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Schedule Trigger": {
      "main": [
        [
          {
            "node": "Fetch Influencer Usernames",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "If New Post Found": {
      "main": [
        [
          {
            "node": "Idea Generator",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Loop Through Influencer List",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "OpenAI Chat Model": {
      "ai_languageModel": [
        [
          {
            "node": "Idea Generator",
            "type": "ai_languageModel",
            "index": 0
          }
        ]
      ]
    },
    "Fetch Scraper Output": {
      "main": [
        [
          {
            "node": "If Post Exists in Scraper Response",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Run LinkedIn Scraper": {
      "main": [
        [
          {
            "node": "Wait for Scraper to Finish",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Create Airtable Record": {
      "main": [
        [
          {
            "node": "Loop Through Influencer List",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Pick One Approved Post": {
      "main": [
        [
          {
            "node": "Download Post Image from Drive",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Publish Post to LinkedIn": {
      "main": [
        [
          {
            "node": "Mark Post as Posted in Airtable",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Structured Output Parser": {
      "ai_outputParser": [
        [
          {
            "node": "Idea Generator",
            "type": "ai_outputParser",
            "index": 0
          }
        ]
      ]
    },
    "Fetch Influencer Usernames": {
      "main": [
        [
          {
            "node": "Loop Through Influencer List",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Wait for Scraper to Finish": {
      "main": [
        [
          {
            "node": "Fetch Scraper Output",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Fetch Last Post in Airtable": {
      "main": [
        [
          {
            "node": "If New Post Found",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Find Approved LinkedIn Posts": {
      "main": [
        [
          {
            "node": "Pick One Approved Post",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Loop Through Influencer List": {
      "main": [
        [],
        [
          {
            "node": "Run LinkedIn Scraper",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Upload Image to Google Drive": {
      "main": [
        [
          {
            "node": "Create Airtable Record",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "Download Post Image from Drive": {
      "main": [
        [
          {
            "node": "Publish Post to LinkedIn",
            "type": "main",
            "index": 0
          }
        ]
      ]
    },
    "If Post Exists in Scraper Response": {
      "main": [
        [
          {
            "node": "Fetch Last Post in Airtable",
            "type": "main",
            "index": 0
          }
        ],
        [
          {
            "node": "Wait for Scraper to Finish",
            "type": "main",
            "index": 0
          }
        ]
      ]
    }
  }
}
常见问题

如何使用这个工作流?

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

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

高级 - 内容创作, 多模态 AI

需要付费吗?

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

工作流信息
难度等级
高级
节点数量21
分类2
节点类型13
难度说明

适合高级用户,包含 16+ 个节点的复杂工作流

作者
Usman Liaqat

Usman Liaqat

@usmanliaqat

Full Stack Website Developer & Automation Expert

外部链接
在 n8n.io 查看

分享此工作流