Custom service validtor client data
How to create custom service and register a JOI validator?
When you create a mongoose service with createModelFromJoi() we set your JOI schema inside the app and then we find this instance from validateSchema hook, if you create a new custom service and don't use createModelFromJoi() then use setJoiInstance(app, serviceName, joiSchema)
setJoiInstance most to come before services.configureServices(app);
joiSchema example
Last updated