Elle est pas belle la vie ?
This commit is contained in:
parent
51dcb39c93
commit
18b67bd725
7 changed files with 41 additions and 4 deletions
|
|
@ -17,6 +17,8 @@ using Unleash;
|
|||
using Microsoft.Extensions.Options;
|
||||
using isnd.Helpers;
|
||||
using Microsoft.IdentityModel.Tokens;
|
||||
using System;
|
||||
using Microsoft.OpenApi.Models;
|
||||
|
||||
namespace isnd
|
||||
{
|
||||
|
|
@ -93,6 +95,24 @@ namespace isnd
|
|||
ValidateAudience = false
|
||||
};
|
||||
});
|
||||
services.AddSwaggerGen(options =>
|
||||
options.SwaggerDoc("v1", new OpenApiInfo
|
||||
{
|
||||
Version = "v1",
|
||||
Title = "ToDo API",
|
||||
Description = "An ASP.NET Core Web API for managing ToDo items",
|
||||
TermsOfService = new Uri("https://isn.pschneider.fr/terms"),
|
||||
Contact = new OpenApiContact
|
||||
{
|
||||
Name = "Example Contact",
|
||||
Url = new Uri("https://isn.pschneider.fr/contact")
|
||||
},
|
||||
License = new OpenApiLicense
|
||||
{
|
||||
Name = "Example License",
|
||||
Url = new Uri("https://isn.pschneider.fr/license")
|
||||
}
|
||||
}));
|
||||
}
|
||||
|
||||
// This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
|
||||
|
|
@ -104,6 +124,8 @@ namespace isnd
|
|||
{
|
||||
app.UseDeveloperExceptionPage();
|
||||
app.UseMigrationsEndPoint();
|
||||
app.UseSwagger();
|
||||
app.UseSwaggerUI();
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue