Commit graph

4 commits

Author SHA1 Message Date
Jeremiah Lowin
bafd5419fa
Redact sensitive headers in OpenAPI provider debug logging (#3436)
* Redact sensitive headers in OpenAPI provider debug logging (#3427)

* Use safe-header allowlist instead of sensitive-header denylist for redaction
2026-03-07 12:10:05 -05:00
Jeremiah Lowin
1d0c0adeab
Add validate_output option for OpenAPI tools (#3134)
Co-authored-by: marvin-context-protocol[bot] <225465937+marvin-context-protocol[bot]@users.noreply.github.com>
2026-02-10 13:29:45 -05:00
Jeremiah Lowin
85eff33b81
Infer MIME types from OpenAPI response definitions (#3101)
* Infer mime_type from OpenAPI response content types for resources

🤖 Generated with Claude Code

https://claude.ai/code/session_01FZD5ZT8WiQqfBu39ybuQis

* Handle media types without schemas in MIME inference

🤖 Generated with Claude Code

https://claude.ai/code/session_01FZD5ZT8WiQqfBu39ybuQis

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-02-06 20:08:08 -05:00
Jeremiah Lowin
96c7a74b27
Move OpenAPI to providers/openapi submodule (#2672)
* Move OpenAPI to providers/openapi/ submodule

Migrates the OpenAPI implementation to the provider pattern:
- Creates src/fastmcp/server/providers/openapi/ submodule with provider.py,
  components.py, and routing.py
- Converts server/openapi/ to deprecated re-export stubs
- FastMCPOpenAPI remains as deprecated wrapper that uses OpenAPIProvider
- Updates experimental/server/openapi to import from new canonical location

* Update tests and FastMCP methods to use OpenAPIProvider

- Update FastMCP.from_openapi() and from_fastapi() to use OpenAPIProvider
  directly, returning FastMCP instead of deprecated FastMCPOpenAPI
- Move tests from tests/server/openapi/ to tests/server/providers/openapi/
- Update all test imports to use new canonical location
- Add tests/deprecated/openapi/ for backward compatibility testing
- Update tests/client/test_openapi.py to use new imports

* Fix deprecation warning tests and address CodeRabbit feedback

- Use importlib.reload() to ensure deprecation warnings fire in tests
- Change logger.error to logger.exception for better stack traces
2025-12-22 11:13:33 -05:00
Renamed from tests/server/openapi/test_openapi_features.py (Browse further)