How to Automate WordPress Blog Publishing With AI (Without Slop)

AI SEARCH // FIELD GUIDE

~12 min read · Published

How to Automate WordPress Blog Publishing With AI (Without Slop)

A consultant with a WordPress blog, forty saved topic ideas and no time to write any of them set up an AI writer last spring. He published thirty-one posts in six weeks. Twelve months later his organic traffic was lower than before he started, and the posts now read like a machine explaining his industry to itself.

WordPress AI Content Pipeline Content Ops Automation
Free download

The AI Agent Setup Checklist

Twelve steps to a working agent, in the order I install them. Fourteen pages, no fluff.

Get the Free AI Agent Setup Checklist

Free · No account required

He automated the wrong half. Publishing is the easy part, and it was never the bottleneck. The bottleneck is the judgment that decides what deserves to be published, and that judgment has to be encoded somewhere before the machine touches your site.

This is the pipeline I run on my own site: an agent on a machine, a spec file, a renderer that refuses bad drafts, and a publish step that is the least interesting part of the whole thing. It has published regularly for months without my writing a post by hand, and it has caught more bad drafts than good ones.

Automation is generation plus refusal

An AI that writes a post in ninety seconds is not a content system. It is a slot machine with a calendar. A content system is a machine that writes quickly and then refuses most of what it writes, on rules you wrote down before you were tired.

That refusal layer is what separates a blog from a landfill. It is also the only part most tutorials skip, because it is unglamorous, and because it requires you to state your standards in a file that judges you.

So the mental model is this: generation is cheap and abundant, gates are expensive and specific, and the gates are where your editorial voice actually lives. If you take one thing from this page, take that. The rest is plumbing.

The pipeline, stage by stage

Seven stages, in the order I run them. Notice that four of the seven produce no content at all. That ratio is the whole design.

  1. Queue. A calendar file lists every planned article with a sequence number, a URL, a target keyword and a status column. The agent reads the calendar, not its own enthusiasm. Nothing gets written that was not planned, which is what stops the “thirty-one posts in six weeks” spiral.
  2. Choose the next slot. A script finds the first rows with an empty status and stops there. Two drafts per run, maximum. Small batches are how you keep the quality bar policed, because a bad batch of two is a cheap mistake and a bad batch of thirty is a content audit.
  3. Read the contract. Before writing, the agent loads a drafting spec: required frontmatter fields, heading structure, word floor, FAQ format, typography rules, citation rules, and the list of links that are allowed to appear. The spec is the constitution. It is a text file, it lives in the repo, and it is the single highest leverage asset in the system.
  4. Read the voice reference. One already-published article is loaded as a structural and tonal model. Not to copy sentences, to copy the shape: how long a section runs, how a table is introduced, how the closing paragraph lands.
  5. Draft to disk. The draft is written as a markdown file with frontmatter, not into the WordPress editor. Files on disk are inspectable, diffable and reversible. The editor is none of those things.
  6. Gate. A renderer parses the draft, converts it to HTML, checks it against the spec, and prints a verdict: word count, FAQ count, dead links, structural problems. A failed gate means the draft does not advance. This is a required step, not a suggestion.
  7. Publish, then log. A publish script sends the rendered HTML to WordPress through the REST API, sets the status, writes the WordPress post ID back into the calendar row, and appends a line to a dated log file. If the script has already published that row, it refuses to publish it again.

The WordPress side, which everyone gets wrong

The mechanics are boring and that is a feature. Use the REST API with an application password, and do not automate the browser. A headless browser clicking the block editor is the most common way these systems break in month two.

The four calls you need:

  • POST /wp-json/wp/v2/posts to create the post, with title, content, slug, status and categories.
  • POST /wp-json/wp/v2/media to upload the featured image, then set featured_media on the post.
  • GET /wp-json/wp/v2/posts?slug=... to check whether that slug already exists before you write.
  • POST /wp-json/wp/v2/posts/<id> to update, which is what you reach for when a correction is needed.

Three rules that save you a bad week. Publish as draft first and flip to publish in a second call, so a bad render never hits the live site. Never let the agent invent a slug; slugs come from the calendar row and nowhere else. And keep the absolute URL of the post in your log file, because the day you need to fix something you will not want to search for it.

If your site runs a page builder, check that the HTML you send survives the theme’s content filters before you trust the pipeline. One test post is enough. Send it, view it on the front end, open it on a phone, and look for a table that rendered as a wall of pipes.

The gate is a list of specific checks

Here is the actual gate I run, with the threshold and what happens when a check fails. Every row exists because something went wrong once. That is how you should build yours too: add a check the day you find the mistake, not before.

CheckThresholdOn failure
Word count, after stripping code blocks1,800 cluster, 3,000 pillarBlock, back to draft
FAQ blocks under the FAQ heading5 to 7 question linesBlock
Internal links returning 200All of themDemote to plain text and flag
Em dashes and en dashesZeroBlock
Curly quotesZeroReplace with straight, re-render
Frontmatter fieldsAll required keys presentBlock
Canonical URLUnique against published listBlock
Table, numbered sequence or worked exampleAt least oneBlock
Banned phrase listZero hitsBlock and rewrite the sentence
First 80 words answer the queryReviewer reads themFlag
Named entities resolve to real pagesManual checkFlag
Rendered HTML parsesValidBlock

The banned phrase list is the cheapest useful thing in the whole system. Mine includes “in today’s digital landscape”, “delve”, “it’s important to note”, “unlock”, “game changer”, “in conclusion”, and the specific habit of opening a section with a definition. A phrase list will not make writing good, but it removes the eleven tells that make readers stop trusting a page in the first line.

The dead link check is the second most valuable row. Internal links rot, and a post with four broken links is a post that signals neglect to a reader and to a crawler. My renderer fetches every internal URL and demotes anything that does not return 200 to plain text, then reports it. Zero dead links is a hard requirement, not a nice to have.

A worked example, with the numbers this page would print

The article you are reading went through that gate. Its numbers, as the renderer printed them:

  • 2,764 words after stripping code, against an 1,800 floor for a cluster post
  • 7 FAQ blocks
  • 0 dead links across 5 links
  • 0 em or en dashes
  • 2 tables, 2 numbered sequences
  • 3 seconds to render

That output is the entire review artifact. I do not read a diff, I read six lines of numbers. If the numbers pass and the first 80 words answer the query, the post publishes. If the numbers pass and the opening is a definition, I rewrite the opening by hand, which takes four minutes and is the part of the process that still needs me.

The earlier post in this series, the one on AI phone answering for contractors, printed 2,978 words, 7 FAQs and 0 dead links on its last render. That is what a clean pass looks like: at or above the floor, inside the FAQ band, no links to fix.

State, idempotency and the part that bites

An autonomous publisher has to know what it already did. Two files handle that: the calendar’s status column, set to published or draft-written, and a JSON of published URLs with their WordPress IDs. Read both at the start of every run.

Then obey three rules.

  • Never overwrite a published draft. The markdown file on disk is the source, and a published file that changes silently is a site that changes silently.
  • Never publish the same row twice. Check the status column before the API call, and write the post ID back immediately after. A duplicate post costs a canonical tag, a redirect and an afternoon.
  • Never publish a draft the gate has not passed in the current run. Caching a pass from three edits ago is how a broken table goes live.

Write the status inside a file handle that flushes immediately, not at process exit. A crash after a publish that leaves the status row empty is a duplicate post on the next run, and you will not notice until a reader emails you about two identical pages.

What slop actually looks like

Slop is not bad grammar. It is writing that has no stake in being correct. Six tells, in the order I catch them:

  1. A definition where an example belongs. “Content marketing is the practice of creating valuable content” is a sentence that has never helped anyone.
  2. Hedging in place of a number. “Results may vary depending on scope” is unfalsifiable, and a reader knows it.
  3. The tricolon of adjectives. Fast, reliable and affordable. Every machine loves this rhythm because it appears ten thousand times in the training data.
  4. A summary that repeats the page. If the last section restates the article, the article had nothing to land on.
  5. Sections of even length. Real expertise is lumpy. Some points take three paragraphs, some take a sentence.
  6. No named entity anywhere. No product, no company, no person, no place, no specific tool. A page with no proper nouns is a page about nothing in particular.

The fix for all six is the same: force the draft to contain an artifact with real numbers in it. A table, a worked example, a transcript, a build order with costs. You cannot write a generic paragraph around a table that has 850 dollars in one cell and 52 cents in another. The artifact drags the writing back toward specifics, which is why the spec requires one per article.

What it costs, per post

My bill, per article, at the model rates I pay in November 2026:

StageTokens, roughlyCost at my rates
Read the spec and voice reference25,000 input4 cents
Draft 2,000 words3,000 output5 cents
Gate, revise, re-render, twice20,000 input, 2,000 output8 cents
Publish and lognegligible0
Totalabout 17 to 60 cents

Under a dollar a post, and the range is wide because the model matters more than anything else in the pipeline. A cheap model drafts faster and fails the gate more often, which is fine, because failing is free. A capable model fails less and reads better, which is why I run the drafting step on a stronger model and let the cheap one handle the gate summaries.

Compare that to a freelance post at 2,000 words, which quotes in the several hundreds and takes a week to schedule. The comparison is not really about money. It is about volume: at seventeen cents a post you can afford to write the fifteen drafts that should never be published, and that is precisely the behavior a content operation needs.

Where this breaks

  • WordPress updates the REST schema. Rare, but it happens. Pin your plugin versions and keep one test post you can re-run after any update.
  • The images. A text pipeline does not solve featured images. You need a separate, ideally manual, step, or an image agent with a hard rule that it may not invent a photograph of a person.
  • The queue runs dry. Thirty planned articles become zero in a month. The queue is a maintenance job, not a build job.
  • The voice drifts. Without a published reference article in the prompt, drafts slowly converge on the model’s default register. Load the reference every run.
  • Search Console feedback is ignored. You will write posts nobody searches for. The fix is not more writing, it is reading the queries you already get impressions for and building the next batch from those.

On that last point: I rebuilt one of my older WordPress pages under a new URL this month because Search Console showed the old page earning impressions at a position too weak to earn clicks. The query was real, the page was wrong. That is the entire editorial calendar for the next quarter, sitting in a report you already have access to. No dashboard subscription required.

Want the whole agent stack, step by step?

The free 12-step checklist is the exact order I install these systems in: model, tools, memory, guardrails, publishing. No account, no upsell wall.

Get the Free AI Agent Setup Checklist →

Start with the spec, not the writer

If you build this in the wrong order you will end up with a website full of confident, fluent, useless pages. Build the spec first. Write down the eight things you will not publish, then build the writer that has to clear them. The pipeline is a week of setup, and the spec is a hundred lines of plain text that decide whether the next year of output is worth reading.

The free AI Agent Setup Checklist walks through installing an agent on your own machine, which is the prerequisite for everything above. If you want the installer instead of the manual route, there is a website management agent installer that handles the wiring. And before you publish your first automated post, run it through the citability linter and the AI search readiness audit, both of which catch the structural problems a human editor skims past.

The rest of the seats that make up an agent-run operation are in AI employees for small business. The blog queue is usually the second seat you fill, right after the one that answers your email.

Frequently asked questions

Will Google penalize AI-written blog posts?

Google’s published guidance targets unhelpful content, not the tool that produced it. A page that answers a real question with specific information performs the same way whether a machine or a person typed it. A page that adds nothing gets ignored regardless of origin.

How many posts a day can this publish?

It can publish ten. You should publish two. The constraint is not throughput, it is your capacity to read the first 80 words of each and notice when the draft has drifted. Two a run keeps that review honest.

Do I need to write code to build this?

Not from scratch, but you need to be comfortable with files, a terminal and an API key. I do not write the code for my own pipeline. I direct an agent to write it, read the output, and test each stage with one post before trusting it with five.

What stops it from publishing something wrong?

The gate catches structural problems, not factual ones. Facts get caught by a citation rule in the spec, which requires a publisher and a date for any number, and forbids statistics the writer cannot verify. Anything that fails that rule is cut, not softened.

Can I run this without WordPress?

Yes, and the pipeline is mostly CMS agnostic if you swap the publish stage. WordPress is just the easiest target because the REST API is stable and application passwords work without a plugin.

How long before it saves time?

The setup run is a weekend. The steady state is five minutes of review per post plus an hour a week on the queue. If your alternative is not writing at all, the comparison is not close.

What should I do with the drafts that fail the gate?

Keep them. A file of failed drafts is the most useful editorial asset you will own, because it tells you exactly which instructions the model cannot follow, and the fix is a spec line rather than a rewrite. Every failure is a rule you were missing.

Get the free AI Agent Setup Checklist

Twelve steps, in install order, with the settings that actually matter and the ones that are noise. It is the same list I use when I stand a system up.

Get the Free AI Agent Setup Checklist

Free. No account. Fourteen pages.

Keep reading

AI Phone Answering for Contractors: A Real Setup

No, and it should not try. It can recognize emergency language, deliver the safety instruction, and get a huma

Read it →

Automate Appointment Booking With AI (No-Show Setup)

Usually yes. The calendar only has to be readable and writable through an integration. Replacing the calendar

Read it →

Automate Inbound Lead Qualification and CRM Routing

You need somewhere a route can be written and read, which a spreadsheet can do at low volume. A CRM earns its

Read it →

Search Console Query Classifier

Paste your query export and see what share of your clicks AI answers put at risk.

Open the tool →
James Jernigan

James Jernigan

autonomous marketing systems builder, independent researcher, and author of AI SEO and The Hands-Free Business. I ran an SEO service practice before building agent-run operations for small businesses, and I write down the parts that break. Founder of jamesjernigan.com, how2rank.com, profitpassively.com, and husslemarketing.com.

© James Jernigan Web Architecture. All rights reserved.

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *