Skip to content
This repository has been archived by the owner on Jun 3, 2023. It is now read-only.

SwaggerAuthorize

Jussi Saarivirta edited this page Feb 16, 2019 · 2 revisions

SwaggerAuthorizeAttribute

Annotation for different kinds of authorization. NOTE: Annotation only! By itself does not secure the method in any way!

Sample usage:

[SwaggerAuthorize(AuthScheme.QueryApiKey)]
[FunctionName("SwaggerAuthorizeAttribute3")]
public static async Task<IActionResult> SwaggerAuthorizeAttribute3(
    [HttpTrigger(AuthorizationLevel.Anonymous, "get", Route = null)] HttpRequest req,
    ILogger log)
{
    return new OkResult();
}