Skip to content

Commit e4a3ed7

Browse files
author
Rudrendu
committed
docs: add CLI reference table for mcp dev/run/install flags
Github-Issue: #457
1 parent cf4e435 commit e4a3ed7

File tree

1 file changed

+38
-0
lines changed

1 file changed

+38
-0
lines changed

README.md

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@
5353
- [Development Mode](#development-mode)
5454
- [Claude Desktop Integration](#claude-desktop-integration)
5555
- [Direct Execution](#direct-execution)
56+
- [CLI Reference](#cli-reference)
5657
- [Streamable HTTP Transport](#streamable-http-transport)
5758
- [CORS Configuration for Browser-Based Clients](#cors-configuration-for-browser-based-clients)
5859
- [Mounting to an Existing ASGI Server](#mounting-to-an-existing-asgi-server)
@@ -1241,6 +1242,43 @@ uv run mcp run servers/direct_execution.py
12411242

12421243
Note that `uv run mcp run` or `uv run mcp dev` only supports server using FastMCP and not the low-level server variant.
12431244

1245+
### CLI Reference
1246+
1247+
A complete reference for all `mcp` CLI commands and their flags.
1248+
1249+
#### `mcp dev <file_spec>`
1250+
1251+
Run an MCP server with the [MCP Inspector](https://github.com/modelcontextprotocol/inspector) for interactive testing and debugging.
1252+
1253+
| Flag | Short | Type | Description |
1254+
|------|-------|------|-------------|
1255+
| `--with-editable` | `-e` | `PATH` | Directory containing `pyproject.toml` to install in editable mode |
1256+
| `--with` | | `TEXT` | Additional packages to install (repeatable) |
1257+
1258+
#### `mcp run <file_spec>`
1259+
1260+
Run an MCP server directly. The server can be specified as a module (`server.py`) or with an explicit object path (`server.py:app`).
1261+
1262+
| Flag | Short | Type | Description |
1263+
|------|-------|------|-------------|
1264+
| `--transport` | `-t` | `stdio\|sse` | Transport protocol to use (default: `stdio`) |
1265+
1266+
#### `mcp install <file_spec>`
1267+
1268+
Install an MCP server in the Claude Desktop app. Environment variables are preserved once set and only updated when new values are explicitly provided.
1269+
1270+
| Flag | Short | Type | Description |
1271+
|------|-------|------|-------------|
1272+
| `--name` | `-n` | `TEXT` | Custom name for the server (defaults to file name) |
1273+
| `--with-editable` | `-e` | `PATH` | Directory containing `pyproject.toml` to install in editable mode |
1274+
| `--with` | | `TEXT` | Additional packages to install (repeatable) |
1275+
| `--env-var` | `-v` | `KEY=VALUE` | Environment variables in `KEY=VALUE` format (repeatable) |
1276+
| `--env-file` | `-f` | `PATH` | Load environment variables from a `.env` file |
1277+
1278+
#### `mcp version`
1279+
1280+
Print the installed MCP SDK version.
1281+
12441282
### Streamable HTTP Transport
12451283

12461284
> **Note**: Streamable HTTP transport is the recommended transport for production deployments. Use `stateless_http=True` and `json_response=True` for optimal scalability.

0 commit comments

Comments
 (0)