MCP.so
登录

Claude-Compatible MCP Server Setup

@bhupender-kaushal

基本信息

分类

AI 与智能体

传输方式

stdio

作者

bhupender-kaushal

关于 Claude-Compatible MCP Server Setup

A demo using MCP servers.

Claude-Compatible MCP Server Setup 配置

使用下面的配置,将此服务器添加到你的 MCP 客户端。

{
  "mcpServers": {
    "MCP_Demo": {
      "command": "uv",
      "args": [
        "run",
        "mcp",
        "install",
        "main.py"
      ]
    }
  }
}

Claude-Compatible MCP Server Setup 工具

工具列表暂未提供

当前收录暂时没有可展示的工具列表,不代表服务没有工具。请查阅项目文档了解支持的能力。

工具是从 README 中自动提取的。维护者可以在 ## Tools 标题下列出工具,即可填充这部分内容。

概览

What is Claude-Compatible MCP Server Setup?

A guide for creating and running a Claude-compatible MCP server using Python, FastMCP, and the uv package manager, supporting Windows, macOS, and Linux. It provides a template server (Demo) with a sample tool and resource.

How to use Claude-Compatible MCP Server Setup?

Create a main.py file with a FastMCP server, install uv, then run uv run mcp install main.py to register the server. Optionally test manually with uv run --python 3.12 --with "mcp[cli]" mcp run main.py.

Key features of Claude-Compatible MCP Server Setup

  • Uses Python ≥ 3.12 and FastMCP
  • Fully compatible with Claude
  • Supports both tools and resources
  • Simplified install via uv and mcp install
  • Works on Windows, macOS, and Linux

Use cases of Claude-Compatible MCP Server Setup

  • Quickly prototype a custom MCP server for Claude
  • Add arithmetic tools and dynamic greeting resources
  • Learn the standard MCP server setup workflow
  • Test MCP implementations without manual JSON configuration

常见问题

1

What dependencies are required?

Python ≥ 3.12, `uv` installed, and the `mcp[cli]` package (added via `uv add "mcp[cli]"`).

2

Why does `spawn uv ENOENT` happen?

`uv` is not on your system PATH. Add `~/.local/bin` (macOS/Linux) or `%USERPROFILE%\.cargo\bin` (Windows) to your PATH.

3

Why does `spawn uv EACCES` happen?

`uv` exists but is not executable (macOS/Linux). Run `chmod +x ~/.local/bin/uv`.

4

How do I fix a Python version error?

Install Python 3.12 or use `uv run --python 3.12` or create a `.python-version` file with `3.12`.

5

What if Claude doesn't connect?

Ensure the server name in `FastMCP("YourName")` matches what Claude expects, and add logging to verify the server is running.

评论

AI 与智能体 分类下的更多 MCP 服务器