Microsoft.AspNetCore.OpenApi 11.0.0

Prefix Reserved
dotnet add package Microsoft.AspNetCore.OpenApi --version 11.0.0
                    
NuGet\Install-Package Microsoft.AspNetCore.OpenApi -Version 11.0.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Microsoft.AspNetCore.OpenApi" Version="11.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Microsoft.AspNetCore.OpenApi" Version="11.0.0" />
                    
Directory.Packages.props
<PackageReference Include="Microsoft.AspNetCore.OpenApi" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Microsoft.AspNetCore.OpenApi --version 11.0.0
                    
#r "nuget: Microsoft.AspNetCore.OpenApi, 11.0.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Microsoft.AspNetCore.OpenApi@11.0.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Microsoft.AspNetCore.OpenApi&version=11.0.0
                    
Install as a Cake Addin
#tool nuget:?package=Microsoft.AspNetCore.OpenApi&version=11.0.0
                    
Install as a Cake Tool

About

Microsoft.AspNetCore.OpenApi is a NuGet package that provides built-in support for generating OpenAPI documents from minimal or controller-based APIs in ASP.NET Core.

Key Features

  • Supports viewing generated OpenAPI documents at runtime via a parameterized endpoint (/openapi/{documentName}.json)
  • Supports generating an OpenAPI document at build-time
  • Supports customizing the generated document via document transformers

How to Use

To start using Microsoft.AspNetCore.OpenApi in your ASP.NET Core application, follow these steps:

Installation

dotnet add package Microsoft.AspNetCore.OpenApi

Configuration

In your Program.cs file, register the services provided by this package in the DI container and map the provided OpenAPI document endpoint in the application.

var builder = WebApplication.CreateBuilder();

// Registers the required services
builder.Services.AddOpenApi();

var app = builder.Build();

// Adds the /openapi/{documentName}.json endpoint to the application
app.MapOpenApi();

app.Run();

For more information on configuring and using Microsoft.AspNetCore.OpenApi, refer to the official documentation.

Build-time Document Generation

Microsoft.AspNetCore.OpenApi supports generating OpenAPI documents at build time via the Microsoft.Extensions.ApiDescription.Server package. When you run dotnet build, the document generation tool runs automatically.

Viewing Build-time Generation Output

By default, the .NET 8+ Terminal Logger suppresses the document generation tool output. To see the full generation logs, including messages like Generating document named 'v1', use one of the following approaches:

  • Increase Terminal Logger verbosity: Pass -tlp:v=d (detailed) to your build command:

    dotnet build -tlp:v=d
    
  • Disable the Terminal Logger: Pass --tl:off to fall back to the classic logger, which shows all tool output:

    dotnet build --tl:off
    

This is particularly useful when debugging OpenAPI document generation issues.

Main Types

The main types provided by this library are:

  • OpenApiOptions: Options for configuring OpenAPI document generation.
  • IDocumentTransformer: Transformer that modifies the OpenAPI document generated by the library.

Feedback & Contributing

Microsoft.AspNetCore.OpenApi is released as open-source under the MIT license. Bug reports and contributions are welcome at the GitHub repository.

Product Compatible and additional computed target framework versions.
.NET net11.0 is compatible. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (1.2K)

Showing the top 5 NuGet packages that depend on Microsoft.AspNetCore.OpenApi:

Package Downloads
MassTransit.AspNetCore

MassTransit AspNetCore Support, including Dashboard; MassTransit provides a developer-focused, modern platform for creating distributed applications without complexity.

Umbraco.Cms

Installs Umbraco CMS with all default dependencies in your ASP.NET Core project.

Umbraco.Cms.Api.Common

Contains the bits and pieces that are shared between the Umbraco CMS APIs.

Umbraco.Cms.StaticAssets

Contains the static assets needed to run Umbraco CMS.

Rystem.Api

Rystem.Api helps you to integrate Api Server and Automated Client for Aspect-Oriented programming.

GitHub repositories (323)

Showing the top 20 popular GitHub repositories that depend on Microsoft.AspNetCore.OpenApi:

Repository Stars
microsoft/semantic-kernel
Integrate cutting-edge LLM technology quickly and easily into your apps
jasontaylordev/CleanArchitecture
Clean Architecture Solution Template for ASP.NET Core
JustArchiNET/ArchiSteamFarm
C# application with primary purpose of farming Steam cards from multiple accounts simultaneously.
dotnet/AspNetCore.Docs
Documentation for ASP.NET Core
dotnet/eShop
A reference .NET application implementing an eCommerce site
dodyg/practical-aspnetcore
Practical samples of ASP.NET Core 11, 10, 9, 8.0, 7.0, 6.0, 5.0, 3.1, 2.2, and 2.1,projects you can use. Readme contains explanations on all projects.
AssetRipper/AssetRipper
GUI application to analyze game files
RicoSuter/NSwag
The Swagger/OpenAPI toolchain for .NET, ASP.NET Core and TypeScript.
fullstackhero/dotnet-starter-kit
Production Grade Cloud-Ready .NET 10 Starter Kit (Web API + React Client) with Multitenancy Support, and Clean/Modular Architecture that saves roughly 200+ Development Hours! All Batteries Included.
microsoft/aspire
Aspire is the tool for code-first, extensible, observable dev and deploy.
FastEndpoints/FastEndpoints
A light-weight REST API development framework for ASP.NET 10 and newer.
dotnet/skills
Repository for skills to assist AI coding agents with .NET and C#
ChilliCream/graphql-platform
Welcome to the home of the Hot Chocolate GraphQL server for .NET, the Strawberry Shake GraphQL client for .NET and Nitro the awesome Monaco based GraphQL IDE.
ServiceStack/ServiceStack
Thoughtfully architected, obscenely fast, thoroughly enjoyable web services for all
umbraco/Umbraco-CMS
Umbraco is a free and open source .NET content management system helping you deliver delightful digital experiences.
microsoft/fluentui-blazor
Microsoft Fluent UI Blazor components library. For use with ASP.NET Core Blazor applications
thomhurst/TUnit
A modern, fast and flexible .NET testing framework
martinothamar/Mediator
A high performance implementation of Mediator pattern in .NET using source generators.
oskardudycz/EventSourcing.NetCore
Examples and Tutorials of Event Sourcing in .NET
AIDotNet/OpenDeepWiki
OpenDeepWiki is the open-source version of the DeepWiki project, aiming to provide a powerful knowledge management and collaboration platform. The project is mainly developed using C# and TypeScript, supporting modular design, and is easy to expand and customize.
Version Downloads Last Updated
11.0.0 24,237 11/10/2026
11.0.0-rc.3.26522.148 64,901 10/25/2026
11.0.0-rc.2.26504.105 86,642 10/13/2026
11.0.0-rc.1.26425.128 125,855 9/8/2026
11.0.0-preview.7.26381.103 40,188 8/11/2026
10.0.15 41,155 11/10/2026
10.0.14 3,089,456 10/25/2026
10.0.13 4,231,104 10/13/2026
10.0.12 9,662,661 9/8/2026
10.0.11 9,690,108 8/11/2026
9.0.23 1,970 11/10/2026
9.0.22 55,361 10/25/2026
9.0.21 88,916 10/13/2026
9.0.20 258,762 9/8/2026
9.0.19 222,997 8/11/2026
8.0.34 1,674 11/10/2026
8.0.33 59,077 10/25/2026
8.0.32 84,861 10/13/2026
8.0.31 220,562 9/8/2026
8.0.30 242,326 8/11/2026
Loading failed