π§ n8n Blog Automation Workflow
π§ n8n Blog Automation Workflow β GPT-5 Optimized
This is a ready-to-use, single workflow β you can copy and paste it directly into n8n and start working.
It handles end-to-end SEO blog automation with triggers, orchestration, AI-powered writing, metadata, tags, excerpts, WordPress publishing, and Google Sheets updates.
π Overview
The system accepts blog parameters either from a form submission or from a Google Sheet row (via scheduled trigger), dynamically fetches WordPress categories, and produces a complete, publication-ready post through an orchestrated sequence of GPT-5 agents.
Each agent executes once in a strict order with clearly defined responsibilities.
Core Capabilities
- Real-time search and fact retrieval (OpenRouter / Perplexity Sonar)
- SEO-focused outline planning
- Structured section creation
- Expert-level section writing with inline HTML citations
- Editorial refinement into cohesive, polished HTML
- Metadata, excerpt, and featured-image prompt generation
- Automated category, tag creation/update, and excerpt update
- Draft publishing to WordPress
- Updates the corresponding Google Sheet row with
created = yes
π Triggers
1. Form Trigger
Collects:
- Keywords
- Word count
- Number of sections
- Writing style
- Website URL
- About Website (used for context)
- Featured image toggle
2. Google Sheets + Schedule Trigger
Automatically pulls rows on schedule from a Google Sheet with the following columns:
- Keywords
- wordCount
- Number of sections
- Generate a featured image
- Writing Style
- Website
- About Website
- created β initially set to no, automatically updated to yes once the blog post is created and uploaded to WordPress.
π§ Orchestration Agent (GPT-5)
Central Director agent optimized for GPT-5 that coordinates the pipeline:
- GetOnlineInfo β Current Q&A and search-driven insights
- OutlinePlanner β SEO-structured Table of Contents
- createSections β ToC β detailed section definitions
- SectionsWriter β Expert, citation-rich content
- Editor β Full HTML assembly, SEO and legal compliance
- MetaInfo β Title, slug, excerpt, meta description, category selection
- Tags Agent β Creates or updates SEO-friendly WordPress tags
- ImagePrompt β Realistic cover image prompt + alt text (if enabled)
βοΈ Writing Flow
- Input parsing (from Form or Google Sheets row)
- Real-time data retrieval
- SEO-optimized outline creation
- Section breakdown with clear descriptions
- Detailed section drafting with verified sources
- Editorial polishing into publish-ready HTML
- Metadata and excerpt generation (title, slug, description, category)
- Tag creation and update in WordPress
- Optional image prompt creation and upload
- Automatic WordPress draft publishing with excerpt and tags updated
- Google Sheet row update β set
created = yes
β Output Format
{
"toc": "Table of Contents",
"post_html": "<final HTML content>",
"meta_data": {
"title": "...",
"slug": "...",
"description": "..."
},
"image_data": {
"image_prompt": "...",
"alt_text": "..."
},
"ready": true
}π WordPress Integration
- Authenticated API calls to
/wp-json/wp/v2/posts,/wp-json/wp/v2/media, and/wp-json/wp/v2/tags - Draft mode publishing with category & author assignment
- Featured image creation, resizing, and metadata linking (if enabled)
- Automatic creation and update of tags
- Automatic creation and update of excerpts
π§© Setup Instructions
1. Required Credentials
- WordPress API credentials
- OpenAI API key
- OpenRouter API key (optional)
- Google Sheets API credentials (if using scheduled trigger)
2. Sub-Workflows Required
- OutlinePlanner
- createSections
- SectionsWriter
- Editor
- MetaInfo
- Tags Agent
- ImagePrompt (if enabled)
3. Dynamic Inputs
- Categories fetched via WP REST API and shown in the form
- Tags generated and updated dynamically by Tags Agent
- Excerpt automatically created and updated in WordPress
- Image creation can be toggled (true / false)
πΈ Optional Image Pipeline
If enabled:
- Generate image prompt and alt text
- Create realistic cover image (1024x1024)
- Resize and upload image to WordPress
- Set image metadata and assign featured image
π‘ Notes
- Workflow is production-ready β just copy-paste into n8n as a single workflow.
- GPT-5 prompts embedded in each agent ensure high-quality, context-aware output
- All HTML, JSON, excerpts, and tags are validated before publication
- Modular sub-workflows allow isolated testing and debugging
- Workflow supports legal accuracy, SEO performance, and dynamic web data responsiveness
π Executive Summary β GPT-5 Blog Automation Workflow Our n8n-powered, GPT-5-optimized blog automation pipeline takes simple inputs (keywords, style, sections, word count) and produces SEO-optimized, citation-rich WordPress articlesβfully formatted and ready for publication. Key Highlights GPT-5 Role-Specific Agents β Specialized prompts for research, outlining, writing, editing, metadata, and image generation. Real-Time Data Integration β Uses live search for factual accuracy and topical relevance. Structured Content Flow β From keyword to outline to polished HTML with citations and internal links. Automated Publishing β Draft posts created in WordPress with categories, authors, and optional AI-generated cover images. Quality Control Built-In β All outputs validated for SEO, readability, and legal accuracy before publishing. This workflow delivers end-to-end, high-quality blog creation with minimal manual intervention, ideal for scaling professional content production.