content
large_stringlengths
3
20.5k
url
large_stringlengths
54
193
branch
large_stringclasses
4 values
source
large_stringclasses
42 values
embeddings
listlengths
384
384
score
float64
-0.21
0.65
immediately, returns the immediate result. Otherwise waits for background task to complete and retrieves result. \*\*Returns:\*\* - list\[ReadResourceContents]: The resource contents
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-client-tasks.mdx
main
model-context-protocol-fastmcp
[ -0.05937742069363594, 0.06555482745170593, -0.050172362476587296, 0.08582314848899841, 0.041659750044345856, -0.005381856579333544, 0.09789548814296722, -0.025318574160337448, 0.046756185591220856, -0.039067257195711136, 0.0010848906822502613, -0.009473035112023354, -0.00497180363163352, -...
0.067256
# `fastmcp.server.providers.skills.skill\_provider` Basic skill provider for handling a single skill folder. ## Classes ### `SkillResource` A resource representing a skill's main file or manifest. \*\*Methods:\*\* #### `read` ```python read(self) -> str | bytes | ResourceResult ``` Read the resource content. ### `Skill...
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-server-providers-skills-skill_provider.mdx
main
model-context-protocol-fastmcp
[ -0.09039632230997086, 0.02731739543378353, -0.052962563931941986, 0.04253937676548958, -0.05772753432393074, -0.05546708032488823, 0.06607768684625626, 0.03188939020037651, -0.058831531554460526, -0.02450225129723549, 0.045969776809215546, 0.03399872034788132, 0.04320593178272247, 0.022867...
0.043721
# `fastmcp.server.middleware.middleware` ## Functions ### `make\_middleware\_wrapper` ```python make\_middleware\_wrapper(middleware: Middleware, call\_next: CallNext[T, R]) -> CallNext[T, R] ``` Create a wrapper that applies a single middleware to a context. The closure bakes in the middleware and call\_next function,...
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-server-middleware-middleware.mdx
main
model-context-protocol-fastmcp
[ -0.11253300309181213, -0.001658720662817359, 0.02720803953707218, -0.03281916677951813, 0.02170165814459324, -0.12080051004886627, 0.047482799738645554, 0.015130865387618542, -0.015223514288663864, -0.030516577884554863, 0.0011642023455351591, -0.04395319148898125, 0.03653562441468239, 0.0...
0.146302
# `fastmcp.cli.client` Client-side CLI commands for querying and invoking MCP servers. ## Functions ### `resolve\_server\_spec` ```python resolve\_server\_spec(server\_spec: str | None) -> str | dict[str, Any] | ClientTransport ``` Turn CLI inputs into something ``Client()`` accepts. Exactly one of ``server\_spec`` or ...
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-cli-client.mdx
main
model-context-protocol-fastmcp
[ -0.07823184132575989, 0.01957501471042633, 0.024281032383441925, 0.0020867760758847, -0.04533106088638306, -0.1223817989230156, -0.015046479180455208, 0.04973926395177841, 0.006490528583526611, -0.0508125014603138, 0.00872411485761404, 0.021059494465589523, 0.030643679201602936, 0.04980815...
0.007336
# `fastmcp.utilities.openapi.formatters` Parameter formatting functions for OpenAPI operations. ## Functions ### `format\_array\_parameter` ```python format\_array\_parameter(values: list, parameter\_name: str, is\_query\_parameter: bool = False) -> str | list ``` Format an array parameter according to OpenAPI specific...
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-utilities-openapi-formatters.mdx
main
model-context-protocol-fastmcp
[ -0.027739064767956734, 0.07550260424613953, -0.04974861815571785, 0.03369373083114624, -0.07535509020090103, -0.07347016781568527, 0.03337159380316734, -0.005152552388608456, -0.05651232227683067, -0.07455170154571533, 0.0236775241792202, -0.06727921217679977, 0.051567986607551575, -0.0080...
0.055966
# `fastmcp.tools.function\_tool` Standalone @tool decorator for FastMCP. ## Functions ### `tool` ```python tool(name\_or\_fn: str | Callable[..., Any] | None = None) -> Any ``` Standalone decorator to mark a function as an MCP tool. Returns the original function with metadata attached. Register with a server using mcp....
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-tools-function_tool.mdx
main
model-context-protocol-fastmcp
[ -0.09454532712697983, -0.0026812306605279446, -0.016325613483786583, 0.04344755411148071, -0.06069362908601761, -0.07057330012321472, -0.024981627240777016, 0.003994743339717388, -0.047091081738471985, -0.0334988571703434, 0.04488052427768707, -0.055101584643125534, 0.028415285050868988, 0...
0.047138
# `fastmcp.cli.generate` Generate a standalone CLI script from an MCP server's capabilities. ## Functions ### `serialize\_transport` ```python serialize\_transport(resolved: str | dict[str, Any] | ClientTransport) -> tuple[str, set[str]] ``` Serialize a resolved transport to a Python expression string. Returns ``(expre...
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-cli-generate.mdx
main
model-context-protocol-fastmcp
[ -0.09732713550329208, 0.019409356638789177, -0.0023540500551462173, 0.00374845159240067, -0.023291826248168945, -0.07540395855903625, 0.032538317143917084, 0.026509571820497513, -0.03888166323304176, -0.016774235293269157, 0.03008446842432022, -0.08812238276004791, 0.04851862043142319, -0....
0.066149
# `fastmcp.client.mixins.task\_management` Task management methods for FastMCP Client. ## Classes ### `ClientTaskManagementMixin` Mixin providing task management methods for Client. \*\*Methods:\*\* #### `get\_task\_status` ```python get\_task\_status(self: Client, task\_id: str) -> GetTaskResult ``` Query the status o...
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-client-mixins-task_management.mdx
main
model-context-protocol-fastmcp
[ -0.0866335928440094, 0.006715055089443922, -0.0006546737276948988, 0.03769947588443756, -0.014665713533759117, -0.0906040221452713, 0.01297026127576828, 0.01653461530804634, -0.016444236040115356, -0.024777771905064583, 0.009245618246495724, -0.044805966317653656, 0.042769331485033035, 0.0...
0.126896
# `fastmcp.server.mixins.transport` Transport-related methods for FastMCP Server. ## Classes ### `TransportMixin` Mixin providing transport-related methods for FastMCP. Includes HTTP/stdio/SSE transport handling and custom HTTP routes. \*\*Methods:\*\* #### `run\_async` ```python run\_async(self: FastMCP, transport: Tr...
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-server-mixins-transport.mdx
main
model-context-protocol-fastmcp
[ -0.06562762707471848, 0.02541871927678585, -0.04122675210237503, 0.04965513199567795, -0.009276341646909714, -0.10387849807739258, -0.02935030497610569, -0.008859318681061268, 0.01855633594095707, -0.09154631197452545, 0.054149411618709564, -0.06191522255539894, 0.02507007122039795, -0.022...
0.047343
Create a Starlette app using the specified HTTP transport. \*\*Args:\*\* - `path`: The path for the HTTP endpoint - `middleware`: A list of middleware to apply to the app - `json\_response`: Whether to use JSON response format - `stateless\_http`: Whether to use stateless mode (new transport per request) - `transport`:...
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-server-mixins-transport.mdx
main
model-context-protocol-fastmcp
[ -0.051729023456573486, -0.047980524599552155, -0.04297434166073799, 0.04222339764237404, -0.055242426693439484, -0.007007318083196878, 0.024091586470603943, 0.0197250097990036, 0.001606777310371399, 0.02606925182044506, -0.07752478867769241, 0.0314825102686882, 0.03783803805708885, -0.0061...
0.136159
# `fastmcp.server.transforms.prompts\_as\_tools` Transform that exposes prompts as tools. This transform generates tools for listing and getting prompts, enabling clients that only support tools to access prompt functionality. Example: ```python from fastmcp import FastMCP from fastmcp.server.transforms import PromptsA...
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-server-transforms-prompts_as_tools.mdx
main
model-context-protocol-fastmcp
[ -0.061619214713573456, 0.016948144882917404, -0.0256507508456707, -0.005570757668465376, -0.009426567703485489, -0.050988201051950455, 0.057599928230047226, -0.007054635789245367, -0.014892448671162128, -0.02422441728413105, 0.035470202565193176, -0.0452239066362381, 0.06766337156295776, -...
0.000236
# `fastmcp.server.transforms.tool\_transform` Transform for applying tool transformations. ## Classes ### `ToolTransform` Applies tool transformations to modify tool schemas. Wraps ToolTransformConfig to apply argument renames, schema changes, hidden arguments, and other transformations at the transform level. \*\*Meth...
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-server-transforms-tool_transform.mdx
main
model-context-protocol-fastmcp
[ -0.09439118206501007, 0.012007089331746101, -0.03929087519645691, -0.006891258060932159, -0.09230411052703857, -0.03896156698465347, -0.0029744047205895185, -0.0295700766146183, 0.011923763900995255, -0.050370123237371445, 0.06504751741886139, -0.06796447932720184, 0.009595130570232868, -0...
-0.011446
# `fastmcp.cli.cli` FastMCP CLI tools using Cyclopts. ## Functions ### `with\_argv` ```python with\_argv(args: list[str] | None) ``` Temporarily replace sys.argv if args provided. This context manager is used at the CLI boundary to inject server arguments when needed, without mutating sys.argv deep in the source loadin...
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-cli-cli.mdx
main
model-context-protocol-fastmcp
[ -0.07006943970918655, 0.026650816202163696, 0.00960338395088911, 0.0019182640826329589, 0.02150384895503521, -0.13122214376926422, 0.03025406412780285, 0.003588353516533971, -0.006740065291523933, -0.051619578152894974, 0.02453148178756237, -0.03059735894203186, 0.05184047296643257, 0.0066...
-0.006999
# `fastmcp.server.providers.openapi.components` OpenAPI component classes: Tool, Resource, and ResourceTemplate. ## Classes ### `OpenAPITool` Tool implementation for OpenAPI endpoints. \*\*Methods:\*\* #### `run` ```python run(self, arguments: dict[str, Any]) -> ToolResult ``` Execute the HTTP request using RequestDire...
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-server-providers-openapi-components.mdx
main
model-context-protocol-fastmcp
[ -0.03271576762199402, 0.08096392452716827, -0.02607007510960102, 0.043991949409246445, -0.030142823234200478, -0.1332458257675171, -0.03923552855849266, -0.01722794584929943, 0.015297798439860344, -0.04229635000228882, 0.018580764532089233, -0.07250349223613739, 0.026082338765263557, -0.02...
0.04957
# `fastmcp.utilities.openapi.schemas` Schema manipulation utilities for OpenAPI operations. ## Functions ### `clean\_schema\_for\_display` ```python clean\_schema\_for\_display(schema: JsonSchema | None) -> JsonSchema | None ``` Clean up a schema dictionary for display by removing internal/complex fields. ### `extract\...
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-utilities-openapi-schemas.mdx
main
model-context-protocol-fastmcp
[ -0.031753331422805786, 0.07332364469766617, 0.012309664860367775, 0.033459220081567764, 0.04513262212276459, -0.09374570846557617, -0.04795362055301666, -0.03270608186721802, -0.018788183107972145, -0.05862325802445412, 0.0884438082575798, -0.0800706148147583, 0.0180972833186388, 0.0276378...
0.053619
# `fastmcp.server.middleware.timing` Timing middleware for measuring and logging request performance. ## Classes ### `TimingMiddleware` Middleware that logs the execution time of requests. Only measures and logs timing for request messages (not notifications). Provides insights into performance characteristics of your ...
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-server-middleware-timing.mdx
main
model-context-protocol-fastmcp
[ -0.039658140391111374, -0.010981366969645023, 0.0334046296775341, -0.0017275519203394651, 0.04916815459728241, -0.14713308215141296, -0.014256126247346401, 0.026747848838567734, 0.015517603605985641, 0.006067162845283747, -0.04736161231994629, -0.02402975782752037, -0.004302209708839655, -...
0.166764
# `fastmcp.utilities.pagination` Pagination utilities for MCP list operations. ## Functions ### `paginate\_sequence` ```python paginate\_sequence(items: Sequence[T], cursor: str | None, page\_size: int) -> tuple[list[T], str | None] ``` Paginate a sequence of items. \*\*Args:\*\* - `items`: The full sequence to paginat...
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-utilities-pagination.mdx
main
model-context-protocol-fastmcp
[ -0.14891210198402405, -0.015880949795246124, 0.056257762014865875, -0.03240933269262314, -0.03245760127902031, -0.029470710083842278, -0.006861815229058266, -0.08078087121248245, -0.042955465614795685, 0.009542643092572689, 0.06056299805641174, 0.03157227486371994, 0.07315359264612198, -0....
0.063654
# `fastmcp.server.auth.providers.supabase` Supabase authentication provider for FastMCP. This module provides SupabaseProvider - a complete authentication solution that integrates with Supabase Auth's JWT verification, supporting Dynamic Client Registration (DCR) for seamless MCP client authentication. ## Classes ### `...
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-server-auth-providers-supabase.mdx
main
model-context-protocol-fastmcp
[ -0.12754923105239868, -0.0004072090669069439, 0.029919663444161415, -0.026403699070215225, 0.03914861008524895, -0.026770124211907387, -0.050824325531721115, 0.013964670710265636, -0.010172132402658463, -0.07239040732383728, 0.03310130909085274, -0.02263682894408703, 0.1028301939368248, -0...
0.007621
# `fastmcp.mcp\_config` Canonical MCP Configuration Format. This module defines the standard configuration format for Model Context Protocol (MCP) servers. It provides a client-agnostic, extensible format that can be used across all MCP implementations. The configuration format supports both stdio and remote (HTTP/SSE)...
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-mcp_config.mdx
main
model-context-protocol-fastmcp
[ -0.04421393945813179, -0.0263544749468565, -0.004535968415439129, 0.0031242661643773317, -0.009016330353915691, -0.0689307451248169, -0.024662423878908157, 0.038585029542446136, -0.019906580448150635, -0.02090677060186863, 0.024202721193432808, -0.0035628180485218763, 0.05164121836423874, ...
0.085065
# `fastmcp.tools.tool` ## Functions ### `default\_serializer` ```python default\_serializer(data: Any) -> str ``` ## Classes ### `ToolResult` \*\*Methods:\*\* #### `to\_mcp\_result` ```python to\_mcp\_result(self) -> list[ContentBlock] | tuple[list[ContentBlock], dict[str, Any]] | CallToolResult ``` ### `Tool` Internal...
https://github.com/jlowin/fastmcp/blob/main//docs/python-sdk/fastmcp-tools-tool.mdx
main
model-context-protocol-fastmcp
[ -0.06369619071483612, 0.007992016151547432, -0.02709280326962471, 0.0015237698098644614, -0.06428160518407822, -0.06584819406270981, -0.0005270508700050414, 0.044484250247478485, -0.07010341435670853, -0.047156695276498795, 0.0721074789762497, -0.06094028055667877, 0.017514079809188843, -0...
0.016939
import { VersionBadge } from "/snippets/version-badge.mdx" FastMCP provides a command-line interface (CLI) that makes it easy to run, develop, and install your MCP servers. The CLI is automatically installed when you install FastMCP. ```bash fastmcp --help ``` ## Commands Overview | Command | Purpose | Dependency Manag...
https://github.com/jlowin/fastmcp/blob/main//docs/patterns/cli.mdx
main
model-context-protocol-fastmcp
[ -0.057269129902124405, -0.03385637700557709, 0.041877489537000656, -0.06089083477854729, 0.04859178140759468, -0.023083647713065147, -0.031156964600086212, -0.005984670482575893, -0.05446551367640495, 0.013715695589780807, 0.06743600964546204, -0.03053947165608406, 0.017604384571313858, -0...
0.058656
for SSE servers. 2. \*\*Python files\*\* — `.py` files are run via `fastmcp run` automatically. 3. \*\*MCPConfig JSON\*\* — `.json` files with an `mcpServers` key are treated as multi-server configs. 4. \*\*Stdio commands\*\* — Use `--command` to connect to any MCP server via stdio (e.g. `npx`, `uvx`). ### Examples ```...
https://github.com/jlowin/fastmcp/blob/main//docs/patterns/cli.mdx
main
model-context-protocol-fastmcp
[ -0.046116720885038376, -0.04615490883588791, -0.058542538434267044, 0.03364939242601395, -0.029550662264227867, -0.0418027825653553, -0.04270339384675026, 0.0629814937710762, -0.010810330510139465, -0.005504522006958723, 0.019190674647688866, 0.011869661509990692, 0.044557299464941025, 0.0...
0.054284
| ---- | ----------- | | Transport | `--transport`, `-t` | Transport protocol to use (`stdio`, `http`, or `sse`) | | Host | `--host` | Host to bind to when using http transport (default: 127.0.0.1) | | Port | `--port`, `-p` | Port to bind to when using http transport (default: 8000) | | Path | `--path` | Path to bind t...
https://github.com/jlowin/fastmcp/blob/main//docs/patterns/cli.mdx
main
model-context-protocol-fastmcp
[ 0.020687784999608994, -0.04226885363459587, -0.08337271958589554, 0.009643230587244034, -0.03734521567821503, -0.048962533473968506, -0.01909753307700157, 0.0815686285495758, -0.008023182861506939, 0.005302670411765575, 0.017965354025363922, -0.025907324627041817, 0.0319606214761734, 0.050...
0.113425
fastmcp run server.py:my\_server ``` #### Factory Function Since `fastmcp run` ignores the `if \_\_name\_\_ == "\_\_main\_\_"` block, you can use a factory function to run setup code before your server starts. Factory functions are called without any arguments and must return a FastMCP server instance. Both sync and as...
https://github.com/jlowin/fastmcp/blob/main//docs/patterns/cli.mdx
main
model-context-protocol-fastmcp
[ -0.09810826927423477, -0.06146107241511345, -0.05318894237279892, 0.018566584214568138, -0.02246902883052826, -0.06809785962104797, -0.06318792700767517, -0.0016042260685935616, -0.04393739998340607, -0.043204616755247116, 0.09896795451641083, 0.033322524279356, 0.03947099670767784, -0.068...
0.000543
command does not support HTTP testing. To test a server over Streamable HTTP or SSE: 1. Start your server manually with the appropriate transport using either the command line: ```bash fastmcp run server.py --transport http ``` or by setting the transport in your code: ```bash python server.py # Assuming your \_\_main\...
https://github.com/jlowin/fastmcp/blob/main//docs/patterns/cli.mdx
main
model-context-protocol-fastmcp
[ -0.0647318884730339, -0.013397146947681904, -0.028403662145137787, 0.0025380190927535295, -0.009170575067400932, -0.11191610246896744, -0.1133570596575737, 0.011053009890019894, -0.02605813555419445, -0.006733181420713663, 0.03715692088007927, -0.024140680208802223, 0.014652734622359276, 0...
-0.073843
Note that for security reasons, MCP clients usually run every server in a completely isolated environment. Therefore, all dependencies must be explicitly specified using the `--with` and/or `--with-editable` options (following `uv` conventions) or by attaching them to your server in code via the `dependencies` paramete...
https://github.com/jlowin/fastmcp/blob/main//docs/patterns/cli.mdx
main
model-context-protocol-fastmcp
[ -0.057039063423871994, -0.021068336442112923, 0.032592371106147766, -0.08245136588811874, 0.007042263634502888, -0.03427135571837425, -0.060979753732681274, 0.05146503821015358, -0.07623607665300369, -0.015120293945074081, 0.03980302810668945, -0.08319961279630661, 0.03508494421839714, 0.0...
-0.059843
server.py --env API\_KEY=secret --env DEBUG=true # Install with environment file fastmcp install cursor server.py --env-file .env # Install in Goose (uses uvx deeplink) fastmcp install goose server.py --with pandas # Install with specific Python version fastmcp install claude-desktop server.py --python 3.11 # Install w...
https://github.com/jlowin/fastmcp/blob/main//docs/patterns/cli.mdx
main
model-context-protocol-fastmcp
[ -0.08413678407669067, -0.049633923918008804, -0.03558632358908653, -0.05443092808127403, -0.02482803910970688, -0.08957330882549286, -0.08289306610822678, 0.03535164147615433, -0.05092339962720871, -0.014838336035609245, 0.1025552749633789, -0.01163523644208908, -0.01676873117685318, -0.03...
-0.08548
| Save JSON report to file instead of stdout. Requires `--format` | ### Output Formats #### FastMCP Format (`--format fastmcp`) The default and most comprehensive format, includes all FastMCP-specific metadata: - Server name, instructions, and version - FastMCP version and MCP version - Tool tags and enabled status - O...
https://github.com/jlowin/fastmcp/blob/main//docs/patterns/cli.mdx
main
model-context-protocol-fastmcp
[ -0.009147684089839458, 0.054795898497104645, -0.023418232798576355, 0.019968125969171524, 0.04042384773492813, 0.010975299403071404, -0.05335099995136261, 0.027528125792741776, -0.04169877618551254, -0.020683301612734795, 0.06999306380748749, -0.058831263333559036, 0.029081398621201515, -0...
0.006817
components. ```bash fastmcp version ``` ### Options | Option | Flag | Description | | ------ | ---- | ----------- | | Copy to Clipboard | `--copy` | Copy version information to clipboard |
https://github.com/jlowin/fastmcp/blob/main//docs/patterns/cli.mdx
main
model-context-protocol-fastmcp
[ 0.04353807494044304, -0.0066308071836829185, -0.008959501050412655, -0.04060051217675209, 0.08151748031377792, 0.023548834025859833, 0.01978323422372341, -0.00899937842041254, 0.012234576046466827, -0.0684763714671135, 0.09359254688024521, -0.02743571437895298, -0.04203445836901665, -0.029...
-0.096725
The best way to ensure a reliable and maintainable FastMCP Server is to test it! The FastMCP Client combined with Pytest provides a simple and powerful way to test your FastMCP servers. ## Prerequisites Testing FastMCP servers requires `pytest-asyncio` to handle async test functions and fixtures. Install it as a develo...
https://github.com/jlowin/fastmcp/blob/main//docs/patterns/testing.mdx
main
model-context-protocol-fastmcp
[ -0.06036306917667389, 0.002273860154673457, 0.022936100140213966, 0.06392118334770203, -0.028451908379793167, -0.10525081306695938, -0.08066757023334503, 0.0013872297713533044, -0.034630004316568375, -0.060996443033218384, 0.03288336098194122, -0.017358725890517235, 0.021417435258626938, 0...
-0.058017
import { VersionBadge } from "/snippets/version-badge.mdx" FastMCP includes a `contrib` package that holds community-contributed modules. These modules extend FastMCP's functionality but aren't officially maintained by the core team. Contrib modules provide additional features, integrations, or patterns that complement...
https://github.com/jlowin/fastmcp/blob/main//docs/patterns/contrib.mdx
main
model-context-protocol-fastmcp
[ -0.10464499890804291, -0.026192743331193924, -0.006444904953241348, -0.03171877935528755, 0.0769624412059784, -0.02527458593249321, -0.029542136937379837, -0.0014241962926462293, -0.06893099099397659, -0.11075769364833832, 0.07228904962539673, -0.006210338324308395, 0.03396931663155556, -0...
0.049772
import { VersionBadge } from "/snippets/version-badge.mdx" Good tests are the foundation of reliable software. In FastMCP, we treat tests as first-class documentation that demonstrates how features work while protecting against regressions. Every new capability needs comprehensive tests that demonstrate correctness. ##...
https://github.com/jlowin/fastmcp/blob/main//docs/development/tests.mdx
main
model-context-protocol-fastmcp
[ -0.03759452700614929, 0.026847021654248238, 0.03203975409269333, -0.005608680658042431, 0.052800990641117096, -0.08500175923109055, -0.031455740332603455, 0.021472690626978874, -0.046380527317523956, -0.006792730651795864, 0.055120643228292465, 0.03667089343070984, 0.045869749039411545, 0....
-0.012811
test\_setup\_server(): """Setup for other tests.""" global test\_server test\_server = FastMCP("shared-server") def test\_server\_works(): """Test server functionality.""" # Depends on test\_setup\_server running first assert test\_server is not None ``` #### Clear Intent Test names and assertions should make the verif...
https://github.com/jlowin/fastmcp/blob/main//docs/development/tests.mdx
main
model-context-protocol-fastmcp
[ -0.1015302985906601, -0.01914246752858162, -0.03718133643269539, 0.06126740947365761, -0.026265908032655716, -0.06278336048126221, 0.007621889468282461, -0.06545277684926987, -0.029286867007613182, -0.02814970351755619, 0.09003610908985138, -0.04414059594273567, 0.09596667438745499, 0.0227...
-0.014541
test\_weather\_operations(): # Pass server directly - no deployment needed async with Client(server) as client: result = await client.call\_tool("get\_temperature", {"city": "NYC"}) assert result.data == {"city": "NYC", "temp": 72} ``` This pattern makes tests deterministic and fast - typically completing in millisecon...
https://github.com/jlowin/fastmcp/blob/main//docs/development/tests.mdx
main
model-context-protocol-fastmcp
[ -0.0482586994767189, -0.0052968282252550125, 0.02507450245320797, 0.13305532932281494, -0.08448008447885513, -0.1360350102186203, 0.0030875219963490963, -0.0707809329032898, -0.05400586500763893, 0.001970705110579729, 0.040973685681819916, -0.07984257489442825, 0.049956172704696655, -0.028...
-0.039924
This guide covers breaking changes and migration steps when upgrading FastMCP. ## v3.0.0 Most servers need only one change: update your import from `from mcp.server.fastmcp import FastMCP` to `from fastmcp import FastMCP`. The sections below cover less common breaking changes. ### Breaking Changes #### WSTransport Remo...
https://github.com/jlowin/fastmcp/blob/main//docs/development/upgrade-guide.mdx
main
model-context-protocol-fastmcp
[ -0.040800128132104874, -0.041896600276231766, 0.016588857397437096, 0.0065564741380512714, 0.061291519552469254, -0.05188151076436043, -0.07646752893924713, -0.029588403180241585, -0.0755646750330925, -0.010162364691495895, 0.07176677882671356, 0.016182785853743553, 0.006081311497837305, -...
-0.083392
`from fastmcp.utilities.types import Image` - `FastMCP(dependencies=[...])` → use `fastmcp.json` configuration - `FastMCPProxy(client=...)` → use `client\_factory=lambda: ...` - `output\_schema=False` → use `output\_schema=None` ## v2.13.0 ### OAuth Token Key Management The OAuth proxy now issues its own JWT tokens. Fo...
https://github.com/jlowin/fastmcp/blob/main//docs/development/upgrade-guide.mdx
main
model-context-protocol-fastmcp
[ -0.07676469534635544, -0.023381970822811127, -0.006795345805585384, 0.01331749651581049, -0.005588003899902105, -0.10414633899927139, -0.032844092696905136, 0.030523503199219704, 0.0036055357195436954, -0.05105180665850639, 0.06157767027616501, 0.016390301287174225, 0.09677038341760635, -0...
-0.07425
Contributing to FastMCP means joining a community that values clean, maintainable code and thoughtful API design. All contributions are valued - from fixing typos in documentation to implementing major features. ## Design Principles Every contribution should advance these principles: - 🚀 \*\*Fast\*\* — High-level inte...
https://github.com/jlowin/fastmcp/blob/main//docs/development/contributing.mdx
main
model-context-protocol-fastmcp
[ -0.1190856322646141, 0.03968435153365135, 0.030032556504011154, 0.004871726967394352, 0.01589474454522133, -0.027573004364967346, -0.046516839414834976, 0.00139286566991359, -0.06010732799768448, -0.01446058601140976, 0.05468204990029335, -0.037123631685972214, 0.05158219113945961, -0.0196...
0.094874
that changes 50 lines across 3 files can be thoroughly reviewed in minutes. A PR that changes 500 lines across 20 files requires hours of careful analysis and often hides subtle issues. Breaking large features into smaller PRs: - Creates better review experiences - Makes git history clear - Simplifies debugging with bi...
https://github.com/jlowin/fastmcp/blob/main//docs/development/contributing.mdx
main
model-context-protocol-fastmcp
[ -0.13932546973228455, 0.054103683680295944, -0.006729314103722572, 0.003690891433507204, 0.035001277923583984, -0.08400635421276093, 0.003241469617933035, 0.049557775259017944, 0.052338745445013046, 0.06235266849398613, 0.07369917631149292, 0.03549724072217941, 0.04259723052382469, -0.0810...
0.036132
``` ### Submitting Your PR #### Before Submitting 1. \*\*Run all checks\*\*: `uv run prek run --all-files && uv run pytest` 2. \*\*Keep scope small\*\*: One feature or fix per PR 3. \*\*Write clear description\*\*: Your PR description becomes permanent documentation 4. \*\*Update docs\*\*: Include documentation for API...
https://github.com/jlowin/fastmcp/blob/main//docs/development/contributing.mdx
main
model-context-protocol-fastmcp
[ -0.09490016102790833, 0.06082504242658615, 0.016180317848920822, -0.04202813655138016, 0.08846713602542877, -0.014120224863290787, 0.020793462172150612, 0.08049025386571884, -0.05893637239933014, 0.06267857551574707, 0.07932308316230774, -0.05062129348516464, 0.028636159375309944, 0.009618...
0.006808
FastMCP releases frequently to deliver features quickly in the rapidly evolving MCP ecosystem. We use semantic versioning pragmatically - the Model Context Protocol is young, patterns are still emerging, and waiting for perfect stability would mean missing opportunities to empower developers with better tools. ## Versi...
https://github.com/jlowin/fastmcp/blob/main//docs/development/releases.mdx
main
model-context-protocol-fastmcp
[ -0.04021451622247696, 0.04065835475921631, 0.11236821115016937, -0.038588155061006546, 0.12127432227134705, -0.03917226940393448, -0.10266092419624329, -0.06161292642354965, -0.04866621643304825, -0.0011659970041364431, 0.04268447682261467, -0.029230307787656784, -0.03737775981426239, -0.0...
0.041447
fixes This approach means you get improvements as soon as they're ready rather than waiting for arbitrary release dates.
https://github.com/jlowin/fastmcp/blob/main//docs/development/releases.mdx
main
model-context-protocol-fastmcp
[ -0.02922416292130947, -0.015252199023962021, 0.11128921061754227, -0.01964293234050274, 0.04883607104420662, -0.012222988530993462, -0.11393625289201736, -0.0347290001809597, -0.034256577491760254, 0.04475676268339157, 0.06258974969387054, 0.09474637359380722, -0.08527372032403946, 0.00489...
0.011417
This document tracks major features in FastMCP v3.0 for release notes preparation. ## 3.0.0beta2 ### CLI: `fastmcp list` and `fastmcp call` New client-side CLI commands for querying and invoking tools on any MCP server — remote URLs, local Python files, MCPConfig JSON, or arbitrary stdio commands. Especially useful for...
https://github.com/jlowin/fastmcp/blob/main//docs/development/v3-notes/v3-features.mdx
main
model-context-protocol-fastmcp
[ -0.08734093606472015, -0.02047581598162651, -0.006310105323791504, 0.0016072336584329605, -0.035409409552812576, -0.06289372593164444, -0.024379946291446686, 0.02077271230518818, 0.005985996685922146, 0.008660257793962955, 0.05685843899846077, 0.006638749968260527, 0.012018590234220028, -0...
0.060745
True} ``` The `ui=` parameter accepts either a typed model (`ToolUI`, `ResourceUI`) or a raw dict for forward compatibility. It merges into `meta["ui"]` — alongside any other metadata you set. \*\*`ui://` resources\*\* automatically get the correct MIME type (`text/html;profile=mcp-app`) unless you override it explicit...
https://github.com/jlowin/fastmcp/blob/main//docs/development/v3-notes/v3-features.mdx
main
model-context-protocol-fastmcp
[ -0.06641998887062073, -0.019317729398608208, 0.006216596812009811, 0.05947834625840187, 0.008721075020730495, -0.09625399857759476, 0.02769092656672001, 0.055395860224962234, -0.026714855805039406, -0.028643248602747917, 0.037953827530145645, -0.03845912963151932, 0.06413623690605164, 0.07...
0.099113
to tools, resources, or templates based on configurable rules. ```python from fastmcp.server.providers.openapi import OpenAPIProvider import httpx client = httpx.AsyncClient(base\_url="https://api.example.com") provider = OpenAPIProvider(openapi\_spec=spec, client=client) mcp = FastMCP("API Server", providers=[provider...
https://github.com/jlowin/fastmcp/blob/main//docs/development/v3-notes/v3-features.mdx
main
model-context-protocol-fastmcp
[ -0.04904801771044731, -0.00027868218603543937, -0.03244135528802872, 0.031310271471738815, -0.03897561505436897, -0.09732088446617126, -0.05462693050503731, 0.04978887736797333, -0.043690040707588196, -0.020216677337884903, 0.03261216729879379, 0.005309319589287043, 0.03952448442578316, -0...
0.031332
as structured JSON. Both transforms: - Capture a provider reference at construction for deferred querying - Route through `FastMCP.read\_resource()` / `FastMCP.render\_prompt()` when the provider is FastMCP, ensuring middleware chains execute - Fall back to direct provider methods for plain providers - Return JSON for ...
https://github.com/jlowin/fastmcp/blob/main//docs/development/v3-notes/v3-features.mdx
main
model-context-protocol-fastmcp
[ -0.12967997789382935, 0.013071639463305473, -0.05214756354689598, 0.017339834943413734, -0.06956899911165237, -0.04891866445541382, 0.011158432811498642, 0.00840368214994669, 0.035186346620321274, -0.03855219855904579, -0.02253292314708233, -0.01565047726035118, 0.08643593639135361, -0.017...
0.073922
y + z # Only v2.0 is exposed to clients via list\_tools() # Calling "add" invokes the v2.0 implementation ``` \*\*Version comparison:\*\* - Uses PEP 440 semantic versioning (1.10 > 1.9 > 1.2) - Falls back to string comparison for non-PEP 440 versions (dates like `2025-01-15` work) - Unversioned components sort lower th...
https://github.com/jlowin/fastmcp/blob/main//docs/development/v3-notes/v3-features.mdx
main
model-context-protocol-fastmcp
[ 0.020327018573880196, 0.012525356374680996, 0.014453494921326637, 0.03520018234848976, 0.07498250901699066, -0.03158307820558548, -0.03940270096063614, 0.012423790991306305, -0.024849461391568184, -0.02553340420126915, 0.0425882488489151, 0.0165280532091856, -0.061431799083948135, -0.00119...
-0.022707
```python from fastmcp.server.tasks import TaskConfig @mcp.tool(task=TaskConfig(mode="required")) async def long\_running\_task(): # Must be executed as background task ... @mcp.tool(task=TaskConfig(mode="optional")) async def flexible\_task(): # Supports both sync and task execution ... @mcp.tool(task=True) # Shorthan...
https://github.com/jlowin/fastmcp/blob/main//docs/development/v3-notes/v3-features.mdx
main
model-context-protocol-fastmcp
[ -0.0995415598154068, 0.034862179309129715, -0.005069973412901163, 0.06770016998052597, 0.010879608802497387, -0.08668830245733261, -0.03511945903301239, -0.04469868168234825, -0.031488869339227676, -0.0012331168400123715, -0.00002032968041021377, -0.01840171404182911, 0.002269587479531765, ...
0.024523
([#2832](https://github.com/jlowin/fastmcp/pull/2832)) - \*\*Reload mode\*\*: `FileSystemProvider("mcp/", reload=True)` re-scans on every request for development - \*\*Package support\*\*: Directories with `\_\_init\_\_.py` support relative imports - \*\*Warning deduplication\*\*: Broken imports warn once per file modi...
https://github.com/jlowin/fastmcp/blob/main//docs/development/v3-notes/v3-features.mdx
main
model-context-protocol-fastmcp
[ -0.16953511536121368, -0.03991880267858505, 0.011055919341742992, 0.00664878124371171, 0.07345543056726456, -0.00981303583830595, 0.036309316754341125, 0.011831921525299549, -0.08447588235139847, 0.0010043145157396793, 0.08595509827136993, 0.014919768087565899, 0.011997588910162449, 0.0513...
0.131926
[Lifespan](/servers/lifespan) --- ### Tool Timeout Tools can limit foreground execution time with a `timeout` parameter ([#2872](https://github.com/jlowin/fastmcp/pull/2872)): ```python @mcp.tool(timeout=30.0) async def fetch\_data(url: str) -> dict: """Fetch with 30-second timeout.""" ... ``` When exceeded, clients re...
https://github.com/jlowin/fastmcp/blob/main//docs/development/v3-notes/v3-features.mdx
main
model-context-protocol-fastmcp
[ -0.0843372642993927, 0.05607251077890396, -0.008849064819514751, 0.04881735146045685, 0.00845555029809475, -0.09663853049278259, -0.087879978120327, -0.03581421822309494, 0.01602758653461933, -0.014320137910544872, 0.006331217009574175, 0.04492528736591339, 0.028004802763462067, -0.0730798...
0.070009
names: `get\_tool(name=...)`, `get\_resource(uri=...)`, etc. (was `key`) - Return types: `get\_tools()`, `get\_resources()`, etc. return lists instead of dicts ```python # v2.x tools = await server.get\_tools() tool = tools["my\_tool"] # v3.0 tools = await server.get\_tools() tool = next((t for t in tools if t.name == ...
https://github.com/jlowin/fastmcp/blob/main//docs/development/v3-notes/v3-features.mdx
main
model-context-protocol-fastmcp
[ -0.027212172746658325, 0.0035401282366365194, 0.05586518719792366, 0.03862609714269638, -0.019356712698936462, -0.09977370500564575, 0.09471245110034943, 0.055481918156147, -0.0050374181009829044, -0.0128182889893651, 0.007198094855993986, -0.08001790195703506, 0.07660441845655441, -0.0019...
0.007069
## Decision: Remove automatic environment variable loading from auth providers You can still use environment variables for configuration - you just read them yourself with `os.environ` instead of relying on FastMCP's automatic loading. \*\*Status:\*\* Implemented in v3.0.0 ### Background Auth providers in v2.x used `py...
https://github.com/jlowin/fastmcp/blob/main//docs/development/v3-notes/auth-provider-env-vars.mdx
main
model-context-protocol-fastmcp
[ -0.02417360059916973, 0.008111607283353806, -0.04044982045888901, -0.016030464321374893, 0.022069396451115608, -0.0365561842918396, -0.0028931647539138794, -0.018306346610188484, -0.028052369132637978, -0.030537201091647148, 0.07773210853338242, -0.018676085397601128, 0.08223579078912735, ...
-0.032763
\*\*[v2.14.5: Sealed Docket](https://github.com/jlowin/fastmcp/releases/tag/v2.14.5)\*\* Fixes a memory leak in the memory:// docket broker where cancelled tasks accumulated instead of being cleaned up. Bumps pydocket to ≥0.17.2. ## What's Changed ### Enhancements 🔧 \* Bump pydocket to 0.17.2 (memory leak fix) by [@ch...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.10787858814001083, 0.07766112685203552, 0.02003289759159088, -0.024147627875208855, 0.06429193913936615, -0.055238571017980576, -0.017863260582089424, 0.020723717287182808, -0.02511393278837204, 0.012232514098286629, 0.06775970757007599, 0.03560608997941017, -0.045204389840364456, 0.001...
0.033039
[v2.14.1...v2.14.2](https://github.com/jlowin/fastmcp/compare/v2.14.1...v2.14.2) \*\*[v2.14.1: 'Tis a Gift to Be Sample](https://github.com/jlowin/fastmcp/releases/tag/v2.14.1)\*\* FastMCP 2.14.1 introduces sampling with tools (SEP-1577), enabling servers to pass tools to `ctx.sample()` for agentic workflows where the ...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.12441586703062057, -0.008809421211481094, -0.015629392117261887, -0.008796488866209984, 0.047033924609422684, -0.08705607056617737, 0.016544993966817856, 0.01363404281437397, 0.004233083687722683, -0.02816302701830864, 0.0022924139630049467, -0.055250171571969986, 0.017755918204784393, ...
0.132523
by [@jlowin](https://github.com/jlowin) in [#2565](https://github.com/jlowin/fastmcp/pull/2565) \* Fix fastapi.cli package structure by [@jlowin](https://github.com/jlowin) in [#2570](https://github.com/jlowin/fastmcp/pull/2570) \* Correct OAuth error codes by [@jlowin](https://github.com/jlowin) in [#2578](https://git...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.14275169372558594, 0.07643387466669083, 0.02088105119764805, -0.09707893431186676, 0.014784863218665123, -0.05045200511813164, -0.021549759432673454, -0.034451451152563095, -0.03753623366355896, -0.058528315275907516, 0.05169273912906647, -0.0018730262527242303, 0.022689543664455414, -0...
-0.025707
DebugTokenVerifier for development by [@jlowin](https://github.com/jlowin) in [#2362](https://github.com/jlowin/fastmcp/pull/2362) \* Add Azure Government support via base\_authority parameter by [@jlowin](https://github.com/jlowin) in [#2385](https://github.com/jlowin/fastmcp/pull/2385) \* Add Supabase authentication ...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.10249333083629608, 0.0024320418015122414, -0.03334965929389, -0.021733786910772324, 0.02730013243854046, 0.058193981647491455, -0.009079858660697937, -0.02363578788936138, -0.05972139909863472, 0.08309747278690338, 0.043700262904167175, -0.01476095151156187, 0.06381310522556305, -0.0102...
0.023049
[v2.12.5...v2.13.0](https://github.com/jlowin/fastmcp/compare/v2.12.5...v2.13.0) \*\*[v2.12.5: Safety Pin](https://github.com/jlowin/fastmcp/releases/tag/v2.12.5)\*\* FastMCP 2.12.5 is a point release that pins the MCP SDK version below 1.17, which introduced a change affecting FastMCP users with auth providers mounted...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.0828409492969513, 0.031123176217079163, 0.04815588518977165, -0.05640903860330582, 0.07385198026895523, -0.029726574197411537, -0.0017292927950620651, -0.018511595204472542, 0.015429707244038582, -0.042321011424064636, 0.12118114531040192, 0.04228059574961662, 0.03691612556576729, -0.00...
-0.004235
[@jlowin](https://github.com/jlowin) in [#1916](https://github.com/jlowin/fastmcp/pull/1916) \* Fix route count logging in OpenAPI server by [@zzstoatzz](https://github.com/zzstoatzz) in [#1928](https://github.com/jlowin/fastmcp/pull/1928) ### Docs 📚 \* docs: make Gemini CLI integration discoverable by [@jackwotherspo...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.14474116265773773, -0.022331569343805313, -0.02425493858754635, -0.004461338743567467, -0.010903785936534405, -0.06309002637863159, -0.03000405617058277, 0.004742877557873726, -0.08020993322134018, -0.038910161703825, 0.028081417083740234, 0.0033133451361209154, -0.02301253192126751, -0...
0.190618
is a hotfix for a bug where the `streamable-http` transport was not recognized as a valid option in `fastmcp.json` configuration files, despite being supported by the CLI. This resulted in a parsing error when the CLI arguments were merged against the configuration spec. ## What's Changed ### Fixes 🐞 \* Fix streamable...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.09067972749471664, 0.00918659195303917, -0.017729759216308594, -0.04225766658782959, 0.06774713099002838, -0.04713674262166023, -0.019242819398641586, -0.021727826446294785, -0.05149226263165474, -0.05213816091418266, 0.06960868090391159, -0.007361145224422216, -0.0034377481788396835, 0...
-0.009322
powerful but underutilized due to limited client support. FastMCP now lets server authors define fallback handlers that generate sampling completions server-side when clients don't support the feature, encouraging adoption while maintaining compatibility. This release took longer than usual to ship, and for good reason...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.17021524906158447, 0.03521453216671944, 0.04048538580536842, 0.0008888291195034981, 0.037615254521369934, -0.036031484603881836, -0.043546345084905624, -0.023523658514022827, -0.010994005016982555, -0.04737298563122749, 0.02919667772948742, 0.08211448043584824, 0.0356089323759079, 0.007...
0.006915
inline snapshots by [@strawgate](https://github.com/strawgate) in [#1605](https://github.com/jlowin/fastmcp/pull/1605) \* Improve fastmcp.json environment configuration and project-based deployments by [@jlowin](https://github.com/jlowin) in [#1631](https://github.com/jlowin/fastmcp/pull/1631) \* fix: allow passing que...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.11560513079166412, 0.06840402632951736, 0.009578879922628403, -0.04113892465829849, 0.027131441980600357, -0.05300072953104973, -0.056774817407131195, 0.003210463561117649, -0.012698858976364136, -0.05060504004359245, 0.02809598483145237, -0.0182485468685627, 0.07229959219694138, -0.020...
-0.080131
server to handle rich links by [@zzstoatzz](https://github.com/zzstoatzz) in [#1556](https://github.com/jlowin/fastmcp/pull/1556) \* fix: enable triage bot for fork PRs using pull\_request\_target by [@jlowin](https://github.com/jlowin) in [#1557](https://github.com/jlowin/fastmcp/pull/1557) ## New Contributors \* [@th...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.13866175711154938, -0.040299784392118454, 0.01809125766158104, -0.018974686041474342, 0.04649131000041962, -0.03232448548078537, -0.01846752129495144, 0.010749065317213535, -0.05881192907691002, 0.02411501295864582, 0.060252897441387177, -0.01586848869919777, 0.028885936364531517, -0.01...
0.043358
and default\_factory by [@jlowin](https://github.com/jlowin) in [#1380](https://github.com/jlowin/fastmcp/pull/1380) ### Other Changes 🦾 \* Remove unused arg by [@jlowin](https://github.com/jlowin) in [#1382](https://github.com/jlowin/fastmcp/pull/1382) \* Add remote auth provider tests by [@jlowin](https://github.com...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.11428740620613098, -0.020652495324611664, -0.00905042514204979, -0.016795435920357704, 0.02273481711745262, 0.009278863668441772, -0.007824000902473927, -0.031937673687934875, -0.05863994359970093, -0.009062378667294979, 0.08547238260507584, 0.0324670635163784, -0.005891895852982998, -0...
0.078601
and `context.session\_id` by [@hopeful0](https://github.com/hopeful0) in [#1242](https://github.com/jlowin/fastmcp/pull/1242) \* Support creating tool argument descriptions from string annotations by [@jlowin](https://github.com/jlowin) in [#1255](https://github.com/jlowin/fastmcp/pull/1255) \* feat: Add Annotations su...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.11303110420703888, 0.09747616946697235, -0.024827659130096436, 0.005245630629360676, 0.05364903062582016, -0.0373108796775341, 0.048344001173973083, 0.041331518441438675, -0.039246685802936554, -0.056671664118766785, 0.01147971861064434, -0.06282835453748703, 0.021397579461336136, 0.031...
0.131123
and experimental openapi parser by [@jlowin](https://github.com/jlowin) in [#1259](https://github.com/jlowin/fastmcp/pull/1259) \* Small clean-up from MCP Tool Transform PR by [@strawgate](https://github.com/strawgate) in [#1267](https://github.com/jlowin/fastmcp/pull/1267) \* Add test for proxy tags visibility by [@jl...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.0962897390127182, 0.01013464666903019, 0.02167932502925396, 0.003940728958696127, 0.08784247189760208, -0.13560819625854492, -0.033397477120161057, -0.03513892740011215, -0.02374952845275402, -0.03192630410194397, 0.06170235201716423, -0.03127838298678398, 0.04339093714952469, -0.005747...
0.120597
Add mirrored component support for proxy servers by [@jlowin](https://github.com/jlowin) in [#1105](https://github.com/jlowin/fastmcp/pull/1105) ### Fixes 🐞 \* Fix OpenAPI deepObject style parameter encoding by [@jlowin](https://github.com/jlowin) in [#1122](https://github.com/jlowin/fastmcp/pull/1122) \* xfail when g...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.08621880412101746, 0.011319870129227638, 0.01825520023703575, -0.02847258560359478, -0.013670814223587513, -0.02377314493060112, -0.02357933297753334, -0.038781873881816864, -0.008242919109761715, -0.04528643190860748, 0.02675298973917961, -0.06087372079491615, 0.05306265875697136, 0.01...
0.040091
Proxy support advanced MCP features by [@hopeful0](https://github.com/hopeful0) in [#1022](https://github.com/jlowin/fastmcp/pull/1022) ### Enhancements 🔧 \* Re-add splash screen by [@jlowin](https://github.com/jlowin) in [#1027](https://github.com/jlowin/fastmcp/pull/1027) \* Reduce banner padding by [@jlowin](https:...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.095039963722229, 0.024496272206306458, 0.07085978239774704, -0.030745340511202812, 0.06295831501483917, -0.010158163495361805, -0.04115644469857216, -0.010453101247549057, -0.073875792324543, -0.015133989043533802, 0.02475663088262081, 0.039181385189294815, -0.006849206984043121, 0.0207...
0.044349
OpenAI docs by [@jlowin](https://github.com/jlowin) in [#1001](https://github.com/jlowin/fastmcp/pull/1001) \* Add CLI banner by [@jlowin](https://github.com/jlowin) in [#1005](https://github.com/jlowin/fastmcp/pull/1005) ### Examples & Contrib 💡 \* Component Manager by [@gorocode](https://github.com/gorocode) in [#97...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.06848007440567017, 0.0057597956620156765, -0.0485464446246624, -0.015324520878493786, 0.1050669252872467, -0.0010647085728123784, -0.03094157949090004, 0.017157835885882378, -0.025852007791399956, -0.027364201843738556, 0.06769336760044098, -0.004888634197413921, -0.009667916223406792, ...
0.124711
\* Add key to component by [@jlowin](https://github.com/jlowin) in [#869](https://github.com/jlowin/fastmcp/pull/869) \* Add session\_id property to Context for data sharing by [@jlowin](https://github.com/jlowin) in [#881](https://github.com/jlowin/fastmcp/pull/881) \* Fix CORS documentation example by [@jlowin](https...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.10692590475082397, 0.037478480488061905, -0.014962926506996155, -0.009277031756937504, 0.02742878906428814, 0.04172416403889656, 0.0231002364307642, 0.014728342182934284, 0.0016865658108144999, -0.02327846735715866, 0.04215158894658089, -0.050425320863723755, -0.005889135878533125, 0.02...
0.063638
### Tool Transformation The highlight of this release is first-class [\*\*Tool Transformation\*\*](/v2/patterns/tool-transformation), a new feature that lets you create enhanced variations of existing tools. You can now easily rename arguments, hide parameters, modify descriptions, and even wrap tools with custom valid...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.10732126235961914, 0.031306806951761246, -0.019731935113668442, 0.019099712371826172, 0.013737929053604603, 0.0074013601988554, -0.01608762890100479, -0.015822215005755424, -0.031114118173718452, -0.01982845552265644, 0.005187519825994968, -0.019044959917664528, 0.029039079323410988, -0...
0.037222
6 by [@dependabot](https://github.com/dependabot) in [#760](https://github.com/jlowin/fastmcp/pull/760) \* Add dependencies section to release by [@jlowin](https://github.com/jlowin) in [#761](https://github.com/jlowin/fastmcp/pull/761) \* Remove extra imports for MCPConfig by [@Maanas-Verma](https://github.com/Maanas-...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.13228552043437958, -0.054551124572753906, 0.007486721966415644, -0.02114156261086464, 0.055696506053209305, 0.03830204904079437, -0.04503051936626434, 0.038786157965660095, -0.06995930522680283, -0.0027541625313460827, 0.10008292645215988, 0.007646367885172367, -0.05209380015730858, 0.0...
0.097752
Fix : fix path error to CLI Documentation by [@yrangana](https://github.com/yrangana) in [#684](https://github.com/jlowin/fastmcp/pull/684) \* Update auth docs by [@jlowin](https://github.com/jlowin) in [#687](https://github.com/jlowin/fastmcp/pull/687) ### Other Changes 🦾 \* Remove deprecation notice by [@jlowin](htt...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.10491868108510971, 0.017508169636130333, 0.01873602904379368, -0.07471176236867905, 0.019337445497512817, -0.03866104036569595, -0.04348702356219292, -0.006899725180119276, -0.0030488085467368364, -0.024350326508283615, 0.08238343894481659, 0.013089912012219429, 0.031569309532642365, 0....
-0.027391
[@jlowin](https://github.com/jlowin) in [#539](https://github.com/jlowin/fastmcp/pull/539) \* Minor addition: add transport to stdio server in mcpconfig, with default by [@jlowin](https://github.com/jlowin) in [#555](https://github.com/jlowin/fastmcp/pull/555) \* Raise an error if a Client is created with no servers in...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.06496241688728333, -0.04181569442152977, -0.017209278419613838, 0.02760326862335205, 0.012875746004283428, 0.013937228359282017, -0.023149091750383377, 0.07703462988138199, -0.05410247668623924, -0.03247048333287239, 0.07597897201776505, -0.060217972844839096, 0.015871185809373856, 0.01...
0.056944
run tests on all PRs by [@jlowin](https://github.com/jlowin) in [#468](https://github.com/jlowin/fastmcp/pull/468) \* add null check by [@zzstoatzz](https://github.com/zzstoatzz) in [#473](https://github.com/jlowin/fastmcp/pull/473) \* strict typing for `server.py` by [@zzstoatzz](https://github.com/zzstoatzz) in [#476...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.1209043487906456, -0.0038949823938310146, -0.015294529497623444, -0.01210353709757328, 0.01689307764172554, -0.0693962350487709, -0.04791521653532982, 0.02256668359041214, -0.06448205560445786, -0.01597052626311779, 0.08359299600124359, 0.028654756024479866, 0.0227797944098711, 0.025557...
-0.038775
Docs 📚 \* Update transport docs by [@jlowin](https://github.com/jlowin) in [#377](https://github.com/jlowin/fastmcp/pull/377) \* Add llms.txt to docs by [@jlowin](https://github.com/jlowin) in [#384](https://github.com/jlowin/fastmcp/pull/384) \* Fixing various text typos by [@didier-durand](https://github.com/didier-...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.10181157290935516, 0.014945554547011852, 0.09334711730480194, 0.03256581723690033, 0.06572896242141724, -0.0004087685374543071, -0.026145247742533684, 0.0160068366676569, 0.018177034333348274, 0.021831074729561806, 0.09372472763061523, 0.056343015283346176, 0.04221343994140625, -0.02716...
0.066164
by [@sandipan1](https://github.com/sandipan1) in [#260](https://github.com/jlowin/fastmcp/pull/260) \* small typing fixes by [@zzstoatzz](https://github.com/zzstoatzz) in [#237](https://github.com/jlowin/fastmcp/pull/237) \* Expose configurable timeout for OpenAPI by [@jlowin](https://github.com/jlowin) in [#279](https...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.11268468201160431, 0.04036043956875801, -0.002565509406849742, 0.03249707818031311, 0.01494626235216856, -0.04762280359864235, -0.05973216891288757, 0.001385245006531477, -0.050651874393224716, -0.07519792020320892, 0.044198647141456604, 0.01663586124777794, -0.019447119906544685, -0.02...
0.135193
Docs 📚 \* Improve integration documentation by [@jlowin](https://github.com/jlowin) in [#184](https://github.com/jlowin/fastmcp/pull/184) \* Improve documentation by [@jlowin](https://github.com/jlowin) in [#185](https://github.com/jlowin/fastmcp/pull/185) ### Other Changes 🦾 \* Add transport kwargs for mcp.run() and...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.10933244228363037, 0.04529924318194389, 0.04151313379406929, -0.019235769286751747, 0.011485530063509941, -0.0012966325739398599, -0.04555317014455795, 0.033763449639081955, -0.0527479462325573, -0.04380500316619873, 0.06090056151151657, -0.019496429711580276, 0.02855817787349224, -0.03...
0.015673
Readme for v2 by [@jlowin](https://github.com/jlowin) in [#112](https://github.com/jlowin/fastmcp/pull/112) \* fix deprecation warnings by [@zzstoatzz](https://github.com/zzstoatzz) in [#113](https://github.com/jlowin/fastmcp/pull/113) \* Readme by [@jlowin](https://github.com/jlowin) in [#118](https://github.com/jlowi...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.11930809915065765, 0.005076486151665449, 0.026528405025601387, -0.02639550343155861, 0.08164041489362717, -0.005374368280172348, -0.025020912289619446, 0.047427255660295486, -0.07723146677017212, -0.02054373361170292, 0.0612272173166275, 0.043309200555086136, -0.014089311473071575, -0.0...
0.100309
README.md by [@jlowin](https://github.com/jlowin) in [#23](https://github.com/jlowin/fastmcp/pull/23) \* add rich handler and dotenv loading for settings by [@zzstoatzz](https://github.com/zzstoatzz) in [#22](https://github.com/jlowin/fastmcp/pull/22) \* print exception when server can't start by [@jlowin](https://gith...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/changelog.mdx
main
model-context-protocol-fastmcp
[ -0.06296097487211227, 0.0006221170187927783, -0.020311567932367325, -0.038386933505535126, 0.09423305094242096, -0.033575091511011124, -0.0522770881652832, 0.02878369763493538, -0.063612200319767, 0.03114272467792034, 0.023921726271510124, 0.060396790504455566, 0.051325853914022446, -0.036...
0.00286
Fixes a memory leak in the memory:// docket broker where cancelled tasks accumulated instead of being cleaned up. Bumps pydocket to ≥0.17.2. Fixes a fresh install bug where the packaging library was missing as a direct dependency, plus backports $ref dereferencing in tool schemas and a task capabilities location fix. S...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/updates.mdx
main
model-context-protocol-fastmcp
[ -0.06349092721939087, 0.04682011529803276, 0.04883274808526039, 0.01110737957060337, 0.05917517468333244, -0.11724424362182617, -0.08755683153867722, -0.022265832871198654, 0.013308464549481869, -0.021655285730957985, 0.06495235860347748, -0.02860405668616295, 0.005281701218336821, -0.0251...
-0.008143
designed library into the FastMCP ecosystem - it's both powerful and remarkably easy to use, including wrappers to add encryption, TTLs, caching, and more to backends ranging from Elasticsearch, Redis, DynamoDB, filesystem, in-memory, and more! 🔐 \*\*OAuth maturity\*\* brings months of production learnings into the fr...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/updates.mdx
main
model-context-protocol-fastmcp
[ -0.12548446655273438, 0.023825904354453087, 0.013620230369269848, -0.054962098598480225, 0.018564628437161446, -0.0873396024107933, -0.04133455827832222, 0.03649615868926048, 0.05818095803260803, -0.04179300367832184, -0.0030665381345897913, 0.06458241492509842, 0.07314571738243103, -0.014...
0.075573
simplicity while setting the foundation for future enterprise features. FastMCP 2.10 achieves full compliance with the 6/18/2025 MCP specification update, introducing powerful new communication patterns. 💬 \*\*Elicitation Support\*\* enables dynamic server-client communication and "human-in-the-loop" workflows, allowi...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/updates.mdx
main
model-context-protocol-fastmcp
[ -0.11358850449323654, -0.001830963185057044, 0.05572650209069252, -0.04574861004948616, 0.06841252744197845, -0.06795591115951538, -0.04530125856399536, 0.02262173220515251, -0.03746241331100464, 0.004704967141151428, 0.005514559336006641, -0.006035889033228159, -0.014869485050439835, -0.0...
0.258086
token support and seamless OAuth 2.1 integration. This release aligns with how major AI platforms are adopting MCP today, making it easier than ever to securely connect your tools to real-world AI models. Dive into the update and secure your stack with minimal friction. Your tests are bad and you should feel bad. Stop ...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/updates.mdx
main
model-context-protocol-fastmcp
[ -0.11824464797973633, -0.04038866609334946, 0.07724933326244354, 0.013186125084757805, 0.04586232453584671, -0.13701242208480835, -0.09731762111186981, -0.004600559361279011, -0.024219347164034843, -0.04632972925901413, -0.02588590607047081, 0.00692811980843544, 0.0419156439602375, -0.0415...
0.07381
import { VersionBadge } from '/snippets/version-badge.mdx' Tools are executable functions exposed by MCP servers. The FastMCP client provides methods to discover available tools and execute them with arguments. ## Discovering Tools Use `list\_tools()` to retrieve all tools available on the server: ```python async with ...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/clients/tools.mdx
main
model-context-protocol-fastmcp
[ -0.02778138779103756, 0.03980332985520363, 0.007991575635969639, -0.003237097291275859, 0.08683519810438156, -0.046372707933187485, 0.038826074451208115, -0.026529142633080482, -0.03259032964706421, -0.042859241366386414, 0.014927896670997143, -0.04322711378335953, 0.05903377756476402, -0....
-0.027484
servers. Standard MCP structured JSON data as sent by the server, available from all MCP servers that support structured outputs. Boolean indicating if the tool execution failed. ### Structured Data Access FastMCP's `.data` property provides fully hydrated Python objects, not just JSON dictionaries. This includes compl...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/clients/tools.mdx
main
model-context-protocol-fastmcp
[ -0.07057936489582062, 0.08449270576238632, 0.08542631566524506, 0.10064297914505005, 0.014578860253095627, -0.13692830502986908, -0.037733931094408035, -0.03448988124728203, -0.02828327752649784, -0.02436426281929016, -0.03855586796998978, -0.05256250873208046, 0.022299207746982574, 0.0122...
0.034153
import { VersionBadge } from "/snippets/version-badge.mdx" The [MCP task protocol](https://modelcontextprotocol.io/specification/2025-11-25/basic/utilities/tasks) lets you request operations to run asynchronously. This returns a Task object immediately, letting you track progress, cancel operations, or await results. S...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/clients/tasks.mdx
main
model-context-protocol-fastmcp
[ -0.0706988200545311, 0.018000883981585503, -0.009357085451483727, 0.048578083515167236, 0.024275781586766243, -0.048322223126888275, -0.034250400960445404, -0.042241521179676056, 0.04242859408259392, -0.004394654184579849, -0.008211477659642696, -0.0031435478013008833, 0.024247070774435997, ...
0.048405
import { VersionBadge } from "/snippets/version-badge.mdx"; ## What is Elicitation? Elicitation allows MCP servers to request structured input from users during tool execution. Instead of requiring all inputs upfront, servers can interactively ask users for information as needed - like prompting for missing parameters,...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/clients/elicitation.mdx
main
model-context-protocol-fastmcp
[ -0.12360445410013199, 0.006323091685771942, 0.05177493020892143, 0.005375824403017759, 0.039113275706768036, -0.08452828228473663, -0.04858303815126419, -0.020670855417847633, -0.05501870438456535, -0.053327564150094986, 0.04100293293595314, -0.0579458586871624, 0.07473186403512955, -0.019...
0.122394
implicitly accept the elicitation return response\_type(value=user\_response) client = Client( "my\_mcp\_server.py", elicitation\_handler=basic\_elicitation\_handler ) ```
https://github.com/jlowin/fastmcp/blob/main//docs/v2/clients/elicitation.mdx
main
model-context-protocol-fastmcp
[ -0.038985081017017365, 0.0008068743627518415, 0.023496141657233238, 0.027549345046281815, -0.043644409626722336, -0.07109367847442627, 0.078750379383564, 0.06985469162464142, -0.054322514683008194, -0.04798150807619095, 0.009672555141150951, -0.028838735073804855, 0.021179845556616783, 0.0...
0.040513
import { VersionBadge } from '/snippets/version-badge.mdx' Prompts are reusable message templates exposed by MCP servers. They can accept arguments to generate personalized message sequences for LLM interactions. ## Listing Prompts Use `list\_prompts()` to retrieve all available prompt templates: ```python async with c...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/clients/prompts.mdx
main
model-context-protocol-fastmcp
[ 0.009065348654985428, 0.05723034217953682, 0.0429316982626915, -0.01651790924370289, 0.0974326953291893, 0.003427989548072219, 0.03382899612188339, 0.021261924877762794, -0.021489977836608887, -0.03878438472747803, -0.027033062651753426, -0.04739144816994667, 0.0919378474354744, -0.0472330...
-0.018652
prompt\_result = await client.get\_prompt\_mcp("example\_prompt", {"arg": "value"}) # prompt\_result -> mcp.types.GetPromptResult ``` ## Multi-Server Clients When using multi-server clients, prompts are accessible without prefixing (unlike tools): ```python async with client: # Multi-server client # Prompts from any se...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/clients/prompts.mdx
main
model-context-protocol-fastmcp
[ 0.029299365356564522, -0.014269747771322727, 0.045546405017375946, 0.08260029554367065, -0.023021342232823372, -0.06455184519290924, 0.002654566429555416, 0.016283158212900162, -0.029789378866553307, -0.05035138502717018, -0.02297971211373806, -0.06747250258922577, 0.06937113404273987, -0....
-0.011318
import { VersionBadge } from "/snippets/version-badge.mdx"; MCP servers can request LLM completions from clients. The client handles these requests through a sampling handler callback. ## Sampling Handler Provide a `sampling\_handler` function when creating the client: ```python from fastmcp import Client from fastmcp....
https://github.com/jlowin/fastmcp/blob/main//docs/v2/clients/sampling.mdx
main
model-context-protocol-fastmcp
[ -0.03608262538909912, -0.0004385893407743424, 0.06243059039115906, 0.004378440789878368, 0.057615138590335846, -0.029727470129728317, 0.03519758954644203, -0.033605627715587616, 0.015459057874977589, -0.03892912343144417, 0.026509208604693413, -0.005261201411485672, 0.09895423799753189, -0...
-0.023015
AsyncAnthropic client = Client( "my\_mcp\_server.py", sampling\_handler=AnthropicSamplingHandler( default\_model="claude-sonnet-4-5", client=AsyncAnthropic(), # Uses ANTHROPIC\_API\_KEY env var ), ) ``` Install the Anthropic handler with `pip install fastmcp[anthropic]`. ### Tool Execution Tool execution happens on the...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/clients/sampling.mdx
main
model-context-protocol-fastmcp
[ -0.07497450709342957, -0.006943442393094301, -0.04648358002305031, 0.013544437475502491, -0.02665136009454727, -0.11450442671775818, -0.017787141725420952, 0.011232681572437286, -0.0032389836851507425, 0.005327265709638596, -0.02089075744152069, -0.007624408695846796, 0.035098880529403687, ...
0.010223
import { VersionBadge } from '/snippets/version-badge.mdx' MCP servers can report progress during long-running operations. The client can receive these updates through a progress handler. ## Progress Handler Set a progress handler when creating the client: ```python from fastmcp import Client async def my\_progress\_ha...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/clients/progress.mdx
main
model-context-protocol-fastmcp
[ -0.02731124311685562, 0.015581712126731873, 0.03020409867167473, 0.02730703167617321, -0.001445630332455039, -0.022768782451748848, 0.0031549527775496244, -0.04778926074504852, -0.007197252009063959, 0.00241045537404716, 0.027567679062485695, 0.0008787948754616082, 0.07099952548742294, -0....
-0.004798
import { VersionBadge } from '/snippets/version-badge.mdx' Roots are a way for clients to inform servers about the resources they have access to. Servers can use this information to adjust behavior or provide more relevant responses. ## Setting Static Roots Provide a list of roots when creating the client: ```python St...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/clients/roots.mdx
main
model-context-protocol-fastmcp
[ -0.05449683591723442, 0.012381883338093758, -0.011254377663135529, -0.0035335191059857607, -0.005474794190376997, -0.11108946800231934, -0.052231814712285995, 0.03460973501205444, 0.013792202807962894, -0.046243779361248016, 0.05896244943141937, 0.03359157219529152, 0.07435985654592514, -0...
-0.034837
import { VersionBadge } from '/snippets/version-badge.mdx' The central piece of MCP client applications is the `fastmcp.Client` class. This class provides a \*\*programmatic interface\*\* for interacting with any Model Context Protocol (MCP) server, handling protocol details and connection management automatically. The...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/clients/client.mdx
main
model-context-protocol-fastmcp
[ -0.07525113224983215, -0.0031539476476609707, -0.01374172791838646, -0.038518548011779785, -0.012773801572620869, -0.08323594182729721, 0.01815524324774742, -0.009619936347007751, -0.056432127952575684, -0.012036974541842937, 0.016303308308124542, 0.002876407466828823, 0.09417416900396347, ...
0.120423
within the same session tools = await client.list\_tools() result = await client.call\_tool("greet", {"name": "World"}) # Connection closed automatically here print(f"Connected: {client.is\_connected()}") ``` ## Operations FastMCP clients can interact with several types of server components: ### Tools Tools are server-...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/clients/client.mdx
main
model-context-protocol-fastmcp
[ -0.08401640504598618, 0.058120738714933395, -0.08634856343269348, 0.10241489112377167, -0.07138612866401672, -0.06600409001111984, 0.020057711750268936, 0.030647721141576767, 0.034594710916280746, -0.016494158655405045, 0.020252354443073273, -0.029788155108690262, 0.01279238611459732, -0.0...
0.009177
for each operation type: ### Core Operations - \*\*[Tools](/v2/clients/tools)\*\* - Execute server-side functions and handle results - \*\*[Resources](/v2/clients/resources)\*\* - Access static and templated resources - \*\*[Prompts](/v2/clients/prompts)\*\* - Work with message templates and argument serialization ### ...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/clients/client.mdx
main
model-context-protocol-fastmcp
[ 0.006796160712838173, 0.03949509188532829, -0.031936418265104294, 0.01145923975855112, -0.017317334190011024, -0.08372645080089569, -0.0026784336660057306, 0.03973233327269554, -0.008123926818370819, 0.04115058854222298, -0.039988402277231216, -0.048620954155921936, 0.02080283686518669, -0...
0.12377
import { VersionBadge } from "/snippets/version-badge.mdx"; MCP clients can receive various types of messages from servers, including requests that need responses and notifications that don't. The message handler provides a unified way to process all these messages. ## Function-Based Handler The simplest way to handle ...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/clients/messages.mdx
main
model-context-protocol-fastmcp
[ -0.04207969084382057, 0.02057095430791378, 0.09733711928129196, 0.04457198455929756, 0.06872061640024185, -0.0685211643576622, 0.061888232827186584, -0.04836220666766167, -0.0026389819104224443, -0.0013452856801450253, 0.02879742719233036, -0.007113348226994276, 0.0768679529428482, -0.0341...
0.046201
import { VersionBadge } from '/snippets/version-badge.mdx' MCP servers can emit log messages to clients. The client can handle these logs through a log handler callback. ## Log Handler Provide a `log\_handler` function when creating the client. For robust logging, the log messages can be integrated with Python's standa...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/clients/logging.mdx
main
model-context-protocol-fastmcp
[ -0.0014001622330397367, 0.02225559763610363, 0.05472299084067345, 0.005002120975404978, 0.04734915494918823, -0.05301202833652496, 0.04309869930148125, -0.006466091610491276, -0.021976156160235405, -0.002465423196554184, 0.0077399746514856815, -0.03804272413253784, 0.11288804560899734, -0....
0.014329
import { VersionBadge } from '/snippets/version-badge.mdx' Resources are data sources exposed by MCP servers. They can be static files or dynamic templates that generate content based on parameters. ## Types of Resources MCP servers expose two types of resources: - \*\*Static Resources\*\*: Fixed content accessible via...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/clients/resources.mdx
main
model-context-protocol-fastmcp
[ -0.04703463613986969, 0.033466875553131104, 0.023792492225766182, 0.047547370195388794, 0.09169355779886246, -0.026946263387799263, 0.005902990233153105, -0.02678745612502098, -0.04803798720240593, -0.021649207919836044, -0.045056600123643875, 0.006681161466985941, 0.09771998971700668, -0....
0.030937
templates\_result = await client.list\_resource\_templates\_mcp() # templates\_result -> mcp.types.ListResourceTemplatesResult content\_result = await client.read\_resource\_mcp("resource://example") # content\_result -> mcp.types.ReadResourceResult ``` ## Common Resource URI Patterns Different MCP servers may use vari...
https://github.com/jlowin/fastmcp/blob/main//docs/v2/clients/resources.mdx
main
model-context-protocol-fastmcp
[ -0.04916013404726982, 0.03454173728823662, 0.02154405601322651, 0.033395737409591675, 0.0007837263983674347, -0.004137298092246056, -0.0030608195811510086, 0.050696372985839844, -0.029639504849910736, -0.023154648020863533, -0.06825820356607437, 0.01160755380988121, -0.009899910539388657, ...
0.081419