![]() ![]() Public void Apply(Operation operation, SchemaRegistry schemaRegistry, ApiDescription apiDescription)ĭescription = "The authorization = "header", / Adds an authorization header to the given operation in Swagger. public class AddAuthorizationHeader : IOperationFilter ![]() In this example, we make the header parameter required on every operation, but make it optional on operations that have the AllowAnonymous attribute. According to your code, operations will be checked according to your filters. OperationFilters are executed on every API operation every time you build Swagger. I also wanted to add the header parameters to the Swagger UI website. We ran into the same problem on our project. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. Archives
March 2023
Categories |