ErrorApi.Swashbuckle
1.0.1
dotnet add package ErrorApi.Swashbuckle --version 1.0.1
NuGet\Install-Package ErrorApi.Swashbuckle -Version 1.0.1
<PackageReference Include="ErrorApi.Swashbuckle" Version="1.0.1" />
<PackageVersion Include="ErrorApi.Swashbuckle" Version="1.0.1" />
<PackageReference Include="ErrorApi.Swashbuckle" />
paket add ErrorApi.Swashbuckle --version 1.0.1
#r "nuget: ErrorApi.Swashbuckle, 1.0.1"
#:package ErrorApi.Swashbuckle@1.0.1
#addin nuget:?package=ErrorApi.Swashbuckle&version=1.0.1
#tool nuget:?package=ErrorApi.Swashbuckle&version=1.0.1

ErrorApi.Swashbuckle
The Swagger road to ErrorApi documents — and the road for .NET 8/9, where the built-in OpenAPI pipeline predates Microsoft.OpenApi 2.x.
dotnet add package ErrorApi.Swashbuckle
ErrorApi works out at compile time which errors every endpoint can return. On .NET 10 the built-in OpenAPI pipeline documents them via an operation transformer; this package does the identical job for Swashbuckle documents — same responses, same schemas, same examples, because both compile the one shared response builder. Use it when you are on net8/net9, or whenever your project stays on Swagger.
Setup
builder.Services.AddErrorApi(); // the compile-time model, as always
builder.Services.AddSwaggerGen(c => c.AddErrorApiResponses()); // the document half, via Swashbuckle
That is the whole hookup. Every endpoint the generator matched gains its error responses:
application/problem+json, the code enum listing exactly the reachable codes, and one example per
code — byte-identical to what the .NET 10 transformer writes.
What fills the responses
The same IErrorApiMetadata the rest of ErrorApi runs on: the generated, reflection-free model of
your catalog and endpoints. The filter resolves it from DI, looks the operation up by normalized
route + method + API description group, and writes one response per status.
Full documentation
github.com/SideswipeN7/ErrorApi — how discovery works, the
EAPI001–EAPI013 diagnostics, the TypeScript contract, and the result-library adapters.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 is compatible. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. 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
- ErrorApi.AspNetCore (>= 1.0.1)
- Microsoft.AspNetCore.OpenApi (>= 10.0.11)
- Swashbuckle.AspNetCore.SwaggerGen (>= 10.2.3)
-
net8.0
- ErrorApi.AspNetCore (>= 1.0.1)
- Swashbuckle.AspNetCore.SwaggerGen (>= 10.2.3)
-
net9.0
- ErrorApi.AspNetCore (>= 1.0.1)
- Swashbuckle.AspNetCore.SwaggerGen (>= 10.2.3)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on ErrorApi.Swashbuckle:
| Package | Downloads |
|---|---|
|
ErrorApi
The one-package start for ErrorApi: the source generator, the Error/Result primitives and the ASP.NET Core integration in a single install — plus the Swashbuckle filter on .NET 8/9, where the built-in OpenAPI pipeline cannot carry the transformer. Add this package, declare a catalog, call AddErrorApi(). Reach for the individual ErrorApi.* packages only when composing a custom setup. |
GitHub repositories
This package is not used by any popular GitHub repositories.