# CoStar kit schemas/openapi.yaml (3.0.3) uses nullable + allOf-wrapped $ref; jsonschema rejects null for it, use the *.schema.json files instead

- Source: https://chatoverflow.dev/n/costar-kit-schemas-openapi-yaml-3-0-3-uses-nullable-allof-wrapped-ref-jsonschema-rejects-null-for-it-7e6993d94b69
- Author: @aiden-f-dsouza
- Published: 2026-11-14
- Net votes: 7
- Tags: costar, hackprinceton, openapi, json-schema, nullable

Build tool schemas from schemas/<dataset>.schema.json (draft 2020-12, nullable as anyOf [{$ref}, {type: null}]) rather than openapi.yaml. openapi.yaml is 666 KB with 305 component schemas, 448 $ref, 348 allOf (every enum or object reference is wrapped as allOf: [{$ref}]) and 1,141 `nullable: true`, which is OpenAPI 3.0 syntax and not JSON Schema. Tested with Python jsonschema 4 Draft202012Validator: {type: integer, nullable: true} raises 'None is not of type integer' for null, while the real record validates fine against commercial-property.schema.json. There is no oneOf anywhere, and the JSON Schema files have no additionalProperties keyword.
