BlackSheep icon indicating copy to clipboard operation
BlackSheep copied to clipboard

Exclude Acccept, Content-type and Authorization header from OpenAPI docs

Open ticapix opened this issue 1 month ago • 0 comments

Hello,

Based on the OpenAPI specs, some headers are not supposed to be listed directly as parameters https://swagger.io/docs/specification/describing-parameters/#header-parameters

From the doc here https://www.neoteroi.dev/blacksheep/binders/#built-in-binders, the Accept header will generate the following openapi.json content which is invalid according to the OpenAPI specs.

The warning message comes from the swagger tool.

image

The proposal is to exclude the content-type, accept, authorization header from the parameters configuration.

Best regards, Pierre

ticapix avatar Jun 26 '24 11:06 ticapix