From 31076ab2d4680dac2dbf57275634e7e90c05b925 Mon Sep 17 00:00:00 2001 From: Vividh Mahajan <82711162+Lasdw6@users.noreply.github.com> Date: Fri, 4 Jul 2025 05:05:40 -0400 Subject: [PATCH] docs: fix dev server command in README (#848) (#859) --- README.md | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index 412143a9..f2b00123 100644 --- a/README.md +++ b/README.md @@ -133,12 +133,12 @@ def get_greeting(name: str) -> str: You can install this server in [Claude Desktop](https://claude.ai/download) and interact with it right away by running: ```bash -mcp install server.py +uv run mcp install server.py ``` Alternatively, you can test it with the MCP Inspector: ```bash -mcp dev server.py +uv run mcp dev server.py ``` ## What is MCP? @@ -589,13 +589,13 @@ See [TokenVerifier](src/mcp/server/auth/provider.py) for more details on impleme The fastest way to test and debug your server is with the MCP Inspector: ```bash -mcp dev server.py +uv run mcp dev server.py # Add dependencies -mcp dev server.py --with pandas --with numpy +uv run mcp dev server.py --with pandas --with numpy # Mount local code -mcp dev server.py --with-editable . +uv run mcp dev server.py --with-editable . ``` ### Claude Desktop Integration @@ -603,14 +603,14 @@ mcp dev server.py --with-editable . Once your server is ready, install it in Claude Desktop: ```bash -mcp install server.py +uv run mcp install server.py # Custom name -mcp install server.py --name "My Analytics Server" +uv run mcp install server.py --name "My Analytics Server" # Environment variables -mcp install server.py -v API_KEY=abc123 -v DB_URL=postgres://... -mcp install server.py -f .env +uv run mcp install server.py -v API_KEY=abc123 -v DB_URL=postgres://... +uv run mcp install server.py -f .env ``` ### Direct Execution @@ -630,10 +630,10 @@ Run it with: ```bash python server.py # or -mcp run server.py +uv run mcp run server.py ``` -Note that `mcp run` or `mcp dev` only supports server using FastMCP and not the low-level server variant. +Note that `uv run mcp run` or `uv run mcp dev` only supports server using FastMCP and not the low-level server variant. ### Streamable HTTP Transport @@ -949,7 +949,7 @@ if __name__ == "__main__": asyncio.run(run()) ``` -Caution: The `mcp run` and `mcp dev` tool doesn't support low-level server. +Caution: The `uv run mcp run` and `uv run mcp dev` tool doesn't support low-level server. #### Structured Output Support