Bielu.AspNetCore.AsyncApi
1.0.0
Prefix Reserved
dotnet add package Bielu.AspNetCore.AsyncApi --version 1.0.0
NuGet\Install-Package Bielu.AspNetCore.AsyncApi -Version 1.0.0
<PackageReference Include="Bielu.AspNetCore.AsyncApi" Version="1.0.0" />
<PackageVersion Include="Bielu.AspNetCore.AsyncApi" Version="1.0.0" />
<PackageReference Include="Bielu.AspNetCore.AsyncApi" />
paket add Bielu.AspNetCore.AsyncApi --version 1.0.0
#r "nuget: Bielu.AspNetCore.AsyncApi, 1.0.0"
#:package Bielu.AspNetCore.AsyncApi@1.0.0
#addin nuget:?package=Bielu.AspNetCore.AsyncApi&version=1.0.0
#tool nuget:?package=Bielu.AspNetCore.AsyncApi&version=1.0.0
About
Bielu.AspNetCore.AsyncApi is a NuGet package that provides built-in support for generating AsyncAPI documents from minimal or controller-based APIs in ASP.NET Core.
This project is based on and inspired by:
- Saunter - The original AsyncAPI documentation generator for .NET
- Microsoft.AspNetCore.OpenApi - Microsoft's OpenAPI implementation that inspired the API design
- ByteBard.AsyncAPI.NET - AsyncAPI schema and serialization
Key Features
- Serves the generated document at runtime from a parameterized endpoint (
/asyncapi/{documentName}.jsonor.yaml) - Emits AsyncAPI 2.6 or 3.1, selected per document
- Generates the document at build time, so it can be committed and diffed in CI
- Customizable via document, operation and schema transformers
- Protocol bindings (AMQP, HTTP, MQTT, Kafka, …), plus first-party SignalR, gRPC, SSE and WebRTC bindings
- Multiple AsyncAPI documents from a single application
- Descriptions from XML doc comments, and message examples
- Native AOT and trimming support via a source-generated metadata provider
How to Use
To start using Bielu.AspNetCore.AsyncApi in your ASP.NET Core application, follow these steps:
Installation
dotnet add package Bielu.AspNetCore.AsyncApi
Configuration
In your Program.cs file, register the services provided by this package in the DI container and map the provided AsyncAPI document endpoint in the application.
var builder = WebApplication.CreateBuilder();
// Registers the required services
builder.Services.AddAsyncApi(options =>
{
options.AddServer("mosquitto", "test.mosquitto.org", "mqtt");
options.WithDefaultContentType("application/json")
.WithDescription("My API Description");
});
var app = builder.Build();
// Adds the /asyncapi/{documentName}.json endpoint to the application
app.MapAsyncApi();
app.Run();
Viewing the Documentation
The library serves a standard AsyncAPI document at /asyncapi/{documentName}.json, so you can render it with any AsyncAPI-compatible UI. We recommend Scalar, which renders AsyncAPI channels, operations, messages, and schemas alongside your OpenAPI references:
dotnet add package Scalar.AspNetCore
app.MapAsyncApi();
app.MapScalarApiReference(options =>
{
options.AddAsyncApiDocument("v1", "My API", "/asyncapi/v1.json");
});
Note: Scalar's AsyncAPI support is still evolving; not every part of the specification is rendered yet.
Main Types
The main types provided by this library are:
AsyncApiOptions: Options for configuring AsyncAPI document generation.IDocumentTransformer: Transformer that modifies the AsyncAPI document generated by the library.ISchemaTransformer: Transformer that modifies generated schemas.
Related Packages
- Bielu.AspNetCore.AsyncApi.Attributes — attributes for defining channels, operations and messages
- Bielu.AspNetCore.AsyncApi.Cli —
dotnet asyncapi(generate, validate, diff, merge) - Bielu.AspNetCore.AsyncApi.Templates —
dotnet newproject templates - Bielu.AspNetCore.AsyncApi.Versioning — one document per API version
- Bielu.AspNetCore.AsyncApi.Overlay — apply OpenAPI Overlays in the generation pipeline
- Bielu.AspNetCore.AsyncApi.Merger — merge documents from several services
- Protocol bindings: SignalR, gRPC, SSE, WebRTC
- Interactive consoles: Scalar.SignalR, Scalar.Grpc
Feedback & Contributing
Bielu.AspNetCore.AsyncApi is released as open-source under the MIT license. Bug reports and contributions are welcome at the GitHub repository.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- Bielu.AspNetCore.AsyncApi.Attributes (>= 1.0.0)
- ByteBard.AsyncAPI.NET (>= 3.0.1)
NuGet packages (9)
Showing the top 5 NuGet packages that depend on Bielu.AspNetCore.AsyncApi:
| Package | Downloads |
|---|---|
|
Bielu.AspNetCore.AsyncApi.UI
[DEPRECATED] Built-in AsyncAPI UI for Bielu.AspNetCore.AsyncApi. This package is deprecated — render the AsyncAPI document with Scalar instead (Scalar.AspNetCore + MapScalarApiReference), optionally with Bielu.AspNetCore.AsyncApi.Scalar.SignalR / .Scalar.Grpc for interactive protocol consoles. |
|
|
Bielu.AspNetCore.AsyncApi.Merger
Tool for merging multiple AsyncAPI documents into a single unified specification. Supports local and remote sources with caching and change detection. |
|
|
Bielu.AspNetCore.AsyncApi.Extensions.Protocols.SignalR
SignalR protocol bindings for Bielu.AspNetCore.AsyncApi. Adds a custom "signalr" AsyncAPI protocol with channel, operation, message and server bindings. |
|
|
Bielu.AspNetCore.AsyncApi.Extensions.Protocols.Grpc
gRPC protocol bindings for Bielu.AspNetCore.AsyncApi. Adds a custom "grpc" AsyncAPI protocol with channel, operation, message and server bindings. |
|
|
Bielu.AspNetCore.AsyncApi.Extensions.Protocols.Sse
Server-Sent Events (SSE) protocol bindings for Bielu.AspNetCore.AsyncApi. Adds a custom "sse" AsyncAPI protocol with channel, operation, message and server bindings. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.0.0 | 186 | 8/2/2026 |
| 1.0.0-beta.639212611648129867 | 69 | 8/2/2026 |
| 1.0.0-beta.639212599446238423 | 80 | 8/2/2026 |
| 1.0.0-beta.639212120718910090 | 86 | 8/1/2026 |
| 1.0.0-beta.639212076260211021 | 83 | 8/1/2026 |
| 1.0.0-beta.639212044042877584 | 90 | 8/1/2026 |
| 1.0.0-beta.639209220947418460 | 112 | 7/29/2026 |
| 1.0.0-beta.639209066819502286 | 76 | 7/29/2026 |
| 1.0.0-beta.639208696856244784 | 80 | 7/28/2026 |
| 1.0.0-beta.639207351003116057 | 86 | 7/27/2026 |
| 1.0.0-beta.639207338242555809 | 81 | 7/27/2026 |
| 1.0.0-beta.639203173131792988 | 126 | 7/22/2026 |
| 1.0.0-beta.639203162467618196 | 75 | 7/22/2026 |
| 1.0.0-beta.639203031360907880 | 73 | 7/22/2026 |
| 1.0.0-beta.639203020568560427 | 70 | 7/22/2026 |
| 1.0.0-beta.639203013842046086 | 67 | 7/22/2026 |
| 1.0.0-beta.639200918818601177 | 549 | 7/19/2026 |
| 1.0.0-beta.639200865823940136 | 85 | 7/19/2026 |
| 1.0.0-beta.639200669692946724 | 76 | 7/19/2026 |
| 1.0.0-beta.639197837648052351 | 250 | 7/16/2026 |