Skip to content

πŸš€ The fast, Pythonic way to build MCP servers and clients.

set body's description as well

ShiWeicb6499922ecb
diff --git a/src/fastmcp/utilities/openapi.py b/src/fastmcp/utilities/openapi.py
index aa5e89bf0..862396966 100644
--- a/src/fastmcp/utilities/openapi.py
+++ b/src/fastmcp/utilities/openapi.py
@@ -942,7 +942,8 @@ def _combine_schemas(route: HTTPRoute) -> dict[str, Any]:
# For now, just use the first content type's schema
content_type = next(iter(route.request_body.content_schema))
body_schema = _replace_ref_with_defs(
- route.request_body.content_schema[content_type].copy()
+ route.request_body.content_schema[content_type].copy(),
+ route.request_body.description,
)
body_props = body_schema.get("properties", {})