dotnet / dotnet/aspnetcore

Description on IBindableFromHttpContext parameter of route handler in Minimal API not generated in OpenAPI requestBody

Open
#57,685 2 comments 0 reactions 0 assignees View on GitHub
area-minimal feature-openapi
Dominant language
C#
Stars
38.4k
Forks
10.9k
Avg merge
2d 10h
Merged PRs (30d)
281

Description

### Is there an existing issue for this?

- [X] I have searched the existing issues

### Describe the bug

In a Minimal API App, the [Description] on an _implicit_ body parameter is lost. In a controller-based app, the description will appear in the description property of the request body in the generated OpenAPI.

### Expected Behavior

In a Minimal API app, the Description on an implicit body parameter should appear in the description property of the request body in the generated OpenAPI, just as it does for a controller-based app.

### Steps To Reproduce

Add a Description to an implicit body parameter in a minimal API app which is configured to generate its OpenAPI document. Build the project and inspect the operation request body.

### Exceptions (if any)

_No response_

### .NET Version

9.0.100-preview.7.24407.12

### Anything else?

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.