-
Notifications
You must be signed in to change notification settings - Fork 10.7k
Include AddEndpointsApiExplorer in ASP.NET Core Web API template By default #36696
Copy link
Copy link
Closed
Closed
Copy link
Labels
area-minimalIncludes minimal APIs, endpoint filters, parameter binding, request delegate generator etcIncludes minimal APIs, endpoint filters, parameter binding, request delegate generator etcfeature-minimal-actionsController-like actions for endpoint routingController-like actions for endpoint routingfeature-openapiold-area-web-frameworks-do-not-use*DEPRECATED* This label is deprecated in favor of the area-mvc and area-minimal labels*DEPRECATED* This label is deprecated in favor of the area-mvc and area-minimal labels
Milestone
Metadata
Metadata
Assignees
Labels
area-minimalIncludes minimal APIs, endpoint filters, parameter binding, request delegate generator etcIncludes minimal APIs, endpoint filters, parameter binding, request delegate generator etcfeature-minimal-actionsController-like actions for endpoint routingController-like actions for endpoint routingfeature-openapiold-area-web-frameworks-do-not-use*DEPRECATED* This label is deprecated in favor of the area-mvc and area-minimal labels*DEPRECATED* This label is deprecated in favor of the area-mvc and area-minimal labels
Type
Fields
Give feedbackNo fields configured for issues without a type.
Is your feature request related to a problem? Please describe.
When you create a Web API project using the ASP.NET Core Web API template and check both
use Controllers and Enable Open API supportas shown in the image below, the Minimal API endpoints do not get automatically added to the API explorer as it is for controller endpoints. The user needs to manually inject theAddEndpointsApiExplorerService (builder.Services.AddEndpointsApiExplorer();) for Minimal endpoints to be added to the API explorer. It will be a better experience to addbuilder.Services.AddEndpointsApiExplorer();by default to the template to enable users to explore Minimal APIs features (Open APIs) while still using MVC controllers.