@@ -10,7 +10,7 @@ FastMCP run command implementation with enhanced type hints.
1010
1111## Functions
1212
13- ### ` is_url ` <sup ><a href = " https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/run.py#L28 " target = " _blank" ><Icon icon = " github" style = " width: 14px; height: 14px;" /></a ></sup >
13+ ### ` is_url ` <sup ><a href = " https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/run.py#L25 " target = " _blank" ><Icon icon = " github" style = " width: 14px; height: 14px;" /></a ></sup >
1414
1515``` python
1616is_url(path: str ) -> bool
@@ -20,35 +20,7 @@ is_url(path: str) -> bool
2020Check if a string is a URL.
2121
2222
23- ### ` run_with_uv ` <sup ><a href = " https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/run.py#L34" target = " _blank" ><Icon icon = " github" style = " width: 14px; height: 14px;" /></a ></sup >
24-
25- ``` python
26- run_with_uv(server_spec: str , python_version: str | None = None , with_packages: list[str ] | None = None , with_requirements: Path | None = None , project: Path | None = None , transport: TransportType | None = None , host: str | None = None , port: int | None = None , path: str | None = None , log_level: LogLevelType | None = None , show_banner: bool = True , editable: str | list[str ] | None = None ) -> None
27- ```
28-
29-
30- Run a MCP server using uv run subprocess.
31-
32- This function is called when we need to set up a Python environment with specific
33- dependencies before running the server. The config parsing and merging should already
34- be done by the caller.
35-
36- ** Args:**
37- - ` server_spec ` : Python file, object specification (file\: obj), config file, or URL
38- - ` python_version ` : Python version to use (e.g. "3.10")
39- - ` with_packages ` : Additional packages to install
40- - ` with_requirements ` : Requirements file to use
41- - ` project ` : Run the command within the given project directory
42- - ` transport ` : Transport protocol to use
43- - ` host ` : Host to bind to when using http transport
44- - ` port ` : Port to bind to when using http transport
45- - ` path ` : Path to bind to when using http transport
46- - ` log_level ` : Log level
47- - ` show_banner ` : Whether to show the server banner
48- - ` editable ` : Editable package paths
49-
50-
51- ### ` create_client_server ` <sup ><a href = " https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/run.py#L115" target = " _blank" ><Icon icon = " github" style = " width: 14px; height: 14px;" /></a ></sup >
23+ ### ` create_client_server ` <sup ><a href = " https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/run.py#L31" target = " _blank" ><Icon icon = " github" style = " width: 14px; height: 14px;" /></a ></sup >
5224
5325``` python
5426create_client_server(url: str ) -> Any
@@ -64,7 +36,7 @@ Create a FastMCP server from a client URL.
6436- A FastMCP server instance
6537
6638
67- ### ` create_mcp_config_server ` <sup ><a href = " https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/run.py#L135 " target = " _blank" ><Icon icon = " github" style = " width: 14px; height: 14px;" /></a ></sup >
39+ ### ` create_mcp_config_server ` <sup ><a href = " https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/run.py#L51 " target = " _blank" ><Icon icon = " github" style = " width: 14px; height: 14px;" /></a ></sup >
6840
6941``` python
7042create_mcp_config_server(mcp_config_path: Path) -> FastMCP[None ]
@@ -74,7 +46,7 @@ create_mcp_config_server(mcp_config_path: Path) -> FastMCP[None]
7446Create a FastMCP server from a MCPConfig.
7547
7648
77- ### ` load_mcp_server_config ` <sup ><a href = " https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/run.py#L146 " target = " _blank" ><Icon icon = " github" style = " width: 14px; height: 14px;" /></a ></sup >
49+ ### ` load_mcp_server_config ` <sup ><a href = " https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/run.py#L62 " target = " _blank" ><Icon icon = " github" style = " width: 14px; height: 14px;" /></a ></sup >
7850
7951``` python
8052load_mcp_server_config(config_path: Path) -> MCPServerConfig
@@ -90,7 +62,7 @@ Load a FastMCP configuration from a fastmcp.json file.
9062- MCPServerConfig object
9163
9264
93- ### ` run_command ` <sup ><a href = " https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/run.py#L163 " target = " _blank" ><Icon icon = " github" style = " width: 14px; height: 14px;" /></a ></sup >
65+ ### ` run_command ` <sup ><a href = " https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/run.py#L79 " target = " _blank" ><Icon icon = " github" style = " width: 14px; height: 14px;" /></a ></sup >
9466
9567``` python
9668run_command(server_spec: str , transport: TransportType | None = None , host: str | None = None , port: int | None = None , path: str | None = None , log_level: LogLevelType | None = None , server_args: list[str ] | None = None , show_banner: bool = True , use_direct_import: bool = False , skip_source: bool = False ) -> None
@@ -112,7 +84,7 @@ Run a MCP server or connect to a remote one.
11284- ` skip_source ` : Whether to skip source preparation step
11385
11486
115- ### ` run_v1_server ` <sup ><a href = " https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/run.py#L284 " target = " _blank" ><Icon icon = " github" style = " width: 14px; height: 14px;" /></a ></sup >
87+ ### ` run_v1_server ` <sup ><a href = " https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/run.py#L200 " target = " _blank" ><Icon icon = " github" style = " width: 14px; height: 14px;" /></a ></sup >
11688
11789``` python
11890run_v1_server(server: FastMCP1x, host: str | None = None , port: int | None = None , transport: TransportType | None = None ) -> None
0 commit comments