Skip to content

Commit 6429b5b

Browse files
chore: Update SDK documentation
1 parent 80d10d2 commit 6429b5b

File tree

3 files changed

+26
-23
lines changed

3 files changed

+26
-23
lines changed

docs/python-sdk/fastmcp-cli-install-cursor.mdx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ Generate a Cursor deeplink for installing the MCP server.
2727
- Deeplink URL that can be clicked to install the server
2828

2929

30-
### `open_deeplink` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/install/cursor.py#L47" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
30+
### `open_deeplink` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/install/cursor.py#L48" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
3131

3232
```python
3333
open_deeplink(deeplink: str) -> bool
@@ -43,7 +43,7 @@ Attempt to open a deeplink URL using the system's default handler.
4343
- True if the command succeeded, False otherwise
4444

4545

46-
### `install_cursor_workspace` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/install/cursor.py#L73" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
46+
### `install_cursor_workspace` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/install/cursor.py#L74" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
4747

4848
```python
4949
install_cursor_workspace(file: Path, server_object: str | None, name: str, workspace_path: Path) -> bool
@@ -68,7 +68,7 @@ Install FastMCP server to workspace-specific Cursor configuration.
6868
- True if installation was successful, False otherwise
6969

7070

71-
### `install_cursor` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/install/cursor.py#L154" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
71+
### `install_cursor` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/install/cursor.py#L155" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
7272

7373
```python
7474
install_cursor(file: Path, server_object: str | None, name: str) -> bool
@@ -93,7 +93,7 @@ Install FastMCP server in Cursor.
9393
- True if installation was successful, False otherwise
9494

9595

96-
### `cursor_command` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/install/cursor.py#L239" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
96+
### `cursor_command` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/cli/install/cursor.py#L240" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
9797

9898
```python
9999
cursor_command(server_spec: str) -> None

docs/python-sdk/fastmcp-client-client.mdx

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -476,7 +476,7 @@ Retrieve a list of tools available on the server.
476476
#### `call_tool_mcp` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/client/client.py#L877" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
477477

478478
```python
479-
call_tool_mcp(self, name: str, arguments: dict[str, Any], progress_handler: ProgressHandler | None = None, timeout: datetime.timedelta | float | int | None = None) -> mcp.types.CallToolResult
479+
call_tool_mcp(self, name: str, arguments: dict[str, Any], progress_handler: ProgressHandler | None = None, timeout: datetime.timedelta | float | int | None = None, meta: dict[str, Any] | None = None) -> mcp.types.CallToolResult
480480
```
481481

482482
Send a tools/call request and return the complete MCP protocol result.
@@ -489,6 +489,7 @@ and other metadata. It does not raise an exception if the tool call results in a
489489
- `arguments`: Arguments to pass to the tool.
490490
- `timeout`: The timeout for the tool call. Defaults to None.
491491
- `progress_handler`: The progress handler to use for the tool call. Defaults to None.
492+
- `meta`: Additional metadata to send with the tool call.
492493

493494
**Returns:**
494495
- mcp.types.CallToolResult: The complete response object from the protocol,
@@ -498,10 +499,10 @@ containing the tool result and any additional metadata.
498499
- `RuntimeError`: If called while the client is not connected.
499500

500501

501-
#### `call_tool` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/client/client.py#L915" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
502+
#### `call_tool` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/client/client.py#L919" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
502503

503504
```python
504-
call_tool(self, name: str, arguments: dict[str, Any] | None = None, timeout: datetime.timedelta | float | int | None = None, progress_handler: ProgressHandler | None = None, raise_on_error: bool = True) -> CallToolResult
505+
call_tool(self, name: str, arguments: dict[str, Any] | None = None, timeout: datetime.timedelta | float | int | None = None, progress_handler: ProgressHandler | None = None, raise_on_error: bool = True, meta: dict[str, Any] | None = None) -> CallToolResult
505506
```
506507

507508
Call a tool on the server.
@@ -513,6 +514,8 @@ Unlike call_tool_mcp, this method raises a ToolError if the tool call results in
513514
- `arguments`: Arguments to pass to the tool. Defaults to None.
514515
- `timeout`: The timeout for the tool call. Defaults to None.
515516
- `progress_handler`: The progress handler to use for the tool call. Defaults to None.
517+
- `raise_on_error`: Whether to raise a ToolError if the tool call results in an error. Defaults to True.
518+
- `meta`: Additional metadata to send with the tool call.
516519

517520
**Returns:**
518521
-
@@ -528,10 +531,10 @@ raw result object.
528531
- `RuntimeError`: If called while the client is not connected.
529532

530533

531-
#### `generate_name` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/client/client.py#L987" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
534+
#### `generate_name` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/client/client.py#L995" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
532535

533536
```python
534537
generate_name(cls, name: str | None = None) -> str
535538
```
536539

537-
### `CallToolResult` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/client/client.py#L996" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
540+
### `CallToolResult` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/client/client.py#L1004" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>

docs/python-sdk/fastmcp-server-auth-auth.mdx

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,13 @@ sidebarTitle: auth
77

88
## Classes
99

10-
### `AccessToken` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L32" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
10+
### `AccessToken` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L36" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
1111

1212

1313
AccessToken that includes all JWT claims.
1414

1515

16-
### `AuthProvider` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L38" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
16+
### `AuthProvider` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L42" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
1717

1818

1919
Base class for all FastMCP authentication providers.
@@ -26,7 +26,7 @@ custom authentication routes.
2626

2727
**Methods:**
2828

29-
#### `verify_token` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L65" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
29+
#### `verify_token` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L69" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
3030

3131
```python
3232
verify_token(self, token: str) -> AccessToken | None
@@ -43,7 +43,7 @@ All auth providers must implement token verification.
4343
- AccessToken object if valid, None if invalid or expired
4444

4545

46-
#### `get_routes` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L78" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
46+
#### `get_routes` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L82" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
4747

4848
```python
4949
get_routes(self, mcp_path: str | None = None) -> list[Route]
@@ -67,7 +67,7 @@ provider does not create the actual MCP endpoint route.
6767
- List of all routes for this provider (excluding the MCP endpoint itself)
6868

6969

70-
#### `get_well_known_routes` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L101" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
70+
#### `get_well_known_routes` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L105" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
7171

7272
```python
7373
get_well_known_routes(self, mcp_path: str | None = None) -> list[Route]
@@ -95,7 +95,7 @@ This is used to construct path-scoped well-known URLs.
9595
- List of well-known discovery routes (typically mounted at root level)
9696

9797

98-
#### `get_middleware` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L133" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
98+
#### `get_middleware` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L137" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
9999

100100
```python
101101
get_middleware(self) -> list
@@ -107,7 +107,7 @@ Get HTTP application-level middleware for this auth provider.
107107
- List of Starlette Middleware instances to apply to the HTTP app
108108

109109

110-
### `TokenVerifier` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L166" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
110+
### `TokenVerifier` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L170" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
111111

112112

113113
Base class for token verifiers (Resource Servers).
@@ -118,7 +118,7 @@ Token verifiers typically don't provide authentication routes by default.
118118

119119
**Methods:**
120120

121-
#### `verify_token` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L187" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
121+
#### `verify_token` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L191" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
122122

123123
```python
124124
verify_token(self, token: str) -> AccessToken | None
@@ -127,7 +127,7 @@ verify_token(self, token: str) -> AccessToken | None
127127
Verify a bearer token and return access info if valid.
128128

129129

130-
### `RemoteAuthProvider` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L192" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
130+
### `RemoteAuthProvider` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L196" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
131131

132132

133133
Authentication provider for resource servers that verify tokens from known authorization servers.
@@ -144,7 +144,7 @@ the authorization servers that issue valid tokens.
144144

145145
**Methods:**
146146

147-
#### `verify_token` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L233" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
147+
#### `verify_token` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L237" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
148148

149149
```python
150150
verify_token(self, token: str) -> AccessToken | None
@@ -153,7 +153,7 @@ verify_token(self, token: str) -> AccessToken | None
153153
Verify token using the configured token verifier.
154154

155155

156-
#### `get_routes` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L237" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
156+
#### `get_routes` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L241" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
157157

158158
```python
159159
get_routes(self, mcp_path: str | None = None) -> list[Route]
@@ -164,7 +164,7 @@ Get routes for this provider.
164164
Creates protected resource metadata routes (RFC 9728).
165165

166166

167-
### `OAuthProvider` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L265" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
167+
### `OAuthProvider` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L269" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
168168

169169

170170
OAuth Authorization Server provider.
@@ -175,7 +175,7 @@ authorization flows, token issuance, and token verification.
175175

176176
**Methods:**
177177

178-
#### `verify_token` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L321" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
178+
#### `verify_token` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L332" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
179179

180180
```python
181181
verify_token(self, token: str) -> AccessToken | None
@@ -193,7 +193,7 @@ to our existing load_access_token method.
193193
- AccessToken object if valid, None if invalid or expired
194194

195195

196-
#### `get_routes` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L336" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
196+
#### `get_routes` <sup><a href="https://github.com/jlowin/fastmcp/blob/main/src/fastmcp/server/auth/auth.py#L347" target="_blank"><Icon icon="github" style="width: 14px; height: 14px;" /></a></sup>
197197

198198
```python
199199
get_routes(self, mcp_path: str | None = None) -> list[Route]

0 commit comments

Comments
 (0)