Commit graph

3,289 commits

Author SHA1 Message Date
Jeremiah Lowin
db24c85359 Update all tests 2025-06-27 21:41:37 -04:00
Jeremiah Lowin
037b1f35b1
Merge pull request #977 from cortexapps/add-extensions
Add OpenAPI extensions support to HTTPRoute
2025-06-27 20:45:01 -04:00
Jeremiah Lowin
05104aa3a8
Merge pull request #976 from gorocode/feature/component-manager
Component Manager
2025-06-27 20:43:18 -04:00
Jeremiah Lowin
a7eb2da273 Update output schema control 2025-06-27 20:17:10 -04:00
Aditya Bansal
f524652f25 Add OpenAPI extensions support to HTTPRoute
- Add extensions field to HTTPRoute class to store x-* fields
  - Extract extensions from operation's model_extra in parser
  - Add test to verify extensions are properly parsed
2025-06-27 15:27:36 -07:00
Goro
18e522b320 Remove redundant testing calls 2025-06-27 23:58:59 +02:00
Goro
3598943d06 Fix doc and example 2025-06-27 23:54:18 +02:00
Goro
852952dd6d Add tests when custom path is provided 2025-06-27 23:30:41 +02:00
Goro
510f3fb3f2 Merge branch 'main' of https://github.com/jlowin/fastmcp into feature/component-manager 2025-06-27 22:18:33 +02:00
Goro
7d252e6da4 Add missing documentation 2025-06-27 22:17:44 +02:00
Jeremiah Lowin
ddb557ba30 Update for 'result' kwarg instead of 'value' 2025-06-27 15:44:46 -04:00
Jeremiah Lowin
d8dc28b9b2 Add structured content & update almost all tests 2025-06-27 15:40:52 -04:00
tommitt
f774612add Rename path 2025-06-27 21:13:45 +02:00
Goro
f2fe4f94b0 Refactor duplicated logic 2025-06-27 21:12:17 +02:00
tommitt
37415dfa1e Introduce Eunomia Middleware docs 2025-06-27 21:04:26 +02:00
Goro
fc26023f5d Fix typing warnings 2025-06-27 20:12:52 +02:00
Goro
02a905e8b9 Add component manager tests 2025-06-27 20:04:25 +02:00
Goro
6b89695949 Refactor component manager into contrib module 2025-06-27 19:27:15 +02:00
Jeremiah Lowin
2b313bc3ff Update tool transformation for ToolResult compatibility
- TransformedTool.run() now returns ToolResult instead of list[ContentBlock]
- forward() and forward_raw() return ToolResult from parent tools
- Transform functions can return ToolResult for full control or any value for auto-wrapping
- Maintains backward compatibility with existing transform functions

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-06-26 22:02:04 -04:00
Jeremiah Lowin
21d4ce092c Add structured output support
- Tools can return StructuredOutput() for explicit structured data
- Tools with output_schema automatically return structured data
- Client hydrates structured responses into typed objects
- Maintains backward compatibility with unstructured-only tools
2025-06-26 21:15:25 -04:00
Jeremiah Lowin
7f0622b707 Fix contrib tests 2025-06-26 20:17:02 -04:00
Jeremiah Lowin
1e29149d5f Merge branch 'main' into output-schema 2025-06-26 19:30:35 -04:00
Jeremiah Lowin
19c1526286 Fix trailing slash 2025-06-26 19:24:57 -04:00
Jeremiah Lowin
37daf553c1 Clean up extra oauth models, not needed anymore 2025-06-26 19:07:05 -04:00
Jeremiah Lowin
85cca273de
Merge pull request #887 from jlowin/protocol-update
MCP 6/18/25: Staging PR
2025-06-26 18:45:10 -04:00
Jeremiah Lowin
33263582b8 Fix typing 2025-06-26 18:33:32 -04:00
Jeremiah Lowin
78f0196db5 Fix OpenAPI tests 2025-06-26 18:21:52 -04:00
Jeremiah Lowin
7b9696405b Remove legacy json parsing
Because the server now validates inputs, its no longer viable to provide a JSON string where e.g. an array is expected, so we can entirely remove FastMCP's "legacy json parsing" support from 1.x.

This is a breaking change (for legacy opt-in behavior)
2025-06-26 18:19:43 -04:00
Jeremiah Lowin
9d51bca0d8 Merge branch 'main' into protocol-update 2025-06-26 18:13:59 -04:00
Jeremiah Lowin
ddb38bacc4 Fix middleware tests 2025-06-26 18:13:32 -04:00
Jeremiah Lowin
6b2df6be51 Fix middleware tests 2025-06-26 17:57:30 -04:00
Jeremiah Lowin
aa66b81b73 Merge branch 'protocol-update' of https://github.com/jlowin/fastmcp into protocol-update 2025-06-26 15:22:41 -04:00
Jeremiah Lowin
4fb778c608
Merge pull request #966 from jlowin/protocol-update-auth
MCP 6/18/25: Update auth primitives
2025-06-26 15:22:28 -04:00
Jeremiah Lowin
fa83f38dc4 Update uv.lock 2025-06-26 15:20:51 -04:00
Jeremiah Lowin
b98b080c98 Implement TokenVerifier protocol for mcp-python-sdk compatibility
Fixes breaking changes from mcp-python-sdk PR #982 which updated
BearerAuthBackend to use TokenVerifier protocol instead of OAuth providers.

Changes:
- Add verify_token() method to BearerAuthProvider implementing TokenVerifier protocol
- Add verify_token() method to InMemoryOAuthProvider implementing TokenVerifier protocol
- Update BearerAuthBackend usage in setup_auth_middleware_and_routes() to pass TokenVerifier
- Add comprehensive unit tests for TokenVerifier implementations
- Add integration tests for BearerAuthBackend with TokenVerifier
- Add tests for HTTP auth setup functions

All existing functionality preserved with full backwards compatibility.

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-06-26 15:08:31 -04:00
Jeremiah Lowin
2dcd6e19ab
Merge pull request #962 from jlowin/pin-mcp v2.9.2
Pin mcp
2025-06-26 11:01:37 -04:00
Jeremiah Lowin
436aa01bb2 Update uv.lock 2025-06-26 10:59:10 -04:00
Jeremiah Lowin
947a02b1f2 Pin mcp 2025-06-26 10:57:11 -04:00
Jeremiah Lowin
0624a4ae53 Update tests for server input validation 2025-06-26 10:56:21 -04:00
Jeremiah Lowin
5ca7a118a6 Fix typeddict imports 2025-06-26 10:09:02 -04:00
Jeremiah Lowin
757c037a04
Merge pull request #960 from jlowin/version
Fix version badge for messages
2025-06-26 09:41:06 -04:00
Jeremiah Lowin
5fc82f4fef Fix version badge for messages 2025-06-26 09:40:49 -04:00
Jeremiah Lowin
3de57fa069
Merge pull request #939 from jlowin/notifications v2.9.1
Add automatic MCP list change notifications and client message handling
2025-06-26 09:38:03 -04:00
Jeremiah Lowin
1fe4eb7a9d
Merge branch 'main' into notifications 2025-06-26 09:36:26 -04:00
Jeremiah Lowin
35d04d645f Update pyproject.toml 2025-06-26 09:26:07 -04:00
Jeremiah Lowin
68ab760240 Merge branch 'main' into protocol-update 2025-06-26 09:25:39 -04:00
Jeremiah Lowin
1bb3c1404f
Merge pull request #957 from rajephon/main
fix(examples): update mount_example.py to work with current fastmcp API
2025-06-26 09:24:22 -04:00
Chanwoo Noh
7a1e332aae fix: update mount_example.py for current fastmcp API
- Update mount() calls to use keyword arguments (server, prefix)
- Replace private API access with public async methods (get_tools, get_resources)
- Fix resource URI handling to use URL parsing instead of string prefixes
- Update resource access to use _mcp_read_resource with proper URI format
- Add urllib.parse import for URL parsing functionality

The mounting API and resource handling changed in recent fastmcp versions,
breaking the mount_example.py functionality. This update ensures the example
works correctly with fastmcp v2.9.0.

Tested on: fastmcp v2.9.0
2025-06-26 14:44:51 +09:00
Jeremiah Lowin
159324ea46
Merge pull request #954 from jlowin/claude-wt-20250625-210215
Fix external schema reference handling in OpenAPI parser
2025-06-25 21:39:49 -04:00
Jeremiah Lowin
f99ac2ea70
Merge pull request #953 from jlowin/claude-wt-20250625-195151
Fix parameter location enum handling in OpenAPI parser
2025-06-25 21:38:36 -04:00