
Contentful MCP Server

2025.03.28
0
TypeScript内容管理系统集成AI助手扩展内容生成
Contentful MCP Server 是一个模型上下文协议(MCP)服务器,允许 Claude 直接与 Contentful CMS 数据进行交互。该集成使 Claude 能够从您的 Contentful 空间中获取内容类型和条目。
View on GitHub
Overview
基本能力
产品定位
Contentful MCP Server 是一个用于连接 Claude 和 Contentful CMS 的中间件,旨在通过 MCP 协议实现 AI 助手与内容管理系统的无缝交互。
核心功能
- 从 Contentful 空间获取所有内容类型
- 检索特定内容类型的条目
- 提供结构化响应,便于 AI 助手使用
适用场景
- 当需要 Claude 访问和操作 Contentful CMS 中的内容时
- 在开发需要内容管理系统集成的 AI 助手应用时
- 需要将结构化内容提供给 AI 进行处理的场景
工具列表
- Node.js 环境:运行服务器的基础
- Contentful API:与 Contentful 服务交互
- Claude Desktop:使用 MCP 服务器的客户端
常见问题解答
(文档中未提供具体常见问题)
使用教程
使用依赖
- Node.js (v16 或更高版本)
- Contentful 账户及 API 密钥
- Claude Desktop
安装 Node.js 命令(以 Ubuntu 为例):
curl -fsSL https://deb.nodesource.com/setup_16.x | sudo -E bash -
sudo apt-get install -y nodejs
安装教程
- 克隆仓库:
git clone https://github.com/yourusername/contentful-mcp-server.git
cd contentful-mcp-server
- 安装依赖:
npm install
- 创建 .env 文件并配置 Contentful 凭证:
CONTENTFUL_SPACE_ID=your_space_id
CONTENTFUL_ACCESS_TOKEN=your_access_token
CONTENTFUL_ENVIRONMENT=develop
CONTENTFUL_PREVIEW_ACCESS_TOKEN=your_preview_token
- 构建项目:
npm run build
调试方式
- 启动服务器:
npm start
- 配置 Claude Desktop 连接:
{
"mcpServers": {
"contentful": {
"command": "node",
"args": [
"/absolute/path/to/contentful-mcp-server/dist/index.js"
]
}
}
}
许可证
None