@contentful/mcp-server

中文文档
1.24.5发布于 2026/11/06MITTypeScriptES Module近 30 天下载 3.9万

Contentful MCP Server - Model Context Protocol server for Contentful

原始使用文档
文档目录14 节
  1. 🚀 Example Use Cases
  2. 📓 Table of Contents
  3. ⚙️ Getting started
  4. Prerequisites
  5. Installation
  6. Environment Variables
  7. Configuration
  8. 🛠️ Available Tools
  9. 🤝 Contributing
  10. 📦 Releases
  11. 📚 Documentation
  12. ❓ Help & Support
  13. 📄 License and Notices
  14. 🛡️ Code of Conduct

Contentful MCP Server

A Model Context Protocol (MCP) server that provides AI assistants with comprehensive tools to interact with Contentful APIs.

🚀 Example Use Cases

This MCP server provides a comprehensive set of tools for content management, allowing AI to help you create, edit, organize, and publish content directly within Contentful. Once configured, you can use natural language in your AI assistant of choice to manage and interact with your Contentful spaces, including:

  • Content Creation: "Create a new blog post for our fall product launch"
  • Content Management: "Update all product entries to include the new pricing structure"
  • Asset Organization: "Upload and organize these marketing images by campaign"
  • Workflow Automation: "Create an AI action that translates content to Spanish"
  • Content Modeling: "Add a new field to the product content type for customer ratings"

📓 Table of Contents

⚙️ Getting started

Prerequisites

Installation

One-Click install

Install MCP Server

Note: This requires Cursor to be installed. If the link doesn't work, try the manual installation below.

Claude Desktop:

Download the .dxt configuration file here from the latest release and import it into Claude Desktop to automatically configure the MCP server with your environment variables.

Install from source

git clone https://github.com/contentful/contentful-mcp-server.git
cd contentful-mcp-server
npm install
npm run build

Environment Variables

Environment VariableRequiredDefault ValueDescription
CONTENTFUL_MANAGEMENT_ACCESS_TOKEN✅ Yes-Your Contentful Management API personal access token
SPACE_ID✅ Yes-Your Contentful Space ID
ENVIRONMENT_ID❌ NomasterTarget environment within your space
CONTENTFUL_HOST❌ Noapi.contentful.comContentful API host
EXPORT_BASE_DIR❌ Noprocess.cwd()Server-controlled root directory for export_space output. The tool creates a dedicated subdirectory per export.
NODE_ENV❌ NoproductionNode Environment to run in
MAX_BULK_SIZE❌ No10Maximum number of IDs allowed in a single bulk-operation tool call (1–100). Caps publish/unpublish/archive/unarchive on entries and assets. Mitigates accidental mass operations from AI hallucinations.
ENABLE_EXO_TOOLS❌ NofalseOpt in to Experience Orchestration (ExO) tools. Set to true to register the ExO tool collections (components, data assemblies, design tokens, experiences, experience templates, experience fragments). Also requires the token to hold the exoM1 entitlement in at least one accessible org — both gates must pass.

Configuration

Refer to the documentation for your AI tool of choice for how to configure MCP servers. For example, see the documentation for Cursor, VS Code, or Claude Desktop.

Below is a sample configuration:

{
  "mcpServers": {
    "contentful-mcp": {
      "command": "npx",
      "args": ["-y", "@contentful/mcp-server"],
      "env": {
        "CONTENTFUL_MANAGEMENT_ACCESS_TOKEN": "your-CMA-token",
        "SPACE_ID": "your-space-id",
        "ENVIRONMENT_ID": "master",
        "CONTENTFUL_HOST": "api.contentful.com"
      }
    }
  }
}

🛠️ Available Tools

CategoryTool NameDescription
Context & Setupget_initial_contextInitialize connection and get usage instructions
Content Typeslist_content_typesList content types (max 10 per request)
get_content_typeGet detailed content type information
create_content_typeCreate new content types
update_content_typeModify existing content types
publish_content_typePublish content type changes
unpublish_content_typeUnpublish content types
delete_content_typeRemove content types
Entriessearch_entriesSearch and filter entries in your space
get_entryRetrieve specific entries
get_entry_snapshotRetrieve entry version history (snapshots)
create_entryCreate new content entries with locale support
update_entryModify existing entries with locale support
patch_entryChange specific field locales without resending the others (JSON Patch)
publish_entryPublish entries (single or bulk up to 100)
unpublish_entryUnpublish entries (single or bulk up to 100)
delete_entryRemove entries
resolve_entry_referencesRecursively resolve an entry's references tree
Editor Interfaceslist_editor_interfacesList all editor interfaces in a space
get_editor_interfaceGet editor interface for a content type
update_editor_interfaceUpdate field controls, sidebars, and layouts
Assetsupload_assetUpload new assets
list_assetsList and browse assets (max 3 per request)
get_assetRetrieve specific assets
update_assetModify asset metadata
publish_assetPublish assets (single or bulk up to 100)
unpublish_assetUnpublish assets (single or bulk up to 100)
delete_assetRemove assets
Spaces & Environmentslist_spacesList available spaces (max 10 per request)
get_spaceGet space details
list_environmentsList environments in a space
create_environmentCreate new environments
delete_environmentRemove environments
Localeslist_localesList all locales in your environment
get_localeRetrieve specific locale information
create_localeCreate new locales for multi-language content
update_localeModify existing locale settings
delete_localeRemove locales from environment
Tagslist_tagsList all tags in an environment
create_tagCreate new tags with public/private visibility
Organizationslist_orgsList organizations user has access to
get_orgGet details of a specific organization
Releaseslist_releasesList releases (max 10 per request)
get_releaseRetrieve a release
create_releaseCreate a release with Entries/Assets
update_releaseModify a release's title and/or contents
delete_releaseRemove a release (and its linked release actions)
publish_releasePublish a release (async; check via get_release_action)
unpublish_releaseUnpublish a release (async; check via get_release_action)
validate_releaseValidate a release, optionally against publish/unpublish
get_release_actionCheck the status of a queued release action
list_release_actionsList release actions (max 10 per request)
schedule_publish_releaseSchedule a release to publish at a future datetime (or reschedule)
schedule_unpublish_releaseSchedule a release to unpublish at a future datetime (or reschedule)
cancel_scheduled_releaseCancel a scheduled release action (two-phase confirm)
list_scheduled_actionsList scheduled actions (max 10 per request)
AI Actionscreate_ai_actionCreate custom AI-powered workflows
invoke_ai_actionInvoke AI action with variables (bulk support)
get_ai_action_invocationGet AI action invocation details
get_ai_actionRetrieve AI action details and configuration
list_ai_actionsList AI actions in a space (max 3 per request)
update_ai_actionUpdate existing AI actions
publish_ai_actionPublish AI actions for use
unpublish_ai_actionUnpublish AI actions
delete_ai_actionRemove AI actions
Taxonomy Conceptscreate_conceptCreate new taxonomy concepts with localization
get_conceptRetrieve specific taxonomy concept
list_conceptsList concepts with filtering and hierarchy
update_conceptUpdate taxonomy concept properties
delete_conceptRemove taxonomy concepts
Taxonomy Schemescreate_concept_schemeCreate new taxonomy concept schemes
get_concept_schemeRetrieve specific concept scheme
list_concept_schemesList concept schemes with pagination
update_concept_schemeUpdate concept scheme properties
delete_concept_schemeRemove concept schemes
Space Migrationspace_to_space_migration_handlerEnable/disable space migration workflow
space_to_space_param_collectionCollect parameters for migration workflow
export_spaceExport space to file for migration
import_spaceImport space from exported file
Usageget_usagesGet aggregated usage metrics for an organization, optionally filtered or grouped by space

🤝 Contributing

We welcome contributions! Please see our Contributing Guide for local development setup and contribution guidelines.

📦 Releases

This project uses Nx Release for automated versioning and publishing. Releases are automatically generated based on Conventional Commits. See Contributing Guide for more information on release process.

📚 Documentation

❓ Help & Support

📄 License and Notices

This project is licensed under the MIT License. See LICENSE for details.

It also includes open-source components licensed under MIT, BSD-2-Clause, and Apache-2.0. For details, see the NOTICE file.

This project includes an automated license management system that keeps track of all dependencies and their licenses. See the AUTOMATION-FOR-LICENSES file for more information.

🛡️ Code of Conduct

We want to provide a safe, inclusive, welcoming, and harassment-free space and experience for all participants, regardless of gender identity and expression, sexual orientation, disability, physical appearance, socioeconomic status, body size, ethnicity, nationality, level of experience, age, religion (or lack thereof), or other identity markers.

Read our full Code of Conduct.

版本与发布记录

@contentful/mcp-server 共发布 111 个版本,首次发布于 2025/07/25;过去 12 个月发布了 88 个版本。

版本发布日期距今
1.24.5latest2026/11/064 天前
1.24.42026/11/065 天前
1.24.32026/11/028 天前
1.24.22026/10/2912 天前
1.24.12026/10/2813 天前
1.24.02026/10/2714 天前

其他发布通道:dev → 1.7.0-dev-20251118T2209-4951c6c.0,next → 1.12.4-next.2。

关于 @contentful/mcp-server 的常见问题

@contentful/mcp-server 是什么?

Contentful MCP Server - Model Context Protocol server for Contentful

如何安装 @contentful/mcp-server?

在项目目录运行 npm install @contentful/mcp-server,或使用 pnpm add / yarn add / bun add。它还提供命令行工具 contentful-mcp-server,可以用 npx contentful-mcp-server 直接运行。

@contentful/mcp-server 支持 TypeScript 吗?

支持。包内自带 TypeScript 类型声明(package.json 声明了 types 入口),安装后即可获得类型提示,无需再安装 @types 包。

@contentful/mcp-server 支持 ESM 还是 CommonJS?

以 ES Module 形式发布,推荐使用 import 引入。在 CommonJS 项目中,Node.js 20.19+ / 22.12+ 可以直接 require() 不含顶层 await 的 ES Module,更早的版本需要改用动态 import()。

@contentful/mcp-server 可以商用吗?

@contentful/mcp-server 使用 MIT 许可。宽松许可:允许商业使用、修改和再分发,通常只需在分发时保留原版权与许可声明。以上为概括,不构成法律意见,请以许可原文为准。

@contentful/mcp-server 的下载量有多少?

根据 npm 官方下载统计,@contentful/mcp-server 在 2026/10/11 – 2026/11/09 这 30 天内被下载 38,843 次,日均约 1,295 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@contentful/mcp-server 还在维护吗?

最新版本 1.24.5 发布于 2026/11/06(4 天前);至今共发布 111 个版本,其中过去 12 个月发布了 88 个;首次发布于 2025/07/25。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。