swagger-core
swagger-core copied to clipboard
Defining grouping in swagger
Defining grouping in swagger endpoints to reduce the challenges brought in creating a per class request models in huge system for better maintainability and for less class redundancy.
This change will support many open and unanswered issues
https://github.com/springdoc/springdoc-openapi/issues/510 https://github.com/springdoc/springdoc-openapi/issues/1374 https://github.com/springdoc/springdoc-openapi/issues/1568 https://stackoverflow.com/questions/71921999/java-annotation-based-validation-io-swagger-v3-oas-annotations-media-schema https://stackoverflow.com/questions/44506965/jax-rs-group-validation-not-recognized-by-swagger-jax-rs-version-1-5-12 https://stackoverflow.com/questions/61461679/how-to-apply-constraints-with-javax-validation-constraints-groups-from-swagger-w https://stackoverflow.com/questions/59477719/swagger-spring-boot-how-to-set-the-example-value-to-be-passed-in-the-api-base https://community.smartbear.com/t5/Swagger-Open-Source-Tools/Support-validation-groups-when-reading-Java-annotations/td-p/199556 https://community.smartbear.com/t5/Swagger-Open-Source-Tools/Grouping-Schemas/m-p/201738 https://community.smartbear.com/t5/Swagger-Open-Source-Tools/How-to-generate-docs-for-api-under-particular-group/m-p/197721
That Pull-Request would be SO helpful as it fixes a major bug (and thus lot of issues). I was so happy when I saw it, and I am watching it for 4months now, but sadly it never gets approved :( How could we fasten the approval of the PR :) ?
I'm waiting on this too - it's maddening. I have a model class like this:
@Schema(description = "Unique ksuid for this Event - returned on submission.", required = false)
@NotEmpty(groups = {EventConsumerValidations.class})
@Builder.Default
private Optional<String> id = Optional.empty();
The idea is we want the validation after the object has been created with an id and not to have a client pass one in. I've tried required = false, I've tried a distinct @Schema annotation on the controller method that specifically omits that id field from the requiredProperties attribute. It's a huge omission. What is the hold-up with this PR?
I'm also looking forward to this.
Any updates on this PR? Is there something I can assist with to get this merged?
Any updates?
Do you have any updates on this? Can I help with something in order to merge this? We really need this functionality.
Thank you in advance
Any updates?
This is a crucial functionality that would help many of us. If there is anything that needs to be done before merging this PR, I propose for Maintainers to write the additional requirements.
I also find this very useful as it reduces unnecessary explanations. This is an example I created based on version 1.7.0 and using another project that beautifies the page. I hope the native project will support this feature soon. knife4j-group, knife4j