From Content Audit to Drafts for Review: The AI Content Agent Built on Payload MCP

verified December 2026
Arthur Nikitsin Senior Engineer
21 min

LLMs have been able to generate text for a long time. Letting them near production content is a different conversation: that’s hundreds of pages your customers are reading right now, and any hallucination or mistake ends up in front of them immediately. Because of that risk, the editorial routine—links, testimonials, translations, meta tags—still happens mostly by hand.

Sanity Content Agent showed us how it could look different: an agent that works right inside the CMS and takes on that routine. We wanted the same for Payload. First, we built an initial version and benchmarked it against Sanity’s agent—on the same tasks, the results came out very close. Next, we handed the agent to two of our content managers for five weeks and compared both agents again, this time on 31 tasks taken from their real requests. We ended that article with a promise to take the agent out of internal beta.

Payload Content Agent is now open source under the MIT license. It’s a plugin that adds an AI agent directly into the Payload CMS admin panel: an editor asks for changes in plain language—from missing alt text to translations and find-and-replace across hundreds of documents—and the agent prepares drafts for a content manager to review and publish. Until a draft is published, readers see the pages as they were. What gets published, and when, remains a human’s call.

Below, we cover what the plugin can do, which rules are enforced in code rather than by prompting the model, what it costs to run, and how to install it on your own project.

Below: what the plugin can do, which rules are enforced in code rather than by asking the model, what it costs to run, and how to install it on your own project.

Payload Content Agent 0.1.0 · MIT · Payload CMS 3 · Bring your own API key

npm · GitHub

TL;DR

  • Control and safety. Before running a bulk edit, you see how many documents it will touch and exact diffs of what will change. Readers keep seeing the live pages until you publish the drafts.
  • Cost. A strong model plans while a lighter model edits. With the default OpenAI pairing, the median task cost in our runs was ~0.65 cents (for Anthropic, we recommend Sonnet + Haiku).Compare results, prices, and time.
  • Speed. In FocusReactive’s benchmark runs, a simple edit on an active draft took a median of 5 seconds from prompt to saved document.
  • Two modes. In the admin chat, the plugin executes tasks end to end. Over MCP, your external client orchestrates the steps while our tools enforce write safety.
  • One rulebook for the whole team. Define your brand voice, translation rules, review checklist, and glossary once in the admin; they apply automatically to every editor and conversation.
  • Your key, your models. Bring your own Anthropic or OpenAI API key with zero markup. Assign any provider model to planning, editing, or background tasks, and swap them in the settings without touching code.

What Did Five Weeks with a Real Editorial Team Show?

Over five weeks, two content managers had 30 conversations with the agent and updated 31 documents—24 articles and 7 landing pages. Model usage for the entire period came to about $20.

One runs the blog, and the requests are short and practical: fix the spelling of a term across all articles, check the grammar, write a meta description from the text. The other builds landing pages and thinks in blocks: move a block from one page to another, swap the case studies and testimonials, make a copy of a landing page for a new topic. Each of those tasks is about as much work as a dozen text edits.

For an editorial team, that’s many hours of routine work that no longer has to be done by hand. That time goes back to what you can’t delegate to an agent: creative work, new formats, and strategic tasks.

The pilot ran on a beta version. Today’s task prices are in the table below.

AI Agent Guardrails: What Does the Plugin Enforce, and What Does the Editor Decide?

The line is simple. What must never happen, the plugin decides in code. Where a human should decide, it asks, and changes nothing without permission.

You review the draft. Readers see the page as it was

Where drafts are enabled in Payload, the agent writes only to the draft. While you compare the old and new versions of a page, nothing changes on the site. And this isn’t a request to the model to be careful: the agent simply has no publish or delete tools. Even if the model decides to publish a page or delete a document, there is nothing for it to call.

In a collection without drafts, new documents are created by a person, and an edit to an existing one is confirmed by an editor. In the screenshot below, the editor asked for alt text. The agent found three files with no description and stopped: the media library has no drafts, so the edit would go straight to the site. The card shows which files it picked and what it will write to each. The write starts only after the click.

The "Edit 3 documents in media?" card: the media library has no drafts, so the chat warns that the edit goes straight to the site and waits for a clickThe "Edit 3 documents in media?" card: the media library has no drafts, so the chat warns that the edit goes straight to the site and waits for a click

Your click approves one specific edit

Say you need to replace a product name on every page for one region. When an edit touches more than five documents, the chat first shows how many documents are affected and exactly what will change. By then, the list is fixed: if a colleague adds another page for that region before you confirm, it won’t be part of this edit.

You won’t have to open every document afterward. With memory enabled, the review panel shows a summary: how many documents had text-only changes versus structural changes, and which fields were touched most often. Documents with open issues and those that differ from the rest appear first in the list.

Deletion works the same way. When text, a link, or a list item needs to be removed from a document, the card shows exactly what will be deleted. One click approves just that change.

The agent also protects your teammates’ work. If a colleague is editing the page at that moment, the agent respects the Payload document lock and writes nothing. The chat tells you how to proceed: ask your colleague to save and close the document, or wait for the lock to expire automatically (after five minutes of inactivity by default). If you’re the one with the page open, the agent edits it as usual.

The bulk edit card "Edit 29 documents in posts?": what changes in each document, a fixed list, all edits saved as draftsThe bulk edit card "Edit 29 documents in posts?": what changes in each document, a fixed list, all edits saved as drafts

The plugin checks the edit before it saves

The check starts before the edit. First, the agent writes down what the document should become: what goes, what appears, what stays untouched. When the edit is ready, code compares the resulting document against that plan before anything is written—and if a condition isn’t met, it sends the work back for a fix, up to three times.

Suppose you ask the agent to rewrite a paragraph—while keeping the date, amount, and email address unchanged. Before the write, the plugin checks that none of those values went missing, and that no duplicates, glued-together fragments or links to pages that don’t exist appeared. An empty new section won’t be saved at all. And a link that deserves a human look shows up in the open issues.

Translations and structural changes get one more reader: a separate model compares the edit with your request. If it finds a mismatch - a missing heading, fewer sections than you asked for, a link to the wrong page - you see that note on the edit card, and in the review panel that document comes first. You compare the versions and decide what to accept. Then, after the write, the agent checks the outcome against the document that was actually saved in the CMS.

Anything that can be counted is counted by code. Ask to cut a meta description to 160 characters, and the length is checked by a counter, not by the model’s estimate. The list of changes on the card and the summary in the review panel are also built from the diff between document versions, not from the agent’s account of its own work. If an edit saved nothing, the chat says so plainly.

And when an edit needs a fact only you know, the agent stops and asks. Nothing is saved until you answer.

One last thing: to the agent, an article’s text is material to work with, not a source of instructions. In three runs out of three, it did not follow an instruction hidden inside an article. We put the mandatory content rules in code, not in a request to the model.

Why Not Just Connect Claude to Payload MCP?

You can - and as long as the task sounds like “find the pages”, you’ll barely notice a difference. The difference becomes clear when you type the words “now fix them”. In the plugin’s chat, the order of editorial work is already set: the plugin picks the model, checks the edit and comes to you when a decision is needed. If you prefer your own Claude, give it the same checked tools over MCP - then your model decides the order of steps, following your instructions.

Standard Payload MCP gives each collection four tools: find, create, update, delete. Thirty collections already mean 120 tools, and the model receives every tool description at every step. We reduced all operations to ten shared tools: you specify the collection and the action. This set doesn’t grow with your schema. In our measurements, an external model using only these ten tools consumed almost half as many input tokens as one using both sets.

Which tools to keep is up to you. By default both sets are available. You can keep the standard ones for reading and route writes through ours. Or keep only ours: the model gets the most compact set, and every write goes through the plugin’s checks.

An agent harness is the code that takes a model from request to result. An instruction in a prompt or a skill only suggests what the model should do; a harness enforces the rule itself. It also divides the work: you pay a strong model for the plan and a light one for an ordinary field edit. An outside client with a single model pays for both stages at one rate. And because the plugin knows how a field edit works, it takes the short path, without long planning.

On a destructive edit, our MCP tool can only refuse. Our chat can stop and ask.

That’s a property of our two modes, not of the protocol: MCP lets a server request input through the client. Our tools work without chat too: they save validated drafts and, if no draft exists or the request would remove content, leave the document unchanged and explain why. With chat and memory enabled, the key owner sees edits made through Claude Code as a separate conversation and can review, publish, or roll them back in the shared review panel.

Five Editorial Jobs You Can Take from Request to Result in Your CMS

Sometimes, it’s easier to show the agent the page you have open than to explain to a colleague where exactly an edit is needed. Below are five tasks, phrased the way you’d describe them in chat.

Find the gaps and fill only those

Which images in the media library have no alt text? Then: Write alt text for each image that has none. Leave existing descriptions unchanged.

The agent found three images with no alt text, looked at each one and wrote the descriptions after confirmation; existing alt text is untouchedThe agent found three images with no alt text, looked at each one and wrote the descriptions after confirmation; existing alt text is untouched

The agent looks at each image and describes what it sees. Checking the work is simple: open two files - one that had no description and one an editor had already worked on. The first now has alt text; the second keeps its old one.

Change one field without rebuilding the page

Change the heading in this nested block. Leave the rest of the page unchanged.

Even if the block sits three levels deep, it’s enough to say “on this page” and name the heading: the chat knows which document is in front of you. The saved edit appears in the open form right away. And if you’ve changed something yourself in the meantime, the plugin leaves your work on the screen and suggests refreshing the page manually.

Update a group of pages with one request

On every page for this region, update the testimonials block with the latest published review from each person.

No new copy is needed here - the right testimonials are: each person’s latest published review has to land in its block on the region’s pages. In our example there were four such pages. Instead of opening each one and picking testimonials by hand, you make one request.

Translate only what the launch needs

Translate the excerpt of this post into Spanish.

The newsletter needed the excerpt in Spanish, and there was no reason to translate the article itself. The agent puts the translation into the right field and touches nothing else. You can translate a whole group of documents the same way.

The translated excerpt is saved as a draft; the review panel shows before and after, and a human publishesThe translated excerpt is saved as a draft; the review panel shows before and after, and a human publishes

Build a page from blocks you already know

Create a new draft from this page and copy the relevant blocks from the other page.

One page already has the right structure; another has an approved block. There’s no need to recreate them from a description: the agent knows the project’s block library and sees where each block is used. It takes the first page as the base for the draft and copies the block from the second unchanged. Both source pages stay where they are.

What Editorial Teams Get in the Open-Source Package

The open-source MIT package covers practically any content work in your CMS. The write checks, translation, bulk edits and the review panel from the sections above are all in it. A few more examples:

  • Search and history. Find a piece by title or phrase, read a long page in full, get the exact number of matches. The agent finds a page’s previous URL and its publication date from the saved versions.

  • Link audit. Check a whole collection. From CMS data, the agent tells a missing page from an unpublished one, and an old URL with a redirect from a live one.

  • Edits at any scale. Change a single field, rich text, a list or a nested block. A selection by condition covers up to 1,000 documents. A literal replacement - say, /old-pricing to /pricing across all posts - is done by code, without a model: matches are replaced exactly, and no tokens are spent on the document text. If a run hits the time limit, you can resume it within 24 hours.

  • Sources at hand. Ask the agent to find and read a page on the web, import an article by URL straight into a draft, or attach a file: an image, PDF, text, DOCX or XLSX.

  • Editorial instructions. These are the agent’s shared rules for the whole team: they are set once in the admin and apply in the chat of everyone who works with content. For example, the lead describes the blog’s brand voice - the tone, how to address the reader, the words the team avoids. those rules attach to every editor’s conversation automatically, so nobody has to repeat them in each request. A review checklist or a translation glossary is configured the same way.

For each instruction, you specify when it applies—when writing, translating, reviewing, or always—so brand voice guidelines don’t get in the way when you’re just fixing links. Explain a new term during a conversation, and the agent will propose adding it to the glossary. It won’t make those proposals after reading an external page, ensuring someone else’s text doesn’t end up in your shared rules. Whether a proposed entry gets added is decided only by people with permission to manage the rules—the same role required to edit the instructions themselves. Instructions guide the model; write permissions are enforced separately.

  • Memory and visual answers. With memory, the agent finds an earlier agreement from a question like “What did we decide about this section last week?” Memory and history need PostgreSQL. An audit summary can be shown as a table or a chart right in the chat.

  • Work in plain sight. While the agent is busy, the chat shows each step in plain words - for example, “Updating posts… 3s”. If a step fails, you see the reason. You can drag, resize or minimize the chat window. It automatically matches the admin’s light or dark theme, and past conversations are easy to reopen from your history.

You can interrupt bulk work at any moment: press Stop, and the documents the agent hasn’t reached yet remain unchanged. If you just need to switch to another task, open a new chat - the previous one keeps running in the background.

What Does Payload Content Agent Pro Add?

Payload Content Agent Pro adds three ready-made modules to the open-source plugin: external MCP servers, an activity log and custom tools. It’s a separate paid package, and each module is turned on separately.

The idea is simple: your editorial team decides what to hand to the agent. You can add your own tools to the built-in ones and connect the MCP servers of services you already use. You can build such a module yourselves on the open SDK - Pro gives you three ready ones that only need switching on in the config.

  • External MCP servers. Connect Ahrefs, for example: in minutes an editor checks demand for key phrases and, right there in the chat, fixes the meta title in a Payload draft. The time that used to go on cross-checking reports and switching tabs goes to a new format, a content plan review or work with an author. You choose which of the server’s tools are available and which parameters are allowed. In a large catalog, the agent finds the tool it needs by search, without loading the whole list. It reads the service’s responses as data, not as commands; if the service is down, the chat keeps working.

  • Activity Log. Ask: “How many of the agent’s edits did we publish unchanged this month?” The log shows what the agent changed, what people edited, and how much of the agent’s text reached the site. Reports also show the drafts still waiting and the median time to publication. Reports are available in the chat and over the API, and edits by outside agents are counted too. By default each person sees only their own work history; other people’s history is visible to those you allow.

  • Custom Tools. Build a tool for your team’s task and give it to the agent. It could be semantic search across your articles or a data request to your company’s internal API. Editors use them in the same chat as the built-in tools.

The agent pulled volume and difficulty for three key phrases from Ahrefs, picked the strongest one and saved a new meta title as a draftThe agent pulled volume and difficulty for three key phrases from Ahrefs, picked the strongest one and saved a new meta title as a draft

The activity log in the chat: how many documents the agent touched in 30 days, how many were published unchanged and how many are still draftsThe activity log in the chat: how many documents the agent touched in 30 days, how many were published unchanged and how many are still drafts

How to get Pro. The package is private: get in touch, and we’ll open access. While you’re at it, tell us which services you’d like to bring together in one editorial chat.

What to Check Before Giving Your Editorial Team Access

Will the agent work with your pages?

Short answer: yes. The plugin is built for any Payload schema that uses the Lexical editor, and it needs no changes for your project. On the first request it reads the structure of your CMS itself - collections, globals, fields, locales, relationships and nested blocks. You don’t have to write a reference for the model. If the schema is large, the agent gets it in a compact form and asks for a block’s details when it needs them. At initialization the plugin adds a map of the available content to the structure. We test it on four schemas built in different ways.

You can confirm this with one edit. Take a page an editor knows well and ask to change one field in a familiar block.

What is left after a rollback?

Say the agent edited a page, and then a colleague updated the price on it. With memory enabled, the panel shows everything that changed during the conversation. A regular rollback undoes the agent’s edits, keeps the colleague’s change and flags it in the panel, and gives each locale back its own values.

If the piece has already been published, the rollback prepares a draft with the old values. Readers see them only after that draft is published.

Which models should your editorial team choose?

Short answer: if you’re choosing on results and price, start with the OpenAI default. If your company works with Anthropic, take Sonnet + Haiku. Here’s what that advice is based on.

To compare models on editorial work, FocusReactive gave each pair the same set: 23 scenarios, three repeats each, from translations and bulk edits to questions about the content. That’s 69 runs per series. We used the open-source package with no paid modules, turned on the content map, and calculated cost from actual usage and the providers’ standard rates as of November 25, 2026.

Model pair: planning + edits Successful runs Median cost per task Median time per task Cost of a 69-run series
OpenAI GPT-6.1 Terra + GPT-6 Luna, the OpenAI default 69 of 69 in each of two series, November 23 and 24 about 0.65 cents 15-20 s about $1
Anthropic Claude Sonnet 5.5 + Claude Haiku 5.5, the Anthropic default 60 of 69 and 63 of 69 in two series 3.5-4 cents about 15 s about $5
Anthropic Claude Opus 5.5 + Claude Haiku 5.5 63 of 69, November 22 about 5.5 cents about 12 s about $6

The OpenAI pair passed the entire test suite twice at the lowest median cost per task. Both Anthropic pairs completed every edit as well, with Sonnet proving more than capable for planning at a fraction of Opus’s price.

We selected the pairings in the table for the best balance of quality and cost. While building the plugin, we found that older-generation models from both providers performed the same tasks less reliably.

Table prices reflect provider-side prompt caching, which we strongly recommend keeping enabled. Because every step resends the same large context block—rules, schema, and editorial guidelines—cached reads reduce token costs by 10–20x. Without caching, the same runs would have cost roughly 4.7x more on OpenAI and 3.4x more on Anthropic.

Planning accounted for the bulk of our spend. The lighter model executed most of the edits while representing just ~11% of total cost on OpenAI and 3–4% on Anthropic. To prevent surprise bills, every request enforces a hard spend limit—if hit, the plugin halts immediately and alerts you in the chat. If you want to change the pair, the steps are in the README.

What exactly did we measure?

For an editor, an edit is done when the right text is in the right field. So that’s what we check, too: whether the saved document matches what the task required.

Behind this release are more than six months of development and over 1,700 automated tests that verify the plugin’s rules on every code change. The tasks, pass conditions, and run reports are all open in the repository/GitHub repo. How the checks work is described in the eval suite README.

Where does your data stay?

Payload and the database stay with you. The plugin sends chat messages, the structure and the content the agent reads for the task to the provider you chose - Anthropic or OpenAI - under your API key. The agent’s search queries go to DuckDuckGo. If vector search over memory is enabled, the text of memory records goes to the embedding model you chose.

When the agent reads a web page or imports an article, your site’s server fetches it. If you’ve connected external MCP servers or custom tools, requests to them go to those services.

Conversation history, memory and telemetry live in your PostgreSQL. The plugin has no analytics of its own: it sends nothing to us.

Who Is the Admin Chat For?

The admin chat shines wherever a single bad edit is costly. You don’t need a massive editorial team to benefit: even on a small site, you want to update testimonials in one specific region and review translations before they go live. If you prefer running your own agent loop in Claude Code, you can connect the plugin’s validated MCP tools on their own.

You control who can open the chat and which collections or globals the agent sees. Because the agent operates using shared collection permissions rather than per-user roles when creating drafts, only grant chat access to team members you trust with those edits. When it comes time to publish or roll back, Payload enforces the individual permissions of the person clicking the button.

If you’re still choosing the platform itself, see our overview of the category, the story of the prototype and the earlier comparison on editorial tasks.

What Should Developers Know Before Installing?

This section is for whoever installs the plugin. It collects the technical details an editorial team doesn’t need.

  • Agent permissions. The agent reads and edits collections through your site’s MCP endpoint with a single MCP key: everyone who has the chat works with them within that key’s scope, whatever their role in Payload. So give the key only find, create and update in the collections your editorial team works with. Globals, and collections the key has no tool for, go through the Local API with the user’s own permissions: Payload’s regular access control applies there. Delete tools are filtered out in code either way: even if the key allows them, the agent never gets them.

  • Prompt caching. There’s nothing to configure in the plugin. Just check that caching isn’t disabled in your account, your gateway or the cloud platform you use to reach the model.

  • Usage tracking. With memory enabled, the plugin records every step in your database: model, time and tokens, including those read from cache. You calculate what the agent costs on your content from your own data.

  • Web access. Web search works without a separate key. The agent fetches pages only at addresses it found itself or a person named, and the plugin rejects private-network addresses.

  • SDK for your own modules. The open-source package is extensible: it has a public SDK with a stable API. A module adds tools and instructions to the agent and can show a result as a table or a chart. The Pro modules are built on the same SDK: if you don’t want to write your own, take the ready ones.

How to Get Started

You’ll need Payload CMS 3.61 or later with the Lexical editor, Node.js 22 or later, and your Anthropic or OpenAI API key. You can start without write access.

  1. Install the package from npm. The command below is for Anthropic. The OpenAI variant and a minimal config are in the plugin README.
npm install @focus-reactive/payload-plugin-content-agent @payloadcms/plugin-mcp ai @ai-sdk/anthropic
  1. Add the keys. Set the key of the provider you chose, and in the Payload admin create a key for the agent with read-only access to the media library.

  2. Ask: Which images in the media library have no alt text? Compare the list with the media library. Write access comes in later, when you want the agent to write the descriptions too.

Is your site deployed on Vercel? There’s a ready deploy setup in the README.

The plugin is in the repository. If it’s useful to your editorial team, we’d appreciate a star. Have an idea or a question? Open an issue: describe the request and the result you want.

Which task would you hand to the agent first? Tell us about it. A conversation about building it into your Payload project needs just one page and one edit: we’ll work out what to hand to the agent and where the editor should keep the last word.

Payload Content Agent FAQ

Can you connect only the Payload Content Agent MCP tools, without the chat?

Yes. Your agent keeps working in the client you're used to, and our tools check the changes and save them as drafts. The order of steps, and the moment the task counts as done, is decided by the model you chose.

Is Claude Code an agent harness?

Yes. Claude Code runs the model and calls the tools available to it. By connecting it to Payload MCP, you give it access to documents. In the Payload Content Agent chat, the editorial order of work is already set up for you.

Who publishes and deletes documents?

A human. You publish selected drafts from the review panel and delete documents in the Payload admin. If a collection doesn't support drafts, you create new documents in it yourself, and the chat asks for confirmation before editing existing ones.

Who can use the chat?

That's your decision: who gets the chat and which collections and globals the agent works with. By default the chat is available to admin users. The agent's permissions in collections are set by the MCP key, which is shared by all chat users.

Does your data stay with you?

Yes, you host Payload and the database yourself. The content a model needs for a specific task goes to the AI provider you chose, under your key. The agent's search queries go to DuckDuckGo. The plugin has no analytics.

Do bulk edits or translation need the paid modules?

No. Translation, bulk changes, write checks and the review panel are part of the open-source MIT package. You pay your provider only for model usage.