Files
sponge/docs/docs.go
2023-01-14 16:24:07 +08:00

487 lines
15 KiB
Go

// Package docs GENERATED BY SWAG; DO NOT EDIT
// This file was generated by swaggo/swag
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": {
"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.Result"
}
}
}
}
},
"/api/v1/userExample/{id}": {
"get": {
"description": "get userExample details by id",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"userExample"
],
"summary": "get userExample details",
"parameters": [
{
"type": "string",
"description": "id",
"name": "id",
"in": "path",
"required": true
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/types.Result"
}
}
}
},
"put": {
"description": "update userExample information by id",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"userExample"
],
"summary": "update userExample information",
"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.Result"
}
}
}
},
"delete": {
"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.Result"
}
}
}
}
},
"/api/v1/userExamples": {
"post": {
"description": "paging and conditional fetching of userExamples lists using post requests",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"userExample"
],
"summary": "get a list of userExamples",
"parameters": [
{
"description": "query parameters",
"name": "data",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/types.Params"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/types.Result"
}
}
}
}
},
"/api/v1/userExamples/delete/ids": {
"post": {
"description": "delete userExamples by multiple id using a post request",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"userExample"
],
"summary": "delete userExamples by multiple id",
"parameters": [
{
"description": "id array",
"name": "data",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/types.DeleteUserExamplesByIDsRequest"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/types.Result"
}
}
}
}
},
"/api/v1/userExamples/ids": {
"post": {
"description": "get userExamples by multiple id using a post request",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"userExample"
],
"summary": "get userExamples by multiple id",
"parameters": [
{
"description": "id array",
"name": "data",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/types.GetUserExamplesByIDsRequest"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/types.Result"
}
}
}
}
},
"/health": {
"get": {
"description": "check health",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"system"
],
"summary": "check health",
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/handlerfunc.checkHealthResponse"
}
}
}
}
},
"/ping": {
"get": {
"description": "ping",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"system"
],
"summary": "ping",
"responses": {}
}
}
},
"definitions": {
"handlerfunc.checkHealthResponse": {
"type": "object",
"properties": {
"hostname": {
"type": "string"
},
"status": {
"type": "string"
}
}
},
"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"
}
}
},
"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 means \u003c+ country code\u003e \u003ccell phone number\u003e.",
"type": "string"
}
}
},
"types.DeleteUserExamplesByIDsRequest": {
"type": "object",
"properties": {
"ids": {
"description": "id list",
"type": "array",
"minItems": 1,
"items": {
"type": "integer"
}
}
}
},
"types.GetUserExamplesByIDsRequest": {
"type": "object",
"properties": {
"ids": {
"description": "id list",
"type": "array",
"minItems": 1,
"items": {
"type": "integer"
}
}
}
},
"types.Params": {
"type": "object",
"properties": {
"columns": {
"description": "query conditions",
"type": "array",
"items": {
"$ref": "#/definitions/types.Column"
}
},
"page": {
"description": "page number, starting from page 0",
"type": "integer",
"minimum": 0
},
"size": {
"description": "lines per page",
"type": "integer"
},
"sort": {
"description": "sorted fields, multi-column sorting separated by commas",
"type": "string"
}
}
},
"types.Result": {
"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"
}
}
}
}
}`
// SwaggerInfo holds exported Swagger Info so clients can modify it
var SwaggerInfo = &swag.Spec{
Version: "v0.0.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)
}