You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In several of our projects, our DTOs often times contain properties that (for different reasons) should be exluded from the generated schema. It would be great to have an easy way, e.g. a Nelmio #[IgnoreFromSchema] attribute, to ignore those properties.
Possible solutions not working for us:
Excluding specific properties using Symfony's #[Ignore] attribute as this leads to unintended side effects in other places where the serializer is used
Applying the #[OA\Property(readOnly: true)] property as this still includes the property in the request body schema for a POST endpoint, for example
Additional context
/
The text was updated successfully, but these errors were encountered:
DominicLuidold
changed the title
[Feature]: Optionally exclude route parameters from request body schema automatically
[Feature]: Easy way to ignore properties from schema generation without relying on Symfony's #[Ignore] attribute
Jun 24, 2024
Description
In several of our projects, our DTOs often times contain properties that (for different reasons) should be exluded from the generated schema. It would be great to have an easy way, e.g. a Nelmio
#[IgnoreFromSchema]
attribute, to ignore those properties.Possible solutions not working for us:
#[Ignore]
attribute as this leads to unintended side effects in other places where the serializer is used#[OA\Property(readOnly: true)]
property as this still includes the property in the request body schema for aPOST
endpoint, for exampleAdditional context
/
The text was updated successfully, but these errors were encountered: