Reputation: 1558
From my spring rest service, I am returning response as -
return new ResponseEntity<ExampleOutputData>(exampleService.exampleServiceCall(inputData), responseHeaders, HttpStatus.ACCEPTED);
And I am mentioning response in annotaion as -
@ApiResponses(value = {
@ApiResponse(code = 202, message = "Success", response = ResponseEntity.class)})
And I am getting yaml doc response as -
responses:
202:
description: "Success"
schema:
$ref: "#/definitions/ResponseEntity"
My question is how do I mention ExampleOutputData in the response as actually my response is ResponseEntity<ExampleOutputData>
Or is it not required and the current implementation and swagger definition is perfect?
Upvotes: 0
Views: 143