diff --git a/cmd/open_im_api/docs/docs.go b/cmd/open_im_api/docs/docs.go index 04efc9ea5..50981d32a 100644 --- a/cmd/open_im_api/docs/docs.go +++ b/cmd/open_im_api/docs/docs.go @@ -11,6 +11,10 @@ const docTemplate = `{ "description": "{{escape .Description}}", "title": "{{.Title}}", "contact": {}, + "license": { + "name": "Apache 2.0", + "url": "http://www.apache.org/licenses/LICENSE-2.0.html" + }, "version": "{{.Version}}" }, "host": "{{.Host}}", @@ -39,7 +43,7 @@ const docTemplate = `{ "required": true }, { - "description": "platform为平台ID, fromUserID为要执行强制登出的用户ID", + "description": "platform为平台ID \u003cbr\u003e fromUserID为要执行强制登出的用户ID", "name": "req", "in": "body", "required": true, @@ -58,13 +62,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.ForceLogoutResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.ForceLogoutResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -72,7 +76,7 @@ const docTemplate = `{ }, "/auth/parse_token": { "post": { - "description": "解析用户token", + "description": "解析当前用户token(token在请求头中传入)", "consumes": [ "application/json" ], @@ -82,7 +86,7 @@ const docTemplate = `{ "tags": [ "鉴权认证" ], - "summary": "解析token", + "summary": "解析当前用户token", "operationId": "ParseToken", "parameters": [ { @@ -93,7 +97,7 @@ const docTemplate = `{ "required": true }, { - "description": "secret为openIM密钥, 详细见服务端config.yaml secret字段, platform为平台ID", + "description": "secret为openIM密钥, 详细见服务端config.yaml secret字段\u003cbr\u003eplatform为平台ID", "name": "req", "in": "body", "required": true, @@ -106,19 +110,31 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.ParseTokenResp" + "allOf": [ + { + "$ref": "#/definitions/base_info.ParseTokenResp" + }, + { + "type": "object", + "properties": { + "Data": { + "$ref": "#/definitions/base_info.ExpireTime" + } + } + } + ] } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.ParseTokenResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.ParseTokenResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -126,7 +142,7 @@ const docTemplate = `{ }, "/auth/user_register": { "post": { - "description": "用户登录", + "description": "用户注册", "consumes": [ "application/json" ], @@ -136,7 +152,7 @@ const docTemplate = `{ "tags": [ "鉴权认证" ], - "summary": "用户登录", + "summary": "用户注册", "operationId": "UserRegister", "parameters": [ { @@ -147,7 +163,7 @@ const docTemplate = `{ "required": true }, { - "description": "secret为openIM密钥, 详细见服务端config.yaml secret字段 \u003cbr\u003e platform为平台ID \u003cbr\u003e ex为拓展字段", + "description": "secret为openIM密钥, 详细见服务端config.yaml secret字段 \u003cbr\u003e platform为平台ID \u003cbr\u003e ex为拓展字段 \u003cbr\u003e gender为性别, 0为女, 1为男", "name": "req", "in": "body", "required": true, @@ -166,13 +182,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.UserRegisterResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.UserRegisterResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -201,7 +217,7 @@ const docTemplate = `{ "required": true }, { - "description": "secret为openIM密钥, 详细见服务端config.yaml secret字段, platform为平台ID", + "description": "secret为openIM密钥, 详细见服务端config.yaml secret字段 \u003cbr\u003e platform为平台ID", "name": "req", "in": "body", "required": true, @@ -220,13 +236,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.UserTokenResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.UserTokenResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -255,7 +271,7 @@ const docTemplate = `{ "required": true }, { - "description": "fromUserID为设置的用户, toUserID为被设置的用户", + "description": "fromUserID为设置的用户 \u003cbr\u003e toUserID为被设置的用户", "name": "req", "in": "body", "required": true, @@ -274,13 +290,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.AddBlacklistResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.AddBlacklistResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -309,7 +325,7 @@ const docTemplate = `{ "required": true }, { - "description": "reqMsg为申请信息, fromUserID为申请用户, toUserID为被添加用户", + "description": "reqMsg为申请信息 \u003cbr\u003e fromUserID为申请用户 \u003cbr\u003e toUserID为被添加用户", "name": "req", "in": "body", "required": true, @@ -328,13 +344,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.AddFriendResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.AddFriendResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -363,7 +379,7 @@ const docTemplate = `{ "required": true }, { - "description": "fromUserID同意/拒绝的用户ID, toUserID为申请用户, handleMsg为处理信息, flag为具体操作, 1为同意, 2为拒绝", + "description": "fromUserID同意/拒绝的用户ID\u003cbr\u003etoUserID为申请用户D\u003cbr\u003ehandleMsg为处理信息\u003cbr\u003eflag为具体操作, 1为同意, 2为拒绝", "name": "req", "in": "body", "required": true, @@ -382,13 +398,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.AddFriendResponseResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.AddFriendResponseResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -417,7 +433,7 @@ const docTemplate = `{ "required": true }, { - "description": "fromUserID为操作用户, toUserID为被删除用户", + "description": "fromUserID为操作用户\u003cbr\u003etoUserID为被删除用户", "name": "req", "in": "body", "required": true, @@ -436,13 +452,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.DeleteFriendResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.DeleteFriendResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -484,19 +500,34 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetBlackListResp" + "allOf": [ + { + "$ref": "#/definitions/base_info.GetBlackListResp" + }, + { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/server_api_params.PublicUserInfo" + } + } + } + } + ] } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetBlackListResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetBlackListResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } } } @@ -538,19 +569,34 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetFriendApplyListResp" + "allOf": [ + { + "$ref": "#/definitions/base_info.GetFriendApplyListResp" + }, + { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/server_api_params.FriendRequest" + } + } + } + } + ] } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetFriendApplyListResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetFriendApplyListResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } } } @@ -592,19 +638,34 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetFriendListResp" + "allOf": [ + { + "$ref": "#/definitions/base_info.GetFriendListResp" + }, + { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/server_api_params.FriendInfo" + } + } + } + } + ] } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetFriendListResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetFriendListResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -646,19 +707,34 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetSelfApplyListResp" + "allOf": [ + { + "$ref": "#/definitions/base_info.GetSelfApplyListResp" + }, + { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/server_api_params.FriendRequest" + } + } + } + } + ] } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetSelfApplyListResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetSelfApplyListResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -687,7 +763,7 @@ const docTemplate = `{ "required": true }, { - "description": "fromUserID批量加好友的用户ID, friendUserIDList为", + "description": "fromUserID批量加好友的用户ID\u003cbr\u003e friendUserIDList为", "name": "req", "in": "body", "required": true, @@ -698,7 +774,7 @@ const docTemplate = `{ ], "responses": { "0": { - "description": "data列表中对象的result-1为添加该用户失败, 0为成功", + "description": "data列表中对象的result-1为添加该用户失败\u003cbr\u003e0为成功", "schema": { "$ref": "#/definitions/base_info.ImportFriendResp" } @@ -706,13 +782,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.ImportFriendResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.ImportFriendResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -741,7 +817,7 @@ const docTemplate = `{ "required": true }, { - "description": "fromUserID为请求用户, toUserID为要检查的用户", + "description": "fromUserID为请求用户\u003cbr\u003e toUserID为要检查的用户", "name": "req", "in": "body", "required": true, @@ -760,13 +836,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.IsFriendResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.IsFriendResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -814,13 +890,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.RemoveBlackListResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.RemoveBlackListResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -849,7 +925,7 @@ const docTemplate = `{ "required": true }, { - "description": "fromUserID为设置的用户, toUserID为被设置的用户, remark为好友备注", + "description": "fromUserID为设置的用户\u003cbr\u003e toUserID为被设置的用户\u003cbr\u003e remark为好友备注", "name": "req", "in": "body", "required": true, @@ -868,13 +944,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.SetFriendRemarkResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.SetFriendRemarkResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -922,13 +998,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.CancelMuteGroupResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.CancelMuteGroupResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -976,13 +1052,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.CancelMuteGroupMemberResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.CancelMuteGroupMemberResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1011,7 +1087,7 @@ const docTemplate = `{ "required": true }, { - "description": "ownerUserID为群主ID \u003cbr\u003e ex为群扩展字段 \u003cbr\u003e roleLevel为群员角色,1为普通用户 2为群主 3为管理员", + "description": "groupType这里填0代表普通群 \u003cbr\u003egroupName为群名称\u003cbr\u003e introduction为群介绍\u003cbr\u003e notification为群公共\u003cbr\u003eownerUserID为群主ID \u003cbr\u003e ex为群扩展字段 \u003cbr\u003e memberList中对象roleLevel为群员角色,1为普通用户 2为群主 3为管理员", "name": "req", "in": "body", "required": true, @@ -1042,13 +1118,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.CreateGroupResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.CreateGroupResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1096,13 +1172,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.DismissGroupResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.DismissGroupResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1165,13 +1241,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetGroupAllMemberResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetGroupAllMemberResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1200,7 +1276,7 @@ const docTemplate = `{ "required": true }, { - "description": "memberList为要获取群成员的群ID列表", + "description": "groupID为要获取的群ID \u003cbr\u003e memberList为要获取群成员的群ID列表", "name": "req", "in": "body", "required": true, @@ -1234,13 +1310,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetGroupMembersInfoResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetGroupMembersInfoResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1288,13 +1364,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetGroupInfoResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetGroupInfoResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1357,13 +1433,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetJoinedGroupListResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetJoinedGroupListResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1405,19 +1481,34 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetGroupApplicationListResp" + "allOf": [ + { + "$ref": "#/definitions/base_info.GetGroupApplicationListResp" + }, + { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/server_api_params.GroupRequest" + } + } + } + } + ] } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetGroupApplicationListResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetGroupApplicationListResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1459,19 +1550,34 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetGroupApplicationListResp" + "allOf": [ + { + "$ref": "#/definitions/base_info.GetGroupApplicationListResp" + }, + { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/server_api_params.GroupRequest" + } + } + } + } + ] } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetGroupApplicationListResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetGroupApplicationListResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1519,13 +1625,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.ApplicationGroupResponseResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.ApplicationGroupResponseResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1573,13 +1679,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.InviteUserToGroupResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.InviteUserToGroupResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1608,7 +1714,7 @@ const docTemplate = `{ "required": true }, { - "description": "reqMessage为申请进群信息", + "description": "reqMessage为申请进群信息\u003cbr\u003egroupID为申请的群ID", "name": "req", "in": "body", "required": true, @@ -1627,13 +1733,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.JoinGroupResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.JoinGroupResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1681,13 +1787,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.KickGroupMemberResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.KickGroupMemberResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1789,13 +1895,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.DismissGroupResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.DismissGroupResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1803,7 +1909,7 @@ const docTemplate = `{ }, "/group/quit_group": { "post": { - "description": "退出群聊", + "description": "当前用户退出群聊", "consumes": [ "application/json" ], @@ -1813,7 +1919,7 @@ const docTemplate = `{ "tags": [ "群组相关" ], - "summary": "退出群聊", + "summary": "当前用户退出群聊", "operationId": "QuitGroup", "parameters": [ { @@ -1843,13 +1949,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.QuitGroupResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.QuitGroupResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1878,7 +1984,7 @@ const docTemplate = `{ "required": true }, { - "description": "notification为群介绍 \u003cbr\u003e introduction为群公告 \u003cbr\u003e needVerification为加群验证 0为申请需要同意 邀请直接进 1为所有人进群需要验证,除了群主管理员邀请进群 2为直接进群", + "description": "groupID为要修改的群ID\u003cbr\u003egroupName为新的群名称\u003cbr\u003enotification为群介绍 \u003cbr\u003e introduction为群公告 \u003cbr\u003e needVerification为加群验证 0为申请需要同意 邀请直接进 1为所有人进群需要验证,除了群主管理员邀请进群 2为直接进群", "name": "req", "in": "body", "required": true, @@ -1897,13 +2003,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.SetGroupInfoResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.SetGroupInfoResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1932,7 +2038,7 @@ const docTemplate = `{ "required": true }, { - "description": "除了operationID, userID, groupID其他参数可选", + "description": "除了operationID, userID, groupID其他参数可选\u003cbr\u003eex为拓展字段\u003cbr\u003efaceURL为群头像\u003cbr\u003enickName为群昵称\u003cbr\u003eroleLevel为群员角色,1为普通用户 2为群主 3为管理员", "name": "req", "in": "body", "required": true, @@ -1951,13 +2057,13 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.SetGroupMemberInfoResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.SetGroupMemberInfoResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -2005,21 +2111,21 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.TransferGroupOwnerResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.TransferGroupOwnerResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } } }, - "/msg/clear_msg": { + "/msg/batch_send_msg": { "post": { - "description": "清空用户消息", + "description": "管理员批量发送群聊单聊消息 消息格式详细见\u003ca href=\"https://doc.rentsoft.cn/#/server_doc/admin?id=%e6%b6%88%e6%81%af%e7%b1%bb%e5%9e%8b%e6%a0%bc%e5%bc%8f%e6%8f%8f%e8%bf%b0\"\u003e消息格式\u003c/href\u003e", "consumes": [ "application/json" ], @@ -2029,8 +2135,8 @@ const docTemplate = `{ "tags": [ "消息相关" ], - "summary": "清空用户消息", - "operationId": "ClearMsg", + "summary": "管理员批量发送群聊单聊消息", + "operationId": "ManagementBatchSendMsg", "parameters": [ { "type": "string", @@ -2040,40 +2146,73 @@ const docTemplate = `{ "required": true }, { - "description": "userID为要清空的用户ID", - "name": "req", + "description": "该请求和消息结构体一样 \u003cbr\u003e recvIDList为接受消息的用户ID列表", + "name": "管理员批量发送单聊消息", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.CleanUpMsgReq" + "allOf": [ + { + "$ref": "#/definitions/base_info.ManagementBatchSendMsgReq" + }, + { + "type": "object", + "properties": { + "content": { + "$ref": "#/definitions/Open_IM_internal_api_manage.TextElem" + } + } + } + ] + } + }, + { + "description": "该请求和消息结构体一样 \u003cbr\u003e recvIDList为接受消息的用户ID列表", + "name": "管理员批量发送OA通知", + "in": "body", + "required": true, + "schema": { + "allOf": [ + { + "$ref": "#/definitions/base_info.ManagementSendMsgReq" + }, + { + "type": "object", + "properties": { + "content": { + "$ref": "#/definitions/Open_IM_internal_api_manage.OANotificationElem" + } + } + } + ] } } ], "responses": { "0": { - "description": "", + "description": "serverMsgID为服务器消息ID \u003cbr\u003e clientMsgID为客户端消息ID \u003cbr\u003e sendTime为发送消息时间", "schema": { - "$ref": "#/definitions/base_info.CleanUpMsgResp" + "$ref": "#/definitions/base_info.ManagementBatchSendMsgReq" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.CleanUpMsgResp" + "$ref": "#/definitions/base_info.ManagementBatchSendMsgReq" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.CleanUpMsgResp" + "$ref": "#/definitions/base_info.ManagementBatchSendMsgReq" } } } } }, - "/msg/del_msg": { + "/msg/clear_msg": { "post": { - "description": "根据seq列表删除消息", + "description": "清空用户消息", "consumes": [ "application/json" ], @@ -2083,8 +2222,8 @@ const docTemplate = `{ "tags": [ "消息相关" ], - "summary": "根据seq列表删除消息", - "operationId": "DelMsg", + "summary": "清空用户消息", + "operationId": "ClearMsg", "parameters": [ { "type": "string", @@ -2094,12 +2233,12 @@ const docTemplate = `{ "required": true }, { - "description": "userID为要删除的用户ID \u003cbr\u003e seqList为seq列表", + "description": "userID为要清空的用户ID", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.DelMsgReq" + "$ref": "#/definitions/base_info.CleanUpMsgReq" } } ], @@ -2107,27 +2246,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.DelMsgResp" + "$ref": "#/definitions/base_info.CleanUpMsgResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.DelMsgResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.DelMsgResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } } }, - "/office/comment_one_work_moment": { + "/msg/del_msg": { "post": { - "description": "评论一条工作圈", + "description": "根据seq列表删除消息", "consumes": [ "application/json" ], @@ -2135,10 +2274,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "工作圈" + "消息相关" ], - "summary": "评论一条工作圈", - "operationId": "CommentOneWorkMoment", + "summary": "根据seq列表删除消息", + "operationId": "DelMsg", "parameters": [ { "type": "string", @@ -2148,12 +2287,12 @@ const docTemplate = `{ "required": true }, { - "description": "请求", + "description": "userID为要删除的用户ID \u003cbr\u003e seqList为seq列表", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.CommentOneWorkMomentReq" + "$ref": "#/definitions/base_info.DelMsgReq" } } ], @@ -2161,27 +2300,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.CommentOneWorkMomentResp" + "$ref": "#/definitions/base_info.DelMsgResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.CommentOneWorkMomentResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.CommentOneWorkMomentResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } } }, - "/office/create_one_work_moment": { + "/msg/get_all_conversations": { "post": { - "description": "用户创建一条工作圈", + "description": "获取用户所有会话", "consumes": [ "application/json" ], @@ -2189,10 +2328,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "工作圈" + "会话相关" ], - "summary": "创建一条工作圈", - "operationId": "CreateOneWorkMoment", + "summary": "获取用户所有会话", + "operationId": "GetAllConversations", "parameters": [ { "type": "string", @@ -2202,12 +2341,12 @@ const docTemplate = `{ "required": true }, { - "description": "请求 atUserList likeUserList permissionGroupList permissionUserList 字段中userName可以不填", + "description": "ownerUserID为要获取的用户ID", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.CreateOneWorkMomentReq" + "$ref": "#/definitions/base_info.GetAllConversationsReq" } } ], @@ -2215,27 +2354,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.CreateOneWorkMomentResp" + "$ref": "#/definitions/base_info.GetAllConversationsResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.CreateOneWorkMomentResp" + "$ref": "#/definitions/base_info.GetAllConversationsResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.CreateOneWorkMomentResp" + "$ref": "#/definitions/base_info.GetAllConversationsResp" } } } } }, - "/office/create_tag": { + "/msg/get_conversation": { "post": { - "description": "创建标签", + "description": "根据会话ID获取会话", "consumes": [ "application/json" ], @@ -2243,10 +2382,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "标签" + "会话相关" ], - "summary": "创建标签", - "operationId": "CreateTag", + "summary": "根据会话ID获取会话", + "operationId": "GetConversation", "parameters": [ { "type": "string", @@ -2256,12 +2395,12 @@ const docTemplate = `{ "required": true }, { - "description": "请求", + "description": "ownerUserID为要获取的用户ID\u003cbr\u003econversationID为要获取的会话ID", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.CreateTagReq" + "$ref": "#/definitions/base_info.GetConversationReq" } } ], @@ -2269,27 +2408,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.CreateTagResp" + "$ref": "#/definitions/base_info.GetConversationResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.CreateTagResp" + "$ref": "#/definitions/base_info.GetConversationResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.CreateTagResp" + "$ref": "#/definitions/base_info.GetConversationResp" } } } } }, - "/office/delete_comment": { + "/msg/get_conversations": { "post": { - "description": "删除一条评论", + "description": "根据会话ID列表获取会话", "consumes": [ "application/json" ], @@ -2297,10 +2436,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "工作圈" + "会话相关" ], - "summary": "删除一条评论", - "operationId": "DeleteComment", + "summary": "根据会话ID列表获取会话", + "operationId": "GetConversations", "parameters": [ { "type": "string", @@ -2310,12 +2449,12 @@ const docTemplate = `{ "required": true }, { - "description": "请求", + "description": "ownerUserID为要获取的用户ID\u003cbr\u003econversationIDs为要获取的会话ID列表", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.DeleteCommentReq" + "$ref": "#/definitions/base_info.GetConversationsReq" } } ], @@ -2323,27 +2462,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.DeleteCommentResp" + "$ref": "#/definitions/base_info.GetConversationsResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.DeleteCommentResp" + "$ref": "#/definitions/base_info.GetConversationsResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.DeleteCommentResp" + "$ref": "#/definitions/base_info.GetConversationsResp" } } } } }, - "/office/delete_one_work_moment": { + "/msg/manage_send_msg": { "post": { - "description": "根据用户工作圈ID删除一条工作圈", + "description": "管理员发送/撤回消息 消息格式详细见\u003ca href=\"https://doc.rentsoft.cn/#/server_doc/admin?id=%e6%b6%88%e6%81%af%e7%b1%bb%e5%9e%8b%e6%a0%bc%e5%bc%8f%e6%8f%8f%e8%bf%b0\"\u003e消息格式\u003c/href\u003e", "consumes": [ "application/json" ], @@ -2351,10 +2490,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "工作圈" + "消息相关" ], - "summary": "删除一条工作圈", - "operationId": "DeleteOneWorkMoment", + "summary": "管理员发送/撤回消息", + "operationId": "ManagementSendMsg", "parameters": [ { "type": "string", @@ -2364,40 +2503,94 @@ const docTemplate = `{ "required": true }, { - "description": "请求", - "name": "req", + "description": "该请求和消息结构体一样", + "name": "管理员发送文字消息", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.DeleteOneWorkMomentReq" - } - } + "allOf": [ + { + "$ref": "#/definitions/base_info.ManagementSendMsgReq" + }, + { + "type": "object", + "properties": { + "content": { + "$ref": "#/definitions/Open_IM_internal_api_manage.TextElem" + } + } + } + ] + } + }, + { + "description": "该请求和消息结构体一样", + "name": "管理员发送OA通知消息", + "in": "body", + "required": true, + "schema": { + "allOf": [ + { + "$ref": "#/definitions/base_info.ManagementSendMsgReq" + }, + { + "type": "object", + "properties": { + "content": { + "$ref": "#/definitions/Open_IM_internal_api_manage.OANotificationElem" + } + } + } + ] + } + }, + { + "description": "该请求和消息结构体一样", + "name": "管理员撤回单聊消息", + "in": "body", + "required": true, + "schema": { + "allOf": [ + { + "$ref": "#/definitions/base_info.ManagementSendMsgReq" + }, + { + "type": "object", + "properties": { + "content": { + "$ref": "#/definitions/Open_IM_internal_api_manage.RevokeElem" + } + } + } + ] + } + } ], "responses": { "0": { - "description": "", + "description": "serverMsgID为服务器消息ID \u003cbr\u003e clientMsgID为客户端消息ID \u003cbr\u003e sendTime为发送消息时间", "schema": { - "$ref": "#/definitions/base_info.DeleteOneWorkMomentResp" + "$ref": "#/definitions/base_info.ManagementSendMsgResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.DeleteOneWorkMomentResp" + "$ref": "#/definitions/base_info.ManagementSendMsgResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.DeleteOneWorkMomentResp" + "$ref": "#/definitions/base_info.ManagementSendMsgResp" } } } } }, - "/office/delete_tag": { + "/office/comment_one_work_moment": { "post": { - "description": "根据标签ID创建标签", + "description": "评论一条工作圈", "consumes": [ "application/json" ], @@ -2405,10 +2598,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "标签" + "工作圈" ], - "summary": "删除标签", - "operationId": "DeleteTag", + "summary": "评论一条工作圈", + "operationId": "CommentOneWorkMoment", "parameters": [ { "type": "string", @@ -2423,7 +2616,7 @@ const docTemplate = `{ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.DeleteTagReq" + "$ref": "#/definitions/base_info.CommentOneWorkMomentReq" } } ], @@ -2431,27 +2624,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.DeleteTagResp" + "$ref": "#/definitions/base_info.CommentOneWorkMomentResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.DeleteTagResp" + "$ref": "#/definitions/base_info.CommentOneWorkMomentResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.DeleteTagResp" + "$ref": "#/definitions/base_info.CommentOneWorkMomentResp" } } } } }, - "/office/get_send_tag_log": { + "/office/create_one_work_moment": { "post": { - "description": "分页获取发送历史记录", + "description": "用户创建一条工作圈", "consumes": [ "application/json" ], @@ -2459,10 +2652,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "标签" + "工作圈" ], - "summary": "获取发送历史记录", - "operationId": "GetTagSendLogs", + "summary": "创建一条工作圈", + "operationId": "CreateOneWorkMoment", "parameters": [ { "type": "string", @@ -2472,12 +2665,12 @@ const docTemplate = `{ "required": true }, { - "description": "请求", + "description": "请求 atUserList likeUserList permissionGroupList permissionUserList 字段中userName可以不填", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetTagSendLogsReq" + "$ref": "#/definitions/base_info.CreateOneWorkMomentReq" } } ], @@ -2485,27 +2678,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetTagSendLogsResp" + "$ref": "#/definitions/base_info.CreateOneWorkMomentResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetTagSendLogsResp" + "$ref": "#/definitions/base_info.CreateOneWorkMomentResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetTagSendLogsResp" + "$ref": "#/definitions/base_info.CreateOneWorkMomentResp" } } } } }, - "/office/get_user_friend_work_moments": { + "/office/create_tag": { "post": { - "description": "查询用户工作圈页面", + "description": "创建标签", "consumes": [ "application/json" ], @@ -2513,10 +2706,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "工作圈" + "标签" ], - "summary": "查询自己大工作圈页面", - "operationId": "GetUserFriendWorkMoments", + "summary": "创建标签", + "operationId": "CreateTag", "parameters": [ { "type": "string", @@ -2531,7 +2724,7 @@ const docTemplate = `{ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetUserFriendWorkMomentsReq" + "$ref": "#/definitions/base_info.CreateTagReq" } } ], @@ -2539,27 +2732,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetUserFriendWorkMomentsResp" + "$ref": "#/definitions/base_info.CreateTagResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetUserFriendWorkMomentsResp" + "$ref": "#/definitions/base_info.CreateTagResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetUserFriendWorkMomentsResp" + "$ref": "#/definitions/base_info.CreateTagResp" } } } } }, - "/office/get_user_tag_by_id": { + "/office/delete_comment": { "post": { - "description": "通过标签id获取该用户的标签信息", + "description": "删除一条评论", "consumes": [ "application/json" ], @@ -2567,10 +2760,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "标签" + "工作圈" ], - "summary": "获取该用户的标签信息", - "operationId": "GetUserTagByID", + "summary": "删除一条评论", + "operationId": "DeleteComment", "parameters": [ { "type": "string", @@ -2585,7 +2778,7 @@ const docTemplate = `{ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetUserTagByIDReq" + "$ref": "#/definitions/base_info.DeleteCommentReq" } } ], @@ -2593,27 +2786,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetUserTagByIDResp" + "$ref": "#/definitions/base_info.DeleteCommentResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetUserTagByIDResp" + "$ref": "#/definitions/base_info.DeleteCommentResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetUserTagByIDResp" + "$ref": "#/definitions/base_info.DeleteCommentResp" } } } } }, - "/office/get_user_tags": { + "/office/delete_one_work_moment": { "post": { - "description": "用户获取自己的所有的标签", + "description": "根据用户工作圈ID删除一条工作圈", "consumes": [ "application/json" ], @@ -2621,10 +2814,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "标签" + "工作圈" ], - "summary": "获取用户标签信息", - "operationId": "GetUserTags", + "summary": "删除一条工作圈", + "operationId": "DeleteOneWorkMoment", "parameters": [ { "type": "string", @@ -2639,7 +2832,7 @@ const docTemplate = `{ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetUserTagsReq" + "$ref": "#/definitions/base_info.DeleteOneWorkMomentReq" } } ], @@ -2647,27 +2840,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetUserTagsResp" + "$ref": "#/definitions/base_info.DeleteOneWorkMomentResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetUserTagsResp" + "$ref": "#/definitions/base_info.DeleteOneWorkMomentResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetUserTagsResp" + "$ref": "#/definitions/base_info.DeleteOneWorkMomentResp" } } } } }, - "/office/get_user_work_moments": { + "/office/delete_tag": { "post": { - "description": "查询用户工作圈", + "description": "根据标签ID创建标签", "consumes": [ "application/json" ], @@ -2675,10 +2868,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "工作圈" + "标签" ], - "summary": "查询用户工作圈", - "operationId": "GetUserWorkMoments", + "summary": "删除标签", + "operationId": "DeleteTag", "parameters": [ { "type": "string", @@ -2693,7 +2886,7 @@ const docTemplate = `{ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetUserWorkMomentsReq" + "$ref": "#/definitions/base_info.DeleteTagReq" } } ], @@ -2701,27 +2894,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetUserWorkMomentsResp" + "$ref": "#/definitions/base_info.DeleteTagResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetUserWorkMomentsResp" + "$ref": "#/definitions/base_info.DeleteTagResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetUserWorkMomentsResp" + "$ref": "#/definitions/base_info.DeleteTagResp" } } } } }, - "/office/get_work_moment_by_id": { + "/office/get_send_tag_log": { "post": { - "description": "通过ID获取工作圈", + "description": "分页获取发送历史记录", "consumes": [ "application/json" ], @@ -2729,10 +2922,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "工作圈" + "标签" ], - "summary": "通过ID获取工作圈", - "operationId": "GetWorkMomentByID", + "summary": "获取发送历史记录", + "operationId": "GetTagSendLogs", "parameters": [ { "type": "string", @@ -2747,7 +2940,7 @@ const docTemplate = `{ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetWorkMomentByIDReq" + "$ref": "#/definitions/base_info.GetTagSendLogsReq" } } ], @@ -2755,27 +2948,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetWorkMomentByIDResp" + "$ref": "#/definitions/base_info.GetTagSendLogsResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetWorkMomentByIDResp" + "$ref": "#/definitions/base_info.GetTagSendLogsResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetWorkMomentByIDResp" + "$ref": "#/definitions/base_info.GetTagSendLogsResp" } } } } }, - "/office/like_one_work_moment": { + "/office/get_user_friend_work_moments": { "post": { - "description": "工作圈ID点赞一条工作圈", + "description": "查询用户工作圈页面", "consumes": [ "application/json" ], @@ -2785,8 +2978,8 @@ const docTemplate = `{ "tags": [ "工作圈" ], - "summary": "点赞一条工作圈", - "operationId": "LikeOneWorkMoment", + "summary": "查询自己大工作圈页面", + "operationId": "GetUserFriendWorkMoments", "parameters": [ { "type": "string", @@ -2801,7 +2994,7 @@ const docTemplate = `{ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.LikeOneWorkMomentReq" + "$ref": "#/definitions/base_info.GetUserFriendWorkMomentsReq" } } ], @@ -2809,27 +3002,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.LikeOneWorkMomentResp" + "$ref": "#/definitions/base_info.GetUserFriendWorkMomentsResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.LikeOneWorkMomentResp" + "$ref": "#/definitions/base_info.GetUserFriendWorkMomentsResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.LikeOneWorkMomentResp" + "$ref": "#/definitions/base_info.GetUserFriendWorkMomentsResp" } } } } }, - "/office/send_msg_to_tag": { + "/office/get_user_tag_by_id": { "post": { - "description": "对标签用户发送消息", + "description": "通过标签id获取该用户的标签信息", "consumes": [ "application/json" ], @@ -2839,8 +3032,8 @@ const docTemplate = `{ "tags": [ "标签" ], - "summary": "发送标签消息", - "operationId": "SendMsg2Tag", + "summary": "获取该用户的标签信息", + "operationId": "GetUserTagByID", "parameters": [ { "type": "string", @@ -2855,7 +3048,7 @@ const docTemplate = `{ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.SendMsg2TagReq" + "$ref": "#/definitions/base_info.GetUserTagByIDReq" } } ], @@ -2863,27 +3056,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.SendMsg2TagResp" + "$ref": "#/definitions/base_info.GetUserTagByIDResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.SendMsg2TagResp" + "$ref": "#/definitions/base_info.GetUserTagByIDResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.SendMsg2TagResp" + "$ref": "#/definitions/base_info.GetUserTagByIDResp" } } } } }, - "/office/set_tag": { + "/office/get_user_tags": { "post": { - "description": "根据标签ID修改标签用户列表, 名称", + "description": "用户获取自己的所有的标签", "consumes": [ "application/json" ], @@ -2893,8 +3086,8 @@ const docTemplate = `{ "tags": [ "标签" ], - "summary": "修改标签", - "operationId": "SetTag", + "summary": "获取用户标签信息", + "operationId": "GetUserTags", "parameters": [ { "type": "string", @@ -2909,7 +3102,7 @@ const docTemplate = `{ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.SetTagReq" + "$ref": "#/definitions/base_info.GetUserTagsReq" } } ], @@ -2917,27 +3110,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.SetTagResp" + "$ref": "#/definitions/base_info.GetUserTagsResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.SetTagResp" + "$ref": "#/definitions/base_info.GetUserTagsResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.SetTagResp" + "$ref": "#/definitions/base_info.GetUserTagsResp" } } } } }, - "/third/minio_upload": { + "/office/get_user_work_moments": { "post": { - "description": "minio上传文件(web api), 请注意本api请求为form并非json", + "description": "查询用户工作圈", "consumes": [ "application/json" ], @@ -2945,10 +3138,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "第三方服务相关" + "工作圈" ], - "summary": "minio上传文件(web api)", - "operationId": "MinioUploadFile", + "summary": "查询用户工作圈", + "operationId": "GetUserWorkMoments", "parameters": [ { "type": "string", @@ -2958,52 +3151,148 @@ const docTemplate = `{ "required": true }, { - "type": "file", - "description": "要上传的文件文件", - "name": "file", - "in": "formData", - "required": true + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.GetUserWorkMomentsReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.GetUserWorkMomentsResp" + } }, - { - "type": "integer", - "description": "文件类型", - "name": "fileType", - "in": "formData", + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.GetUserWorkMomentsResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.GetUserWorkMomentsResp" + } + } + } + } + }, + "/office/get_work_moment_by_id": { + "post": { + "description": "通过ID获取工作圈", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "工作圈" + ], + "summary": "通过ID获取工作圈", + "operationId": "GetWorkMomentByID", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", "required": true }, + { + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.GetWorkMomentByIDReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.GetWorkMomentByIDResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.GetWorkMomentByIDResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.GetWorkMomentByIDResp" + } + } + } + } + }, + "/office/like_one_work_moment": { + "post": { + "description": "工作圈ID点赞一条工作圈", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "工作圈" + ], + "summary": "点赞一条工作圈", + "operationId": "LikeOneWorkMoment", + "parameters": [ { "type": "string", - "description": "操作唯一ID", - "name": "operationID", - "in": "formData", + "description": "im token", + "name": "token", + "in": "header", "required": true + }, + { + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.LikeOneWorkMomentReq" + } } ], "responses": { "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.MinioUploadFileResp" + "$ref": "#/definitions/base_info.LikeOneWorkMomentResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.MinioUploadFileResp" + "$ref": "#/definitions/base_info.LikeOneWorkMomentResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.MinioUploadFileResp" + "$ref": "#/definitions/base_info.LikeOneWorkMomentResp" } } } } }, - "/user/account_check": { + "/office/send_msg_to_tag": { "post": { - "description": "传入UserIDList检查列表账户注册状态,并且返回结果", + "description": "对标签用户发送消息", "consumes": [ "application/json" ], @@ -3011,10 +3300,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "用户相关" + "标签" ], - "summary": "检查列表账户注册状态,并且返回结果", - "operationId": "AccountCheck", + "summary": "发送标签消息", + "operationId": "SendMsg2Tag", "parameters": [ { "type": "string", @@ -3024,12 +3313,12 @@ const docTemplate = `{ "required": true }, { - "description": "请求体", + "description": "请求", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.AccountCheckReq" + "$ref": "#/definitions/base_info.SendMsg2TagReq" } } ], @@ -3037,27 +3326,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.AccountCheckResp" + "$ref": "#/definitions/base_info.SendMsg2TagResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.AccountCheckResp" + "$ref": "#/definitions/base_info.SendMsg2TagResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.AccountCheckResp" + "$ref": "#/definitions/base_info.SendMsg2TagResp" } } } } }, - "/user/get_all_users_uid": { + "/office/set_tag": { "post": { - "description": "获取所有用户uid列表", + "description": "根据标签ID修改标签用户列表, 名称", "consumes": [ "application/json" ], @@ -3065,10 +3354,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "用户相关" + "标签" ], - "summary": "获取所有用户uid列表", - "operationId": "GetAllUsersUid", + "summary": "修改标签", + "operationId": "SetTag", "parameters": [ { "type": "string", @@ -3078,12 +3367,12 @@ const docTemplate = `{ "required": true }, { - "description": "请求体", + "description": "请求", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetAllUsersUidReq" + "$ref": "#/definitions/base_info.SetTagReq" } } ], @@ -3091,27 +3380,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetAllUsersUidResp" + "$ref": "#/definitions/base_info.SetTagResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetAllUsersUidResp" + "$ref": "#/definitions/base_info.SetTagResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetAllUsersUidResp" + "$ref": "#/definitions/base_info.SetTagResp" } } } } }, - "/user/get_self_user_info": { + "/organization/create_department": { "post": { - "description": "传入ID获取自己的信息", + "description": "创建部门", "consumes": [ "application/json" ], @@ -3119,10 +3408,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "用户相关" + "组织架构相关" ], - "summary": "获取自己的信息", - "operationId": "GetSelfUserInfo", + "summary": "创建部门", + "operationId": "CreateDepartment", "parameters": [ { "type": "string", @@ -3132,12 +3421,12 @@ const docTemplate = `{ "required": true }, { - "description": "请求体", + "description": "请求", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetSelfUserInfoReq" + "$ref": "#/definitions/base_info.CreateDepartmentReq" } } ], @@ -3147,13 +3436,13 @@ const docTemplate = `{ "schema": { "allOf": [ { - "$ref": "#/definitions/base_info.GetSelfUserInfoResp" + "$ref": "#/definitions/base_info.CreateDepartmentResp" }, { "type": "object", "properties": { "data": { - "$ref": "#/definitions/server_api_params.UserInfo" + "$ref": "#/definitions/server_api_params.Department" } } } @@ -3163,21 +3452,21 @@ const docTemplate = `{ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetSelfUserInfoResp" + "$ref": "#/definitions/base_info.CreateDepartmentResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetSelfUserInfoResp" + "$ref": "#/definitions/base_info.CreateDepartmentResp" } } } } }, - "/user/get_users_info": { + "/organization/create_department_member": { "post": { - "description": "根据用户列表批量获取用户信息", + "description": "创建部门用户", "consumes": [ "application/json" ], @@ -3185,10 +3474,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "用户相关" + "组织架构相关" ], - "summary": "获取用户信息", - "operationId": "GetUsersInfo", + "summary": "创建部门用户", + "operationId": "CreateDepartmentMember", "parameters": [ { "type": "string", @@ -3198,12 +3487,12 @@ const docTemplate = `{ "required": true }, { - "description": "请求体", + "description": "请求", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetUsersInfoReq" + "$ref": "#/definitions/base_info.CreateDepartmentMemberReq" } } ], @@ -3211,27 +3500,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetUsersInfoResp" + "$ref": "#/definitions/base_info.CreateDepartmentMemberResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetUsersInfoResp" + "$ref": "#/definitions/base_info.CreateDepartmentMemberResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetUsersInfoResp" + "$ref": "#/definitions/base_info.CreateDepartmentMemberResp" } } } } }, - "/user/get_users_online_status": { + "/organization/create_organization_user": { "post": { - "description": "获取用户在线状态", + "description": "组织架构导入用户", "consumes": [ "application/json" ], @@ -3239,10 +3528,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "用户相关" + "组织架构相关" ], - "summary": "获取用户在线状态", - "operationId": "GetUsersOnlineStatus", + "summary": "组织架构导入用户", + "operationId": "CreateOrganizationUser", "parameters": [ { "type": "string", @@ -3252,12 +3541,12 @@ const docTemplate = `{ "required": true }, { - "description": "请求体", + "description": "请求", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetUsersOnlineStatusReq" + "$ref": "#/definitions/base_info.CreateOrganizationUserReq" } } ], @@ -3265,27 +3554,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetUsersOnlineStatusResp" + "$ref": "#/definitions/base_info.CreateOrganizationUserResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetUsersOnlineStatusResp" + "$ref": "#/definitions/base_info.CreateOrganizationUserResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetUsersOnlineStatusResp" + "$ref": "#/definitions/base_info.CreateOrganizationUserResp" } } } } }, - "/user/set_global_msg_recv_opt": { + "/organization/delete_department": { "post": { - "description": "设置全局免打扰", + "description": "删除部门", "consumes": [ "application/json" ], @@ -3293,10 +3582,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "用户相关" + "组织架构相关" ], - "summary": "设置全局免打扰", - "operationId": "SetGlobalRecvMessageOpt", + "summary": "删除部门", + "operationId": "DeleteDepartment", "parameters": [ { "type": "string", @@ -3306,12 +3595,12 @@ const docTemplate = `{ "required": true }, { - "description": "请求体", + "description": "请求", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.SetGlobalRecvMessageOptReq" + "$ref": "#/definitions/base_info.DeleteDepartmentReq" } } ], @@ -3319,27 +3608,27 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.SetGlobalRecvMessageOptResp" + "$ref": "#/definitions/base_info.DeleteDepartmentResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.SetGlobalRecvMessageOptResp" + "$ref": "#/definitions/base_info.DeleteDepartmentResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.SetGlobalRecvMessageOptResp" + "$ref": "#/definitions/base_info.DeleteDepartmentResp" } } } } }, - "/user/update_user_info": { + "/organization/delete_organization_user": { "post": { - "description": "修改用户信息 userID faceURL等", + "description": "删除组织架构中某个用户", "consumes": [ "application/json" ], @@ -3347,10 +3636,10 @@ const docTemplate = `{ "application/json" ], "tags": [ - "用户相关" + "组织架构相关" ], - "summary": "修改用户信息", - "operationId": "UpdateUserInfo", + "summary": "删除组织架构中某个用户", + "operationId": "DeleteOrganizationUser", "parameters": [ { "type": "string", @@ -3360,12 +3649,12 @@ const docTemplate = `{ "required": true }, { - "description": "请求体", + "description": "请求", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.UpdateSelfUserInfoReq" + "$ref": "#/definitions/base_info.DeleteOrganizationUserReq" } } ], @@ -3373,82 +3662,1611 @@ const docTemplate = `{ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.UpdateUserInfoResp" + "$ref": "#/definitions/base_info.DeleteOrganizationUserResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.UpdateUserInfoResp" + "$ref": "#/definitions/base_info.DeleteOrganizationUserResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.UpdateUserInfoResp" + "$ref": "#/definitions/base_info.DeleteOrganizationUserResp" } } } } - } - }, - "definitions": { - "base_info.AccountCheckReq": { - "type": "object", - "required": [ - "checkUserIDList", - "operationID" - ], - "properties": { - "checkUserIDList": { - "type": "array", - "maxItems": 100, - "items": { - "type": "string" - } - }, - "operationID": { - "type": "string" - } - } }, - "base_info.AccountCheckResp": { - "type": "object", - "properties": { - "data": { - "type": "array", - "items": { - "$ref": "#/definitions/user.AccountCheckResp_SingleUserStatus" + "/organization/delete_user_in_department": { + "post": { + "description": "删除部门中某个用户", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "组织架构相关" + ], + "summary": "删除部门中某个用户", + "operationId": "DeleteUserInDepartment", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.DeleteUserInDepartmentReq" + } } - }, - "errCode": { - "type": "integer" - }, - "errMsg": { - "type": "string" - } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.DeleteUserInDepartmentResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.DeleteUserInDepartmentResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.DeleteUserInDepartmentResp" + } + } + } + } + }, + "/organization/get_department_member": { + "post": { + "description": "获取部门中所有成员", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "组织架构相关" + ], + "summary": "获取部门中所有成员", + "operationId": "GetDepartmentMember", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.GetDepartmentMemberReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "allOf": [ + { + "$ref": "#/definitions/base_info.GetDepartmentMemberResp" + }, + { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/server_api_params.UserDepartmentMember" + } + } + } + ] + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.GetDepartmentMemberResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.GetDepartmentMemberResp" + } + } + } + } + }, + "/organization/get_sub_department": { + "post": { + "description": "获取子部门列表", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "组织架构相关" + ], + "summary": "获取子部门列表", + "operationId": "GetSubDepartment", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.GetSubDepartmentReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.GetSubDepartmentResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.GetSubDepartmentResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.GetSubDepartmentResp" + } + } + } + } + }, + "/organization/get_user_in_department": { + "post": { + "description": "获取部门中的所有用户", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "组织架构相关" + ], + "summary": "获取部门中的所有用户", + "operationId": "GetUserInDepartment", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.GetUserInDepartmentReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "allOf": [ + { + "$ref": "#/definitions/base_info.GetUserInDepartmentResp" + }, + { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/server_api_params.UserInDepartment" + } + } + } + ] + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.GetUserInDepartmentResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.GetUserInDepartmentResp" + } + } + } + } + }, + "/organization/update_department": { + "post": { + "description": "更新部门信息", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "组织架构相关" + ], + "summary": "更新部门信息", + "operationId": "UpdateDepartment", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.UpdateDepartmentReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.UpdateDepartmentResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.UpdateDepartmentResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.UpdateDepartmentResp" + } + } + } + } + }, + "/organization/update_organization_user": { + "post": { + "description": "更新组织架构中的用户", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "组织架构相关" + ], + "summary": "更新组织架构中的用户", + "operationId": "UpdateOrganizationUser", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.UpdateOrganizationUserReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.UpdateOrganizationUserResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.UpdateOrganizationUserResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.UpdateOrganizationUserResp" + } + } + } + } + }, + "/organization/update_user_in_department": { + "post": { + "description": "更新部门中某个用户", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "组织架构相关" + ], + "summary": "更新部门中某个用户", + "operationId": "UpdateUserInDepartment", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.UpdateUserInDepartmentReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.UpdateUserInDepartmentResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.UpdateUserInDepartmentResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.UpdateUserInDepartmentResp" + } + } + } + } + }, + "/third/minio_upload": { + "post": { + "description": "minio上传文件(web api), 请注意本api请求为form并非json", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "第三方服务相关" + ], + "summary": "minio上传文件(web api)", + "operationId": "MinioUploadFile", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "type": "file", + "description": "要上传的文件文件", + "name": "file", + "in": "formData", + "required": true + }, + { + "type": "integer", + "description": "文件类型", + "name": "fileType", + "in": "formData", + "required": true + }, + { + "type": "string", + "description": "操作唯一ID", + "name": "operationID", + "in": "formData", + "required": true + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.MinioUploadFileResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.Swagger400Resp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.Swagger500Resp" + } + } + } + } + }, + "/user/account_check": { + "post": { + "description": "传入UserIDList检查列表账户注册状态,并且返回结果", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "用户相关" + ], + "summary": "检查列表账户注册状态,并且返回结果", + "operationId": "AccountCheck", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求体", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.AccountCheckReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.AccountCheckResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.AccountCheckResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.AccountCheckResp" + } + } + } + } + }, + "/user/get_all_users_uid": { + "post": { + "description": "获取所有用户uid列表", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "用户相关" + ], + "summary": "获取所有用户uid列表", + "operationId": "GetAllUsersUid", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求体", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.GetAllUsersUidReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.GetAllUsersUidResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.GetAllUsersUidResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.GetAllUsersUidResp" + } + } + } + } + }, + "/user/get_self_user_info": { + "post": { + "description": "传入ID获取自己的信息", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "用户相关" + ], + "summary": "获取自己的信息", + "operationId": "GetSelfUserInfo", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求体", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.GetSelfUserInfoReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "allOf": [ + { + "$ref": "#/definitions/base_info.GetSelfUserInfoResp" + }, + { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/server_api_params.UserInfo" + } + } + } + ] + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.Swagger400Resp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.Swagger500Resp" + } + } + } + } + }, + "/user/get_users_info": { + "post": { + "description": "根据用户列表批量获取用户信息", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "用户相关" + ], + "summary": "获取用户信息", + "operationId": "GetUsersInfo", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求体", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.GetUsersInfoReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "allOf": [ + { + "$ref": "#/definitions/base_info.GetUsersInfoResp" + }, + { + "type": "object", + "properties": { + "Data": { + "type": "array", + "items": { + "$ref": "#/definitions/server_api_params.PublicUserInfo" + } + } + } + } + ] + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.Swagger400Resp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.Swagger500Resp" + } + } + } + } + }, + "/user/get_users_online_status": { + "post": { + "description": "获取用户在线状态", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "用户相关" + ], + "summary": "获取用户在线状态", + "operationId": "GetUsersOnlineStatus", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求体", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.GetUsersOnlineStatusReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.GetUsersOnlineStatusResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.Swagger400Resp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.Swagger500Resp" + } + } + } + } + }, + "/user/set_global_msg_recv_opt": { + "post": { + "description": "设置全局免打扰", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "用户相关" + ], + "summary": "设置全局免打扰", + "operationId": "SetGlobalRecvMessageOpt", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "globalRecvMsgOpt为全局免打扰设置0为关闭 1为开启", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.SetGlobalRecvMessageOptReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.SetGlobalRecvMessageOptResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.Swagger400Resp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.Swagger500Resp" + } + } + } + } + }, + "/user/update_user_info": { + "post": { + "description": "修改用户信息 userID faceURL等", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "用户相关" + ], + "summary": "修改用户信息", + "operationId": "UpdateUserInfo", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求体", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.UpdateSelfUserInfoReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.UpdateUserInfoResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.Swagger400Resp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.Swagger500Resp" + } + } + } + } + } + }, + "definitions": { + "Open_IM_internal_api_manage.FileElem": { + "type": "object", + "properties": { + "fileName": { + "type": "string" + }, + "filePath": { + "type": "string" + }, + "fileSize": { + "type": "integer" + }, + "sourceURL": { + "type": "string" + }, + "uuid": { + "type": "string" + } + } + }, + "Open_IM_internal_api_manage.OANotificationElem": { + "type": "object", + "required": [ + "notificationFaceURL", + "notificationName", + "notificationType", + "text" + ], + "properties": { + "ex": { + "type": "string" + }, + "fileElem": { + "$ref": "#/definitions/Open_IM_internal_api_manage.FileElem" + }, + "mixType": { + "type": "integer" + }, + "notificationFaceURL": { + "type": "string" + }, + "notificationName": { + "type": "string" + }, + "notificationType": { + "type": "integer" + }, + "pictureElem": { + "$ref": "#/definitions/Open_IM_internal_api_manage.PictureElem" + }, + "soundElem": { + "$ref": "#/definitions/Open_IM_internal_api_manage.SoundElem" + }, + "text": { + "type": "string" + }, + "url": { + "type": "string" + }, + "videoElem": { + "$ref": "#/definitions/Open_IM_internal_api_manage.VideoElem" + } + } + }, + "Open_IM_internal_api_manage.PictureBaseInfo": { + "type": "object", + "properties": { + "height": { + "type": "integer" + }, + "size": { + "type": "integer" + }, + "type": { + "type": "string" + }, + "url": { + "type": "string" + }, + "uuid": { + "type": "string" + }, + "width": { + "type": "integer" + } + } + }, + "Open_IM_internal_api_manage.PictureElem": { + "type": "object", + "properties": { + "bigPicture": { + "$ref": "#/definitions/Open_IM_internal_api_manage.PictureBaseInfo" + }, + "snapshotPicture": { + "$ref": "#/definitions/Open_IM_internal_api_manage.PictureBaseInfo" + }, + "sourcePath": { + "type": "string" + }, + "sourcePicture": { + "$ref": "#/definitions/Open_IM_internal_api_manage.PictureBaseInfo" + } + } + }, + "Open_IM_internal_api_manage.RevokeElem": { + "type": "object", + "required": [ + "revokeMsgClientID" + ], + "properties": { + "revokeMsgClientID": { + "type": "string" + } + } + }, + "Open_IM_internal_api_manage.SoundElem": { + "type": "object", + "properties": { + "dataSize": { + "type": "integer" + }, + "duration": { + "type": "integer" + }, + "soundPath": { + "type": "string" + }, + "sourceURL": { + "type": "string" + }, + "uuid": { + "type": "string" + } + } + }, + "Open_IM_internal_api_manage.TextElem": { + "type": "object", + "required": [ + "text" + ], + "properties": { + "text": { + "type": "string" + } + } + }, + "Open_IM_internal_api_manage.VideoElem": { + "type": "object", + "properties": { + "duration": { + "type": "integer" + }, + "snapshotHeight": { + "type": "integer" + }, + "snapshotPath": { + "type": "string" + }, + "snapshotSize": { + "type": "integer" + }, + "snapshotURL": { + "type": "string" + }, + "snapshotUUID": { + "type": "string" + }, + "snapshotWidth": { + "type": "integer" + }, + "videoPath": { + "type": "string" + }, + "videoSize": { + "type": "integer" + }, + "videoType": { + "type": "string" + }, + "videoURL": { + "type": "string" + }, + "videoUUID": { + "type": "string" + } + } + }, + "base_info.AccountCheckReq": { + "type": "object", + "required": [ + "checkUserIDList", + "operationID" + ], + "properties": { + "checkUserIDList": { + "type": "array", + "maxItems": 100, + "items": { + "type": "string" + } + }, + "operationID": { + "type": "string" + } + } + }, + "base_info.AccountCheckResp": { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/user.AccountCheckResp_SingleUserStatus" + } + }, + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.AddBlacklistReq": { + "type": "object", + "required": [ + "fromUserID", + "operationID", + "toUserID" + ], + "properties": { + "fromUserID": { + "type": "string" + }, + "operationID": { + "type": "string" + }, + "toUserID": { + "type": "string" + } + } + }, + "base_info.AddBlacklistResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.AddFriendReq": { + "type": "object", + "required": [ + "fromUserID", + "operationID", + "toUserID" + ], + "properties": { + "fromUserID": { + "type": "string" + }, + "operationID": { + "type": "string" + }, + "reqMsg": { + "type": "string" + }, + "toUserID": { + "type": "string" + } + } + }, + "base_info.AddFriendResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.AddFriendResponseReq": { + "type": "object", + "required": [ + "flag", + "fromUserID", + "operationID", + "toUserID" + ], + "properties": { + "flag": { + "type": "integer", + "enum": [ + -1, + 0, + 1 + ] + }, + "fromUserID": { + "type": "string" + }, + "handleMsg": { + "type": "string" + }, + "operationID": { + "type": "string" + }, + "toUserID": { + "type": "string" + } + } + }, + "base_info.AddFriendResponseResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.ApplicationGroupResponseReq": { + "type": "object", + "required": [ + "fromUserID", + "groupID", + "handleResult", + "operationID" + ], + "properties": { + "fromUserID": { + "description": "application from FromUserID", + "type": "string" + }, + "groupID": { + "type": "string" + }, + "handleResult": { + "type": "integer", + "enum": [ + -1, + 1 + ] + }, + "handledMsg": { + "type": "string" + }, + "operationID": { + "type": "string" + } + } + }, + "base_info.ApplicationGroupResponseResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.CancelMuteGroupMemberReq": { + "type": "object", + "required": [ + "groupID", + "operationID", + "userID" + ], + "properties": { + "groupID": { + "type": "string" + }, + "operationID": { + "type": "string" + }, + "userID": { + "type": "string" + } + } + }, + "base_info.CancelMuteGroupMemberResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.CancelMuteGroupReq": { + "type": "object", + "required": [ + "groupID", + "operationID" + ], + "properties": { + "groupID": { + "type": "string" + }, + "operationID": { + "type": "string" + } } }, - "base_info.AddBlacklistReq": { + "base_info.CancelMuteGroupResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.CleanUpMsgReq": { "type": "object", "required": [ - "fromUserID", "operationID", - "toUserID" + "userID" ], "properties": { - "fromUserID": { + "operationID": { + "type": "string" + }, + "userID": { + "type": "string" + } + } + }, + "base_info.CleanUpMsgResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.Comment": { + "type": "object", + "properties": { + "content": { + "type": "string" + }, + "contentID": { + "type": "string" + }, + "createTime": { + "type": "integer" + }, + "replyUserID": { + "type": "string" + }, + "replyUserName": { + "type": "string" + }, + "userID": { + "type": "string" + }, + "userName": { + "type": "string" + } + } + }, + "base_info.CommentOneWorkMomentReq": { + "type": "object", + "required": [ + "content", + "operationID", + "workMomentID" + ], + "properties": { + "content": { + "type": "string" + }, + "operationID": { + "type": "string" + }, + "replyUserID": { + "type": "string" + }, + "workMomentID": { + "type": "string" + } + } + }, + "base_info.CommentOneWorkMomentResp": { + "type": "object", + "properties": { + "data": { + "type": "object" + }, + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.Conversation": { + "type": "object", + "required": [ + "conversationID", + "conversationType", + "ownerUserID" + ], + "properties": { + "attachedInfo": { + "type": "string" + }, + "conversationID": { + "type": "string" + }, + "conversationType": { + "type": "integer" + }, + "draftTextTime": { + "type": "integer" + }, + "ex": { + "type": "string" + }, + "groupAtType": { + "type": "integer" + }, + "groupID": { + "type": "string" + }, + "isNotInGroup": { + "type": "boolean" + }, + "isPinned": { + "type": "boolean" + }, + "isPrivateChat": { + "type": "boolean" + }, + "ownerUserID": { + "type": "string" + }, + "recvMsgOpt": { + "type": "integer", + "enum": [ + 0, + 1, + 2 + ] + }, + "unreadCount": { + "type": "integer" + }, + "userID": { + "type": "string" + } + } + }, + "base_info.CreateDepartmentMemberReq": { + "type": "object", + "required": [ + "operationID" + ], + "properties": { + "departmentID": { + "type": "string" + }, + "ex": { + "type": "string" + }, + "leader": { + "type": "integer" + }, + "operationID": { + "type": "string" + }, + "order": { + "type": "integer" + }, + "position": { + "type": "string" + }, + "status": { + "type": "integer" + }, + "userID": { + "type": "string" + } + } + }, + "base_info.CreateDepartmentMemberResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.CreateDepartmentReq": { + "type": "object", + "required": [ + "operationID" + ], + "properties": { + "createTime": { + "type": "integer" + }, + "departmentID": { + "type": "string" + }, + "departmentType": { + "type": "integer" + }, + "ex": { + "type": "string" + }, + "faceURL": { + "type": "string" + }, + "memberNum": { + "type": "integer" + }, + "name": { + "type": "string" + }, + "operationID": { + "type": "string" + }, + "order": { + "type": "integer" + }, + "parentID": { + "type": "string" + }, + "subDepartmentNum": { + "type": "integer" + } + } + }, + "base_info.CreateDepartmentResp": { + "type": "object", + "properties": { + "data": { + "type": "object", + "additionalProperties": true + }, + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.CreateGroupReq": { + "type": "object", + "required": [ + "operationID" + ], + "properties": { + "ex": { + "type": "string" + }, + "faceURL": { + "type": "string" + }, + "groupID": { + "type": "string" + }, + "groupName": { + "type": "string" + }, + "groupType": { + "type": "integer" + }, + "introduction": { + "type": "string" + }, + "memberList": { + "type": "array", + "items": { + "$ref": "#/definitions/base_info.GroupAddMemberInfo" + } + }, + "notification": { "type": "string" }, "operationID": { "type": "string" }, - "toUserID": { + "ownerUserID": { "type": "string" } } }, - "base_info.AddBlacklistResp": { + "base_info.CreateGroupResp": { "type": "object", "properties": { "errCode": { @@ -3459,31 +5277,23 @@ const docTemplate = `{ } } }, - "base_info.AddFriendReq": { + "base_info.CreateOneWorkMomentReq": { "type": "object", - "required": [ - "fromUserID", - "operationID", - "toUserID" - ], "properties": { - "fromUserID": { - "type": "string" - }, "operationID": { "type": "string" }, - "reqMsg": { - "type": "string" - }, - "toUserID": { - "type": "string" + "workMoment": { + "$ref": "#/definitions/office.WorkMoment" } } }, - "base_info.AddFriendResp": { + "base_info.CreateOneWorkMomentResp": { "type": "object", "properties": { + "data": { + "type": "object" + }, "errCode": { "type": "integer" }, @@ -3492,38 +5302,51 @@ const docTemplate = `{ } } }, - "base_info.AddFriendResponseReq": { + "base_info.CreateOrganizationUserReq": { "type": "object", "required": [ - "flag", - "fromUserID", - "operationID", - "toUserID" + "operationID" ], "properties": { - "flag": { - "type": "integer", - "enum": [ - -1, - 0, - 1 - ] + "birth": { + "type": "integer" }, - "fromUserID": { + "createTime": { + "type": "integer" + }, + "email": { "type": "string" }, - "handleMsg": { + "englishName": { + "type": "string" + }, + "ex": { + "type": "string" + }, + "faceURL": { + "type": "string" + }, + "gender": { + "type": "integer" + }, + "mobile": { + "type": "string" + }, + "nickname": { "type": "string" }, "operationID": { "type": "string" }, - "toUserID": { + "telephone": { + "type": "string" + }, + "userID": { "type": "string" } } }, - "base_info.AddFriendResponseResp": { + "base_info.CreateOrganizationUserResp": { "type": "object", "properties": { "errCode": { @@ -3534,38 +5357,31 @@ const docTemplate = `{ } } }, - "base_info.ApplicationGroupResponseReq": { + "base_info.CreateTagReq": { "type": "object", "required": [ - "fromUserID", - "groupID", - "handleResult", - "operationID" + "operationID", + "tagName", + "userIDList" ], "properties": { - "fromUserID": { - "description": "application from FromUserID", - "type": "string" - }, - "groupID": { + "operationID": { "type": "string" }, - "handleResult": { - "type": "integer", - "enum": [ - -1, - 1 - ] - }, - "handledMsg": { + "tagName": { + "description": "tag名称", "type": "string" }, - "operationID": { - "type": "string" + "userIDList": { + "description": "用户ID列表", + "type": "array", + "items": { + "type": "string" + } } } }, - "base_info.ApplicationGroupResponseResp": { + "base_info.CreateTagResp": { "type": "object", "properties": { "errCode": { @@ -3576,26 +5392,29 @@ const docTemplate = `{ } } }, - "base_info.CancelMuteGroupMemberReq": { + "base_info.DelMsgReq": { "type": "object", "required": [ - "groupID", "operationID", + "seqList", "userID" ], "properties": { - "groupID": { - "type": "string" - }, "operationID": { "type": "string" }, + "seqList": { + "type": "array", + "items": { + "type": "integer" + } + }, "userID": { "type": "string" } } }, - "base_info.CancelMuteGroupMemberResp": { + "base_info.DelMsgResp": { "type": "object", "properties": { "errCode": { @@ -3606,24 +5425,31 @@ const docTemplate = `{ } } }, - "base_info.CancelMuteGroupReq": { + "base_info.DeleteCommentReq": { "type": "object", "required": [ - "groupID", - "operationID" + "contentID", + "operationID", + "workMomentID" ], "properties": { - "groupID": { + "contentID": { "type": "string" }, "operationID": { "type": "string" + }, + "workMomentID": { + "type": "string" } } }, - "base_info.CancelMuteGroupResp": { + "base_info.DeleteCommentResp": { "type": "object", "properties": { + "data": { + "type": "object" + }, "errCode": { "type": "integer" }, @@ -3632,22 +5458,22 @@ const docTemplate = `{ } } }, - "base_info.CleanUpMsgReq": { + "base_info.DeleteDepartmentReq": { "type": "object", "required": [ - "operationID", - "userID" + "departmentID", + "operationID" ], "properties": { - "operationID": { + "departmentID": { "type": "string" }, - "userID": { + "operationID": { "type": "string" } } }, - "base_info.CleanUpMsgResp": { + "base_info.DeleteDepartmentResp": { "type": "object", "properties": { "errCode": { @@ -3658,60 +5484,28 @@ const docTemplate = `{ } } }, - "base_info.Comment": { - "type": "object", - "properties": { - "content": { - "type": "string" - }, - "contentID": { - "type": "string" - }, - "createTime": { - "type": "integer" - }, - "replyUserID": { - "type": "string" - }, - "replyUserName": { - "type": "string" - }, - "userID": { - "type": "string" - }, - "userName": { - "type": "string" - } - } - }, - "base_info.CommentOneWorkMomentReq": { + "base_info.DeleteFriendReq": { "type": "object", "required": [ - "content", + "fromUserID", "operationID", - "workMomentID" + "toUserID" ], "properties": { - "content": { + "fromUserID": { "type": "string" }, "operationID": { "type": "string" }, - "replyUserID": { - "type": "string" - }, - "workMomentID": { + "toUserID": { "type": "string" } } }, - "base_info.CommentOneWorkMomentResp": { + "base_info.DeleteFriendResp": { "type": "object", "properties": { - "data": { - "type": "object" - }, "errCode": { "type": "integer" }, @@ -3720,50 +5514,27 @@ const docTemplate = `{ } } }, - "base_info.CreateGroupReq": { + "base_info.DeleteOneWorkMomentReq": { "type": "object", "required": [ - "operationID" + "operationID", + "workMomentID" ], "properties": { - "ex": { - "type": "string" - }, - "faceURL": { - "type": "string" - }, - "groupID": { - "type": "string" - }, - "groupName": { - "type": "string" - }, - "groupType": { - "type": "integer" - }, - "introduction": { - "type": "string" - }, - "memberList": { - "type": "array", - "items": { - "$ref": "#/definitions/base_info.GroupAddMemberInfo" - } - }, - "notification": { - "type": "string" - }, "operationID": { "type": "string" }, - "ownerUserID": { + "workMomentID": { "type": "string" } } }, - "base_info.CreateGroupResp": { + "base_info.DeleteOneWorkMomentResp": { "type": "object", "properties": { + "data": { + "type": "object" + }, "errCode": { "type": "integer" }, @@ -3772,23 +5543,24 @@ const docTemplate = `{ } } }, - "base_info.CreateOneWorkMomentReq": { + "base_info.DeleteOrganizationUserReq": { "type": "object", + "required": [ + "operationID", + "userID" + ], "properties": { "operationID": { "type": "string" }, - "workMoment": { - "$ref": "#/definitions/office.WorkMoment" + "userID": { + "type": "string" } } }, - "base_info.CreateOneWorkMomentResp": { + "base_info.DeleteOrganizationUserResp": { "type": "object", "properties": { - "data": { - "type": "object" - }, "errCode": { "type": "integer" }, @@ -3797,31 +5569,22 @@ const docTemplate = `{ } } }, - "base_info.CreateTagReq": { + "base_info.DeleteTagReq": { "type": "object", "required": [ "operationID", - "tagName", - "userIDList" + "tagID" ], "properties": { - "operationID": { - "type": "string" - }, - "tagName": { - "description": "tag名称", + "operationID": { "type": "string" }, - "userIDList": { - "description": "用户ID列表", - "type": "array", - "items": { - "type": "string" - } + "tagID": { + "type": "string" } } }, - "base_info.CreateTagResp": { + "base_info.DeleteTagResp": { "type": "object", "properties": { "errCode": { @@ -3832,29 +5595,26 @@ const docTemplate = `{ } } }, - "base_info.DelMsgReq": { + "base_info.DeleteUserInDepartmentReq": { "type": "object", "required": [ + "departmentID", "operationID", - "seqList", "userID" ], "properties": { - "operationID": { + "departmentID": { "type": "string" }, - "seqList": { - "type": "array", - "items": { - "type": "integer" - } + "operationID": { + "type": "string" }, "userID": { "type": "string" } } }, - "base_info.DelMsgResp": { + "base_info.DeleteUserInDepartmentResp": { "type": "object", "properties": { "errCode": { @@ -3865,31 +5625,24 @@ const docTemplate = `{ } } }, - "base_info.DeleteCommentReq": { + "base_info.DismissGroupReq": { "type": "object", "required": [ - "contentID", - "operationID", - "workMomentID" + "groupID", + "operationID" ], "properties": { - "contentID": { + "groupID": { "type": "string" }, "operationID": { "type": "string" - }, - "workMomentID": { - "type": "string" } } }, - "base_info.DeleteCommentResp": { + "base_info.DismissGroupResp": { "type": "object", "properties": { - "data": { - "type": "object" - }, "errCode": { "type": "integer" }, @@ -3898,26 +5651,38 @@ const docTemplate = `{ } } }, - "base_info.DeleteFriendReq": { + "base_info.ExpireTime": { + "type": "object", + "properties": { + "expireTimeSeconds": { + "type": "integer" + } + } + }, + "base_info.ForceLogoutReq": { "type": "object", "required": [ "fromUserID", "operationID", - "toUserID" + "platform" ], "properties": { "fromUserID": { - "type": "string" + "type": "string", + "maxLength": 64, + "minLength": 1 }, "operationID": { "type": "string" }, - "toUserID": { - "type": "string" + "platform": { + "type": "integer", + "maximum": 8, + "minimum": 1 } } }, - "base_info.DeleteFriendResp": { + "base_info.ForceLogoutResp": { "type": "object", "properties": { "errCode": { @@ -3928,26 +5693,29 @@ const docTemplate = `{ } } }, - "base_info.DeleteOneWorkMomentReq": { + "base_info.GetAllConversationsReq": { "type": "object", "required": [ "operationID", - "workMomentID" + "ownerUserID" ], "properties": { "operationID": { "type": "string" }, - "workMomentID": { + "ownerUserID": { "type": "string" } } }, - "base_info.DeleteOneWorkMomentResp": { + "base_info.GetAllConversationsResp": { "type": "object", "properties": { "data": { - "type": "object" + "type": "array", + "items": { + "$ref": "#/definitions/base_info.Conversation" + } }, "errCode": { "type": "integer" @@ -3957,24 +5725,26 @@ const docTemplate = `{ } } }, - "base_info.DeleteTagReq": { + "base_info.GetAllUsersUidReq": { "type": "object", "required": [ - "operationID", - "tagID" + "operationID" ], "properties": { "operationID": { "type": "string" - }, - "tagID": { - "type": "string" } } }, - "base_info.DeleteTagResp": { + "base_info.GetAllUsersUidResp": { "type": "object", "properties": { + "data": { + "type": "array", + "items": { + "type": "string" + } + }, "errCode": { "type": "integer" }, @@ -3983,14 +5753,14 @@ const docTemplate = `{ } } }, - "base_info.DismissGroupReq": { + "base_info.GetBlackListReq": { "type": "object", "required": [ - "groupID", + "fromUserID", "operationID" ], "properties": { - "groupID": { + "fromUserID": { "type": "string" }, "operationID": { @@ -3998,7 +5768,7 @@ const docTemplate = `{ } } }, - "base_info.DismissGroupResp": { + "base_info.GetBlackListResp": { "type": "object", "properties": { "errCode": { @@ -4009,32 +5779,31 @@ const docTemplate = `{ } } }, - "base_info.ForceLogoutReq": { + "base_info.GetConversationReq": { "type": "object", "required": [ - "fromUserID", + "conversationID", "operationID", - "platform" + "ownerUserID" ], "properties": { - "fromUserID": { - "type": "string", - "maxLength": 64, - "minLength": 1 + "conversationID": { + "type": "string" }, "operationID": { "type": "string" }, - "platform": { - "type": "integer", - "maximum": 8, - "minimum": 1 + "ownerUserID": { + "type": "string" } } }, - "base_info.ForceLogoutResp": { + "base_info.GetConversationResp": { "type": "object", "properties": { + "data": { + "$ref": "#/definitions/base_info.Conversation" + }, "errCode": { "type": "integer" }, @@ -4043,24 +5812,35 @@ const docTemplate = `{ } } }, - "base_info.GetAllUsersUidReq": { + "base_info.GetConversationsReq": { "type": "object", "required": [ - "operationID" + "conversationIDs", + "operationID", + "ownerUserID" ], "properties": { + "conversationIDs": { + "type": "array", + "items": { + "type": "string" + } + }, "operationID": { "type": "string" + }, + "ownerUserID": { + "type": "string" } } }, - "base_info.GetAllUsersUidResp": { + "base_info.GetConversationsResp": { "type": "object", "properties": { "data": { "type": "array", "items": { - "type": "string" + "$ref": "#/definitions/base_info.Conversation" } }, "errCode": { @@ -4071,14 +5851,14 @@ const docTemplate = `{ } } }, - "base_info.GetBlackListReq": { + "base_info.GetDepartmentMemberReq": { "type": "object", "required": [ - "fromUserID", + "departmentID", "operationID" ], "properties": { - "fromUserID": { + "departmentID": { "type": "string" }, "operationID": { @@ -4086,7 +5866,7 @@ const docTemplate = `{ } } }, - "base_info.GetBlackListResp": { + "base_info.GetDepartmentMemberResp": { "type": "object", "properties": { "data": { @@ -4122,13 +5902,6 @@ const docTemplate = `{ "base_info.GetFriendApplyListResp": { "type": "object", "properties": { - "data": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": true - } - }, "errCode": { "type": "integer" }, @@ -4155,13 +5928,6 @@ const docTemplate = `{ "base_info.GetFriendListResp": { "type": "object", "properties": { - "data": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": true - } - }, "errCode": { "type": "integer" }, @@ -4188,13 +5954,6 @@ const docTemplate = `{ "base_info.GetGroupAllMemberResp": { "type": "object", "properties": { - "data": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": true - } - }, "errCode": { "type": "integer" }, @@ -4222,13 +5981,6 @@ const docTemplate = `{ "base_info.GetGroupApplicationListResp": { "type": "object", "properties": { - "data": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": true - } - }, "errCode": { "type": "integer" }, @@ -4258,13 +6010,6 @@ const docTemplate = `{ "base_info.GetGroupInfoResp": { "type": "object", "properties": { - "data": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": true - } - }, "errCode": { "type": "integer" }, @@ -4298,13 +6043,6 @@ const docTemplate = `{ "base_info.GetGroupMembersInfoResp": { "type": "object", "properties": { - "data": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": true - } - }, "errCode": { "type": "integer" }, @@ -4331,13 +6069,6 @@ const docTemplate = `{ "base_info.GetJoinedGroupListResp": { "type": "object", "properties": { - "data": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": true - } - }, "errCode": { "type": "integer" }, @@ -4364,13 +6095,6 @@ const docTemplate = `{ "base_info.GetSelfApplyListResp": { "type": "object", "properties": { - "data": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": true - } - }, "errCode": { "type": "integer" }, @@ -4405,6 +6129,39 @@ const docTemplate = `{ } } }, + "base_info.GetSubDepartmentReq": { + "type": "object", + "required": [ + "departmentID", + "operationID" + ], + "properties": { + "departmentID": { + "type": "string" + }, + "operationID": { + "type": "string" + } + } + }, + "base_info.GetSubDepartmentResp": { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "type": "object", + "additionalProperties": true + } + }, + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, "base_info.GetTagSendLogsReq": { "type": "object", "required": [ @@ -4463,33 +6220,63 @@ const docTemplate = `{ "operationID": { "type": "string" }, - "pageNumber": { - "type": "integer" - }, - "showNumber": { - "type": "integer" + "pageNumber": { + "type": "integer" + }, + "showNumber": { + "type": "integer" + } + } + }, + "base_info.GetUserFriendWorkMomentsResp": { + "type": "object", + "properties": { + "data": { + "type": "object", + "properties": { + "currentPage": { + "type": "integer" + }, + "showNumber": { + "type": "integer" + }, + "workMoments": { + "type": "array", + "items": { + "$ref": "#/definitions/base_info.WorkMoment" + } + } + } + }, + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.GetUserInDepartmentReq": { + "type": "object", + "required": [ + "operationID", + "userID" + ], + "properties": { + "operationID": { + "type": "string" + }, + "userID": { + "type": "string" } } }, - "base_info.GetUserFriendWorkMomentsResp": { + "base_info.GetUserInDepartmentResp": { "type": "object", "properties": { "data": { "type": "object", - "properties": { - "currentPage": { - "type": "integer" - }, - "showNumber": { - "type": "integer" - }, - "workMoments": { - "type": "array", - "items": { - "$ref": "#/definitions/base_info.WorkMoment" - } - } - } + "additionalProperties": true }, "errCode": { "type": "integer" @@ -4959,19 +6746,135 @@ const docTemplate = `{ } } }, - "base_info.MinioUploadFileResp": { + "base_info.ManagementBatchSendMsgReq": { "type": "object", + "required": [ + "contentType", + "operationID", + "sendID", + "sessionType" + ], "properties": { - "URL": { + "contentType": { + "type": "integer" + }, + "groupID": { "type": "string" }, - "newName": { + "isOnlineOnly": { + "type": "boolean" + }, + "offlinePushInfo": { + "$ref": "#/definitions/server_api_params.OfflinePushInfo" + }, + "operationID": { + "type": "string" + }, + "recvIDList": { + "type": "array", + "items": { + "type": "string" + } + }, + "sendID": { "type": "string" }, - "snapshotName": { + "senderFaceURL": { "type": "string" }, - "snapshotURL": { + "senderNickname": { + "type": "string" + }, + "senderPlatformID": { + "type": "integer" + }, + "sessionType": { + "type": "integer" + } + } + }, + "base_info.ManagementSendMsgReq": { + "type": "object", + "required": [ + "contentType", + "operationID", + "sendID", + "sessionType" + ], + "properties": { + "contentType": { + "type": "integer" + }, + "groupID": { + "type": "string" + }, + "isOnlineOnly": { + "type": "boolean" + }, + "offlinePushInfo": { + "$ref": "#/definitions/server_api_params.OfflinePushInfo" + }, + "operationID": { + "type": "string" + }, + "recvID": { + "type": "string" + }, + "sendID": { + "type": "string" + }, + "senderFaceURL": { + "type": "string" + }, + "senderNickname": { + "type": "string" + }, + "senderPlatformID": { + "type": "integer" + }, + "sessionType": { + "type": "integer" + } + } + }, + "base_info.ManagementSendMsgResp": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/server_api_params.UserSendMsgResp" + }, + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.MinioUploadFileResp": { + "type": "object", + "properties": { + "data": { + "type": "object", + "properties": { + "URL": { + "type": "string" + }, + "newName": { + "type": "string" + }, + "snapshotName": { + "type": "string" + }, + "snapshotURL": { + "type": "string" + } + } + }, + "errCode": { + "type": "integer" + }, + "errMsg": { "type": "string" } } @@ -5039,10 +6942,6 @@ const docTemplate = `{ "base_info.ParseTokenResp": { "type": "object", "properties": { - "data": { - "type": "object", - "additionalProperties": true - }, "errCode": { "type": "integer" }, @@ -5260,7 +7159,152 @@ const docTemplate = `{ } } }, - "base_info.SetGroupInfoResp": { + "base_info.SetGroupInfoResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.SetGroupMemberInfoReq": { + "type": "object", + "required": [ + "groupID", + "operationID", + "userID" + ], + "properties": { + "ex": { + "type": "string" + }, + "groupID": { + "type": "string" + }, + "nickname": { + "type": "string" + }, + "operationID": { + "type": "string" + }, + "roleLevel": { + "type": "integer", + "maximum": 3, + "minimum": 1 + }, + "userGroupFaceUrl": { + "type": "string" + }, + "userID": { + "type": "string" + } + } + }, + "base_info.SetGroupMemberInfoResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.SetTagReq": { + "type": "object", + "required": [ + "operationID", + "tagID" + ], + "properties": { + "increaseUserIDList": { + "type": "array", + "items": { + "type": "string" + } + }, + "newName": { + "type": "string" + }, + "operationID": { + "type": "string" + }, + "reduceUserIDList": { + "type": "array", + "items": { + "type": "string" + } + }, + "tagID": { + "type": "string" + } + } + }, + "base_info.SetTagResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.Swagger400Resp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer", + "example": 400 + }, + "errMsg": { + "type": "string", + "example": "err msg" + } + } + }, + "base_info.Swagger500Resp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer", + "example": 500 + }, + "errMsg": { + "type": "string", + "example": "err msg" + } + } + }, + "base_info.TransferGroupOwnerReq": { + "type": "object", + "required": [ + "groupID", + "newOwnerUserID", + "oldOwnerUserID", + "operationID" + ], + "properties": { + "groupID": { + "type": "string" + }, + "newOwnerUserID": { + "type": "string" + }, + "oldOwnerUserID": { + "type": "string" + }, + "operationID": { + "type": "string" + } + } + }, + "base_info.TransferGroupOwnerResp": { "type": "object", "properties": { "errCode": { @@ -5271,40 +7315,49 @@ const docTemplate = `{ } } }, - "base_info.SetGroupMemberInfoReq": { + "base_info.UpdateDepartmentReq": { "type": "object", "required": [ - "groupID", - "operationID", - "userID" + "departmentID", + "operationID" ], "properties": { + "createTime": { + "type": "integer" + }, + "departmentID": { + "type": "string" + }, + "departmentType": { + "type": "integer" + }, "ex": { "type": "string" }, - "groupID": { + "faceURL": { "type": "string" }, - "nickname": { + "memberNum": { + "type": "integer" + }, + "name": { "type": "string" }, "operationID": { "type": "string" }, - "roleLevel": { - "type": "integer", - "maximum": 3, - "minimum": 1 + "order": { + "type": "integer" }, - "userGroupFaceUrl": { + "parentID": { "type": "string" }, - "userID": { - "type": "string" + "subDepartmentNum": { + "type": "integer" } } }, - "base_info.SetGroupMemberInfoResp": { + "base_info.UpdateDepartmentResp": { "type": "object", "properties": { "errCode": { @@ -5315,71 +7368,51 @@ const docTemplate = `{ } } }, - "base_info.SetTagReq": { + "base_info.UpdateOrganizationUserReq": { "type": "object", "required": [ - "operationID", - "tagID" + "operationID" ], "properties": { - "increaseUserIDList": { - "type": "array", - "items": { - "type": "string" - } + "birth": { + "type": "integer" }, - "newName": { + "createTime": { + "type": "integer" + }, + "email": { "type": "string" }, - "operationID": { + "englishName": { "type": "string" }, - "reduceUserIDList": { - "type": "array", - "items": { - "type": "string" - } + "ex": { + "type": "string" }, - "tagID": { + "faceURL": { "type": "string" - } - } - }, - "base_info.SetTagResp": { - "type": "object", - "properties": { - "errCode": { + }, + "gender": { "type": "integer" }, - "errMsg": { + "mobile": { "type": "string" - } - } - }, - "base_info.TransferGroupOwnerReq": { - "type": "object", - "required": [ - "groupID", - "newOwnerUserID", - "oldOwnerUserID", - "operationID" - ], - "properties": { - "groupID": { + }, + "nickname": { "type": "string" }, - "newOwnerUserID": { + "operationID": { "type": "string" }, - "oldOwnerUserID": { + "telephone": { "type": "string" }, - "operationID": { + "userID": { "type": "string" } } }, - "base_info.TransferGroupOwnerResp": { + "base_info.UpdateOrganizationUserResp": { "type": "object", "properties": { "errCode": { @@ -5439,6 +7472,49 @@ const docTemplate = `{ } } }, + "base_info.UpdateUserInDepartmentReq": { + "type": "object", + "required": [ + "operationID" + ], + "properties": { + "departmentID": { + "type": "string" + }, + "ex": { + "type": "string" + }, + "leader": { + "type": "integer" + }, + "operationID": { + "type": "string" + }, + "order": { + "type": "integer" + }, + "position": { + "type": "string" + }, + "status": { + "type": "integer" + }, + "userID": { + "type": "string" + } + } + }, + "base_info.UpdateUserInDepartmentResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, "base_info.UpdateUserInfoResp": { "type": "object", "properties": { @@ -5621,33 +7697,220 @@ const docTemplate = `{ "$ref": "#/definitions/base_info.WorkMomentUser" } }, - "permission": { + "permission": { + "type": "integer" + }, + "permissionUsers": { + "type": "array", + "items": { + "$ref": "#/definitions/base_info.WorkMomentUser" + } + }, + "userID": { + "type": "string" + }, + "userName": { + "type": "string" + }, + "workMomentID": { + "type": "string" + } + } + }, + "base_info.WorkMomentUser": { + "type": "object", + "properties": { + "userID": { + "type": "string" + }, + "userName": { + "type": "string" + } + } + }, + "internal_api_manage.FileElem": { + "type": "object", + "properties": { + "fileName": { + "type": "string" + }, + "filePath": { + "type": "string" + }, + "fileSize": { + "type": "integer" + }, + "sourceURL": { + "type": "string" + }, + "uuid": { + "type": "string" + } + } + }, + "internal_api_manage.OANotificationElem": { + "type": "object", + "required": [ + "notificationFaceURL", + "notificationName", + "notificationType", + "text" + ], + "properties": { + "ex": { + "type": "string" + }, + "fileElem": { + "$ref": "#/definitions/internal_api_manage.FileElem" + }, + "mixType": { + "type": "integer" + }, + "notificationFaceURL": { + "type": "string" + }, + "notificationName": { + "type": "string" + }, + "notificationType": { + "type": "integer" + }, + "pictureElem": { + "$ref": "#/definitions/internal_api_manage.PictureElem" + }, + "soundElem": { + "$ref": "#/definitions/internal_api_manage.SoundElem" + }, + "text": { + "type": "string" + }, + "url": { + "type": "string" + }, + "videoElem": { + "$ref": "#/definitions/internal_api_manage.VideoElem" + } + } + }, + "internal_api_manage.PictureBaseInfo": { + "type": "object", + "properties": { + "height": { + "type": "integer" + }, + "size": { + "type": "integer" + }, + "type": { + "type": "string" + }, + "url": { + "type": "string" + }, + "uuid": { + "type": "string" + }, + "width": { + "type": "integer" + } + } + }, + "internal_api_manage.PictureElem": { + "type": "object", + "properties": { + "bigPicture": { + "$ref": "#/definitions/internal_api_manage.PictureBaseInfo" + }, + "snapshotPicture": { + "$ref": "#/definitions/internal_api_manage.PictureBaseInfo" + }, + "sourcePath": { + "type": "string" + }, + "sourcePicture": { + "$ref": "#/definitions/internal_api_manage.PictureBaseInfo" + } + } + }, + "internal_api_manage.RevokeElem": { + "type": "object", + "required": [ + "revokeMsgClientID" + ], + "properties": { + "revokeMsgClientID": { + "type": "string" + } + } + }, + "internal_api_manage.SoundElem": { + "type": "object", + "properties": { + "dataSize": { + "type": "integer" + }, + "duration": { + "type": "integer" + }, + "soundPath": { + "type": "string" + }, + "sourceURL": { + "type": "string" + }, + "uuid": { + "type": "string" + } + } + }, + "internal_api_manage.TextElem": { + "type": "object", + "required": [ + "text" + ], + "properties": { + "text": { + "type": "string" + } + } + }, + "internal_api_manage.VideoElem": { + "type": "object", + "properties": { + "duration": { + "type": "integer" + }, + "snapshotHeight": { + "type": "integer" + }, + "snapshotPath": { + "type": "string" + }, + "snapshotSize": { "type": "integer" }, - "permissionUsers": { - "type": "array", - "items": { - "$ref": "#/definitions/base_info.WorkMomentUser" - } + "snapshotURL": { + "type": "string" }, - "userID": { + "snapshotUUID": { "type": "string" }, - "userName": { + "snapshotWidth": { + "type": "integer" + }, + "videoPath": { "type": "string" }, - "workMomentID": { + "videoSize": { + "type": "integer" + }, + "videoType": { "type": "string" - } - } - }, - "base_info.WorkMomentUser": { - "type": "object", - "properties": { - "userID": { + }, + "videoURL": { "type": "string" }, - "userName": { + "videoUUID": { "type": "string" } } @@ -5832,6 +8095,143 @@ const docTemplate = `{ } } }, + "server_api_params.Department": { + "type": "object", + "properties": { + "createTime": { + "type": "integer" + }, + "departmentID": { + "type": "string" + }, + "departmentType": { + "type": "integer" + }, + "ex": { + "type": "string" + }, + "faceURL": { + "type": "string" + }, + "memberNum": { + "type": "integer" + }, + "name": { + "type": "string" + }, + "order": { + "type": "integer" + }, + "parentID": { + "type": "string" + }, + "subDepartmentNum": { + "type": "integer" + } + } + }, + "server_api_params.DepartmentMember": { + "type": "object", + "properties": { + "departmentID": { + "type": "string" + }, + "ex": { + "type": "string" + }, + "leader": { + "type": "integer" + }, + "order": { + "type": "integer" + }, + "position": { + "type": "string" + }, + "status": { + "type": "integer" + }, + "userID": { + "type": "string" + } + } + }, + "server_api_params.FriendInfo": { + "type": "object", + "properties": { + "addSource": { + "type": "integer" + }, + "createTime": { + "type": "integer" + }, + "ex": { + "type": "string" + }, + "friendUser": { + "$ref": "#/definitions/server_api_params.UserInfo" + }, + "operatorUserID": { + "type": "string" + }, + "ownerUserID": { + "type": "string" + }, + "remark": { + "type": "string" + } + } + }, + "server_api_params.FriendRequest": { + "type": "object", + "properties": { + "createTime": { + "type": "integer" + }, + "ex": { + "type": "string" + }, + "fromFaceURL": { + "type": "string" + }, + "fromGender": { + "type": "integer" + }, + "fromNickname": { + "type": "string" + }, + "fromUserID": { + "type": "string" + }, + "handleMsg": { + "type": "string" + }, + "handleResult": { + "type": "integer" + }, + "handleTime": { + "type": "integer" + }, + "handlerUserID": { + "type": "string" + }, + "reqMsg": { + "type": "string" + }, + "toFaceURL": { + "type": "string" + }, + "toGender": { + "type": "integer" + }, + "toNickname": { + "type": "string" + }, + "toUserID": { + "type": "string" + } + } + }, "server_api_params.GroupInfo": { "type": "object", "properties": { @@ -5863,7 +8263,7 @@ const docTemplate = `{ "type": "integer" }, "needVerification": { - "$ref": "#/definitions/wrapperspb.Int32Value" + "type": "integer" }, "notification": { "type": "string" @@ -5914,6 +8314,141 @@ const docTemplate = `{ } } }, + "server_api_params.GroupRequest": { + "type": "object", + "properties": { + "ex": { + "type": "string" + }, + "groupInfo": { + "$ref": "#/definitions/server_api_params.GroupInfo" + }, + "handleMsg": { + "type": "string" + }, + "handleResult": { + "type": "integer" + }, + "handleTime": { + "type": "integer" + }, + "handleUserID": { + "type": "string" + }, + "reqMsg": { + "type": "string" + }, + "reqTime": { + "type": "integer" + }, + "userInfo": { + "$ref": "#/definitions/server_api_params.PublicUserInfo" + } + } + }, + "server_api_params.OfflinePushInfo": { + "type": "object", + "properties": { + "desc": { + "type": "string" + }, + "ex": { + "type": "string" + }, + "iOSBadgeCount": { + "type": "boolean" + }, + "iOSPushSound": { + "type": "string" + }, + "title": { + "type": "string" + } + } + }, + "server_api_params.OrganizationUser": { + "type": "object", + "properties": { + "birth": { + "type": "integer" + }, + "createTime": { + "type": "integer" + }, + "email": { + "type": "string" + }, + "englishName": { + "type": "string" + }, + "ex": { + "type": "string" + }, + "faceURL": { + "type": "string" + }, + "gender": { + "type": "integer" + }, + "mobile": { + "type": "string" + }, + "nickname": { + "type": "string" + }, + "telephone": { + "type": "string" + }, + "userID": { + "type": "string" + } + } + }, + "server_api_params.PublicUserInfo": { + "type": "object", + "properties": { + "ex": { + "type": "string" + }, + "faceURL": { + "type": "string" + }, + "gender": { + "type": "integer" + }, + "nickname": { + "type": "string" + }, + "userID": { + "type": "string" + } + } + }, + "server_api_params.UserDepartmentMember": { + "type": "object", + "properties": { + "departmentMember": { + "$ref": "#/definitions/server_api_params.DepartmentMember" + }, + "organizationUser": { + "$ref": "#/definitions/server_api_params.OrganizationUser" + } + } + }, + "server_api_params.UserInDepartment": { + "type": "object", + "properties": { + "departmentMemberList": { + "type": "array", + "items": { + "$ref": "#/definitions/server_api_params.DepartmentMember" + } + }, + "organizationUser": { + "$ref": "#/definitions/server_api_params.OrganizationUser" + } + } + }, "server_api_params.UserInfo": { "type": "object", "properties": { @@ -5952,23 +8487,28 @@ const docTemplate = `{ } } }, - "user.AccountCheckResp_SingleUserStatus": { + "server_api_params.UserSendMsgResp": { "type": "object", "properties": { - "accountStatus": { + "clientMsgID": { "type": "string" }, - "userID": { + "sendTime": { + "type": "integer" + }, + "serverMsgID": { "type": "string" } } }, - "wrapperspb.Int32Value": { + "user.AccountCheckResp_SingleUserStatus": { "type": "object", "properties": { - "value": { - "description": "The int32 value.", - "type": "integer" + "accountStatus": { + "type": "string" + }, + "userID": { + "type": "string" } } } @@ -5977,12 +8517,12 @@ const docTemplate = `{ // SwaggerInfo holds exported Swagger Info so clients can modify it var SwaggerInfo = &swag.Spec{ - Version: "", + Version: "1.0", Host: "", - BasePath: "", + BasePath: "/", Schemes: []string{}, - Title: "", - Description: "", + Title: "open-IM-Server API", + Description: "open-IM-Server 的API服务器文档, 文档中所有请求都有一个operationID字段用于链路追踪", InfoInstanceName: "swagger", SwaggerTemplate: docTemplate, } diff --git a/cmd/open_im_api/docs/swagger.json b/cmd/open_im_api/docs/swagger.json index ff3c03dc5..6e03a6912 100644 --- a/cmd/open_im_api/docs/swagger.json +++ b/cmd/open_im_api/docs/swagger.json @@ -1,8 +1,16 @@ { "swagger": "2.0", "info": { - "contact": {} + "description": "open-IM-Server 的API服务器文档, 文档中所有请求都有一个operationID字段用于链路追踪", + "title": "open-IM-Server API", + "contact": {}, + "license": { + "name": "Apache 2.0", + "url": "http://www.apache.org/licenses/LICENSE-2.0.html" + }, + "version": "1.0" }, + "basePath": "/", "paths": { "/auth/force_logout": { "post": { @@ -27,7 +35,7 @@ "required": true }, { - "description": "platform为平台ID, fromUserID为要执行强制登出的用户ID", + "description": "platform为平台ID \u003cbr\u003e fromUserID为要执行强制登出的用户ID", "name": "req", "in": "body", "required": true, @@ -46,13 +54,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.ForceLogoutResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.ForceLogoutResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -60,7 +68,7 @@ }, "/auth/parse_token": { "post": { - "description": "解析用户token", + "description": "解析当前用户token(token在请求头中传入)", "consumes": [ "application/json" ], @@ -70,7 +78,7 @@ "tags": [ "鉴权认证" ], - "summary": "解析token", + "summary": "解析当前用户token", "operationId": "ParseToken", "parameters": [ { @@ -81,7 +89,7 @@ "required": true }, { - "description": "secret为openIM密钥, 详细见服务端config.yaml secret字段, platform为平台ID", + "description": "secret为openIM密钥, 详细见服务端config.yaml secret字段\u003cbr\u003eplatform为平台ID", "name": "req", "in": "body", "required": true, @@ -94,19 +102,31 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.ParseTokenResp" + "allOf": [ + { + "$ref": "#/definitions/base_info.ParseTokenResp" + }, + { + "type": "object", + "properties": { + "Data": { + "$ref": "#/definitions/base_info.ExpireTime" + } + } + } + ] } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.ParseTokenResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.ParseTokenResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -114,7 +134,7 @@ }, "/auth/user_register": { "post": { - "description": "用户登录", + "description": "用户注册", "consumes": [ "application/json" ], @@ -124,7 +144,7 @@ "tags": [ "鉴权认证" ], - "summary": "用户登录", + "summary": "用户注册", "operationId": "UserRegister", "parameters": [ { @@ -135,7 +155,7 @@ "required": true }, { - "description": "secret为openIM密钥, 详细见服务端config.yaml secret字段 \u003cbr\u003e platform为平台ID \u003cbr\u003e ex为拓展字段", + "description": "secret为openIM密钥, 详细见服务端config.yaml secret字段 \u003cbr\u003e platform为平台ID \u003cbr\u003e ex为拓展字段 \u003cbr\u003e gender为性别, 0为女, 1为男", "name": "req", "in": "body", "required": true, @@ -154,13 +174,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.UserRegisterResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.UserRegisterResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -189,7 +209,7 @@ "required": true }, { - "description": "secret为openIM密钥, 详细见服务端config.yaml secret字段, platform为平台ID", + "description": "secret为openIM密钥, 详细见服务端config.yaml secret字段 \u003cbr\u003e platform为平台ID", "name": "req", "in": "body", "required": true, @@ -208,13 +228,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.UserTokenResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.UserTokenResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -243,7 +263,7 @@ "required": true }, { - "description": "fromUserID为设置的用户, toUserID为被设置的用户", + "description": "fromUserID为设置的用户 \u003cbr\u003e toUserID为被设置的用户", "name": "req", "in": "body", "required": true, @@ -262,13 +282,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.AddBlacklistResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.AddBlacklistResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -297,7 +317,7 @@ "required": true }, { - "description": "reqMsg为申请信息, fromUserID为申请用户, toUserID为被添加用户", + "description": "reqMsg为申请信息 \u003cbr\u003e fromUserID为申请用户 \u003cbr\u003e toUserID为被添加用户", "name": "req", "in": "body", "required": true, @@ -316,13 +336,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.AddFriendResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.AddFriendResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -351,7 +371,7 @@ "required": true }, { - "description": "fromUserID同意/拒绝的用户ID, toUserID为申请用户, handleMsg为处理信息, flag为具体操作, 1为同意, 2为拒绝", + "description": "fromUserID同意/拒绝的用户ID\u003cbr\u003etoUserID为申请用户D\u003cbr\u003ehandleMsg为处理信息\u003cbr\u003eflag为具体操作, 1为同意, 2为拒绝", "name": "req", "in": "body", "required": true, @@ -370,13 +390,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.AddFriendResponseResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.AddFriendResponseResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -405,7 +425,7 @@ "required": true }, { - "description": "fromUserID为操作用户, toUserID为被删除用户", + "description": "fromUserID为操作用户\u003cbr\u003etoUserID为被删除用户", "name": "req", "in": "body", "required": true, @@ -424,13 +444,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.DeleteFriendResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.DeleteFriendResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -472,19 +492,34 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetBlackListResp" + "allOf": [ + { + "$ref": "#/definitions/base_info.GetBlackListResp" + }, + { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/server_api_params.PublicUserInfo" + } + } + } + } + ] } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetBlackListResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetBlackListResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } } } @@ -526,19 +561,34 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetFriendApplyListResp" + "allOf": [ + { + "$ref": "#/definitions/base_info.GetFriendApplyListResp" + }, + { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/server_api_params.FriendRequest" + } + } + } + } + ] } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetFriendApplyListResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetFriendApplyListResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } } } @@ -580,19 +630,34 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetFriendListResp" + "allOf": [ + { + "$ref": "#/definitions/base_info.GetFriendListResp" + }, + { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/server_api_params.FriendInfo" + } + } + } + } + ] } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetFriendListResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetFriendListResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -634,19 +699,34 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetSelfApplyListResp" + "allOf": [ + { + "$ref": "#/definitions/base_info.GetSelfApplyListResp" + }, + { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/server_api_params.FriendRequest" + } + } + } + } + ] } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetSelfApplyListResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetSelfApplyListResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -675,7 +755,7 @@ "required": true }, { - "description": "fromUserID批量加好友的用户ID, friendUserIDList为", + "description": "fromUserID批量加好友的用户ID\u003cbr\u003e friendUserIDList为", "name": "req", "in": "body", "required": true, @@ -686,7 +766,7 @@ ], "responses": { "0": { - "description": "data列表中对象的result-1为添加该用户失败, 0为成功", + "description": "data列表中对象的result-1为添加该用户失败\u003cbr\u003e0为成功", "schema": { "$ref": "#/definitions/base_info.ImportFriendResp" } @@ -694,13 +774,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.ImportFriendResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.ImportFriendResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -729,7 +809,7 @@ "required": true }, { - "description": "fromUserID为请求用户, toUserID为要检查的用户", + "description": "fromUserID为请求用户\u003cbr\u003e toUserID为要检查的用户", "name": "req", "in": "body", "required": true, @@ -748,13 +828,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.IsFriendResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.IsFriendResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -802,13 +882,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.RemoveBlackListResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.RemoveBlackListResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -837,7 +917,7 @@ "required": true }, { - "description": "fromUserID为设置的用户, toUserID为被设置的用户, remark为好友备注", + "description": "fromUserID为设置的用户\u003cbr\u003e toUserID为被设置的用户\u003cbr\u003e remark为好友备注", "name": "req", "in": "body", "required": true, @@ -856,13 +936,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.SetFriendRemarkResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.SetFriendRemarkResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -910,13 +990,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.CancelMuteGroupResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.CancelMuteGroupResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -964,13 +1044,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.CancelMuteGroupMemberResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.CancelMuteGroupMemberResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -999,7 +1079,7 @@ "required": true }, { - "description": "ownerUserID为群主ID \u003cbr\u003e ex为群扩展字段 \u003cbr\u003e roleLevel为群员角色,1为普通用户 2为群主 3为管理员", + "description": "groupType这里填0代表普通群 \u003cbr\u003egroupName为群名称\u003cbr\u003e introduction为群介绍\u003cbr\u003e notification为群公共\u003cbr\u003eownerUserID为群主ID \u003cbr\u003e ex为群扩展字段 \u003cbr\u003e memberList中对象roleLevel为群员角色,1为普通用户 2为群主 3为管理员", "name": "req", "in": "body", "required": true, @@ -1030,13 +1110,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.CreateGroupResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.CreateGroupResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1084,13 +1164,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.DismissGroupResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.DismissGroupResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1153,13 +1233,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetGroupAllMemberResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetGroupAllMemberResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1188,7 +1268,7 @@ "required": true }, { - "description": "memberList为要获取群成员的群ID列表", + "description": "groupID为要获取的群ID \u003cbr\u003e memberList为要获取群成员的群ID列表", "name": "req", "in": "body", "required": true, @@ -1222,13 +1302,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetGroupMembersInfoResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetGroupMembersInfoResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1276,13 +1356,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetGroupInfoResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetGroupInfoResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1345,13 +1425,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetJoinedGroupListResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetJoinedGroupListResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1393,19 +1473,34 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetGroupApplicationListResp" + "allOf": [ + { + "$ref": "#/definitions/base_info.GetGroupApplicationListResp" + }, + { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/server_api_params.GroupRequest" + } + } + } + } + ] } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetGroupApplicationListResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetGroupApplicationListResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1447,19 +1542,34 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetGroupApplicationListResp" + "allOf": [ + { + "$ref": "#/definitions/base_info.GetGroupApplicationListResp" + }, + { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/server_api_params.GroupRequest" + } + } + } + } + ] } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetGroupApplicationListResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetGroupApplicationListResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1507,13 +1617,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.ApplicationGroupResponseResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.ApplicationGroupResponseResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1561,13 +1671,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.InviteUserToGroupResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.InviteUserToGroupResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1596,7 +1706,7 @@ "required": true }, { - "description": "reqMessage为申请进群信息", + "description": "reqMessage为申请进群信息\u003cbr\u003egroupID为申请的群ID", "name": "req", "in": "body", "required": true, @@ -1615,13 +1725,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.JoinGroupResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.JoinGroupResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1669,13 +1779,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.KickGroupMemberResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.KickGroupMemberResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1777,13 +1887,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.DismissGroupResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.DismissGroupResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1791,7 +1901,7 @@ }, "/group/quit_group": { "post": { - "description": "退出群聊", + "description": "当前用户退出群聊", "consumes": [ "application/json" ], @@ -1801,7 +1911,7 @@ "tags": [ "群组相关" ], - "summary": "退出群聊", + "summary": "当前用户退出群聊", "operationId": "QuitGroup", "parameters": [ { @@ -1831,13 +1941,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.QuitGroupResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.QuitGroupResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1866,7 +1976,7 @@ "required": true }, { - "description": "notification为群介绍 \u003cbr\u003e introduction为群公告 \u003cbr\u003e needVerification为加群验证 0为申请需要同意 邀请直接进 1为所有人进群需要验证,除了群主管理员邀请进群 2为直接进群", + "description": "groupID为要修改的群ID\u003cbr\u003egroupName为新的群名称\u003cbr\u003enotification为群介绍 \u003cbr\u003e introduction为群公告 \u003cbr\u003e needVerification为加群验证 0为申请需要同意 邀请直接进 1为所有人进群需要验证,除了群主管理员邀请进群 2为直接进群", "name": "req", "in": "body", "required": true, @@ -1885,13 +1995,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.SetGroupInfoResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.SetGroupInfoResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1920,7 +2030,7 @@ "required": true }, { - "description": "除了operationID, userID, groupID其他参数可选", + "description": "除了operationID, userID, groupID其他参数可选\u003cbr\u003eex为拓展字段\u003cbr\u003efaceURL为群头像\u003cbr\u003enickName为群昵称\u003cbr\u003eroleLevel为群员角色,1为普通用户 2为群主 3为管理员", "name": "req", "in": "body", "required": true, @@ -1939,13 +2049,13 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.SetGroupMemberInfoResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.SetGroupMemberInfoResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } @@ -1993,21 +2103,21 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.TransferGroupOwnerResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.TransferGroupOwnerResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } } }, - "/msg/clear_msg": { + "/msg/batch_send_msg": { "post": { - "description": "清空用户消息", + "description": "管理员批量发送群聊单聊消息 消息格式详细见\u003ca href=\"https://doc.rentsoft.cn/#/server_doc/admin?id=%e6%b6%88%e6%81%af%e7%b1%bb%e5%9e%8b%e6%a0%bc%e5%bc%8f%e6%8f%8f%e8%bf%b0\"\u003e消息格式\u003c/href\u003e", "consumes": [ "application/json" ], @@ -2017,8 +2127,8 @@ "tags": [ "消息相关" ], - "summary": "清空用户消息", - "operationId": "ClearMsg", + "summary": "管理员批量发送群聊单聊消息", + "operationId": "ManagementBatchSendMsg", "parameters": [ { "type": "string", @@ -2028,40 +2138,73 @@ "required": true }, { - "description": "userID为要清空的用户ID", - "name": "req", + "description": "该请求和消息结构体一样 \u003cbr\u003e recvIDList为接受消息的用户ID列表", + "name": "管理员批量发送单聊消息", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.CleanUpMsgReq" + "allOf": [ + { + "$ref": "#/definitions/base_info.ManagementBatchSendMsgReq" + }, + { + "type": "object", + "properties": { + "content": { + "$ref": "#/definitions/Open_IM_internal_api_manage.TextElem" + } + } + } + ] + } + }, + { + "description": "该请求和消息结构体一样 \u003cbr\u003e recvIDList为接受消息的用户ID列表", + "name": "管理员批量发送OA通知", + "in": "body", + "required": true, + "schema": { + "allOf": [ + { + "$ref": "#/definitions/base_info.ManagementSendMsgReq" + }, + { + "type": "object", + "properties": { + "content": { + "$ref": "#/definitions/Open_IM_internal_api_manage.OANotificationElem" + } + } + } + ] } } ], "responses": { "0": { - "description": "", + "description": "serverMsgID为服务器消息ID \u003cbr\u003e clientMsgID为客户端消息ID \u003cbr\u003e sendTime为发送消息时间", "schema": { - "$ref": "#/definitions/base_info.CleanUpMsgResp" + "$ref": "#/definitions/base_info.ManagementBatchSendMsgReq" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.CleanUpMsgResp" + "$ref": "#/definitions/base_info.ManagementBatchSendMsgReq" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.CleanUpMsgResp" + "$ref": "#/definitions/base_info.ManagementBatchSendMsgReq" } } } } }, - "/msg/del_msg": { + "/msg/clear_msg": { "post": { - "description": "根据seq列表删除消息", + "description": "清空用户消息", "consumes": [ "application/json" ], @@ -2071,8 +2214,8 @@ "tags": [ "消息相关" ], - "summary": "根据seq列表删除消息", - "operationId": "DelMsg", + "summary": "清空用户消息", + "operationId": "ClearMsg", "parameters": [ { "type": "string", @@ -2082,12 +2225,12 @@ "required": true }, { - "description": "userID为要删除的用户ID \u003cbr\u003e seqList为seq列表", + "description": "userID为要清空的用户ID", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.DelMsgReq" + "$ref": "#/definitions/base_info.CleanUpMsgReq" } } ], @@ -2095,27 +2238,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.DelMsgResp" + "$ref": "#/definitions/base_info.CleanUpMsgResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.DelMsgResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.DelMsgResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } } }, - "/office/comment_one_work_moment": { + "/msg/del_msg": { "post": { - "description": "评论一条工作圈", + "description": "根据seq列表删除消息", "consumes": [ "application/json" ], @@ -2123,10 +2266,10 @@ "application/json" ], "tags": [ - "工作圈" + "消息相关" ], - "summary": "评论一条工作圈", - "operationId": "CommentOneWorkMoment", + "summary": "根据seq列表删除消息", + "operationId": "DelMsg", "parameters": [ { "type": "string", @@ -2136,12 +2279,12 @@ "required": true }, { - "description": "请求", + "description": "userID为要删除的用户ID \u003cbr\u003e seqList为seq列表", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.CommentOneWorkMomentReq" + "$ref": "#/definitions/base_info.DelMsgReq" } } ], @@ -2149,27 +2292,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.CommentOneWorkMomentResp" + "$ref": "#/definitions/base_info.DelMsgResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.CommentOneWorkMomentResp" + "$ref": "#/definitions/base_info.Swagger400Resp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.CommentOneWorkMomentResp" + "$ref": "#/definitions/base_info.Swagger500Resp" } } } } }, - "/office/create_one_work_moment": { + "/msg/get_all_conversations": { "post": { - "description": "用户创建一条工作圈", + "description": "获取用户所有会话", "consumes": [ "application/json" ], @@ -2177,10 +2320,10 @@ "application/json" ], "tags": [ - "工作圈" + "会话相关" ], - "summary": "创建一条工作圈", - "operationId": "CreateOneWorkMoment", + "summary": "获取用户所有会话", + "operationId": "GetAllConversations", "parameters": [ { "type": "string", @@ -2190,12 +2333,12 @@ "required": true }, { - "description": "请求 atUserList likeUserList permissionGroupList permissionUserList 字段中userName可以不填", + "description": "ownerUserID为要获取的用户ID", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.CreateOneWorkMomentReq" + "$ref": "#/definitions/base_info.GetAllConversationsReq" } } ], @@ -2203,27 +2346,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.CreateOneWorkMomentResp" + "$ref": "#/definitions/base_info.GetAllConversationsResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.CreateOneWorkMomentResp" + "$ref": "#/definitions/base_info.GetAllConversationsResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.CreateOneWorkMomentResp" + "$ref": "#/definitions/base_info.GetAllConversationsResp" } } } } }, - "/office/create_tag": { + "/msg/get_conversation": { "post": { - "description": "创建标签", + "description": "根据会话ID获取会话", "consumes": [ "application/json" ], @@ -2231,10 +2374,10 @@ "application/json" ], "tags": [ - "标签" + "会话相关" ], - "summary": "创建标签", - "operationId": "CreateTag", + "summary": "根据会话ID获取会话", + "operationId": "GetConversation", "parameters": [ { "type": "string", @@ -2244,12 +2387,12 @@ "required": true }, { - "description": "请求", + "description": "ownerUserID为要获取的用户ID\u003cbr\u003econversationID为要获取的会话ID", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.CreateTagReq" + "$ref": "#/definitions/base_info.GetConversationReq" } } ], @@ -2257,27 +2400,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.CreateTagResp" + "$ref": "#/definitions/base_info.GetConversationResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.CreateTagResp" + "$ref": "#/definitions/base_info.GetConversationResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.CreateTagResp" + "$ref": "#/definitions/base_info.GetConversationResp" } } } } }, - "/office/delete_comment": { + "/msg/get_conversations": { "post": { - "description": "删除一条评论", + "description": "根据会话ID列表获取会话", "consumes": [ "application/json" ], @@ -2285,10 +2428,10 @@ "application/json" ], "tags": [ - "工作圈" + "会话相关" ], - "summary": "删除一条评论", - "operationId": "DeleteComment", + "summary": "根据会话ID列表获取会话", + "operationId": "GetConversations", "parameters": [ { "type": "string", @@ -2298,12 +2441,12 @@ "required": true }, { - "description": "请求", + "description": "ownerUserID为要获取的用户ID\u003cbr\u003econversationIDs为要获取的会话ID列表", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.DeleteCommentReq" + "$ref": "#/definitions/base_info.GetConversationsReq" } } ], @@ -2311,27 +2454,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.DeleteCommentResp" + "$ref": "#/definitions/base_info.GetConversationsResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.DeleteCommentResp" + "$ref": "#/definitions/base_info.GetConversationsResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.DeleteCommentResp" + "$ref": "#/definitions/base_info.GetConversationsResp" } } } } }, - "/office/delete_one_work_moment": { + "/msg/manage_send_msg": { "post": { - "description": "根据用户工作圈ID删除一条工作圈", + "description": "管理员发送/撤回消息 消息格式详细见\u003ca href=\"https://doc.rentsoft.cn/#/server_doc/admin?id=%e6%b6%88%e6%81%af%e7%b1%bb%e5%9e%8b%e6%a0%bc%e5%bc%8f%e6%8f%8f%e8%bf%b0\"\u003e消息格式\u003c/href\u003e", "consumes": [ "application/json" ], @@ -2339,10 +2482,10 @@ "application/json" ], "tags": [ - "工作圈" + "消息相关" ], - "summary": "删除一条工作圈", - "operationId": "DeleteOneWorkMoment", + "summary": "管理员发送/撤回消息", + "operationId": "ManagementSendMsg", "parameters": [ { "type": "string", @@ -2352,40 +2495,94 @@ "required": true }, { - "description": "请求", - "name": "req", + "description": "该请求和消息结构体一样", + "name": "管理员发送文字消息", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.DeleteOneWorkMomentReq" - } - } - ], + "allOf": [ + { + "$ref": "#/definitions/base_info.ManagementSendMsgReq" + }, + { + "type": "object", + "properties": { + "content": { + "$ref": "#/definitions/Open_IM_internal_api_manage.TextElem" + } + } + } + ] + } + }, + { + "description": "该请求和消息结构体一样", + "name": "管理员发送OA通知消息", + "in": "body", + "required": true, + "schema": { + "allOf": [ + { + "$ref": "#/definitions/base_info.ManagementSendMsgReq" + }, + { + "type": "object", + "properties": { + "content": { + "$ref": "#/definitions/Open_IM_internal_api_manage.OANotificationElem" + } + } + } + ] + } + }, + { + "description": "该请求和消息结构体一样", + "name": "管理员撤回单聊消息", + "in": "body", + "required": true, + "schema": { + "allOf": [ + { + "$ref": "#/definitions/base_info.ManagementSendMsgReq" + }, + { + "type": "object", + "properties": { + "content": { + "$ref": "#/definitions/Open_IM_internal_api_manage.RevokeElem" + } + } + } + ] + } + } + ], "responses": { "0": { - "description": "", + "description": "serverMsgID为服务器消息ID \u003cbr\u003e clientMsgID为客户端消息ID \u003cbr\u003e sendTime为发送消息时间", "schema": { - "$ref": "#/definitions/base_info.DeleteOneWorkMomentResp" + "$ref": "#/definitions/base_info.ManagementSendMsgResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.DeleteOneWorkMomentResp" + "$ref": "#/definitions/base_info.ManagementSendMsgResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.DeleteOneWorkMomentResp" + "$ref": "#/definitions/base_info.ManagementSendMsgResp" } } } } }, - "/office/delete_tag": { + "/office/comment_one_work_moment": { "post": { - "description": "根据标签ID创建标签", + "description": "评论一条工作圈", "consumes": [ "application/json" ], @@ -2393,10 +2590,10 @@ "application/json" ], "tags": [ - "标签" + "工作圈" ], - "summary": "删除标签", - "operationId": "DeleteTag", + "summary": "评论一条工作圈", + "operationId": "CommentOneWorkMoment", "parameters": [ { "type": "string", @@ -2411,7 +2608,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.DeleteTagReq" + "$ref": "#/definitions/base_info.CommentOneWorkMomentReq" } } ], @@ -2419,27 +2616,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.DeleteTagResp" + "$ref": "#/definitions/base_info.CommentOneWorkMomentResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.DeleteTagResp" + "$ref": "#/definitions/base_info.CommentOneWorkMomentResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.DeleteTagResp" + "$ref": "#/definitions/base_info.CommentOneWorkMomentResp" } } } } }, - "/office/get_send_tag_log": { + "/office/create_one_work_moment": { "post": { - "description": "分页获取发送历史记录", + "description": "用户创建一条工作圈", "consumes": [ "application/json" ], @@ -2447,10 +2644,10 @@ "application/json" ], "tags": [ - "标签" + "工作圈" ], - "summary": "获取发送历史记录", - "operationId": "GetTagSendLogs", + "summary": "创建一条工作圈", + "operationId": "CreateOneWorkMoment", "parameters": [ { "type": "string", @@ -2460,12 +2657,12 @@ "required": true }, { - "description": "请求", + "description": "请求 atUserList likeUserList permissionGroupList permissionUserList 字段中userName可以不填", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetTagSendLogsReq" + "$ref": "#/definitions/base_info.CreateOneWorkMomentReq" } } ], @@ -2473,27 +2670,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetTagSendLogsResp" + "$ref": "#/definitions/base_info.CreateOneWorkMomentResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetTagSendLogsResp" + "$ref": "#/definitions/base_info.CreateOneWorkMomentResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetTagSendLogsResp" + "$ref": "#/definitions/base_info.CreateOneWorkMomentResp" } } } } }, - "/office/get_user_friend_work_moments": { + "/office/create_tag": { "post": { - "description": "查询用户工作圈页面", + "description": "创建标签", "consumes": [ "application/json" ], @@ -2501,10 +2698,10 @@ "application/json" ], "tags": [ - "工作圈" + "标签" ], - "summary": "查询自己大工作圈页面", - "operationId": "GetUserFriendWorkMoments", + "summary": "创建标签", + "operationId": "CreateTag", "parameters": [ { "type": "string", @@ -2519,7 +2716,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetUserFriendWorkMomentsReq" + "$ref": "#/definitions/base_info.CreateTagReq" } } ], @@ -2527,27 +2724,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetUserFriendWorkMomentsResp" + "$ref": "#/definitions/base_info.CreateTagResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetUserFriendWorkMomentsResp" + "$ref": "#/definitions/base_info.CreateTagResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetUserFriendWorkMomentsResp" + "$ref": "#/definitions/base_info.CreateTagResp" } } } } }, - "/office/get_user_tag_by_id": { + "/office/delete_comment": { "post": { - "description": "通过标签id获取该用户的标签信息", + "description": "删除一条评论", "consumes": [ "application/json" ], @@ -2555,10 +2752,10 @@ "application/json" ], "tags": [ - "标签" + "工作圈" ], - "summary": "获取该用户的标签信息", - "operationId": "GetUserTagByID", + "summary": "删除一条评论", + "operationId": "DeleteComment", "parameters": [ { "type": "string", @@ -2573,7 +2770,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetUserTagByIDReq" + "$ref": "#/definitions/base_info.DeleteCommentReq" } } ], @@ -2581,27 +2778,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetUserTagByIDResp" + "$ref": "#/definitions/base_info.DeleteCommentResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetUserTagByIDResp" + "$ref": "#/definitions/base_info.DeleteCommentResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetUserTagByIDResp" + "$ref": "#/definitions/base_info.DeleteCommentResp" } } } } }, - "/office/get_user_tags": { + "/office/delete_one_work_moment": { "post": { - "description": "用户获取自己的所有的标签", + "description": "根据用户工作圈ID删除一条工作圈", "consumes": [ "application/json" ], @@ -2609,10 +2806,10 @@ "application/json" ], "tags": [ - "标签" + "工作圈" ], - "summary": "获取用户标签信息", - "operationId": "GetUserTags", + "summary": "删除一条工作圈", + "operationId": "DeleteOneWorkMoment", "parameters": [ { "type": "string", @@ -2627,7 +2824,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetUserTagsReq" + "$ref": "#/definitions/base_info.DeleteOneWorkMomentReq" } } ], @@ -2635,27 +2832,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetUserTagsResp" + "$ref": "#/definitions/base_info.DeleteOneWorkMomentResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetUserTagsResp" + "$ref": "#/definitions/base_info.DeleteOneWorkMomentResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetUserTagsResp" + "$ref": "#/definitions/base_info.DeleteOneWorkMomentResp" } } } } }, - "/office/get_user_work_moments": { + "/office/delete_tag": { "post": { - "description": "查询用户工作圈", + "description": "根据标签ID创建标签", "consumes": [ "application/json" ], @@ -2663,10 +2860,10 @@ "application/json" ], "tags": [ - "工作圈" + "标签" ], - "summary": "查询用户工作圈", - "operationId": "GetUserWorkMoments", + "summary": "删除标签", + "operationId": "DeleteTag", "parameters": [ { "type": "string", @@ -2681,7 +2878,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetUserWorkMomentsReq" + "$ref": "#/definitions/base_info.DeleteTagReq" } } ], @@ -2689,27 +2886,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetUserWorkMomentsResp" + "$ref": "#/definitions/base_info.DeleteTagResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetUserWorkMomentsResp" + "$ref": "#/definitions/base_info.DeleteTagResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetUserWorkMomentsResp" + "$ref": "#/definitions/base_info.DeleteTagResp" } } } } }, - "/office/get_work_moment_by_id": { + "/office/get_send_tag_log": { "post": { - "description": "通过ID获取工作圈", + "description": "分页获取发送历史记录", "consumes": [ "application/json" ], @@ -2717,10 +2914,10 @@ "application/json" ], "tags": [ - "工作圈" + "标签" ], - "summary": "通过ID获取工作圈", - "operationId": "GetWorkMomentByID", + "summary": "获取发送历史记录", + "operationId": "GetTagSendLogs", "parameters": [ { "type": "string", @@ -2735,7 +2932,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetWorkMomentByIDReq" + "$ref": "#/definitions/base_info.GetTagSendLogsReq" } } ], @@ -2743,27 +2940,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetWorkMomentByIDResp" + "$ref": "#/definitions/base_info.GetTagSendLogsResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetWorkMomentByIDResp" + "$ref": "#/definitions/base_info.GetTagSendLogsResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetWorkMomentByIDResp" + "$ref": "#/definitions/base_info.GetTagSendLogsResp" } } } } }, - "/office/like_one_work_moment": { + "/office/get_user_friend_work_moments": { "post": { - "description": "工作圈ID点赞一条工作圈", + "description": "查询用户工作圈页面", "consumes": [ "application/json" ], @@ -2773,8 +2970,8 @@ "tags": [ "工作圈" ], - "summary": "点赞一条工作圈", - "operationId": "LikeOneWorkMoment", + "summary": "查询自己大工作圈页面", + "operationId": "GetUserFriendWorkMoments", "parameters": [ { "type": "string", @@ -2789,7 +2986,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.LikeOneWorkMomentReq" + "$ref": "#/definitions/base_info.GetUserFriendWorkMomentsReq" } } ], @@ -2797,27 +2994,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.LikeOneWorkMomentResp" + "$ref": "#/definitions/base_info.GetUserFriendWorkMomentsResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.LikeOneWorkMomentResp" + "$ref": "#/definitions/base_info.GetUserFriendWorkMomentsResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.LikeOneWorkMomentResp" + "$ref": "#/definitions/base_info.GetUserFriendWorkMomentsResp" } } } } }, - "/office/send_msg_to_tag": { + "/office/get_user_tag_by_id": { "post": { - "description": "对标签用户发送消息", + "description": "通过标签id获取该用户的标签信息", "consumes": [ "application/json" ], @@ -2827,8 +3024,8 @@ "tags": [ "标签" ], - "summary": "发送标签消息", - "operationId": "SendMsg2Tag", + "summary": "获取该用户的标签信息", + "operationId": "GetUserTagByID", "parameters": [ { "type": "string", @@ -2843,7 +3040,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.SendMsg2TagReq" + "$ref": "#/definitions/base_info.GetUserTagByIDReq" } } ], @@ -2851,27 +3048,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.SendMsg2TagResp" + "$ref": "#/definitions/base_info.GetUserTagByIDResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.SendMsg2TagResp" + "$ref": "#/definitions/base_info.GetUserTagByIDResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.SendMsg2TagResp" + "$ref": "#/definitions/base_info.GetUserTagByIDResp" } } } } }, - "/office/set_tag": { + "/office/get_user_tags": { "post": { - "description": "根据标签ID修改标签用户列表, 名称", + "description": "用户获取自己的所有的标签", "consumes": [ "application/json" ], @@ -2881,8 +3078,8 @@ "tags": [ "标签" ], - "summary": "修改标签", - "operationId": "SetTag", + "summary": "获取用户标签信息", + "operationId": "GetUserTags", "parameters": [ { "type": "string", @@ -2897,7 +3094,7 @@ "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.SetTagReq" + "$ref": "#/definitions/base_info.GetUserTagsReq" } } ], @@ -2905,27 +3102,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.SetTagResp" + "$ref": "#/definitions/base_info.GetUserTagsResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.SetTagResp" + "$ref": "#/definitions/base_info.GetUserTagsResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.SetTagResp" + "$ref": "#/definitions/base_info.GetUserTagsResp" } } } } }, - "/third/minio_upload": { + "/office/get_user_work_moments": { "post": { - "description": "minio上传文件(web api), 请注意本api请求为form并非json", + "description": "查询用户工作圈", "consumes": [ "application/json" ], @@ -2933,10 +3130,10 @@ "application/json" ], "tags": [ - "第三方服务相关" + "工作圈" ], - "summary": "minio上传文件(web api)", - "operationId": "MinioUploadFile", + "summary": "查询用户工作圈", + "operationId": "GetUserWorkMoments", "parameters": [ { "type": "string", @@ -2946,52 +3143,148 @@ "required": true }, { - "type": "file", - "description": "要上传的文件文件", - "name": "file", - "in": "formData", - "required": true + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.GetUserWorkMomentsReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.GetUserWorkMomentsResp" + } }, - { - "type": "integer", - "description": "文件类型", - "name": "fileType", - "in": "formData", + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.GetUserWorkMomentsResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.GetUserWorkMomentsResp" + } + } + } + } + }, + "/office/get_work_moment_by_id": { + "post": { + "description": "通过ID获取工作圈", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "工作圈" + ], + "summary": "通过ID获取工作圈", + "operationId": "GetWorkMomentByID", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", "required": true }, + { + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.GetWorkMomentByIDReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.GetWorkMomentByIDResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.GetWorkMomentByIDResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.GetWorkMomentByIDResp" + } + } + } + } + }, + "/office/like_one_work_moment": { + "post": { + "description": "工作圈ID点赞一条工作圈", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "工作圈" + ], + "summary": "点赞一条工作圈", + "operationId": "LikeOneWorkMoment", + "parameters": [ { "type": "string", - "description": "操作唯一ID", - "name": "operationID", - "in": "formData", + "description": "im token", + "name": "token", + "in": "header", "required": true + }, + { + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.LikeOneWorkMomentReq" + } } ], "responses": { "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.MinioUploadFileResp" + "$ref": "#/definitions/base_info.LikeOneWorkMomentResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.MinioUploadFileResp" + "$ref": "#/definitions/base_info.LikeOneWorkMomentResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.MinioUploadFileResp" + "$ref": "#/definitions/base_info.LikeOneWorkMomentResp" } } } } }, - "/user/account_check": { + "/office/send_msg_to_tag": { "post": { - "description": "传入UserIDList检查列表账户注册状态,并且返回结果", + "description": "对标签用户发送消息", "consumes": [ "application/json" ], @@ -2999,10 +3292,10 @@ "application/json" ], "tags": [ - "用户相关" + "标签" ], - "summary": "检查列表账户注册状态,并且返回结果", - "operationId": "AccountCheck", + "summary": "发送标签消息", + "operationId": "SendMsg2Tag", "parameters": [ { "type": "string", @@ -3012,12 +3305,12 @@ "required": true }, { - "description": "请求体", + "description": "请求", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.AccountCheckReq" + "$ref": "#/definitions/base_info.SendMsg2TagReq" } } ], @@ -3025,27 +3318,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.AccountCheckResp" + "$ref": "#/definitions/base_info.SendMsg2TagResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.AccountCheckResp" + "$ref": "#/definitions/base_info.SendMsg2TagResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.AccountCheckResp" + "$ref": "#/definitions/base_info.SendMsg2TagResp" } } } } }, - "/user/get_all_users_uid": { + "/office/set_tag": { "post": { - "description": "获取所有用户uid列表", + "description": "根据标签ID修改标签用户列表, 名称", "consumes": [ "application/json" ], @@ -3053,10 +3346,10 @@ "application/json" ], "tags": [ - "用户相关" + "标签" ], - "summary": "获取所有用户uid列表", - "operationId": "GetAllUsersUid", + "summary": "修改标签", + "operationId": "SetTag", "parameters": [ { "type": "string", @@ -3066,12 +3359,12 @@ "required": true }, { - "description": "请求体", + "description": "请求", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetAllUsersUidReq" + "$ref": "#/definitions/base_info.SetTagReq" } } ], @@ -3079,27 +3372,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetAllUsersUidResp" + "$ref": "#/definitions/base_info.SetTagResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetAllUsersUidResp" + "$ref": "#/definitions/base_info.SetTagResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetAllUsersUidResp" + "$ref": "#/definitions/base_info.SetTagResp" } } } } }, - "/user/get_self_user_info": { + "/organization/create_department": { "post": { - "description": "传入ID获取自己的信息", + "description": "创建部门", "consumes": [ "application/json" ], @@ -3107,10 +3400,10 @@ "application/json" ], "tags": [ - "用户相关" + "组织架构相关" ], - "summary": "获取自己的信息", - "operationId": "GetSelfUserInfo", + "summary": "创建部门", + "operationId": "CreateDepartment", "parameters": [ { "type": "string", @@ -3120,12 +3413,12 @@ "required": true }, { - "description": "请求体", + "description": "请求", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetSelfUserInfoReq" + "$ref": "#/definitions/base_info.CreateDepartmentReq" } } ], @@ -3135,13 +3428,13 @@ "schema": { "allOf": [ { - "$ref": "#/definitions/base_info.GetSelfUserInfoResp" + "$ref": "#/definitions/base_info.CreateDepartmentResp" }, { "type": "object", "properties": { "data": { - "$ref": "#/definitions/server_api_params.UserInfo" + "$ref": "#/definitions/server_api_params.Department" } } } @@ -3151,21 +3444,21 @@ "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetSelfUserInfoResp" + "$ref": "#/definitions/base_info.CreateDepartmentResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetSelfUserInfoResp" + "$ref": "#/definitions/base_info.CreateDepartmentResp" } } } } }, - "/user/get_users_info": { + "/organization/create_department_member": { "post": { - "description": "根据用户列表批量获取用户信息", + "description": "创建部门用户", "consumes": [ "application/json" ], @@ -3173,10 +3466,10 @@ "application/json" ], "tags": [ - "用户相关" + "组织架构相关" ], - "summary": "获取用户信息", - "operationId": "GetUsersInfo", + "summary": "创建部门用户", + "operationId": "CreateDepartmentMember", "parameters": [ { "type": "string", @@ -3186,12 +3479,12 @@ "required": true }, { - "description": "请求体", + "description": "请求", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetUsersInfoReq" + "$ref": "#/definitions/base_info.CreateDepartmentMemberReq" } } ], @@ -3199,27 +3492,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetUsersInfoResp" + "$ref": "#/definitions/base_info.CreateDepartmentMemberResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetUsersInfoResp" + "$ref": "#/definitions/base_info.CreateDepartmentMemberResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetUsersInfoResp" + "$ref": "#/definitions/base_info.CreateDepartmentMemberResp" } } } } }, - "/user/get_users_online_status": { + "/organization/create_organization_user": { "post": { - "description": "获取用户在线状态", + "description": "组织架构导入用户", "consumes": [ "application/json" ], @@ -3227,10 +3520,10 @@ "application/json" ], "tags": [ - "用户相关" + "组织架构相关" ], - "summary": "获取用户在线状态", - "operationId": "GetUsersOnlineStatus", + "summary": "组织架构导入用户", + "operationId": "CreateOrganizationUser", "parameters": [ { "type": "string", @@ -3240,12 +3533,12 @@ "required": true }, { - "description": "请求体", + "description": "请求", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.GetUsersOnlineStatusReq" + "$ref": "#/definitions/base_info.CreateOrganizationUserReq" } } ], @@ -3253,27 +3546,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.GetUsersOnlineStatusResp" + "$ref": "#/definitions/base_info.CreateOrganizationUserResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.GetUsersOnlineStatusResp" + "$ref": "#/definitions/base_info.CreateOrganizationUserResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.GetUsersOnlineStatusResp" + "$ref": "#/definitions/base_info.CreateOrganizationUserResp" } } } } }, - "/user/set_global_msg_recv_opt": { + "/organization/delete_department": { "post": { - "description": "设置全局免打扰", + "description": "删除部门", "consumes": [ "application/json" ], @@ -3281,10 +3574,10 @@ "application/json" ], "tags": [ - "用户相关" + "组织架构相关" ], - "summary": "设置全局免打扰", - "operationId": "SetGlobalRecvMessageOpt", + "summary": "删除部门", + "operationId": "DeleteDepartment", "parameters": [ { "type": "string", @@ -3294,12 +3587,12 @@ "required": true }, { - "description": "请求体", + "description": "请求", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.SetGlobalRecvMessageOptReq" + "$ref": "#/definitions/base_info.DeleteDepartmentReq" } } ], @@ -3307,27 +3600,27 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.SetGlobalRecvMessageOptResp" + "$ref": "#/definitions/base_info.DeleteDepartmentResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.SetGlobalRecvMessageOptResp" + "$ref": "#/definitions/base_info.DeleteDepartmentResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.SetGlobalRecvMessageOptResp" + "$ref": "#/definitions/base_info.DeleteDepartmentResp" } } } } }, - "/user/update_user_info": { + "/organization/delete_organization_user": { "post": { - "description": "修改用户信息 userID faceURL等", + "description": "删除组织架构中某个用户", "consumes": [ "application/json" ], @@ -3335,10 +3628,10 @@ "application/json" ], "tags": [ - "用户相关" + "组织架构相关" ], - "summary": "修改用户信息", - "operationId": "UpdateUserInfo", + "summary": "删除组织架构中某个用户", + "operationId": "DeleteOrganizationUser", "parameters": [ { "type": "string", @@ -3348,12 +3641,12 @@ "required": true }, { - "description": "请求体", + "description": "请求", "name": "req", "in": "body", "required": true, "schema": { - "$ref": "#/definitions/base_info.UpdateSelfUserInfoReq" + "$ref": "#/definitions/base_info.DeleteOrganizationUserReq" } } ], @@ -3361,82 +3654,1611 @@ "0": { "description": "", "schema": { - "$ref": "#/definitions/base_info.UpdateUserInfoResp" + "$ref": "#/definitions/base_info.DeleteOrganizationUserResp" } }, "400": { "description": "errCode为400 一般为参数输入错误, token未带上等", "schema": { - "$ref": "#/definitions/base_info.UpdateUserInfoResp" + "$ref": "#/definitions/base_info.DeleteOrganizationUserResp" } }, "500": { "description": "errCode为500 一般为服务器内部错误", "schema": { - "$ref": "#/definitions/base_info.UpdateUserInfoResp" + "$ref": "#/definitions/base_info.DeleteOrganizationUserResp" } } } } - } - }, - "definitions": { - "base_info.AccountCheckReq": { - "type": "object", - "required": [ - "checkUserIDList", - "operationID" - ], - "properties": { - "checkUserIDList": { - "type": "array", - "maxItems": 100, - "items": { - "type": "string" - } - }, - "operationID": { - "type": "string" - } - } }, - "base_info.AccountCheckResp": { - "type": "object", - "properties": { - "data": { - "type": "array", - "items": { - "$ref": "#/definitions/user.AccountCheckResp_SingleUserStatus" + "/organization/delete_user_in_department": { + "post": { + "description": "删除部门中某个用户", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "组织架构相关" + ], + "summary": "删除部门中某个用户", + "operationId": "DeleteUserInDepartment", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.DeleteUserInDepartmentReq" + } } - }, - "errCode": { - "type": "integer" - }, - "errMsg": { - "type": "string" + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.DeleteUserInDepartmentResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.DeleteUserInDepartmentResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.DeleteUserInDepartmentResp" + } + } + } + } + }, + "/organization/get_department_member": { + "post": { + "description": "获取部门中所有成员", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "组织架构相关" + ], + "summary": "获取部门中所有成员", + "operationId": "GetDepartmentMember", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.GetDepartmentMemberReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "allOf": [ + { + "$ref": "#/definitions/base_info.GetDepartmentMemberResp" + }, + { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/server_api_params.UserDepartmentMember" + } + } + } + ] + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.GetDepartmentMemberResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.GetDepartmentMemberResp" + } + } + } + } + }, + "/organization/get_sub_department": { + "post": { + "description": "获取子部门列表", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "组织架构相关" + ], + "summary": "获取子部门列表", + "operationId": "GetSubDepartment", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.GetSubDepartmentReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.GetSubDepartmentResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.GetSubDepartmentResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.GetSubDepartmentResp" + } + } + } + } + }, + "/organization/get_user_in_department": { + "post": { + "description": "获取部门中的所有用户", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "组织架构相关" + ], + "summary": "获取部门中的所有用户", + "operationId": "GetUserInDepartment", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.GetUserInDepartmentReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "allOf": [ + { + "$ref": "#/definitions/base_info.GetUserInDepartmentResp" + }, + { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/server_api_params.UserInDepartment" + } + } + } + ] + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.GetUserInDepartmentResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.GetUserInDepartmentResp" + } + } + } + } + }, + "/organization/update_department": { + "post": { + "description": "更新部门信息", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "组织架构相关" + ], + "summary": "更新部门信息", + "operationId": "UpdateDepartment", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.UpdateDepartmentReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.UpdateDepartmentResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.UpdateDepartmentResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.UpdateDepartmentResp" + } + } + } + } + }, + "/organization/update_organization_user": { + "post": { + "description": "更新组织架构中的用户", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "组织架构相关" + ], + "summary": "更新组织架构中的用户", + "operationId": "UpdateOrganizationUser", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.UpdateOrganizationUserReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.UpdateOrganizationUserResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.UpdateOrganizationUserResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.UpdateOrganizationUserResp" + } + } + } + } + }, + "/organization/update_user_in_department": { + "post": { + "description": "更新部门中某个用户", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "组织架构相关" + ], + "summary": "更新部门中某个用户", + "operationId": "UpdateUserInDepartment", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.UpdateUserInDepartmentReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.UpdateUserInDepartmentResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.UpdateUserInDepartmentResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.UpdateUserInDepartmentResp" + } + } + } + } + }, + "/third/minio_upload": { + "post": { + "description": "minio上传文件(web api), 请注意本api请求为form并非json", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "第三方服务相关" + ], + "summary": "minio上传文件(web api)", + "operationId": "MinioUploadFile", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "type": "file", + "description": "要上传的文件文件", + "name": "file", + "in": "formData", + "required": true + }, + { + "type": "integer", + "description": "文件类型", + "name": "fileType", + "in": "formData", + "required": true + }, + { + "type": "string", + "description": "操作唯一ID", + "name": "operationID", + "in": "formData", + "required": true + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.MinioUploadFileResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.Swagger400Resp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.Swagger500Resp" + } + } + } + } + }, + "/user/account_check": { + "post": { + "description": "传入UserIDList检查列表账户注册状态,并且返回结果", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "用户相关" + ], + "summary": "检查列表账户注册状态,并且返回结果", + "operationId": "AccountCheck", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求体", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.AccountCheckReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.AccountCheckResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.AccountCheckResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.AccountCheckResp" + } + } + } + } + }, + "/user/get_all_users_uid": { + "post": { + "description": "获取所有用户uid列表", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "用户相关" + ], + "summary": "获取所有用户uid列表", + "operationId": "GetAllUsersUid", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求体", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.GetAllUsersUidReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.GetAllUsersUidResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.GetAllUsersUidResp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.GetAllUsersUidResp" + } + } + } + } + }, + "/user/get_self_user_info": { + "post": { + "description": "传入ID获取自己的信息", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "用户相关" + ], + "summary": "获取自己的信息", + "operationId": "GetSelfUserInfo", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求体", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.GetSelfUserInfoReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "allOf": [ + { + "$ref": "#/definitions/base_info.GetSelfUserInfoResp" + }, + { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/server_api_params.UserInfo" + } + } + } + ] + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.Swagger400Resp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.Swagger500Resp" + } + } + } + } + }, + "/user/get_users_info": { + "post": { + "description": "根据用户列表批量获取用户信息", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "用户相关" + ], + "summary": "获取用户信息", + "operationId": "GetUsersInfo", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求体", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.GetUsersInfoReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "allOf": [ + { + "$ref": "#/definitions/base_info.GetUsersInfoResp" + }, + { + "type": "object", + "properties": { + "Data": { + "type": "array", + "items": { + "$ref": "#/definitions/server_api_params.PublicUserInfo" + } + } + } + } + ] + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.Swagger400Resp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.Swagger500Resp" + } + } + } + } + }, + "/user/get_users_online_status": { + "post": { + "description": "获取用户在线状态", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "用户相关" + ], + "summary": "获取用户在线状态", + "operationId": "GetUsersOnlineStatus", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求体", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.GetUsersOnlineStatusReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.GetUsersOnlineStatusResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.Swagger400Resp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.Swagger500Resp" + } + } + } + } + }, + "/user/set_global_msg_recv_opt": { + "post": { + "description": "设置全局免打扰", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "用户相关" + ], + "summary": "设置全局免打扰", + "operationId": "SetGlobalRecvMessageOpt", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "globalRecvMsgOpt为全局免打扰设置0为关闭 1为开启", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.SetGlobalRecvMessageOptReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.SetGlobalRecvMessageOptResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.Swagger400Resp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.Swagger500Resp" + } + } + } + } + }, + "/user/update_user_info": { + "post": { + "description": "修改用户信息 userID faceURL等", + "consumes": [ + "application/json" + ], + "produces": [ + "application/json" + ], + "tags": [ + "用户相关" + ], + "summary": "修改用户信息", + "operationId": "UpdateUserInfo", + "parameters": [ + { + "type": "string", + "description": "im token", + "name": "token", + "in": "header", + "required": true + }, + { + "description": "请求体", + "name": "req", + "in": "body", + "required": true, + "schema": { + "$ref": "#/definitions/base_info.UpdateSelfUserInfoReq" + } + } + ], + "responses": { + "0": { + "description": "", + "schema": { + "$ref": "#/definitions/base_info.UpdateUserInfoResp" + } + }, + "400": { + "description": "errCode为400 一般为参数输入错误, token未带上等", + "schema": { + "$ref": "#/definitions/base_info.Swagger400Resp" + } + }, + "500": { + "description": "errCode为500 一般为服务器内部错误", + "schema": { + "$ref": "#/definitions/base_info.Swagger500Resp" + } + } + } + } + } + }, + "definitions": { + "Open_IM_internal_api_manage.FileElem": { + "type": "object", + "properties": { + "fileName": { + "type": "string" + }, + "filePath": { + "type": "string" + }, + "fileSize": { + "type": "integer" + }, + "sourceURL": { + "type": "string" + }, + "uuid": { + "type": "string" + } + } + }, + "Open_IM_internal_api_manage.OANotificationElem": { + "type": "object", + "required": [ + "notificationFaceURL", + "notificationName", + "notificationType", + "text" + ], + "properties": { + "ex": { + "type": "string" + }, + "fileElem": { + "$ref": "#/definitions/Open_IM_internal_api_manage.FileElem" + }, + "mixType": { + "type": "integer" + }, + "notificationFaceURL": { + "type": "string" + }, + "notificationName": { + "type": "string" + }, + "notificationType": { + "type": "integer" + }, + "pictureElem": { + "$ref": "#/definitions/Open_IM_internal_api_manage.PictureElem" + }, + "soundElem": { + "$ref": "#/definitions/Open_IM_internal_api_manage.SoundElem" + }, + "text": { + "type": "string" + }, + "url": { + "type": "string" + }, + "videoElem": { + "$ref": "#/definitions/Open_IM_internal_api_manage.VideoElem" + } + } + }, + "Open_IM_internal_api_manage.PictureBaseInfo": { + "type": "object", + "properties": { + "height": { + "type": "integer" + }, + "size": { + "type": "integer" + }, + "type": { + "type": "string" + }, + "url": { + "type": "string" + }, + "uuid": { + "type": "string" + }, + "width": { + "type": "integer" + } + } + }, + "Open_IM_internal_api_manage.PictureElem": { + "type": "object", + "properties": { + "bigPicture": { + "$ref": "#/definitions/Open_IM_internal_api_manage.PictureBaseInfo" + }, + "snapshotPicture": { + "$ref": "#/definitions/Open_IM_internal_api_manage.PictureBaseInfo" + }, + "sourcePath": { + "type": "string" + }, + "sourcePicture": { + "$ref": "#/definitions/Open_IM_internal_api_manage.PictureBaseInfo" + } + } + }, + "Open_IM_internal_api_manage.RevokeElem": { + "type": "object", + "required": [ + "revokeMsgClientID" + ], + "properties": { + "revokeMsgClientID": { + "type": "string" + } + } + }, + "Open_IM_internal_api_manage.SoundElem": { + "type": "object", + "properties": { + "dataSize": { + "type": "integer" + }, + "duration": { + "type": "integer" + }, + "soundPath": { + "type": "string" + }, + "sourceURL": { + "type": "string" + }, + "uuid": { + "type": "string" + } + } + }, + "Open_IM_internal_api_manage.TextElem": { + "type": "object", + "required": [ + "text" + ], + "properties": { + "text": { + "type": "string" + } + } + }, + "Open_IM_internal_api_manage.VideoElem": { + "type": "object", + "properties": { + "duration": { + "type": "integer" + }, + "snapshotHeight": { + "type": "integer" + }, + "snapshotPath": { + "type": "string" + }, + "snapshotSize": { + "type": "integer" + }, + "snapshotURL": { + "type": "string" + }, + "snapshotUUID": { + "type": "string" + }, + "snapshotWidth": { + "type": "integer" + }, + "videoPath": { + "type": "string" + }, + "videoSize": { + "type": "integer" + }, + "videoType": { + "type": "string" + }, + "videoURL": { + "type": "string" + }, + "videoUUID": { + "type": "string" + } + } + }, + "base_info.AccountCheckReq": { + "type": "object", + "required": [ + "checkUserIDList", + "operationID" + ], + "properties": { + "checkUserIDList": { + "type": "array", + "maxItems": 100, + "items": { + "type": "string" + } + }, + "operationID": { + "type": "string" + } + } + }, + "base_info.AccountCheckResp": { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "$ref": "#/definitions/user.AccountCheckResp_SingleUserStatus" + } + }, + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.AddBlacklistReq": { + "type": "object", + "required": [ + "fromUserID", + "operationID", + "toUserID" + ], + "properties": { + "fromUserID": { + "type": "string" + }, + "operationID": { + "type": "string" + }, + "toUserID": { + "type": "string" + } + } + }, + "base_info.AddBlacklistResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.AddFriendReq": { + "type": "object", + "required": [ + "fromUserID", + "operationID", + "toUserID" + ], + "properties": { + "fromUserID": { + "type": "string" + }, + "operationID": { + "type": "string" + }, + "reqMsg": { + "type": "string" + }, + "toUserID": { + "type": "string" + } + } + }, + "base_info.AddFriendResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.AddFriendResponseReq": { + "type": "object", + "required": [ + "flag", + "fromUserID", + "operationID", + "toUserID" + ], + "properties": { + "flag": { + "type": "integer", + "enum": [ + -1, + 0, + 1 + ] + }, + "fromUserID": { + "type": "string" + }, + "handleMsg": { + "type": "string" + }, + "operationID": { + "type": "string" + }, + "toUserID": { + "type": "string" + } + } + }, + "base_info.AddFriendResponseResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.ApplicationGroupResponseReq": { + "type": "object", + "required": [ + "fromUserID", + "groupID", + "handleResult", + "operationID" + ], + "properties": { + "fromUserID": { + "description": "application from FromUserID", + "type": "string" + }, + "groupID": { + "type": "string" + }, + "handleResult": { + "type": "integer", + "enum": [ + -1, + 1 + ] + }, + "handledMsg": { + "type": "string" + }, + "operationID": { + "type": "string" + } + } + }, + "base_info.ApplicationGroupResponseResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.CancelMuteGroupMemberReq": { + "type": "object", + "required": [ + "groupID", + "operationID", + "userID" + ], + "properties": { + "groupID": { + "type": "string" + }, + "operationID": { + "type": "string" + }, + "userID": { + "type": "string" + } + } + }, + "base_info.CancelMuteGroupMemberResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.CancelMuteGroupReq": { + "type": "object", + "required": [ + "groupID", + "operationID" + ], + "properties": { + "groupID": { + "type": "string" + }, + "operationID": { + "type": "string" } } }, - "base_info.AddBlacklistReq": { + "base_info.CancelMuteGroupResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.CleanUpMsgReq": { "type": "object", "required": [ - "fromUserID", "operationID", - "toUserID" + "userID" ], "properties": { - "fromUserID": { + "operationID": { + "type": "string" + }, + "userID": { + "type": "string" + } + } + }, + "base_info.CleanUpMsgResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.Comment": { + "type": "object", + "properties": { + "content": { + "type": "string" + }, + "contentID": { + "type": "string" + }, + "createTime": { + "type": "integer" + }, + "replyUserID": { + "type": "string" + }, + "replyUserName": { + "type": "string" + }, + "userID": { + "type": "string" + }, + "userName": { + "type": "string" + } + } + }, + "base_info.CommentOneWorkMomentReq": { + "type": "object", + "required": [ + "content", + "operationID", + "workMomentID" + ], + "properties": { + "content": { + "type": "string" + }, + "operationID": { + "type": "string" + }, + "replyUserID": { + "type": "string" + }, + "workMomentID": { + "type": "string" + } + } + }, + "base_info.CommentOneWorkMomentResp": { + "type": "object", + "properties": { + "data": { + "type": "object" + }, + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.Conversation": { + "type": "object", + "required": [ + "conversationID", + "conversationType", + "ownerUserID" + ], + "properties": { + "attachedInfo": { + "type": "string" + }, + "conversationID": { + "type": "string" + }, + "conversationType": { + "type": "integer" + }, + "draftTextTime": { + "type": "integer" + }, + "ex": { + "type": "string" + }, + "groupAtType": { + "type": "integer" + }, + "groupID": { + "type": "string" + }, + "isNotInGroup": { + "type": "boolean" + }, + "isPinned": { + "type": "boolean" + }, + "isPrivateChat": { + "type": "boolean" + }, + "ownerUserID": { + "type": "string" + }, + "recvMsgOpt": { + "type": "integer", + "enum": [ + 0, + 1, + 2 + ] + }, + "unreadCount": { + "type": "integer" + }, + "userID": { + "type": "string" + } + } + }, + "base_info.CreateDepartmentMemberReq": { + "type": "object", + "required": [ + "operationID" + ], + "properties": { + "departmentID": { + "type": "string" + }, + "ex": { + "type": "string" + }, + "leader": { + "type": "integer" + }, + "operationID": { + "type": "string" + }, + "order": { + "type": "integer" + }, + "position": { + "type": "string" + }, + "status": { + "type": "integer" + }, + "userID": { + "type": "string" + } + } + }, + "base_info.CreateDepartmentMemberResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.CreateDepartmentReq": { + "type": "object", + "required": [ + "operationID" + ], + "properties": { + "createTime": { + "type": "integer" + }, + "departmentID": { + "type": "string" + }, + "departmentType": { + "type": "integer" + }, + "ex": { + "type": "string" + }, + "faceURL": { + "type": "string" + }, + "memberNum": { + "type": "integer" + }, + "name": { + "type": "string" + }, + "operationID": { + "type": "string" + }, + "order": { + "type": "integer" + }, + "parentID": { + "type": "string" + }, + "subDepartmentNum": { + "type": "integer" + } + } + }, + "base_info.CreateDepartmentResp": { + "type": "object", + "properties": { + "data": { + "type": "object", + "additionalProperties": true + }, + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.CreateGroupReq": { + "type": "object", + "required": [ + "operationID" + ], + "properties": { + "ex": { + "type": "string" + }, + "faceURL": { + "type": "string" + }, + "groupID": { + "type": "string" + }, + "groupName": { + "type": "string" + }, + "groupType": { + "type": "integer" + }, + "introduction": { + "type": "string" + }, + "memberList": { + "type": "array", + "items": { + "$ref": "#/definitions/base_info.GroupAddMemberInfo" + } + }, + "notification": { "type": "string" }, "operationID": { "type": "string" }, - "toUserID": { + "ownerUserID": { "type": "string" } } }, - "base_info.AddBlacklistResp": { + "base_info.CreateGroupResp": { "type": "object", "properties": { "errCode": { @@ -3447,31 +5269,23 @@ } } }, - "base_info.AddFriendReq": { + "base_info.CreateOneWorkMomentReq": { "type": "object", - "required": [ - "fromUserID", - "operationID", - "toUserID" - ], "properties": { - "fromUserID": { - "type": "string" - }, "operationID": { "type": "string" }, - "reqMsg": { - "type": "string" - }, - "toUserID": { - "type": "string" + "workMoment": { + "$ref": "#/definitions/office.WorkMoment" } } }, - "base_info.AddFriendResp": { + "base_info.CreateOneWorkMomentResp": { "type": "object", "properties": { + "data": { + "type": "object" + }, "errCode": { "type": "integer" }, @@ -3480,38 +5294,51 @@ } } }, - "base_info.AddFriendResponseReq": { + "base_info.CreateOrganizationUserReq": { "type": "object", "required": [ - "flag", - "fromUserID", - "operationID", - "toUserID" + "operationID" ], "properties": { - "flag": { - "type": "integer", - "enum": [ - -1, - 0, - 1 - ] + "birth": { + "type": "integer" }, - "fromUserID": { + "createTime": { + "type": "integer" + }, + "email": { "type": "string" }, - "handleMsg": { + "englishName": { + "type": "string" + }, + "ex": { + "type": "string" + }, + "faceURL": { + "type": "string" + }, + "gender": { + "type": "integer" + }, + "mobile": { + "type": "string" + }, + "nickname": { "type": "string" }, "operationID": { "type": "string" }, - "toUserID": { + "telephone": { + "type": "string" + }, + "userID": { "type": "string" } } }, - "base_info.AddFriendResponseResp": { + "base_info.CreateOrganizationUserResp": { "type": "object", "properties": { "errCode": { @@ -3522,38 +5349,31 @@ } } }, - "base_info.ApplicationGroupResponseReq": { + "base_info.CreateTagReq": { "type": "object", "required": [ - "fromUserID", - "groupID", - "handleResult", - "operationID" + "operationID", + "tagName", + "userIDList" ], "properties": { - "fromUserID": { - "description": "application from FromUserID", - "type": "string" - }, - "groupID": { + "operationID": { "type": "string" }, - "handleResult": { - "type": "integer", - "enum": [ - -1, - 1 - ] - }, - "handledMsg": { + "tagName": { + "description": "tag名称", "type": "string" }, - "operationID": { - "type": "string" + "userIDList": { + "description": "用户ID列表", + "type": "array", + "items": { + "type": "string" + } } } }, - "base_info.ApplicationGroupResponseResp": { + "base_info.CreateTagResp": { "type": "object", "properties": { "errCode": { @@ -3564,26 +5384,29 @@ } } }, - "base_info.CancelMuteGroupMemberReq": { + "base_info.DelMsgReq": { "type": "object", "required": [ - "groupID", "operationID", + "seqList", "userID" ], "properties": { - "groupID": { - "type": "string" - }, "operationID": { "type": "string" }, + "seqList": { + "type": "array", + "items": { + "type": "integer" + } + }, "userID": { "type": "string" } } }, - "base_info.CancelMuteGroupMemberResp": { + "base_info.DelMsgResp": { "type": "object", "properties": { "errCode": { @@ -3594,24 +5417,31 @@ } } }, - "base_info.CancelMuteGroupReq": { + "base_info.DeleteCommentReq": { "type": "object", "required": [ - "groupID", - "operationID" + "contentID", + "operationID", + "workMomentID" ], "properties": { - "groupID": { + "contentID": { "type": "string" }, "operationID": { "type": "string" + }, + "workMomentID": { + "type": "string" } } }, - "base_info.CancelMuteGroupResp": { + "base_info.DeleteCommentResp": { "type": "object", "properties": { + "data": { + "type": "object" + }, "errCode": { "type": "integer" }, @@ -3620,22 +5450,22 @@ } } }, - "base_info.CleanUpMsgReq": { + "base_info.DeleteDepartmentReq": { "type": "object", "required": [ - "operationID", - "userID" + "departmentID", + "operationID" ], "properties": { - "operationID": { + "departmentID": { "type": "string" }, - "userID": { + "operationID": { "type": "string" } } }, - "base_info.CleanUpMsgResp": { + "base_info.DeleteDepartmentResp": { "type": "object", "properties": { "errCode": { @@ -3646,60 +5476,28 @@ } } }, - "base_info.Comment": { - "type": "object", - "properties": { - "content": { - "type": "string" - }, - "contentID": { - "type": "string" - }, - "createTime": { - "type": "integer" - }, - "replyUserID": { - "type": "string" - }, - "replyUserName": { - "type": "string" - }, - "userID": { - "type": "string" - }, - "userName": { - "type": "string" - } - } - }, - "base_info.CommentOneWorkMomentReq": { + "base_info.DeleteFriendReq": { "type": "object", "required": [ - "content", + "fromUserID", "operationID", - "workMomentID" + "toUserID" ], "properties": { - "content": { + "fromUserID": { "type": "string" }, "operationID": { "type": "string" }, - "replyUserID": { - "type": "string" - }, - "workMomentID": { + "toUserID": { "type": "string" } } }, - "base_info.CommentOneWorkMomentResp": { + "base_info.DeleteFriendResp": { "type": "object", "properties": { - "data": { - "type": "object" - }, "errCode": { "type": "integer" }, @@ -3708,50 +5506,27 @@ } } }, - "base_info.CreateGroupReq": { + "base_info.DeleteOneWorkMomentReq": { "type": "object", "required": [ - "operationID" + "operationID", + "workMomentID" ], "properties": { - "ex": { - "type": "string" - }, - "faceURL": { - "type": "string" - }, - "groupID": { - "type": "string" - }, - "groupName": { - "type": "string" - }, - "groupType": { - "type": "integer" - }, - "introduction": { - "type": "string" - }, - "memberList": { - "type": "array", - "items": { - "$ref": "#/definitions/base_info.GroupAddMemberInfo" - } - }, - "notification": { - "type": "string" - }, "operationID": { "type": "string" }, - "ownerUserID": { + "workMomentID": { "type": "string" } } }, - "base_info.CreateGroupResp": { + "base_info.DeleteOneWorkMomentResp": { "type": "object", "properties": { + "data": { + "type": "object" + }, "errCode": { "type": "integer" }, @@ -3760,23 +5535,24 @@ } } }, - "base_info.CreateOneWorkMomentReq": { + "base_info.DeleteOrganizationUserReq": { "type": "object", + "required": [ + "operationID", + "userID" + ], "properties": { "operationID": { "type": "string" }, - "workMoment": { - "$ref": "#/definitions/office.WorkMoment" + "userID": { + "type": "string" } } }, - "base_info.CreateOneWorkMomentResp": { + "base_info.DeleteOrganizationUserResp": { "type": "object", "properties": { - "data": { - "type": "object" - }, "errCode": { "type": "integer" }, @@ -3785,31 +5561,22 @@ } } }, - "base_info.CreateTagReq": { + "base_info.DeleteTagReq": { "type": "object", "required": [ "operationID", - "tagName", - "userIDList" + "tagID" ], "properties": { - "operationID": { - "type": "string" - }, - "tagName": { - "description": "tag名称", + "operationID": { "type": "string" }, - "userIDList": { - "description": "用户ID列表", - "type": "array", - "items": { - "type": "string" - } + "tagID": { + "type": "string" } } }, - "base_info.CreateTagResp": { + "base_info.DeleteTagResp": { "type": "object", "properties": { "errCode": { @@ -3820,29 +5587,26 @@ } } }, - "base_info.DelMsgReq": { + "base_info.DeleteUserInDepartmentReq": { "type": "object", "required": [ + "departmentID", "operationID", - "seqList", "userID" ], "properties": { - "operationID": { + "departmentID": { "type": "string" }, - "seqList": { - "type": "array", - "items": { - "type": "integer" - } + "operationID": { + "type": "string" }, "userID": { "type": "string" } } }, - "base_info.DelMsgResp": { + "base_info.DeleteUserInDepartmentResp": { "type": "object", "properties": { "errCode": { @@ -3853,31 +5617,24 @@ } } }, - "base_info.DeleteCommentReq": { + "base_info.DismissGroupReq": { "type": "object", "required": [ - "contentID", - "operationID", - "workMomentID" + "groupID", + "operationID" ], "properties": { - "contentID": { + "groupID": { "type": "string" }, "operationID": { "type": "string" - }, - "workMomentID": { - "type": "string" } } }, - "base_info.DeleteCommentResp": { + "base_info.DismissGroupResp": { "type": "object", "properties": { - "data": { - "type": "object" - }, "errCode": { "type": "integer" }, @@ -3886,26 +5643,38 @@ } } }, - "base_info.DeleteFriendReq": { + "base_info.ExpireTime": { + "type": "object", + "properties": { + "expireTimeSeconds": { + "type": "integer" + } + } + }, + "base_info.ForceLogoutReq": { "type": "object", "required": [ "fromUserID", "operationID", - "toUserID" + "platform" ], "properties": { "fromUserID": { - "type": "string" + "type": "string", + "maxLength": 64, + "minLength": 1 }, "operationID": { "type": "string" }, - "toUserID": { - "type": "string" + "platform": { + "type": "integer", + "maximum": 8, + "minimum": 1 } } }, - "base_info.DeleteFriendResp": { + "base_info.ForceLogoutResp": { "type": "object", "properties": { "errCode": { @@ -3916,26 +5685,29 @@ } } }, - "base_info.DeleteOneWorkMomentReq": { + "base_info.GetAllConversationsReq": { "type": "object", "required": [ "operationID", - "workMomentID" + "ownerUserID" ], "properties": { "operationID": { "type": "string" }, - "workMomentID": { + "ownerUserID": { "type": "string" } } }, - "base_info.DeleteOneWorkMomentResp": { + "base_info.GetAllConversationsResp": { "type": "object", "properties": { "data": { - "type": "object" + "type": "array", + "items": { + "$ref": "#/definitions/base_info.Conversation" + } }, "errCode": { "type": "integer" @@ -3945,24 +5717,26 @@ } } }, - "base_info.DeleteTagReq": { + "base_info.GetAllUsersUidReq": { "type": "object", "required": [ - "operationID", - "tagID" + "operationID" ], "properties": { "operationID": { "type": "string" - }, - "tagID": { - "type": "string" } } }, - "base_info.DeleteTagResp": { + "base_info.GetAllUsersUidResp": { "type": "object", "properties": { + "data": { + "type": "array", + "items": { + "type": "string" + } + }, "errCode": { "type": "integer" }, @@ -3971,14 +5745,14 @@ } } }, - "base_info.DismissGroupReq": { + "base_info.GetBlackListReq": { "type": "object", "required": [ - "groupID", + "fromUserID", "operationID" ], "properties": { - "groupID": { + "fromUserID": { "type": "string" }, "operationID": { @@ -3986,7 +5760,7 @@ } } }, - "base_info.DismissGroupResp": { + "base_info.GetBlackListResp": { "type": "object", "properties": { "errCode": { @@ -3997,32 +5771,31 @@ } } }, - "base_info.ForceLogoutReq": { + "base_info.GetConversationReq": { "type": "object", "required": [ - "fromUserID", + "conversationID", "operationID", - "platform" + "ownerUserID" ], "properties": { - "fromUserID": { - "type": "string", - "maxLength": 64, - "minLength": 1 + "conversationID": { + "type": "string" }, "operationID": { "type": "string" }, - "platform": { - "type": "integer", - "maximum": 8, - "minimum": 1 + "ownerUserID": { + "type": "string" } } }, - "base_info.ForceLogoutResp": { + "base_info.GetConversationResp": { "type": "object", "properties": { + "data": { + "$ref": "#/definitions/base_info.Conversation" + }, "errCode": { "type": "integer" }, @@ -4031,24 +5804,35 @@ } } }, - "base_info.GetAllUsersUidReq": { + "base_info.GetConversationsReq": { "type": "object", "required": [ - "operationID" + "conversationIDs", + "operationID", + "ownerUserID" ], "properties": { + "conversationIDs": { + "type": "array", + "items": { + "type": "string" + } + }, "operationID": { "type": "string" + }, + "ownerUserID": { + "type": "string" } } }, - "base_info.GetAllUsersUidResp": { + "base_info.GetConversationsResp": { "type": "object", "properties": { "data": { "type": "array", "items": { - "type": "string" + "$ref": "#/definitions/base_info.Conversation" } }, "errCode": { @@ -4059,14 +5843,14 @@ } } }, - "base_info.GetBlackListReq": { + "base_info.GetDepartmentMemberReq": { "type": "object", "required": [ - "fromUserID", + "departmentID", "operationID" ], "properties": { - "fromUserID": { + "departmentID": { "type": "string" }, "operationID": { @@ -4074,7 +5858,7 @@ } } }, - "base_info.GetBlackListResp": { + "base_info.GetDepartmentMemberResp": { "type": "object", "properties": { "data": { @@ -4110,13 +5894,6 @@ "base_info.GetFriendApplyListResp": { "type": "object", "properties": { - "data": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": true - } - }, "errCode": { "type": "integer" }, @@ -4143,13 +5920,6 @@ "base_info.GetFriendListResp": { "type": "object", "properties": { - "data": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": true - } - }, "errCode": { "type": "integer" }, @@ -4176,13 +5946,6 @@ "base_info.GetGroupAllMemberResp": { "type": "object", "properties": { - "data": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": true - } - }, "errCode": { "type": "integer" }, @@ -4210,13 +5973,6 @@ "base_info.GetGroupApplicationListResp": { "type": "object", "properties": { - "data": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": true - } - }, "errCode": { "type": "integer" }, @@ -4246,13 +6002,6 @@ "base_info.GetGroupInfoResp": { "type": "object", "properties": { - "data": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": true - } - }, "errCode": { "type": "integer" }, @@ -4286,13 +6035,6 @@ "base_info.GetGroupMembersInfoResp": { "type": "object", "properties": { - "data": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": true - } - }, "errCode": { "type": "integer" }, @@ -4319,13 +6061,6 @@ "base_info.GetJoinedGroupListResp": { "type": "object", "properties": { - "data": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": true - } - }, "errCode": { "type": "integer" }, @@ -4352,13 +6087,6 @@ "base_info.GetSelfApplyListResp": { "type": "object", "properties": { - "data": { - "type": "array", - "items": { - "type": "object", - "additionalProperties": true - } - }, "errCode": { "type": "integer" }, @@ -4393,6 +6121,39 @@ } } }, + "base_info.GetSubDepartmentReq": { + "type": "object", + "required": [ + "departmentID", + "operationID" + ], + "properties": { + "departmentID": { + "type": "string" + }, + "operationID": { + "type": "string" + } + } + }, + "base_info.GetSubDepartmentResp": { + "type": "object", + "properties": { + "data": { + "type": "array", + "items": { + "type": "object", + "additionalProperties": true + } + }, + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, "base_info.GetTagSendLogsReq": { "type": "object", "required": [ @@ -4451,33 +6212,63 @@ "operationID": { "type": "string" }, - "pageNumber": { - "type": "integer" - }, - "showNumber": { - "type": "integer" + "pageNumber": { + "type": "integer" + }, + "showNumber": { + "type": "integer" + } + } + }, + "base_info.GetUserFriendWorkMomentsResp": { + "type": "object", + "properties": { + "data": { + "type": "object", + "properties": { + "currentPage": { + "type": "integer" + }, + "showNumber": { + "type": "integer" + }, + "workMoments": { + "type": "array", + "items": { + "$ref": "#/definitions/base_info.WorkMoment" + } + } + } + }, + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.GetUserInDepartmentReq": { + "type": "object", + "required": [ + "operationID", + "userID" + ], + "properties": { + "operationID": { + "type": "string" + }, + "userID": { + "type": "string" } } }, - "base_info.GetUserFriendWorkMomentsResp": { + "base_info.GetUserInDepartmentResp": { "type": "object", "properties": { "data": { "type": "object", - "properties": { - "currentPage": { - "type": "integer" - }, - "showNumber": { - "type": "integer" - }, - "workMoments": { - "type": "array", - "items": { - "$ref": "#/definitions/base_info.WorkMoment" - } - } - } + "additionalProperties": true }, "errCode": { "type": "integer" @@ -4947,19 +6738,135 @@ } } }, - "base_info.MinioUploadFileResp": { + "base_info.ManagementBatchSendMsgReq": { "type": "object", + "required": [ + "contentType", + "operationID", + "sendID", + "sessionType" + ], "properties": { - "URL": { + "contentType": { + "type": "integer" + }, + "groupID": { "type": "string" }, - "newName": { + "isOnlineOnly": { + "type": "boolean" + }, + "offlinePushInfo": { + "$ref": "#/definitions/server_api_params.OfflinePushInfo" + }, + "operationID": { + "type": "string" + }, + "recvIDList": { + "type": "array", + "items": { + "type": "string" + } + }, + "sendID": { "type": "string" }, - "snapshotName": { + "senderFaceURL": { "type": "string" }, - "snapshotURL": { + "senderNickname": { + "type": "string" + }, + "senderPlatformID": { + "type": "integer" + }, + "sessionType": { + "type": "integer" + } + } + }, + "base_info.ManagementSendMsgReq": { + "type": "object", + "required": [ + "contentType", + "operationID", + "sendID", + "sessionType" + ], + "properties": { + "contentType": { + "type": "integer" + }, + "groupID": { + "type": "string" + }, + "isOnlineOnly": { + "type": "boolean" + }, + "offlinePushInfo": { + "$ref": "#/definitions/server_api_params.OfflinePushInfo" + }, + "operationID": { + "type": "string" + }, + "recvID": { + "type": "string" + }, + "sendID": { + "type": "string" + }, + "senderFaceURL": { + "type": "string" + }, + "senderNickname": { + "type": "string" + }, + "senderPlatformID": { + "type": "integer" + }, + "sessionType": { + "type": "integer" + } + } + }, + "base_info.ManagementSendMsgResp": { + "type": "object", + "properties": { + "data": { + "$ref": "#/definitions/server_api_params.UserSendMsgResp" + }, + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.MinioUploadFileResp": { + "type": "object", + "properties": { + "data": { + "type": "object", + "properties": { + "URL": { + "type": "string" + }, + "newName": { + "type": "string" + }, + "snapshotName": { + "type": "string" + }, + "snapshotURL": { + "type": "string" + } + } + }, + "errCode": { + "type": "integer" + }, + "errMsg": { "type": "string" } } @@ -5027,10 +6934,6 @@ "base_info.ParseTokenResp": { "type": "object", "properties": { - "data": { - "type": "object", - "additionalProperties": true - }, "errCode": { "type": "integer" }, @@ -5248,7 +7151,152 @@ } } }, - "base_info.SetGroupInfoResp": { + "base_info.SetGroupInfoResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.SetGroupMemberInfoReq": { + "type": "object", + "required": [ + "groupID", + "operationID", + "userID" + ], + "properties": { + "ex": { + "type": "string" + }, + "groupID": { + "type": "string" + }, + "nickname": { + "type": "string" + }, + "operationID": { + "type": "string" + }, + "roleLevel": { + "type": "integer", + "maximum": 3, + "minimum": 1 + }, + "userGroupFaceUrl": { + "type": "string" + }, + "userID": { + "type": "string" + } + } + }, + "base_info.SetGroupMemberInfoResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.SetTagReq": { + "type": "object", + "required": [ + "operationID", + "tagID" + ], + "properties": { + "increaseUserIDList": { + "type": "array", + "items": { + "type": "string" + } + }, + "newName": { + "type": "string" + }, + "operationID": { + "type": "string" + }, + "reduceUserIDList": { + "type": "array", + "items": { + "type": "string" + } + }, + "tagID": { + "type": "string" + } + } + }, + "base_info.SetTagResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, + "base_info.Swagger400Resp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer", + "example": 400 + }, + "errMsg": { + "type": "string", + "example": "err msg" + } + } + }, + "base_info.Swagger500Resp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer", + "example": 500 + }, + "errMsg": { + "type": "string", + "example": "err msg" + } + } + }, + "base_info.TransferGroupOwnerReq": { + "type": "object", + "required": [ + "groupID", + "newOwnerUserID", + "oldOwnerUserID", + "operationID" + ], + "properties": { + "groupID": { + "type": "string" + }, + "newOwnerUserID": { + "type": "string" + }, + "oldOwnerUserID": { + "type": "string" + }, + "operationID": { + "type": "string" + } + } + }, + "base_info.TransferGroupOwnerResp": { "type": "object", "properties": { "errCode": { @@ -5259,40 +7307,49 @@ } } }, - "base_info.SetGroupMemberInfoReq": { + "base_info.UpdateDepartmentReq": { "type": "object", "required": [ - "groupID", - "operationID", - "userID" + "departmentID", + "operationID" ], "properties": { + "createTime": { + "type": "integer" + }, + "departmentID": { + "type": "string" + }, + "departmentType": { + "type": "integer" + }, "ex": { "type": "string" }, - "groupID": { + "faceURL": { "type": "string" }, - "nickname": { + "memberNum": { + "type": "integer" + }, + "name": { "type": "string" }, "operationID": { "type": "string" }, - "roleLevel": { - "type": "integer", - "maximum": 3, - "minimum": 1 + "order": { + "type": "integer" }, - "userGroupFaceUrl": { + "parentID": { "type": "string" }, - "userID": { - "type": "string" + "subDepartmentNum": { + "type": "integer" } } }, - "base_info.SetGroupMemberInfoResp": { + "base_info.UpdateDepartmentResp": { "type": "object", "properties": { "errCode": { @@ -5303,71 +7360,51 @@ } } }, - "base_info.SetTagReq": { + "base_info.UpdateOrganizationUserReq": { "type": "object", "required": [ - "operationID", - "tagID" + "operationID" ], "properties": { - "increaseUserIDList": { - "type": "array", - "items": { - "type": "string" - } + "birth": { + "type": "integer" }, - "newName": { + "createTime": { + "type": "integer" + }, + "email": { "type": "string" }, - "operationID": { + "englishName": { "type": "string" }, - "reduceUserIDList": { - "type": "array", - "items": { - "type": "string" - } + "ex": { + "type": "string" }, - "tagID": { + "faceURL": { "type": "string" - } - } - }, - "base_info.SetTagResp": { - "type": "object", - "properties": { - "errCode": { + }, + "gender": { "type": "integer" }, - "errMsg": { + "mobile": { "type": "string" - } - } - }, - "base_info.TransferGroupOwnerReq": { - "type": "object", - "required": [ - "groupID", - "newOwnerUserID", - "oldOwnerUserID", - "operationID" - ], - "properties": { - "groupID": { + }, + "nickname": { "type": "string" }, - "newOwnerUserID": { + "operationID": { "type": "string" }, - "oldOwnerUserID": { + "telephone": { "type": "string" }, - "operationID": { + "userID": { "type": "string" } } }, - "base_info.TransferGroupOwnerResp": { + "base_info.UpdateOrganizationUserResp": { "type": "object", "properties": { "errCode": { @@ -5427,6 +7464,49 @@ } } }, + "base_info.UpdateUserInDepartmentReq": { + "type": "object", + "required": [ + "operationID" + ], + "properties": { + "departmentID": { + "type": "string" + }, + "ex": { + "type": "string" + }, + "leader": { + "type": "integer" + }, + "operationID": { + "type": "string" + }, + "order": { + "type": "integer" + }, + "position": { + "type": "string" + }, + "status": { + "type": "integer" + }, + "userID": { + "type": "string" + } + } + }, + "base_info.UpdateUserInDepartmentResp": { + "type": "object", + "properties": { + "errCode": { + "type": "integer" + }, + "errMsg": { + "type": "string" + } + } + }, "base_info.UpdateUserInfoResp": { "type": "object", "properties": { @@ -5609,33 +7689,220 @@ "$ref": "#/definitions/base_info.WorkMomentUser" } }, - "permission": { + "permission": { + "type": "integer" + }, + "permissionUsers": { + "type": "array", + "items": { + "$ref": "#/definitions/base_info.WorkMomentUser" + } + }, + "userID": { + "type": "string" + }, + "userName": { + "type": "string" + }, + "workMomentID": { + "type": "string" + } + } + }, + "base_info.WorkMomentUser": { + "type": "object", + "properties": { + "userID": { + "type": "string" + }, + "userName": { + "type": "string" + } + } + }, + "internal_api_manage.FileElem": { + "type": "object", + "properties": { + "fileName": { + "type": "string" + }, + "filePath": { + "type": "string" + }, + "fileSize": { + "type": "integer" + }, + "sourceURL": { + "type": "string" + }, + "uuid": { + "type": "string" + } + } + }, + "internal_api_manage.OANotificationElem": { + "type": "object", + "required": [ + "notificationFaceURL", + "notificationName", + "notificationType", + "text" + ], + "properties": { + "ex": { + "type": "string" + }, + "fileElem": { + "$ref": "#/definitions/internal_api_manage.FileElem" + }, + "mixType": { + "type": "integer" + }, + "notificationFaceURL": { + "type": "string" + }, + "notificationName": { + "type": "string" + }, + "notificationType": { + "type": "integer" + }, + "pictureElem": { + "$ref": "#/definitions/internal_api_manage.PictureElem" + }, + "soundElem": { + "$ref": "#/definitions/internal_api_manage.SoundElem" + }, + "text": { + "type": "string" + }, + "url": { + "type": "string" + }, + "videoElem": { + "$ref": "#/definitions/internal_api_manage.VideoElem" + } + } + }, + "internal_api_manage.PictureBaseInfo": { + "type": "object", + "properties": { + "height": { + "type": "integer" + }, + "size": { + "type": "integer" + }, + "type": { + "type": "string" + }, + "url": { + "type": "string" + }, + "uuid": { + "type": "string" + }, + "width": { + "type": "integer" + } + } + }, + "internal_api_manage.PictureElem": { + "type": "object", + "properties": { + "bigPicture": { + "$ref": "#/definitions/internal_api_manage.PictureBaseInfo" + }, + "snapshotPicture": { + "$ref": "#/definitions/internal_api_manage.PictureBaseInfo" + }, + "sourcePath": { + "type": "string" + }, + "sourcePicture": { + "$ref": "#/definitions/internal_api_manage.PictureBaseInfo" + } + } + }, + "internal_api_manage.RevokeElem": { + "type": "object", + "required": [ + "revokeMsgClientID" + ], + "properties": { + "revokeMsgClientID": { + "type": "string" + } + } + }, + "internal_api_manage.SoundElem": { + "type": "object", + "properties": { + "dataSize": { + "type": "integer" + }, + "duration": { + "type": "integer" + }, + "soundPath": { + "type": "string" + }, + "sourceURL": { + "type": "string" + }, + "uuid": { + "type": "string" + } + } + }, + "internal_api_manage.TextElem": { + "type": "object", + "required": [ + "text" + ], + "properties": { + "text": { + "type": "string" + } + } + }, + "internal_api_manage.VideoElem": { + "type": "object", + "properties": { + "duration": { + "type": "integer" + }, + "snapshotHeight": { + "type": "integer" + }, + "snapshotPath": { + "type": "string" + }, + "snapshotSize": { "type": "integer" }, - "permissionUsers": { - "type": "array", - "items": { - "$ref": "#/definitions/base_info.WorkMomentUser" - } + "snapshotURL": { + "type": "string" }, - "userID": { + "snapshotUUID": { "type": "string" }, - "userName": { + "snapshotWidth": { + "type": "integer" + }, + "videoPath": { "type": "string" }, - "workMomentID": { + "videoSize": { + "type": "integer" + }, + "videoType": { "type": "string" - } - } - }, - "base_info.WorkMomentUser": { - "type": "object", - "properties": { - "userID": { + }, + "videoURL": { "type": "string" }, - "userName": { + "videoUUID": { "type": "string" } } @@ -5820,6 +8087,143 @@ } } }, + "server_api_params.Department": { + "type": "object", + "properties": { + "createTime": { + "type": "integer" + }, + "departmentID": { + "type": "string" + }, + "departmentType": { + "type": "integer" + }, + "ex": { + "type": "string" + }, + "faceURL": { + "type": "string" + }, + "memberNum": { + "type": "integer" + }, + "name": { + "type": "string" + }, + "order": { + "type": "integer" + }, + "parentID": { + "type": "string" + }, + "subDepartmentNum": { + "type": "integer" + } + } + }, + "server_api_params.DepartmentMember": { + "type": "object", + "properties": { + "departmentID": { + "type": "string" + }, + "ex": { + "type": "string" + }, + "leader": { + "type": "integer" + }, + "order": { + "type": "integer" + }, + "position": { + "type": "string" + }, + "status": { + "type": "integer" + }, + "userID": { + "type": "string" + } + } + }, + "server_api_params.FriendInfo": { + "type": "object", + "properties": { + "addSource": { + "type": "integer" + }, + "createTime": { + "type": "integer" + }, + "ex": { + "type": "string" + }, + "friendUser": { + "$ref": "#/definitions/server_api_params.UserInfo" + }, + "operatorUserID": { + "type": "string" + }, + "ownerUserID": { + "type": "string" + }, + "remark": { + "type": "string" + } + } + }, + "server_api_params.FriendRequest": { + "type": "object", + "properties": { + "createTime": { + "type": "integer" + }, + "ex": { + "type": "string" + }, + "fromFaceURL": { + "type": "string" + }, + "fromGender": { + "type": "integer" + }, + "fromNickname": { + "type": "string" + }, + "fromUserID": { + "type": "string" + }, + "handleMsg": { + "type": "string" + }, + "handleResult": { + "type": "integer" + }, + "handleTime": { + "type": "integer" + }, + "handlerUserID": { + "type": "string" + }, + "reqMsg": { + "type": "string" + }, + "toFaceURL": { + "type": "string" + }, + "toGender": { + "type": "integer" + }, + "toNickname": { + "type": "string" + }, + "toUserID": { + "type": "string" + } + } + }, "server_api_params.GroupInfo": { "type": "object", "properties": { @@ -5851,7 +8255,7 @@ "type": "integer" }, "needVerification": { - "$ref": "#/definitions/wrapperspb.Int32Value" + "type": "integer" }, "notification": { "type": "string" @@ -5902,6 +8306,141 @@ } } }, + "server_api_params.GroupRequest": { + "type": "object", + "properties": { + "ex": { + "type": "string" + }, + "groupInfo": { + "$ref": "#/definitions/server_api_params.GroupInfo" + }, + "handleMsg": { + "type": "string" + }, + "handleResult": { + "type": "integer" + }, + "handleTime": { + "type": "integer" + }, + "handleUserID": { + "type": "string" + }, + "reqMsg": { + "type": "string" + }, + "reqTime": { + "type": "integer" + }, + "userInfo": { + "$ref": "#/definitions/server_api_params.PublicUserInfo" + } + } + }, + "server_api_params.OfflinePushInfo": { + "type": "object", + "properties": { + "desc": { + "type": "string" + }, + "ex": { + "type": "string" + }, + "iOSBadgeCount": { + "type": "boolean" + }, + "iOSPushSound": { + "type": "string" + }, + "title": { + "type": "string" + } + } + }, + "server_api_params.OrganizationUser": { + "type": "object", + "properties": { + "birth": { + "type": "integer" + }, + "createTime": { + "type": "integer" + }, + "email": { + "type": "string" + }, + "englishName": { + "type": "string" + }, + "ex": { + "type": "string" + }, + "faceURL": { + "type": "string" + }, + "gender": { + "type": "integer" + }, + "mobile": { + "type": "string" + }, + "nickname": { + "type": "string" + }, + "telephone": { + "type": "string" + }, + "userID": { + "type": "string" + } + } + }, + "server_api_params.PublicUserInfo": { + "type": "object", + "properties": { + "ex": { + "type": "string" + }, + "faceURL": { + "type": "string" + }, + "gender": { + "type": "integer" + }, + "nickname": { + "type": "string" + }, + "userID": { + "type": "string" + } + } + }, + "server_api_params.UserDepartmentMember": { + "type": "object", + "properties": { + "departmentMember": { + "$ref": "#/definitions/server_api_params.DepartmentMember" + }, + "organizationUser": { + "$ref": "#/definitions/server_api_params.OrganizationUser" + } + } + }, + "server_api_params.UserInDepartment": { + "type": "object", + "properties": { + "departmentMemberList": { + "type": "array", + "items": { + "$ref": "#/definitions/server_api_params.DepartmentMember" + } + }, + "organizationUser": { + "$ref": "#/definitions/server_api_params.OrganizationUser" + } + } + }, "server_api_params.UserInfo": { "type": "object", "properties": { @@ -5940,23 +8479,28 @@ } } }, - "user.AccountCheckResp_SingleUserStatus": { + "server_api_params.UserSendMsgResp": { "type": "object", "properties": { - "accountStatus": { + "clientMsgID": { "type": "string" }, - "userID": { + "sendTime": { + "type": "integer" + }, + "serverMsgID": { "type": "string" } } }, - "wrapperspb.Int32Value": { + "user.AccountCheckResp_SingleUserStatus": { "type": "object", "properties": { - "value": { - "description": "The int32 value.", - "type": "integer" + "accountStatus": { + "type": "string" + }, + "userID": { + "type": "string" } } } diff --git a/cmd/open_im_api/docs/swagger.yaml b/cmd/open_im_api/docs/swagger.yaml index 07440bc83..f030e5353 100644 --- a/cmd/open_im_api/docs/swagger.yaml +++ b/cmd/open_im_api/docs/swagger.yaml @@ -1,4 +1,128 @@ +basePath: / definitions: + Open_IM_internal_api_manage.FileElem: + properties: + fileName: + type: string + filePath: + type: string + fileSize: + type: integer + sourceURL: + type: string + uuid: + type: string + type: object + Open_IM_internal_api_manage.OANotificationElem: + properties: + ex: + type: string + fileElem: + $ref: '#/definitions/Open_IM_internal_api_manage.FileElem' + mixType: + type: integer + notificationFaceURL: + type: string + notificationName: + type: string + notificationType: + type: integer + pictureElem: + $ref: '#/definitions/Open_IM_internal_api_manage.PictureElem' + soundElem: + $ref: '#/definitions/Open_IM_internal_api_manage.SoundElem' + text: + type: string + url: + type: string + videoElem: + $ref: '#/definitions/Open_IM_internal_api_manage.VideoElem' + required: + - notificationFaceURL + - notificationName + - notificationType + - text + type: object + Open_IM_internal_api_manage.PictureBaseInfo: + properties: + height: + type: integer + size: + type: integer + type: + type: string + url: + type: string + uuid: + type: string + width: + type: integer + type: object + Open_IM_internal_api_manage.PictureElem: + properties: + bigPicture: + $ref: '#/definitions/Open_IM_internal_api_manage.PictureBaseInfo' + snapshotPicture: + $ref: '#/definitions/Open_IM_internal_api_manage.PictureBaseInfo' + sourcePath: + type: string + sourcePicture: + $ref: '#/definitions/Open_IM_internal_api_manage.PictureBaseInfo' + type: object + Open_IM_internal_api_manage.RevokeElem: + properties: + revokeMsgClientID: + type: string + required: + - revokeMsgClientID + type: object + Open_IM_internal_api_manage.SoundElem: + properties: + dataSize: + type: integer + duration: + type: integer + soundPath: + type: string + sourceURL: + type: string + uuid: + type: string + type: object + Open_IM_internal_api_manage.TextElem: + properties: + text: + type: string + required: + - text + type: object + Open_IM_internal_api_manage.VideoElem: + properties: + duration: + type: integer + snapshotHeight: + type: integer + snapshotPath: + type: string + snapshotSize: + type: integer + snapshotURL: + type: string + snapshotUUID: + type: string + snapshotWidth: + type: integer + videoPath: + type: string + videoSize: + type: integer + videoType: + type: string + videoURL: + type: string + videoUUID: + type: string + type: object base_info.AccountCheckReq: properties: checkUserIDList: @@ -218,6 +342,110 @@ definitions: errMsg: type: string type: object + base_info.Conversation: + properties: + attachedInfo: + type: string + conversationID: + type: string + conversationType: + type: integer + draftTextTime: + type: integer + ex: + type: string + groupAtType: + type: integer + groupID: + type: string + isNotInGroup: + type: boolean + isPinned: + type: boolean + isPrivateChat: + type: boolean + ownerUserID: + type: string + recvMsgOpt: + enum: + - 0 + - 1 + - 2 + type: integer + unreadCount: + type: integer + userID: + type: string + required: + - conversationID + - conversationType + - ownerUserID + type: object + base_info.CreateDepartmentMemberReq: + properties: + departmentID: + type: string + ex: + type: string + leader: + type: integer + operationID: + type: string + order: + type: integer + position: + type: string + status: + type: integer + userID: + type: string + required: + - operationID + type: object + base_info.CreateDepartmentMemberResp: + properties: + errCode: + type: integer + errMsg: + type: string + type: object + base_info.CreateDepartmentReq: + properties: + createTime: + type: integer + departmentID: + type: string + departmentType: + type: integer + ex: + type: string + faceURL: + type: string + memberNum: + type: integer + name: + type: string + operationID: + type: string + order: + type: integer + parentID: + type: string + subDepartmentNum: + type: integer + required: + - operationID + type: object + base_info.CreateDepartmentResp: + properties: + data: + additionalProperties: true + type: object + errCode: + type: integer + errMsg: + type: string + type: object base_info.CreateGroupReq: properties: ex: @@ -268,6 +496,42 @@ definitions: errMsg: type: string type: object + base_info.CreateOrganizationUserReq: + properties: + birth: + type: integer + createTime: + type: integer + email: + type: string + englishName: + type: string + ex: + type: string + faceURL: + type: string + gender: + type: integer + mobile: + type: string + nickname: + type: string + operationID: + type: string + telephone: + type: string + userID: + type: string + required: + - operationID + type: object + base_info.CreateOrganizationUserResp: + properties: + errCode: + type: integer + errMsg: + type: string + type: object base_info.CreateTagReq: properties: operationID: @@ -336,6 +600,23 @@ definitions: errMsg: type: string type: object + base_info.DeleteDepartmentReq: + properties: + departmentID: + type: string + operationID: + type: string + required: + - departmentID + - operationID + type: object + base_info.DeleteDepartmentResp: + properties: + errCode: + type: integer + errMsg: + type: string + type: object base_info.DeleteFriendReq: properties: fromUserID: @@ -375,6 +656,23 @@ definitions: errMsg: type: string type: object + base_info.DeleteOrganizationUserReq: + properties: + operationID: + type: string + userID: + type: string + required: + - operationID + - userID + type: object + base_info.DeleteOrganizationUserResp: + properties: + errCode: + type: integer + errMsg: + type: string + type: object base_info.DeleteTagReq: properties: operationID: @@ -392,6 +690,26 @@ definitions: errMsg: type: string type: object + base_info.DeleteUserInDepartmentReq: + properties: + departmentID: + type: string + operationID: + type: string + userID: + type: string + required: + - departmentID + - operationID + - userID + type: object + base_info.DeleteUserInDepartmentResp: + properties: + errCode: + type: integer + errMsg: + type: string + type: object base_info.DismissGroupReq: properties: groupID: @@ -409,6 +727,11 @@ definitions: errMsg: type: string type: object + base_info.ExpireTime: + properties: + expireTimeSeconds: + type: integer + type: object base_info.ForceLogoutReq: properties: fromUserID: @@ -433,47 +756,46 @@ definitions: errMsg: type: string type: object - base_info.GetAllUsersUidReq: + base_info.GetAllConversationsReq: properties: operationID: type: string + ownerUserID: + type: string required: - operationID + - ownerUserID type: object - base_info.GetAllUsersUidResp: + base_info.GetAllConversationsResp: properties: data: items: - type: string + $ref: '#/definitions/base_info.Conversation' type: array errCode: type: integer errMsg: type: string type: object - base_info.GetBlackListReq: + base_info.GetAllUsersUidReq: properties: - fromUserID: - type: string operationID: type: string required: - - fromUserID - operationID type: object - base_info.GetBlackListResp: + base_info.GetAllUsersUidResp: properties: data: items: - additionalProperties: true - type: object + type: string type: array errCode: type: integer errMsg: type: string type: object - base_info.GetFriendApplyListReq: + base_info.GetBlackListReq: properties: fromUserID: type: string @@ -483,51 +805,72 @@ definitions: - fromUserID - operationID type: object - base_info.GetFriendApplyListResp: + base_info.GetBlackListResp: properties: - data: - items: - additionalProperties: true - type: object - type: array errCode: type: integer errMsg: type: string type: object - base_info.GetFriendListReq: + base_info.GetConversationReq: properties: - fromUserID: + conversationID: type: string operationID: type: string + ownerUserID: + type: string required: - - fromUserID + - conversationID - operationID + - ownerUserID type: object - base_info.GetFriendListResp: + base_info.GetConversationResp: properties: data: - items: - additionalProperties: true - type: object - type: array + $ref: '#/definitions/base_info.Conversation' errCode: type: integer errMsg: type: string type: object - base_info.GetGroupAllMemberReq: + base_info.GetConversationsReq: properties: - groupID: - type: string + conversationIDs: + items: + type: string + type: array operationID: type: string + ownerUserID: + type: string required: - - groupID + - conversationIDs - operationID + - ownerUserID type: object - base_info.GetGroupAllMemberResp: + base_info.GetConversationsResp: + properties: + data: + items: + $ref: '#/definitions/base_info.Conversation' + type: array + errCode: + type: integer + errMsg: + type: string + type: object + base_info.GetDepartmentMemberReq: + properties: + departmentID: + type: string + operationID: + type: string + required: + - departmentID + - operationID + type: object + base_info.GetDepartmentMemberResp: properties: data: items: @@ -539,6 +882,57 @@ definitions: errMsg: type: string type: object + base_info.GetFriendApplyListReq: + properties: + fromUserID: + type: string + operationID: + type: string + required: + - fromUserID + - operationID + type: object + base_info.GetFriendApplyListResp: + properties: + errCode: + type: integer + errMsg: + type: string + type: object + base_info.GetFriendListReq: + properties: + fromUserID: + type: string + operationID: + type: string + required: + - fromUserID + - operationID + type: object + base_info.GetFriendListResp: + properties: + errCode: + type: integer + errMsg: + type: string + type: object + base_info.GetGroupAllMemberReq: + properties: + groupID: + type: string + operationID: + type: string + required: + - groupID + - operationID + type: object + base_info.GetGroupAllMemberResp: + properties: + errCode: + type: integer + errMsg: + type: string + type: object base_info.GetGroupApplicationListReq: properties: fromUserID: @@ -552,11 +946,6 @@ definitions: type: object base_info.GetGroupApplicationListResp: properties: - data: - items: - additionalProperties: true - type: object - type: array errCode: type: integer errMsg: @@ -576,11 +965,6 @@ definitions: type: object base_info.GetGroupInfoResp: properties: - data: - items: - additionalProperties: true - type: object - type: array errCode: type: integer errMsg: @@ -603,11 +987,6 @@ definitions: type: object base_info.GetGroupMembersInfoResp: properties: - data: - items: - additionalProperties: true - type: object - type: array errCode: type: integer errMsg: @@ -625,11 +1004,6 @@ definitions: type: object base_info.GetJoinedGroupListResp: properties: - data: - items: - additionalProperties: true - type: object - type: array errCode: type: integer errMsg: @@ -647,11 +1021,6 @@ definitions: type: object base_info.GetSelfApplyListResp: properties: - data: - items: - additionalProperties: true - type: object - type: array errCode: type: integer errMsg: @@ -674,6 +1043,28 @@ definitions: errMsg: type: string type: object + base_info.GetSubDepartmentReq: + properties: + departmentID: + type: string + operationID: + type: string + required: + - departmentID + - operationID + type: object + base_info.GetSubDepartmentResp: + properties: + data: + items: + additionalProperties: true + type: object + type: array + errCode: + type: integer + errMsg: + type: string + type: object base_info.GetTagSendLogsReq: properties: operationID: @@ -736,6 +1127,26 @@ definitions: errMsg: type: string type: object + base_info.GetUserInDepartmentReq: + properties: + operationID: + type: string + userID: + type: string + required: + - operationID + - userID + type: object + base_info.GetUserInDepartmentResp: + properties: + data: + additionalProperties: true + type: object + errCode: + type: integer + errMsg: + type: string + type: object base_info.GetUserReqGroupApplicationListReq: properties: operationID: @@ -1039,15 +1450,93 @@ definitions: errMsg: type: string type: object - base_info.MinioUploadFileResp: + base_info.ManagementBatchSendMsgReq: properties: - URL: + contentType: + type: integer + groupID: type: string - newName: + isOnlineOnly: + type: boolean + offlinePushInfo: + $ref: '#/definitions/server_api_params.OfflinePushInfo' + operationID: + type: string + recvIDList: + items: + type: string + type: array + sendID: type: string - snapshotName: + senderFaceURL: type: string - snapshotURL: + senderNickname: + type: string + senderPlatformID: + type: integer + sessionType: + type: integer + required: + - contentType + - operationID + - sendID + - sessionType + type: object + base_info.ManagementSendMsgReq: + properties: + contentType: + type: integer + groupID: + type: string + isOnlineOnly: + type: boolean + offlinePushInfo: + $ref: '#/definitions/server_api_params.OfflinePushInfo' + operationID: + type: string + recvID: + type: string + sendID: + type: string + senderFaceURL: + type: string + senderNickname: + type: string + senderPlatformID: + type: integer + sessionType: + type: integer + required: + - contentType + - operationID + - sendID + - sessionType + type: object + base_info.ManagementSendMsgResp: + properties: + data: + $ref: '#/definitions/server_api_params.UserSendMsgResp' + errCode: + type: integer + errMsg: + type: string + type: object + base_info.MinioUploadFileResp: + properties: + data: + properties: + URL: + type: string + newName: + type: string + snapshotName: + type: string + snapshotURL: + type: string + type: object + errCode: + type: integer + errMsg: type: string type: object base_info.MuteGroupMemberReq: @@ -1092,9 +1581,6 @@ definitions: type: object base_info.ParseTokenResp: properties: - data: - additionalProperties: true - type: object errCode: type: integer errMsg: @@ -1303,6 +1789,24 @@ definitions: errMsg: type: string type: object + base_info.Swagger400Resp: + properties: + errCode: + example: 400 + type: integer + errMsg: + example: err msg + type: string + type: object + base_info.Swagger500Resp: + properties: + errCode: + example: 500 + type: integer + errMsg: + example: err msg + type: string + type: object base_info.TransferGroupOwnerReq: properties: groupID: @@ -1326,57 +1830,78 @@ definitions: errMsg: type: string type: object - base_info.UpdateSelfUserInfoReq: + base_info.UpdateDepartmentReq: + properties: + createTime: + type: integer + departmentID: + type: string + departmentType: + type: integer + ex: + type: string + faceURL: + type: string + memberNum: + type: integer + name: + type: string + operationID: + type: string + order: + type: integer + parentID: + type: string + subDepartmentNum: + type: integer + required: + - departmentID + - operationID + type: object + base_info.UpdateDepartmentResp: + properties: + errCode: + type: integer + errMsg: + type: string + type: object + base_info.UpdateOrganizationUserReq: properties: birth: type: integer + createTime: + type: integer email: - maxLength: 64 + type: string + englishName: type: string ex: - maxLength: 1024 type: string faceURL: - maxLength: 1024 type: string gender: - enum: - - 0 - - 1 - - 2 type: integer + mobile: + type: string nickname: - maxLength: 64 - minLength: 1 type: string operationID: type: string - phoneNumber: - maxLength: 32 + telephone: type: string userID: - maxLength: 64 - minLength: 1 type: string required: - operationID - - userID type: object - base_info.UpdateUserInfoResp: + base_info.UpdateOrganizationUserResp: properties: errCode: type: integer errMsg: type: string type: object - base_info.UserIDResult: - properties: - result: - type: integer - userID: - type: string - type: object - base_info.UserRegisterReq: + base_info.UpdateSelfUserInfoReq: properties: birth: type: integer @@ -1404,21 +1929,99 @@ definitions: phoneNumber: maxLength: 32 type: string - platform: - maximum: 7 - minimum: 1 - type: integer - secret: - maxLength: 32 - type: string userID: maxLength: 64 minLength: 1 type: string required: - operationID - - platform - - secret + - userID + type: object + base_info.UpdateUserInDepartmentReq: + properties: + departmentID: + type: string + ex: + type: string + leader: + type: integer + operationID: + type: string + order: + type: integer + position: + type: string + status: + type: integer + userID: + type: string + required: + - operationID + type: object + base_info.UpdateUserInDepartmentResp: + properties: + errCode: + type: integer + errMsg: + type: string + type: object + base_info.UpdateUserInfoResp: + properties: + errCode: + type: integer + errMsg: + type: string + type: object + base_info.UserIDResult: + properties: + result: + type: integer + userID: + type: string + type: object + base_info.UserRegisterReq: + properties: + birth: + type: integer + email: + maxLength: 64 + type: string + ex: + maxLength: 1024 + type: string + faceURL: + maxLength: 1024 + type: string + gender: + enum: + - 0 + - 1 + - 2 + type: integer + nickname: + maxLength: 64 + minLength: 1 + type: string + operationID: + type: string + phoneNumber: + maxLength: 32 + type: string + platform: + maximum: 7 + minimum: 1 + type: integer + secret: + maxLength: 32 + type: string + userID: + maxLength: 64 + minLength: 1 + type: string + required: + - operationID + - platform + - secret - userID type: object base_info.UserRegisterResp: @@ -1509,6 +2112,129 @@ definitions: userName: type: string type: object + internal_api_manage.FileElem: + properties: + fileName: + type: string + filePath: + type: string + fileSize: + type: integer + sourceURL: + type: string + uuid: + type: string + type: object + internal_api_manage.OANotificationElem: + properties: + ex: + type: string + fileElem: + $ref: '#/definitions/internal_api_manage.FileElem' + mixType: + type: integer + notificationFaceURL: + type: string + notificationName: + type: string + notificationType: + type: integer + pictureElem: + $ref: '#/definitions/internal_api_manage.PictureElem' + soundElem: + $ref: '#/definitions/internal_api_manage.SoundElem' + text: + type: string + url: + type: string + videoElem: + $ref: '#/definitions/internal_api_manage.VideoElem' + required: + - notificationFaceURL + - notificationName + - notificationType + - text + type: object + internal_api_manage.PictureBaseInfo: + properties: + height: + type: integer + size: + type: integer + type: + type: string + url: + type: string + uuid: + type: string + width: + type: integer + type: object + internal_api_manage.PictureElem: + properties: + bigPicture: + $ref: '#/definitions/internal_api_manage.PictureBaseInfo' + snapshotPicture: + $ref: '#/definitions/internal_api_manage.PictureBaseInfo' + sourcePath: + type: string + sourcePicture: + $ref: '#/definitions/internal_api_manage.PictureBaseInfo' + type: object + internal_api_manage.RevokeElem: + properties: + revokeMsgClientID: + type: string + required: + - revokeMsgClientID + type: object + internal_api_manage.SoundElem: + properties: + dataSize: + type: integer + duration: + type: integer + soundPath: + type: string + sourceURL: + type: string + uuid: + type: string + type: object + internal_api_manage.TextElem: + properties: + text: + type: string + required: + - text + type: object + internal_api_manage.VideoElem: + properties: + duration: + type: integer + snapshotHeight: + type: integer + snapshotPath: + type: string + snapshotSize: + type: integer + snapshotURL: + type: string + snapshotUUID: + type: string + snapshotWidth: + type: integer + videoPath: + type: string + videoSize: + type: integer + videoType: + type: string + videoURL: + type: string + videoUUID: + type: string + type: object office.Comment: properties: content: @@ -1626,6 +2352,96 @@ definitions: userID: type: string type: object + server_api_params.Department: + properties: + createTime: + type: integer + departmentID: + type: string + departmentType: + type: integer + ex: + type: string + faceURL: + type: string + memberNum: + type: integer + name: + type: string + order: + type: integer + parentID: + type: string + subDepartmentNum: + type: integer + type: object + server_api_params.DepartmentMember: + properties: + departmentID: + type: string + ex: + type: string + leader: + type: integer + order: + type: integer + position: + type: string + status: + type: integer + userID: + type: string + type: object + server_api_params.FriendInfo: + properties: + addSource: + type: integer + createTime: + type: integer + ex: + type: string + friendUser: + $ref: '#/definitions/server_api_params.UserInfo' + operatorUserID: + type: string + ownerUserID: + type: string + remark: + type: string + type: object + server_api_params.FriendRequest: + properties: + createTime: + type: integer + ex: + type: string + fromFaceURL: + type: string + fromGender: + type: integer + fromNickname: + type: string + fromUserID: + type: string + handleMsg: + type: string + handleResult: + type: integer + handleTime: + type: integer + handlerUserID: + type: string + reqMsg: + type: string + toFaceURL: + type: string + toGender: + type: integer + toNickname: + type: string + toUserID: + type: string + type: object server_api_params.GroupInfo: properties: createTime: @@ -1647,7 +2463,7 @@ definitions: memberCount: type: integer needVerification: - $ref: '#/definitions/wrapperspb.Int32Value' + type: integer notification: type: string ownerUserID: @@ -1680,60 +2496,157 @@ definitions: userID: type: string type: object - server_api_params.UserInfo: + server_api_params.GroupRequest: properties: - appMangerLevel: + ex: + type: string + groupInfo: + $ref: '#/definitions/server_api_params.GroupInfo' + handleMsg: + type: string + handleResult: + type: integer + handleTime: + type: integer + handleUserID: + type: string + reqMsg: + type: string + reqTime: type: integer + userInfo: + $ref: '#/definitions/server_api_params.PublicUserInfo' + type: object + server_api_params.OfflinePushInfo: + properties: + desc: + type: string + ex: + type: string + iOSBadgeCount: + type: boolean + iOSPushSound: + type: string + title: + type: string + type: object + server_api_params.OrganizationUser: + properties: birth: type: integer createTime: type: integer email: type: string + englishName: + type: string ex: type: string faceURL: type: string gender: type: integer - globalRecvMsgOpt: - type: integer + mobile: + type: string nickname: type: string - phoneNumber: + telephone: type: string userID: type: string type: object - user.AccountCheckResp_SingleUserStatus: + server_api_params.PublicUserInfo: properties: - accountStatus: + ex: + type: string + faceURL: + type: string + gender: + type: integer + nickname: type: string userID: type: string type: object - wrapperspb.Int32Value: + server_api_params.UserDepartmentMember: properties: - value: - description: The int32 value. - type: integer + departmentMember: + $ref: '#/definitions/server_api_params.DepartmentMember' + organizationUser: + $ref: '#/definitions/server_api_params.OrganizationUser' type: object -info: - contact: {} -paths: - /auth/force_logout: - post: - consumes: - - application/json - description: 对应的平台强制登出 - operationId: ForceLogout - parameters: - - description: im token - in: header - name: token - required: true + server_api_params.UserInDepartment: + properties: + departmentMemberList: + items: + $ref: '#/definitions/server_api_params.DepartmentMember' + type: array + organizationUser: + $ref: '#/definitions/server_api_params.OrganizationUser' + type: object + server_api_params.UserInfo: + properties: + appMangerLevel: + type: integer + birth: + type: integer + createTime: + type: integer + email: + type: string + ex: + type: string + faceURL: + type: string + gender: + type: integer + globalRecvMsgOpt: + type: integer + nickname: + type: string + phoneNumber: + type: string + userID: + type: string + type: object + server_api_params.UserSendMsgResp: + properties: + clientMsgID: + type: string + sendTime: + type: integer + serverMsgID: + type: string + type: object + user.AccountCheckResp_SingleUserStatus: + properties: + accountStatus: + type: string + userID: + type: string + type: object +info: + contact: {} + description: open-IM-Server 的API服务器文档, 文档中所有请求都有一个operationID字段用于链路追踪 + license: + name: Apache 2.0 + url: http://www.apache.org/licenses/LICENSE-2.0.html + title: open-IM-Server API + version: "1.0" +paths: + /auth/force_logout: + post: + consumes: + - application/json + description: 对应的平台强制登出 + operationId: ForceLogout + parameters: + - description: im token + in: header + name: token + required: true type: string - - description: platform为平台ID, fromUserID为要执行强制登出的用户ID + - description: platform为平台ID
fromUserID为要执行强制登出的用户ID in: body name: req required: true @@ -1749,11 +2662,11 @@ paths: "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.ForceLogoutResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.ForceLogoutResp' + $ref: '#/definitions/base_info.Swagger500Resp' summary: 强制登出 tags: - 鉴权认证 @@ -1761,7 +2674,7 @@ paths: post: consumes: - application/json - description: 解析用户token + description: 解析当前用户token(token在请求头中传入) operationId: ParseToken parameters: - description: im token @@ -1769,7 +2682,7 @@ paths: name: token required: true type: string - - description: secret为openIM密钥, 详细见服务端config.yaml secret字段, platform为平台ID + - description: secret为openIM密钥, 详细见服务端config.yaml secret字段
platform为平台ID in: body name: req required: true @@ -1781,23 +2694,28 @@ paths: "0": description: "" schema: - $ref: '#/definitions/base_info.ParseTokenResp' + allOf: + - $ref: '#/definitions/base_info.ParseTokenResp' + - properties: + Data: + $ref: '#/definitions/base_info.ExpireTime' + type: object "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.ParseTokenResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.ParseTokenResp' - summary: 解析token + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 解析当前用户token tags: - 鉴权认证 /auth/user_register: post: consumes: - application/json - description: 用户登录 + description: 用户注册 operationId: UserRegister parameters: - description: im token @@ -1806,7 +2724,7 @@ paths: required: true type: string - description: secret为openIM密钥, 详细见服务端config.yaml secret字段
platform为平台ID -
ex为拓展字段 +
ex为拓展字段
gender为性别, 0为女, 1为男 in: body name: req required: true @@ -1822,12 +2740,12 @@ paths: "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.UserRegisterResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.UserRegisterResp' - summary: 用户登录 + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 用户注册 tags: - 鉴权认证 /auth/user_token: @@ -1842,7 +2760,7 @@ paths: name: token required: true type: string - - description: secret为openIM密钥, 详细见服务端config.yaml secret字段, platform为平台ID + - description: secret为openIM密钥, 详细见服务端config.yaml secret字段
platform为平台ID in: body name: req required: true @@ -1858,11 +2776,11 @@ paths: "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.UserTokenResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.UserTokenResp' + $ref: '#/definitions/base_info.Swagger500Resp' summary: 用户登录 tags: - 鉴权认证 @@ -1878,7 +2796,7 @@ paths: name: token required: true type: string - - description: fromUserID为设置的用户, toUserID为被设置的用户 + - description: fromUserID为设置的用户
toUserID为被设置的用户 in: body name: req required: true @@ -1894,11 +2812,11 @@ paths: "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.AddBlacklistResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.AddBlacklistResp' + $ref: '#/definitions/base_info.Swagger500Resp' summary: 添加黑名单 tags: - 好友相关 @@ -1914,7 +2832,7 @@ paths: name: token required: true type: string - - description: reqMsg为申请信息, fromUserID为申请用户, toUserID为被添加用户 + - description: reqMsg为申请信息
fromUserID为申请用户
toUserID为被添加用户 in: body name: req required: true @@ -1930,11 +2848,11 @@ paths: "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.AddFriendResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.AddFriendResp' + $ref: '#/definitions/base_info.Swagger500Resp' summary: 添加好友 tags: - 好友相关 @@ -1942,1190 +2860,1890 @@ paths: post: consumes: - application/json - description: 同意/拒绝好友请求 - operationId: AddFriendResponse + description: 同意/拒绝好友请求 + operationId: AddFriendResponse + parameters: + - description: im token + in: header + name: token + required: true + type: string + - description: fromUserID同意/拒绝的用户ID
toUserID为申请用户D
handleMsg为处理信息
flag为具体操作, + 1为同意, 2为拒绝 + in: body + name: req + required: true + schema: + $ref: '#/definitions/base_info.AddFriendResponseReq' + produces: + - application/json + responses: + "0": + description: "" + schema: + $ref: '#/definitions/base_info.AddFriendResponseResp' + "400": + description: errCode为400 一般为参数输入错误, token未带上等 + schema: + $ref: '#/definitions/base_info.Swagger400Resp' + "500": + description: errCode为500 一般为服务器内部错误 + schema: + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 同意/拒绝好友请求 + tags: + - 好友相关 + /friend/delete_friend: + post: + consumes: + - application/json + description: 删除好友 + operationId: DeleteFriend + parameters: + - description: im token + in: header + name: token + required: true + type: string + - description: fromUserID为操作用户
toUserID为被删除用户 + in: body + name: req + required: true + schema: + $ref: '#/definitions/base_info.DeleteFriendReq' + produces: + - application/json + responses: + "0": + description: "" + schema: + $ref: '#/definitions/base_info.DeleteFriendResp' + "400": + description: errCode为400 一般为参数输入错误, token未带上等 + schema: + $ref: '#/definitions/base_info.Swagger400Resp' + "500": + description: errCode为500 一般为服务器内部错误 + schema: + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 删除好友 + tags: + - 好友相关 + /friend/get_black_list: + post: + consumes: + - application/json + description: 获取黑名单列表 + operationId: GetBlacklist + parameters: + - description: im token + in: header + name: token + required: true + type: string + - description: fromUserID要获取黑名单的用户 + in: body + name: req + required: true + schema: + $ref: '#/definitions/base_info.GetBlackListReq' + produces: + - application/json + responses: + "0": + description: "" + schema: + allOf: + - $ref: '#/definitions/base_info.GetBlackListResp' + - properties: + data: + items: + $ref: '#/definitions/server_api_params.PublicUserInfo' + type: array + type: object + "400": + description: errCode为400 一般为参数输入错误, token未带上等 + schema: + $ref: '#/definitions/base_info.Swagger500Resp' + "500": + description: errCode为500 一般为服务器内部错误 + schema: + $ref: '#/definitions/base_info.Swagger400Resp' + summary: 获取黑名单列表 + tags: + - 好友相关 + /friend/get_friend_apply_list: + post: + consumes: + - application/json + description: 删除好友 + operationId: GetFriendApplyList + parameters: + - description: im token + in: header + name: token + required: true + type: string + - description: fromUserID为要获取申请列表的用户ID + in: body + name: req + required: true + schema: + $ref: '#/definitions/base_info.GetFriendApplyListReq' + produces: + - application/json + responses: + "0": + description: "" + schema: + allOf: + - $ref: '#/definitions/base_info.GetFriendApplyListResp' + - properties: + data: + items: + $ref: '#/definitions/server_api_params.FriendRequest' + type: array + type: object + "400": + description: errCode为400 一般为参数输入错误, token未带上等 + schema: + $ref: '#/definitions/base_info.Swagger400Resp' + "500": + description: errCode为500 一般为服务器内部错误 + schema: + $ref: '#/definitions/base_info.Swagger400Resp' + summary: 获取好友申请列表 + tags: + - 好友相关 + /friend/get_friend_list: + post: + consumes: + - application/json + description: 获取用户的好友列表 + operationId: GetFriendList + parameters: + - description: im token + in: header + name: token + required: true + type: string + - description: fromUserID为要获取好友列表的用户ID + in: body + name: req + required: true + schema: + $ref: '#/definitions/base_info.GetFriendListReq' + produces: + - application/json + responses: + "0": + description: "" + schema: + allOf: + - $ref: '#/definitions/base_info.GetFriendListResp' + - properties: + data: + items: + $ref: '#/definitions/server_api_params.FriendInfo' + type: array + type: object + "400": + description: errCode为400 一般为参数输入错误, token未带上等 + schema: + $ref: '#/definitions/base_info.Swagger400Resp' + "500": + description: errCode为500 一般为服务器内部错误 + schema: + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 获取用户的好友列表 + tags: + - 好友相关 + /friend/get_self_friend_apply_list: + post: + consumes: + - application/json + description: 获取自己的好友申请列表 + operationId: GetSelfFriendApplyList + parameters: + - description: im token + in: header + name: token + required: true + type: string + - description: fromUserID为自己的用户ID + in: body + name: req + required: true + schema: + $ref: '#/definitions/base_info.GetSelfApplyListReq' + produces: + - application/json + responses: + "0": + description: "" + schema: + allOf: + - $ref: '#/definitions/base_info.GetSelfApplyListResp' + - properties: + data: + items: + $ref: '#/definitions/server_api_params.FriendRequest' + type: array + type: object + "400": + description: errCode为400 一般为参数输入错误, token未带上等 + schema: + $ref: '#/definitions/base_info.Swagger400Resp' + "500": + description: errCode为500 一般为服务器内部错误 + schema: + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 获取自己的好友申请列表 + tags: + - 好友相关 + /friend/import_friend: + post: + consumes: + - application/json + description: 批量加好友 + operationId: ImportFriend + parameters: + - description: im token + in: header + name: token + required: true + type: string + - description: fromUserID批量加好友的用户ID
friendUserIDList为 + in: body + name: req + required: true + schema: + $ref: '#/definitions/base_info.ImportFriendReq' + produces: + - application/json + responses: + "0": + description: data列表中对象的result-1为添加该用户失败
0为成功 + schema: + $ref: '#/definitions/base_info.ImportFriendResp' + "400": + description: errCode为400 一般为参数输入错误, token未带上等 + schema: + $ref: '#/definitions/base_info.Swagger400Resp' + "500": + description: errCode为500 一般为服务器内部错误 + schema: + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 批量加好友 + tags: + - 好友相关 + /friend/is_friend: + post: + consumes: + - application/json + description: 检查用户之间是否为好友 + operationId: IsFriend + parameters: + - description: im token + in: header + name: token + required: true + type: string + - description: fromUserID为请求用户
toUserID为要检查的用户 + in: body + name: req + required: true + schema: + $ref: '#/definitions/base_info.IsFriendReq' + produces: + - application/json + responses: + "0": + description: "" + schema: + $ref: '#/definitions/base_info.IsFriendResp' + "400": + description: errCode为400 一般为参数输入错误, token未带上等 + schema: + $ref: '#/definitions/base_info.Swagger400Resp' + "500": + description: errCode为500 一般为服务器内部错误 + schema: + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 检查用户之间是否为好友 + tags: + - 好友相关 + /friend/remove_black: + post: + consumes: + - application/json + description: 把用户移除黑名单 + operationId: RemoveBlack + parameters: + - description: im token + in: header + name: token + required: true + type: string + - description: fromUserID要获取黑名单的用户 + in: body + name: req + required: true + schema: + $ref: '#/definitions/base_info.RemoveBlackListReq' + produces: + - application/json + responses: + "0": + description: "" + schema: + $ref: '#/definitions/base_info.RemoveBlackListResp' + "400": + description: errCode为400 一般为参数输入错误, token未带上等 + schema: + $ref: '#/definitions/base_info.Swagger400Resp' + "500": + description: errCode为500 一般为服务器内部错误 + schema: + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 把用户移除黑名单 + tags: + - 好友相关 + /friend/set_friend_remark: + post: + consumes: + - application/json + description: 设置好友备注 + operationId: SetFriendRemark + parameters: + - description: im token + in: header + name: token + required: true + type: string + - description: fromUserID为设置的用户
toUserID为被设置的用户
remark为好友备注 + in: body + name: req + required: true + schema: + $ref: '#/definitions/base_info.SetFriendRemarkReq' + produces: + - application/json + responses: + "0": + description: "" + schema: + $ref: '#/definitions/base_info.SetFriendRemarkResp' + "400": + description: errCode为400 一般为参数输入错误, token未带上等 + schema: + $ref: '#/definitions/base_info.Swagger400Resp' + "500": + description: errCode为500 一般为服务器内部错误 + schema: + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 设置好友备注 + tags: + - 好友相关 + /group/cancel_mute_group: + post: + consumes: + - application/json + description: 取消禁言群组 + operationId: CancelMuteGroup + parameters: + - description: im token + in: header + name: token + required: true + type: string + - description: groupID为群组ID + in: body + name: req + required: true + schema: + $ref: '#/definitions/base_info.CancelMuteGroupReq' + produces: + - application/json + responses: + "0": + description: "" + schema: + $ref: '#/definitions/base_info.CancelMuteGroupResp' + "400": + description: errCode为400 一般为参数输入错误, token未带上等 + schema: + $ref: '#/definitions/base_info.Swagger400Resp' + "500": + description: errCode为500 一般为服务器内部错误 + schema: + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 取消禁言群组 + tags: + - 群组相关 + /group/cancel_mute_group_member: + post: + consumes: + - application/json + description: 取消禁言群成员 + operationId: CancelMuteGroupMember + parameters: + - description: im token + in: header + name: token + required: true + type: string + - description: groupID为群组ID
userID为要取消禁言的用户ID + in: body + name: req + required: true + schema: + $ref: '#/definitions/base_info.CancelMuteGroupMemberReq' + produces: + - application/json + responses: + "0": + description: "" + schema: + $ref: '#/definitions/base_info.CancelMuteGroupMemberResp' + "400": + description: errCode为400 一般为参数输入错误, token未带上等 + schema: + $ref: '#/definitions/base_info.Swagger400Resp' + "500": + description: errCode为500 一般为服务器内部错误 + schema: + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 取消禁言群成员 + tags: + - 群组相关 + /group/create_group: + post: + consumes: + - application/json + description: 创建群组 + operationId: CreateGroup + parameters: + - description: im token + in: header + name: token + required: true + type: string + - description: groupType这里填0代表普通群
groupName为群名称
introduction为群介绍
+ notification为群公共
ownerUserID为群主ID
ex为群扩展字段
memberList中对象roleLevel为群员角色,1为普通用户 + 2为群主 3为管理员 + in: body + name: req + required: true + schema: + $ref: '#/definitions/base_info.CreateGroupReq' + produces: + - application/json + responses: + "0": + description: "" + schema: + allOf: + - $ref: '#/definitions/base_info.CreateGroupResp' + - properties: + data: + $ref: '#/definitions/server_api_params.GroupInfo' + type: object + "400": + description: errCode为400 一般为参数输入错误, token未带上等 + schema: + $ref: '#/definitions/base_info.Swagger400Resp' + "500": + description: errCode为500 一般为服务器内部错误 + schema: + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 创建群组 + tags: + - 群组相关 + /group/dismiss_group: + post: + consumes: + - application/json + description: 解散群组 + operationId: DismissGroup + parameters: + - description: im token + in: header + name: token + required: true + type: string + - description: groupID为要解散的群组ID + in: body + name: req + required: true + schema: + $ref: '#/definitions/base_info.DismissGroupReq' + produces: + - application/json + responses: + "0": + description: "" + schema: + $ref: '#/definitions/base_info.DismissGroupResp' + "400": + description: errCode为400 一般为参数输入错误, token未带上等 + schema: + $ref: '#/definitions/base_info.Swagger400Resp' + "500": + description: errCode为500 一般为服务器内部错误 + schema: + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 解散群组 + tags: + - 群组相关 + /group/get_group_all_member_list: + post: + consumes: + - application/json + description: 获取全部群成员列表 + operationId: GetGroupAllMemberList + parameters: + - description: im token + in: header + name: token + required: true + type: string + - description: GroupID为要获取群成员的群ID + in: body + name: req + required: true + schema: + $ref: '#/definitions/base_info.GetGroupAllMemberReq' + produces: + - application/json + responses: + "0": + description: "" + schema: + allOf: + - $ref: '#/definitions/base_info.GetGroupAllMemberResp' + - properties: + data: + items: + $ref: '#/definitions/server_api_params.GroupMemberFullInfo' + type: array + type: object + "400": + description: errCode为400 一般为参数输入错误, token未带上等 + schema: + $ref: '#/definitions/base_info.Swagger400Resp' + "500": + description: errCode为500 一般为服务器内部错误 + schema: + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 获取全部群成员列表 + tags: + - 群组相关 + /group/get_group_members_info: + post: + consumes: + - application/json + description: 获取群成员信息 + operationId: GetGroupMembersInfo + parameters: + - description: im token + in: header + name: token + required: true + type: string + - description: groupID为要获取的群ID
memberList为要获取群成员的群ID列表 + in: body + name: req + required: true + schema: + $ref: '#/definitions/base_info.GetGroupMembersInfoReq' + produces: + - application/json + responses: + "0": + description: "" + schema: + allOf: + - $ref: '#/definitions/base_info.GetGroupMembersInfoResp' + - properties: + data: + items: + $ref: '#/definitions/server_api_params.GroupMemberFullInfo' + type: array + type: object + "400": + description: errCode为400 一般为参数输入错误, token未带上等 + schema: + $ref: '#/definitions/base_info.Swagger400Resp' + "500": + description: errCode为500 一般为服务器内部错误 + schema: + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 获取群成员信息 + tags: + - 群组相关 + /group/get_groups_info: + post: + consumes: + - application/json + description: 通过群ID列表获取群信息 + operationId: GetGroupsInfo + parameters: + - description: im token + in: header + name: token + required: true + type: string + - description: groupIDList为群ID列表 + in: body + name: req + required: true + schema: + $ref: '#/definitions/base_info.GetGroupInfoReq' + produces: + - application/json + responses: + "0": + description: "" + schema: + $ref: '#/definitions/base_info.GetGroupInfoResp' + "400": + description: errCode为400 一般为参数输入错误, token未带上等 + schema: + $ref: '#/definitions/base_info.Swagger400Resp' + "500": + description: errCode为500 一般为服务器内部错误 + schema: + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 通过群ID列表获取群信息 + tags: + - 群组相关 + /group/get_joined_group_list: + post: + consumes: + - application/json + description: 获取用户加入群列表 + operationId: GetJoinedGroupList parameters: - description: im token in: header name: token required: true type: string - - description: fromUserID同意/拒绝的用户ID, toUserID为申请用户, handleMsg为处理信息, flag为具体操作, - 1为同意, 2为拒绝 + - description: fromUserID为要获取的用户ID in: body name: req required: true schema: - $ref: '#/definitions/base_info.AddFriendResponseReq' + $ref: '#/definitions/base_info.GetJoinedGroupListReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.AddFriendResponseResp' + allOf: + - $ref: '#/definitions/base_info.GetJoinedGroupListResp' + - properties: + data: + items: + $ref: '#/definitions/server_api_params.GroupInfo' + type: array + type: object "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.AddFriendResponseResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.AddFriendResponseResp' - summary: 同意/拒绝好友请求 + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 获取用户加入群列表 tags: - - 好友相关 - /friend/delete_friend: + - 群组相关 + /group/get_recv_group_applicationList: post: consumes: - application/json - description: 删除好友 - operationId: DeleteFriend + description: 获取用户收到的加群信息列表 + operationId: GetRecvGroupApplicationList parameters: - description: im token in: header name: token required: true type: string - - description: fromUserID为操作用户, toUserID为被删除用户 + - description: fromUserID为要获取的用户ID in: body name: req required: true schema: - $ref: '#/definitions/base_info.DeleteFriendReq' + $ref: '#/definitions/base_info.GetGroupApplicationListReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.DeleteFriendResp' + allOf: + - $ref: '#/definitions/base_info.GetGroupApplicationListResp' + - properties: + data: + items: + $ref: '#/definitions/server_api_params.GroupRequest' + type: array + type: object "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.DeleteFriendResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.DeleteFriendResp' - summary: 删除好友 + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 获取用户收到的加群信息列表 tags: - - 好友相关 - /friend/get_black_list: + - 群组相关 + /group/get_user_req_group_applicationList: post: consumes: - application/json - description: 获取黑名单列表 - operationId: GetBlacklist + description: 获取用户加群申请列表 + operationId: GetUserReqGroupApplicationList parameters: - description: im token in: header name: token required: true type: string - - description: fromUserID要获取黑名单的用户 + - description: userID为要获取的用户ID in: body name: req required: true schema: - $ref: '#/definitions/base_info.GetBlackListReq' + $ref: '#/definitions/base_info.GetUserReqGroupApplicationListReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.GetBlackListResp' + allOf: + - $ref: '#/definitions/base_info.GetGroupApplicationListResp' + - properties: + data: + items: + $ref: '#/definitions/server_api_params.GroupRequest' + type: array + type: object "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetBlackListResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetBlackListResp' - summary: 获取黑名单列表 + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 获取用户加群申请列表 tags: - - 好友相关 - /friend/get_friend_apply_list: + - 群组相关 + /group/group_application_response: post: consumes: - application/json - description: 删除好友 - operationId: GetFriendApplyList + description: 处理加群消息 + operationId: ApplicationGroupResponse parameters: - description: im token in: header name: token required: true type: string - - description: fromUserID为要获取申请列表的用户ID + - description: groupID为要处理的群ID
fromUserID为要处理的用户ID
handleMsg为处理结果信息 +
handleResult为处理结果 1为同意加群 2为拒绝加群 in: body name: req required: true schema: - $ref: '#/definitions/base_info.GetFriendApplyListReq' + $ref: '#/definitions/base_info.ApplicationGroupResponseReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.GetFriendApplyListResp' + $ref: '#/definitions/base_info.ApplicationGroupResponseResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetFriendApplyListResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetFriendApplyListResp' - summary: 获取好友申请列表 + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 处理加群消息 tags: - - 好友相关 - /friend/get_friend_list: + - 群组相关 + /group/invite_user_to_group: post: consumes: - application/json - description: 获取用户的好友列表 - operationId: GetFriendList + description: 将用户拉入群组 + operationId: InviteUserToGroup parameters: - description: im token in: header name: token required: true type: string - - description: fromUserID为要获取好友列表的用户ID + - description: groupID为要拉进的群组ID
invitedUserIDList为要获取群成员的群ID列表
reason为原因 in: body name: req required: true schema: - $ref: '#/definitions/base_info.GetFriendListReq' + $ref: '#/definitions/base_info.InviteUserToGroupReq' produces: - application/json responses: "0": - description: "" + description: result为结果码, -1为失败, 0为成功 schema: - $ref: '#/definitions/base_info.GetFriendListResp' + $ref: '#/definitions/base_info.InviteUserToGroupResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetFriendListResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetFriendListResp' - summary: 获取用户的好友列表 + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 将用户拉入群组 tags: - - 好友相关 - /friend/get_self_friend_apply_list: + - 群组相关 + /group/join_group: post: consumes: - application/json - description: 获取自己的好友申请列表 - operationId: GetSelfFriendApplyList + description: 加入群聊 + operationId: JoinGroup parameters: - description: im token in: header name: token required: true type: string - - description: fromUserID为自己的用户ID + - description: reqMessage为申请进群信息
groupID为申请的群ID in: body name: req required: true schema: - $ref: '#/definitions/base_info.GetSelfApplyListReq' + $ref: '#/definitions/base_info.JoinGroupReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.GetSelfApplyListResp' + $ref: '#/definitions/base_info.JoinGroupResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetSelfApplyListResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetSelfApplyListResp' - summary: 获取自己的好友申请列表 + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 加入群聊 tags: - - 好友相关 - /friend/import_friend: + - 群组相关 + /group/kick_group: post: consumes: - application/json - description: 批量加好友 - operationId: ImportFriend + description: 把用户踢出群组 + operationId: KickGroupMember parameters: - description: im token in: header name: token required: true type: string - - description: fromUserID批量加好友的用户ID, friendUserIDList为 + - description: GroupID为要操作的群ID
kickedUserIDList为要踢出的群用户ID
reason为原因 in: body name: req required: true schema: - $ref: '#/definitions/base_info.ImportFriendReq' + $ref: '#/definitions/base_info.KickGroupMemberReq' produces: - application/json responses: "0": - description: data列表中对象的result-1为添加该用户失败, 0为成功 + description: result为结果码, -1为失败, 0为成功 schema: - $ref: '#/definitions/base_info.ImportFriendResp' + $ref: '#/definitions/base_info.KickGroupMemberResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.ImportFriendResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.ImportFriendResp' - summary: 批量加好友 + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 把用户踢出群组 tags: - - 好友相关 - /friend/is_friend: + - 群组相关 + /group/mute_group: post: consumes: - application/json - description: 检查用户之间是否为好友 - operationId: IsFriend + description: 禁言群组 + operationId: MuteGroup parameters: - description: im token in: header name: token required: true type: string - - description: fromUserID为请求用户, toUserID为要检查的用户 + - description: groupID为群组ID in: body name: req required: true schema: - $ref: '#/definitions/base_info.IsFriendReq' + $ref: '#/definitions/base_info.MuteGroupReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.IsFriendResp' + $ref: '#/definitions/base_info.MuteGroupResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.IsFriendResp' + $ref: '#/definitions/base_info.MuteGroupResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.IsFriendResp' - summary: 检查用户之间是否为好友 + $ref: '#/definitions/base_info.MuteGroupResp' + summary: 禁言群组 tags: - - 好友相关 - /friend/remove_black: + - 群组相关 + /group/mute_group_member: post: consumes: - application/json - description: 把用户移除黑名单 - operationId: RemoveBlack + description: 禁言群成员 + operationId: MuteGroupMember parameters: - description: im token in: header name: token required: true type: string - - description: fromUserID要获取黑名单的用户 + - description: groupID为群组ID
userID为要禁言的用户ID
mutedSeconds为禁言秒数 in: body name: req required: true schema: - $ref: '#/definitions/base_info.RemoveBlackListReq' + $ref: '#/definitions/base_info.MuteGroupMemberReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.RemoveBlackListResp' + $ref: '#/definitions/base_info.DismissGroupResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.RemoveBlackListResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.RemoveBlackListResp' - summary: 把用户移除黑名单 + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 禁言群成员 tags: - - 好友相关 - /friend/set_friend_remark: + - 群组相关 + /group/quit_group: post: consumes: - application/json - description: 设置好友备注 - operationId: SetFriendRemark + description: 当前用户退出群聊 + operationId: QuitGroup parameters: - description: im token in: header name: token required: true type: string - - description: fromUserID为设置的用户, toUserID为被设置的用户, remark为好友备注 + - description: groupID为要退出的群ID in: body name: req required: true schema: - $ref: '#/definitions/base_info.SetFriendRemarkReq' + $ref: '#/definitions/base_info.QuitGroupReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.SetFriendRemarkResp' + $ref: '#/definitions/base_info.QuitGroupResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.SetFriendRemarkResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.SetFriendRemarkResp' - summary: 设置好友备注 + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 当前用户退出群聊 tags: - - 好友相关 - /group/cancel_mute_group: + - 群组相关 + /group/set_group_info: post: consumes: - application/json - description: 取消禁言群组 - operationId: CancelMuteGroup + description: 设置群信息 + operationId: SetGroupInfo parameters: - description: im token in: header name: token required: true type: string - - description: groupID为群组ID + - description: groupID为要修改的群ID
groupName为新的群名称
notification为群介绍
introduction为群公告 +
needVerification为加群验证 0为申请需要同意 邀请直接进 1为所有人进群需要验证,除了群主管理员邀请进群 2为直接进群 in: body name: req required: true schema: - $ref: '#/definitions/base_info.CancelMuteGroupReq' + $ref: '#/definitions/base_info.SetGroupInfoReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.CancelMuteGroupResp' + $ref: '#/definitions/base_info.SetGroupInfoResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.CancelMuteGroupResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.CancelMuteGroupResp' - summary: 取消禁言群组 + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 设置群信息 tags: - 群组相关 - /group/cancel_mute_group_member: + /group/set_group_member_info: post: consumes: - application/json - description: 取消禁言群成员 - operationId: CancelMuteGroupMember + description: 修改群成员信息 + operationId: SetGroupMemberInfo parameters: - description: im token in: header name: token required: true type: string - - description: groupID为群组ID
userID为要取消禁言的用户ID + - description: 除了operationID, userID, groupID其他参数可选
ex为拓展字段
faceURL为群头像
nickName为群昵称
roleLevel为群员角色,1为普通用户 + 2为群主 3为管理员 in: body name: req required: true schema: - $ref: '#/definitions/base_info.CancelMuteGroupMemberReq' + $ref: '#/definitions/base_info.SetGroupMemberInfoReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.CancelMuteGroupMemberResp' + $ref: '#/definitions/base_info.SetGroupMemberInfoResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.CancelMuteGroupMemberResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.CancelMuteGroupMemberResp' - summary: 取消禁言群成员 + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 修改群成员信息 tags: - 群组相关 - /group/create_group: + /group/transfer_group: post: consumes: - application/json - description: 创建群组 - operationId: CreateGroup + description: 转让群主 + operationId: TransferGroupOwner parameters: - description: im token in: header name: token required: true type: string - - description: ownerUserID为群主ID
ex为群扩展字段
roleLevel为群员角色,1为普通用户 2为群主 - 3为管理员 + - description: GroupID为要操作的群ID
oldOwnerUserID为老群主ID
newOwnerUserID为新群主ID in: body name: req required: true schema: - $ref: '#/definitions/base_info.CreateGroupReq' + $ref: '#/definitions/base_info.TransferGroupOwnerReq' produces: - application/json responses: "0": description: "" schema: - allOf: - - $ref: '#/definitions/base_info.CreateGroupResp' - - properties: - data: - $ref: '#/definitions/server_api_params.GroupInfo' - type: object + $ref: '#/definitions/base_info.TransferGroupOwnerResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.CreateGroupResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.CreateGroupResp' - summary: 创建群组 + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 转让群主 tags: - 群组相关 - /group/dismiss_group: + /msg/batch_send_msg: post: consumes: - application/json - description: 解散群组 - operationId: DismissGroup + description: 管理员批量发送群聊单聊消息 消息格式详细见消息格式 + operationId: ManagementBatchSendMsg parameters: - description: im token in: header name: token required: true type: string - - description: groupID为要解散的群组ID + - description: 该请求和消息结构体一样
recvIDList为接受消息的用户ID列表 in: body - name: req + name: 管理员批量发送单聊消息 required: true schema: - $ref: '#/definitions/base_info.DismissGroupReq' + allOf: + - $ref: '#/definitions/base_info.ManagementBatchSendMsgReq' + - properties: + content: + $ref: '#/definitions/Open_IM_internal_api_manage.TextElem' + type: object + - description: 该请求和消息结构体一样
recvIDList为接受消息的用户ID列表 + in: body + name: 管理员批量发送OA通知 + required: true + schema: + allOf: + - $ref: '#/definitions/base_info.ManagementSendMsgReq' + - properties: + content: + $ref: '#/definitions/Open_IM_internal_api_manage.OANotificationElem' + type: object produces: - application/json responses: "0": - description: "" + description: serverMsgID为服务器消息ID
clientMsgID为客户端消息ID
sendTime为发送消息时间 schema: - $ref: '#/definitions/base_info.DismissGroupResp' + $ref: '#/definitions/base_info.ManagementBatchSendMsgReq' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.DismissGroupResp' + $ref: '#/definitions/base_info.ManagementBatchSendMsgReq' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.DismissGroupResp' - summary: 解散群组 + $ref: '#/definitions/base_info.ManagementBatchSendMsgReq' + summary: 管理员批量发送群聊单聊消息 tags: - - 群组相关 - /group/get_group_all_member_list: + - 消息相关 + /msg/clear_msg: post: consumes: - application/json - description: 获取全部群成员列表 - operationId: GetGroupAllMemberList + description: 清空用户消息 + operationId: ClearMsg parameters: - description: im token in: header name: token required: true type: string - - description: GroupID为要获取群成员的群ID + - description: userID为要清空的用户ID in: body name: req required: true schema: - $ref: '#/definitions/base_info.GetGroupAllMemberReq' + $ref: '#/definitions/base_info.CleanUpMsgReq' produces: - application/json responses: "0": description: "" schema: - allOf: - - $ref: '#/definitions/base_info.GetGroupAllMemberResp' - - properties: - data: - items: - $ref: '#/definitions/server_api_params.GroupMemberFullInfo' - type: array - type: object + $ref: '#/definitions/base_info.CleanUpMsgResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetGroupAllMemberResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetGroupAllMemberResp' - summary: 获取全部群成员列表 + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 清空用户消息 tags: - - 群组相关 - /group/get_group_members_info: + - 消息相关 + /msg/del_msg: post: consumes: - application/json - description: 获取群成员信息 - operationId: GetGroupMembersInfo + description: 根据seq列表删除消息 + operationId: DelMsg parameters: - description: im token in: header name: token required: true type: string - - description: memberList为要获取群成员的群ID列表 + - description: userID为要删除的用户ID
seqList为seq列表 in: body name: req required: true schema: - $ref: '#/definitions/base_info.GetGroupMembersInfoReq' + $ref: '#/definitions/base_info.DelMsgReq' produces: - application/json responses: "0": description: "" schema: - allOf: - - $ref: '#/definitions/base_info.GetGroupMembersInfoResp' - - properties: - data: - items: - $ref: '#/definitions/server_api_params.GroupMemberFullInfo' - type: array - type: object + $ref: '#/definitions/base_info.DelMsgResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetGroupMembersInfoResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetGroupMembersInfoResp' - summary: 获取群成员信息 + $ref: '#/definitions/base_info.Swagger500Resp' + summary: 根据seq列表删除消息 tags: - - 群组相关 - /group/get_groups_info: + - 消息相关 + /msg/get_all_conversations: post: consumes: - application/json - description: 通过群ID列表获取群信息 - operationId: GetGroupsInfo + description: 获取用户所有会话 + operationId: GetAllConversations parameters: - description: im token in: header name: token required: true type: string - - description: groupIDList为群ID列表 + - description: ownerUserID为要获取的用户ID in: body name: req required: true schema: - $ref: '#/definitions/base_info.GetGroupInfoReq' + $ref: '#/definitions/base_info.GetAllConversationsReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.GetGroupInfoResp' + $ref: '#/definitions/base_info.GetAllConversationsResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetGroupInfoResp' + $ref: '#/definitions/base_info.GetAllConversationsResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetGroupInfoResp' - summary: 通过群ID列表获取群信息 + $ref: '#/definitions/base_info.GetAllConversationsResp' + summary: 获取用户所有会话 tags: - - 群组相关 - /group/get_joined_group_list: + - 会话相关 + /msg/get_conversation: post: consumes: - application/json - description: 获取用户加入群列表 - operationId: GetJoinedGroupList + description: 根据会话ID获取会话 + operationId: GetConversation parameters: - description: im token in: header name: token required: true type: string - - description: fromUserID为要获取的用户ID + - description: ownerUserID为要获取的用户ID
conversationID为要获取的会话ID in: body name: req required: true schema: - $ref: '#/definitions/base_info.GetJoinedGroupListReq' + $ref: '#/definitions/base_info.GetConversationReq' produces: - application/json responses: "0": description: "" schema: - allOf: - - $ref: '#/definitions/base_info.GetJoinedGroupListResp' - - properties: - data: - items: - $ref: '#/definitions/server_api_params.GroupInfo' - type: array - type: object + $ref: '#/definitions/base_info.GetConversationResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetJoinedGroupListResp' + $ref: '#/definitions/base_info.GetConversationResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetJoinedGroupListResp' - summary: 获取用户加入群列表 + $ref: '#/definitions/base_info.GetConversationResp' + summary: 根据会话ID获取会话 tags: - - 群组相关 - /group/get_recv_group_applicationList: + - 会话相关 + /msg/get_conversations: post: consumes: - application/json - description: 获取用户收到的加群信息列表 - operationId: GetRecvGroupApplicationList + description: 根据会话ID列表获取会话 + operationId: GetConversations parameters: - description: im token in: header name: token required: true type: string - - description: fromUserID为要获取的用户ID + - description: ownerUserID为要获取的用户ID
conversationIDs为要获取的会话ID列表 in: body name: req required: true schema: - $ref: '#/definitions/base_info.GetGroupApplicationListReq' + $ref: '#/definitions/base_info.GetConversationsReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.GetGroupApplicationListResp' + $ref: '#/definitions/base_info.GetConversationsResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetGroupApplicationListResp' + $ref: '#/definitions/base_info.GetConversationsResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetGroupApplicationListResp' - summary: 获取用户收到的加群信息列表 + $ref: '#/definitions/base_info.GetConversationsResp' + summary: 根据会话ID列表获取会话 tags: - - 群组相关 - /group/get_user_req_group_applicationList: + - 会话相关 + /msg/manage_send_msg: post: consumes: - application/json - description: 获取用户加群申请列表 - operationId: GetUserReqGroupApplicationList + description: 管理员发送/撤回消息 消息格式详细见
消息格式 + operationId: ManagementSendMsg parameters: - description: im token in: header name: token required: true type: string - - description: userID为要获取的用户ID + - description: 该请求和消息结构体一样 in: body - name: req + name: 管理员发送文字消息 required: true schema: - $ref: '#/definitions/base_info.GetUserReqGroupApplicationListReq' + allOf: + - $ref: '#/definitions/base_info.ManagementSendMsgReq' + - properties: + content: + $ref: '#/definitions/Open_IM_internal_api_manage.TextElem' + type: object + - description: 该请求和消息结构体一样 + in: body + name: 管理员发送OA通知消息 + required: true + schema: + allOf: + - $ref: '#/definitions/base_info.ManagementSendMsgReq' + - properties: + content: + $ref: '#/definitions/Open_IM_internal_api_manage.OANotificationElem' + type: object + - description: 该请求和消息结构体一样 + in: body + name: 管理员撤回单聊消息 + required: true + schema: + allOf: + - $ref: '#/definitions/base_info.ManagementSendMsgReq' + - properties: + content: + $ref: '#/definitions/Open_IM_internal_api_manage.RevokeElem' + type: object produces: - application/json responses: "0": - description: "" + description: serverMsgID为服务器消息ID
clientMsgID为客户端消息ID
sendTime为发送消息时间 schema: - $ref: '#/definitions/base_info.GetGroupApplicationListResp' + $ref: '#/definitions/base_info.ManagementSendMsgResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetGroupApplicationListResp' + $ref: '#/definitions/base_info.ManagementSendMsgResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetGroupApplicationListResp' - summary: 获取用户加群申请列表 + $ref: '#/definitions/base_info.ManagementSendMsgResp' + summary: 管理员发送/撤回消息 tags: - - 群组相关 - /group/group_application_response: + - 消息相关 + /office/comment_one_work_moment: post: consumes: - application/json - description: 处理加群消息 - operationId: ApplicationGroupResponse + description: 评论一条工作圈 + operationId: CommentOneWorkMoment parameters: - description: im token in: header name: token required: true type: string - - description: groupID为要处理的群ID
fromUserID为要处理的用户ID
handleMsg为处理结果信息 -
handleResult为处理结果 1为同意加群 2为拒绝加群 + - description: 请求 in: body name: req required: true schema: - $ref: '#/definitions/base_info.ApplicationGroupResponseReq' + $ref: '#/definitions/base_info.CommentOneWorkMomentReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.ApplicationGroupResponseResp' + $ref: '#/definitions/base_info.CommentOneWorkMomentResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.ApplicationGroupResponseResp' + $ref: '#/definitions/base_info.CommentOneWorkMomentResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.ApplicationGroupResponseResp' - summary: 处理加群消息 + $ref: '#/definitions/base_info.CommentOneWorkMomentResp' + summary: 评论一条工作圈 tags: - - 群组相关 - /group/invite_user_to_group: + - 工作圈 + /office/create_one_work_moment: post: consumes: - application/json - description: 将用户拉入群组 - operationId: InviteUserToGroup + description: 用户创建一条工作圈 + operationId: CreateOneWorkMoment parameters: - description: im token in: header name: token required: true type: string - - description: groupID为要拉进的群组ID
invitedUserIDList为要获取群成员的群ID列表
reason为原因 + - description: 请求 atUserList likeUserList permissionGroupList permissionUserList + 字段中userName可以不填 in: body name: req required: true schema: - $ref: '#/definitions/base_info.InviteUserToGroupReq' + $ref: '#/definitions/base_info.CreateOneWorkMomentReq' produces: - application/json responses: "0": - description: result为结果码, -1为失败, 0为成功 + description: "" schema: - $ref: '#/definitions/base_info.InviteUserToGroupResp' + $ref: '#/definitions/base_info.CreateOneWorkMomentResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.InviteUserToGroupResp' + $ref: '#/definitions/base_info.CreateOneWorkMomentResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.InviteUserToGroupResp' - summary: 将用户拉入群组 + $ref: '#/definitions/base_info.CreateOneWorkMomentResp' + summary: 创建一条工作圈 tags: - - 群组相关 - /group/join_group: + - 工作圈 + /office/create_tag: post: consumes: - application/json - description: 加入群聊 - operationId: JoinGroup + description: 创建标签 + operationId: CreateTag parameters: - description: im token in: header name: token required: true type: string - - description: reqMessage为申请进群信息 + - description: 请求 in: body name: req required: true schema: - $ref: '#/definitions/base_info.JoinGroupReq' + $ref: '#/definitions/base_info.CreateTagReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.JoinGroupResp' + $ref: '#/definitions/base_info.CreateTagResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.JoinGroupResp' + $ref: '#/definitions/base_info.CreateTagResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.JoinGroupResp' - summary: 加入群聊 + $ref: '#/definitions/base_info.CreateTagResp' + summary: 创建标签 tags: - - 群组相关 - /group/kick_group: + - 标签 + /office/delete_comment: post: consumes: - application/json - description: 把用户踢出群组 - operationId: KickGroupMember + description: 删除一条评论 + operationId: DeleteComment parameters: - description: im token in: header name: token required: true type: string - - description: GroupID为要操作的群ID
kickedUserIDList为要踢出的群用户ID
reason为原因 + - description: 请求 in: body name: req required: true schema: - $ref: '#/definitions/base_info.KickGroupMemberReq' + $ref: '#/definitions/base_info.DeleteCommentReq' produces: - application/json responses: "0": - description: result为结果码, -1为失败, 0为成功 + description: "" schema: - $ref: '#/definitions/base_info.KickGroupMemberResp' + $ref: '#/definitions/base_info.DeleteCommentResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.KickGroupMemberResp' + $ref: '#/definitions/base_info.DeleteCommentResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.KickGroupMemberResp' - summary: 把用户踢出群组 + $ref: '#/definitions/base_info.DeleteCommentResp' + summary: 删除一条评论 tags: - - 群组相关 - /group/mute_group: + - 工作圈 + /office/delete_one_work_moment: post: consumes: - application/json - description: 禁言群组 - operationId: MuteGroup + description: 根据用户工作圈ID删除一条工作圈 + operationId: DeleteOneWorkMoment parameters: - description: im token in: header name: token required: true type: string - - description: groupID为群组ID + - description: 请求 in: body name: req required: true schema: - $ref: '#/definitions/base_info.MuteGroupReq' + $ref: '#/definitions/base_info.DeleteOneWorkMomentReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.MuteGroupResp' + $ref: '#/definitions/base_info.DeleteOneWorkMomentResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.MuteGroupResp' + $ref: '#/definitions/base_info.DeleteOneWorkMomentResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.MuteGroupResp' - summary: 禁言群组 + $ref: '#/definitions/base_info.DeleteOneWorkMomentResp' + summary: 删除一条工作圈 tags: - - 群组相关 - /group/mute_group_member: + - 工作圈 + /office/delete_tag: post: consumes: - application/json - description: 禁言群成员 - operationId: MuteGroupMember + description: 根据标签ID创建标签 + operationId: DeleteTag parameters: - description: im token in: header name: token required: true type: string - - description: groupID为群组ID
userID为要禁言的用户ID
mutedSeconds为禁言秒数 + - description: 请求 in: body name: req required: true schema: - $ref: '#/definitions/base_info.MuteGroupMemberReq' + $ref: '#/definitions/base_info.DeleteTagReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.DismissGroupResp' + $ref: '#/definitions/base_info.DeleteTagResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.DismissGroupResp' + $ref: '#/definitions/base_info.DeleteTagResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.DismissGroupResp' - summary: 禁言群成员 + $ref: '#/definitions/base_info.DeleteTagResp' + summary: 删除标签 tags: - - 群组相关 - /group/quit_group: + - 标签 + /office/get_send_tag_log: post: consumes: - application/json - description: 退出群聊 - operationId: QuitGroup + description: 分页获取发送历史记录 + operationId: GetTagSendLogs parameters: - description: im token in: header name: token required: true type: string - - description: groupID为要退出的群ID + - description: 请求 in: body name: req required: true schema: - $ref: '#/definitions/base_info.QuitGroupReq' + $ref: '#/definitions/base_info.GetTagSendLogsReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.QuitGroupResp' + $ref: '#/definitions/base_info.GetTagSendLogsResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.QuitGroupResp' + $ref: '#/definitions/base_info.GetTagSendLogsResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.QuitGroupResp' - summary: 退出群聊 + $ref: '#/definitions/base_info.GetTagSendLogsResp' + summary: 获取发送历史记录 tags: - - 群组相关 - /group/set_group_info: + - 标签 + /office/get_user_friend_work_moments: post: consumes: - application/json - description: 设置群信息 - operationId: SetGroupInfo + description: 查询用户工作圈页面 + operationId: GetUserFriendWorkMoments parameters: - description: im token in: header name: token required: true type: string - - description: notification为群介绍
introduction为群公告
needVerification为加群验证 - 0为申请需要同意 邀请直接进 1为所有人进群需要验证,除了群主管理员邀请进群 2为直接进群 + - description: 请求 in: body name: req required: true schema: - $ref: '#/definitions/base_info.SetGroupInfoReq' + $ref: '#/definitions/base_info.GetUserFriendWorkMomentsReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.SetGroupInfoResp' + $ref: '#/definitions/base_info.GetUserFriendWorkMomentsResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.SetGroupInfoResp' + $ref: '#/definitions/base_info.GetUserFriendWorkMomentsResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.SetGroupInfoResp' - summary: 设置群信息 + $ref: '#/definitions/base_info.GetUserFriendWorkMomentsResp' + summary: 查询自己大工作圈页面 tags: - - 群组相关 - /group/set_group_member_info: + - 工作圈 + /office/get_user_tag_by_id: post: consumes: - application/json - description: 修改群成员信息 - operationId: SetGroupMemberInfo + description: 通过标签id获取该用户的标签信息 + operationId: GetUserTagByID parameters: - description: im token in: header name: token required: true type: string - - description: 除了operationID, userID, groupID其他参数可选 + - description: 请求 in: body name: req required: true schema: - $ref: '#/definitions/base_info.SetGroupMemberInfoReq' + $ref: '#/definitions/base_info.GetUserTagByIDReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.SetGroupMemberInfoResp' + $ref: '#/definitions/base_info.GetUserTagByIDResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.SetGroupMemberInfoResp' + $ref: '#/definitions/base_info.GetUserTagByIDResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.SetGroupMemberInfoResp' - summary: 修改群成员信息 + $ref: '#/definitions/base_info.GetUserTagByIDResp' + summary: 获取该用户的标签信息 tags: - - 群组相关 - /group/transfer_group: + - 标签 + /office/get_user_tags: post: consumes: - application/json - description: 转让群主 - operationId: TransferGroupOwner + description: 用户获取自己的所有的标签 + operationId: GetUserTags parameters: - description: im token in: header name: token required: true type: string - - description: GroupID为要操作的群ID
oldOwnerUserID为老群主ID
newOwnerUserID为新群主ID + - description: 请求 in: body name: req required: true schema: - $ref: '#/definitions/base_info.TransferGroupOwnerReq' + $ref: '#/definitions/base_info.GetUserTagsReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.TransferGroupOwnerResp' + $ref: '#/definitions/base_info.GetUserTagsResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.TransferGroupOwnerResp' + $ref: '#/definitions/base_info.GetUserTagsResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.TransferGroupOwnerResp' - summary: 转让群主 + $ref: '#/definitions/base_info.GetUserTagsResp' + summary: 获取用户标签信息 tags: - - 群组相关 - /msg/clear_msg: + - 标签 + /office/get_user_work_moments: post: consumes: - application/json - description: 清空用户消息 - operationId: ClearMsg + description: 查询用户工作圈 + operationId: GetUserWorkMoments parameters: - description: im token in: header name: token required: true type: string - - description: userID为要清空的用户ID + - description: 请求 in: body name: req required: true schema: - $ref: '#/definitions/base_info.CleanUpMsgReq' + $ref: '#/definitions/base_info.GetUserWorkMomentsReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.CleanUpMsgResp' + $ref: '#/definitions/base_info.GetUserWorkMomentsResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.CleanUpMsgResp' + $ref: '#/definitions/base_info.GetUserWorkMomentsResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.CleanUpMsgResp' - summary: 清空用户消息 + $ref: '#/definitions/base_info.GetUserWorkMomentsResp' + summary: 查询用户工作圈 tags: - - 消息相关 - /msg/del_msg: + - 工作圈 + /office/get_work_moment_by_id: post: consumes: - application/json - description: 根据seq列表删除消息 - operationId: DelMsg + description: 通过ID获取工作圈 + operationId: GetWorkMomentByID parameters: - description: im token in: header name: token required: true type: string - - description: userID为要删除的用户ID
seqList为seq列表 + - description: 请求 in: body name: req required: true schema: - $ref: '#/definitions/base_info.DelMsgReq' + $ref: '#/definitions/base_info.GetWorkMomentByIDReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.DelMsgResp' + $ref: '#/definitions/base_info.GetWorkMomentByIDResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.DelMsgResp' + $ref: '#/definitions/base_info.GetWorkMomentByIDResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.DelMsgResp' - summary: 根据seq列表删除消息 + $ref: '#/definitions/base_info.GetWorkMomentByIDResp' + summary: 通过ID获取工作圈 tags: - - 消息相关 - /office/comment_one_work_moment: + - 工作圈 + /office/like_one_work_moment: post: consumes: - application/json - description: 评论一条工作圈 - operationId: CommentOneWorkMoment + description: 工作圈ID点赞一条工作圈 + operationId: LikeOneWorkMoment parameters: - description: im token in: header @@ -3137,68 +4755,67 @@ paths: name: req required: true schema: - $ref: '#/definitions/base_info.CommentOneWorkMomentReq' + $ref: '#/definitions/base_info.LikeOneWorkMomentReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.CommentOneWorkMomentResp' + $ref: '#/definitions/base_info.LikeOneWorkMomentResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.CommentOneWorkMomentResp' + $ref: '#/definitions/base_info.LikeOneWorkMomentResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.CommentOneWorkMomentResp' - summary: 评论一条工作圈 + $ref: '#/definitions/base_info.LikeOneWorkMomentResp' + summary: 点赞一条工作圈 tags: - 工作圈 - /office/create_one_work_moment: + /office/send_msg_to_tag: post: consumes: - application/json - description: 用户创建一条工作圈 - operationId: CreateOneWorkMoment + description: 对标签用户发送消息 + operationId: SendMsg2Tag parameters: - description: im token in: header name: token required: true type: string - - description: 请求 atUserList likeUserList permissionGroupList permissionUserList - 字段中userName可以不填 + - description: 请求 in: body name: req required: true schema: - $ref: '#/definitions/base_info.CreateOneWorkMomentReq' + $ref: '#/definitions/base_info.SendMsg2TagReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.CreateOneWorkMomentResp' + $ref: '#/definitions/base_info.SendMsg2TagResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.CreateOneWorkMomentResp' + $ref: '#/definitions/base_info.SendMsg2TagResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.CreateOneWorkMomentResp' - summary: 创建一条工作圈 + $ref: '#/definitions/base_info.SendMsg2TagResp' + summary: 发送标签消息 tags: - - 工作圈 - /office/create_tag: + - 标签 + /office/set_tag: post: consumes: - application/json - description: 创建标签 - operationId: CreateTag + description: 根据标签ID修改标签用户列表, 名称 + operationId: SetTag parameters: - description: im token in: header @@ -3210,31 +4827,31 @@ paths: name: req required: true schema: - $ref: '#/definitions/base_info.CreateTagReq' + $ref: '#/definitions/base_info.SetTagReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.CreateTagResp' + $ref: '#/definitions/base_info.SetTagResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.CreateTagResp' + $ref: '#/definitions/base_info.SetTagResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.CreateTagResp' - summary: 创建标签 + $ref: '#/definitions/base_info.SetTagResp' + summary: 修改标签 tags: - 标签 - /office/delete_comment: + /organization/create_department: post: consumes: - application/json - description: 删除一条评论 - operationId: DeleteComment + description: 创建部门 + operationId: CreateDepartment parameters: - description: im token in: header @@ -3246,31 +4863,36 @@ paths: name: req required: true schema: - $ref: '#/definitions/base_info.DeleteCommentReq' + $ref: '#/definitions/base_info.CreateDepartmentReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.DeleteCommentResp' + allOf: + - $ref: '#/definitions/base_info.CreateDepartmentResp' + - properties: + data: + $ref: '#/definitions/server_api_params.Department' + type: object "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.DeleteCommentResp' + $ref: '#/definitions/base_info.CreateDepartmentResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.DeleteCommentResp' - summary: 删除一条评论 + $ref: '#/definitions/base_info.CreateDepartmentResp' + summary: 创建部门 tags: - - 工作圈 - /office/delete_one_work_moment: + - 组织架构相关 + /organization/create_department_member: post: consumes: - application/json - description: 根据用户工作圈ID删除一条工作圈 - operationId: DeleteOneWorkMoment + description: 创建部门用户 + operationId: CreateDepartmentMember parameters: - description: im token in: header @@ -3282,31 +4904,31 @@ paths: name: req required: true schema: - $ref: '#/definitions/base_info.DeleteOneWorkMomentReq' + $ref: '#/definitions/base_info.CreateDepartmentMemberReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.DeleteOneWorkMomentResp' + $ref: '#/definitions/base_info.CreateDepartmentMemberResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.DeleteOneWorkMomentResp' + $ref: '#/definitions/base_info.CreateDepartmentMemberResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.DeleteOneWorkMomentResp' - summary: 删除一条工作圈 + $ref: '#/definitions/base_info.CreateDepartmentMemberResp' + summary: 创建部门用户 tags: - - 工作圈 - /office/delete_tag: + - 组织架构相关 + /organization/create_organization_user: post: consumes: - application/json - description: 根据标签ID创建标签 - operationId: DeleteTag + description: 组织架构导入用户 + operationId: CreateOrganizationUser parameters: - description: im token in: header @@ -3318,31 +4940,31 @@ paths: name: req required: true schema: - $ref: '#/definitions/base_info.DeleteTagReq' + $ref: '#/definitions/base_info.CreateOrganizationUserReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.DeleteTagResp' + $ref: '#/definitions/base_info.CreateOrganizationUserResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.DeleteTagResp' + $ref: '#/definitions/base_info.CreateOrganizationUserResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.DeleteTagResp' - summary: 删除标签 + $ref: '#/definitions/base_info.CreateOrganizationUserResp' + summary: 组织架构导入用户 tags: - - 标签 - /office/get_send_tag_log: + - 组织架构相关 + /organization/delete_department: post: consumes: - application/json - description: 分页获取发送历史记录 - operationId: GetTagSendLogs + description: 删除部门 + operationId: DeleteDepartment parameters: - description: im token in: header @@ -3354,31 +4976,31 @@ paths: name: req required: true schema: - $ref: '#/definitions/base_info.GetTagSendLogsReq' + $ref: '#/definitions/base_info.DeleteDepartmentReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.GetTagSendLogsResp' + $ref: '#/definitions/base_info.DeleteDepartmentResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetTagSendLogsResp' + $ref: '#/definitions/base_info.DeleteDepartmentResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetTagSendLogsResp' - summary: 获取发送历史记录 + $ref: '#/definitions/base_info.DeleteDepartmentResp' + summary: 删除部门 tags: - - 标签 - /office/get_user_friend_work_moments: + - 组织架构相关 + /organization/delete_organization_user: post: consumes: - application/json - description: 查询用户工作圈页面 - operationId: GetUserFriendWorkMoments + description: 删除组织架构中某个用户 + operationId: DeleteOrganizationUser parameters: - description: im token in: header @@ -3390,31 +5012,31 @@ paths: name: req required: true schema: - $ref: '#/definitions/base_info.GetUserFriendWorkMomentsReq' + $ref: '#/definitions/base_info.DeleteOrganizationUserReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.GetUserFriendWorkMomentsResp' + $ref: '#/definitions/base_info.DeleteOrganizationUserResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetUserFriendWorkMomentsResp' + $ref: '#/definitions/base_info.DeleteOrganizationUserResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetUserFriendWorkMomentsResp' - summary: 查询自己大工作圈页面 + $ref: '#/definitions/base_info.DeleteOrganizationUserResp' + summary: 删除组织架构中某个用户 tags: - - 工作圈 - /office/get_user_tag_by_id: + - 组织架构相关 + /organization/delete_user_in_department: post: consumes: - application/json - description: 通过标签id获取该用户的标签信息 - operationId: GetUserTagByID + description: 删除部门中某个用户 + operationId: DeleteUserInDepartment parameters: - description: im token in: header @@ -3426,31 +5048,31 @@ paths: name: req required: true schema: - $ref: '#/definitions/base_info.GetUserTagByIDReq' + $ref: '#/definitions/base_info.DeleteUserInDepartmentReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.GetUserTagByIDResp' + $ref: '#/definitions/base_info.DeleteUserInDepartmentResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetUserTagByIDResp' + $ref: '#/definitions/base_info.DeleteUserInDepartmentResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetUserTagByIDResp' - summary: 获取该用户的标签信息 + $ref: '#/definitions/base_info.DeleteUserInDepartmentResp' + summary: 删除部门中某个用户 tags: - - 标签 - /office/get_user_tags: + - 组织架构相关 + /organization/get_department_member: post: consumes: - application/json - description: 用户获取自己的所有的标签 - operationId: GetUserTags + description: 获取部门中所有成员 + operationId: GetDepartmentMember parameters: - description: im token in: header @@ -3462,31 +5084,36 @@ paths: name: req required: true schema: - $ref: '#/definitions/base_info.GetUserTagsReq' + $ref: '#/definitions/base_info.GetDepartmentMemberReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.GetUserTagsResp' + allOf: + - $ref: '#/definitions/base_info.GetDepartmentMemberResp' + - properties: + data: + $ref: '#/definitions/server_api_params.UserDepartmentMember' + type: object "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetUserTagsResp' + $ref: '#/definitions/base_info.GetDepartmentMemberResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetUserTagsResp' - summary: 获取用户标签信息 + $ref: '#/definitions/base_info.GetDepartmentMemberResp' + summary: 获取部门中所有成员 tags: - - 标签 - /office/get_user_work_moments: + - 组织架构相关 + /organization/get_sub_department: post: consumes: - application/json - description: 查询用户工作圈 - operationId: GetUserWorkMoments + description: 获取子部门列表 + operationId: GetSubDepartment parameters: - description: im token in: header @@ -3498,31 +5125,31 @@ paths: name: req required: true schema: - $ref: '#/definitions/base_info.GetUserWorkMomentsReq' + $ref: '#/definitions/base_info.GetSubDepartmentReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.GetUserWorkMomentsResp' + $ref: '#/definitions/base_info.GetSubDepartmentResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetUserWorkMomentsResp' + $ref: '#/definitions/base_info.GetSubDepartmentResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetUserWorkMomentsResp' - summary: 查询用户工作圈 + $ref: '#/definitions/base_info.GetSubDepartmentResp' + summary: 获取子部门列表 tags: - - 工作圈 - /office/get_work_moment_by_id: + - 组织架构相关 + /organization/get_user_in_department: post: consumes: - application/json - description: 通过ID获取工作圈 - operationId: GetWorkMomentByID + description: 获取部门中的所有用户 + operationId: GetUserInDepartment parameters: - description: im token in: header @@ -3534,31 +5161,36 @@ paths: name: req required: true schema: - $ref: '#/definitions/base_info.GetWorkMomentByIDReq' + $ref: '#/definitions/base_info.GetUserInDepartmentReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.GetWorkMomentByIDResp' + allOf: + - $ref: '#/definitions/base_info.GetUserInDepartmentResp' + - properties: + data: + $ref: '#/definitions/server_api_params.UserInDepartment' + type: object "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetWorkMomentByIDResp' + $ref: '#/definitions/base_info.GetUserInDepartmentResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetWorkMomentByIDResp' - summary: 通过ID获取工作圈 + $ref: '#/definitions/base_info.GetUserInDepartmentResp' + summary: 获取部门中的所有用户 tags: - - 工作圈 - /office/like_one_work_moment: + - 组织架构相关 + /organization/update_department: post: consumes: - application/json - description: 工作圈ID点赞一条工作圈 - operationId: LikeOneWorkMoment + description: 更新部门信息 + operationId: UpdateDepartment parameters: - description: im token in: header @@ -3570,31 +5202,31 @@ paths: name: req required: true schema: - $ref: '#/definitions/base_info.LikeOneWorkMomentReq' + $ref: '#/definitions/base_info.UpdateDepartmentReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.LikeOneWorkMomentResp' + $ref: '#/definitions/base_info.UpdateDepartmentResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.LikeOneWorkMomentResp' + $ref: '#/definitions/base_info.UpdateDepartmentResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.LikeOneWorkMomentResp' - summary: 点赞一条工作圈 + $ref: '#/definitions/base_info.UpdateDepartmentResp' + summary: 更新部门信息 tags: - - 工作圈 - /office/send_msg_to_tag: + - 组织架构相关 + /organization/update_organization_user: post: consumes: - application/json - description: 对标签用户发送消息 - operationId: SendMsg2Tag + description: 更新组织架构中的用户 + operationId: UpdateOrganizationUser parameters: - description: im token in: header @@ -3606,31 +5238,31 @@ paths: name: req required: true schema: - $ref: '#/definitions/base_info.SendMsg2TagReq' + $ref: '#/definitions/base_info.UpdateOrganizationUserReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.SendMsg2TagResp' + $ref: '#/definitions/base_info.UpdateOrganizationUserResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.SendMsg2TagResp' + $ref: '#/definitions/base_info.UpdateOrganizationUserResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.SendMsg2TagResp' - summary: 发送标签消息 + $ref: '#/definitions/base_info.UpdateOrganizationUserResp' + summary: 更新组织架构中的用户 tags: - - 标签 - /office/set_tag: + - 组织架构相关 + /organization/update_user_in_department: post: consumes: - application/json - description: 根据标签ID修改标签用户列表, 名称 - operationId: SetTag + description: 更新部门中某个用户 + operationId: UpdateUserInDepartment parameters: - description: im token in: header @@ -3642,25 +5274,25 @@ paths: name: req required: true schema: - $ref: '#/definitions/base_info.SetTagReq' + $ref: '#/definitions/base_info.UpdateUserInDepartmentReq' produces: - application/json responses: "0": description: "" schema: - $ref: '#/definitions/base_info.SetTagResp' + $ref: '#/definitions/base_info.UpdateUserInDepartmentResp' "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.SetTagResp' + $ref: '#/definitions/base_info.UpdateUserInDepartmentResp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.SetTagResp' - summary: 修改标签 + $ref: '#/definitions/base_info.UpdateUserInDepartmentResp' + summary: 更新部门中某个用户 tags: - - 标签 + - 组织架构相关 /third/minio_upload: post: consumes: @@ -3698,11 +5330,11 @@ paths: "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.MinioUploadFileResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.MinioUploadFileResp' + $ref: '#/definitions/base_info.Swagger500Resp' summary: minio上传文件(web api) tags: - 第三方服务相关 @@ -3811,11 +5443,11 @@ paths: "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetSelfUserInfoResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetSelfUserInfoResp' + $ref: '#/definitions/base_info.Swagger500Resp' summary: 获取自己的信息 tags: - 用户相关 @@ -3843,15 +5475,22 @@ paths: "0": description: "" schema: - $ref: '#/definitions/base_info.GetUsersInfoResp' + allOf: + - $ref: '#/definitions/base_info.GetUsersInfoResp' + - properties: + Data: + items: + $ref: '#/definitions/server_api_params.PublicUserInfo' + type: array + type: object "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetUsersInfoResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetUsersInfoResp' + $ref: '#/definitions/base_info.Swagger500Resp' summary: 获取用户信息 tags: - 用户相关 @@ -3883,11 +5522,11 @@ paths: "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.GetUsersOnlineStatusResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.GetUsersOnlineStatusResp' + $ref: '#/definitions/base_info.Swagger500Resp' summary: 获取用户在线状态 tags: - 用户相关 @@ -3903,7 +5542,7 @@ paths: name: token required: true type: string - - description: 请求体 + - description: globalRecvMsgOpt为全局免打扰设置0为关闭 1为开启 in: body name: req required: true @@ -3919,11 +5558,11 @@ paths: "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.SetGlobalRecvMessageOptResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.SetGlobalRecvMessageOptResp' + $ref: '#/definitions/base_info.Swagger500Resp' summary: 设置全局免打扰 tags: - 用户相关 @@ -3955,11 +5594,11 @@ paths: "400": description: errCode为400 一般为参数输入错误, token未带上等 schema: - $ref: '#/definitions/base_info.UpdateUserInfoResp' + $ref: '#/definitions/base_info.Swagger400Resp' "500": description: errCode为500 一般为服务器内部错误 schema: - $ref: '#/definitions/base_info.UpdateUserInfoResp' + $ref: '#/definitions/base_info.Swagger500Resp' summary: 修改用户信息 tags: - 用户相关 diff --git a/cmd/open_im_api/main.go b/cmd/open_im_api/main.go index 42b715180..37ceefff2 100644 --- a/cmd/open_im_api/main.go +++ b/cmd/open_im_api/main.go @@ -29,6 +29,13 @@ import ( "Open_IM/pkg/common/constant" ) +// @title open-IM-Server API +// @version 1.0 +// @description open-IM-Server 的API服务器文档, 文档中所有请求都有一个operationID字段用于链路追踪 + +// @license.name Apache 2.0 +// @license.url http://www.apache.org/licenses/LICENSE-2.0.html +// @BasePath / func main() { log.NewPrivateLog(constant.LogFileName) gin.SetMode(gin.ReleaseMode) diff --git a/internal/api/auth/auth.go b/internal/api/auth/auth.go index 1f06ec847..540e6cc92 100644 --- a/internal/api/auth/auth.go +++ b/internal/api/auth/auth.go @@ -16,17 +16,17 @@ import ( "strings" ) -// @Summary 用户登录 -// @Description 用户登录 +// @Summary 用户注册 +// @Description 用户注册 // @Tags 鉴权认证 // @ID UserRegister // @Accept json // @Param token header string true "im token" -// @Param req body api.UserRegisterReq true "secret为openIM密钥, 详细见服务端config.yaml secret字段
platform为平台ID
ex为拓展字段" +// @Param req body api.UserRegisterReq true "secret为openIM密钥, 详细见服务端config.yaml secret字段
platform为平台ID
ex为拓展字段
gender为性别, 0为女, 1为男" // @Produce json // @Success 0 {object} api.UserRegisterResp -// @Failure 500 {object} api.UserRegisterResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.UserRegisterResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /auth/user_register [post] func UserRegister(c *gin.Context) { params := api.UserRegisterReq{} @@ -91,11 +91,11 @@ func UserRegister(c *gin.Context) { // @ID UserToken // @Accept json // @Param token header string true "im token" -// @Param req body api.UserTokenReq true "secret为openIM密钥, 详细见服务端config.yaml secret字段, platform为平台ID" +// @Param req body api.UserTokenReq true "secret为openIM密钥, 详细见服务端config.yaml secret字段
platform为平台ID" // @Produce json // @Success 0 {object} api.UserTokenResp -// @Failure 500 {object} api.UserTokenResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.UserTokenResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /auth/user_token [post] func UserToken(c *gin.Context) { params := api.UserTokenReq{} @@ -135,17 +135,17 @@ func UserToken(c *gin.Context) { c.JSON(http.StatusOK, resp) } -// @Summary 解析token -// @Description 解析用户token +// @Summary 解析当前用户token +// @Description 解析当前用户token(token在请求头中传入) // @Tags 鉴权认证 // @ID ParseToken // @Accept json // @Param token header string true "im token" -// @Param req body api.ParseTokenReq true "secret为openIM密钥, 详细见服务端config.yaml secret字段, platform为平台ID" +// @Param req body api.ParseTokenReq true "secret为openIM密钥, 详细见服务端config.yaml secret字段
platform为平台ID" // @Produce json -// @Success 0 {object} api.ParseTokenResp -// @Failure 500 {object} api.ParseTokenResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.ParseTokenResp "errCode为400 一般为参数输入错误, token未带上等" +// @Success 0 {object} api.ParseTokenResp{Data=api.ExpireTime} +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /auth/parse_token [post] func ParseToken(c *gin.Context) { params := api.ParseTokenReq{} @@ -179,11 +179,11 @@ func ParseToken(c *gin.Context) { // @ID ForceLogout // @Accept json // @Param token header string true "im token" -// @Param req body api.ForceLogoutReq true "platform为平台ID, fromUserID为要执行强制登出的用户ID" +// @Param req body api.ForceLogoutReq true "platform为平台ID
fromUserID为要执行强制登出的用户ID" // @Produce json // @Success 0 {object} api.ForceLogoutResp -// @Failure 500 {object} api.ForceLogoutResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.ForceLogoutResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /auth/force_logout [post] func ForceLogout(c *gin.Context) { params := api.ForceLogoutReq{} diff --git a/internal/api/chat/del_msg.go b/internal/api/chat/del_msg.go index d993ef23f..c6a6da385 100644 --- a/internal/api/chat/del_msg.go +++ b/internal/api/chat/del_msg.go @@ -25,8 +25,8 @@ import ( // @Param req body api.DelMsgReq true "userID为要删除的用户ID
seqList为seq列表" // @Produce json // @Success 0 {object} api.DelMsgResp -// @Failure 500 {object} api.DelMsgResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.DelMsgResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /msg/del_msg [post] func DelMsg(c *gin.Context) { var ( @@ -82,8 +82,8 @@ func DelMsg(c *gin.Context) { // @Param req body api.CleanUpMsgReq true "userID为要清空的用户ID" // @Produce json // @Success 0 {object} api.CleanUpMsgResp -// @Failure 500 {object} api.CleanUpMsgResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.CleanUpMsgResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /msg/clear_msg [post] func ClearMsg(c *gin.Context) { params := api.CleanUpMsgReq{} diff --git a/internal/api/conversation/conversation.go b/internal/api/conversation/conversation.go index b60b89ed4..36d7388bf 100644 --- a/internal/api/conversation/conversation.go +++ b/internal/api/conversation/conversation.go @@ -127,6 +127,18 @@ func BatchSetConversations(c *gin.Context) { c.JSON(http.StatusOK, resp) } +// @Summary 获取用户所有会话 +// @Description 获取用户所有会话 +// @Tags 会话相关 +// @ID GetAllConversations +// @Accept json +// @Param token header string true "im token" +// @Param req body api.GetAllConversationsReq true "ownerUserID为要获取的用户ID" +// @Produce json +// @Success 0 {object} api.GetAllConversationsResp +// @Failure 500 {object} api.GetAllConversationsResp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.GetAllConversationsResp "errCode为400 一般为参数输入错误, token未带上等" +// @Router /msg/get_all_conversations [post] func GetAllConversations(c *gin.Context) { var ( req api.GetAllConversationsReq @@ -165,6 +177,18 @@ func GetAllConversations(c *gin.Context) { c.JSON(http.StatusOK, resp) } +// @Summary 根据会话ID获取会话 +// @Description 根据会话ID获取会话 +// @Tags 会话相关 +// @ID GetConversation +// @Accept json +// @Param token header string true "im token" +// @Param req body api.GetConversationReq true "ownerUserID为要获取的用户ID
conversationID为要获取的会话ID" +// @Produce json +// @Success 0 {object} api.GetConversationResp +// @Failure 500 {object} api.GetConversationResp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.GetConversationResp "errCode为400 一般为参数输入错误, token未带上等" +// @Router /msg/get_conversation [post] func GetConversation(c *gin.Context) { var ( req api.GetConversationReq @@ -203,6 +227,18 @@ func GetConversation(c *gin.Context) { c.JSON(http.StatusOK, resp) } +// @Summary 根据会话ID列表获取会话 +// @Description 根据会话ID列表获取会话 +// @Tags 会话相关 +// @ID GetConversations +// @Accept json +// @Param token header string true "im token" +// @Param req body api.GetConversationsReq true "ownerUserID为要获取的用户ID
conversationIDs为要获取的会话ID列表" +// @Produce json +// @Success 0 {object} api.GetConversationsResp +// @Failure 500 {object} api.GetConversationsResp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.GetConversationsResp "errCode为400 一般为参数输入错误, token未带上等" +// @Router /msg/get_conversations [post] func GetConversations(c *gin.Context) { var ( req api.GetConversationsReq diff --git a/internal/api/friend/friend.go b/internal/api/friend/friend.go index 1170a3363..ac637275f 100644 --- a/internal/api/friend/friend.go +++ b/internal/api/friend/friend.go @@ -22,11 +22,11 @@ import ( // @ID AddBlack // @Accept json // @Param token header string true "im token" -// @Param req body api.AddBlacklistReq true "fromUserID为设置的用户, toUserID为被设置的用户" +// @Param req body api.AddBlacklistReq true "fromUserID为设置的用户
toUserID为被设置的用户" // @Produce json // @Success 0 {object} api.AddBlacklistResp -// @Failure 500 {object} api.AddBlacklistResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.AddBlacklistResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /friend/add_black [post] func AddBlack(c *gin.Context) { params := api.AddBlacklistReq{} @@ -43,7 +43,7 @@ func AddBlack(c *gin.Context) { if !ok { errMsg := req.CommID.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.CommID.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } log.NewInfo(params.OperationID, "AddBlacklist args ", req.String()) @@ -67,11 +67,11 @@ func AddBlack(c *gin.Context) { // @ID ImportFriend // @Accept json // @Param token header string true "im token" -// @Param req body api.ImportFriendReq true "fromUserID批量加好友的用户ID, friendUserIDList为" +// @Param req body api.ImportFriendReq true "fromUserID批量加好友的用户ID
friendUserIDList为" // @Produce json -// @Success 0 {object} api.ImportFriendResp "data列表中对象的result-1为添加该用户失败, 0为成功" -// @Failure 500 {object} api.ImportFriendResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.ImportFriendResp "errCode为400 一般为参数输入错误, token未带上等" +// @Success 0 {object} api.ImportFriendResp "data列表中对象的result-1为添加该用户失败
0为成功" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /friend/import_friend [post] func ImportFriend(c *gin.Context) { params := api.ImportFriendReq{} @@ -88,7 +88,7 @@ func ImportFriend(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -127,11 +127,11 @@ func ImportFriend(c *gin.Context) { // @ID AddFriend // @Accept json // @Param token header string true "im token" -// @Param req body api.AddFriendReq true "reqMsg为申请信息, fromUserID为申请用户, toUserID为被添加用户" +// @Param req body api.AddFriendReq true "reqMsg为申请信息
fromUserID为申请用户
toUserID为被添加用户" // @Produce json // @Success 0 {object} api.AddFriendResp -// @Failure 500 {object} api.AddFriendResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.AddFriendResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /friend/add_friend [post] func AddFriend(c *gin.Context) { params := api.AddFriendReq{} @@ -182,11 +182,11 @@ func AddFriend(c *gin.Context) { // @ID AddFriendResponse // @Accept json // @Param token header string true "im token" -// @Param req body api.AddFriendResponseReq true "fromUserID同意/拒绝的用户ID, toUserID为申请用户, handleMsg为处理信息, flag为具体操作, 1为同意, 2为拒绝" +// @Param req body api.AddFriendResponseReq true "fromUserID同意/拒绝的用户ID
toUserID为申请用户D
handleMsg为处理信息
flag为具体操作, 1为同意, 2为拒绝" // @Produce json // @Success 0 {object} api.AddFriendResponseResp -// @Failure 500 {object} api.AddFriendResponseResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.AddFriendResponseResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /friend/add_friend_response [post] func AddFriendResponse(c *gin.Context) { params := api.AddFriendResponseReq{} @@ -240,11 +240,11 @@ func AddFriendResponse(c *gin.Context) { // @ID DeleteFriend // @Accept json // @Param token header string true "im token" -// @Param req body api.DeleteFriendReq true "fromUserID为操作用户, toUserID为被删除用户" +// @Param req body api.DeleteFriendReq true "fromUserID为操作用户
toUserID为被删除用户" // @Produce json // @Success 0 {object} api.DeleteFriendResp -// @Failure 500 {object} api.DeleteFriendResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.DeleteFriendResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /friend/delete_friend [post] func DeleteFriend(c *gin.Context) { params := api.DeleteFriendReq{} @@ -262,7 +262,7 @@ func DeleteFriend(c *gin.Context) { if !ok { errMsg := req.CommID.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.CommID.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -296,9 +296,9 @@ func DeleteFriend(c *gin.Context) { // @Param token header string true "im token" // @Param req body api.GetBlackListReq true "fromUserID要获取黑名单的用户" // @Produce json -// @Success 0 {object} api.GetBlackListResp -// @Failure 500 {object} api.GetBlackListResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.GetBlackListResp "errCode为400 一般为参数输入错误, token未带上等" +// @Success 0 {object} api.GetBlackListResp{data=[]open_im_sdk.PublicUserInfo} +// @Failure 500 {object} api.Swagger400Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger500Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /friend/get_black_list [post] func GetBlacklist(c *gin.Context) { params := api.GetBlackListReq{} @@ -354,11 +354,11 @@ func GetBlacklist(c *gin.Context) { // @ID SetFriendRemark // @Accept json // @Param token header string true "im token" -// @Param req body api.SetFriendRemarkReq true "fromUserID为设置的用户, toUserID为被设置的用户, remark为好友备注" +// @Param req body api.SetFriendRemarkReq true "fromUserID为设置的用户
toUserID为被设置的用户
remark为好友备注" // @Produce json // @Success 0 {object} api.SetFriendRemarkResp -// @Failure 500 {object} api.SetFriendRemarkResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.SetFriendRemarkResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /friend/set_friend_remark [post] func SetFriendRemark(c *gin.Context) { params := api.SetFriendRemarkReq{} @@ -377,7 +377,7 @@ func SetFriendRemark(c *gin.Context) { if !ok { errMsg := req.CommID.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.CommID.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -412,8 +412,8 @@ func SetFriendRemark(c *gin.Context) { // @Param req body api.RemoveBlackListReq true "fromUserID要获取黑名单的用户" // @Produce json // @Success 0 {object} api.RemoveBlackListResp -// @Failure 500 {object} api.RemoveBlackListResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.RemoveBlackListResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /friend/remove_black [post] func RemoveBlack(c *gin.Context) { params := api.RemoveBlackListReq{} @@ -462,11 +462,11 @@ func RemoveBlack(c *gin.Context) { // @ID IsFriend // @Accept json // @Param token header string true "im token" -// @Param req body api.IsFriendReq true "fromUserID为请求用户, toUserID为要检查的用户" +// @Param req body api.IsFriendReq true "fromUserID为请求用户
toUserID为要检查的用户" // @Produce json // @Success 0 {object} api.IsFriendResp -// @Failure 500 {object} api.IsFriendResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.IsFriendResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /friend/is_friend [post] func IsFriend(c *gin.Context) { params := api.IsFriendReq{} @@ -519,9 +519,9 @@ func IsFriend(c *gin.Context) { // @Param token header string true "im token" // @Param req body api.GetFriendListReq true "fromUserID为要获取好友列表的用户ID" // @Produce json -// @Success 0 {object} api.GetFriendListResp -// @Failure 500 {object} api.GetFriendListResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.GetFriendListResp "errCode为400 一般为参数输入错误, token未带上等" +// @Success 0 {object} api.GetFriendListResp{data=[]open_im_sdk.FriendInfo} +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /friend/get_friend_list [post] func GetFriendList(c *gin.Context) { params := api.GetFriendListReq{} @@ -539,7 +539,7 @@ func GetFriendList(c *gin.Context) { if !ok { errMsg := req.CommID.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.CommID.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -575,9 +575,9 @@ func GetFriendList(c *gin.Context) { // @Param token header string true "im token" // @Param req body api.GetFriendApplyListReq true "fromUserID为要获取申请列表的用户ID" // @Produce json -// @Success 0 {object} api.GetFriendApplyListResp -// @Failure 500 {object} api.GetFriendApplyListResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.GetFriendApplyListResp "errCode为400 一般为参数输入错误, token未带上等" +// @Success 0 {object} api.GetFriendApplyListResp{data=[]open_im_sdk.FriendRequest} +// @Failure 500 {object} api.Swagger400Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /friend/get_friend_apply_list [post] func GetFriendApplyList(c *gin.Context) { params := api.GetFriendApplyListReq{} @@ -631,9 +631,9 @@ func GetFriendApplyList(c *gin.Context) { // @Param token header string true "im token" // @Param req body api.GetSelfApplyListReq true "fromUserID为自己的用户ID" // @Produce json -// @Success 0 {object} api.GetSelfApplyListResp -// @Failure 500 {object} api.GetSelfApplyListResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.GetSelfApplyListResp "errCode为400 一般为参数输入错误, token未带上等" +// @Success 0 {object} api.GetSelfApplyListResp{data=[]open_im_sdk.FriendRequest} +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /friend/get_self_friend_apply_list [post] func GetSelfFriendApplyList(c *gin.Context) { params := api.GetSelfApplyListReq{} diff --git a/internal/api/group/group.go b/internal/api/group/group.go index fafb33081..e7696fb92 100644 --- a/internal/api/group/group.go +++ b/internal/api/group/group.go @@ -29,8 +29,8 @@ import ( // @Param req body api.KickGroupMemberReq true "GroupID为要操作的群ID
kickedUserIDList为要踢出的群用户ID
reason为原因" // @Produce json // @Success 0 {object} api.KickGroupMemberResp "result为结果码, -1为失败, 0为成功" -// @Failure 500 {object} api.KickGroupMemberResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.KickGroupMemberResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/kick_group [post] func KickGroupMember(c *gin.Context) { params := api.KickGroupMemberReq{} @@ -49,7 +49,7 @@ func KickGroupMember(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -90,11 +90,11 @@ func KickGroupMember(c *gin.Context) { // @ID GetGroupMembersInfo // @Accept json // @Param token header string true "im token" -// @Param req body api.GetGroupMembersInfoReq true "memberList为要获取群成员的群ID列表" +// @Param req body api.GetGroupMembersInfoReq true "groupID为要获取的群ID
memberList为要获取群成员的群ID列表" // @Produce json // @Success 0 {object} api.GetGroupMembersInfoResp{data=[]open_im_sdk.GroupMemberFullInfo} -// @Failure 500 {object} api.GetGroupMembersInfoResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.GetGroupMembersInfoResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/get_group_members_info [post] func GetGroupMembersInfo(c *gin.Context) { params := api.GetGroupMembersInfoReq{} @@ -112,7 +112,7 @@ func GetGroupMembersInfo(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -156,7 +156,7 @@ func GetGroupMemberList(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -194,8 +194,8 @@ func GetGroupMemberList(c *gin.Context) { // @Param req body api.GetGroupAllMemberReq true "GroupID为要获取群成员的群ID" // @Produce json // @Success 0 {object} api.GetGroupAllMemberResp{data=[]open_im_sdk.GroupMemberFullInfo} -// @Failure 500 {object} api.GetGroupAllMemberResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.GetGroupAllMemberResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/get_group_all_member_list [post] func GetGroupAllMemberList(c *gin.Context) { params := api.GetGroupAllMemberReq{} @@ -213,7 +213,7 @@ func GetGroupAllMemberList(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -249,8 +249,8 @@ func GetGroupAllMemberList(c *gin.Context) { // @Param req body api.GetJoinedGroupListReq true "fromUserID为要获取的用户ID" // @Produce json // @Success 0 {object} api.GetJoinedGroupListResp{data=[]open_im_sdk.GroupInfo} -// @Failure 500 {object} api.GetJoinedGroupListResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.GetJoinedGroupListResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/get_joined_group_list [post] func GetJoinedGroupList(c *gin.Context) { params := api.GetJoinedGroupListReq{} @@ -268,7 +268,7 @@ func GetJoinedGroupList(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -304,8 +304,8 @@ func GetJoinedGroupList(c *gin.Context) { // @Param req body api.InviteUserToGroupReq true "groupID为要拉进的群组ID
invitedUserIDList为要获取群成员的群ID列表
reason为原因" // @Produce json // @Success 0 {object} api.InviteUserToGroupResp "result为结果码, -1为失败, 0为成功"" -// @Failure 500 {object} api.InviteUserToGroupResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.InviteUserToGroupResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/invite_user_to_group [post] func InviteUserToGroup(c *gin.Context) { params := api.InviteUserToGroupReq{} @@ -323,7 +323,7 @@ func InviteUserToGroup(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -363,11 +363,11 @@ func InviteUserToGroup(c *gin.Context) { // @ID CreateGroup // @Accept json // @Param token header string true "im token" -// @Param req body api.CreateGroupReq true "ownerUserID为群主ID
ex为群扩展字段
roleLevel为群员角色,1为普通用户 2为群主 3为管理员" +// @Param req body api.CreateGroupReq true "groupType这里填0代表普通群
groupName为群名称
introduction为群介绍
notification为群公共
ownerUserID为群主ID
ex为群扩展字段
memberList中对象roleLevel为群员角色,1为普通用户 2为群主 3为管理员" // @Produce json // @Success 0 {object} api.CreateGroupResp{data=open_im_sdk.GroupInfo} -// @Failure 500 {object} api.CreateGroupResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.CreateGroupResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/create_group [post] func CreateGroup(c *gin.Context) { params := api.CreateGroupReq{} @@ -431,9 +431,9 @@ func CreateGroup(c *gin.Context) { // @Param token header string true "im token" // @Param req body api.GetGroupApplicationListReq true "fromUserID为要获取的用户ID" // @Produce json -// @Success 0 {object} api.GetGroupApplicationListResp -// @Failure 500 {object} api.GetGroupApplicationListResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.GetGroupApplicationListResp "errCode为400 一般为参数输入错误, token未带上等" +// @Success 0 {object} api.GetGroupApplicationListResp{data=[]open_im_sdk.GroupRequest} +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/get_recv_group_applicationList [post] func GetRecvGroupApplicationList(c *gin.Context) { params := api.GetGroupApplicationListReq{} @@ -484,9 +484,9 @@ func GetRecvGroupApplicationList(c *gin.Context) { // @Param token header string true "im token" // @Param req body api.GetUserReqGroupApplicationListReq true "userID为要获取的用户ID" // @Produce json -// @Success 0 {object} api.GetGroupApplicationListResp -// @Failure 500 {object} api.GetGroupApplicationListResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.GetGroupApplicationListResp "errCode为400 一般为参数输入错误, token未带上等" +// @Success 0 {object} api.GetGroupApplicationListResp{data=[]open_im_sdk.GroupRequest} +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/get_user_req_group_applicationList [post] func GetUserReqGroupApplicationList(c *gin.Context) { var params api.GetUserReqGroupApplicationListReq @@ -537,8 +537,8 @@ func GetUserReqGroupApplicationList(c *gin.Context) { // @Param req body api.GetGroupInfoReq true "groupIDList为群ID列表" // @Produce json // @Success 0 {object} api.GetGroupInfoResp -// @Failure 500 {object} api.GetGroupInfoResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.GetGroupInfoResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/get_groups_info [post] func GetGroupsInfo(c *gin.Context) { params := api.GetGroupInfoReq{} @@ -556,7 +556,7 @@ func GetGroupsInfo(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -606,8 +606,8 @@ func GetGroupsInfo(c *gin.Context) { // @Param req body api.ApplicationGroupResponseReq true "groupID为要处理的群ID
fromUserID为要处理的用户ID
handleMsg为处理结果信息
handleResult为处理结果 1为同意加群 2为拒绝加群" // @Produce json // @Success 0 {object} api.ApplicationGroupResponseResp -// @Failure 500 {object} api.ApplicationGroupResponseResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.ApplicationGroupResponseResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/group_application_response [post] func ApplicationGroupResponse(c *gin.Context) { params := api.ApplicationGroupResponseReq{} @@ -625,7 +625,7 @@ func ApplicationGroupResponse(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -657,11 +657,11 @@ func ApplicationGroupResponse(c *gin.Context) { // @ID JoinGroup // @Accept json // @Param token header string true "im token" -// @Param req body api.JoinGroupReq true "reqMessage为申请进群信息" +// @Param req body api.JoinGroupReq true "reqMessage为申请进群信息
groupID为申请的群ID" // @Produce json // @Success 0 {object} api.JoinGroupResp -// @Failure 500 {object} api.JoinGroupResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.JoinGroupResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/join_group [post] func JoinGroup(c *gin.Context) { params := api.JoinGroupReq{} @@ -704,8 +704,8 @@ func JoinGroup(c *gin.Context) { c.JSON(http.StatusOK, resp) } -// @Summary 退出群聊 -// @Description 退出群聊 +// @Summary 当前用户退出群聊 +// @Description 当前用户退出群聊 // @Tags 群组相关 // @ID QuitGroup // @Accept json @@ -713,8 +713,8 @@ func JoinGroup(c *gin.Context) { // @Param req body api.QuitGroupReq true "groupID为要退出的群ID" // @Produce json // @Success 0 {object} api.QuitGroupResp -// @Failure 500 {object} api.QuitGroupResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.QuitGroupResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/quit_group [post] func QuitGroup(c *gin.Context) { params := api.QuitGroupReq{} @@ -732,7 +732,7 @@ func QuitGroup(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -763,11 +763,11 @@ func QuitGroup(c *gin.Context) { // @ID SetGroupInfo // @Accept json // @Param token header string true "im token" -// @Param req body api.SetGroupInfoReq true "notification为群介绍
introduction为群公告
needVerification为加群验证 0为申请需要同意 邀请直接进 1为所有人进群需要验证,除了群主管理员邀请进群 2为直接进群" +// @Param req body api.SetGroupInfoReq true "groupID为要修改的群ID
groupName为新的群名称
notification为群介绍
introduction为群公告
needVerification为加群验证 0为申请需要同意 邀请直接进 1为所有人进群需要验证,除了群主管理员邀请进群 2为直接进群" // @Produce json // @Success 0 {object} api.SetGroupInfoResp -// @Failure 500 {object} api.SetGroupInfoResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.SetGroupInfoResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/set_group_info [post] func SetGroupInfo(c *gin.Context) { params := api.SetGroupInfoReq{} @@ -791,7 +791,7 @@ func SetGroupInfo(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -825,8 +825,8 @@ func SetGroupInfo(c *gin.Context) { // @Param req body api.TransferGroupOwnerReq true "GroupID为要操作的群ID
oldOwnerUserID为老群主ID
newOwnerUserID为新群主ID" // @Produce json // @Success 0 {object} api.TransferGroupOwnerResp -// @Failure 500 {object} api.TransferGroupOwnerResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.TransferGroupOwnerResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/transfer_group [post] func TransferGroupOwner(c *gin.Context) { params := api.TransferGroupOwnerReq{} @@ -844,7 +844,7 @@ func TransferGroupOwner(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -879,8 +879,8 @@ func TransferGroupOwner(c *gin.Context) { // @Param req body api.DismissGroupReq true "groupID为要解散的群组ID" // @Produce json // @Success 0 {object} api.DismissGroupResp -// @Failure 500 {object} api.DismissGroupResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.DismissGroupResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/dismiss_group [post] func DismissGroup(c *gin.Context) { params := api.DismissGroupReq{} @@ -898,7 +898,7 @@ func DismissGroup(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -933,8 +933,8 @@ func DismissGroup(c *gin.Context) { // @Param req body api.MuteGroupMemberReq true "groupID为群组ID
userID为要禁言的用户ID
mutedSeconds为禁言秒数" // @Produce json // @Success 0 {object} api.DismissGroupResp -// @Failure 500 {object} api.DismissGroupResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.DismissGroupResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/mute_group_member [post] func MuteGroupMember(c *gin.Context) { params := api.MuteGroupMemberReq{} @@ -952,7 +952,7 @@ func MuteGroupMember(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -987,8 +987,8 @@ func MuteGroupMember(c *gin.Context) { // @Param req body api.CancelMuteGroupMemberReq true "groupID为群组ID
userID为要取消禁言的用户ID" // @Produce json // @Success 0 {object} api.CancelMuteGroupMemberResp -// @Failure 500 {object} api.CancelMuteGroupMemberResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.CancelMuteGroupMemberResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/cancel_mute_group_member [post] func CancelMuteGroupMember(c *gin.Context) { params := api.CancelMuteGroupMemberReq{} @@ -1006,7 +1006,7 @@ func CancelMuteGroupMember(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -1060,7 +1060,7 @@ func MuteGroup(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 400, "errMsg": errMsg}) return } @@ -1095,8 +1095,8 @@ func MuteGroup(c *gin.Context) { // @Param req body api.CancelMuteGroupReq true "groupID为群组ID" // @Produce json // @Success 0 {object} api.CancelMuteGroupResp -// @Failure 500 {object} api.CancelMuteGroupResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.CancelMuteGroupResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/cancel_mute_group [post] func CancelMuteGroup(c *gin.Context) { params := api.CancelMuteGroupReq{} @@ -1114,7 +1114,7 @@ func CancelMuteGroup(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -1158,7 +1158,7 @@ func SetGroupMemberNickname(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } @@ -1190,11 +1190,11 @@ func SetGroupMemberNickname(c *gin.Context) { // @ID SetGroupMemberInfo // @Accept json // @Param token header string true "im token" -// @Param req body api.SetGroupMemberInfoReq true "除了operationID, userID, groupID其他参数可选" +// @Param req body api.SetGroupMemberInfoReq true "除了operationID, userID, groupID其他参数可选
ex为拓展字段
faceURL为群头像
nickName为群昵称
roleLevel为群员角色,1为普通用户 2为群主 3为管理员" // @Produce json // @Success 0 {object} api.SetGroupMemberInfoResp -// @Failure 500 {object} api.SetGroupMemberInfoResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.SetGroupMemberInfoResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /group/set_group_member_info [post] func SetGroupMemberInfo(c *gin.Context) { var ( @@ -1212,7 +1212,7 @@ func SetGroupMemberInfo(c *gin.Context) { if !ok { errMsg := req.OperationID + " " + "GetUserIDFromToken failed " + errInfo + " token:" + c.Request.Header.Get("token") log.NewError(req.OperationID, errMsg) - c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) + c.JSON(http.StatusBadRequest, gin.H{"errCode": 500, "errMsg": errMsg}) return } diff --git a/internal/api/manage/management_chat.go b/internal/api/manage/management_chat.go index 6c9cd5ece..a70cbacf2 100644 --- a/internal/api/manage/management_chat.go +++ b/internal/api/manage/management_chat.go @@ -59,7 +59,6 @@ func newUserSendMsgReq(params *api.ManagementSendMsgReq) *pbChat.SendMsgReq { OperationID: params.OperationID, MsgData: &open_im_sdk.MsgData{ SendID: params.SendID, - RecvID: params.RecvID, GroupID: params.GroupID, ClientMsgID: utils.GetMsgID(params.SendID), SenderPlatformID: params.SenderPlatformID, @@ -69,6 +68,7 @@ func newUserSendMsgReq(params *api.ManagementSendMsgReq) *pbChat.SendMsgReq { MsgFrom: constant.SysMsgType, ContentType: params.ContentType, Content: []byte(newContent), + RecvID: params.RecvID, // ForceList: params.ForceList, CreateTime: utils.GetCurrentTimestampByMill(), Options: options, @@ -89,6 +89,20 @@ func init() { validate = validator.New() } +// @Summary 管理员发送/撤回消息 +// @Description 管理员发送/撤回消息 消息格式详细见
消息格式 +// @Tags 消息相关 +// @ID ManagementSendMsg +// @Accept json +// @Param token header string true "im token" +// @Param 管理员发送文字消息 body api.ManagementSendMsgReq{content=TextElem{}} true "该请求和消息结构体一样" +// @Param 管理员发送OA通知消息 body api.ManagementSendMsgReq{content=OANotificationElem{}} true "该请求和消息结构体一样" +// @Param 管理员撤回单聊消息 body api.ManagementSendMsgReq{content=RevokeElem{}} true "该请求和消息结构体一样" +// @Produce json +// @Success 0 {object} api.ManagementSendMsgResp "serverMsgID为服务器消息ID
clientMsgID为客户端消息ID
sendTime为发送消息时间" +// @Failure 500 {object} api.ManagementSendMsgResp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.ManagementSendMsgResp "errCode为400 一般为参数输入错误, token未带上等" +// @Router /msg/manage_send_msg [post] func ManagementSendMsg(c *gin.Context) { var data interface{} params := api.ManagementSendMsgReq{} @@ -194,6 +208,19 @@ func ManagementSendMsg(c *gin.Context) { c.JSON(http.StatusOK, resp) } +// @Summary 管理员批量发送群聊单聊消息 +// @Description 管理员批量发送群聊单聊消息 消息格式详细见
消息格式 +// @Tags 消息相关 +// @ID ManagementBatchSendMsg +// @Accept json +// @Param token header string true "im token" +// @Param 管理员批量发送单聊消息 body api.ManagementBatchSendMsgReq{content=TextElem{}} true "该请求和消息结构体一样
recvIDList为接受消息的用户ID列表" +// @Param 管理员批量发送OA通知 body api.ManagementSendMsgReq{content=OANotificationElem{}} true "该请求和消息结构体一样
recvIDList为接受消息的用户ID列表" +// @Produce json +// @Success 0 {object} api.ManagementBatchSendMsgReq "serverMsgID为服务器消息ID
clientMsgID为客户端消息ID
sendTime为发送消息时间" +// @Failure 500 {object} api.ManagementBatchSendMsgReq "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.ManagementBatchSendMsgReq "errCode为400 一般为参数输入错误, token未带上等" +// @Router /msg/batch_send_msg [post] func ManagementBatchSendMsg(c *gin.Context) { var data interface{} params := api.ManagementBatchSendMsgReq{} @@ -260,7 +287,11 @@ func ManagementBatchSendMsg(c *gin.Context) { } log.NewInfo(params.OperationID, "Ws call success to ManagementSendMsgReq", params) for _, recvID := range params.RecvIDList { - pbData := newUserSendMsgReq(¶ms.ManagementSendMsgReq) + req := &api.ManagementSendMsgReq{ + ManagementSendMsg: params.ManagementSendMsg, + RecvID: recvID, + } + pbData := newUserSendMsgReq(req) pbData.MsgData.RecvID = recvID log.Info(params.OperationID, "", "api ManagementSendMsg call start..., ", pbData.String()) etcdConn := getcdv3.GetConn(config.Config.Etcd.EtcdSchema, strings.Join(config.Config.Etcd.EtcdAddr, ","), config.Config.RpcRegisterName.OpenImOfflineMessageName, params.OperationID) diff --git a/internal/api/organization/organization.go b/internal/api/organization/organization.go index 5998fb0dd..32273756f 100644 --- a/internal/api/organization/organization.go +++ b/internal/api/organization/organization.go @@ -16,6 +16,18 @@ import ( "strings" ) +// @Summary 创建部门 +// @Description 创建部门 +// @Tags 组织架构相关 +// @ID CreateDepartment +// @Accept json +// @Param token header string true "im token" +// @Param req body api.CreateDepartmentReq true "请求" +// @Produce json +// @Success 0 {object} api.CreateDepartmentResp{data=open_im_sdk.Department} +// @Failure 500 {object} api.CreateDepartmentResp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.CreateDepartmentResp "errCode为400 一般为参数输入错误, token未带上等" +// @Router /organization/create_department [post] func CreateDepartment(c *gin.Context) { params := api.CreateDepartmentReq{} if err := c.BindJSON(¶ms); err != nil { @@ -59,6 +71,18 @@ func CreateDepartment(c *gin.Context) { c.JSON(http.StatusOK, apiResp) } +// @Summary 更新部门信息 +// @Description 更新部门信息 +// @Tags 组织架构相关 +// @ID UpdateDepartment +// @Accept json +// @Param token header string true "im token" +// @Param req body api.UpdateDepartmentReq true "请求" +// @Produce json +// @Success 0 {object} api.UpdateDepartmentResp +// @Failure 500 {object} api.UpdateDepartmentResp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.UpdateDepartmentResp "errCode为400 一般为参数输入错误, token未带上等" +// @Router /organization/update_department [post] func UpdateDepartment(c *gin.Context) { params := api.UpdateDepartmentReq{} if err := c.BindJSON(¶ms); err != nil { @@ -101,6 +125,18 @@ func UpdateDepartment(c *gin.Context) { c.JSON(http.StatusOK, apiResp) } +// @Summary 获取子部门列表 +// @Description 获取子部门列表 +// @Tags 组织架构相关 +// @ID GetSubDepartment +// @Accept json +// @Param token header string true "im token" +// @Param req body api.GetSubDepartmentReq true "请求" +// @Produce json +// @Success 0 {object} api.GetSubDepartmentResp +// @Failure 500 {object} api.GetSubDepartmentResp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.GetSubDepartmentResp "errCode为400 一般为参数输入错误, token未带上等" +// @Router /organization/get_sub_department [post] func GetSubDepartment(c *gin.Context) { params := api.GetSubDepartmentReq{} if err := c.BindJSON(¶ms); err != nil { @@ -146,6 +182,18 @@ func GetAllDepartment(c *gin.Context) { } +// @Summary 删除部门 +// @Description 删除部门 +// @Tags 组织架构相关 +// @ID DeleteDepartment +// @Accept json +// @Param token header string true "im token" +// @Param req body api.DeleteDepartmentReq true "请求" +// @Produce json +// @Success 0 {object} api.DeleteDepartmentResp +// @Failure 500 {object} api.DeleteDepartmentResp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.DeleteDepartmentResp "errCode为400 一般为参数输入错误, token未带上等" +// @Router /organization/delete_department [post] func DeleteDepartment(c *gin.Context) { params := api.DeleteDepartmentReq{} if err := c.BindJSON(¶ms); err != nil { @@ -185,6 +233,18 @@ func DeleteDepartment(c *gin.Context) { c.JSON(http.StatusOK, apiResp) } +// @Summary 组织架构导入用户 +// @Description 组织架构导入用户 +// @Tags 组织架构相关 +// @ID CreateOrganizationUser +// @Accept json +// @Param token header string true "im token" +// @Param req body api.CreateOrganizationUserReq true "请求" +// @Produce json +// @Success 0 {object} api.CreateOrganizationUserResp +// @Failure 500 {object} api.CreateOrganizationUserResp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.CreateOrganizationUserResp "errCode为400 一般为参数输入错误, token未带上等" +// @Router /organization/create_organization_user [post] func CreateOrganizationUser(c *gin.Context) { params := api.CreateOrganizationUserReq{} if err := c.BindJSON(¶ms); err != nil { @@ -227,6 +287,18 @@ func CreateOrganizationUser(c *gin.Context) { c.JSON(http.StatusOK, apiResp) } +// @Summary 更新组织架构中的用户 +// @Description 更新组织架构中的用户 +// @Tags 组织架构相关 +// @ID UpdateOrganizationUser +// @Accept json +// @Param token header string true "im token" +// @Param req body api.UpdateOrganizationUserReq true "请求" +// @Produce json +// @Success 0 {object} api.UpdateOrganizationUserResp +// @Failure 500 {object} api.UpdateOrganizationUserResp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.UpdateOrganizationUserResp "errCode为400 一般为参数输入错误, token未带上等" +// @Router /organization/update_organization_user [post] func UpdateOrganizationUser(c *gin.Context) { params := api.UpdateOrganizationUserReq{} if err := c.BindJSON(¶ms); err != nil { @@ -262,12 +334,23 @@ func UpdateOrganizationUser(c *gin.Context) { c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": errMsg}) return } - apiResp := api.UpdateOrganizationUserResp{CommResp: api.CommResp{ErrCode: RpcResp.ErrCode, ErrMsg: RpcResp.ErrMsg}} log.NewInfo(req.OperationID, utils.GetSelfFuncName(), "api return ", apiResp) c.JSON(http.StatusOK, apiResp) } +// @Summary 创建部门用户 +// @Description 创建部门用户 +// @Tags 组织架构相关 +// @ID CreateDepartmentMember +// @Accept json +// @Param token header string true "im token" +// @Param req body api.CreateDepartmentMemberReq true "请求" +// @Produce json +// @Success 0 {object} api.CreateDepartmentMemberResp +// @Failure 500 {object} api.CreateDepartmentMemberResp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.CreateDepartmentMemberResp "errCode为400 一般为参数输入错误, token未带上等" +// @Router /organization/create_department_member [post] func CreateDepartmentMember(c *gin.Context) { params := api.CreateDepartmentMemberReq{} if err := c.BindJSON(¶ms); err != nil { @@ -310,6 +393,18 @@ func CreateDepartmentMember(c *gin.Context) { c.JSON(http.StatusOK, apiResp) } +// @Summary 获取部门中的所有用户 +// @Description 获取部门中的所有用户 +// @Tags 组织架构相关 +// @ID GetUserInDepartment +// @Accept json +// @Param token header string true "im token" +// @Param req body api.GetUserInDepartmentReq true "请求" +// @Produce json +// @Success 0 {object} api.GetUserInDepartmentResp{data=open_im_sdk.UserInDepartment} +// @Failure 500 {object} api.GetUserInDepartmentResp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.GetUserInDepartmentResp "errCode为400 一般为参数输入错误, token未带上等" +// @Router /organization/get_user_in_department [post] func GetUserInDepartment(c *gin.Context) { params := api.GetUserInDepartmentReq{} if err := c.BindJSON(¶ms); err != nil { @@ -352,6 +447,18 @@ func GetUserInDepartment(c *gin.Context) { c.JSON(http.StatusOK, apiResp) } +// @Summary 更新部门中某个用户 +// @Description 更新部门中某个用户 +// @Tags 组织架构相关 +// @ID UpdateUserInDepartment +// @Accept json +// @Param token header string true "im token" +// @Param req body api.UpdateUserInDepartmentReq true "请求" +// @Produce json +// @Success 0 {object} api.UpdateUserInDepartmentResp +// @Failure 500 {object} api.UpdateUserInDepartmentResp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.UpdateUserInDepartmentResp "errCode为400 一般为参数输入错误, token未带上等" +// @Router /organization/update_user_in_department [post] func UpdateUserInDepartment(c *gin.Context) { params := api.UpdateUserInDepartmentReq{} if err := c.BindJSON(¶ms); err != nil { @@ -393,6 +500,18 @@ func UpdateUserInDepartment(c *gin.Context) { c.JSON(http.StatusOK, apiResp) } +// @Summary 删除组织架构中某个用户 +// @Description 删除组织架构中某个用户 +// @Tags 组织架构相关 +// @ID DeleteOrganizationUser +// @Accept json +// @Param token header string true "im token" +// @Param req body api.DeleteOrganizationUserReq true "请求" +// @Produce json +// @Success 0 {object} api.DeleteOrganizationUserResp +// @Failure 500 {object} api.DeleteOrganizationUserResp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.DeleteOrganizationUserResp "errCode为400 一般为参数输入错误, token未带上等" +// @Router /organization/delete_organization_user [post] func DeleteOrganizationUser(c *gin.Context) { params := api.DeleteOrganizationUserReq{} if err := c.BindJSON(¶ms); err != nil { @@ -434,6 +553,18 @@ func DeleteOrganizationUser(c *gin.Context) { c.JSON(http.StatusOK, apiResp) } +// @Summary 获取部门中所有成员 +// @Description 获取部门中所有成员 +// @Tags 组织架构相关 +// @ID GetDepartmentMember +// @Accept json +// @Param token header string true "im token" +// @Param req body api.GetDepartmentMemberReq true "请求" +// @Produce json +// @Success 0 {object} api.GetDepartmentMemberResp{data=open_im_sdk.UserDepartmentMember} +// @Failure 500 {object} api.GetDepartmentMemberResp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.GetDepartmentMemberResp "errCode为400 一般为参数输入错误, token未带上等" +// @Router /organization/get_department_member [post] func GetDepartmentMember(c *gin.Context) { params := api.GetDepartmentMemberReq{} if err := c.BindJSON(¶ms); err != nil { @@ -476,6 +607,18 @@ func GetDepartmentMember(c *gin.Context) { c.JSON(http.StatusOK, apiResp) } +// @Summary 删除部门中某个用户 +// @Description 删除部门中某个用户 +// @Tags 组织架构相关 +// @ID DeleteUserInDepartment +// @Accept json +// @Param token header string true "im token" +// @Param req body api.DeleteUserInDepartmentReq true "请求" +// @Produce json +// @Success 0 {object} api.DeleteUserInDepartmentResp +// @Failure 500 {object} api.DeleteUserInDepartmentResp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.DeleteUserInDepartmentResp "errCode为400 一般为参数输入错误, token未带上等" +// @Router /organization/delete_user_in_department [post] func DeleteUserInDepartment(c *gin.Context) { params := api.DeleteUserInDepartmentReq{} if err := c.BindJSON(¶ms); err != nil { diff --git a/internal/api/third/minio_storage_credential.go b/internal/api/third/minio_storage_credential.go index 7d0124688..e21550044 100644 --- a/internal/api/third/minio_storage_credential.go +++ b/internal/api/third/minio_storage_credential.go @@ -28,13 +28,13 @@ import ( // @Param operationID formData string true "操作唯一ID" // @Produce json // @Success 0 {object} api.MinioUploadFileResp "" -// @Failure 500 {object} api.MinioUploadFileResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.MinioUploadFileResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /third/minio_upload [post] func MinioUploadFile(c *gin.Context) { var ( req api.MinioUploadFileReq - resp api.MinioUploadFileResp + resp api.MinioUploadFile ) defer func() { if r := recover(); r != nil { diff --git a/internal/api/user/user.go b/internal/api/user/user.go index 81832f5b2..3047dce46 100644 --- a/internal/api/user/user.go +++ b/internal/api/user/user.go @@ -155,9 +155,9 @@ func GetBlackIDListFromCache(c *gin.Context) { // @Param token header string true "im token" // @Param req body api.GetUsersInfoReq true "请求体" // @Produce json -// @Success 0 {object} api.GetUsersInfoResp -// @Failure 500 {object} api.GetUsersInfoResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.GetUsersInfoResp "errCode为400 一般为参数输入错误, token未带上等" +// @Success 0 {object} api.GetUsersInfoResp{Data=[]open_im_sdk.PublicUserInfo} +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /user/get_users_info [post] func GetUsersInfo(c *gin.Context) { params := api.GetUsersInfoReq{} @@ -216,8 +216,8 @@ func GetUsersInfo(c *gin.Context) { // @Param req body api.UpdateSelfUserInfoReq true "请求体" // @Produce json // @Success 0 {object} api.UpdateUserInfoResp -// @Failure 500 {object} api.UpdateUserInfoResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.UpdateUserInfoResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /user/update_user_info [post] func UpdateUserInfo(c *gin.Context) { params := api.UpdateSelfUserInfoReq{} @@ -264,11 +264,11 @@ func UpdateUserInfo(c *gin.Context) { // @ID SetGlobalRecvMessageOpt // @Accept json // @Param token header string true "im token" -// @Param req body api.SetGlobalRecvMessageOptReq true "请求体" +// @Param req body api.SetGlobalRecvMessageOptReq true "globalRecvMsgOpt为全局免打扰设置0为关闭 1为开启" // @Produce json // @Success 0 {object} api.SetGlobalRecvMessageOptResp -// @Failure 500 {object} api.SetGlobalRecvMessageOptResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.SetGlobalRecvMessageOptResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /user/set_global_msg_recv_opt [post] func SetGlobalRecvMessageOpt(c *gin.Context) { params := api.SetGlobalRecvMessageOptReq{} @@ -318,8 +318,8 @@ func SetGlobalRecvMessageOpt(c *gin.Context) { // @Param req body api.GetSelfUserInfoReq true "请求体" // @Produce json // @Success 0 {object} api.GetSelfUserInfoResp{data=open_im_sdk.UserInfo} -// @Failure 500 {object} api.GetSelfUserInfoResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.GetSelfUserInfoResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /user/get_self_user_info [post] func GetSelfUserInfo(c *gin.Context) { params := api.GetSelfUserInfoReq{} @@ -381,8 +381,8 @@ func GetSelfUserInfo(c *gin.Context) { // @Param req body api.GetUsersOnlineStatusReq true "请求体" // @Produce json // @Success 0 {object} api.GetUsersOnlineStatusResp -// @Failure 500 {object} api.GetUsersOnlineStatusResp "errCode为500 一般为服务器内部错误" -// @Failure 400 {object} api.GetUsersOnlineStatusResp "errCode为400 一般为参数输入错误, token未带上等" +// @Failure 500 {object} api.Swagger500Resp "errCode为500 一般为服务器内部错误" +// @Failure 400 {object} api.Swagger400Resp "errCode为400 一般为参数输入错误, token未带上等" // @Router /user/get_users_online_status [post] func GetUsersOnlineStatus(c *gin.Context) { params := api.GetUsersOnlineStatusReq{} diff --git a/pkg/base_info/auth_api_struct.go b/pkg/base_info/auth_api_struct.go index 70f0f86c9..3b2fb2b13 100644 --- a/pkg/base_info/auth_api_struct.go +++ b/pkg/base_info/auth_api_struct.go @@ -63,6 +63,6 @@ type ExpireTime struct { type ParseTokenResp struct { CommResp - Data map[string]interface{} `json:"data"` + Data map[string]interface{} `json:"data" swaggerignore:"true"` ExpireTime ExpireTime `json:"-"` } diff --git a/pkg/base_info/friend_api_struct.go b/pkg/base_info/friend_api_struct.go index 3c45c393e..e15bed380 100644 --- a/pkg/base_info/friend_api_struct.go +++ b/pkg/base_info/friend_api_struct.go @@ -60,7 +60,7 @@ type GetBlackListReq struct { type GetBlackListResp struct { CommResp BlackUserInfoList []*open_im_sdk.PublicUserInfo `json:"-"` - Data []map[string]interface{} `json:"data"` + Data []map[string]interface{} `json:"data" swaggerignore:"true"` } //type PublicUserInfo struct { @@ -102,7 +102,7 @@ type GetFriendsInfoReq struct { type GetFriendsInfoResp struct { CommResp FriendInfoList []*open_im_sdk.FriendInfo `json:"-"` - Data []map[string]interface{} `json:"data"` + Data []map[string]interface{} `json:"data" swaggerignore:"true"` } type GetFriendListReq struct { @@ -112,7 +112,7 @@ type GetFriendListReq struct { type GetFriendListResp struct { CommResp FriendInfoList []*open_im_sdk.FriendInfo `json:"-"` - Data []map[string]interface{} `json:"data"` + Data []map[string]interface{} `json:"data" swaggerignore:"true"` } type GetFriendApplyListReq struct { @@ -122,7 +122,7 @@ type GetFriendApplyListReq struct { type GetFriendApplyListResp struct { CommResp FriendRequestList []*open_im_sdk.FriendRequest `json:"-"` - Data []map[string]interface{} `json:"data"` + Data []map[string]interface{} `json:"data" swaggerignore:"true"` } type GetSelfApplyListReq struct { @@ -132,5 +132,5 @@ type GetSelfApplyListReq struct { type GetSelfApplyListResp struct { CommResp FriendRequestList []*open_im_sdk.FriendRequest `json:"-"` - Data []map[string]interface{} `json:"data"` + Data []map[string]interface{} `json:"data" swaggerignore:"true"` } diff --git a/pkg/base_info/group_api_struct.go b/pkg/base_info/group_api_struct.go index d38615026..dac6328ee 100644 --- a/pkg/base_info/group_api_struct.go +++ b/pkg/base_info/group_api_struct.go @@ -33,7 +33,7 @@ type GetGroupMembersInfoReq struct { type GetGroupMembersInfoResp struct { CommResp MemberList []*open_im_sdk.GroupMemberFullInfo `json:"-"` - Data []map[string]interface{} `json:"data"` + Data []map[string]interface{} `json:"data" swaggerignore:"true"` } type InviteUserToGroupReq struct { @@ -54,7 +54,7 @@ type GetJoinedGroupListReq struct { type GetJoinedGroupListResp struct { CommResp GroupInfoList []*open_im_sdk.GroupInfo `json:"-"` - Data []map[string]interface{} `json:"data"` + Data []map[string]interface{} `json:"data" swaggerignore:"true"` } type GetGroupMemberListReq struct { @@ -67,7 +67,7 @@ type GetGroupMemberListResp struct { CommResp NextSeq int32 `json:"nextSeq"` MemberList []*open_im_sdk.GroupMemberFullInfo `json:"-"` - Data []map[string]interface{} `json:"data"` + Data []map[string]interface{} `json:"data" swaggerignore:"true"` } type GetGroupAllMemberReq struct { @@ -77,7 +77,7 @@ type GetGroupAllMemberReq struct { type GetGroupAllMemberResp struct { CommResp MemberList []*open_im_sdk.GroupMemberFullInfo `json:"-"` - Data []map[string]interface{} `json:"data"` + Data []map[string]interface{} `json:"data" swaggerignore:"true"` } type CreateGroupReq struct { @@ -105,7 +105,7 @@ type GetGroupApplicationListReq struct { type GetGroupApplicationListResp struct { CommResp GroupRequestList []*open_im_sdk.GroupRequest `json:"-"` - Data []map[string]interface{} `json:"data"` + Data []map[string]interface{} `json:"data" swaggerignore:"true"` } type GetUserReqGroupApplicationListReq struct { @@ -125,7 +125,7 @@ type GetGroupInfoReq struct { type GetGroupInfoResp struct { CommResp GroupInfoList []*open_im_sdk.GroupInfo `json:"-"` - Data []map[string]interface{} `json:"data"` + Data []map[string]interface{} `json:"data" swaggerignore:"true"` } //type GroupInfoAlias struct { diff --git a/pkg/base_info/manage_api_struct.go b/pkg/base_info/manage_api_struct.go index f8515dd5b..5c249b3f7 100644 --- a/pkg/base_info/manage_api_struct.go +++ b/pkg/base_info/manage_api_struct.go @@ -39,20 +39,24 @@ type AccountCheckResp struct { ResultList []*pbUser.AccountCheckResp_SingleUserStatus `json:"data"` } +type ManagementSendMsg struct { + OperationID string `json:"operationID" binding:"required"` + SendID string `json:"sendID" binding:"required"` + GroupID string `json:"groupID" ` + SenderNickname string `json:"senderNickname" ` + SenderFaceURL string `json:"senderFaceURL" ` + SenderPlatformID int32 `json:"senderPlatformID"` + //ForceList []string `json:"forceList" ` + Content map[string]interface{} `json:"content" binding:"required" swaggerignore:"true"` + ContentType int32 `json:"contentType" binding:"required"` + SessionType int32 `json:"sessionType" binding:"required"` + IsOnlineOnly bool `json:"isOnlineOnly"` + OfflinePushInfo *open_im_sdk.OfflinePushInfo `json:"offlinePushInfo"` +} + type ManagementSendMsgReq struct { - OperationID string `json:"operationID" binding:"required"` - SendID string `json:"sendID" binding:"required"` - RecvID string `json:"recvID" ` - GroupID string `json:"groupID" ` - SenderNickname string `json:"senderNickname" ` - SenderFaceURL string `json:"senderFaceURL" ` - SenderPlatformID int32 `json:"senderPlatformID"` - ForceList []string `json:"forceList" ` - Content map[string]interface{} `json:"content" binding:"required"` - ContentType int32 `json:"contentType" binding:"required"` - SessionType int32 `json:"sessionType" binding:"required"` - IsOnlineOnly bool `json:"isOnlineOnly"` - OfflinePushInfo *open_im_sdk.OfflinePushInfo `json:"offlinePushInfo"` + ManagementSendMsg + RecvID string `json:"recvID" ` } type ManagementSendMsgResp struct { @@ -61,7 +65,7 @@ type ManagementSendMsgResp struct { } type ManagementBatchSendMsgReq struct { - ManagementSendMsgReq + ManagementSendMsg RecvIDList []string `json:"recvIDList"` } diff --git a/pkg/base_info/swagger_example.go b/pkg/base_info/swagger_example.go new file mode 100644 index 000000000..b56f26276 --- /dev/null +++ b/pkg/base_info/swagger_example.go @@ -0,0 +1,11 @@ +package base_info + +type Swagger400Resp struct { + ErrCode int32 `json:"errCode" example:"400"` + ErrMsg string `json:"errMsg" example:"err msg"` +} + +type Swagger500Resp struct { + ErrCode int32 `json:"errCode" example:"500"` + ErrMsg string `json:"errMsg" example:"err msg"` +} diff --git a/pkg/base_info/third_api_struct.go b/pkg/base_info/third_api_struct.go index e59e03940..72924e873 100644 --- a/pkg/base_info/third_api_struct.go +++ b/pkg/base_info/third_api_struct.go @@ -19,13 +19,20 @@ type MinioUploadFileReq struct { FileType int `form:"fileType" binding:"required"` } -type MinioUploadFileResp struct { +type MinioUploadFile struct { URL string `json:"URL"` NewName string `json:"newName"` SnapshotURL string `json:"snapshotURL,omitempty"` SnapshotNewName string `json:"snapshotName,omitempty"` } +type MinioUploadFileResp struct { + CommResp + Data struct { + MinioUploadFile + } `json:"data"` +} + type UploadUpdateAppReq struct { OperationID string `form:"operationID" binding:"required"` Type int `form:"type" binding:"required"`