gofiber-study/docs/swagger.json
2022-10-03 15:10:03 +08:00

77 lines
2.3 KiB
JSON

{
"swagger": "2.0",
"info": {
"description": "基于 Fiber 框架的 swagger",
"title": "GoFiber Study API",
"termsOfService": "http://swagger.io/terms/",
"contact": {
"name": "Shikong",
"email": "919411476@qq.com"
},
"license": {
"name": "Apache 2.0",
"url": "http://www.apache.org/licenses/LICENSE-2.0.html"
},
"version": "1.0"
},
"basePath": "/",
"paths": {
"/": {
"get": {
"description": "简单的 HelloWorld 示例",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"HelloWorld"
],
"summary": "HelloWorld",
"responses": {
"200": {
"description": "OK",
"schema": {
"type": "string"
}
},
"400": {
"description": "Bad Request",
"schema": {
"$ref": "#/definitions/errorx.CodeErrorResponse"
}
},
"404": {
"description": "Not Found",
"schema": {
"$ref": "#/definitions/errorx.CodeErrorResponse"
}
},
"500": {
"description": "Internal Server Error",
"schema": {
"$ref": "#/definitions/errorx.CodeErrorResponse"
}
}
}
}
}
},
"definitions": {
"errorx.CodeErrorResponse": {
"type": "object",
"properties": {
"code": {
"type": "integer",
"example": 200
},
"data": {},
"msg": {
"type": "string",
"example": "OK"
}
}
}
}
}