An AI-powered interface for Statamic CMS that lets you manage your site using natural language commands.
This addon is in an early alpha stage and is being developed mainly using AI. Please use in care and never on production sites.
- Natural Language Commands: Type instructions like "Create 10 blog posts" or "Update all entries in collection X"
- Claude-Powered: Uses Anthropic's Claude API with tool use for intelligent operations
- Real-time Streaming: See responses and tool executions in real-time via SSE
- Budget Control: Set daily, monthly, and per-session spending limits
- Permission Modes: Choose between "Content Only" (safe) or "Full Access" (power mode)
- Bulk Operations: Efficiently create or update multiple entries in a single operation
- Statamic v6
- PHP 8.2+
- Laravel 12+
- Claude API key from Anthropic Console
composer require reachweb/statamic-ai-agentPublish the configuration (optional):
php artisan vendor:publish --tag=statamic-ai-agent-configAdd your Claude API key to .env:
ANTHROPIC_API_KEY=your-api-key-hereAnd configure via the Control Panel at Settings > AI Agent.
- Open the Statamic Control Panel
- Press
Cmd+I(Mac) orCtrl+I(Windows) to open the AI Agent terminal or use the icon in the header - Type your command in natural language
- The agent will execute the appropriate tools and show results
- "List all collections"
- "Show me the fields in the blog blueprint"
- "Get entry with slug 'hello-world' from the posts collection"
- "Update the title of entry X to 'New Title'"
- "Create 5 sample blog posts with different topics"
- "Update all entries in the news collection to set featured = true"
- "Translate the home page to French" (multisite)
| Tool | Description | Mode |
|---|---|---|
list_entries |
List entries from a collection with pagination | Content |
get_entry |
Get a single entry by ID or slug | Content |
create_entry |
Create a new entry | Content |
update_entry |
Update an existing entry | Content |
delete_entry |
Delete an entry (requires confirmation) | Content |
bulk_create_entries |
Create multiple entries at once (up to 50) | Content |
bulk_update_entries |
Update multiple entries with the same data | Content |
| Tool | Description | Mode |
|---|---|---|
list_collections |
List all collections | Content |
get_collection |
Get collection details | Content |
create_collection |
Create a new collection | Full |
update_collection |
Update collection settings | Full |
| Tool | Description | Mode |
|---|---|---|
list_blueprints |
List all blueprints | Content |
get_blueprint |
Get blueprint field definitions | Content |
update_blueprint |
Update a blueprint | Full |
add_field |
Add a field to a blueprint | Full |
edit_field |
Edit an existing field | Full |
remove_field |
Remove a field from a blueprint | Full |
rename_field |
Rename a field | Full |
reorder_fields |
Reorder fields in a blueprint | Full |
| Tool | Description | Mode |
|---|---|---|
list_taxonomies |
List all taxonomies | Content |
get_taxonomy |
Get taxonomy details | Content |
create_taxonomy |
Create a new taxonomy | Content |
list_terms |
List terms in a taxonomy | Content |
get_term |
Get a single term | Content |
create_term |
Create a new term | Content |
update_term |
Update an existing term | Content |
| Tool | Description | Mode |
|---|---|---|
list_globals |
List all global sets | Content |
get_global |
Get global set data | Content |
update_global |
Update global set values | Content |
update_global_blueprint |
Update a global set's blueprint | Full |
| Tool | Description | Mode |
|---|---|---|
list_navs |
List all navigation structures | Content |
get_nav |
Get navigation tree | Content |
update_nav |
Update navigation structure | Full |
add_nav_item |
Add an item to navigation | Full |
remove_nav_item |
Remove an item from navigation | Full |
| Tool | Description | Mode |
|---|---|---|
list_asset_containers |
List asset containers | Content |
list_assets |
List assets in a container | Content |
get_asset |
Get asset metadata | Content |
update_asset |
Update asset metadata | Content |
| Tool | Description | Mode |
|---|---|---|
list_sites |
List configured sites/locales | Content |
translate_entry |
Create a localized version of an entry | Content |
bulk_translate_entries |
Translate multiple entries at once | Content |
| Tool | Description | Mode |
|---|---|---|
find_views |
Search for view files | Full |
get_view |
Read a view file's contents | Full |
update_view |
Modify a view file | Full |
preview_view_changes |
Preview changes before applying | Full |
| Tool | Description | Mode |
|---|---|---|
git_status |
Show git working directory status | Content |
git_diff |
Show changes in files | Content |
git_commit |
Commit changes | Full |
git_revert |
Revert changes | Full |
| Tool | Description | Mode |
|---|---|---|
request_confirmation |
Request user confirmation before actions | Content |
- Read collections, blueprints, entries
- Create and modify entry content
- Bulk create/update entries
- Manage taxonomy terms
- Translate entries (multisite)
Everything above, plus:
- Modify blueprints (add/edit/remove fields)
- Modify collection settings
- Update views/templates
- Modify navigation structures
- Modify global set blueprints
- Git operations (commit, revert)
The agent supports efficient bulk operations with a single confirmation:
"Create 10 sample products in the products collection"
"Update all blog posts to set status = published"
"Translate all entries from the news collection to French"
Bulk tools are limited to prevent accidental mass operations:
bulk_create_entries: Up to 50 entries per callbulk_update_entries: Default limit of 100 entries per callbulk_translate_entries: Processes entries with configurable limits
The addon tracks API spending and allows you to set limits:
- Daily Limit: Maximum spend per day
- Monthly Limit: Maximum spend per month
- Per-Session Limit: Maximum spend per conversation
- Warning Threshold: Percentage at which to show warnings
Usage is stored in JSON files at storage/statamic-ai-agent/usage/.
php artisan ai-agent:prune-usage --days=90Build frontend assets:
cd vendor/reachweb/statamic-ai-agent
npm install
npm run buildRun tests:
vendor/bin/pestMIT License. See LICENSE for details.