Skip to content

Add QueryString documentation when using TransferObject with @ModelAttribute as single argument #3029

Discussion options

You must be logged in to vote

I believe a possible approach could be to introduce a meta-annotation similar to the one introduced here, and then make it carry a number of annotations that describe the query parameters that you have (and you could probably make the annotation take an argument, so you could controller the required value for each annotation?).

The annotation that I am thinking of would be:

@Parameter(name = "queryValue", in = ParameterIn.QUERY, example = "1", schema = @Schema(type = "number"))

from swagger annotations.

Replies: 1 comment 7 replies

Comment options

You must be logged in to vote
7 replies
@angelomarzocchi
Comment options

@Mattias-Sehlstedt
Comment options

Answer selected by angelomarzocchi
@Mattias-Sehlstedt
Comment options

@angelomarzocchi
Comment options

@Mattias-Sehlstedt
Comment options

@angelomarzocchi
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants