Static Typing vs Runtime Validation: TypeScript vs Zod
TypeScript checks source code during development but its types are erased at runtime. External JSON can still violate an interface after the application is built.
Zod schemas inspect runtime values and can produce a TypeScript type with z.infer. Generated schemas are a starting point: review constraints, coercion, dates, formats, discriminators and API-version behavior.