fastmcp 2.7.1__tar.gz → 2.8.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (240) hide show
  1. fastmcp-2.8.1/.github/dependabot.yml +20 -0
  2. {fastmcp-2.7.1 → fastmcp-2.8.1}/.github/release.yml +10 -0
  3. {fastmcp-2.7.1 → fastmcp-2.8.1}/.github/workflows/publish.yml +1 -1
  4. {fastmcp-2.7.1 → fastmcp-2.8.1}/.github/workflows/run-static.yml +1 -1
  5. {fastmcp-2.7.1 → fastmcp-2.8.1}/.github/workflows/run-tests.yml +1 -1
  6. {fastmcp-2.7.1 → fastmcp-2.8.1}/PKG-INFO +48 -26
  7. {fastmcp-2.7.1 → fastmcp-2.8.1}/README.md +46 -24
  8. fastmcp-2.8.1/docs/assets/images/tutorial-rest-api-result.png +0 -0
  9. fastmcp-2.8.1/docs/assets/updates/release-2-7.png +0 -0
  10. fastmcp-2.8.1/docs/changelog.mdx +1129 -0
  11. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/clients/auth/bearer.mdx +6 -3
  12. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/clients/auth/oauth.mdx +3 -3
  13. fastmcp-2.8.1/docs/community/README.md +22 -0
  14. fastmcp-2.8.1/docs/community/showcase.mdx +59 -0
  15. fastmcp-2.8.1/docs/docs.json +177 -0
  16. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/getting-started/installation.mdx +1 -1
  17. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/getting-started/welcome.mdx +15 -7
  18. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/integrations/anthropic.mdx +8 -11
  19. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/integrations/claude-desktop.mdx +1 -1
  20. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/integrations/gemini.mdx +2 -2
  21. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/integrations/openai.mdx +3 -4
  22. fastmcp-2.8.1/docs/patterns/tool-transformation.mdx +454 -0
  23. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/servers/composition.mdx +1 -1
  24. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/servers/fastmcp.mdx +101 -15
  25. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/servers/openapi.mdx +95 -40
  26. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/servers/prompts.mdx +27 -0
  27. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/servers/resources.mdx +27 -0
  28. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/servers/tools.mdx +53 -18
  29. fastmcp-2.8.1/docs/snippets/youtube-embed.mdx +12 -0
  30. fastmcp-2.8.1/docs/tutorials/create-mcp-server.mdx +198 -0
  31. fastmcp-2.8.1/docs/tutorials/mcp.mdx +120 -0
  32. fastmcp-2.8.1/docs/tutorials/rest-api.mdx +203 -0
  33. fastmcp-2.8.1/docs/updates.mdx +171 -0
  34. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/screenshot.py +2 -1
  35. {fastmcp-2.7.1 → fastmcp-2.8.1}/justfile +4 -1
  36. {fastmcp-2.7.1 → fastmcp-2.8.1}/pyproject.toml +3 -1
  37. fastmcp-2.8.1/src/fastmcp/__init__.py +50 -0
  38. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/cli/cli.py +3 -2
  39. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/client/auth/oauth.py +1 -1
  40. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/client/client.py +6 -5
  41. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/client/sampling.py +5 -9
  42. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/client/transports.py +42 -33
  43. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/exceptions.py +4 -0
  44. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/prompts/prompt.py +11 -21
  45. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/prompts/prompt_manager.py +13 -9
  46. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/resources/resource.py +21 -26
  47. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/resources/resource_manager.py +15 -12
  48. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/resources/template.py +8 -16
  49. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/server/auth/providers/bearer_env.py +8 -11
  50. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/server/auth/providers/in_memory.py +2 -2
  51. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/server/context.py +12 -10
  52. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/server/openapi.py +87 -57
  53. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/server/proxy.py +29 -20
  54. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/server/server.py +422 -206
  55. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/settings.py +113 -37
  56. fastmcp-2.8.1/src/fastmcp/tools/__init__.py +5 -0
  57. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/tools/tool.py +125 -85
  58. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/tools/tool_manager.py +12 -11
  59. fastmcp-2.8.1/src/fastmcp/tools/tool_transform.py +669 -0
  60. fastmcp-2.8.1/src/fastmcp/utilities/components.py +55 -0
  61. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/utilities/exceptions.py +1 -1
  62. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/utilities/mcp_config.py +1 -1
  63. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/utilities/tests.py +3 -3
  64. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/utilities/types.py +82 -14
  65. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/auth/providers/test_bearer_env.py +33 -24
  66. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/client/test_client.py +10 -0
  67. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/client/test_openapi.py +11 -0
  68. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/client/test_streamable_http.py +9 -17
  69. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/contrib/test_bulk_tool_caller.py +1 -3
  70. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/deprecated/test_deprecated.py +23 -0
  71. fastmcp-2.8.1/tests/deprecated/test_settings.py +357 -0
  72. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/resources/test_resource_template.py +41 -0
  73. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/resources/test_resources.py +2 -8
  74. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/openapi/test_openapi.py +543 -113
  75. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/openapi/test_route_map_fn.py +11 -14
  76. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/test_auth_integration.py +3 -3
  77. fastmcp-2.8.1/tests/server/test_proxy.py +516 -0
  78. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/test_server.py +103 -0
  79. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/test_server_interactions.py +742 -15
  80. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/test_tool_exclude_args.py +2 -7
  81. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/tools/test_tool.py +52 -2
  82. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/tools/test_tool_manager.py +2 -1
  83. fastmcp-2.8.1/tests/tools/test_tool_transform.py +1021 -0
  84. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/utilities/test_tests.py +3 -3
  85. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/utilities/test_types.py +107 -0
  86. {fastmcp-2.7.1 → fastmcp-2.8.1}/uv.lock +150 -148
  87. fastmcp-2.7.1/docs/docs.json +0 -150
  88. fastmcp-2.7.1/docs/updates.mdx +0 -21
  89. fastmcp-2.7.1/src/fastmcp/__init__.py +0 -21
  90. fastmcp-2.7.1/src/fastmcp/tools/__init__.py +0 -4
  91. fastmcp-2.7.1/tests/server/test_proxy.py +0 -266
  92. {fastmcp-2.7.1 → fastmcp-2.8.1}/.cursor/rules/core-mcp-objects.mdc +0 -0
  93. {fastmcp-2.7.1 → fastmcp-2.8.1}/.github/ISSUE_TEMPLATE/bug.yml +0 -0
  94. {fastmcp-2.7.1 → fastmcp-2.8.1}/.github/ISSUE_TEMPLATE/config.yml +0 -0
  95. {fastmcp-2.7.1 → fastmcp-2.8.1}/.github/ISSUE_TEMPLATE/enhancement.yml +0 -0
  96. {fastmcp-2.7.1 → fastmcp-2.8.1}/.github/labeler.yml +0 -0
  97. {fastmcp-2.7.1 → fastmcp-2.8.1}/.github/workflows/labeler.yml +0 -0
  98. {fastmcp-2.7.1 → fastmcp-2.8.1}/.gitignore +0 -0
  99. {fastmcp-2.7.1 → fastmcp-2.8.1}/.pre-commit-config.yaml +0 -0
  100. {fastmcp-2.7.1 → fastmcp-2.8.1}/AGENTS.md +0 -0
  101. {fastmcp-2.7.1 → fastmcp-2.8.1}/LICENSE +0 -0
  102. {fastmcp-2.7.1 → fastmcp-2.8.1}/Windows_Notes.md +0 -0
  103. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/assets/demo-inspector.png +0 -0
  104. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/assets/favicon.ico +0 -0
  105. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/assets/logo.png +0 -0
  106. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/clients/advanced-features.mdx +0 -0
  107. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/clients/client.mdx +0 -0
  108. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/clients/transports.mdx +0 -0
  109. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/deployment/asgi.mdx +0 -0
  110. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/deployment/running-server.mdx +0 -0
  111. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/getting-started/quickstart.mdx +0 -0
  112. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/integrations/contrib.mdx +0 -0
  113. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/patterns/cli.mdx +0 -0
  114. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/patterns/decorating-methods.mdx +0 -0
  115. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/patterns/http-requests.mdx +0 -0
  116. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/patterns/testing.mdx +0 -0
  117. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/servers/auth/bearer.mdx +0 -0
  118. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/servers/context.mdx +0 -0
  119. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/servers/proxy.mdx +0 -0
  120. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/snippets/version-badge.mdx +0 -0
  121. {fastmcp-2.7.1 → fastmcp-2.8.1}/docs/style.css +0 -0
  122. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/complex_inputs.py +0 -0
  123. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/config_server.py +0 -0
  124. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/desktop.py +0 -0
  125. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/echo.py +0 -0
  126. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/in_memory_proxy_example.py +0 -0
  127. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/memory.py +0 -0
  128. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/mount_example.py +0 -0
  129. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/sampling.py +0 -0
  130. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/serializer.py +0 -0
  131. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/simple_echo.py +0 -0
  132. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/smart_home/README.md +0 -0
  133. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/smart_home/pyproject.toml +0 -0
  134. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/smart_home/src/smart_home/__init__.py +0 -0
  135. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/smart_home/src/smart_home/__main__.py +0 -0
  136. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/smart_home/src/smart_home/hub.py +0 -0
  137. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/smart_home/src/smart_home/lights/__init__.py +0 -0
  138. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/smart_home/src/smart_home/lights/hue_utils.py +0 -0
  139. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/smart_home/src/smart_home/lights/server.py +0 -0
  140. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/smart_home/src/smart_home/py.typed +0 -0
  141. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/smart_home/src/smart_home/settings.py +0 -0
  142. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/smart_home/uv.lock +0 -0
  143. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/tags_example.py +0 -0
  144. {fastmcp-2.7.1 → fastmcp-2.8.1}/examples/text_me.py +0 -0
  145. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/cli/__init__.py +0 -0
  146. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/cli/claude.py +0 -0
  147. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/cli/run.py +0 -0
  148. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/client/__init__.py +0 -0
  149. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/client/auth/__init__.py +0 -0
  150. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/client/auth/bearer.py +0 -0
  151. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/client/logging.py +0 -0
  152. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/client/oauth_callback.py +0 -0
  153. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/client/progress.py +0 -0
  154. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/client/roots.py +0 -0
  155. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/contrib/README.md +0 -0
  156. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/contrib/bulk_tool_caller/README.md +0 -0
  157. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/contrib/bulk_tool_caller/__init__.py +0 -0
  158. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/contrib/bulk_tool_caller/bulk_tool_caller.py +0 -0
  159. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/contrib/bulk_tool_caller/example.py +0 -0
  160. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/contrib/mcp_mixin/README.md +0 -0
  161. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/contrib/mcp_mixin/__init__.py +0 -0
  162. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/contrib/mcp_mixin/example.py +0 -0
  163. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/contrib/mcp_mixin/mcp_mixin.py +0 -0
  164. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/prompts/__init__.py +0 -0
  165. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/py.typed +0 -0
  166. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/resources/__init__.py +0 -0
  167. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/resources/types.py +0 -0
  168. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/server/__init__.py +0 -0
  169. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/server/auth/__init__.py +0 -0
  170. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/server/auth/auth.py +0 -0
  171. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/server/auth/providers/__init__.py +0 -0
  172. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/server/auth/providers/bearer.py +0 -0
  173. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/server/dependencies.py +0 -0
  174. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/server/http.py +0 -0
  175. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/utilities/__init__.py +0 -0
  176. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/utilities/cache.py +0 -0
  177. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/utilities/http.py +0 -0
  178. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/utilities/json_schema.py +0 -0
  179. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/utilities/logging.py +0 -0
  180. {fastmcp-2.7.1 → fastmcp-2.8.1}/src/fastmcp/utilities/openapi.py +0 -0
  181. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/__init__.py +0 -0
  182. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/auth/__init__.py +0 -0
  183. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/auth/providers/test_bearer.py +0 -0
  184. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/auth/test_oauth_client.py +0 -0
  185. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/cli/__init__.py +0 -0
  186. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/cli/test_cli.py +0 -0
  187. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/cli/test_run.py +0 -0
  188. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/client/__init__.py +0 -0
  189. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/client/test_logs.py +0 -0
  190. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/client/test_progress.py +0 -0
  191. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/client/test_roots.py +0 -0
  192. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/client/test_sampling.py +0 -0
  193. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/client/test_sse.py +0 -0
  194. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/client/test_stdio.py +0 -0
  195. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/conftest.py +0 -0
  196. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/contrib/__init__.py +0 -0
  197. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/contrib/test_mcp_mixin.py +0 -0
  198. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/deprecated/__init__.py +0 -0
  199. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/deprecated/test_mount_separators.py +0 -0
  200. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/deprecated/test_resource_prefixes.py +0 -0
  201. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/deprecated/test_route_type_ignore.py +0 -0
  202. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/prompts/__init__.py +0 -0
  203. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/prompts/test_prompt.py +0 -0
  204. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/prompts/test_prompt_manager.py +0 -0
  205. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/resources/__init__.py +0 -0
  206. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/resources/test_file_resources.py +0 -0
  207. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/resources/test_function_resources.py +0 -0
  208. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/resources/test_resource_manager.py +0 -0
  209. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/__init__.py +0 -0
  210. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/http/__init__.py +0 -0
  211. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/http/test_custom_routes.py +0 -0
  212. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/http/test_http_dependencies.py +0 -0
  213. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/http/test_http_middleware.py +0 -0
  214. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/openapi/__init__.py +0 -0
  215. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/openapi/test_openapi_path_parameters.py +0 -0
  216. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/test_app_state.py +0 -0
  217. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/test_context.py +0 -0
  218. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/test_file_server.py +0 -0
  219. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/test_import_server.py +0 -0
  220. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/test_logging.py +0 -0
  221. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/test_mount.py +0 -0
  222. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/test_resource_prefix_formats.py +0 -0
  223. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/test_run_server.py +0 -0
  224. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/server/test_tool_annotations.py +0 -0
  225. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/test_examples.py +0 -0
  226. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/test_servers/fastmcp_server.py +0 -0
  227. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/test_servers/sse.py +0 -0
  228. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/test_servers/stdio.py +0 -0
  229. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/tools/__init__.py +0 -0
  230. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/utilities/__init__.py +0 -0
  231. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/utilities/openapi/__init__.py +0 -0
  232. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/utilities/openapi/conftest.py +0 -0
  233. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/utilities/openapi/test_openapi.py +0 -0
  234. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/utilities/openapi/test_openapi_advanced.py +0 -0
  235. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/utilities/openapi/test_openapi_fastapi.py +0 -0
  236. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/utilities/test_cache.py +0 -0
  237. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/utilities/test_json_schema.py +0 -0
  238. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/utilities/test_logging.py +0 -0
  239. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/utilities/test_mcp_config.py +0 -0
  240. {fastmcp-2.7.1 → fastmcp-2.8.1}/tests/utilities/test_typeadapter.py +0 -0
@@ -0,0 +1,20 @@
1
+ version: 2
2
+ updates:
3
+ - package-ecosystem: "uv"
4
+ directory: "/"
5
+ schedule:
6
+ interval: "daily"
7
+ labels:
8
+ - "dependencies"
9
+ - package-ecosystem: "pip"
10
+ directory: "/"
11
+ schedule:
12
+ interval: "daily"
13
+ labels:
14
+ - "dependencies"
15
+ - package-ecosystem: "github-actions"
16
+ directory: "/"
17
+ schedule:
18
+ interval: "weekly"
19
+ labels:
20
+ - "dependencies"
@@ -7,6 +7,12 @@ changelog:
7
7
  - title: New Features 🎉
8
8
  labels:
9
9
  - feature
10
+ exclude:
11
+ labels:
12
+ - breaking change
13
+
14
+ - title: Enhancements 🔧
15
+ labels:
10
16
  - enhancement
11
17
  exclude:
12
18
  labels:
@@ -27,6 +33,10 @@ changelog:
27
33
  labels:
28
34
  - documentation
29
35
 
36
+ - title: Dependencies 📦
37
+ labels:
38
+ - dependencies
39
+
30
40
  - title: Other Changes 🦾
31
41
  labels:
32
42
  - "*"
@@ -17,7 +17,7 @@ jobs:
17
17
  fetch-depth: 0
18
18
 
19
19
  - name: "Install uv"
20
- uses: astral-sh/setup-uv@v3
20
+ uses: astral-sh/setup-uv@v6
21
21
 
22
22
  - name: Build
23
23
  run: uv build
@@ -32,7 +32,7 @@ jobs:
32
32
  steps:
33
33
  - uses: actions/checkout@v4
34
34
  - name: Install uv
35
- uses: astral-sh/setup-uv@v5
35
+ uses: astral-sh/setup-uv@v6
36
36
  with:
37
37
  enable-cache: true
38
38
  cache-dependency-glob: "uv.lock"
@@ -37,7 +37,7 @@ jobs:
37
37
  - uses: actions/checkout@v4
38
38
 
39
39
  - name: Install uv
40
- uses: astral-sh/setup-uv@v5
40
+ uses: astral-sh/setup-uv@v6
41
41
  with:
42
42
  enable-cache: true
43
43
  cache-dependency-glob: "uv.lock"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: fastmcp
3
- Version: 2.7.1
3
+ Version: 2.8.1
4
4
  Summary: The fast, Pythonic way to build MCP servers.
5
5
  Project-URL: Homepage, https://gofastmcp.com
6
6
  Project-URL: Repository, https://github.com/jlowin/fastmcp
@@ -20,7 +20,7 @@ Requires-Python: >=3.10
20
20
  Requires-Dist: authlib>=1.5.2
21
21
  Requires-Dist: exceptiongroup>=1.2.2
22
22
  Requires-Dist: httpx>=0.28.1
23
- Requires-Dist: mcp<2.0.0,>=1.9.2
23
+ Requires-Dist: mcp<2.0.0,>=1.9.4
24
24
  Requires-Dist: openapi-pydantic>=0.5.1
25
25
  Requires-Dist: python-dotenv>=1.1.0
26
26
  Requires-Dist: rich>=13.9.4
@@ -33,8 +33,11 @@ Description-Content-Type: text/markdown
33
33
 
34
34
  <!-- omit in toc -->
35
35
  # FastMCP v2 🚀
36
+
36
37
  <strong>The fast, Pythonic way to build MCP servers and clients.</strong>
37
38
 
39
+ *FastMCP is made with 💙 by [Prefect](https://www.prefect.io/)*
40
+
38
41
  [![Docs](https://img.shields.io/badge/docs-gofastmcp.com-blue)](https://gofastmcp.com)
39
42
  [![PyPI - Version](https://img.shields.io/pypi/v/fastmcp.svg)](https://pypi.org/project/fastmcp)
40
43
  [![Tests](https://github.com/jlowin/fastmcp/actions/workflows/run-tests.yml/badge.svg)](https://github.com/jlowin/fastmcp/actions/workflows/run-tests.yml)
@@ -44,13 +47,16 @@ Description-Content-Type: text/markdown
44
47
  </div>
45
48
 
46
49
  > [!Note]
50
+ >
47
51
  > #### Beyond the Protocol
48
- >
49
- > FastMCP is the standard framework for working with the Model Context Protocol. FastMCP 1.0 was incorporated into the [official low-level Python SDK](https://github.com/modelcontextprotocol/python-sdk), and FastMCP 2.0 *(this project)* provides a complete toolkit for working with the MCP ecosystem.
50
52
  >
51
- > FastMCP has a comprehensive set of features that go far beyond the core MCP specification, all in service of providing **the simplest path to production**. These include client support, server composition, auth, automatic generation from OpenAPI specs, remote server proxying, built-in testing tools, integrations, and more.
53
+ > FastMCP is the standard framework for working with the Model Context Protocol. FastMCP 1.0 was incorporated into the [official MCP Python SDK](https://github.com/modelcontextprotocol/python-sdk) in 2024.
52
54
  >
53
- > Ready to upgrade or get started? Follow the [installation instructions](/getting-started/installation), which include specific steps for upgrading from the official MCP SDK.
55
+ > This is FastMCP 2.0, the **actively maintained version** that provides a complete toolkit for working with the MCP ecosystem.
56
+ >
57
+ > FastMCP 2.0 has a comprehensive set of features that go far beyond the core MCP specification, all in service of providing **the simplest path to production**. These include deployment, auth, clients, server proxying and composition, generating servers from REST APIs, dynamic tool rewriting, built-in testing tools, integrations, and more.
58
+ >
59
+ > Ready to upgrade or get started? Follow the [installation instructions](https://gofastmcp.com/getting-started/installation), which include steps for upgrading from the official MCP SDK.
54
60
 
55
61
  ---
56
62
 
@@ -72,6 +78,7 @@ if __name__ == "__main__":
72
78
  ```
73
79
 
74
80
  Run the server locally:
81
+
75
82
  ```bash
76
83
  fastmcp run server.py
77
84
  ```
@@ -80,9 +87,10 @@ fastmcp run server.py
80
87
 
81
88
  FastMCP's complete documentation is available at **[gofastmcp.com](https://gofastmcp.com)**, including detailed guides, API references, and advanced patterns. This readme provides only a high-level overview.
82
89
 
83
- Documentation is also available in [llms.txt format](https://llmstxt.org/), which is a simple markdown standard that LLMs can consume easily.
90
+ Documentation is also available in [llms.txt format](https://llmstxt.org/), which is a simple markdown standard that LLMs can consume easily.
84
91
 
85
92
  There are two ways to access the LLM-friendly documentation:
93
+
86
94
  - [`llms.txt`](https://gofastmcp.com/llms.txt) is essentially a sitemap, listing all the pages in the documentation.
87
95
  - [`llms-full.txt`](https://gofastmcp.com/llms-full.txt) contains the entire documentation. Note this may exceed the context window of your LLM.
88
96
 
@@ -172,7 +180,7 @@ Learn more in the [**FastMCP Server Documentation**](https://gofastmcp.com/serve
172
180
 
173
181
  ### Tools
174
182
 
175
- Tools allow LLMs to perform actions by executing your Python functions (sync or async). Ideal for computations, API calls, or side effects (like `POST`/`PUT`). FastMCP handles schema generation from type hints and docstrings. Tools can return various types, including text, JSON-serializable objects, and even images using the [`fastmcp.Image`](https://gofastmcp.com/servers/tools#return-values) helper.
183
+ Tools allow LLMs to perform actions by executing your Python functions (sync or async). Ideal for computations, API calls, or side effects (like `POST`/`PUT`). FastMCP handles schema generation from type hints and docstrings. Tools can return various types, including text, JSON-serializable objects, and even images or audio aided by the FastMCP media helper classes.
176
184
 
177
185
  ```python
178
186
  @mcp.tool
@@ -218,12 +226,13 @@ Learn more in the [**Prompts Documentation**](https://gofastmcp.com/servers/prom
218
226
  ### Context
219
227
 
220
228
  Access MCP session capabilities within your tools, resources, or prompts by adding a `ctx: Context` parameter. Context provides methods for:
221
- * **Logging:** Log messages to MCP clients with `ctx.info()`, `ctx.error()`, etc.
222
- * **LLM Sampling:** Use `ctx.sample()` to request completions from the client's LLM.
223
- * **HTTP Request:** Use `ctx.http_request()` to make HTTP requests to other servers.
224
- * **Resource Access:** Use `ctx.read_resource()` to access resources on the server
225
- * **Progress Reporting:** Use `ctx.report_progress()` to report progress to the client.
226
- * and more...
229
+
230
+ - **Logging:** Log messages to MCP clients with `ctx.info()`, `ctx.error()`, etc.
231
+ - **LLM Sampling:** Use `ctx.sample()` to request completions from the client's LLM.
232
+ - **HTTP Request:** Use `ctx.http_request()` to make HTTP requests to other servers.
233
+ - **Resource Access:** Use `ctx.read_resource()` to access resources on the server
234
+ - **Progress Reporting:** Use `ctx.report_progress()` to report progress to the client.
235
+ - and more...
227
236
 
228
237
  To access the context, add a parameter annotated as `Context` to any mcp-decorated function. FastMCP will automatically inject the correct context object when the function is called.
229
238
 
@@ -363,16 +372,19 @@ if __name__ == "__main__":
363
372
  FastMCP supports three transport protocols:
364
373
 
365
374
  **STDIO (Default)**: Best for local tools and command-line scripts.
375
+
366
376
  ```python
367
377
  mcp.run(transport="stdio") # Default, so transport argument is optional
368
378
  ```
369
379
 
370
380
  **Streamable HTTP**: Recommended for web deployments.
381
+
371
382
  ```python
372
383
  mcp.run(transport="streamable-http", host="127.0.0.1", port=8000, path="/mcp")
373
384
  ```
374
385
 
375
386
  **SSE**: For compatibility with existing SSE clients.
387
+
376
388
  ```python
377
389
  mcp.run(transport="sse", host="127.0.0.1", port=8000)
378
390
  ```
@@ -385,22 +397,26 @@ Contributions are the core of open source! We welcome improvements and features.
385
397
 
386
398
  ### Prerequisites
387
399
 
388
- * Python 3.10+
389
- * [uv](https://docs.astral.sh/uv/) (Recommended for environment management)
400
+ - Python 3.10+
401
+ - [uv](https://docs.astral.sh/uv/) (Recommended for environment management)
390
402
 
391
403
  ### Setup
392
404
 
393
- 1. Clone the repository:
405
+ 1. Clone the repository:
406
+
394
407
  ```bash
395
408
  git clone https://github.com/jlowin/fastmcp.git
396
409
  cd fastmcp
397
410
  ```
398
- 2. Create and sync the environment:
411
+
412
+ 2. Create and sync the environment:
413
+
399
414
  ```bash
400
415
  uv sync
401
416
  ```
417
+
402
418
  This installs all dependencies, including dev tools.
403
-
419
+
404
420
  3. Activate the virtual environment (e.g., `source .venv/bin/activate` or via your IDE).
405
421
 
406
422
  ### Unit Tests
@@ -408,10 +424,13 @@ Contributions are the core of open source! We welcome improvements and features.
408
424
  FastMCP has a comprehensive unit test suite. All PRs must introduce or update tests as appropriate and pass the full suite.
409
425
 
410
426
  Run tests using pytest:
427
+
411
428
  ```bash
412
429
  pytest
413
430
  ```
431
+
414
432
  or if you want an overview of the code coverage
433
+
415
434
  ```bash
416
435
  uv run pytest --cov=src --cov=examples --cov-report=html
417
436
  ```
@@ -421,10 +440,13 @@ uv run pytest --cov=src --cov=examples --cov-report=html
421
440
  FastMCP uses `pre-commit` for code formatting, linting, and type-checking. All PRs must pass these checks (they run automatically in CI).
422
441
 
423
442
  Install the hooks locally:
443
+
424
444
  ```bash
425
445
  uv run pre-commit install
426
446
  ```
447
+
427
448
  The hooks will now run automatically on `git commit`. You can also run them manually at any time:
449
+
428
450
  ```bash
429
451
  pre-commit run --all-files
430
452
  # or via uv
@@ -433,11 +455,11 @@ uv run pre-commit run --all-files
433
455
 
434
456
  ### Pull Requests
435
457
 
436
- 1. Fork the repository on GitHub.
437
- 2. Create a feature branch from `main`.
438
- 3. Make your changes, including tests and documentation updates.
439
- 4. Ensure tests and pre-commit hooks pass.
440
- 5. Commit your changes and push to your fork.
441
- 6. Open a pull request against the `main` branch of `jlowin/fastmcp`.
458
+ 1. Fork the repository on GitHub.
459
+ 2. Create a feature branch from `main`.
460
+ 3. Make your changes, including tests and documentation updates.
461
+ 4. Ensure tests and pre-commit hooks pass.
462
+ 5. Commit your changes and push to your fork.
463
+ 6. Open a pull request against the `main` branch of `jlowin/fastmcp`.
442
464
 
443
- Please open an issue or discussion for questions or suggestions before starting significant work!
465
+ Please open an issue or discussion for questions or suggestions before starting significant work!
@@ -2,8 +2,11 @@
2
2
 
3
3
  <!-- omit in toc -->
4
4
  # FastMCP v2 🚀
5
+
5
6
  <strong>The fast, Pythonic way to build MCP servers and clients.</strong>
6
7
 
8
+ *FastMCP is made with 💙 by [Prefect](https://www.prefect.io/)*
9
+
7
10
  [![Docs](https://img.shields.io/badge/docs-gofastmcp.com-blue)](https://gofastmcp.com)
8
11
  [![PyPI - Version](https://img.shields.io/pypi/v/fastmcp.svg)](https://pypi.org/project/fastmcp)
9
12
  [![Tests](https://github.com/jlowin/fastmcp/actions/workflows/run-tests.yml/badge.svg)](https://github.com/jlowin/fastmcp/actions/workflows/run-tests.yml)
@@ -13,13 +16,16 @@
13
16
  </div>
14
17
 
15
18
  > [!Note]
19
+ >
16
20
  > #### Beyond the Protocol
17
- >
18
- > FastMCP is the standard framework for working with the Model Context Protocol. FastMCP 1.0 was incorporated into the [official low-level Python SDK](https://github.com/modelcontextprotocol/python-sdk), and FastMCP 2.0 *(this project)* provides a complete toolkit for working with the MCP ecosystem.
19
21
  >
20
- > FastMCP has a comprehensive set of features that go far beyond the core MCP specification, all in service of providing **the simplest path to production**. These include client support, server composition, auth, automatic generation from OpenAPI specs, remote server proxying, built-in testing tools, integrations, and more.
22
+ > FastMCP is the standard framework for working with the Model Context Protocol. FastMCP 1.0 was incorporated into the [official MCP Python SDK](https://github.com/modelcontextprotocol/python-sdk) in 2024.
21
23
  >
22
- > Ready to upgrade or get started? Follow the [installation instructions](/getting-started/installation), which include specific steps for upgrading from the official MCP SDK.
24
+ > This is FastMCP 2.0, the **actively maintained version** that provides a complete toolkit for working with the MCP ecosystem.
25
+ >
26
+ > FastMCP 2.0 has a comprehensive set of features that go far beyond the core MCP specification, all in service of providing **the simplest path to production**. These include deployment, auth, clients, server proxying and composition, generating servers from REST APIs, dynamic tool rewriting, built-in testing tools, integrations, and more.
27
+ >
28
+ > Ready to upgrade or get started? Follow the [installation instructions](https://gofastmcp.com/getting-started/installation), which include steps for upgrading from the official MCP SDK.
23
29
 
24
30
  ---
25
31
 
@@ -41,6 +47,7 @@ if __name__ == "__main__":
41
47
  ```
42
48
 
43
49
  Run the server locally:
50
+
44
51
  ```bash
45
52
  fastmcp run server.py
46
53
  ```
@@ -49,9 +56,10 @@ fastmcp run server.py
49
56
 
50
57
  FastMCP's complete documentation is available at **[gofastmcp.com](https://gofastmcp.com)**, including detailed guides, API references, and advanced patterns. This readme provides only a high-level overview.
51
58
 
52
- Documentation is also available in [llms.txt format](https://llmstxt.org/), which is a simple markdown standard that LLMs can consume easily.
59
+ Documentation is also available in [llms.txt format](https://llmstxt.org/), which is a simple markdown standard that LLMs can consume easily.
53
60
 
54
61
  There are two ways to access the LLM-friendly documentation:
62
+
55
63
  - [`llms.txt`](https://gofastmcp.com/llms.txt) is essentially a sitemap, listing all the pages in the documentation.
56
64
  - [`llms-full.txt`](https://gofastmcp.com/llms-full.txt) contains the entire documentation. Note this may exceed the context window of your LLM.
57
65
 
@@ -141,7 +149,7 @@ Learn more in the [**FastMCP Server Documentation**](https://gofastmcp.com/serve
141
149
 
142
150
  ### Tools
143
151
 
144
- Tools allow LLMs to perform actions by executing your Python functions (sync or async). Ideal for computations, API calls, or side effects (like `POST`/`PUT`). FastMCP handles schema generation from type hints and docstrings. Tools can return various types, including text, JSON-serializable objects, and even images using the [`fastmcp.Image`](https://gofastmcp.com/servers/tools#return-values) helper.
152
+ Tools allow LLMs to perform actions by executing your Python functions (sync or async). Ideal for computations, API calls, or side effects (like `POST`/`PUT`). FastMCP handles schema generation from type hints and docstrings. Tools can return various types, including text, JSON-serializable objects, and even images or audio aided by the FastMCP media helper classes.
145
153
 
146
154
  ```python
147
155
  @mcp.tool
@@ -187,12 +195,13 @@ Learn more in the [**Prompts Documentation**](https://gofastmcp.com/servers/prom
187
195
  ### Context
188
196
 
189
197
  Access MCP session capabilities within your tools, resources, or prompts by adding a `ctx: Context` parameter. Context provides methods for:
190
- * **Logging:** Log messages to MCP clients with `ctx.info()`, `ctx.error()`, etc.
191
- * **LLM Sampling:** Use `ctx.sample()` to request completions from the client's LLM.
192
- * **HTTP Request:** Use `ctx.http_request()` to make HTTP requests to other servers.
193
- * **Resource Access:** Use `ctx.read_resource()` to access resources on the server
194
- * **Progress Reporting:** Use `ctx.report_progress()` to report progress to the client.
195
- * and more...
198
+
199
+ - **Logging:** Log messages to MCP clients with `ctx.info()`, `ctx.error()`, etc.
200
+ - **LLM Sampling:** Use `ctx.sample()` to request completions from the client's LLM.
201
+ - **HTTP Request:** Use `ctx.http_request()` to make HTTP requests to other servers.
202
+ - **Resource Access:** Use `ctx.read_resource()` to access resources on the server
203
+ - **Progress Reporting:** Use `ctx.report_progress()` to report progress to the client.
204
+ - and more...
196
205
 
197
206
  To access the context, add a parameter annotated as `Context` to any mcp-decorated function. FastMCP will automatically inject the correct context object when the function is called.
198
207
 
@@ -332,16 +341,19 @@ if __name__ == "__main__":
332
341
  FastMCP supports three transport protocols:
333
342
 
334
343
  **STDIO (Default)**: Best for local tools and command-line scripts.
344
+
335
345
  ```python
336
346
  mcp.run(transport="stdio") # Default, so transport argument is optional
337
347
  ```
338
348
 
339
349
  **Streamable HTTP**: Recommended for web deployments.
350
+
340
351
  ```python
341
352
  mcp.run(transport="streamable-http", host="127.0.0.1", port=8000, path="/mcp")
342
353
  ```
343
354
 
344
355
  **SSE**: For compatibility with existing SSE clients.
356
+
345
357
  ```python
346
358
  mcp.run(transport="sse", host="127.0.0.1", port=8000)
347
359
  ```
@@ -354,22 +366,26 @@ Contributions are the core of open source! We welcome improvements and features.
354
366
 
355
367
  ### Prerequisites
356
368
 
357
- * Python 3.10+
358
- * [uv](https://docs.astral.sh/uv/) (Recommended for environment management)
369
+ - Python 3.10+
370
+ - [uv](https://docs.astral.sh/uv/) (Recommended for environment management)
359
371
 
360
372
  ### Setup
361
373
 
362
- 1. Clone the repository:
374
+ 1. Clone the repository:
375
+
363
376
  ```bash
364
377
  git clone https://github.com/jlowin/fastmcp.git
365
378
  cd fastmcp
366
379
  ```
367
- 2. Create and sync the environment:
380
+
381
+ 2. Create and sync the environment:
382
+
368
383
  ```bash
369
384
  uv sync
370
385
  ```
386
+
371
387
  This installs all dependencies, including dev tools.
372
-
388
+
373
389
  3. Activate the virtual environment (e.g., `source .venv/bin/activate` or via your IDE).
374
390
 
375
391
  ### Unit Tests
@@ -377,10 +393,13 @@ Contributions are the core of open source! We welcome improvements and features.
377
393
  FastMCP has a comprehensive unit test suite. All PRs must introduce or update tests as appropriate and pass the full suite.
378
394
 
379
395
  Run tests using pytest:
396
+
380
397
  ```bash
381
398
  pytest
382
399
  ```
400
+
383
401
  or if you want an overview of the code coverage
402
+
384
403
  ```bash
385
404
  uv run pytest --cov=src --cov=examples --cov-report=html
386
405
  ```
@@ -390,10 +409,13 @@ uv run pytest --cov=src --cov=examples --cov-report=html
390
409
  FastMCP uses `pre-commit` for code formatting, linting, and type-checking. All PRs must pass these checks (they run automatically in CI).
391
410
 
392
411
  Install the hooks locally:
412
+
393
413
  ```bash
394
414
  uv run pre-commit install
395
415
  ```
416
+
396
417
  The hooks will now run automatically on `git commit`. You can also run them manually at any time:
418
+
397
419
  ```bash
398
420
  pre-commit run --all-files
399
421
  # or via uv
@@ -402,11 +424,11 @@ uv run pre-commit run --all-files
402
424
 
403
425
  ### Pull Requests
404
426
 
405
- 1. Fork the repository on GitHub.
406
- 2. Create a feature branch from `main`.
407
- 3. Make your changes, including tests and documentation updates.
408
- 4. Ensure tests and pre-commit hooks pass.
409
- 5. Commit your changes and push to your fork.
410
- 6. Open a pull request against the `main` branch of `jlowin/fastmcp`.
427
+ 1. Fork the repository on GitHub.
428
+ 2. Create a feature branch from `main`.
429
+ 3. Make your changes, including tests and documentation updates.
430
+ 4. Ensure tests and pre-commit hooks pass.
431
+ 5. Commit your changes and push to your fork.
432
+ 6. Open a pull request against the `main` branch of `jlowin/fastmcp`.
411
433
 
412
- Please open an issue or discussion for questions or suggestions before starting significant work!
434
+ Please open an issue or discussion for questions or suggestions before starting significant work!