-
Notifications
You must be signed in to change notification settings - Fork 1.5k
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
@ApiResponses tag does not override default responses #1887
Comments
You could use the |
Yes, but I was hoping to use that as a last resort since it would require more annotations. |
Could you clarify with an example or may be create a breaking test with how you intend it to work vs. how its working now. Happy to consider a contribution if you think its a feature gap. |
Will do. |
Example: @PostMapping(value = "/lists/{env}/{list-id}/emails", produces = APPLICATION_JSON_UTF8_VALUE, consumes = APPLICATION_JSON_UTF8_VALUE)
@ApiOperation(value = "Add new emails to list", response = MailListEntry.class)
public CompletableFuture<Map<String, List<MailListEntry>>> addEmailsToList(@PathVariable String env, @PathVariable("list-id") String listId, @RequestBody List<String> emails) { But it generates definition:
problem is |
Reading #632 seems to imply that the
@ApiResponses
annotation, if present should override the default response messages . However it looks like that is not the behavior and reading the code/home/ademaria/.m2/repository/io/springfox/springfox-core/2.7.0/springfox-core-2.7.0-sources.jar!/springfox/documentation/builders/OperationBuilder.java:205
it looks like you only ever merge the response messages. Can you please clarify on desired behavior here? I for one, would like to see@ApiResponses
be an override rather than a merge.The text was updated successfully, but these errors were encountered: