-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
discriminator does not support allOf #187
Comments
@wcloete Thank you for your report, but I use Ajv under the hood for the validation and it only supports |
@wcloete I just had a closer look at your example again.. Your example is not how the discriminator is supposed to be used (see also the Discriminator-section). If you just want to make a model composition, you don't need the |
Strange, because as I say, I took the schemas almost verbatim from the docs - my only change was to remove The paragraph above the example even says
But as you say, Ajv only supports Thank you for your time, and for a nice library! |
I was about to post an example with a |
I can't promise that this will resolve your issue, but |
Yes, it looks like 2261 covers what I need. I'll keep an eye out for updates too. |
Hi since #185 I have an API that is failing validation. It uses the
discriminator
keyword on the parent definition andallOf
on the children.Example
This was adapted from the OAS documentation for
discriminator
API spec:
Validate with:
Error:
Other info
Version: [email protected]
Operating system: https://hub.docker.com/_/node, image ID acd15857ce39
OpenAPI version: 3.0.3
The text was updated successfully, but these errors were encountered: