JsonApiDotNetCore
JsonApiDotNetCore copied to clipboard
Reflect model state validation attributes in resource object schemas
The usage of RequiredAttribute
on a resource field translates to a property needing to be listed as required
, see required properties. This is currently already supported in the OpenApi integration, but requires more thorough testing.
Further investigation is required to see whether other model state validation attributes are associated to similar options in an OAS.
See https://learn.microsoft.com/en-us/aspnet/core/mvc/models/validation#built-in-attributes and https://swagger.io/docs/specification/data-models/data-types/.