This capstone project builds a complete, production-grade content automation pipeline that covers the entire lifecycle: from topic selection to Google indexing. It combines every skill from the previous five modules.
What the system does:
- Reads pending topics from an Airtable content calendar
- Uses Claude to generate a 1,200-word SEO-optimized article
- Uses GPT-4o to generate the SEO title, meta description, and social media posts (4 platforms)
- Publishes the article to WordPress via REST API
- Posts to Facebook Page, LinkedIn, Twitter/X, and Telegram Channel
- Submits the new URL to IndexNow (Bing, Yandex instant indexing)
- Logs everything to MySQL + sends a completion report to Slack
- Updates Airtable record to "published" with the live URL
Total time from trigger to live article: under 45 seconds.
The content generation layer uses three AI calls in sequence, each feeding the next.
Call 1 — Claude: Article Body
POST https://api.anthropic.com/v1/messages
{
"model": "claude-sonnet-4-6",
"max_tokens": 3000,
"system": "You are an expert SEO content writer. Write informative, factually accurate articles. Include one H2 per major section. Write for a general audience. Do not use AI clichés like 'dive into' or 'delve'.",
"messages": [{
"role": "user",
"content": "Write a 1,200-word article about: {{ $json.topic }}\nTarget keyword: {{ $json.primary_keyword }}\nAudience: {{ $json.audience }}\nTone: {{ $json.tone }}"
}]
}Call 2 — GPT-4o: SEO Metadata
Generate the following for this article topic: {{ $json.topic }}
Primary keyword: {{ $json.primary_keyword }}
Article excerpt (first 200 words): {{ $json.article_excerpt }}
Return ONLY valid JSON with these exact keys:
{
"seo_title": "...",
"meta_description": "...",
"slug": "...",
"tags": ["tag1", "tag2", "tag3"],
"focus_keyword": "..."
}Call 3 — GPT-4o: Social Media Posts
Write 4 social media posts for this article:
Title: {{ $json.seo_title }}
Topic: {{ $json.topic }}
URL: (will be added after WordPress publish)
Return JSON:
{
"twitter": "Max 280 chars, punchy, include 2 hashtags",
"linkedin": "200-300 chars, professional tone, include URL placeholder [URL]",
"facebook": "150-200 chars, conversational, include URL placeholder [URL]",
"telegram": "150 chars, direct, with emoji, include URL placeholder [URL]"
}After all three AI calls complete (run in sequence — Call 2 and 3 can be parallel), publish to WordPress via the REST API.
// HTTP Request: POST to WordPress
POST https://yourdomain.com/wp-json/wp/v2/posts
Auth: Basic Auth (Application Password)
Body:
{
"title": "{{ $node["GPT-SEO"].json.seo_title }}",
"content": "{{ $node["Claude-Article"].json.content[0].text }}",
"status": "publish",
"slug": "{{ $node["GPT-SEO"].json.slug }}",
"excerpt": "{{ $node["GPT-SEO"].json.meta_description }}",
"tags": [tag IDs from previous step],
"meta": {
"_yoast_wpseo_title": "{{ $node["GPT-SEO"].json.seo_title }}",
"_yoast_wpseo_metadesc": "{{ $node["GPT-SEO"].json.meta_description }}",
"_yoast_wpseo_focuskw": "{{ $node["GPT-SEO"].json.focus_keyword }}"
}
}WordPress returns the published post including its link field — the live URL. Extract it with a Set node: live_url: {{ $json.link }}. All subsequent nodes use this URL.
With the live URL available, replace the [URL] placeholder in all social posts and publish simultaneously to all four platforms.
Replace URL placeholders in a Code node:
const liveUrl = $node["WordPress-Publish"].json.link;
const socialPosts = $node["GPT-Social"].json;
return [{
twitter: socialPosts.twitter.replace("[URL]", liveUrl),
linkedin: socialPosts.linkedin.replace("[URL]", liveUrl),
facebook: socialPosts.facebook.replace("[URL]", liveUrl),
telegram: socialPosts.telegram.replace("[URL]", liveUrl),
live_url: liveUrl
}];Facebook Page Post: POST to https://graph.facebook.com/v21.0/PAGE_ID/feed with message and link parameters using your Page Access Token.
LinkedIn Post: POST to https://api.linkedin.com/v2/ugcPosts with your LinkedIn OAuth2 token.
Twitter/X: POST to https://api.twitter.com/2/tweets with OAuth1.0a credentials.
Telegram Channel: POST to https://api.telegram.org/bot{TOKEN}/sendMessage with chat_id = your channel username.
IndexNow:
POST https://api.indexnow.org/indexnow
{
"host": "yourdomain.com",
"key": "{{ your-indexnow-key }}",
"keyLocation": "https://yourdomain.com/{{ your-indexnow-key }}.txt",
"urlList": ["{{ $json.live_url }}"]
}Run all five parallel HTTP requests simultaneously, then merge with a "Wait All" Merge node.
After all publishing actions complete, run three final operations in parallel:
1. MySQL Log Entry:
INSERT INTO published_articles (
topic, slug, live_url, word_count, seo_title,
airtable_record_id, published_at, workflow_execution_id,
social_facebook, social_linkedin, social_twitter, social_telegram
) VALUES (...);2. Airtable Update: Update the original content calendar record to status "published", add the live_url, and set published_at timestamp. Use the PATCH endpoint with the record ID stored at the start of the workflow.
3. Slack Completion Report:
// Slack message format
*Published:* <{{ live_url }}|{{ seo_title }}>
*Topic:* {{ topic }}
*Word Count:* {{ word_count }}
*Social:* Facebook ✓ | LinkedIn ✓ | Twitter/X ✓ | Telegram ✓
*IndexNow:* Submitted ✓
*Total Time:* {{ elapsed_seconds }}sMerge all three parallel operations, then send the Slack report. The entire pipeline — from Airtable trigger to Slack confirmation — runs in under 45 seconds for a 1,200-word article.
A solo content creator was spending 8+ hours per article — research, writing, SEO, social posting, and Google submission. After building this n8n pipeline, the same workflow runs in 45 seconds for initial publication, leaving only final human review.