返回市场
云栖地-mcp-服务器

云栖地-mcp-服务器

作者:felores9 星标更新:2025-03-14

项目介绍

Cloudinary MCP Server

此MCP服务器提供了通过Claude Desktop和兼容的MCP客户端上传图片和视频到Cloudinary的工具。

<a href="https://glama.ai/mcp/servers/zjiw1ry8ly"><img width="380" height="200" src="https://gips2.baidu.com/it/u=411916495,3006091087&fm=3081&app=3081&f=PNG?w=760&h=400" alt="Cloudinary Server MCP server" /></a>

安装

要求:Node.js

  1. nodejs.org安装Node.js(版本18或更高)和npm。
  2. 验证安装:
    node --version
    npm --version
    

使用npx安装(推荐)

  1. 导航到Claude配置目录:

    • Windows: C:\Users\NAME\AppData\Roaming\Claude
    • macOS: ~/Library/Application Support/Claude/

    您也可以在Claude Desktop应用中找到这些目录:Claude Desktop > 设置 > 开发者 > 编辑配置

  2. 将以下配置添加到您的MCP设置文件中:

{
  "mcpServers": {
    "cloudinary": {
      "command": "npx",
      "args": ["@felores/cloudinary-mcp-server@latest"],
      "env": {
        "CLOUDINARY_CLOUD_NAME": "your_cloud_name",
        "CLOUDINARY_API_KEY": "your_api_key",
        "CLOUDINARY_API_SECRET": "your_api_secret"
      }
    }
  }
}
  1. 确保用您从Cloudinary控制台获取的Cloudinary凭证替换环境变量。

开发者安装

如果您想修改服务器或参与开发:

  1. 克隆仓库:
git clone https://github.com/felores/cloudinary-mcp-server.git
cd cloudinary-mcp-server
  1. 安装依赖并构建:
npm install
npm run build

设置说明

  1. 首先,确保您有一个Cloudinary账户,并从Cloudinary控制台获取您的凭证:

    • Cloud Name
    • API Key
    • API Secret
  2. 将服务器配置添加到您的Claude/Cline MCP设置文件中:

{
  "mcpServers": {
    "cloudinary": {
      "command": "node",
      "args": ["c:/path/to/cloudinary-mcp-server/dist/index.js"],
      "env": {
        "CLOUDINARY_CLOUD_NAME": "your_cloud_name",
        "CLOUDINARY_API_KEY": "your_api_key",
        "CLOUDINARY_API_SECRET": "your_api_secret"
      }
    }
  }
}

对于Claude桌面应用程序,在适当的位置编辑配置文件。

  1. 安装依赖并构建服务器:
npm install
npm run build

可用工具

upload

上传图片和视频到Cloudinary。

参数:

  • file(必需):要上传的文件路径、URL或base64数据URI
  • resource_type(可选):资源类型('image','video' 或 'raw')
  • public_id(可选):上传资产的自定义公共ID
  • overwrite(可选):是否覆盖具有相同公共ID的现有资产
  • tags(可选):分配给上传资产的标签数组

在Claude/Cline中的示例用法:

use_mcp_tool({
  server_name: "cloudinary",
  tool_name: "upload",
  arguments: {
    file: "path/to/image.jpg",
    resource_type: "image",
    public_id: "my-custom-id"
  }
});