Templates / Auto-generate & publish SEO articles to WordPress with GPT-4 + Postgres tracking

Auto-generate & publish SEO articles to WordPress with GPT-4 + Postgres tracking

Needs changes

by AlexWantMoreB Β· 4,528 views Β· created 2025-05-06 Β· Content Creation, Multimodal AI

Needs changes. This template uses 1 thing(s) that n8n 3.0 removes: AI Agent v1 (old agent modes). 1 breaking item(s) found. Static check, last run 2026-10-19.

What to replace before upgrading

Removed in 3.0Replace with
AI Agent v1 (old agent modes)
AI Agent SEO Headings (v1.9), AI Agent SEO writer (v1.9)
Latest AI Agent node (Tools Agent). For SQL Agent, use a Postgres or MySQL tool with a recent AI Agent.

Nodes used (9)

OpenAI Chat ModelPostgresAI Agent

What it does

πŸš€ What this flow does β€’ πŸ”Ž Selects the least-used WordPress category (tracked in PostgreSQL) β€’ πŸ€– Uses GPT (4-mini or better) to generate a fully formatted SEO article with headings, TOC, lists, CTA, and Yoast blocks β€’ πŸ–ΌοΈ Creates a placeholder cover image and uploads it to WordPress Media β€’ πŸ“¬ Publishes the final post via /wp-json/wp/v2/posts with correct category + featured image β€’ 🧠 Logs the used category for future rotation (zero duplicates!) βš™οΈ Setup in 3 mins 🏷️ Add your WordPress domain with a simple Set node: domain=https://yourdomain.com πŸ” Create these 3 credentials in n8n: YOURWORDPRESSCREDENTIAL β€” for /media, /posts YOURPOSTGRESCREDENTIAL β€” for category tracking YOUROPENAICREDENTIAL β€” GPT-4-mini or better 🧱 Run the SQL from docs to create the usedcategories table βœ… Manually test first 3–5 nodes to check WP auth, OpenAI response, and DB connection πŸ•’ Then just schedule it and let the bot write for you. 🎯 Why it's awesome This is your personal AI content writer + publisher β€” perfect for: β€’ πŸ“° SEO content farms β€’ πŸ“ˆ Affiliate blogs β€’ 🧰 Micro niche sites β€’ 🀫 PBNs with rotation-safe automation No more manual uploads, broken categories, or GPT spam. Every post is structured, beautiful, and intelligently categorized.

View the original on n8n.io β†’ Check your own copy

Get the weekly β€œwhat broke” email

New templates, newly broken ones, and n8n release changes. One short email a week.

Form not loading? Subscribe here.