Open naleczynskia opened 4 years ago
š Thanks for opening this issue! š· I have applied any labels matching special text in your issue.
The team will review the labels and make any necessary changes.
Encountering the same bug: ...requestBody.content.encoding.contentType is missing
Specifying a content type should not be required if default one is ok. It is a valid spec without it.
The defaults are listed here: https://swagger.io/docs/specification/describing-request-body/multipart-requests/ (nicer formatting)
or first description table cell in official OpenAPI spec.
This may be related https://github.com/domaindrivendev/Swashbuckle.AspNetCore/issues/1820
Description
Validation fails when multipart request description contains encoding without contentType.
Using openapi-generator-cli@1.0.12-4.3.0
OpenAPI declaration file content or url
Command line used for generation
openapi-generator generate -i swagger.json -g typescript-redux-query -o src/openapi-client
Steps to reproduce
Suggest a fix
After removing the encoding element entirely, validation passes. It should be possible to specify encoding without content type in this context.