diff --git a/src/bemserver_api/extensions/smorest.py b/src/bemserver_api/extensions/smorest.py index f1e2528..87a081c 100644 --- a/src/bemserver_api/extensions/smorest.py +++ b/src/bemserver_api/extensions/smorest.py @@ -62,7 +62,7 @@ def _field2parameter(self, field, *, name, location): # Document DictStr as "content" parameter # https://github.com/marshmallow-code/apispec/issues/922 if isinstance(field, DictStr): - ret["content"] = {"application/json": ret.pop("schema")} + ret["content"] = {"application/json": {"schema": ret.pop("schema")}} for param_attr_func in self.parameter_attribute_functions: ret.update(param_attr_func(field, ret=ret))