// GENERATED BY THE COMMAND ABOVE; DO NOT EDIT // This file was generated by swaggo/swag package docs import ( "bytes" "encoding/json" "strings" "github.com/alecthomas/template" "github.com/swaggo/swag" ) var doc = `{ "schemes": {{ marshal .Schemes }}, "swagger": "2.0", "info": { "description": "{{.Description}}", "title": "{{.Title}}", "contact": {}, "version": "{{.Version}}" }, "host": "{{.Host}}", "basePath": "{{.BasePath}}", "paths": { "/app/check-call": { "post": { "tags": [ "call" ], "summary": "检查通话状态", "parameters": [ { "type": "string", "description": "MOCK", "name": "FZM-SIGNATURE", "in": "header", "required": true }, { "description": "body", "name": "data", "in": "body", "schema": { "$ref": "#/definitions/model.CheckCallRequest" } } ], "responses": { "200": { "description": "OK", "schema": { "allOf": [ { "$ref": "#/definitions/model.GeneralResponse" }, { "type": "object", "properties": { "data": { "$ref": "#/definitions/model.CheckCallResponse" } } } ] } } } } }, "/app/handle-call": { "post": { "tags": [ "call" ], "summary": "处理通话", "parameters": [ { "type": "string", "description": "MOCK", "name": "FZM-SIGNATURE", "in": "header", "required": true }, { "description": "body", "name": "data", "in": "body", "schema": { "$ref": "#/definitions/model.HandleCallRequest" } } ], "responses": { "200": { "description": "OK", "schema": { "allOf": [ { "$ref": "#/definitions/model.GeneralResponse" }, { "type": "object", "properties": { "data": { "$ref": "#/definitions/model.HandleCallResponse" } } } ] } } } } }, "/app/reply-busy": { "post": { "tags": [ "call" ], "summary": "返回忙碌", "parameters": [ { "type": "string", "description": "MOCK", "name": "FZM-SIGNATURE", "in": "header", "required": true }, { "description": "body", "name": "data", "in": "body", "schema": { "$ref": "#/definitions/model.ReplyBusyRequest" } } ], "responses": { "200": { "description": "OK", "schema": { "allOf": [ { "$ref": "#/definitions/model.GeneralResponse" }, { "type": "object", "properties": { "data": { "$ref": "#/definitions/model.ReplyBusyResponse" } } } ] } } } } }, "/app/start-call": { "post": { "tags": [ "call" ], "summary": "开始通话", "parameters": [ { "type": "string", "description": "MOCK", "name": "FZM-SIGNATURE", "in": "header", "required": true }, { "description": "body", "name": "data", "in": "body", "schema": { "$ref": "#/definitions/model.StartCallRequest" } } ], "responses": { "200": { "description": "OK", "schema": { "allOf": [ { "$ref": "#/definitions/model.GeneralResponse" }, { "type": "object", "properties": { "data": { "$ref": "#/definitions/model.StartCallResponse" } } } ] } } } } } }, "definitions": { "model.CheckCallRequest": { "type": "object", "properties": { "traceId": { "type": "integer" }, "traceIdStr": { "description": "如果同时填了 tracedIdStr, 则优先选择 traceIdStr", "type": "string" } } }, "model.CheckCallResponse": { "type": "object", "properties": { "RTCType": { "type": "integer" }, "caller": { "type": "string" }, "createTime": { "type": "integer" }, "deadline": { "type": "integer" }, "groupId": { "type": "string" }, "invitees": { "type": "array", "items": { "type": "string" } }, "timeout": { "type": "integer" }, "traceId": { "type": "integer" }, "traceIdStr": { "type": "string" } } }, "model.GeneralResponse": { "type": "object", "properties": { "data": { "type": "object" }, "message": { "type": "integer" }, "result": { "type": "integer" } } }, "model.HandleCallRequest": { "type": "object", "properties": { "answer": { "type": "boolean" }, "traceId": { "type": "integer" }, "traceIdStr": { "description": "如果同时填了 tracedIdStr, 则优先选择 traceIdStr", "type": "string" } } }, "model.HandleCallResponse": { "type": "object", "properties": { "privateMapKey": { "type": "string" }, "roomId": { "type": "integer" }, "sdkAppId": { "type": "integer" }, "userSig": { "type": "string" } } }, "model.ReplyBusyRequest": { "type": "object", "properties": { "traceId": { "type": "integer" }, "traceIdStr": { "description": "如果同时填了 tracedIdStr, 则优先选择 traceIdStr", "type": "string" } } }, "model.ReplyBusyResponse": { "type": "object" }, "model.StartCallRequest": { "type": "object", "required": [ "invitees" ], "properties": { "RTCType": { "type": "integer" }, "groupId": { "type": "string" }, "invitees": { "type": "array", "items": { "type": "string" } } } }, "model.StartCallResponse": { "type": "object", "properties": { "RTCType": { "type": "integer" }, "caller": { "type": "string" }, "createTime": { "type": "integer" }, "deadline": { "type": "integer" }, "groupId": { "description": "0表示私聊, 其他表示群聊", "type": "string" }, "invitees": { "type": "array", "items": { "type": "string" } }, "timeout": { "type": "integer" }, "traceId": { "type": "integer" }, "traceIdStr": { "type": "string" } } } } }` type swaggerInfo struct { Version string Host string BasePath string Schemes []string Title string Description string } // SwaggerInfo holds exported Swagger Info so clients can modify it var SwaggerInfo = swaggerInfo{ Version: "1.0", Host: "127.0.0.1:18013", BasePath: "", Schemes: []string{}, Title: "音视频信令服务接口", Description: "", } type s struct{} func (s *s) ReadDoc() string { sInfo := SwaggerInfo sInfo.Description = strings.Replace(sInfo.Description, "\n", "\\n", -1) t, err := template.New("swagger_info").Funcs(template.FuncMap{ "marshal": func(v interface{}) string { a, _ := json.Marshal(v) return string(a) }, }).Parse(doc) if err != nil { return doc } var tpl bytes.Buffer if err := t.Execute(&tpl, sInfo); err != nil { return doc } return tpl.String() } func init() { swag.Register(swag.Name, &s{}) }