Using settings in custom security scheme:


#1

I am trying use a custom security scheme that needs arguments at usage:
eg:

  /users:
    get:
      securedBy: [jwt: {permissions: ['user:read']}]

But there seems to be no way to declare that this scheme should allow ‘permissions’.

The scheme is defined as:

securitySchemes:
  jwt:
    type: x-vi-auth
    description:
      Vimana aquired JWT
    describedBy:
      headers:
        Authorization:
          type: string
          description: The JWT token, eg 'bearer ad4839cf-3adfafz-JJDND'

      responses:
        401:
          description: |
              Bad or expired token. This can happen if the user or Vimana
              revoked or expired an access token. To fix, re-authenticate
              the user.

#2

Did you find a solution to this problem? I have the same question.