自动化分发内容到Google Sheet和Slack
中级
这是一个Social Media领域的自动化工作流,包含 12 个节点。主要使用 If, Set, Slack, Twitter, LinkedIn 等节点。 使用Google Sheets和Slack自动化社交媒体内容分发
前置要求
- •Slack Bot Token 或 Webhook URL
- •Twitter API 凭证
- •LinkedIn API 凭证
- •Google Sheets API 凭证
- •Facebook Graph API 凭证
分类
工作流预览
可视化展示节点连接关系,支持缩放和平移
导出工作流
复制以下 JSON 配置到 n8n 导入,即可使用此工作流
{
"id": "7nrbRUkisTTkK3e8",
"meta": {
"instanceId": "a287613f1596da776459594685fbf4e2b4a12124f80ab8c8772f5e37bff103ae",
"templateCredsSetupCompleted": true
},
"name": "自动化分发内容到 Google Sheet 和 Slack",
"tags": [],
"nodes": [
{
"id": "409d8e05-ad6e-4b6f-ba9e-7e26fe070ec5",
"name": "Google Sheets 触发器",
"type": "n8n-nodes-base.googleSheetsTrigger",
"position": [
0,
0
],
"parameters": {
"event": "rowUpdate",
"options": {},
"pollTimes": {
"item": [
{
"mode": "everyMinute"
}
]
},
"sheetName": {
"__rl": true,
"mode": "id",
"value": "[YOUR_SHEET_NAME]"
},
"documentId": {
"__rl": true,
"mode": "url",
"value": "https://docs.google.com/spreadsheets/d/YOUR_SPREADSHEET_ID_HERE/edit"
}
},
"credentials": {
"googleSheetsTriggerOAuth2Api": {
"id": "y0YhoaKRGXeG1RfK",
"name": "temp"
}
},
"typeVersion": 1
},
{
"id": "f04569fe-ffd0-4ae5-b284-c71ce26a3f43",
"name": "内容参数",
"type": "n8n-nodes-base.set",
"position": [
224,
0
],
"parameters": {
"options": {},
"assignments": {
"assignments": [
{
"id": "f2c1b112-f4ae-40ec-a916-2a8d8af0cd76",
"name": "social_media_text_core",
"type": "string",
"value": "={{ $json.Title }} - {{ $json.Short_Description }}\\nRead more: {{ $json.URL }}\\n{{ $json.Hashtags }}"
}
]
}
},
"typeVersion": 3.4
},
{
"id": "3ce6b53b-43ad-4b9f-8a97-5e551501f8d5",
"name": "检查 Facebook 帖子",
"type": "n8n-nodes-base.if",
"position": [
448,
0
],
"parameters": {
"options": {},
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "6b10eac9-d290-4250-a573-8f2b6e0969f5",
"operator": {
"type": "boolean",
"operation": "true",
"singleValue": true
},
"leftValue": "={{ $json.Post_to_Facebook }}",
"rightValue": ""
}
]
}
},
"typeVersion": 2.2
},
{
"id": "97c1ef75-dcf9-4239-939a-947de498668c",
"name": "发布消息",
"type": "n8n-nodes-base.facebookGraphApi",
"position": [
672,
-96
],
"parameters": {
"edge": "={{ $json.social_media_text_core }}",
"node": "[YOUR_FACEBOOK_PAGE_ID]",
"options": {},
"httpRequestMethod": "POST"
},
"typeVersion": 1
},
{
"id": "cd54bbdc-25b7-47b5-9e84-b9bc94b95e66",
"name": "检查 Twitter 帖子",
"type": "n8n-nodes-base.if",
"position": [
672,
96
],
"parameters": {
"options": {},
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "097807a3-4bd8-4d58-b2d5-4d07691c8139",
"operator": {
"type": "boolean",
"operation": "true",
"singleValue": true
},
"leftValue": "={{ $json.Post_to_Twitter }}",
"rightValue": ""
}
]
}
},
"typeVersion": 2.2
},
{
"id": "4410a6ce-2687-4400-97fe-05903676325a",
"name": "创建推文",
"type": "n8n-nodes-base.twitter",
"position": [
896,
0
],
"parameters": {
"text": "={{ $json.social_media_text_core }}",
"additionalFields": {}
},
"credentials": {
"twitterOAuth2Api": {
"id": "i9ltvI3IKFGSIxYt",
"name": "temp"
}
},
"typeVersion": 2
},
{
"id": "d71eda0c-5b96-40ac-9e72-0a68c3dff971",
"name": "检查 LinkedIn 帖子",
"type": "n8n-nodes-base.if",
"position": [
896,
192
],
"parameters": {
"options": {},
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "35e581d3-16a2-4e9b-88ff-cc8aba9816d2",
"operator": {
"type": "boolean",
"operation": "true",
"singleValue": true
},
"leftValue": "={{ $json.Post_to_LinkedIn }}",
"rightValue": ""
}
]
}
},
"typeVersion": 2.2
},
{
"id": "930262d9-f0d2-44d1-b702-b95eb8baddcc",
"name": "分享更新",
"type": "n8n-nodes-base.linkedIn",
"position": [
1120,
192
],
"parameters": {
"text": "={{ $json.social_media_text_core }}\n{{ $json.URL }}",
"postAs": "organization",
"organization": "[YOUR_LINKEDIN_ORG_ID]",
"additionalFields": {},
"binaryPropertyName": "=",
"shareMediaCategory": "IMAGE"
},
"credentials": {
"linkedInOAuth2Api": {
"id": "XDjElJwF7bJz0ilR",
"name": "temp"
}
},
"typeVersion": 1
},
{
"id": "699e0dcc-ca88-463e-8cb7-6ed2942c8677",
"name": "更新发布状态",
"type": "n8n-nodes-base.googleSheets",
"position": [
1344,
192
],
"parameters": {
"columns": {
"value": {},
"schema": [],
"mappingMode": "defineBelow",
"matchingColumns": [],
"attemptToConvertTypes": false,
"convertFieldsToString": false
},
"options": {},
"operation": "append",
"sheetName": {
"__rl": true,
"mode": "name",
"value": "[YOUR_SHEET_NAME]"
},
"documentId": {
"__rl": true,
"mode": "id",
"value": "[YOUR_GOOGLE_SHEET_CONTENT_ID]"
}
},
"credentials": {
"googleSheetsOAuth2Api": {
"id": "MSnszF5oRAiSGHDo",
"name": "temp"
}
},
"typeVersion": 4.6
},
{
"id": "6218283b-1cbe-4e22-babe-334073a76ebc",
"name": "发送Slack通知",
"type": "n8n-nodes-base.slack",
"position": [
1568,
192
],
"webhookId": "20b1f158-7da3-43f5-ab62-444db7abfca4",
"parameters": {
"text": "=New content \"{{ $json.Title }}\" successfully published to social media! 🎉 Check: {{ $json.URL }}",
"select": "channel",
"channelId": {
"__rl": true,
"mode": "id",
"value": "[YOUR_SLACK_CHANNEL_ID]"
},
"otherOptions": {}
},
"credentials": {
"slackApi": {
"id": "AFKF0YsguyhsagR0",
"name": "temp"
}
},
"typeVersion": 2.3
},
{
"id": "1e56067d-18c2-4c40-926c-69e07c78fd9b",
"name": "便签",
"type": "n8n-nodes-base.stickyNote",
"position": [
-64,
-176
],
"parameters": {
"color": 3,
"width": 1840,
"height": 608,
"content": "# 流程"
},
"typeVersion": 1
},
{
"id": "cb142585-3cfb-4475-95f8-82d4e7ca5742",
"name": "便签1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-64,
496
],
"parameters": {
"color": 5,
"width": 1840,
"height": 3504,
"content": "# \"自动化社交媒体内容分发系统\""
},
"typeVersion": 1
}
],
"active": false,
"pinData": {},
"settings": {
"executionOrder": "v1"
},
"versionId": "3633890b-8499-45ab-ac18-321c35959730",
"connections": {
"Share Update": {
"main": [
[
{
"node": "Update Publication Status",
"type": "main",
"index": 0
}
]
]
},
"Check Twitter Post": {
"main": [
[
{
"node": "Create Tweet",
"type": "main",
"index": 0
}
],
[
{
"node": "Check LinkedIn Post",
"type": "main",
"index": 0
}
]
]
},
"Content Parameters": {
"main": [
[
{
"node": "Check Facebook Post",
"type": "main",
"index": 0
}
]
]
},
"Check Facebook Post": {
"main": [
[
{
"node": "Post Message",
"type": "main",
"index": 0
}
],
[
{
"node": "Check Twitter Post",
"type": "main",
"index": 0
}
]
]
},
"Check LinkedIn Post": {
"main": [
[
{
"node": "Share Update",
"type": "main",
"index": 0
}
]
]
},
"Google Sheets Trigger": {
"main": [
[
{
"node": "Content Parameters",
"type": "main",
"index": 0
}
]
]
},
"Update Publication Status": {
"main": [
[
{
"node": "Send Slack Notification",
"type": "main",
"index": 0
}
]
]
}
}
}常见问题
如何使用这个工作流?
复制上方的 JSON 配置代码,在您的 n8n 实例中创建新工作流并选择「从 JSON 导入」,粘贴配置后根据需要修改凭证设置即可。
这个工作流适合什么场景?
中级 - 社交媒体
需要付费吗?
本工作流完全免费,您可以直接导入使用。但请注意,工作流中使用的第三方服务(如 OpenAI API)可能需要您自行付费。
相关工作流推荐
智能内容与营销中心(含 GPT-4)
通过GPT-4自动化内容分析与多平台分发
Code
Merge
Twitter
+7
15 节点Marth
社交媒体
社交媒体工厂
基于AI的社交媒体内容创建器,支持多平台发布与审批
If
Set
Gmail
+15
48 节点Taiki
社交媒体
员工表彰自动化与Slack、Sheets和Gmail
使用 Slack、Sheets、Gmail 和可选 GPT-4 实现员工表彰自动化
If
Code
Gmail
+6
16 节点Marth
人力资源
基于 GPT-4 和 Stripe 发票的自动化智能现金流与账单管理系统
使用 GPT-4、Stripe 和 Google Workspace 的自动化发票工作流与智能提醒
If
Wait
Gmail
+7
16 节点Marth
发票处理
自动化潜在客户捕获、AI资质鉴定及ElevenLabs个性化语音跟进
基于 OpenAI 和 ElevenLabs 的自动化线索捕获与 AI 个性化语音跟进
If
Set
Code
+10
22 节点Marth
客户培育
帖子工厂
基于OpenAI、LinkedIn和Twitter审批的自动化社交媒体内容创作
If
Gmail
Slack
+10
22 节点Saloni Malhotra
社交媒体
工作流信息
难度等级
中级
节点数量12
分类1
节点类型9
作者
Marth
@marthSimplifying Business with Smart Automation. I create and share user-friendly, highly efficient n8n workflow templates for SMEs, focusing on digital marketing, sales, and operational excellence. Get ready to automate, innovate, and elevate your business. Connect me on Linkedin for custom solutions.
外部链接
在 n8n.io 查看 →
分享此工作流