24 lines
482 B
C#
24 lines
482 B
C#
namespace SchengenVisaApi;
|
|
|
|
/// Provides methods for configuring middleware
|
|
public static class PipelineRequest
|
|
{
|
|
/// Configure middleware
|
|
public static WebApplication ConfigurePipelineRequest(this WebApplication app)
|
|
{
|
|
app.UseSwagger()
|
|
.UseSwaggerUI();
|
|
|
|
app.UseStatusCodePages();
|
|
|
|
app.UseCors("policy");
|
|
|
|
app.UseAuthentication()
|
|
.UseAuthorization();
|
|
|
|
app.MapControllers();
|
|
|
|
return app;
|
|
}
|
|
}
|