AJV is an excellent way to generate data validation code starting from JSON Schema's. OpenAPI specifications build on JSON Schema's. The openapi-ts project can generate JSON Schema's from OpenAPI specs. To close the loop, the task is to ensure those schema's are usable by AJV.
Description
AJV is an excellent way to generate data validation code starting from JSON Schema's. OpenAPI specifications build on JSON Schema's. The openapi-ts project can generate JSON Schema's from OpenAPI specs. To close the loop, the task is to ensure those schema's are usable by AJV.
The goal is similar to the Zod request -- https://github.com/hey-api/openapi-ts/issues/876 -- Which is autogeneration of data validation from an OpenAPI spec.
It seems to me AJV is a more direct ask since OpenAPI is so close to JSON Schema.