My App's response looks like this:
{
"status": "success",
"data": {
"status": "ready"
},
"request_id": "string"
}
I tried to define response in Swagger
* @SWG\Response (
* response=200,
* description="Success response",
* @SWG\Schema (
* @SWG\Property(
* property="status",
* type="string",
* default="success"
* ),
* @SWG\Property(
* property="data",
* @SWG\Schema(
* ref="#/definitions/Service/models/Status"
* )
* ),
* @SWG\Property(
* property="request_id",
* type="string"
* ),
* )
* ),
But it does not use Schema definition for Status, so my response actually looks like:
{
"status": "success",
"data": {},
"request_id": "string"
}
How can I define data property to use schema definition? Or can it can be done in a different way?