Netcool.Swashbuckle.AspNetCore
8.0.0
.NET 5.0
This package targets .NET 5.0. The package is compatible with this framework or higher.
.NET Standard 2.0
This package targets .NET Standard 2.0. The package is compatible with this framework or higher.
dotnet add package Netcool.Swashbuckle.AspNetCore --version 8.0.0
NuGet\Install-Package Netcool.Swashbuckle.AspNetCore -Version 8.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="Netcool.Swashbuckle.AspNetCore" Version="8.0.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Netcool.Swashbuckle.AspNetCore --version 8.0.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: Netcool.Swashbuckle.AspNetCore, 8.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.
// Install Netcool.Swashbuckle.AspNetCore as a Cake Addin #addin nuget:?package=Netcool.Swashbuckle.AspNetCore&version=8.0.0 // Install Netcool.Swashbuckle.AspNetCore as a Cake Tool #tool nuget:?package=Netcool.Swashbuckle.AspNetCore&version=8.0.0
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
Netcool.Swashbuckle.AspNetCore
Extensions library for Swashbuckle.AspNetCore.
What's included
CamelCaseQueryStringOperationFilter
Display query string parameters in camel case.
EnumDescriptionDocumentFilter
Display enum descriptions for enum member decorated by DescriptionAttribute.
FileUploadOperationFilter
Put a file upload button for uploading file with content-type:multipart/form-data.
Extension methods
void IncludeAllXmlComments(this SwaggerGenOptions options, bool includeControllerXmlComments = false)
void IncludeXmlComments(this SwaggerGenOptions options, Assembly assembly, bool includeControllerXmlComments = false)
void AddJwtBearerSecurity(this SwaggerGenOptions options)
void InjectHeadContent(this SwaggerUIOptions options, string headContent)
Examples
services.AddSwaggerGen(c =>
{
c.DocumentFilter<EnumDescriptionDocumentFilter>();
c.OperationFilter<CamelCaseQueryStringOperationFilter>();
c.OperationFilter<FileUploadOperationFilter>();
c.IncludeXmlComments(Assembly.GetAssembly(typeof(NetcoolDbContext)));
c.IncludeAllXmlComments();
c.AddJwtBearerSecurity();
});
app.UseSwaggerUI(c =>
{
if (env.IsDevelopment())
{
c.InjectHeadContent(
@"<script async id=""mini-profiler"" src=""/profiler/includes.min.js?v=4.2.22+4563a9e1ab""
data-version=""4.2.22+4563a9e1ab"" data-path=""/profiler/""
data-current-id=""7a3d98bb-3968-41fb-8836-65f9923ee6eb""
data-ids=""7a3d98bb-3968-41fb-8836-65f9923ee6eb""
data-position=""Left"" data-scheme=""Light"" data-authorized=""true"" data-max-traces=""15""
data-toggle-shortcut=""Alt+P"" data-trivial-milliseconds=""2.0""
data-ignored-duplicate-execute-types=""Open,OpenAsync,Close,CloseAsync""></script>");
}
});
[HttpPost("upload")]
[ProducesResponseType(typeof(FileDto), 200)]
[FileUploadOperationFilter.FileContentType]
public async Task<IActionResult> Upload()
{
var fileDto = await UploadMultipart();
return Ok(fileDto);
}
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net5.0 is compatible. net5.0-windows was computed. net6.0 is compatible. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 is compatible. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. 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. |
.NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
.NET Standard | netstandard2.0 is compatible. netstandard2.1 was computed. |
.NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
MonoAndroid | monoandroid was computed. |
MonoMac | monomac was computed. |
MonoTouch | monotouch was computed. |
Tizen | tizen40 was computed. tizen60 was computed. |
Xamarin.iOS | xamarinios was computed. |
Xamarin.Mac | xamarinmac was computed. |
Xamarin.TVOS | xamarintvos was computed. |
Xamarin.WatchOS | xamarinwatchos was computed. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
.NETStandard 2.0
- Swashbuckle.AspNetCore.SwaggerGen (>= 6.5.0)
- Swashbuckle.AspNetCore.SwaggerUI (>= 6.5.0)
-
net5.0
- Swashbuckle.AspNetCore.SwaggerGen (>= 6.5.0)
- Swashbuckle.AspNetCore.SwaggerUI (>= 6.5.0)
-
net6.0
- Swashbuckle.AspNetCore.SwaggerGen (>= 6.5.0)
- Swashbuckle.AspNetCore.SwaggerUI (>= 6.5.0)
-
net7.0
- Swashbuckle.AspNetCore.SwaggerGen (>= 6.5.0)
- Swashbuckle.AspNetCore.SwaggerUI (>= 6.5.0)
-
net8.0
- Swashbuckle.AspNetCore.SwaggerGen (>= 6.5.0)
- Swashbuckle.AspNetCore.SwaggerUI (>= 6.5.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
Support net8.0