Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Optional authentication not rendered properly #2117

Closed
arvidfm opened this issue Aug 3, 2022 · 1 comment
Closed

Optional authentication not rendered properly #2117

arvidfm opened this issue Aug 3, 2022 · 1 comment

Comments

@arvidfm
Copy link

arvidfm commented Aug 3, 2022

Describe the bug
The recommended way of representing optional authentication on an endpoint is something like:

security:
  - {}
  - basic: []

Unfortunately this doesn't render properly in Redoc.

Expected behavior
The "authorizations" section of the endpoint documentation should clearly communicate that it is an optionally authenticated endpoint.

Minimal reproducible OpenAPI snippet(if possible)

openapi: 3.1.0
info:
  title: Optional auth
  version: 1.0.0
paths:
  /info:
    get:
      summary: Get info
      operationId: getInfo
      security:
        - {}
        - basic: []

components:
  securitySchemes:
    basic:
      scheme: basic
      type: http

Screenshots
image

image

Additional context
Add any other context about the problem here.

@AlexVarchuk
Copy link
Collaborator

closed via #2134

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants