Struggling with posting blog daily ? There’s a way to automatically fetch trending tech news, turn it into unique blog posts, and publish them to WordPress ; all without lifting a finger? Sounds too good to be true ? But here’s the thing: automation isn’t magic anymore. In this guide, I’ll walk you through setting up a powerful n8n workflow that does exactly this. By the end, you’ll have your own AI-powered blogging machine running 24/7.
What Exactly Is This Workflow?
Think of this workflow as your personal blogging assistant. It wakes up every morning at 9 AM, grabs the latest technology news from NewsData.io, rewrites it into a fresh blog post using OpenAI, and publishes it directly to your WordPress site. No copy-pasting. No manual work. Just automatic content.
The beauty here? This isn’t some complicated coding project. We’re using n8n, a visual automation tool that connects different apps together like LEGO blocks. You drag, drop, connect, and boom ; you’re done .
Get Your N8n Template – Start Building
Before We Start: What You’ll Need
Let’s get our ducks in a row. Here’s everything you need before jumping in:
Required Accounts:
- n8n account (cloud or self-hosted)
N8N Free Access For 14 Days “TRY NOW”
- NewsData.io API key (free tier gives you 200 requests daily)
- OpenAI API account with credits
- WordPress site with admin access
Now we dive into the real part
Step 1: Setting Up the Schedule Trigger
Every automation needs a starting point ; a trigger that kicks everything into motion. We’re using the Schedule Trigger node, which acts like an alarm clock for your workflow.
Here’s how to set it up:
Open your n8n workspace and click the big “+” button. Search for “Schedule Trigger” and drag it onto your canvas. Now click on the node to open its settings.
The configuration looks like this:
- Mode: Hour
- Hour: 9
- Minute: 0
That’s it. Your workflow now has a heartbeat.
Step 2: Fetching News with HTTP Request
Now that we have our trigger, we need content. This is where NewsData.io comes in—a powerful news API that delivers fresh articles from thousands of sources worldwide.
Setting up the HTTP Request node:
Add a new node by clicking the “+” next to your Schedule Trigger. Search for “HTTP Request” and select it. Connect the Schedule Trigger to this new node by dragging a line between them.
Now let’s configure the request. Change the method to GET and enter this URL:
But here’s where it gets interesting. We need to add query parameters to tell the API exactly what we want. Click “Add Parameter” and create these five entries:
Parameter 1:
- Name: apikey
- Value: pub_f1095321884a440bb0a5a8b618ef4923 (replace with your own key)
Parameter 2:
- Name: category
- Value: technology
Parameter 3:
- Name: language
- Value: en
Parameter 4:
- Name: country
- Value: us
Parameter 5:
- Name: size
- Value: 1
Let me break down what each parameter does. The API key authenticates your requests. Category filters for tech news only—you could change this to “sports” or “business” if you want. Language ensures English articles. Country focuses on US news sources. And size? That tells the API to send just one article per request. Why one? Because we’re publishing daily, and quality beats quantity.
Step 3: The Magic Happens—AI Content Creation
This is where things get exciting. We’re about to transform a boring news snippet into an engaging blog post using OpenAI’s GPT model.
Connecting OpenAI:
Add an “OpenAI” node to your canvas and connect it to the HTTP Request node. You’ll need to set up credentials first. Click “Create New Credential” and enter your OpenAI API key.
Now here’s where the magic formula lives—in the messages section. We’re giving GPT two messages: a system message and a user message.
System Message:
You are an expert blog writer who creates engaging, original content. You excel at transforming news into interesting articles without plagiarism.
This sets the tone. We’re telling the AI to act as a professional writer, not a news copier.
User Message:
Write a completely original blog post about this news:
Title: {{ $json.results[0].title }}
Description:{{ $json.results[0].description }}
Requirements:
- Create a unique and engaging title
- Write EXACTLY 5 separate paragraphs (each in its own <p> tag)
- Include your own analysis and perspective
- Do NOT copy phrases from the original source
- End with a thoughtful conclusion
Format the response as clean JSON without backticks:
{
"title": "Your creative blog title",
"content": "The full blog post content with HTML formatting including separate <p> tags for each paragraph"
}
Notice those curly braces? That’s n8n’s way of pulling data from the previous node. We’re grabbing the news title and description and feeding it to OpenAI.
The model we’re using is “gpt-4.1-nano-2025-04-14″—a fast, cost-effective option perfect for blog writing. It’s cheaper than GPT-4 but still delivers quality content.
Publishing content is great but closing clients is better.
If you’re doing outreach, don’t miss this:
Step 4: Cleaning Up the Response with Code
OpenAI sends back a text response, but we need clean JSON data to work with. That’s what the Code node does ; it parses the response and extracts just what we need.
Setting up the Code node:
Add a “Code” node after OpenAI and paste this JavaScript:
const response = items[0].json.message.content;
const parsed = JSON.parse(response);
return [
{
json: {
title: parsed.title,
content: parsed.content
}
}
];
The first two pull data from our Code node using those curly braces again. The third one tells WordPress to publish immediately. If you want drafts instead, change “publish” to “draft.”
Let me explain what’s happening here.
First line grabs the OpenAI response. Second line converts it from text into actual JSON.
Then we return only the title and content fields, ignoring everything else. Why do we need this? Because WordPress expects specific data fields.
This code node acts as a translator between OpenAI’s response and WordPress’s requirements.
Step 5: Publishing to WordPress
The final piece of the puzzle ; actually getting your blog post live on your website.
Configuring the WordPress HTTP Request:
Add another HTTP Request node, but this time we’re using it to talk to WordPress.
Change the method to POST and enter your WordPress REST API URL:
https://yourdomain.com/wp-json/wp/v2/posts
(Replace “yourdomain.com” with your actual site URL)
Now here’s the security part. WordPress needs authentication.
Click on “Authentication” and select “Predefined Credential Type.”
Choose “WordPress API” and enter your WordPress credentials.
You’ll need an application password from your WordPress admin panel ; not your regular login password.
Adding Body Parameters:
Click “Send Body” and add these three parameters:
Parameter 1:
- Name: title
- Value: ={{ $json.title }}
Parameter 2:
- Name: content
- Value: ={{ $json.content }}
Parameter 3:
- Name: status
- Value: publish
The first two pull data from our Code node using those curly braces again. The third one tells WordPress to publish immediately. If you want drafts instead, change “publish” to “draft.”
Common Issues and Fixes:
If the NewsData node fails, double-check your API key. If OpenAI errors out, verify you have credits in your account. If WordPress returns a 401 error, your authentication needs fixing—regenerate your application password.
Going Live: Activating Your Workflow
Once testing works perfectly, flip the switch. At the top of your workflow, you’ll see an “Active” toggle. Turn it on.
That’s it. Your workflow is now live and will run automatically every day at 9 AM. You can check the “Executions” tab to see the history of all past runs. Each execution shows you exactly what happened, what data passed through, and whether it succeeded or failed.
Final Verdict : Your Automated Future Starts Now
You’ve just built a self-running blog that publishes daily without constant attention. This workflow handles repetitive tasks so you can focus on growing your audience and building your brand.
But remember: automation is your assistant, not your replacement. Use it to maintain consistency, but don’t abandon your unique voice. Let it handle daily news while you create the premium, in-depth content only you can write. So flip that Active switch and enjoy the freedom—but use that extra time to engage with readers and craft content that truly showcases your expertise. Welcome to smarter blogging.
Useful content for anyone interested in N8n ฟรี and no code tools for task automation data synchronization and integration platform development
Useful content for anyone interested in N8n ฟรี and no code tools for task automation data
synchronization and integration platform development
This article explains how N8n ฟรี works for workflow automation and open source automation making it easier to understand self hosting and visual workflow editor usage