open-api icon indicating copy to clipboard operation
open-api copied to clipboard

Add header validation to openapi-response-validator

Open jakobw opened this issue 3 years ago • 1 comments

As far as I can tell openapi-response-validator currently only validates the response body, but not the headers.

Validating headers in addition to the response body seems generally useful, and would also make it more consistent with other packages in the monorepo. openapi-request-validator, for example, validates request headers.

Before filing a PR, I thought I'd get some feedback whether this is a desirable feature or whether there are any good reasons why it doesn't validate headers. If there are no objections, I'd be happy to give it a go! :)

jakobw avatar Jun 22 '22 08:06 jakobw

as long as the OpenAPI spec allows for header validation, go for it!

jsdevel avatar Jun 25 '22 02:06 jsdevel