Could it be possible that the library set default value(s) defined in parameters?
Today, with the version 0.4.4 of the lib. If I use the example below:
/users:
get:
description: |
Returns all users from the referential
operationId: findUsers
parameters:
- name: limit
in: query
description: Number of items to retrieve per page. Default is 5, maximum is 50.
required: false
schema:
type: integer
format: int32
minimum: 1
maximum: 50
default: 5
And this implementation :
const validator = new OpenApiValidator(openApiDocument, {ajvOptions: { coerceTypes: true }});
router.get('/', validator.validate("get", "/users"), function(req, res) {
console.log(req.query); //the object is empty... I expect the param `limit` to be equal to 5
res.send('success');
});
Is this feature is out of scope of the library? Is it a bug?
Hello,
Could it be possible that the library set default value(s) defined in parameters?
Today, with the version
0.4.4
of the lib. If I use the example below:And this implementation :
Is this feature is out of scope of the library? Is it a bug?
Thank you in advance!