Comparison with OpenAPI Specification in regards to inheritance / polymorphism



My intention is not to start a flame war, but rather to understand the differences between RAML and OpenAPI specification, specifically with respect to polymorphism and inheritance.

I started working on some documentation with SwaggerUI / OpenAPI spec, but moved over to RAML.

I have been following a github topic:

I’m curious, how would one implement the most recent question there in RAML?

AKA a survey type application with multiple Questions each of which have a QuestionType which defines the schema it must conform to?

This is the best example of a use case I can find to compare the two, and it is simple to understand.


What is your question exactly?

I’m not familiar with swagger, but the gist of the issue you linked to seems to be that they have decided to only support a subset of json schema for whatever reason (specifically, clauses like “oneOf” are not supported).

This limitation does not exist with RAML, which allows any valid json schema to be used.