发展
设置您的环境
首先,让我们安装 uv 并设置我们的 Python 项目和环境:
MacOS/Linux : curl -LsSf https://astral.sh/uv/install.sh | sh
Windows : powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"之后请确保重新启动终端以确保 uv 命令被接收。
现在,让我们创建并设置我们的项目:
运行本地克劳德桌面应用程序
确保你需要更新 claude_desktop_config.json 来注册工具
Related MCP server: GitHub MCP Server
你可以找到 claude_desktop_config.json :
For Windows : code $env:AppData\Claude\claude_desktop_config.json
For Mac/Linux :code ~/Library/Application\ Support/Claude/claude_desktop_config.json{
"mcpServers": {
"Github-Oauth": {
"command": "C:\\Users\\Hp\\.local\\bin\\uv",
"args": [
"--directory",
"C:\\Users\\Hp\\Github-Oauth\\src\\github_oauth",
"run",
"server.py"
]
}
}
}调试
由于 MCP 服务器通过 stdio 运行,调试起来可能比较困难。为了获得最佳调试体验,我们强烈建议使用MCP Inspector 。
您可以使用以下命令通过npm启动 MCP Inspector:
npx @modelcontextprotocol/inspector uv --directory C:\Users\Hp\Github-Oauth run github-oauth启动后,检查器将显示一个 URL,您可以在浏览器中访问该 URL 以开始调试。
Resources
Looking for Admin?
Admins can modify the Dockerfile, update the server description, and track usage metrics. If you are the server author, to authenticate as an admin.