Enigmatry.Entry.Swagger 9.4.0

dotnet add package Enigmatry.Entry.Swagger --version 9.4.0
                    
NuGet\Install-Package Enigmatry.Entry.Swagger -Version 9.4.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="Enigmatry.Entry.Swagger" Version="9.4.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Enigmatry.Entry.Swagger" Version="9.4.0" />
                    
Directory.Packages.props
<PackageReference Include="Enigmatry.Entry.Swagger" />
                    
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 Enigmatry.Entry.Swagger --version 9.4.0
                    
#r "nuget: Enigmatry.Entry.Swagger, 9.4.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 Enigmatry.Entry.Swagger@9.4.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=Enigmatry.Entry.Swagger&version=9.4.0
                    
Install as a Cake Addin
#tool nuget:?package=Enigmatry.Entry.Swagger&version=9.4.0
                    
Install as a Cake Tool

Swagger Security

This library provides security enhancements for Swagger/OpenAPI documentation in ASP.NET Core applications.

Intended Usage

Use this library to add security features to your Swagger documentation, such as authentication requirements, API key configuration, and endpoint access control.

Installation

Add the package to your project:

dotnet add package Enigmatry.Entry.Swagger

Usage Example

using Enigmatry.Entry.Swagger;
using Microsoft.AspNetCore.Builder;
using Microsoft.Extensions.DependencyInjection;
using NSwag.Generation.AspNetCore;
using System.Collections.Generic;

public class Startup
{
    public void ConfigureServices(IServiceCollection services)
    {
        // Add Swagger with OAuth 2.0 Authorization Code flow
        services.AddEntrySwaggerWithAuthorizationCode(
            appTitle: "My API",
            authorizationUrl: "https://auth.example.com/authorize",
            tokenUrl: "https://auth.example.com/token",
            scopes: new Dictionary<string, string>
            {
                { "api", "API access" },
                { "openid", "OpenID" },
                { "profile", "Profile information" }
            },
            appVersion: "v1",
            configureSettings: settings =>
            {
                // Configure additional Swagger document settings
                settings.Description = "API with OAuth2 security";
                
                // You can add custom schema processors if needed
                settings.SchemaSettings.SchemaNameGenerator = new CustomSwaggerSchemaNameGenerator();
            });
    }
    
    public void Configure(IApplicationBuilder app)
    {
        // Enable Swagger UI with OAuth2 client integration
        app.UseEntrySwaggerWithOAuth2Client(
            clientId: "swagger-ui-client",
            clientSecret: "",  // Optional client secret
            path: "/api-docs"
        );
    }
}
Product Compatible and additional computed target framework versions.
.NET 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 was computed.  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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
9.4.0 514 12/22/2025
9.3.1-preview.3 252 12/18/2025
9.3.1-preview.1 465 11/25/2025
9.3.0 564 11/10/2025
9.2.0 1,310 9/24/2025
9.1.1-preview.5 200 8/8/2025
9.1.1-preview.4 117 6/27/2025
9.1.1-preview.3 152 6/4/2025
9.1.0 1,259 6/3/2025
9.0.1-preview.8 152 5/26/2025
9.0.1-preview.7 235 5/13/2025
9.0.1-preview.6 389 5/9/2025
9.0.1-preview.5 183 5/7/2025
9.0.1-preview.4 154 4/30/2025
9.0.1-preview.2 159 4/1/2025
9.0.0 1,519 2/26/2025
8.3.1-preview.1 134 12/24/2025
8.3.0 274 12/23/2025
8.2.0 473 9/24/2025
8.1.1-preview.3 142 5/7/2025
8.1.1-preview.1 162 4/1/2025
8.1.0 772 2/19/2025
8.0.1-preview.4 104 2/7/2025
8.0.1-preview.2 87 1/15/2025
8.0.0 1,238 11/27/2024
3.4.6-preview.10 99 11/27/2024
3.4.3 2,150 10/22/2024
3.4.2 800 10/11/2024
3.4.1 206 10/9/2024
3.4.0 185 10/9/2024
3.3.2 556 8/28/2024
3.3.2-preview.7 117 8/27/2024
3.3.1 489 7/16/2024
3.3.1-preview.4 109 7/12/2024
3.3.0 1,172 6/20/2024
3.2.1-preview.4 98 6/17/2024
3.2.1-preview.1 101 5/23/2024
3.2.0 3,995 4/3/2024
3.1.1-preview.1 1,076 3/13/2024
3.1.0 434 3/8/2024
3.1.0-preview.2 461 2/19/2024
3.0.1-preview.2 1,180 2/9/2024
3.0.1-preview.1 115 1/24/2024
3.0.0 1,339 1/15/2024
3.0.0-preview.14 149 1/9/2024
3.0.0-preview.12 105 1/9/2024
3.0.0-preview.5 112 1/10/2024
3.0.0-preview.2 181 12/28/2023
3.0.0-preview 205 12/20/2023
2.1.0 280 12/28/2023
2.0.1-preview.3 136 12/1/2023
2.0.1-preview.2 120 11/29/2023
2.0.1-preview.1 112 11/28/2023
2.0.0 536 11/8/2023
2.0.0-preview.3 491 10/27/2023
2.0.0-preview.2 117 10/27/2023
2.0.0-preview.1 117 10/27/2023
2.0.0-preview 187 10/27/2023
1.1.500 240 10/27/2023
1.1.495 290 9/24/2023
1.1.486 526 9/13/2023
1.1.484 291 9/7/2023
1.1.482 245 9/6/2023
1.1.480 361 8/24/2023
1.1.477 258 8/2/2023
1.1.464 278 7/5/2023
1.1.447 1,239 5/26/2023
1.1.396 459 4/11/2023
1.1.383 385 4/3/2023
1.1.377 374 3/13/2023
1.1.376 351 3/13/2023
1.1.365 1,109 2/15/2023