Skip to content
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

Support oneOf for Schema Objects #113

Open
IntegrationMike opened this issue Oct 16, 2019 · 0 comments
Open

Support oneOf for Schema Objects #113

IntegrationMike opened this issue Oct 16, 2019 · 0 comments

Comments

@IntegrationMike
Copy link

IntegrationMike commented Oct 16, 2019

Open API now supports oneOf, though only for schema objects, however dapper does not appear to support it even for schemas

OpenAPI 3.0:
https://swagger.io/docs/specification/data-models/oneof-anyof-allof-not/

When I mimic that format:

"responses": {
  "200": {
    "description":"Text",
    "schema": {
      "oneOf":[
        {
          "$ref": "http://localhost:3123/definitions.json#/definitions/allowedParameters"
        },
        {
          "$ref": "http://localhost:3123/definitions.json#/definitions/calculatedPayment"
        }
      ]
    }
  },
}

I get
Error: POST /api/vehicles/allowedParameters references a model definition that does not have a title member.

I'm sure this has been asked before, but I have often wondered by dapperdox insists that I use the key "definitions" instead of "schemas" so if someone could explain that to me as well that would be wonderful :D

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant