Open Striar-Yunis opened 3 years ago
Probably solved already but, in case someone gets here with the same issue you should use the property "file" instead of "core". like:
requestBody:
required: true
content:
multipart/form-data:
schema:
type: object
properties:
file:
type: string
format: binary
Reproduction
Note: I have created a minimal reproducible example in CodeSandBox. To use this example:
curl -X POST --form 'core=@/home/...YOUR_PATH.../core' https://GET_URL_FROM_ADDRESS_BAR/example
System Description
Issue Description
The validation middleware isn't accepting files that are defined in the OpenAPI yaml. The files are correctly parsed by multer but they are marked as extra.
Swagger
OpenApiValidator Config
Curl
The Error