docs.go 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145
  1. // Code generated by swaggo/swag. DO NOT EDIT.
  2. package docs
  3. import "github.com/swaggo/swag"
  4. const docTemplate = `{
  5. "schemes": {{ marshal .Schemes }},
  6. "swagger": "2.0",
  7. "info": {
  8. "description": "{{escape .Description}}",
  9. "title": "{{.Title}}",
  10. "termsOfService": "http://swagger.io/terms/",
  11. "contact": {},
  12. "license": {
  13. "name": "Apache 2.0",
  14. "url": "http://www.apache.org/licenses/LICENSE-2.0.html"
  15. },
  16. "version": "{{.Version}}"
  17. },
  18. "host": "{{.Host}}",
  19. "basePath": "{{.BasePath}}",
  20. "paths": {
  21. "/user/login": {
  22. "post": {
  23. "tags": [
  24. "用户模块"
  25. ],
  26. "summary": "登录",
  27. "parameters": [
  28. {
  29. "type": "string",
  30. "description": "用户ID",
  31. "name": "uid",
  32. "in": "formData"
  33. }
  34. ],
  35. "responses": {
  36. "200": {
  37. "description": "code\",\"data\",\"token\"}",
  38. "schema": {
  39. "type": "string"
  40. }
  41. }
  42. }
  43. }
  44. },
  45. "/user/modify": {
  46. "post": {
  47. "tags": [
  48. "用户模块"
  49. ],
  50. "summary": "修改用户信息",
  51. "parameters": [
  52. {
  53. "type": "string",
  54. "description": "用户ID",
  55. "name": "uid",
  56. "in": "formData"
  57. },
  58. {
  59. "type": "string",
  60. "description": "头像",
  61. "name": "avatar",
  62. "in": "formData"
  63. },
  64. {
  65. "type": "string",
  66. "description": "用户名",
  67. "name": "name",
  68. "in": "formData"
  69. },
  70. {
  71. "type": "string",
  72. "description": "电话",
  73. "name": "phone",
  74. "in": "formData"
  75. }
  76. ],
  77. "responses": {
  78. "200": {
  79. "description": "code\",\"data\",\"token\"}",
  80. "schema": {
  81. "type": "string"
  82. }
  83. }
  84. }
  85. }
  86. },
  87. "/user/register": {
  88. "post": {
  89. "tags": [
  90. "用户模块"
  91. ],
  92. "summary": "创建用户",
  93. "parameters": [
  94. {
  95. "type": "string",
  96. "description": "用户ID",
  97. "name": "uid",
  98. "in": "formData"
  99. },
  100. {
  101. "type": "string",
  102. "description": "用户名",
  103. "name": "name",
  104. "in": "formData"
  105. },
  106. {
  107. "type": "string",
  108. "description": "头像",
  109. "name": "avatar",
  110. "in": "formData"
  111. }
  112. ],
  113. "responses": {
  114. "200": {
  115. "description": "code\",\"data\",\"message\"}",
  116. "schema": {
  117. "type": "string"
  118. }
  119. }
  120. }
  121. }
  122. }
  123. }
  124. }`
  125. // SwaggerInfo holds exported Swagger Info so clients can modify it
  126. var SwaggerInfo = &swag.Spec{
  127. Version: "1.0",
  128. Host: "127.0.0.1:8084",
  129. BasePath: "/WeChatTrading/trading-go",
  130. Schemes: []string{},
  131. Title: "二手交易",
  132. Description: "一个基于微信小程序的校园二手交易平台的api",
  133. InfoInstanceName: "swagger",
  134. SwaggerTemplate: docTemplate,
  135. LeftDelim: "{{",
  136. RightDelim: "}}",
  137. }
  138. func init() {
  139. swag.Register(SwaggerInfo.InstanceName(), SwaggerInfo)
  140. }