Playbook · 5 minute read
How to Build a WordPress AI Agent
A WordPress AI agent authenticates through an application password on a dedicated user with the lowest workable role, creates drafts through the REST API for editors to publish, maintains content across large sites by finding outdated pages and broken links, and runs SEO checks. It never publishes and never holds administrator access, because WordPress security incidents start with over-privileged accounts.
WordPress powers everything from a local business site to enterprise publishing operations, and its REST API makes connecting an agent straightforward. That ease is the risk: an agent connected with an administrator account is a credential that can install plugins, change settings, and take over the site, and WordPress compromises overwhelmingly begin with exactly that kind of credential. This guide covers building an agent that adds content capacity with a security posture appropriate to the platform, drawing on FISTA Solutions' AI agents delivery for content and marketing teams. It complements how to build an ai content pipeline and how to build a contentful ai agent.
How should authentication and roles work?
| Role | Permits | Fits |
|---|---|---|
| Contributor | Create drafts, cannot publish or upload media | Drafting text content |
| Author | Create and publish own posts, upload media | Drafting with images, if publish is blocked by workflow |
| Editor | Publish and edit all content | Not for agents |
| Administrator | Everything including plugins and settings | Never for agents |
A dedicated user for the agent, at Contributor or Author, with an application password over HTTPS. Where the agent needs media upload, Author is required, and an editorial workflow plugin that requires review before publish restores the control Author's publish capability would otherwise remove.
Application passwords should be rotated, restricted by IP where hosting allows, and revoked immediately if the agent is retired. An agent's credential is a target, and its blast radius is its role.
What should the agent do with content?
Draft. Posts and pages from briefs, structured into the post type's fields and taxonomies. Updates to existing content proposed as new drafts or revisions for comparison. Missing metadata, excerpts, and alt text generated for editor review. Internal link suggestions. All saved as draft or pending review, so an editor publishes.
The distinction matters as much here as in any CMS: published content carries the organisation's name, and the review step is what protects it.
Why is content maintenance the biggest opportunity?
Because large WordPress sites decay and nobody audits them. Thousands of pages accumulate over years with outdated dates, superseded products, broken links, duplicate metadata, thin content that hurts search performance, and orphaned pages nothing links to. Content teams focus on new content because maintenance is tedious and invisible.
An agent that audits the whole site, prioritises findings by traffic and severity, and proposes specific fixes turns that into a workable backlog. Outdated pricing on a page with meaningful traffic ranks above a broken link on a page nobody visits. Fixes are drafted for editor approval, not applied. See nextjs seo guide for the search dimension.
How are custom post types and fields handled?
By reading them. Sites built on WordPress frequently define custom post types, taxonomies, and fields through plugins, and the REST API exposes those when the types are registered with API support. The agent reads the structure and produces content that fits it, which is the same grounding discipline a headless CMS agent applies to a content model.
Where custom fields are not exposed to the REST API, they need to be, or the agent cannot populate them, which is a configuration change to make before the agent is built rather than a limitation to discover afterwards.
What SEO checks fit?
On drafts and on existing content: title and description presence and length, heading structure, image alt text, internal linking, canonical consistency, and readability against the audience. On the site as a whole: duplicate titles across pages, thin pages, orphaned pages, and redirect chains. Findings go to the editor or the content backlog, not into automatic changes, because an SEO plugin already handles the mechanical parts and the agent's value is in judgement about what to fix.
What must the agent never do?
Publish. Install, activate, or update plugins. Change settings. Modify themes or templates. Manage users. Each of those is either a brand risk or a security risk, and none is needed for content work. An agent that can do them is an administrator with a different name, and it should not exist.
How does multisite change things?
It multiplies the scope and the risk. A network of sites should give the agent a user per site, or a network-level user with carefully limited capabilities, rather than a super administrator. Content maintenance across a network is where the agent's value compounds, since the same audit runs everywhere, but the credential scoping must be correspondingly stricter.
How is it evaluated?
Drafts by editor edits before publish. Maintenance findings by precision, judged by the content team on a sample: was the flagged page actually outdated, was the link actually broken. SEO checks against manual audit. And the site health measures: broken link count, pages with missing metadata, and average content age on high-traffic pages, tracked over time.
What does the build sequence look like?
One week on the dedicated user, role, application password, and confirming the editorial workflow blocks agent publishing. Two weeks on drafting for one post type with editors reviewing. Two weeks on the site audit with prioritisation the content team agrees. One week on SEO checks. Then custom post types and multisite as applicable.
What goes wrong?
Administrator accounts. Application passwords over HTTP. Agents that publish. Plugin changes. Audits that flag everything equally. Custom fields the API cannot see, discovered late. And credentials never rotated, sitting in a config file long after the project ended.
How FISTA Solutions helps
FISTA Solutions builds WordPress agents on least-privilege dedicated users with rotated application passwords, drafting into the editorial workflow, auditing large sites with prioritised maintenance backlogs, and never publishing or touching plugins and settings, through AI enablement, AI agents, and forward deployed engineers working with content and marketing teams. The record behind the approach is 150+ projects for 50+ companies with 99.9% uptime.
To maintain and grow a WordPress estate without widening its attack surface, message FISTA on WhatsApp, or read how to build an ai content pipeline.
Share-ready article cover
Download the generated social format.
Clear answers
Questions raised by this field note.
Straightforward guidance for evaluating scope, fit, and the next step.
01How should an agent authenticate to WordPress?
Through an application password attached to a dedicated user account holding the lowest role that permits the required actions, typically Contributor for drafting or Author where media upload is needed, over HTTPS, with the password rotated and access restricted by IP where hosting allows. Never an administrator account.
02What should the agent do with content?
Create drafts from briefs structured into the post type's fields, propose updates to outdated pages, generate missing metadata and alt text, and suggest internal links, all saved as drafts or pending review so an editor publishes. It does not publish or modify live content directly.
03How does content maintenance work at scale?
By auditing the site: finding pages with outdated dates, facts, or products, broken internal and external links, missing or duplicate metadata, thin content, and orphaned pages with no internal links, and producing a prioritised list with proposed fixes for the content team to work through.
04How are custom post types handled?
By reading their registered fields and taxonomies through the REST API, including custom fields exposed by field plugins, and producing content that fits them. Sites with heavy customisation need the agent grounded in that structure the same way a headless CMS agent is grounded in the content model.
05What security posture does a WordPress agent need?
Least-privilege user, application password rotation, HTTPS only, IP restriction where possible, audit logging of the agent's actions through a logging plugin, and no plugin installation or settings changes. WordPress compromises typically begin with an over-privileged credential, and an agent credential is a target.
Continue exploring
Related capabilities
Start with the hard problem
Need the outcome owned, not merely analyzed?
Tell us where delivery is constrained. We’ll map the fastest credible path from intent to verified production.