Skip to content

Add global security annotation #1453

@cwansart

Description

@cwansart

Is your feature request related to a problem? Please describe.
Our API is always using authentication for all routes, so we want to use global security definition described in https://swagger.io/docs/specification/2-0/authentication/basic-authentication/

Describe the solution you'd like
I want to add
// @Security BasicAuth
somewhere central (beneath // @securityDefinitions.basic BasicAuth?)
so that

security:
  - basicAuth: []

gets added to the root resulting json/yaml file.

Describe alternatives you've considered
So far I had to add // @Security BasicAuth to every @router element.

Additional context
Not much else to show I guess.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions