1 Star 5 Fork 6

zhufuyi/sponge

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
docs.go 18.63 KB
一键复制 编辑 原始数据 按行查看 历史
zhufuyi 提交于 9个月前 . adjust name
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591
// Code generated by swaggo/swag. DO NOT EDIT.
package docs
import "github.com/swaggo/swag"
const docTemplate = `{
"schemes": {{ marshal .Schemes }},
"swagger": "2.0",
"info": {
"description": "{{escape .Description}}",
"title": "{{.Title}}",
"contact": {},
"version": "{{.Version}}"
},
"host": "{{.Host}}",
"basePath": "{{.BasePath}}",
"paths": {
"/api/v1/userExample": {
"post": {
"security": [
{
"BearerAuth": []
}
],
"description": "submit information to create userExample",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"userExample"
],
"summary": "create userExample",
"parameters": [
{
"description": "userExample information",
"name": "data",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/types.CreateUserExampleRequest"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/types.CreateUserExampleReply"
}
}
}
}
},
"/api/v1/userExample/list": {
"post": {
"security": [
{
"BearerAuth": []
}
],
"description": "list of userExamples by paging and conditions",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"userExample"
],
"summary": "list of userExamples by query parameters",
"parameters": [
{
"description": "query parameters",
"name": "data",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/github_com_zhufuyi_sponge_internal_types.Params"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/types.ListUserExamplesReply"
}
}
}
}
},
"/api/v1/userExample/{id}": {
"get": {
"security": [
{
"BearerAuth": []
}
],
"description": "get userExample detail by id",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"userExample"
],
"summary": "get userExample detail",
"parameters": [
{
"type": "string",
"description": "id",
"name": "id",
"in": "path",
"required": true
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/types.GetUserExampleByIDReply"
}
}
}
},
"put": {
"security": [
{
"BearerAuth": []
}
],
"description": "update userExample information by id",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"userExample"
],
"summary": "update userExample",
"parameters": [
{
"type": "string",
"description": "id",
"name": "id",
"in": "path",
"required": true
},
{
"description": "userExample information",
"name": "data",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/types.UpdateUserExampleByIDRequest"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/types.UpdateUserExampleByIDReply"
}
}
}
},
"delete": {
"security": [
{
"BearerAuth": []
}
],
"description": "delete userExample by id",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"userExample"
],
"summary": "delete userExample",
"parameters": [
{
"type": "string",
"description": "id",
"name": "id",
"in": "path",
"required": true
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/types.DeleteUserExampleByIDReply"
}
}
}
}
},
"/codes": {
"get": {
"description": "list error codes info",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"system"
],
"summary": "list error codes info",
"responses": {}
}
},
"/config": {
"get": {
"description": "show config info",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"system"
],
"summary": "show config info",
"responses": {}
}
},
"/health": {
"get": {
"description": "check health",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"system"
],
"summary": "check health",
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/handlerfunc.CheckHealthReply"
}
}
}
}
},
"/ping": {
"get": {
"description": "ping",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"system"
],
"summary": "ping",
"responses": {}
}
}
},
"definitions": {
"github_com_zhufuyi_sponge_internal_types.Column": {
"type": "object",
"properties": {
"exp": {
"description": "expressions, which default to = when the value is null, have =, !=, \u003e, \u003e=, \u003c, \u003c=, like",
"type": "string"
},
"logic": {
"description": "logical type, defaults to and when value is null, only \u0026(and), ||(or)",
"type": "string"
},
"name": {
"description": "column name",
"type": "string"
},
"value": {
"description": "column value"
}
}
},
"github_com_zhufuyi_sponge_internal_types.Params": {
"type": "object",
"properties": {
"columns": {
"description": "query conditions",
"type": "array",
"items": {
"$ref": "#/definitions/github_com_zhufuyi_sponge_internal_types.Column"
}
},
"limit": {
"description": "lines per page",
"type": "integer"
},
"page": {
"description": "page number, starting from page 0",
"type": "integer"
},
"sort": {
"description": "sorted fields, multi-column sorting separated by commas",
"type": "string"
}
}
},
"handlerfunc.CheckHealthReply": {
"type": "object",
"properties": {
"hostname": {
"type": "string"
},
"status": {
"type": "string"
}
}
},
"types.CreateUserExampleReply": {
"type": "object",
"properties": {
"code": {
"description": "return code",
"type": "integer"
},
"data": {
"description": "return data",
"type": "object",
"properties": {
"id": {
"description": "id",
"type": "integer"
}
}
},
"msg": {
"description": "return information description",
"type": "string"
}
}
},
"types.CreateUserExampleRequest": {
"type": "object",
"properties": {
"age": {
"description": "age",
"type": "integer"
},
"avatar": {
"description": "avatar",
"type": "string",
"minLength": 5
},
"email": {
"description": "email",
"type": "string"
},
"gender": {
"description": "gender, 1:Male, 2:Female, other values:unknown",
"type": "integer",
"maximum": 2,
"minimum": 0
},
"name": {
"description": "username",
"type": "string",
"minLength": 2
},
"password": {
"description": "password",
"type": "string"
},
"phone": {
"description": "phone number, e164 rules, e.g. +8612345678901",
"type": "string"
}
}
},
"types.DeleteUserExampleByIDReply": {
"type": "object",
"properties": {
"code": {
"description": "return code",
"type": "integer"
},
"data": {
"description": "return data"
},
"msg": {
"description": "return information description",
"type": "string"
}
}
},
"types.GetUserExampleByIDReply": {
"type": "object",
"properties": {
"code": {
"description": "return code",
"type": "integer"
},
"data": {
"description": "return data",
"type": "object",
"properties": {
"userExample": {
"$ref": "#/definitions/types.UserExampleObjDetail"
}
}
},
"msg": {
"description": "return information description",
"type": "string"
}
}
},
"types.ListUserExamplesReply": {
"type": "object",
"properties": {
"code": {
"description": "return code",
"type": "integer"
},
"data": {
"description": "return data",
"type": "object",
"properties": {
"userExamples": {
"type": "array",
"items": {
"$ref": "#/definitions/types.UserExampleObjDetail"
}
}
}
},
"msg": {
"description": "return information description",
"type": "string"
}
}
},
"types.UpdateUserExampleByIDReply": {
"type": "object",
"properties": {
"code": {
"description": "return code",
"type": "integer"
},
"data": {
"description": "return data"
},
"msg": {
"description": "return information description",
"type": "string"
}
}
},
"types.UpdateUserExampleByIDRequest": {
"type": "object",
"properties": {
"age": {
"description": "age",
"type": "integer"
},
"avatar": {
"description": "avatar",
"type": "string"
},
"email": {
"description": "email",
"type": "string"
},
"gender": {
"description": "gender, 1:Male, 2:Female, other values:unknown",
"type": "integer"
},
"id": {
"description": "id",
"type": "integer"
},
"name": {
"description": "username",
"type": "string"
},
"password": {
"description": "password",
"type": "string"
},
"phone": {
"description": "phone number",
"type": "string"
}
}
},
"types.UserExampleObjDetail": {
"type": "object",
"properties": {
"age": {
"description": "age",
"type": "integer"
},
"avatar": {
"description": "avatar",
"type": "string"
},
"createdAt": {
"description": "create time",
"type": "string"
},
"email": {
"description": "email",
"type": "string"
},
"gender": {
"description": "gender, 1:Male, 2:Female, other values:unknown",
"type": "integer"
},
"id": {
"description": "id",
"type": "integer"
},
"loginAt": {
"description": "login timestamp",
"type": "integer"
},
"name": {
"description": "username",
"type": "string"
},
"phone": {
"description": "phone number",
"type": "string"
},
"status": {
"description": "account status, 1:inactive, 2:activated, 3:blocked",
"type": "integer"
},
"updatedAt": {
"description": "update time",
"type": "string"
}
}
}
},
"securityDefinitions": {
"BearerAuth": {
"description": "Type Bearer your-jwt-token to Value",
"type": "apiKey",
"name": "Authorization",
"in": "header"
}
}
}`
// SwaggerInfo holds exported Swagger Info so clients can modify it
var SwaggerInfo = &swag.Spec{
Version: "2.0",
Host: "localhost:8080",
BasePath: "",
Schemes: []string{"http", "https"},
Title: "serverNameExample api docs",
Description: "http server api docs",
InfoInstanceName: "swagger",
SwaggerTemplate: docTemplate,
}
func init() {
swag.Register(SwaggerInfo.InstanceName(), SwaggerInfo)
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Go
1
https://gitee.com/zhufuyi/sponge.git
git@gitee.com:zhufuyi/sponge.git
zhufuyi
sponge
sponge
main

搜索帮助