JSON-Schema API
OAI/OpenAPI-Specification#1548
- JSON-Schema.
additionalProperties
defaults totrue
. - OpenAPI 2.0.
additionalProperties
defaults tofalse
. - OpenAPI 3.0.2. "Consistent with JSON Schema,
additionalProperties
defaults totrue
." https://github.com/OAI/OpenAPI-Specification/blob/v3.0.2-dev/versions/3.0.2.md
A simplified version of OpenAPI can introduce a global configuration field additionalProperties
.
A strict version of OpenAPI should require the additionalProperties
property if type is object
.
if Schema
defines a default value then a validation step may produce a value of type which has no undefined
values. For example
interface A {
a?: string
}
transforms into
interface A {
a: string
}