Adds an AI chat view and nav link to the Payload admin. You declare per-collection read, create, update and delete permissions plus optional field scoping, and tools are generated only for allowed operations. Every action runs through the Local API as the logged-in user with access control enforced. Built on AI SDK v6 with Anthropic Claude as the default model; requires Payload 3.37+, Next.js 15 or 16, React 19 and an Anthropic API key for the default model.
Config-driven AI control panel for Payload CMS. Declare what the AI may read/create/update/delete; get a chat panel in the admin that controls your app — every action runs through Payload access control as the logged-in user.
Installation
npm i payload-ai-admin3
Stars
0
Forks
0
Open Issues
6 months ago
Last Updated
9
Weekly Downloads
v0.1.0
npm Version
118.0 KB
Unpacked Size
5
Dependencies
30 since Sep 6
| Date | Stars |
|---|---|
| Dec 5, 2026 | 3 |
| Dec 4, 2026 | 3 |
| Dec 3, 2026 | 3 |
| Dec 2, 2026 | 3 |
| Dec 1, 2026 | 3 |
| Nov 30, 2026 | 3 |
| Nov 29, 2026 | 3 |
| Nov 28, 2026 | 3 |
| Nov 27, 2026 | 3 |
| Nov 26, 2026 | 3 |
| Nov 25, 2026 | 3 |
| Nov 24, 2026 | 3 |
| Nov 23, 2026 | 3 |
| Nov 22, 2026 | 3 |
| Nov 21, 2026 | 3 |
| Nov 20, 2026 | 3 |
| Nov 19, 2026 | 3 |
| Nov 18, 2026 | 3 |
| Nov 17, 2026 | 3 |
| Nov 16, 2026 | 3 |
| Nov 15, 2026 | 3 |
| Nov 14, 2026 | 3 |
| Nov 13, 2026 | 3 |
| Nov 12, 2026 | 3 |
| Nov 11, 2026 | 3 |
| Nov 10, 2026 | 3 |
| Nov 9, 2026 | 3 |
| Nov 8, 2026 | 3 |
| Nov 7, 2026 | 3 |
| Nov 6, 2026 | 3 |
| Nov 5, 2026 | 3 |
| Nov 4, 2026 | 3 |
| Nov 3, 2026 | 3 |
| Nov 2, 2026 | 3 |
| Nov 1, 2026 | 3 |
| Oct 31, 2026 | 3 |
| Oct 30, 2026 | 3 |
| Oct 29, 2026 | 3 |
| Oct 28, 2026 | 3 |
| Oct 27, 2026 | 3 |
| Oct 26, 2026 | 3 |
| Oct 25, 2026 | 3 |
| Oct 24, 2026 | 3 |
| Oct 23, 2026 | 3 |
| Oct 22, 2026 | 3 |
| Oct 21, 2026 | 3 |
| Oct 20, 2026 | 3 |
| Oct 19, 2026 | 3 |
| Oct 18, 2026 | 3 |
| Oct 17, 2026 | 3 |
| Oct 16, 2026 | 3 |
| Oct 15, 2026 | 3 |
| Oct 14, 2026 | 3 |
| Oct 13, 2026 | 3 |
| Oct 12, 2026 | 3 |
| Oct 11, 2026 | 3 |
| Oct 10, 2026 | 3 |
| Oct 9, 2026 | 3 |
| Oct 8, 2026 | 3 |
| Oct 7, 2026 | 3 |
| Oct 6, 2026 | 3 |
| Oct 5, 2026 | 3 |
| Oct 4, 2026 | 3 |
| Oct 3, 2026 | 3 |
| Oct 2, 2026 | 3 |
| Oct 1, 2026 | 3 |
| Sep 30, 2026 | 3 |
| Sep 29, 2026 | 3 |
| Sep 28, 2026 | 3 |
| Sep 27, 2026 | 3 |
| Sep 26, 2026 | 3 |
| Sep 25, 2026 | 3 |
| Sep 24, 2026 | 3 |
| Sep 23, 2026 | 3 |
| Sep 22, 2026 | 3 |
| Sep 21, 2026 | 3 |
| Sep 20, 2026 | 3 |
| Sep 19, 2026 | 3 |
| Sep 18, 2026 | 3 |
| Sep 17, 2026 | 3 |
| Sep 16, 2026 | 3 |
| Sep 15, 2026 | 3 |
| Sep 14, 2026 | 3 |
| Sep 13, 2026 | 3 |
| Sep 12, 2026 | 3 |
| Sep 11, 2026 | 3 |
| Sep 10, 2026 | 3 |
| Sep 9, 2026 | 3 |
| Sep 8, 2026 | 3 |
| Sep 7, 2026 | 3 |
| Sep 6, 2026 | 3 |
7+2 since Sep 6
| Date | Weekly downloads |
|---|---|
| Dec 5, 2026 | 7 |
| Dec 4, 2026 | 7 |
| Dec 3, 2026 | 6 |
| Dec 2, 2026 | 5 |
| Dec 1, 2026 | 6 |
| Nov 30, 2026 | 9 |
| Nov 29, 2026 | 9 |
| Nov 28, 2026 | 8 |
| Nov 27, 2026 | 14 |
| Nov 26, 2026 | 14 |
| Nov 25, 2026 | 14 |
| Nov 24, 2026 | 11 |
| Nov 23, 2026 | 8 |
| Nov 22, 2026 | 8 |
| Nov 21, 2026 | 8 |
| Nov 20, 2026 | 1 |
| Nov 19, 2026 | 3 |
| Nov 18, 2026 | 5 |
| Nov 17, 2026 | 5 |
| Nov 16, 2026 | 7 |
| Nov 15, 2026 | 7 |
| Nov 14, 2026 | 8 |
| Nov 13, 2026 | 11 |
| Nov 12, 2026 | 11 |
| Nov 11, 2026 | 9 |
| Nov 10, 2026 | 9 |
| Nov 9, 2026 | 7 |
| Nov 8, 2026 | 7 |
| Nov 7, 2026 | 7 |
| Nov 6, 2026 | 4 |
| Nov 5, 2026 | 3 |
| Nov 4, 2026 | 4 |
| Nov 3, 2026 | 4 |
| Nov 2, 2026 | 8 |
| Nov 1, 2026 | 8 |
| Oct 31, 2026 | 7 |
| Oct 30, 2026 | 7 |
| Oct 29, 2026 | 6 |
| Oct 28, 2026 | 5 |
| Oct 27, 2026 | 6 |
| Oct 26, 2026 | 3 |
| Oct 25, 2026 | 2 |
| Oct 24, 2026 | 4 |
| Oct 23, 2026 | 4 |
| Oct 22, 2026 | 6 |
| Oct 21, 2026 | 6 |
| Oct 20, 2026 | 5 |
| Oct 19, 2026 | 6 |
| Oct 18, 2026 | 6 |
| Oct 17, 2026 | 5 |
| Oct 16, 2026 | 5 |
| Oct 15, 2026 | 4 |
| Oct 14, 2026 | 4 |
| Oct 13, 2026 | 4 |
| Oct 12, 2026 | 3 |
| Oct 11, 2026 | 4 |
| Oct 10, 2026 | 3 |
| Oct 9, 2026 | 4 |
| Oct 8, 2026 | 3 |
| Oct 7, 2026 | 4 |
| Oct 6, 2026 | 4 |
| Oct 5, 2026 | 3 |
| Oct 4, 2026 | 2 |
| Oct 3, 2026 | 3 |
| Oct 2, 2026 | 4 |
| Oct 1, 2026 | 4 |
| Sep 30, 2026 | 3 |
| Sep 29, 2026 | 3 |
| Sep 28, 2026 | 3 |
| Sep 27, 2026 | 4 |
| Sep 26, 2026 | 7 |
| Sep 25, 2026 | 6 |
| Sep 24, 2026 | 6 |
| Sep 23, 2026 | 6 |
| Sep 22, 2026 | 7 |
| Sep 21, 2026 | 7 |
| Sep 20, 2026 | 7 |
| Sep 19, 2026 | 4 |
| Sep 18, 2026 | 3 |
| Sep 17, 2026 | 4 |
| Sep 16, 2026 | 5 |
| Sep 15, 2026 | 4 |
| Sep 14, 2026 | 6 |
| Sep 13, 2026 | 6 |
| Sep 12, 2026 | 5 |
| Sep 11, 2026 | 5 |
| Sep 10, 2026 | 4 |
| Sep 9, 2026 | 4 |
| Sep 8, 2026 | 4 |
| Sep 7, 2026 | 6 |
| Sep 6, 2026 | 5 |
Each point is npm's rolling 7-day download count.
Health Score
Composite score based on GitHub activity, stars, npm downloads, publish recency, dependency count, and package size.
Badge for your README
[](https://payloaddirectory.dev/plugins/1245559680-root)<a href="https://payloaddirectory.dev/plugins/1245559680-root"><img src="https://payloaddirectory.dev/badge/1245559680-root.svg" alt="Payload Directory"></a>README
A config-driven AI control panel for PayloadCMS. Install the plugin, declare which collections/fields/operations the AI may touch, and get a chat panel inside the Payload admin that reads and edits your app on command.
Built on the AI SDK v6. The default model is Anthropic Claude; any AI SDK model works.
Status: v0.x, experimental. The plugin API (a function
config => config) is stable; option shapes may still change before 1.0.
Capability is enforced in two layers:
overrideAccess: false. The AI can never do anything the logged-in user couldn't do by hand — your existing collection/field access functions apply unchanged.collections declares per-slug read/create/update/delete, optional field include/exclude lists, and which writes require human approval. A tool for a slug/op you didn't allow is never even generated, so the model can't call it.Auth is free: the chat is a Payload custom endpoint and the admin view reuses the Payload admin session cookie — no separate app, JWT proxy, or second deployment.
read/create/update/deleteoverrideAccess: false) + a narrower plugin allowlistsalt/hash)preview → executed/failed/reverted)npm install payload-ai-admin
# or
pnpm add payload-ai-admin
# or
yarn add payload-ai-admin
payload@^3.37)react@^19, react-dom@^19)ANTHROPIC_API_KEY in your environment (for the default model)Add the plugin to your Payload config and declare what the AI may touch:
// payload.config.ts
import { buildConfig } from 'payload'
import { payloadAiAdmin } from 'payload-ai-admin'
export default buildConfig({
// ...your config
plugins: [
payloadAiAdmin({
// who may use the chat (defaults to any authenticated user)
access: (user) => user?.roles?.includes('admin') ?? false,
collections: {
orders: { read: true, update: true, approval: ['update'] },
products: { read: true, create: true, update: true },
users: { read: true, fields: { exclude: ['salt', 'hash'] } },
},
}),
],
})
payload generate:importmap
This resolves the embedded admin view + nav link.
ANTHROPIC_API_KEY=sk-ant-...
Start your app and open /admin/claudia.
| Option | Type | Default | Description |
|---|---|---|---|
collections | Record<string, ClaudiaCollectionRule> | required | The capability map. |
access | (user) => boolean | any authed user | Who may use the chat + see the audit ledger. |
model | AI SDK LanguageModel | anthropic('claude-sonnet-4-6') | Any AI SDK v6 model. |
tools | (ctx) => Record<string, Tool> | — | Register custom domain tools (access-scoped ctx). |
instructions | string | (ctx) => string | auto from config | Override/extend the system prompt. |
maxSteps | number | 6 | Agent loop cap. |
label | string | 'Claudia' | Nav-item / view label. |
siteName | string | — | Name injected into the system prompt. |
conversationsSlug | string | claudia-conversations | Slug for the chat-history collection. |
actionsSlug | string | claudia-actions | Slug for the audit-ledger collection. |
enabled | boolean | true | Disable without uninstalling. |
ClaudiaCollectionRule){
read?: boolean
create?: boolean
update?: boolean
delete?: boolean
fields?: { include?: string[]; exclude?: string[] } // field-level scoping
approval?: ('create' | 'update' | 'delete')[] // writes that need human OK
}
claudia-conversations (chat history) and claudia-actions (an audit ledger — preview → executed/failed/reverted).POST /api/claudia/chat (streams the agent via AI SDK) and POST /api/claudia/actions/:id/:decision (approve/reject a queued write).queryCollection, getDocument, countDocuments, createDocument, updateDocument, deleteDocument) are generated from your collections config.preview row and surface an approval card; the change executes only when a human approves it./admin/claudia + a nav link.Register domain-specific tools alongside the generated CRUD tools. The context (payload/req) is access-scoped to the logged-in user:
import { tool } from 'ai'
import { z } from 'zod'
import { payloadAiAdmin } from 'payload-ai-admin'
payloadAiAdmin({
collections: { orders: { read: true } },
tools: ({ payload, req }) => ({
refundOrder: tool({
description: 'Refund an order via the payment provider.',
inputSchema: z.object({ orderId: z.number() }),
execute: async ({ orderId }) => {
// your domain logic; payload/req are access-scoped
return { ok: true }
},
}),
}),
})
Full TypeScript support. The package ships type declarations and three entry points:
import { payloadAiAdmin } from 'payload-ai-admin' // server / payload.config.ts
import { /* client components */ } from 'payload-ai-admin/client'
import { /* RSC exports */ } from 'payload-ai-admin/rsc'
pnpm install
pnpm build # tsc → dist (preserves 'use client')
pnpm test # vitest
Currently dogfooded inside a full Payload ecommerce app. A standalone dev/ harness (via create-payload-app --template plugin) is on the roadmap.
Contributions are welcome! Please open an issue or pull request.
MIT © blaze IT s.r.o.
payload plugin presets
Save and apply reusable block configurations as presets from the Payload admin blocks drawer
786.7k/wk37v3
payload enhanced sidebar
Tabbed sidebar navigation for the Payload admin that groups collections, globals and custom links
76835/wk32v3 v4
payload cmdk
Keyboard-driven command menu for navigating collections, globals and custom actions in the Payload admin
75528/wk32v3
payload plugin visual editing
Click-to-edit overlays on your frontend that focus the matching field in the Payload admin
741.4k/wk37v3
payload plugin stacked editing
Stacked, breadcrumb-navigated editing panels for nested blocks and arrays in the Payload admin
71250/wk37v3
payload ai manager
Generate product titles, descriptions, attributes and translations with Claude, ChatGPT, Gemini or Kimi
7022/wk1v3