Integrations
Integrates with Strapi CMS to provide access to content types and entries through the MCP protocol, allowing creation, reading, updating, and deletion of content entries, as well as media uploads
Strapi MCP
An MCP server for Strapi CMS, providing access to content types and entries through the Model Context Protocol.
Overview
This MCP server integrates with any Strapi CMS instance to provide:
- Access to Strapi content types as resources
- Tools to create and update content types in Strapi
- Tools to manage content entries (create, read, update, delete)
- Support for Strapi in development mode
Setup
Environment Variables
It's recommended to use a .env
file in the project root to store your credentials.
STRAPI_URL
: The URL of your Strapi instance (default:http://localhost:1337
)STRAPI_ADMIN_EMAIL
: The email address for a Strapi admin user (Recommended for full functionality, especially schema access).STRAPI_ADMIN_PASSWORD
: The password for the Strapi admin user (Recommended).STRAPI_API_TOKEN
: (Optional Fallback) An API token. Can be used if admin credentials are not provided, but may have limited permissions.STRAPI_DEV_MODE
: Set to"true"
to enable development mode features (defaults tofalse
).
Example .env
file:
Important: Add .env
to your .gitignore
file to avoid committing credentials.
Installation
Running
Recommended Method (using .env
file):
Make sure you have built the project (npm run build
). Then run the server using Node.js v20.6.0+ with the --env-file
flag:
Alternative (using environment variables directly):
Features
- List and read content types
- Get, create, update, and delete entries
- Upload media files
- Connect and disconnect relations
- Get content type schemas
Changelog
0.1.6
- Added
create_content_type
tool: Allows creating new content types via the Content-Type Builder API (requires admin credentials). - Prioritized Admin Credentials: Updated logic to prefer admin email/password for fetching content types and schemas, improving reliability.
- Updated Documentation: Clarified authentication methods and recommended running procedures.
0.1.5
- Improved content type discovery with multiple fallback methods
- Added more robust error handling and logging
- Enhanced schema inference for content types
0.1.4
- Improved error handling with more specific error codes
- Added
ResourceNotFound
andAccessDenied
error codes - Better error messages for common API errors
0.1.3
- Initial public release
License
MIT
strapi-mcp MCP Server
An MCP server for your Strapi CMS
This is a TypeScript-based MCP server that integrates with Strapi CMS. It provides access to Strapi content types and entries through the MCP protocol, allowing you to:
- Access Strapi content types as resources
- Create, read, update, and delete content entries
- Manage your Strapi content through MCP tools
Features
Resources
- List and access content types via
strapi://content-type/
URIs - Each content type exposes its entries as JSON
- Application/JSON mime type for structured content access
Tools
list_content_types
- List all available content types in Strapiget_entries
- Get entries for a specific content type with optional filtering, pagination, sorting, and population of relationsget_entry
- Get a specific entry by IDcreate_entry
- Create a new entry for a content typeupdate_entry
- Update an existing entrydelete_entry
- Delete an entryupload_media
- Upload a media file to Strapiget_content_type_schema
- Get the schema (fields, types, relations) for a specific content type.connect_relation
- Connect related entries to an entry's relation field.disconnect_relation
- Disconnect related entries from an entry's relation field.create_content_type
- Create a new content type using the Content-Type Builder API (Requires Admin privileges).
Advanced Features
Filtering, Pagination, and Sorting
The get_entries
tool supports advanced query options:
Resource URIs
Resources can be accessed with various URI formats:
strapi://content-type/api::article.article
- Get all articlesstrapi://content-type/api::article.article/1
- Get article with ID 1strapi://content-type/api::article.article?filters={"title":{"$contains":"hello"}}
- Get filtered articles
Development
Install dependencies:
Build the server:
For development with auto-rebuild:
Installation
For detailed step-by-step instructions on how to deploy and test this MCP server, please see the DEPLOYMENT.md file.
Quick setup:
- Build the server:
npm run build
- Configure your Strapi instance and get an API token
- Add the server config to Claude Desktop:
On MacOS: ~/Library/Application Support/Claude/claude_desktop_config.json
On Windows: %APPDATA%/Claude/claude_desktop_config.json
Environment Variables
STRAPI_URL
(optional): The URL of your Strapi instance (defaults to http://localhost:1337)STRAPI_ADMIN_EMAIL
&STRAPI_ADMIN_PASSWORD
(Recommended): Credentials for a Strapi admin user. Required for full functionality like fetching content type schemas.STRAPI_API_TOKEN
(Optional Fallback): Your Strapi API token. Can be used if admin credentials are not provided, but functionality might be limited based on token permissions.STRAPI_DEV_MODE
(optional): Set to "true" to enable development mode features (defaults to false)
Authentication Priority
The server prioritizes authentication methods in this order:
- Admin Email & Password (
STRAPI_ADMIN_EMAIL
,STRAPI_ADMIN_PASSWORD
) - API Token (
STRAPI_API_TOKEN
)
It's strongly recommended to use Admin Credentials for the best results.
Getting Strapi Credentials
- Admin Credentials: Use the email and password of an existing Super Admin or create a dedicated admin user in your Strapi admin panel (Settings > Administration Panel > Users).
- API Token: (Optional Fallback)
- Log in to your Strapi admin panel
- Go to Settings > API Tokens
- Click "Create new API Token"
- Set a name, description, and token type (preferably "Full access")
- Copy the generated token and use it in your MCP server configuration
Debugging
Since MCP servers communicate over stdio, debugging can be challenging. We recommend using the MCP Inspector, which is available as a package script:
The Inspector will provide a URL to access debugging tools in your browser.
Usage Examples
Once the MCP server is configured and running, you can use it with Claude to interact with your Strapi CMS. Here are some examples:
Listing Content Types
Getting Entries
Creating an Entry
Uploading Media
Connecting Relations
Disconnecting Relations
Creating a Content Type
Updating a Content Type
Accessing Resources
This server cannot be installed
hybrid server
The server is able to function both locally and remotely, depending on the configuration or use case.
Provides access to Strapi CMS content through the MCP protocol, allowing users to create, read, update, and delete content entries via Claude.
Related Resources
Related MCP Servers
- AsecurityAlicenseAqualityA Model Context Protocol server that enables AI assistants to interact with Strapi CMS instances through a standardized interface, supporting content types and REST API operations.Last updated -56520JavaScriptMIT License
- -securityAlicense-qualityAn MCP server that allows accessing and managing ledger files through Claude by providing account listing, balance checking, and transaction register viewing capabilities.Last updated -1PythonGPL 3.0
- AsecurityAlicenseAqualityAn MCP server that enables Claude to interact with Twitter, allowing for posting tweets and searching Twitter content.Last updated -265202TypeScriptMIT License
- AsecurityFlicenseAqualityAn MCP server that integrates Claude with Anki flashcards, allowing users to review due cards and create new flashcards directly through conversation.Last updated -68Python