You can not select more than 25 topics Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.

docs.go 11 kB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343
  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. "contact": {},
  11. "version": "{{.Version}}"
  12. },
  13. "host": "{{.Host}}",
  14. "basePath": "{{.BasePath}}",
  15. "paths": {
  16. "/api/v1/community/create": {
  17. "post": {
  18. "description": "Create a new community",
  19. "produces": [
  20. "application/json"
  21. ],
  22. "tags": [
  23. "community"
  24. ],
  25. "summary": "CreateCommunity",
  26. "parameters": [
  27. {
  28. "description": "Community",
  29. "name": "data",
  30. "in": "body",
  31. "required": true,
  32. "schema": {
  33. "$ref": "#/definitions/param.CommunityParams"
  34. }
  35. }
  36. ],
  37. "responses": {
  38. "200": {
  39. "description": "Success",
  40. "schema": {
  41. "allOf": [
  42. {
  43. "$ref": "#/definitions/response.Response"
  44. },
  45. {
  46. "type": "object",
  47. "properties": {
  48. "msg": {
  49. "type": "string"
  50. }
  51. }
  52. }
  53. ]
  54. }
  55. }
  56. }
  57. }
  58. },
  59. "/api/v1/email/code": {
  60. "post": {
  61. "description": "Use email to send verification code",
  62. "produces": [
  63. "application/json"
  64. ],
  65. "tags": [
  66. "mail"
  67. ],
  68. "summary": "SendCode",
  69. "parameters": [
  70. {
  71. "description": "Email address",
  72. "name": "data",
  73. "in": "body",
  74. "required": true,
  75. "schema": {
  76. "$ref": "#/definitions/param.SendToParams"
  77. }
  78. }
  79. ],
  80. "responses": {
  81. "200": {
  82. "description": "Success",
  83. "schema": {
  84. "allOf": [
  85. {
  86. "$ref": "#/definitions/response.Response"
  87. },
  88. {
  89. "type": "object",
  90. "properties": {
  91. "msg": {
  92. "type": "string"
  93. }
  94. }
  95. }
  96. ]
  97. }
  98. }
  99. }
  100. }
  101. },
  102. "/api/v1/openim/callback": {
  103. "post": {
  104. "description": "Support OpenIM callback",
  105. "produces": [
  106. "application/json"
  107. ],
  108. "tags": [
  109. "openim"
  110. ],
  111. "summary": "OpenIMCallback",
  112. "responses": {
  113. "200": {
  114. "description": "Success",
  115. "schema": {
  116. "allOf": [
  117. {
  118. "$ref": "#/definitions/response.Response"
  119. },
  120. {
  121. "type": "object",
  122. "properties": {
  123. "msg": {
  124. "type": "string"
  125. }
  126. }
  127. }
  128. ]
  129. }
  130. }
  131. }
  132. }
  133. },
  134. "/api/v1/register/admin": {
  135. "post": {
  136. "description": "Create a new admin",
  137. "produces": [
  138. "application/json"
  139. ],
  140. "tags": [
  141. "user"
  142. ],
  143. "summary": "AdminRegister",
  144. "parameters": [
  145. {
  146. "description": "RegisterAdminParams",
  147. "name": "data",
  148. "in": "body",
  149. "required": true,
  150. "schema": {
  151. "$ref": "#/definitions/param.RegisterAdminParams"
  152. }
  153. }
  154. ],
  155. "responses": {
  156. "200": {
  157. "description": "Success",
  158. "schema": {
  159. "allOf": [
  160. {
  161. "$ref": "#/definitions/response.Response"
  162. },
  163. {
  164. "type": "object",
  165. "properties": {
  166. "msg": {
  167. "type": "string"
  168. }
  169. }
  170. }
  171. ]
  172. }
  173. }
  174. }
  175. }
  176. },
  177. "/api/v1/register/staff": {
  178. "post": {
  179. "description": "Create a new staff",
  180. "produces": [
  181. "application/json"
  182. ],
  183. "tags": [
  184. "user"
  185. ],
  186. "summary": "StaffRegister",
  187. "parameters": [
  188. {
  189. "description": "RegisterStaffParams",
  190. "name": "data",
  191. "in": "body",
  192. "required": true,
  193. "schema": {
  194. "$ref": "#/definitions/param.RegisterStaffParams"
  195. }
  196. }
  197. ],
  198. "responses": {
  199. "200": {
  200. "description": "Success",
  201. "schema": {
  202. "allOf": [
  203. {
  204. "$ref": "#/definitions/response.Response"
  205. },
  206. {
  207. "type": "object",
  208. "properties": {
  209. "msg": {
  210. "type": "string"
  211. }
  212. }
  213. }
  214. ]
  215. }
  216. }
  217. }
  218. }
  219. }
  220. },
  221. "definitions": {
  222. "param.CommunityParams": {
  223. "type": "object",
  224. "required": [
  225. "avatar",
  226. "email",
  227. "name"
  228. ],
  229. "properties": {
  230. "avatar": {
  231. "type": "string"
  232. },
  233. "email": {
  234. "type": "string"
  235. },
  236. "name": {
  237. "type": "string"
  238. }
  239. }
  240. },
  241. "param.CreateUserParams": {
  242. "type": "object",
  243. "required": [
  244. "avatar",
  245. "email",
  246. "nickname",
  247. "password"
  248. ],
  249. "properties": {
  250. "avatar": {
  251. "type": "string"
  252. },
  253. "email": {
  254. "type": "string"
  255. },
  256. "nickname": {
  257. "type": "string"
  258. },
  259. "password": {
  260. "type": "string"
  261. }
  262. }
  263. },
  264. "param.RegisterAdminParams": {
  265. "type": "object",
  266. "required": [
  267. "code",
  268. "community_info",
  269. "user_info"
  270. ],
  271. "properties": {
  272. "code": {
  273. "type": "string"
  274. },
  275. "community_info": {
  276. "$ref": "#/definitions/param.CommunityParams"
  277. },
  278. "user_info": {
  279. "$ref": "#/definitions/param.CreateUserParams"
  280. }
  281. }
  282. },
  283. "param.RegisterStaffParams": {
  284. "type": "object",
  285. "required": [
  286. "community_id",
  287. "user_info"
  288. ],
  289. "properties": {
  290. "community_id": {
  291. "type": "integer"
  292. },
  293. "user_info": {
  294. "$ref": "#/definitions/param.CreateUserParams"
  295. }
  296. }
  297. },
  298. "param.SendToParams": {
  299. "type": "object",
  300. "required": [
  301. "email"
  302. ],
  303. "properties": {
  304. "email": {
  305. "type": "string"
  306. }
  307. }
  308. },
  309. "response.Response": {
  310. "type": "object",
  311. "properties": {
  312. "code": {
  313. "type": "integer"
  314. },
  315. "data": {},
  316. "msg": {
  317. "type": "string"
  318. }
  319. }
  320. }
  321. }
  322. }`
  323. // SwaggerInfo holds exported Swagger Info so clients can modify it
  324. var SwaggerInfo = &swag.Spec{
  325. Version: "",
  326. Host: "",
  327. BasePath: "",
  328. Schemes: []string{},
  329. Title: "",
  330. Description: "",
  331. InfoInstanceName: "swagger",
  332. SwaggerTemplate: docTemplate,
  333. LeftDelim: "{{",
  334. RightDelim: "}}",
  335. }
  336. func init() {
  337. swag.Register(SwaggerInfo.InstanceName(), SwaggerInfo)
  338. }