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

[OpenAPI] Add securitySchemes #3197

Open
lcawl opened this issue Nov 29, 2024 · 1 comment
Open

[OpenAPI] Add securitySchemes #3197

lcawl opened this issue Nov 29, 2024 · 1 comment

Comments

@lcawl
Copy link
Contributor

lcawl commented Nov 29, 2024

🚀 Feature Proposal

The OpenAPI documents are missing securitySchemes and security declarations.

They could perhaps be added similarly to the info in https://github.com/elastic/elasticsearch-specification/blob/main/compiler/src/steps/add-info.ts

NOTE: I believe that you could have the same list of securitySchemes for both documents, but the security list for the serverless document would not include basicAuth.

Motivation

Relates to elastic/docs-content#192

Example

In the Kibana openAPI document, it looks like this:

security:
  - apiKeyAuth: []
  - basicAuth: []

...

  securitySchemes:
    apiKeyAuth:
      description: |
        These APIs use key-based authentication. You must create an API key and use the encoded value in the request header. For example: `Authorization: ApiKey base64AccessApiKey`
      in: header
      name: Authorization
      type: apiKey
    basicAuth:
      scheme: basic
      type: http
@lcawl
Copy link
Contributor Author

lcawl commented Nov 29, 2024

As a work-around I've created #3198

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

1 participant