ChatGPT创意写作AI 评分 · 待评分AI 辅助编辑·未发现明显提示词注入风险n8n.io

从关键词列表批量生成 SEO 文章并发布到 Webflow

输入:Google Sheets 关键词列表 → 处理:n8n AI Agent 生成内容+配图 → 输出:Webflow 草稿 + 结果记录

有一点经验步骤流程提示词贴士
给谁
内容营销人员和 SEO 专员,需要批量生成长尾关键词变体的优化文章
你会得到
自动将关键词转为 600+ 字的 SEO 文章和配图,以草稿形式存入 Webflow,并记录成功/失败结果
你需要
n8n · google-sheets · google-drive · webflow

硬约束

需要 n8n 实例、OpenAI API 密钥、OpenRouter API 密钥(或类似 Gemini 访问方式)、Webflow OAuth2 应用、Google Sheets 和 Google Drive OAuth2 凭证。主工作流需配合独立导入的「AI image generation」子工作流使用。模板默认每月触发,可调整。

他们做了什么

作者创建了 n8n 模板,通过 Schedule Trigger 按月触发,从 Google Sheets 读取 status=pending 的关键词列表,经 Loop Over Items 逐条送入 AI Agent。AI Agent 使用 gpt-4.1-mini 生成 600-800 字的 SEO 文章(含标题、元描述、结构化正文),并通过 toolWorkflow 调用独立的图像生成子工作流,由 OpenRouter 上的 Gemini 2.5 Flash 生成配图并上传至 Google Drive。主工作流对 Agent 输出做 JSON 清洗和字数检查,不足 600 词时由 gpt-4o-mini 扩展;随后将 markdown 转为 HTML,调用 Webflow API 创建草稿,并将成功/失败结果分别记录到 Google Sheets。

效果如何

模板作者报告该工作流可自动生成 600+ 字的 SEO 文章并创建 Webflow 草稿,支持批量处理长尾关键词变体(作者报告,未经验证)。

值得知道

1. 子工作流必须独立导入并在 AI Agent 的 Tool 节点中显式选择,不可嵌套在同一工作流内运行(来源 Important 提示)。 2. 图像生成依赖 OpenRouter 的 Gemini 2.5 Flash 预览版模型,若该模型或端点变更,需手动调整 HTTP Request 节点的 URL 和 jsonBody。 3. 默认 Schedule Trigger 为每月执行,批量处理前务必用单条关键词验证全链路。 4. Webflow OAuth2 配置较复杂,需在 Webflow 侧创建应用并授予 CMS 读写权限;siteId 和 collectionId 需在 Webflow Designer 或 CMS 设置中获取。 5. 本站未实测该工作流,reproduction 状态为 not_tested;实际运行中需关注 OpenAI 和 OpenRouter 的 API 费用及速率限制。

n8n 工作流模板

结构已检查 · 未实际运行

下载后在 n8n 选择“Import from File”,或复制 JSON 后粘贴到编辑器。先配置自己的账号,再用测试数据运行;模板默认未启用。

配置与测试清单

需要绑定的凭证

  • OpenAI Chat Model 节点:绑定OpenAI API 凭证。
  • Load Pending Keywords 节点:绑定Google Sheets OAuth2 凭证。
  • Expand Content 节点:绑定OpenAI API 凭证。
  • Create New Post 节点:绑定webflowOAuth2Api 凭证。
  • Mark as Complete 节点:绑定Google Sheets OAuth2 凭证。
  • Save Success Results 节点:绑定Google Sheets OAuth2 凭证。
  • Save Error 节点:绑定Google Sheets OAuth2 凭证。
  • Upload to Google Drive 节点:绑定Google Drive OAuth2 凭证。
  • Get Download Links 节点:绑定Google Drive OAuth2 凭证。

需要替换的配置

  • 源模板来自 n8n 公开库 #9191(约 43 个节点)。导入后先保持未启用,核对触发器、表达式与外部 API 端点。
  • Sticky Note 中的说明仅供参考;按自己的账号、表结构或频道 ID 替换占位配置。

测试输入与预期结果

  • 在测试环境手动执行一次主路径,确认每个需凭证的节点已连接且无鉴权错误。
  • 用一条合成/脱敏样例数据跑通,核对输出字段与下游写入目标,再考虑生产启用。

模板处理说明

  • 已移除原作者凭证绑定、webhookId 与执行数据,工作流设为未启用;节点、连线与原文提示词保持原样。未在 n8n 中实际运行。
  • 未改业务逻辑;运行前请自行核对密钥、配额与隐私合规。

模板获取日期: 2026-10-24

步骤

  1. 导入主工作流和图像子工作流

    在 n8n 中分别导入两个工作流:主工作流「Bulk SEO content generation and Webflow draft creation with AI images」和子工作流「AI image generation for automatic content creation」。子工作流必须作为独立工作流存在,后续在主工作流的 AI Agent 工具节点中引用。

    运行提示词 · 来源原文。使用前确认粘贴位置、输入变量及输出格式。

    =Current date and time: {{$now}}
    
    TASK: Create high-quality SEO content and generate a relevant featured image for the keyword below.
    
    Keyword: {{ $json['main keyword'] }}
    
    Requirements:
    1. Write 600-800 words of engaging, professional but accessible content.
    2. Include the keyword naturally 2-3 times: once in the introduction, once in a subheading, and once in the conclusion.
    3. Create a compelling title (50-60 characters).
    4. Write a meta description (150-160 characters).
    5. Structure the article with clear sections:
       - Introduction
       - Key Benefits
       - How It Works / Practical Advice
       - Conclusion / Next Steps
    6. Target audience: general readers searching for this keyword (not academic or overly technical).
    7. Generate ONE relevant professional image. The image should:
       - Visually represent the keyword topic (not generic SEO/marketing visuals)
       - Use a clean, modern, professional style
       - Be suitable as a blog featured image
       - IMPORTANT: Generate only ONE image per article
    
    CRITICAL: Call the image generation tool exactly ONCE per article. Do not generate multiple images or variations.
    
    8. Provide descriptive **alt text** for the image, optimized for accessibility and SEO.
    
    Output Format:
    Return ONLY this valid JSON structure as raw JSON (no markdown code blocks, no json tags, no extra text, notes, or explanations):
    {
    "title": "SEO optimized title here",
    "slug": "{{ $('Load Pending Keywords').item.json.slug }}", 
    "metaDescription": "Compelling meta description here",
    "content": "Full article content here (600-800 words). CRITICAL FORMATTING REQUIREMENTS: Start with ### Introduction as the first heading. Use ### for ALL section headings (Key Benefits, How It Works / Practical Advice, Conclusion / Next Steps). Write complete paragraphs separated by blank lines. Never mix plain text with markdown formatting. Each section must have substantial content with specific examples and actionable advice. Include the target keyword naturally 2-3 times throughout the content. Ensure consistent markdown structure from start to finish.",
    "main keyword": "{{ $json['main keyword'] }}",
    "imageUrl": "URL from image generation tool", 
    "altText": "Descriptive and SEO-friendly alt text here"
    }
    
    FORMATTING VALIDATION: Before returning JSON, verify that:
    1. Content starts with ### Introduction 
    2. All headings use ### format consistently
    3. Each paragraph is properly separated with blank lines
    4. No mixing of plain text and markdown syntax
    5. Content flows logically between sections
    6. Target keyword appears naturally in introduction and conclusion
    
    CRITICAL: Your response must start with { and end with }. Do not wrap the JSON in markdown formatting or code blocks. Return the raw JSON object only.

    运行提示词 · 来源原文。使用前确认粘贴位置、输入变量及输出格式。

    You are an expert SEO content writer and AI coordinator. Your responsibilities: Always follow the Agent Prompt exactly. Always generate both content and a relevant professional image. Always return valid JSON only, with no extra commentary or notes. Never skip image generation. Never output incomplete or invalid JSON. Ensure the content is engaging, structured, and optimized for readers searching for the keyword.
  2. 配置 Google Sheets 结构

    按模板要求创建或克隆 Google Sheets,包含三个工作表: - `keywords`:id, main keyword, head terms, modifiers, slug, status(status 列用于标记 pending/created) - `content_created`:id, slug, meta description, content, generatedAt, updated on - `webflow_error_logs`:keyword, error, timestamp, status 将 keywords 中待处理行的 status 设为 pending。

  3. 添加 API 凭证

    在 n8n Credentials 中配置以下凭证: - OpenAI API(用于内容生成) - OpenRouter API 或等效 Gemini 访问(用于图像生成子工作流) - Webflow OAuth2 API(需先在 Webflow 创建应用,复制 Client ID/Secret 和 OAuth Redirect URL) - Google Sheets OAuth2 - Google Drive OAuth2 Webflow OAuth 详细步骤:在 n8n 创建 Webflow OAuth2 API 凭证并复制 Redirect URL → 在 Webflow Workspace Settings → Apps & Integrations → Develop 创建应用 → 开启 Data Client REST API → 粘贴 Redirect URL → 选择 CMS collections 读写权限 → 将 Client ID/Secret 填入 n8n。

  4. 更新工作流节点配置

    在主工作流和子工作流中更新以下参数: - 所有 Google Sheets 节点:替换为正确的 documentId 和 sheetName - Webflow Create/Update Post 节点:填入你的 siteId 和 collectionId - 子工作流中的 Google Drive 节点:设置目标 folderId - AI Image Generation Tool 节点:确认 workflowId 指向已导入的子工作流 - 可选:调整 Loop Over Items 的批次大小、Content Quality Check 的字数阈值(默认 600)、Schedule Trigger 的执行频率(默认每月)

  5. 测试单个关键词

    在 keywords 表中只保留一行 status=pending 的测试数据,手动触发工作流运行。检查: - AI Agent 是否成功生成 JSON 格式的文章数据 - 图像子工作流是否返回 Google Drive 图片链接 - Content Quality Check 是否通过(≥600 词) - Webflow 是否成功创建草稿 - 结果是否正确记录到 content_created 或 webflow_error_logs 若内容不足 600 词,Expand Content 节点会自动调用 gpt-4o-mini 扩展。

  6. 启用定时生产运行

    测试通过后,启用 Schedule Trigger(默认每月执行)。工作流将自动读取所有 status=pending 的关键词,逐条生成文章和配图,转换为 HTML 后创建 Webflow 草稿,更新 keywords 状态,并记录结果。建议在初期监控 webflow_error_logs 表中的错误条目。

可复制提示词

搭建指导 · 本站建议版本。交给搭建助手,先确认输入和权限

这一段是提示词,页面不会在这里插入广告。

你是一个 n8n 工作流搭建助手。用户希望复现「从关键词列表批量生成 SEO 文章并发布到 Webflow」的模板。请按以下顺序协助:
1. 确认用户已准备好 n8n 实例和全部 API 凭证(OpenAI、OpenRouter/Gemini、Webflow OAuth2、Google Sheets、Google Drive)。
2. 指导用户分别导入主工作流和图像生成子工作流,并强调子工作流必须独立存在、通过 AI Agent 的 Tool 节点调用。
3. 协助配置 Google Sheets 的三表结构和示例数据。
4. 逐步检查各节点的 documentId、siteId、collectionId、folderId 等关键参数是否已替换为用户真实值。
5. 建议先用单个关键词测试,观察 Process Agent Output → Content Quality Check → Expand Content(如需要)→ Convert to HTML → Create New Post 的完整链路。
6. 若遇到 JSON 解析错误,检查 AI Agent 输出是否被 markdown 代码块包裹;Process Agent Output 节点已包含清洗逻辑,但可手动验证。

搭建前请确认所有 OAuth 应用已授权,且 Webflow CMS collection 字段(name, slug, page-content, metadescription, featured-image)与模板映射一致。

来源

Generate SEO blog posts from a keyword list and publish to Webflow · mssporto · n8n.io · 2025-10-02

留言与反馈

试过这个方法吗?分享效果、遇到的问题或改进建议。留言审核后公开,请勿填写敏感信息。

正在加载…

    相关用例