WP - 已更新
高级
这是一个AI, Marketing领域的自动化工作流,包含 16 个节点。主要使用 If, Discord, Telegram, Wordpress, HttpRequest 等节点,结合人工智能技术实现智能自动化。 使用AI生成并发布SEO优化的WordPress博客文章
前置要求
- •Discord Bot Token 或 Webhook
- •Telegram Bot Token
- •可能需要目标 API 的认证凭证
- •OpenAI API Key
使用的节点 (16)
工作流预览
可视化展示节点连接关系,支持缩放和平移
导出工作流
复制以下 JSON 配置到 n8n 导入,即可使用此工作流
{
"id": "lZI2xknLPhHU6gZB",
"meta": {
"instanceId": "c2650793f644091dc80fb900fe63448ad1f4b774008de9608064d67294f8307c",
"templateCredsSetupCompleted": true
},
"name": "WP - 已更新",
"tags": [],
"nodes": [
{
"id": "a7e0b3f7-7b86-4e94-b5c5-104cb92a332f",
"name": "主题选择器和标题生成器",
"type": "@n8n/n8n-nodes-langchain.chainLlm",
"position": [
320,
-320
],
"parameters": {
"text": "Do as instructed!",
"messages": {
"messageValues": [
{
"message": "=You are an expert SEO blog writer for “Dax AI,” specializing in Technology and Artificial Intelligence content. For each request, you must:\n\n1. Randomly select one category (exactly as shown):\n – Technology\n – Artificial Intelligence (AI)\n – Tech Fact\n – Tech History\n – Tech Tips\n\n2. Create:\n • A unique, non-robotic article title (no colons “:”, clickbait is OK but don’t exaggerate). \n • A URL-friendly slug (lowercase, hyphens). \n • A focus keyphrase (max 2 words, capturing the main idea). \n • A meta description (≤160 characters, summarizing the article).\n\n3. Use the current year placeholder {{ $json.Year }} if needed in the title.\n\nOutput exactly in this format:\nCategory: <chosen category>\nTitle: <your title>\nSlug: <your-slug>\nFocus Keyphrase: <max 2 words>\nMeta Description: <≤160 characters>"
}
]
},
"promptType": "define",
"hasOutputParser": true
},
"typeVersion": 1.6
},
{
"id": "55642750-4403-4868-a263-6e08bf6fbb05",
"name": "基础 LLM 链",
"type": "@n8n/n8n-nodes-langchain.chainLlm",
"position": [
640,
-320
],
"parameters": {
"text": "=Write a comprehensive, 1,500–2,500-word article using the following inputs:\n\n• Title: {{ $json.output.title }}\n• Category: {{ $json.output.category }}\n• Focus Phrase: {{ $json.output.focus_phrase }}\n\nRequirements:\n\nTitle:\n – Craft an engaging title that includes the focus phrase.\n - Do not add title in the body\n\nIntroduction (100–150 words)\n - Dont use word \"Introduction\"\n – Hook the reader.\n – Include the focus phrase.\n\nBody Structure\n - Do Not Add Title In the body\n – Use 4–6 H2 subheadings, with 1–2 H3s beneath each as needed.\n – Ensure the focus phrase appears in at least one H2 or H3.\n – Sprinkle the focus phrase naturally throughout—minimum 4 times, maximum 16 times.\n – Use bullet lists, examples, data or quotes to illustrate key points.\n - add outbound link if available\n\nTone & Style\n – Friendly yet authoritative.\n – Clear, concise paragraphs (2–4 sentences each).\n – Smooth transitions and varied sentence structure.\n\nConclusion & Call to Action\n - Don't use starting \"Conclusion\"\n – Summarize the key takeaways.\n – End with a compelling call to action or next step.\n - add available to contact cta (\"khmuhtadin.com\")\n\nEnsure flawless grammar, optimal keyword density, and readability for a general audience.",
"messages": {
"messageValues": [
{
"message": "=You are an elite blog writer for Dax AI, tasked with producing highly valuable, SEO-optimized, audience-focused long-form articles suitable for direct publication in WordPress. When given a topic or title, follow these rules precisely:\n\n1. Content Focus\n - Deliver practical tips, clear strategies, in-depth insights or step-by-step guides directly related to the topic.\n - Prioritize original, actionable advice that readers can implement immediately.\n\n2. Article Length & Structure\n - Minimum 1,500 words.\n - Use clear hierarchical headings (H2, H3, H4) to organize sections and subsections.\n - Ensure each section flows logically, with introductions, transitions, and conclusions where appropriate.\n\n3. SEO Optimization\n - Make content scannable: use short paragraphs, subheadings, and bulleted or numbered lists.\n - Naturally incorporate relevant keywords without keyword stuffing.\n - Write an engaging, concise meta description (under 160 characters) at the top.\n\n4. WordPress-Compatible Formatting\n - Output plain text only—no Markdown, no code fences, no additional commentary.\n - Format headings as WordPress recognizes (e.g., “<h2>Section Title</h2>” or using the WordPress editor’s native heading styles).\n - For lists, use a simple dash or number followed by a space (e.g., “– Android Automation Apps:” or “1. Step one”) never make it bols (e.g., \"- **product 1**\").\n - Do not include the article title, any author bylines, or any formatting instructions—only the body content.\n\n5. Final Output\n – Only the article body in ready-to-publish WordPress format.\n – No extra notes, disclaimers, or explanations.\n – Confirm compliance by immediately starting with the first section heading when writing.\n"
}
]
},
"promptType": "define"
},
"typeVersion": 1.6
},
{
"id": "3ab3b38b-0627-4a92-a3c2-75776cd896cc",
"name": "主题选择器和标题生成器解析器",
"type": "@n8n/n8n-nodes-langchain.outputParserStructured",
"position": [
500,
-120
],
"parameters": {
"jsonSchemaExample": "{\n\t\"category\": \"Technology\",\n\t\"title\": \"Article Title\",\n \"slug\": \"article-slug\",\n\t\"focus_phrase\": \"focus phrase for SEO\",\n\t\"meta_description\": \"meta description under 160 characters\"\n}"
},
"typeVersion": 1.2
},
{
"id": "f5bafe2f-ac4b-42e5-9c23-506b02115060",
"name": "WordPress 文章草稿",
"type": "n8n-nodes-base.wordpress",
"position": [
340,
20
],
"parameters": {
"title": "={{ $('Topic Chooser and Title Maker').item.json.output.title }}",
"additionalFields": {
"slug": "={{ $('Topic Chooser and Title Maker').item.json.output.slug }}",
"format": "standard",
"status": "publish",
"content": "={{ $json.text }}",
"authorId": 1,
"categories": "={{ $('Topic Chooser and Title Maker').item.json.output.category == \"Technology\" ? [3] :\n $('Topic Chooser and Title Maker').item.json.output.category == \"Artificial Intelligence (AI)\" ? [4] :\n $('Topic Chooser and Title Maker').item.json.output.category == \"Tech Fact\" ? [7] :\n $('Topic Chooser and Title Maker').item.json.output.category == \"Tech History\" ? [8] :\n $('Topic Chooser and Title Maker').item.json.output.category == \"Tech Tips\" ? [9] : [1] }}"
}
},
"credentials": {
"wordpressApi": {
"id": "gGfRrkCtaoISRmDr",
"name": "Wordpress account"
}
},
"typeVersion": 1
},
{
"id": "34fcbcf7-a734-4b7d-9421-0371f56de25d",
"name": "OpenAI - 生成图片",
"type": "@n8n/n8n-nodes-langchain.openAi",
"position": [
540,
20
],
"parameters": {
"prompt": "=Create a highly realistic, natural-looking image that visually represents the blog article titled \"{{ $json.title.raw }}\". The image should be grounded in reality with believable lighting, textures, and composition—avoid fantasy or surreal elements. Focus on lifelike details that a real camera could capture. Do not include any text in the image.",
"options": {
"size": "1024x1024",
"style": "vivid"
},
"resource": "image"
},
"credentials": {
"openAiApi": {
"id": "xgxbqurhU1VXjSge",
"name": "OpenAi account"
}
},
"typeVersion": 1.8
},
{
"id": "a860c065-448a-44f6-83de-6a739380c731",
"name": "上传图片到 WP",
"type": "n8n-nodes-base.httpRequest",
"position": [
740,
20
],
"parameters": {
"url": "https://cartilo.my.id/wp-json/wp/v2/media",
"method": "POST",
"options": {},
"sendBody": true,
"contentType": "binaryData",
"sendHeaders": true,
"authentication": "predefinedCredentialType",
"headerParameters": {
"parameters": [
{
"name": "Content-Type",
"value": "image/png"
},
{
"name": "Content-Disposition",
"value": "=attachment; filename={{$now.toMillis()}}.png"
}
]
},
"inputDataFieldName": "data",
"nodeCredentialType": "wordpressApi"
},
"credentials": {
"wordpressApi": {
"id": "gGfRrkCtaoISRmDr",
"name": "Wordpress account"
}
},
"typeVersion": 4.2
},
{
"id": "638a51ea-dedf-4734-8e12-c1fc0d76b794",
"name": "WordPress - 设置特色图片",
"type": "n8n-nodes-base.httpRequest",
"position": [
940,
0
],
"parameters": {
"url": "=https://cartilo.my.id/wp-json/wp/v2/posts/{{ $('Wordpress Post Draft').item.json.id }}",
"method": "POST",
"options": {},
"sendBody": true,
"authentication": "predefinedCredentialType",
"bodyParameters": {
"parameters": [
{
"name": "featured_media",
"value": "={{ $json.id }}"
}
]
},
"nodeCredentialType": "wordpressApi"
},
"credentials": {
"wordpressApi": {
"id": "gGfRrkCtaoISRmDr",
"name": "Wordpress account"
}
},
"typeVersion": 4.2
},
{
"id": "cf9ed09e-aca1-496b-8b39-a1290f912bbf",
"name": "计划触发器",
"type": "n8n-nodes-base.scheduleTrigger",
"position": [
-80,
-140
],
"parameters": {
"rule": {
"interval": [
{
"field": "hours",
"hoursInterval": 3
}
]
}
},
"typeVersion": 1.2
},
{
"id": "3a661537-7bf8-4f05-9869-c2ed0f4f497d",
"name": "标题、分类、元数据、关键词生成器",
"type": "@n8n/n8n-nodes-langchain.lmChatOpenRouter",
"position": [
340,
-120
],
"parameters": {
"model": "google/gemini-2.5-flash-preview",
"options": {}
},
"credentials": {
"openRouterApi": {
"id": "DPrHlBN0s5WFDxi9",
"name": "OpenRouter account"
}
},
"typeVersion": 1
},
{
"id": "14ac3e7a-5830-4f36-98ce-672c1442cba8",
"name": "使用 Webhook 发送到 Discord",
"type": "n8n-nodes-base.discord",
"position": [
1180,
-60
],
"webhookId": "722513b9-8a0c-4ba1-b0ee-c712d8fb0af6",
"parameters": {
"embeds": {
"values": [
{}
]
},
"content": "=Published!\n{{ $json.link }}",
"options": {},
"authentication": "webhook"
},
"credentials": {
"discordWebhookApi": {
"id": "LLZlMnlqvhY0SVaL",
"name": "Discord Webhook account"
}
},
"typeVersion": 2
},
{
"id": "9a1bd821-e55f-4448-b4ba-a827e7a0724c",
"name": "文章生成器",
"type": "@n8n/n8n-nodes-langchain.lmChatOpenAi",
"position": [
660,
-120
],
"parameters": {
"model": {
"__rl": true,
"mode": "list",
"value": "gpt-4.1-mini",
"cachedResultName": "gpt-4.1-mini"
},
"options": {}
},
"credentials": {
"openAiApi": {
"id": "xgxbqurhU1VXjSge",
"name": "OpenAi account"
}
},
"typeVersion": 1.2
},
{
"id": "4ef52544-155b-4192-9fe3-243503c3f83e",
"name": "Telegram 触发器",
"type": "n8n-nodes-base.telegramTrigger",
"position": [
-180,
-380
],
"webhookId": "a9b697dc-5b4e-418c-83ed-54966ce7ea34",
"parameters": {
"updates": [
"message"
],
"additionalFields": {}
},
"credentials": {
"telegramApi": {
"id": "7yvBdfOsTDXmqA4b",
"name": "motun8nwpbot"
}
},
"typeVersion": 1.2
},
{
"id": "29fd6900-3f7c-4efa-83bf-93297239c425",
"name": "条件判断",
"type": "n8n-nodes-base.if",
"position": [
0,
-380
],
"parameters": {
"options": {},
"conditions": {
"options": {
"version": 2,
"leftValue": "",
"caseSensitive": true,
"typeValidation": "strict"
},
"combinator": "and",
"conditions": [
{
"id": "3dbc34fc-8457-422f-807e-123b5f16bd0c",
"operator": {
"name": "filter.operator.equals",
"type": "string",
"operation": "equals"
},
"leftValue": "={{ $json.message.text }}",
"rightValue": "generate"
}
]
}
},
"typeVersion": 2.2
},
{
"id": "89058ee2-9400-4b32-8cf4-d1a5796a003b",
"name": "Telegram",
"type": "n8n-nodes-base.telegram",
"position": [
1180,
160
],
"webhookId": "29c01d67-35b0-4234-92dd-c729fcb6fe7e",
"parameters": {
"text": "=Published!\n\n{{ $json.link }}",
"chatId": "={{ $('Telegram Trigger').item.json.message.chat.id }}",
"additionalFields": {}
},
"credentials": {
"telegramApi": {
"id": "7yvBdfOsTDXmqA4b",
"name": "motun8nwpbot"
}
},
"typeVersion": 1.2
},
{
"id": "3e8fb441-91eb-4697-840d-9dc0741b43cc",
"name": "便签",
"type": "n8n-nodes-base.stickyNote",
"position": [
-180,
-680
],
"parameters": {
"width": 760,
"height": 260,
"content": "## 工作流描述"
},
"typeVersion": 1
},
{
"id": "fd604313-c4c8-4d02-b7e9-2fc7229608e2",
"name": "便签1",
"type": "n8n-nodes-base.stickyNote",
"position": [
-200,
240
],
"parameters": {
"width": 620,
"height": 280,
"content": "## 设置说明"
},
"typeVersion": 1
}
],
"active": true,
"pinData": {},
"settings": {
"executionOrder": "v1"
},
"versionId": "b5690cda-0809-43c5-a799-f6ffe1689389",
"connections": {
"If": {
"main": [
[
{
"node": "Topic Chooser and Title Maker",
"type": "main",
"index": 0
}
]
]
},
"Basic LLM Chain": {
"main": [
[
{
"node": "Wordpress Post Draft",
"type": "main",
"index": 0
}
]
]
},
"Schedule Trigger": {
"main": [
[
{
"node": "Topic Chooser and Title Maker",
"type": "main",
"index": 0
}
]
]
},
"Telegram Trigger": {
"main": [
[
{
"node": "If",
"type": "main",
"index": 0
}
]
]
},
"Article Generator": {
"ai_languageModel": [
[
{
"node": "Basic LLM Chain",
"type": "ai_languageModel",
"index": 0
}
]
]
},
"Upload Image to WP": {
"main": [
[
{
"node": "Wordpress - Set Featured Image",
"type": "main",
"index": 0
}
]
]
},
"Wordpress Post Draft": {
"main": [
[
{
"node": "OpenAI - Generate Image",
"type": "main",
"index": 0
}
]
]
},
"OpenAI - Generate Image": {
"main": [
[
{
"node": "Upload Image to WP",
"type": "main",
"index": 0
}
]
]
},
"Send to Discord Using Webhook": {
"main": [
[]
]
},
"Topic Chooser and Title Maker": {
"main": [
[
{
"node": "Basic LLM Chain",
"type": "main",
"index": 0
}
]
]
},
"Wordpress - Set Featured Image": {
"main": [
[
{
"node": "Send to Discord Using Webhook",
"type": "main",
"index": 0
},
{
"node": "Telegram",
"type": "main",
"index": 0
}
]
]
},
"Topic Chooser and Title Maker Parser": {
"ai_outputParser": [
[
{
"node": "Topic Chooser and Title Maker",
"type": "ai_outputParser",
"index": 0
}
]
]
},
"Title, category, meta, keyphrase generator": {
"ai_languageModel": [
[
{
"node": "Topic Chooser and Title Maker",
"type": "ai_languageModel",
"index": 0
}
]
]
}
}
}常见问题
如何使用这个工作流?
复制上方的 JSON 配置代码,在您的 n8n 实例中创建新工作流并选择「从 JSON 导入」,粘贴配置后根据需要修改凭证设置即可。
这个工作流适合什么场景?
高级 - 人工智能, 营销
需要付费吗?
本工作流完全免费,您可以直接导入使用。但请注意,工作流中使用的第三方服务(如 OpenAI API)可能需要您自行付费。
相关工作流推荐
SEO 友好 - WordPress 文章生成器
生成并发布 SEO 优化的博客文章到 WordPress
If
Discord
Telegram
+11
18 节点Khairul Muhtadin
人工智能
博客闪电战Runware
使用OpenRouter和Runware自动生成并发布SEO博客文章到WordPress
Discord
Telegram
Wordpress
+8
23 节点Khairul Muhtadin
人工智能
WordPress + 社交媒体
基于GPT/Gemini和WordPress的自动化博客创建与多平台发布
If
Set
Switch
+18
44 节点Khairul Muhtadin
内容创作
博客闪电战:博主版
使用 OpenAI 和 DALL-E 生成 SEO 优化的博客文章并发布到 Blogger
Set
Code
Telegram
+7
19 节点Khairul Muhtadin
人工智能
智能资金管理器
基于Telegram、Google Sheets和OpenAI的AI驱动收据和支出追踪器
If
Set
Code
+13
50 节点Khairul Muhtadin
财务
YouTube 摘要生成器
YouTube 视频转录与摘要生成器,使用 GPT-4o 发送至 Telegram
Telegram
Http Request
Supadata
+5
10 节点Khairul Muhtadin
人工智能