Description parameter of ProducesResponseTypeAttribute does not work in minimal API app #60518
Open
1 task done
Labels
area-minimal
Includes minimal APIs, endpoint filters, parameter binding, request delegate generator etc
feature-openapi
help wanted
Up for grabs. We would accept a PR to help resolve this issue
Milestone
Is there an existing issue for this?
Describe the bug
A Description parameter was added to ProducesResponseTypeAttribute in .NET 10 to set the
description
field of the response in the generated OpenAPI document. This works fine in a controller-based app but does not seem to work in a Minimal API app.Expected Behavior
The ProducesResponseTypeAttribute, when placed on the delegate parameter of a minimal API app endpoint, should add a description to the response in the generated API.
Steps To Reproduce
I've reproduced the problem in the project in this repo:
https://github.com/mikekistler/ResponseDescription
The problem exists for both the OpenAPI generated at build time and the OpenAPI served from the /openapi/v1.json endpoint.
Exceptions (if any)
No response
.NET Version
10.0.100-preview.1.25104.26
Anything else?
No response
The text was updated successfully, but these errors were encountered: