SafeLine/backend/docs/docs.go
2023-12-08 17:49:44 +08:00

335 lines
9.4 KiB
Go

// Package docs 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": {
"/exist": {
"post": {
"description": "get ip if id exist",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"Safeline"
],
"summary": "get ip if id exist",
"parameters": [
{
"description": "body",
"name": "body",
"in": "body",
"required": true,
"schema": {
"$ref": "#/definitions/handler.ExistReq"
}
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"type": "string"
}
}
}
}
},
"/repos/discussions": {
"get": {
"description": "get discussions from GitHub",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"GitHub"
],
"summary": "get discussions",
"parameters": [
{
"type": "string",
"description": "search by",
"name": "q",
"in": "query"
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"type": "array",
"items": {
"$ref": "#/definitions/service.Discussion"
}
}
}
}
}
},
"/repos/info": {
"get": {
"description": "get repo info from GitHub",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"GitHub"
],
"summary": "get repo info",
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/service.Repo"
}
}
}
}
},
"/repos/issues": {
"get": {
"description": "get issues from GitHub",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"GitHub"
],
"summary": "get issues",
"parameters": [
{
"type": "string",
"description": "search by",
"name": "q",
"in": "query"
}
],
"responses": {
"200": {
"description": "OK",
"schema": {
"type": "array",
"items": {
"$ref": "#/definitions/service.Issue"
}
}
}
}
}
},
"/safeline/count": {
"get": {
"description": "get installer count",
"consumes": [
"application/json"
],
"produces": [
"application/json"
],
"tags": [
"Safeline"
],
"summary": "get installer count",
"responses": {
"200": {
"description": "OK",
"schema": {
"$ref": "#/definitions/service.InstallerCount"
}
}
}
}
}
},
"definitions": {
"handler.ExistReq": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"token": {
"type": "string"
}
}
},
"service.Category": {
"type": "object",
"properties": {
"emoji": {
"type": "string"
},
"emoji_html": {
"type": "string"
},
"id": {
"type": "string"
},
"name": {
"type": "string"
}
}
},
"service.Discussion": {
"type": "object",
"properties": {
"author": {
"$ref": "#/definitions/service.User"
},
"category": {
"$ref": "#/definitions/service.Category"
},
"comment_count": {
"type": "integer"
},
"comment_users": {
"type": "array",
"items": {
"$ref": "#/definitions/service.User"
}
},
"created_at": {
"type": "integer"
},
"id": {
"type": "string"
},
"is_answered": {
"type": "boolean"
},
"labels": {
"type": "array",
"items": {
"$ref": "#/definitions/service.Label"
}
},
"thumbs_up": {
"type": "integer"
},
"title": {
"type": "string"
},
"upvote_count": {
"type": "integer"
},
"url": {
"type": "string"
}
}
},
"service.InstallerCount": {
"type": "object",
"properties": {
"total": {
"type": "integer"
}
}
},
"service.Issue": {
"type": "object",
"properties": {
"author": {
"$ref": "#/definitions/service.User"
},
"comment_count": {
"type": "integer"
},
"created_at": {
"type": "integer"
},
"id": {
"type": "string"
},
"labels": {
"type": "array",
"items": {
"$ref": "#/definitions/service.Label"
}
},
"thumbs_up": {
"type": "integer"
},
"title": {
"type": "string"
},
"url": {
"type": "string"
}
}
},
"service.Label": {
"type": "object",
"properties": {
"color": {
"type": "string"
},
"name": {
"type": "string"
}
}
},
"service.Repo": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"star_count": {
"type": "integer"
}
}
},
"service.User": {
"type": "object",
"properties": {
"avatar_url": {
"type": "string"
},
"login": {
"type": "string"
}
}
}
}
}`
// SwaggerInfo holds exported Swagger Info so clients can modify it
var SwaggerInfo = &swag.Spec{
Version: "",
Host: "",
BasePath: "",
Schemes: []string{},
Title: "",
Description: "",
InfoInstanceName: "swagger",
SwaggerTemplate: docTemplate,
LeftDelim: "{{",
RightDelim: "}}",
}
func init() {
swag.Register(SwaggerInfo.InstanceName(), SwaggerInfo)
}