Extension Field Registry
x-jsonschema-unevaluatedProperties - The JSON Schema unevaluatedProperties keyword, used when targeting OpenAPI versions that do not directly support it.
JSON Schema 2019-09 introduced the unevaluatedProperties keyword to apply a schema to object properties not already evaluated by adjacent keywords.
The x-jsonschema-unevaluatedProperties extension mirrors the JSON Schema unevaluatedProperties keyword by serializing it as x-jsonschema-unevaluatedProperties when targeting OpenAPI versions where unevaluatedProperties is not directly available.
Use this extension only with JSON Schema versions before 2019-09; 2019-09 and later define unevaluatedProperties directly.
It can appear as a property in the following objects: ["Schema Object"].
Used by: (informational)
- Microsoft.OpenApi (.NET OpenAPI library)
Schema
{"oneOf"=>[{"type"=>"boolean"}, {"$ref"=>"#/$defs/schemaObject"}]}
Example
openapi: 3.0.4
info:
title: My API
version: 1.0.0
paths: {}
components:
schemas:
ExtensibleResource:
type: object
patternProperties:
^x-: true
Invoice:
type: object
allOf:
- $ref: '#/components/schemas/ExtensibleResource'
properties:
id:
type: string
total:
type: number
format: double
x-jsonschema-unevaluatedProperties: false