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
I have 2 endpoints that differ only by the media type they consume. From #71 I understand that this kind of scenario is well supported by springdoc-openapi. I use the latest 1.4.0 version on springdoc-openapi.
Indeed, looking in the generated swagger-ui I see the /search operation with a select box containing the 2 media types, which is what I wanted to get.
However, because I have a configuration that adds 2 header parameters to every operation, for the above /search endpoint I will have the 2 header parameters duplicated in the generated docs.
The Operation type from swagger-api contains a List<Parameter> (And not a Set) which explains the behaviour your are facing.
OperationCustomizer is called just after operation processing is finished, and for each operation (search, searchByFile) tjhe parameters are concatenated inside the List.
Hi,
I have 2 endpoints that differ only by the media type they consume. From #71 I understand that this kind of scenario is well supported by springdoc-openapi. I use the latest 1.4.0 version on springdoc-openapi.
Indeed, looking in the generated swagger-ui I see the /search operation with a select box containing the 2 media types, which is what I wanted to get.
However, because I have a configuration that adds 2 header parameters to every operation, for the above /search endpoint I will have the 2 header parameters duplicated in the generated docs.
This is how the generated json looks like:
Is this a known issue? Am I missing something?
Thank you!
The text was updated successfully, but these errors were encountered: