mirror of
https://github.com/PrefectHQ/fastmcp.git
synced 2026-08-16 18:49:14 +02:00
* Add compatibility tools contrib module Implements four standalone tools that expose resources and prompts as callable tools for clients that only support the tools capability. Features: - list_resources: List all available resources - get_resource: Read a resource by URI - list_prompts: List all available prompts - get_prompt: Get a prompt with optional arguments The tools use Context to access the server instance and can be easily added to any FastMCP server using the add_compatibility_tools helper or by adding individual tool instances directly. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: William Easton <strawgate@users.noreply.github.com> * Simplify compatibility tools to return raw MCP protocol objects Return raw MCP protocol objects (ListResourcesResult, ReadResourceResult, ListPromptsResult, GetPromptResult) instead of custom dictionaries. This makes the tools simpler and more predictable by directly exposing what the client methods return. Co-authored-by: William Easton <strawgate@users.noreply.github.com> * Add tool injection middleware * cleanup contrib module * More clean-up * Clean up tool injection middleware. * Update src/fastmcp/server/middleware/tool_injection.py Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Add tool injection docs * Small cleanup of prompt middleware * PR Feedback * Fix tool injection tests --------- Co-authored-by: claude[bot] <41898282+claude[bot]@users.noreply.github.com> Co-authored-by: William Easton <strawgate@users.noreply.github.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> |
||
|---|---|---|
| .. | ||
| __init__.py | ||
| test_caching.py | ||
| test_error_handling.py | ||
| test_initialization_middleware.py | ||
| test_logging.py | ||
| test_middleware.py | ||
| test_rate_limiting.py | ||
| test_timing.py | ||
| test_tool_injection.py | ||