I'm trying to get my schema to work but using a top level allOf seem to cause a "request body schema is not an object schema" error in the end points their used in.
schemas:
SomeName:
allOf:
- $ref: "#/components/schemas/Ref1"
- $ref: "#/components/schemas/Ref2"
cause an error
schemas:
SomeName:
type: object
properties:
some_property:
type: array
items:
allOf:
- $ref: "#/components/schemas/Ref1"
- $ref: "#/components/schemas/Ref2"
required:
- some_property
works just fine
schemas:
SomeName:
oneOf:
- $ref: "#/components/schemas/Ref1"
- $ref: "#/components/schemas/Ref2"
also works fine
EDIT:
schemas:
SomeName:
type: object
properties:
allOf:
- $ref: "#/components/schemas/Ref1"
- $ref: "#/components/schemas/Ref2"
and this results in an internal server error