MCP 服务器项目
该项目包含多个 MCP 服务器,用于处理客户访谈、端到端测试和上线流程等各种任务。每个 MCP 服务器均使用 FastMCP 框架实现。
先决条件
- Python 3.11 或更高版本
uv
包管理器(代替pip
使用)
设置
- 克隆存储库:
- 使用
uv
安装依赖项:
运行项目
要运行特定的 MCP 服务器,请使用以下命令:
将<mcp_server_name>
替换为您要运行的 MCP 服务器的名称。可用选项包括:
hello
customer_mcp
interview_mcp
go_live_mcp
testing_e2e_mcp
例子
要运行customer_mcp
服务器:
这将启动customer_mcp
服务器并使其可在以下位置访问:
使用 Docker Compose 运行
您可以使用 Docker Compose 同时运行所有 MCP 服务器。每个服务器将暴露在不同的端口上。
运行步骤
- 构建并启动所有服务:
- 通过以下 URL 访问 MCP 服务器:
hello-mcp
: http://127.0.0.1: 8000/hello-server/mcpcustomer-mcp
: http://127.0.0.1 :8001/customer-mcp-server/mcpinterview-mcp
: http://127.0.0.1 :8002/interview-mcp-server/mcpgo-live-mcp
: http://127.0.0.1 :8003/go-live-mcp-server/mcptesting-e2e-mcp
: http://127.0.0.1:8004/ testing-e2e-mcp-server/mcp
- 停止所有服务:
笔记
- 确保您的系统上安装了 Docker 和 Docker Compose。
- 每个 MCP 服务器都在其自己的容器中运行,并可通过其各自的端口进行访问。
在 VSCode 中配置 MCP 服务器
要在 VSCode 中配置 MCP 服务器,您可以在settings.json
文件的mcp.servers
部分添加条目。这允许您定义和管理 MCP 服务器端点,以便轻松访问。
示例配置
要配置hello-mcp-server
,请将以下条目添加到您的settings.json
文件:
然后您可以通过在 Copilot 中执行: #hello <something>
来访问 hello 服务器hello
工具。
添加配置的步骤
- 打开你的 VSCode
settings.json
文件。 - 找到或创建
mcp.servers
部分。 - 添加所需 MCP 服务器的配置,如上例所示。
访问服务器
配置完成后,您可以使用定义的 URL 与 MCP 服务器进行交互。例如, hello-mcp-server
可以通过以下方式访问:
此设置确保您可以直接从 VSCode 轻松管理和测试 MCP 服务器。
项目结构
main.py
:运行 MCP 服务器的入口点。customer_mcp.py
:处理与客户访谈相关的任务。interview_mcp.py
:管理客户访谈步骤。go_live_mcp.py
:处理上线流程。testing_e2e_mcp.py
:管理 E2E 测试任务。hello.py
:用于测试的示例 MCP 服务器。
笔记
- 确保
uv
包管理器已正确安装和配置。 - 使用
--mcp
参数指定要运行哪个 MCP 服务器。
This server cannot be installed
local-only server
The server can only run on the client's local machine because it depends on local resources.
使用 FastMCP 框架构建的 MCP 服务器集合,可处理包括客户访谈、E2E 测试和上线流程在内的各种任务,并可通过 VSCode 与 GitHub Copilot 无缝集成。
Related MCP Servers
- AsecurityAlicenseAqualityA MCP server for managing and storing code snippets in various programming languages, allowing users to create, list, and delete snippets via a standardized interface.Last updated -34JavaScriptMIT License
- -securityAlicense-qualityFastMCP is a comprehensive MCP server allowing secure and standardized data and functionality exposure to LLM applications, offering resources, tools, and prompt management for efficient LLM interactions.Last updated -3PythonMIT License
- AsecurityFlicenseAqualityAn MCP server implementation that enables interaction with the Unstructured API, providing tools to list, create, update, and manage sources, destinations, and workflows.Last updated -3928
- AsecurityAlicenseAqualityMCP Server for the Peacock extension for VS Code (https://peacockcode.dev), coloring your world, one Code editor at a time. The main goal of the project is to show how an MCP server can be used to interact with APIs.Last updated -1391TypeScriptMIT License