openapi-client
openapi-client copied to clipboard
Allow security override of specific endpoints
For an endpoint specified like this:
/pets:
get:
description: Example
security: []
Currently openapi-client still will add security to the endpoint, just because the array exists.
This change removes the security from the operation if an empty array is passed in.
This is discussed a little more here: https://github.com/OAI/OpenAPI-Specification/issues/14
I think this aligns with the spec because if you load a spec into the swagger editor with an endpoint like above, it won't show a lock icon, indicating there should not be auth.
Thanks!