From f5e0de676857701f0930131bf5f1f0ca4be0bedc Mon Sep 17 00:00:00 2001 From: Sander ten Brinke Date: Sat, 12 Jul 2025 15:33:14 +0200 Subject: [PATCH 1/6] Remove comment about Minimal API's not supporting ProducesResponseType --- .../aspnetcore-10/includes/responseDescProducesResponseType.md | 1 - 1 file changed, 1 deletion(-) diff --git a/aspnetcore/release-notes/aspnetcore-10/includes/responseDescProducesResponseType.md b/aspnetcore/release-notes/aspnetcore-10/includes/responseDescProducesResponseType.md index 29eb865527c6..c0453fa3ed5d 100644 --- a/aspnetcore/release-notes/aspnetcore-10/includes/responseDescProducesResponseType.md +++ b/aspnetcore/release-notes/aspnetcore-10/includes/responseDescProducesResponseType.md @@ -18,6 +18,5 @@ And the generated OpenAPI: "description": "The weather forecast for the next 5 days.", "content": { ``` -[Minimal APIs](https://github.com/dotnet/aspnetcore/issues/58724) currently don't support `ProducesResponseType`. [Community contribution](https://github.com/dotnet/aspnetcore/pull/58193) by [Sander ten Brinke](https://github.com/sander1095) 🙏 From 95f223e0471bd5e5a672b7c5834b767cbfb78d93 Mon Sep 17 00:00:00 2001 From: Sander ten Brinke Date: Sat, 12 Jul 2025 15:44:16 +0200 Subject: [PATCH 2/6] Fix community member reference --- .../aspnetcore-10/includes/webapiaotTemplateAddedOpenAPI.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/aspnetcore/release-notes/aspnetcore-10/includes/webapiaotTemplateAddedOpenAPI.md b/aspnetcore/release-notes/aspnetcore-10/includes/webapiaotTemplateAddedOpenAPI.md index eb64f256aac5..8119aef5e78f 100644 --- a/aspnetcore/release-notes/aspnetcore-10/includes/webapiaotTemplateAddedOpenAPI.md +++ b/aspnetcore/release-notes/aspnetcore-10/includes/webapiaotTemplateAddedOpenAPI.md @@ -2,4 +2,4 @@ The **ASP.NET Core Web API (Native AOT)** project template (short name `webapiaot`) now includes support for OpenAPI document generation using the [`Microsoft.AspNetCore.OpenApi`](https://www.nuget.org/packages/Microsoft.AspNetCore.OpenApi) package by default. This support is disabled by using the `--no-openapi` flag when creating a new project. -This was a community contribution by @sander1095. Thanks for this contribution! +[Community contribution](https://github.com/dotnet/aspnetcore/pull/60337) by [Sander ten Brinke](https://github.com/sander1095) 🙏 From d99e30e7e882a9da998c5a3b33bdfeff559557ac Mon Sep 17 00:00:00 2001 From: Luke Latham <1622880+guardrex@users.noreply.github.com> Date: Sat, 12 Jul 2025 10:18:06 -0400 Subject: [PATCH 3/6] Updates --- .../aspnetcore-10/includes/webapiaotTemplateAddedOpenAPI.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/aspnetcore/release-notes/aspnetcore-10/includes/webapiaotTemplateAddedOpenAPI.md b/aspnetcore/release-notes/aspnetcore-10/includes/webapiaotTemplateAddedOpenAPI.md index 8119aef5e78f..1f50dc867ac3 100644 --- a/aspnetcore/release-notes/aspnetcore-10/includes/webapiaotTemplateAddedOpenAPI.md +++ b/aspnetcore/release-notes/aspnetcore-10/includes/webapiaotTemplateAddedOpenAPI.md @@ -1,5 +1,5 @@ ### Microsoft.AspNetCore.OpenApi added to the ASP.NET Core web API (Native AOT) template -The **ASP.NET Core Web API (Native AOT)** project template (short name `webapiaot`) now includes support for OpenAPI document generation using the [`Microsoft.AspNetCore.OpenApi`](https://www.nuget.org/packages/Microsoft.AspNetCore.OpenApi) package by default. This support is disabled by using the `--no-openapi` flag when creating a new project. +The **ASP.NET Core Web API (Native AOT)** project template (short name `webapiaot`) now includes support for OpenAPI document generation using the [`Microsoft.AspNetCore.OpenApi` package](https://www.nuget.org/packages/Microsoft.AspNetCore.OpenApi) by default. This support is disabled by using the `--no-openapi` flag when creating a new project. -[Community contribution](https://github.com/dotnet/aspnetcore/pull/60337) by [Sander ten Brinke](https://github.com/sander1095) 🙏 +[Community contribution (`dotnet/aspnetcore` #60337)](https://github.com/dotnet/aspnetcore/pull/60337) by [Sander ten Brinke](https://github.com/sander1095). From 9847281b67960407514a7209814817811a8d1470 Mon Sep 17 00:00:00 2001 From: Luke Latham <1622880+guardrex@users.noreply.github.com> Date: Sat, 12 Jul 2025 10:23:08 -0400 Subject: [PATCH 4/6] Updates --- .../responseDescProducesResponseType.md | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/aspnetcore/release-notes/aspnetcore-10/includes/responseDescProducesResponseType.md b/aspnetcore/release-notes/aspnetcore-10/includes/responseDescProducesResponseType.md index c0453fa3ed5d..517777365b05 100644 --- a/aspnetcore/release-notes/aspnetcore-10/includes/responseDescProducesResponseType.md +++ b/aspnetcore/release-notes/aspnetcore-10/includes/responseDescProducesResponseType.md @@ -1,22 +1,22 @@ -### Response description on ProducesResponseType for API controllers +### Response description on `ProducesResponseType` for API controllers -The [ProducesAttribute](/dotnet/api/microsoft.aspnetcore.mvc.producesattribute-1), [ProducesResponseTypeAttribute](/dotnet/api/microsoft.aspnetcore.mvc.producesresponsetypeattribute-1), and [ProducesDefaultResponseType](/dotnet/api/microsoft.aspnetcore.mvc.producesdefaultresponsetypeattribute) attributes now accept an optional string parameter, `Description`, that will set the description of the response. Here's an example: +The , , and now accept an optional string parameter, `Description`, that sets the description of the response: ```csharp [HttpGet(Name = "GetWeatherForecast")] [ProducesResponseType>(StatusCodes.Status200OK, - Description = "The weather forecast for the next 5 days.")] + Description = "The weather forecast for the next 5 days.")] public IEnumerable Get() { ``` -And the generated OpenAPI: +Generated OpenAPI data: ```json - "responses": { - "200": { - "description": "The weather forecast for the next 5 days.", - "content": { +"responses": { + "200": { + "description": "The weather forecast for the next 5 days.", + "content": { ``` -[Community contribution](https://github.com/dotnet/aspnetcore/pull/58193) by [Sander ten Brinke](https://github.com/sander1095) 🙏 +[Community contribution (`dotnet/aspnetcore` #58193)](https://github.com/dotnet/aspnetcore/pull/58193) by [Sander ten Brinke](https://github.com/sander1095). From 72861901088a58811c3b3255bdcaecba0c38d18b Mon Sep 17 00:00:00 2001 From: Luke Latham <1622880+guardrex@users.noreply.github.com> Date: Sat, 12 Jul 2025 10:33:04 -0400 Subject: [PATCH 5/6] Updates --- .../aspnetcore-10/includes/responseDescProducesResponseType.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/aspnetcore/release-notes/aspnetcore-10/includes/responseDescProducesResponseType.md b/aspnetcore/release-notes/aspnetcore-10/includes/responseDescProducesResponseType.md index 517777365b05..a7c890d9b79f 100644 --- a/aspnetcore/release-notes/aspnetcore-10/includes/responseDescProducesResponseType.md +++ b/aspnetcore/release-notes/aspnetcore-10/includes/responseDescProducesResponseType.md @@ -19,4 +19,6 @@ Generated OpenAPI data: "content": { ``` +Currently, Minimal APIs don't support . Support is planned for a future ASP.NET Core release. For more information, see [Improving current methods for setting OpenAPI response descriptions with Minimal APIs (`dotnet/aspnetcore` #58724)](https://github.com/dotnet/aspnetcore/issues/58724). + [Community contribution (`dotnet/aspnetcore` #58193)](https://github.com/dotnet/aspnetcore/pull/58193) by [Sander ten Brinke](https://github.com/sander1095). From d87fa233bfb6ea5d99d7590ede4bf081730667e6 Mon Sep 17 00:00:00 2001 From: Luke Latham <1622880+guardrex@users.noreply.github.com> Date: Sat, 12 Jul 2025 14:51:30 -0400 Subject: [PATCH 6/6] Updates --- .../aspnetcore-10/includes/responseDescProducesResponseType.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/aspnetcore/release-notes/aspnetcore-10/includes/responseDescProducesResponseType.md b/aspnetcore/release-notes/aspnetcore-10/includes/responseDescProducesResponseType.md index a7c890d9b79f..517777365b05 100644 --- a/aspnetcore/release-notes/aspnetcore-10/includes/responseDescProducesResponseType.md +++ b/aspnetcore/release-notes/aspnetcore-10/includes/responseDescProducesResponseType.md @@ -19,6 +19,4 @@ Generated OpenAPI data: "content": { ``` -Currently, Minimal APIs don't support . Support is planned for a future ASP.NET Core release. For more information, see [Improving current methods for setting OpenAPI response descriptions with Minimal APIs (`dotnet/aspnetcore` #58724)](https://github.com/dotnet/aspnetcore/issues/58724). - [Community contribution (`dotnet/aspnetcore` #58193)](https://github.com/dotnet/aspnetcore/pull/58193) by [Sander ten Brinke](https://github.com/sander1095).