/**
* @api {post} /users Request CreateUsers
* @apiName CreateUsers
* @apiGroup User
*
* @apiParam {Object[]} users User list.
* @apiParam {String} users.id UUID of user.
* @apiParam {String} users.name Name of user.
*
* @apiSuccess {String} status Status of request.
* @apiSuccess {Object[]} users User list.
* @apiSuccess {String} users.id UUID of user.
* @apiSuccess {String} users.name Name of user.
*/
...
"definitions": {
"CreateUsers": {
"properties": {
"users": {
"type": "array",
"description": "User list.",
"items": {
"type": "Object"
}
},
...
...
"responses": {
"200": {
"description": "successful operation",
"schema": {
"type": "String",
"items": {
"$ref": "#/definitions/CreateUsers"
}
}
}
}
...
{
"swagger": "2.0",
"info": {
"title": "test",
"version": "1.0.0",
"description": "Test project description"
},
"paths": {
"/users": {
"post": {
"tags": [
"User"
],
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"parameters": [
{
"in": "body",
"name": "body",
"required": true,
"schema": {
"$ref": "#/definitions/CreateUsers"
}
}
],
"responses": {
"200": {
"description": "successful operation",
"schema": {
"type": "String",
"items": {
"$ref": "#/definitions/CreateUsers"
}
}
}
}
}
}
},
"definitions": {
"CreateUsers": {
"properties": {
"users": {
"type": "array",
"description": "User list.",
"items": {
"type": "Object"
}
},
"status": {
"type": "string",
"description": "Status of request."
}
},
"required": [
"users",
"status"
]
},
"users": {
"properties": {
"id": {
"type": "string",
"description": "UUID of user."
},
"name": {
"type": "string",
"description": "Name of user."
}
},
"required": [
"id",
"name"
]
}
}
}