mirror of
https://github.com/openimsdk/open-im-server.git
synced 2025-04-06 04:15:46 +08:00
cobra
This commit is contained in:
parent
345bf3a882
commit
9ce50095b5
@ -28,7 +28,7 @@ func run(port int) error {
|
|||||||
if port == 0 {
|
if port == 0 {
|
||||||
port = config.Config.Api.GinPort[0]
|
port = config.Config.Api.GinPort[0]
|
||||||
}
|
}
|
||||||
zk, err := openKeeper.NewClient(config.Config.Zookeeper.ZkAddr, "", 10, "", "")
|
zk, err := openKeeper.NewClient(config.Config.Zookeeper.ZkAddr, "", 10, config.Config.Zookeeper.UserName, config.Config.Zookeeper.Password)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
@ -3,24 +3,24 @@ package api
|
|||||||
import (
|
import (
|
||||||
"OpenIM/internal/api/a2r"
|
"OpenIM/internal/api/a2r"
|
||||||
"OpenIM/pkg/common/config"
|
"OpenIM/pkg/common/config"
|
||||||
|
"OpenIM/pkg/discoveryregistry"
|
||||||
auth "OpenIM/pkg/proto/auth"
|
auth "OpenIM/pkg/proto/auth"
|
||||||
"context"
|
"context"
|
||||||
"github.com/OpenIMSDK/openKeeper"
|
|
||||||
"github.com/gin-gonic/gin"
|
"github.com/gin-gonic/gin"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ context.Context // 解决goland编辑器bug
|
var _ context.Context // 解决goland编辑器bug
|
||||||
|
|
||||||
func NewAuth(zk *openKeeper.ZkClient) *Auth {
|
func NewAuth(c discoveryregistry.SvcDiscoveryRegistry) *Auth {
|
||||||
return &Auth{zk: zk}
|
return &Auth{c: c}
|
||||||
}
|
}
|
||||||
|
|
||||||
type Auth struct {
|
type Auth struct {
|
||||||
zk *openKeeper.ZkClient
|
c discoveryregistry.SvcDiscoveryRegistry
|
||||||
}
|
}
|
||||||
|
|
||||||
func (o *Auth) client() (auth.AuthClient, error) {
|
func (o *Auth) client() (auth.AuthClient, error) {
|
||||||
conn, err := o.zk.GetConn(config.Config.RpcRegisterName.OpenImAuthName)
|
conn, err := o.c.GetConn(config.Config.RpcRegisterName.OpenImAuthName)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
@ -3,24 +3,24 @@ package api
|
|||||||
import (
|
import (
|
||||||
"OpenIM/internal/api/a2r"
|
"OpenIM/internal/api/a2r"
|
||||||
"OpenIM/pkg/common/config"
|
"OpenIM/pkg/common/config"
|
||||||
|
"OpenIM/pkg/discoveryregistry"
|
||||||
"OpenIM/pkg/proto/conversation"
|
"OpenIM/pkg/proto/conversation"
|
||||||
"context"
|
"context"
|
||||||
"github.com/OpenIMSDK/openKeeper"
|
|
||||||
"github.com/gin-gonic/gin"
|
"github.com/gin-gonic/gin"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ context.Context // 解决goland编辑器bug
|
var _ context.Context // 解决goland编辑器bug
|
||||||
|
|
||||||
func NewConversation(zk *openKeeper.ZkClient) *Conversation {
|
func NewConversation(c discoveryregistry.SvcDiscoveryRegistry) *Conversation {
|
||||||
return &Conversation{zk: zk}
|
return &Conversation{c: c}
|
||||||
}
|
}
|
||||||
|
|
||||||
type Conversation struct {
|
type Conversation struct {
|
||||||
zk *openKeeper.ZkClient
|
c discoveryregistry.SvcDiscoveryRegistry
|
||||||
}
|
}
|
||||||
|
|
||||||
func (o *Conversation) client() (conversation.ConversationClient, error) {
|
func (o *Conversation) client() (conversation.ConversationClient, error) {
|
||||||
conn, err := o.zk.GetConn(config.Config.RpcRegisterName.OpenImConversationName)
|
conn, err := o.c.GetConn(config.Config.RpcRegisterName.OpenImConversationName)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
@ -3,24 +3,25 @@ package api
|
|||||||
import (
|
import (
|
||||||
"OpenIM/internal/api/a2r"
|
"OpenIM/internal/api/a2r"
|
||||||
"OpenIM/pkg/common/config"
|
"OpenIM/pkg/common/config"
|
||||||
|
"OpenIM/pkg/discoveryregistry"
|
||||||
"OpenIM/pkg/proto/friend"
|
"OpenIM/pkg/proto/friend"
|
||||||
"context"
|
"context"
|
||||||
"github.com/OpenIMSDK/openKeeper"
|
|
||||||
"github.com/gin-gonic/gin"
|
"github.com/gin-gonic/gin"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ context.Context // 解决goland编辑器bug
|
var _ context.Context // 解决goland编辑器bug
|
||||||
|
|
||||||
func NewFriend(zk *openKeeper.ZkClient) *Friend {
|
func NewFriend(c discoveryregistry.SvcDiscoveryRegistry) *Friend {
|
||||||
return &Friend{zk: zk}
|
return &Friend{c: c}
|
||||||
}
|
}
|
||||||
|
|
||||||
type Friend struct {
|
type Friend struct {
|
||||||
zk *openKeeper.ZkClient
|
c discoveryregistry.SvcDiscoveryRegistry
|
||||||
}
|
}
|
||||||
|
|
||||||
func (o *Friend) client() (friend.FriendClient, error) {
|
func (o *Friend) client() (friend.FriendClient, error) {
|
||||||
conn, err := o.zk.GetConn(config.Config.RpcRegisterName.OpenImFriendName)
|
conn, err := o.c.GetConn(config.Config.RpcRegisterName.OpenImFriendName)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
@ -3,24 +3,25 @@ package api
|
|||||||
import (
|
import (
|
||||||
"OpenIM/internal/api/a2r"
|
"OpenIM/internal/api/a2r"
|
||||||
"OpenIM/pkg/common/config"
|
"OpenIM/pkg/common/config"
|
||||||
|
"OpenIM/pkg/discoveryregistry"
|
||||||
"OpenIM/pkg/proto/group"
|
"OpenIM/pkg/proto/group"
|
||||||
"context"
|
"context"
|
||||||
"github.com/OpenIMSDK/openKeeper"
|
|
||||||
"github.com/gin-gonic/gin"
|
"github.com/gin-gonic/gin"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ context.Context // 解决goland编辑器bug
|
var _ context.Context // 解决goland编辑器bug
|
||||||
|
|
||||||
func NewGroup(zk *openKeeper.ZkClient) *Group {
|
func NewGroup(c discoveryregistry.SvcDiscoveryRegistry) *Group {
|
||||||
return &Group{zk: zk}
|
return &Group{c: c}
|
||||||
}
|
}
|
||||||
|
|
||||||
type Group struct {
|
type Group struct {
|
||||||
zk *openKeeper.ZkClient
|
c discoveryregistry.SvcDiscoveryRegistry
|
||||||
}
|
}
|
||||||
|
|
||||||
func (o *Group) client() (group.GroupClient, error) {
|
func (o *Group) client() (group.GroupClient, error) {
|
||||||
conn, err := o.zk.GetConn(config.Config.RpcRegisterName.OpenImGroupName)
|
conn, err := o.c.GetConn(config.Config.RpcRegisterName.OpenImGroupName)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
@ -7,13 +7,13 @@ import (
|
|||||||
"OpenIM/pkg/common/config"
|
"OpenIM/pkg/common/config"
|
||||||
"OpenIM/pkg/common/constant"
|
"OpenIM/pkg/common/constant"
|
||||||
"OpenIM/pkg/common/log"
|
"OpenIM/pkg/common/log"
|
||||||
|
"OpenIM/pkg/discoveryregistry"
|
||||||
"OpenIM/pkg/errs"
|
"OpenIM/pkg/errs"
|
||||||
"OpenIM/pkg/proto/msg"
|
"OpenIM/pkg/proto/msg"
|
||||||
"OpenIM/pkg/proto/sdkws"
|
"OpenIM/pkg/proto/sdkws"
|
||||||
"OpenIM/pkg/utils"
|
"OpenIM/pkg/utils"
|
||||||
"context"
|
"context"
|
||||||
"errors"
|
"errors"
|
||||||
"github.com/OpenIMSDK/openKeeper"
|
|
||||||
"github.com/gin-gonic/gin"
|
"github.com/gin-gonic/gin"
|
||||||
"github.com/go-playground/validator/v10"
|
"github.com/go-playground/validator/v10"
|
||||||
"github.com/golang/protobuf/proto"
|
"github.com/golang/protobuf/proto"
|
||||||
@ -22,12 +22,12 @@ import (
|
|||||||
|
|
||||||
var _ context.Context // 解决goland编辑器bug
|
var _ context.Context // 解决goland编辑器bug
|
||||||
|
|
||||||
func NewMsg(zk *openKeeper.ZkClient) *Msg {
|
func NewMsg(c discoveryregistry.SvcDiscoveryRegistry) *Msg {
|
||||||
return &Msg{zk: zk, validate: validator.New()}
|
return &Msg{c: c, validate: validator.New()}
|
||||||
}
|
}
|
||||||
|
|
||||||
type Msg struct {
|
type Msg struct {
|
||||||
zk *openKeeper.ZkClient
|
c discoveryregistry.SvcDiscoveryRegistry
|
||||||
validate *validator.Validate
|
validate *validator.Validate
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -107,7 +107,7 @@ func newUserSendMsgReq(params *apistruct.ManagementSendMsgReq) *msg.SendMsgReq {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (o *Msg) client() (msg.MsgClient, error) {
|
func (o *Msg) client() (msg.MsgClient, error) {
|
||||||
conn, err := o.zk.GetConn(config.Config.RpcRegisterName.OpenImMsgName)
|
conn, err := o.c.GetConn(config.Config.RpcRegisterName.OpenImMsgName)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
@ -214,7 +214,7 @@ func (o *Msg) ManagementSendMsg(c *gin.Context) {
|
|||||||
}
|
}
|
||||||
log.NewInfo(params.OperationID, "Ws call success to ManagementSendMsgReq", params)
|
log.NewInfo(params.OperationID, "Ws call success to ManagementSendMsgReq", params)
|
||||||
pbData := newUserSendMsgReq(¶ms)
|
pbData := newUserSendMsgReq(¶ms)
|
||||||
conn, err := o.zk.GetConn(config.Config.RpcRegisterName.OpenImMsgName)
|
conn, err := o.c.GetConn(config.Config.RpcRegisterName.OpenImMsgName)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
apiresp.GinError(c, errs.ErrInternalServer)
|
apiresp.GinError(c, errs.ErrInternalServer)
|
||||||
return
|
return
|
||||||
|
@ -5,13 +5,13 @@ import (
|
|||||||
"OpenIM/pkg/common/log"
|
"OpenIM/pkg/common/log"
|
||||||
"OpenIM/pkg/common/mw"
|
"OpenIM/pkg/common/mw"
|
||||||
"OpenIM/pkg/common/prome"
|
"OpenIM/pkg/common/prome"
|
||||||
"github.com/OpenIMSDK/openKeeper"
|
"OpenIM/pkg/discoveryregistry"
|
||||||
"github.com/gin-gonic/gin"
|
"github.com/gin-gonic/gin"
|
||||||
"io"
|
"io"
|
||||||
"os"
|
"os"
|
||||||
)
|
)
|
||||||
|
|
||||||
func NewGinRouter(zk *openKeeper.ZkClient) *gin.Engine {
|
func NewGinRouter(zk discoveryregistry.SvcDiscoveryRegistry) *gin.Engine {
|
||||||
gin.SetMode(gin.ReleaseMode)
|
gin.SetMode(gin.ReleaseMode)
|
||||||
f, _ := os.Create("../logs/api.log")
|
f, _ := os.Create("../logs/api.log")
|
||||||
gin.DefaultWriter = io.MultiWriter(f)
|
gin.DefaultWriter = io.MultiWriter(f)
|
||||||
@ -27,7 +27,6 @@ func NewGinRouter(zk *openKeeper.ZkClient) *gin.Engine {
|
|||||||
r.GET("/metrics", prome.PrometheusHandler())
|
r.GET("/metrics", prome.PrometheusHandler())
|
||||||
}
|
}
|
||||||
zk.AddOption(mw.GrpcClient()) // 默认RPC中间件
|
zk.AddOption(mw.GrpcClient()) // 默认RPC中间件
|
||||||
|
|
||||||
userRouterGroup := r.Group("/user")
|
userRouterGroup := r.Group("/user")
|
||||||
{
|
{
|
||||||
u := NewUser(zk)
|
u := NewUser(zk)
|
||||||
|
@ -3,24 +3,25 @@ package api
|
|||||||
import (
|
import (
|
||||||
"OpenIM/internal/api/a2r"
|
"OpenIM/internal/api/a2r"
|
||||||
"OpenIM/pkg/common/config"
|
"OpenIM/pkg/common/config"
|
||||||
|
"OpenIM/pkg/discoveryregistry"
|
||||||
"OpenIM/pkg/proto/third"
|
"OpenIM/pkg/proto/third"
|
||||||
"context"
|
"context"
|
||||||
"github.com/OpenIMSDK/openKeeper"
|
|
||||||
"github.com/gin-gonic/gin"
|
"github.com/gin-gonic/gin"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ context.Context // 解决goland编辑器bug
|
var _ context.Context // 解决goland编辑器bug
|
||||||
|
|
||||||
func NewThird(zk *openKeeper.ZkClient) *Third {
|
func NewThird(c discoveryregistry.SvcDiscoveryRegistry) *Third {
|
||||||
return &Third{zk: zk}
|
return &Third{c: c}
|
||||||
}
|
}
|
||||||
|
|
||||||
type Third struct {
|
type Third struct {
|
||||||
zk *openKeeper.ZkClient
|
c discoveryregistry.SvcDiscoveryRegistry
|
||||||
}
|
}
|
||||||
|
|
||||||
func (o *Third) client() (third.ThirdClient, error) {
|
func (o *Third) client() (third.ThirdClient, error) {
|
||||||
conn, err := o.zk.GetConn(config.Config.RpcRegisterName.OpenImThirdName)
|
conn, err := o.c.GetConn(config.Config.RpcRegisterName.OpenImThirdName)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
@ -3,24 +3,24 @@ package api
|
|||||||
import (
|
import (
|
||||||
"OpenIM/internal/api/a2r"
|
"OpenIM/internal/api/a2r"
|
||||||
"OpenIM/pkg/common/config"
|
"OpenIM/pkg/common/config"
|
||||||
|
"OpenIM/pkg/discoveryregistry"
|
||||||
"OpenIM/pkg/proto/user"
|
"OpenIM/pkg/proto/user"
|
||||||
"context"
|
"context"
|
||||||
"github.com/OpenIMSDK/openKeeper"
|
|
||||||
"github.com/gin-gonic/gin"
|
"github.com/gin-gonic/gin"
|
||||||
)
|
)
|
||||||
|
|
||||||
var _ context.Context // 解决goland编辑器bug
|
var _ context.Context // 解决goland编辑器bug
|
||||||
|
|
||||||
func NewUser(zk *openKeeper.ZkClient) *User {
|
func NewUser(client discoveryregistry.SvcDiscoveryRegistry) *User {
|
||||||
return &User{zk: zk}
|
return &User{c: client}
|
||||||
}
|
}
|
||||||
|
|
||||||
type User struct {
|
type User struct {
|
||||||
zk *openKeeper.ZkClient
|
c discoveryregistry.SvcDiscoveryRegistry
|
||||||
}
|
}
|
||||||
|
|
||||||
func (o *User) client() (user.UserClient, error) {
|
func (o *User) client() (user.UserClient, error) {
|
||||||
conn, err := o.zk.GetConn(config.Config.RpcRegisterName.OpenImUserName)
|
conn, err := o.c.GetConn(config.Config.RpcRegisterName.OpenImUserName)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,6 @@ type UserTokenInfo struct {
|
|||||||
ExpiredTime int64 `json:"expiredTime"`
|
ExpiredTime int64 `json:"expiredTime"`
|
||||||
}
|
}
|
||||||
type UserRegisterResp struct {
|
type UserRegisterResp struct {
|
||||||
CommResp
|
|
||||||
UserToken UserTokenInfo `json:"data"`
|
UserToken UserTokenInfo `json:"data"`
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -25,7 +24,6 @@ type UserTokenReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type UserTokenResp struct {
|
type UserTokenResp struct {
|
||||||
CommResp
|
|
||||||
UserToken UserTokenInfo `json:"data"`
|
UserToken UserTokenInfo `json:"data"`
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -36,7 +34,6 @@ type ForceLogoutReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type ForceLogoutResp struct {
|
type ForceLogoutResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type ParseTokenReq struct {
|
type ParseTokenReq struct {
|
||||||
@ -44,7 +41,7 @@ type ParseTokenReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
//type ParseTokenResp struct {
|
//type ParseTokenResp struct {
|
||||||
// CommResp
|
//
|
||||||
// ExpireTime int64 `json:"expireTime" binding:"required"`
|
// ExpireTime int64 `json:"expireTime" binding:"required"`
|
||||||
//}
|
//}
|
||||||
|
|
||||||
@ -53,7 +50,6 @@ type ExpireTime struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type ParseTokenResp struct {
|
type ParseTokenResp struct {
|
||||||
CommResp
|
|
||||||
Data map[string]interface{} `json:"data" swaggerignore:"true"`
|
Data map[string]interface{} `json:"data" swaggerignore:"true"`
|
||||||
ExpireTime ExpireTime `json:"-"`
|
ExpireTime ExpireTime `json:"-"`
|
||||||
}
|
}
|
||||||
|
@ -14,7 +14,6 @@ type AwsStorageCredentialRespData struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type AwsStorageCredentialResp struct {
|
type AwsStorageCredentialResp struct {
|
||||||
CommResp
|
|
||||||
CosData AwsStorageCredentialRespData
|
CosData AwsStorageCredentialRespData
|
||||||
Data map[string]interface{} `json:"data"`
|
Data map[string]interface{} `json:"data"`
|
||||||
}
|
}
|
||||||
|
@ -1,6 +0,0 @@
|
|||||||
package apistruct
|
|
||||||
|
|
||||||
type RequestPagination struct {
|
|
||||||
PageNumber int `json:"pageNumber" binding:"required"`
|
|
||||||
ShowNumber int `json:"showNumber" binding:"required"`
|
|
||||||
}
|
|
@ -9,7 +9,6 @@ type GetAllConversationMessageOptReq struct {
|
|||||||
FromUserID string `json:"fromUserID" binding:"required"`
|
FromUserID string `json:"fromUserID" binding:"required"`
|
||||||
}
|
}
|
||||||
type GetAllConversationMessageOptResp struct {
|
type GetAllConversationMessageOptResp struct {
|
||||||
CommResp
|
|
||||||
ConversationOptResultList []*OptResult `json:"data"`
|
ConversationOptResultList []*OptResult `json:"data"`
|
||||||
}
|
}
|
||||||
type GetReceiveMessageOptReq struct {
|
type GetReceiveMessageOptReq struct {
|
||||||
@ -18,7 +17,6 @@ type GetReceiveMessageOptReq struct {
|
|||||||
FromUserID string `json:"fromUserID" binding:"required"`
|
FromUserID string `json:"fromUserID" binding:"required"`
|
||||||
}
|
}
|
||||||
type GetReceiveMessageOptResp struct {
|
type GetReceiveMessageOptResp struct {
|
||||||
CommResp
|
|
||||||
ConversationOptResultList []*OptResult `json:"data"`
|
ConversationOptResultList []*OptResult `json:"data"`
|
||||||
}
|
}
|
||||||
type SetReceiveMessageOptReq struct {
|
type SetReceiveMessageOptReq struct {
|
||||||
@ -28,7 +26,6 @@ type SetReceiveMessageOptReq struct {
|
|||||||
ConversationIDList []string `json:"conversationIDList" binding:"required"`
|
ConversationIDList []string `json:"conversationIDList" binding:"required"`
|
||||||
}
|
}
|
||||||
type SetReceiveMessageOptResp struct {
|
type SetReceiveMessageOptResp struct {
|
||||||
CommResp
|
|
||||||
ConversationOptResultList []*OptResult `json:"data"`
|
ConversationOptResultList []*OptResult `json:"data"`
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -58,7 +55,6 @@ type SetConversationReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type SetConversationResp struct {
|
type SetConversationResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
type ModifyConversationFieldReq struct {
|
type ModifyConversationFieldReq struct {
|
||||||
Conversation
|
Conversation
|
||||||
@ -67,7 +63,6 @@ type ModifyConversationFieldReq struct {
|
|||||||
OperationID string `json:"operationID" binding:"required"`
|
OperationID string `json:"operationID" binding:"required"`
|
||||||
}
|
}
|
||||||
type ModifyConversationFieldResp struct {
|
type ModifyConversationFieldResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type BatchSetConversationsReq struct {
|
type BatchSetConversationsReq struct {
|
||||||
@ -78,7 +73,6 @@ type BatchSetConversationsReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type BatchSetConversationsResp struct {
|
type BatchSetConversationsResp struct {
|
||||||
CommResp
|
|
||||||
Data struct {
|
Data struct {
|
||||||
Success []string `json:"success"`
|
Success []string `json:"success"`
|
||||||
Failed []string `json:"failed"`
|
Failed []string `json:"failed"`
|
||||||
@ -92,7 +86,6 @@ type GetConversationReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type GetConversationResp struct {
|
type GetConversationResp struct {
|
||||||
CommResp
|
|
||||||
Conversation Conversation `json:"data"`
|
Conversation Conversation `json:"data"`
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -102,7 +95,6 @@ type GetAllConversationsReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type GetAllConversationsResp struct {
|
type GetAllConversationsResp struct {
|
||||||
CommResp
|
|
||||||
Conversations []Conversation `json:"data"`
|
Conversations []Conversation `json:"data"`
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -113,7 +105,6 @@ type GetConversationsReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type GetConversationsResp struct {
|
type GetConversationsResp struct {
|
||||||
CommResp
|
|
||||||
Conversations []Conversation `json:"data"`
|
Conversations []Conversation `json:"data"`
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -126,5 +117,4 @@ type SetRecvMsgOptReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type SetRecvMsgOptResp struct {
|
type SetRecvMsgOptResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,6 @@ type TencentCloudStorageCredentialRespData struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type TencentCloudStorageCredentialResp struct {
|
type TencentCloudStorageCredentialResp struct {
|
||||||
CommResp
|
|
||||||
CosData TencentCloudStorageCredentialRespData `json:"-"`
|
CosData TencentCloudStorageCredentialRespData `json:"-"`
|
||||||
|
|
||||||
Data map[string]interface{} `json:"data"`
|
Data map[string]interface{} `json:"data"`
|
||||||
|
@ -10,7 +10,7 @@ package apistruct
|
|||||||
// ParamsCommFriend
|
// ParamsCommFriend
|
||||||
//}
|
//}
|
||||||
//type AddBlacklistResp struct {
|
//type AddBlacklistResp struct {
|
||||||
// CommResp
|
//
|
||||||
//}
|
//}
|
||||||
//
|
//
|
||||||
//type ImportFriendReq struct {
|
//type ImportFriendReq struct {
|
||||||
@ -23,7 +23,7 @@ package apistruct
|
|||||||
// Result int32 `json:"result"`
|
// Result int32 `json:"result"`
|
||||||
//}
|
//}
|
||||||
//type ImportFriendResp struct {
|
//type ImportFriendResp struct {
|
||||||
// CommResp
|
//
|
||||||
// UserIDResultList []UserIDResult `json:"data"`
|
// UserIDResultList []UserIDResult `json:"data"`
|
||||||
//}
|
//}
|
||||||
//
|
//
|
||||||
@ -32,7 +32,7 @@ package apistruct
|
|||||||
// ReqMsg string `json:"reqMsg"`
|
// ReqMsg string `json:"reqMsg"`
|
||||||
//}
|
//}
|
||||||
//type AddFriendResp struct {
|
//type AddFriendResp struct {
|
||||||
// CommResp
|
//
|
||||||
//}
|
//}
|
||||||
//
|
//
|
||||||
//type AddFriendResponseReq struct {
|
//type AddFriendResponseReq struct {
|
||||||
@ -41,14 +41,14 @@ package apistruct
|
|||||||
// HandleMsg string `json:"handleMsg"`
|
// HandleMsg string `json:"handleMsg"`
|
||||||
//}
|
//}
|
||||||
//type AddFriendResponseResp struct {
|
//type AddFriendResponseResp struct {
|
||||||
// CommResp
|
//
|
||||||
//}
|
//}
|
||||||
//
|
//
|
||||||
//type DeleteFriendReq struct {
|
//type DeleteFriendReq struct {
|
||||||
// ParamsCommFriend
|
// ParamsCommFriend
|
||||||
//}
|
//}
|
||||||
//type DeleteFriendResp struct {
|
//type DeleteFriendResp struct {
|
||||||
// CommResp
|
//
|
||||||
//}
|
//}
|
||||||
//
|
//
|
||||||
//type GetBlackListReq struct {
|
//type GetBlackListReq struct {
|
||||||
@ -56,7 +56,7 @@ package apistruct
|
|||||||
// FromUserID string `json:"fromUserID" binding:"required"`
|
// FromUserID string `json:"fromUserID" binding:"required"`
|
||||||
//}
|
//}
|
||||||
//type GetBlackListResp struct {
|
//type GetBlackListResp struct {
|
||||||
// CommResp
|
//
|
||||||
// BlackUserInfoList []*sdkws.PublicUserInfo `json:"-"`
|
// BlackUserInfoList []*sdkws.PublicUserInfo `json:"-"`
|
||||||
// Map []map[string]interface{} `json:"data" swaggerignore:"true"`
|
// Map []map[string]interface{} `json:"data" swaggerignore:"true"`
|
||||||
//}
|
//}
|
||||||
@ -73,14 +73,14 @@ package apistruct
|
|||||||
// Remark string `json:"remark"`
|
// Remark string `json:"remark"`
|
||||||
//}
|
//}
|
||||||
//type SetFriendRemarkResp struct {
|
//type SetFriendRemarkResp struct {
|
||||||
// CommResp
|
//
|
||||||
//}
|
//}
|
||||||
//
|
//
|
||||||
//type RemoveBlacklistReq struct {
|
//type RemoveBlacklistReq struct {
|
||||||
// ParamsCommFriend
|
// ParamsCommFriend
|
||||||
//}
|
//}
|
||||||
//type RemoveBlacklistResp struct {
|
//type RemoveBlacklistResp struct {
|
||||||
// CommResp
|
//
|
||||||
//}
|
//}
|
||||||
//
|
//
|
||||||
//type IsFriendReq struct {
|
//type IsFriendReq struct {
|
||||||
@ -90,7 +90,7 @@ package apistruct
|
|||||||
// Friend bool `json:"isFriend"`
|
// Friend bool `json:"isFriend"`
|
||||||
//}
|
//}
|
||||||
//type IsFriendResp struct {
|
//type IsFriendResp struct {
|
||||||
// CommResp
|
//
|
||||||
// Response Response `json:"data"`
|
// Response Response `json:"data"`
|
||||||
//}
|
//}
|
||||||
//
|
//
|
||||||
@ -98,7 +98,7 @@ package apistruct
|
|||||||
// ParamsCommFriend
|
// ParamsCommFriend
|
||||||
//}
|
//}
|
||||||
//type GetFriendsInfoResp struct {
|
//type GetFriendsInfoResp struct {
|
||||||
// CommResp
|
//
|
||||||
// FriendInfoList []*sdkws.FriendInfo `json:"-"`
|
// FriendInfoList []*sdkws.FriendInfo `json:"-"`
|
||||||
// Map []map[string]interface{} `json:"data" swaggerignore:"true"`
|
// Map []map[string]interface{} `json:"data" swaggerignore:"true"`
|
||||||
//}
|
//}
|
||||||
@ -108,7 +108,7 @@ package apistruct
|
|||||||
// FromUserID string `json:"fromUserID" binding:"required"`
|
// FromUserID string `json:"fromUserID" binding:"required"`
|
||||||
//}
|
//}
|
||||||
//type GetFriendListResp struct {
|
//type GetFriendListResp struct {
|
||||||
// CommResp
|
//
|
||||||
// FriendInfoList []*sdkws.FriendInfo `json:"-"`
|
// FriendInfoList []*sdkws.FriendInfo `json:"-"`
|
||||||
// Map []map[string]interface{} `json:"data" swaggerignore:"true"`
|
// Map []map[string]interface{} `json:"data" swaggerignore:"true"`
|
||||||
//}
|
//}
|
||||||
@ -118,7 +118,7 @@ package apistruct
|
|||||||
// FromUserID string `json:"fromUserID" binding:"required"`
|
// FromUserID string `json:"fromUserID" binding:"required"`
|
||||||
//}
|
//}
|
||||||
//type GetFriendApplyListResp struct {
|
//type GetFriendApplyListResp struct {
|
||||||
// CommResp
|
//
|
||||||
// FriendRequestList []*sdkws.FriendRequest `json:"-"`
|
// FriendRequestList []*sdkws.FriendRequest `json:"-"`
|
||||||
// Map []map[string]interface{} `json:"data" swaggerignore:"true"`
|
// Map []map[string]interface{} `json:"data" swaggerignore:"true"`
|
||||||
//}
|
//}
|
||||||
@ -128,7 +128,7 @@ package apistruct
|
|||||||
// FromUserID string `json:"fromUserID" binding:"required"`
|
// FromUserID string `json:"fromUserID" binding:"required"`
|
||||||
//}
|
//}
|
||||||
//type GetSelfApplyListResp struct {
|
//type GetSelfApplyListResp struct {
|
||||||
// CommResp
|
//
|
||||||
// FriendRequestList []*sdkws.FriendRequest `json:"-"`
|
// FriendRequestList []*sdkws.FriendRequest `json:"-"`
|
||||||
// Map []map[string]interface{} `json:"data" swaggerignore:"true"`
|
// Map []map[string]interface{} `json:"data" swaggerignore:"true"`
|
||||||
//}
|
//}
|
||||||
@ -180,7 +180,7 @@ type ImportFriendReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type ImportFriendResp struct {
|
type ImportFriendResp struct {
|
||||||
//CommResp
|
//
|
||||||
}
|
}
|
||||||
|
|
||||||
type AddFriendReq struct {
|
type AddFriendReq struct {
|
||||||
@ -189,7 +189,7 @@ type AddFriendReq struct {
|
|||||||
ReqMsg string `json:"reqMsg"`
|
ReqMsg string `json:"reqMsg"`
|
||||||
}
|
}
|
||||||
type AddFriendResp struct {
|
type AddFriendResp struct {
|
||||||
//CommResp
|
//
|
||||||
}
|
}
|
||||||
|
|
||||||
type AddFriendResponseReq struct {
|
type AddFriendResponseReq struct {
|
||||||
|
@ -4,13 +4,13 @@ import (
|
|||||||
sdkws "OpenIM/pkg/proto/sdkws"
|
sdkws "OpenIM/pkg/proto/sdkws"
|
||||||
)
|
)
|
||||||
|
|
||||||
type CommResp struct {
|
type struct {
|
||||||
ErrCode int32 `json:"errCode"`
|
ErrCode int32 `json:"errCode"`
|
||||||
ErrMsg string `json:"errMsg"`
|
ErrMsg string `json:"errMsg"`
|
||||||
}
|
}
|
||||||
|
|
||||||
type CommDataResp struct {
|
type CommDataResp struct {
|
||||||
CommResp
|
|
||||||
Data []map[string]interface{} `json:"data"`
|
Data []map[string]interface{} `json:"data"`
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -21,7 +21,7 @@ type KickGroupMemberReq struct {
|
|||||||
OperationID string `json:"operationID" binding:"required"`
|
OperationID string `json:"operationID" binding:"required"`
|
||||||
}
|
}
|
||||||
type KickGroupMemberResp struct {
|
type KickGroupMemberResp struct {
|
||||||
CommResp
|
|
||||||
//UserIDResultList []*UserIDResult `json:"data"`
|
//UserIDResultList []*UserIDResult `json:"data"`
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -31,7 +31,7 @@ type GetGroupMembersInfoReq struct {
|
|||||||
OperationID string `json:"operationID" binding:"required"`
|
OperationID string `json:"operationID" binding:"required"`
|
||||||
}
|
}
|
||||||
type GetGroupMembersInfoResp struct {
|
type GetGroupMembersInfoResp struct {
|
||||||
CommResp
|
|
||||||
MemberList []*sdkws.GroupMemberFullInfo `json:"-"`
|
MemberList []*sdkws.GroupMemberFullInfo `json:"-"`
|
||||||
Data []map[string]interface{} `json:"data" swaggerignore:"true"`
|
Data []map[string]interface{} `json:"data" swaggerignore:"true"`
|
||||||
}
|
}
|
||||||
@ -43,7 +43,7 @@ type InviteUserToGroupReq struct {
|
|||||||
OperationID string `json:"operationID" binding:"required"`
|
OperationID string `json:"operationID" binding:"required"`
|
||||||
}
|
}
|
||||||
type InviteUserToGroupResp struct {
|
type InviteUserToGroupResp struct {
|
||||||
CommResp
|
|
||||||
//UserIDResultList []*UserIDResult `json:"data"`
|
//UserIDResultList []*UserIDResult `json:"data"`
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -52,7 +52,7 @@ type GetJoinedGroupListReq struct {
|
|||||||
FromUserID string `json:"fromUserID" binding:"required"`
|
FromUserID string `json:"fromUserID" binding:"required"`
|
||||||
}
|
}
|
||||||
type GetJoinedGroupListResp struct {
|
type GetJoinedGroupListResp struct {
|
||||||
CommResp
|
|
||||||
GroupInfoList []*sdkws.GroupInfo `json:"-"`
|
GroupInfoList []*sdkws.GroupInfo `json:"-"`
|
||||||
Data []map[string]interface{} `json:"data" swaggerignore:"true"`
|
Data []map[string]interface{} `json:"data" swaggerignore:"true"`
|
||||||
}
|
}
|
||||||
@ -64,7 +64,7 @@ type GetGroupMemberListReq struct {
|
|||||||
OperationID string `json:"operationID"`
|
OperationID string `json:"operationID"`
|
||||||
}
|
}
|
||||||
type GetGroupMemberListResp struct {
|
type GetGroupMemberListResp struct {
|
||||||
CommResp
|
|
||||||
NextSeq int32 `json:"nextSeq"`
|
NextSeq int32 `json:"nextSeq"`
|
||||||
MemberList []*sdkws.GroupMemberFullInfo `json:"-"`
|
MemberList []*sdkws.GroupMemberFullInfo `json:"-"`
|
||||||
Data []map[string]interface{} `json:"data" swaggerignore:"true"`
|
Data []map[string]interface{} `json:"data" swaggerignore:"true"`
|
||||||
@ -77,7 +77,7 @@ type GetGroupAllMemberReq struct {
|
|||||||
Count int32 `json:"count"`
|
Count int32 `json:"count"`
|
||||||
}
|
}
|
||||||
type GetGroupAllMemberResp struct {
|
type GetGroupAllMemberResp struct {
|
||||||
CommResp
|
|
||||||
MemberList []*sdkws.GroupMemberFullInfo `json:"-"`
|
MemberList []*sdkws.GroupMemberFullInfo `json:"-"`
|
||||||
Data []map[string]interface{} `json:"data" swaggerignore:"true"`
|
Data []map[string]interface{} `json:"data" swaggerignore:"true"`
|
||||||
}
|
}
|
||||||
@ -90,7 +90,7 @@ type GetGroupAllMemberResp struct {
|
|||||||
// Count int32 `json:"count" binding:"required"`
|
// Count int32 `json:"count" binding:"required"`
|
||||||
//}
|
//}
|
||||||
//type GetGroupAllMemberListBySplitResp struct {
|
//type GetGroupAllMemberListBySplitResp struct {
|
||||||
// CommResp
|
//
|
||||||
// MemberList []*sdkws.GroupMemberFullInfo `json:"-"`
|
// MemberList []*sdkws.GroupMemberFullInfo `json:"-"`
|
||||||
// Map []map[string]interface{} `json:"data" swaggerignore:"true"`
|
// Map []map[string]interface{} `json:"data" swaggerignore:"true"`
|
||||||
//}
|
//}
|
||||||
@ -108,7 +108,7 @@ type CreateGroupReq struct {
|
|||||||
GroupID string `json:"groupID"`
|
GroupID string `json:"groupID"`
|
||||||
}
|
}
|
||||||
type CreateGroupResp struct {
|
type CreateGroupResp struct {
|
||||||
CommResp
|
|
||||||
GroupInfo sdkws.GroupInfo `json:"-"`
|
GroupInfo sdkws.GroupInfo `json:"-"`
|
||||||
Data map[string]interface{} `json:"data" swaggerignore:"true"`
|
Data map[string]interface{} `json:"data" swaggerignore:"true"`
|
||||||
}
|
}
|
||||||
@ -118,7 +118,7 @@ type GetGroupApplicationListReq struct {
|
|||||||
FromUserID string `json:"fromUserID" binding:"required"` //作为管理员或群主收到的 进群申请
|
FromUserID string `json:"fromUserID" binding:"required"` //作为管理员或群主收到的 进群申请
|
||||||
}
|
}
|
||||||
type GetGroupApplicationListResp struct {
|
type GetGroupApplicationListResp struct {
|
||||||
CommResp
|
|
||||||
GroupRequestList []*sdkws.GroupRequest `json:"-"`
|
GroupRequestList []*sdkws.GroupRequest `json:"-"`
|
||||||
Data []map[string]interface{} `json:"data" swaggerignore:"true"`
|
Data []map[string]interface{} `json:"data" swaggerignore:"true"`
|
||||||
}
|
}
|
||||||
@ -137,7 +137,7 @@ type GetGroupInfoReq struct {
|
|||||||
OperationID string `json:"operationID" binding:"required"`
|
OperationID string `json:"operationID" binding:"required"`
|
||||||
}
|
}
|
||||||
type GetGroupInfoResp struct {
|
type GetGroupInfoResp struct {
|
||||||
CommResp
|
|
||||||
GroupInfoList []*sdkws.GroupInfo `json:"-"`
|
GroupInfoList []*sdkws.GroupInfo `json:"-"`
|
||||||
Data []map[string]interface{} `json:"data" swaggerignore:"true"`
|
Data []map[string]interface{} `json:"data" swaggerignore:"true"`
|
||||||
}
|
}
|
||||||
@ -171,7 +171,7 @@ type ApplicationGroupResponseReq struct {
|
|||||||
HandleResult int32 `json:"handleResult" binding:"required,oneof=-1 1"`
|
HandleResult int32 `json:"handleResult" binding:"required,oneof=-1 1"`
|
||||||
}
|
}
|
||||||
type ApplicationGroupResponseResp struct {
|
type ApplicationGroupResponseResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type JoinGroupReq struct {
|
type JoinGroupReq struct {
|
||||||
@ -183,7 +183,7 @@ type JoinGroupReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type JoinGroupResp struct {
|
type JoinGroupResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type QuitGroupReq struct {
|
type QuitGroupReq struct {
|
||||||
@ -191,7 +191,7 @@ type QuitGroupReq struct {
|
|||||||
OperationID string `json:"operationID" binding:"required"`
|
OperationID string `json:"operationID" binding:"required"`
|
||||||
}
|
}
|
||||||
type QuitGroupResp struct {
|
type QuitGroupResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type SetGroupInfoReq struct {
|
type SetGroupInfoReq struct {
|
||||||
@ -208,7 +208,7 @@ type SetGroupInfoReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type SetGroupInfoResp struct {
|
type SetGroupInfoResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type TransferGroupOwnerReq struct {
|
type TransferGroupOwnerReq struct {
|
||||||
@ -218,7 +218,7 @@ type TransferGroupOwnerReq struct {
|
|||||||
OperationID string `json:"operationID" binding:"required"`
|
OperationID string `json:"operationID" binding:"required"`
|
||||||
}
|
}
|
||||||
type TransferGroupOwnerResp struct {
|
type TransferGroupOwnerResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type DismissGroupReq struct {
|
type DismissGroupReq struct {
|
||||||
@ -226,7 +226,7 @@ type DismissGroupReq struct {
|
|||||||
OperationID string `json:"operationID" binding:"required"`
|
OperationID string `json:"operationID" binding:"required"`
|
||||||
}
|
}
|
||||||
type DismissGroupResp struct {
|
type DismissGroupResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type MuteGroupMemberReq struct {
|
type MuteGroupMemberReq struct {
|
||||||
@ -236,7 +236,7 @@ type MuteGroupMemberReq struct {
|
|||||||
MutedSeconds uint32 `json:"mutedSeconds" binding:"required"`
|
MutedSeconds uint32 `json:"mutedSeconds" binding:"required"`
|
||||||
}
|
}
|
||||||
type MuteGroupMemberResp struct {
|
type MuteGroupMemberResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type CancelMuteGroupMemberReq struct {
|
type CancelMuteGroupMemberReq struct {
|
||||||
@ -245,7 +245,7 @@ type CancelMuteGroupMemberReq struct {
|
|||||||
UserID string `json:"userID" binding:"required"`
|
UserID string `json:"userID" binding:"required"`
|
||||||
}
|
}
|
||||||
type CancelMuteGroupMemberResp struct {
|
type CancelMuteGroupMemberResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type MuteGroupReq struct {
|
type MuteGroupReq struct {
|
||||||
@ -253,7 +253,7 @@ type MuteGroupReq struct {
|
|||||||
GroupID string `json:"groupID" binding:"required"`
|
GroupID string `json:"groupID" binding:"required"`
|
||||||
}
|
}
|
||||||
type MuteGroupResp struct {
|
type MuteGroupResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type CancelMuteGroupReq struct {
|
type CancelMuteGroupReq struct {
|
||||||
@ -261,7 +261,7 @@ type CancelMuteGroupReq struct {
|
|||||||
GroupID string `json:"groupID" binding:"required"`
|
GroupID string `json:"groupID" binding:"required"`
|
||||||
}
|
}
|
||||||
type CancelMuteGroupResp struct {
|
type CancelMuteGroupResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type SetGroupMemberNicknameReq struct {
|
type SetGroupMemberNicknameReq struct {
|
||||||
@ -272,7 +272,7 @@ type SetGroupMemberNicknameReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type SetGroupMemberNicknameResp struct {
|
type SetGroupMemberNicknameResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type SetGroupMemberInfoReq struct {
|
type SetGroupMemberInfoReq struct {
|
||||||
@ -286,7 +286,7 @@ type SetGroupMemberInfoReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type SetGroupMemberInfoResp struct {
|
type SetGroupMemberInfoResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type GetGroupAbstractInfoReq struct {
|
type GetGroupAbstractInfoReq struct {
|
||||||
@ -295,7 +295,7 @@ type GetGroupAbstractInfoReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type GetGroupAbstractInfoResp struct {
|
type GetGroupAbstractInfoResp struct {
|
||||||
CommResp
|
|
||||||
GroupMemberNumber int32 `json:"groupMemberNumber"`
|
GroupMemberNumber int32 `json:"groupMemberNumber"`
|
||||||
GroupMemberListHash uint64 `json:"groupMemberListHash"`
|
GroupMemberListHash uint64 `json:"groupMemberListHash"`
|
||||||
}
|
}
|
||||||
|
@ -9,14 +9,12 @@ type DeleteUsersReq struct {
|
|||||||
DeleteUserIDList []string `json:"deleteUserIDList" binding:"required"`
|
DeleteUserIDList []string `json:"deleteUserIDList" binding:"required"`
|
||||||
}
|
}
|
||||||
type DeleteUsersResp struct {
|
type DeleteUsersResp struct {
|
||||||
CommResp
|
|
||||||
FailedUserIDList []string `json:"data"`
|
FailedUserIDList []string `json:"data"`
|
||||||
}
|
}
|
||||||
type GetAllUsersUidReq struct {
|
type GetAllUsersUidReq struct {
|
||||||
OperationID string `json:"operationID" binding:"required"`
|
OperationID string `json:"operationID" binding:"required"`
|
||||||
}
|
}
|
||||||
type GetAllUsersUidResp struct {
|
type GetAllUsersUidResp struct {
|
||||||
CommResp
|
|
||||||
UserIDList []string `json:"data"`
|
UserIDList []string `json:"data"`
|
||||||
}
|
}
|
||||||
type GetUsersOnlineStatusReq struct {
|
type GetUsersOnlineStatusReq struct {
|
||||||
@ -24,7 +22,7 @@ type GetUsersOnlineStatusReq struct {
|
|||||||
UserIDList []string `json:"userIDList" binding:"required,lte=200"`
|
UserIDList []string `json:"userIDList" binding:"required,lte=200"`
|
||||||
}
|
}
|
||||||
type GetUsersOnlineStatusResp struct {
|
type GetUsersOnlineStatusResp struct {
|
||||||
CommResp
|
|
||||||
//SuccessResult []*msggateway.GetUsersOnlineStatusResp_SuccessResult `json:"data"`
|
//SuccessResult []*msggateway.GetUsersOnlineStatusResp_SuccessResult `json:"data"`
|
||||||
}
|
}
|
||||||
type AccountCheckReq struct {
|
type AccountCheckReq struct {
|
||||||
@ -32,7 +30,7 @@ type AccountCheckReq struct {
|
|||||||
CheckUserIDList []string `json:"checkUserIDList" binding:"required,lte=100"`
|
CheckUserIDList []string `json:"checkUserIDList" binding:"required,lte=100"`
|
||||||
}
|
}
|
||||||
type AccountCheckResp struct {
|
type AccountCheckResp struct {
|
||||||
CommResp
|
|
||||||
//ResultList []*pbUser.AccountCheckResp_SingleUserStatus `json:"data"`
|
//ResultList []*pbUser.AccountCheckResp_SingleUserStatus `json:"data"`
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -69,7 +67,6 @@ type ManagementBatchSendMsgReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type ManagementBatchSendMsgResp struct {
|
type ManagementBatchSendMsgResp struct {
|
||||||
CommResp
|
|
||||||
Data struct {
|
Data struct {
|
||||||
ResultList []*SingleReturnResult `json:"resultList"`
|
ResultList []*SingleReturnResult `json:"resultList"`
|
||||||
FailedIDList []string
|
FailedIDList []string
|
||||||
@ -87,7 +84,6 @@ type CheckMsgIsSendSuccessReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type CheckMsgIsSendSuccessResp struct {
|
type CheckMsgIsSendSuccessResp struct {
|
||||||
CommResp
|
|
||||||
Status int32 `json:"status"`
|
Status int32 `json:"status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -119,7 +115,6 @@ type CMSUser struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type GetUsersResp struct {
|
type GetUsersResp struct {
|
||||||
CommResp
|
|
||||||
Data struct {
|
Data struct {
|
||||||
UserList []*CMSUser `json:"userList"`
|
UserList []*CMSUser `json:"userList"`
|
||||||
TotalNum int32 `json:"totalNum"`
|
TotalNum int32 `json:"totalNum"`
|
||||||
|
@ -12,7 +12,6 @@ type DelMsgReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type DelMsgResp struct {
|
type DelMsgResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type CleanUpMsgReq struct {
|
type CleanUpMsgReq struct {
|
||||||
@ -21,7 +20,6 @@ type CleanUpMsgReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type CleanUpMsgResp struct {
|
type CleanUpMsgResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type DelSuperGroupMsgReq struct {
|
type DelSuperGroupMsgReq struct {
|
||||||
@ -33,7 +31,6 @@ type DelSuperGroupMsgReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type DelSuperGroupMsgResp struct {
|
type DelSuperGroupMsgResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type MsgDeleteNotificationElem struct {
|
type MsgDeleteNotificationElem struct {
|
||||||
@ -50,7 +47,6 @@ type SetMsgMinSeqReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type SetMsgMinSeqResp struct {
|
type SetMsgMinSeqResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type ModifyMessageReactionExtensionsReq struct {
|
type ModifyMessageReactionExtensionsReq struct {
|
||||||
@ -67,7 +63,6 @@ type ModifyMessageReactionExtensionsReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type ModifyMessageReactionExtensionsResp struct {
|
type ModifyMessageReactionExtensionsResp struct {
|
||||||
CommResp
|
|
||||||
Data struct {
|
Data struct {
|
||||||
ResultKeyValue []*msg.KeyValueResp `json:"result"`
|
ResultKeyValue []*msg.KeyValueResp `json:"result"`
|
||||||
MsgFirstModifyTime int64 `json:"msgFirstModifyTime"`
|
MsgFirstModifyTime int64 `json:"msgFirstModifyTime"`
|
||||||
@ -83,7 +78,6 @@ type ModifyMessageReactionExtensionsResp struct {
|
|||||||
//}
|
//}
|
||||||
|
|
||||||
type OperateMessageListReactionExtensionsResp struct {
|
type OperateMessageListReactionExtensionsResp struct {
|
||||||
CommResp
|
|
||||||
Data struct {
|
Data struct {
|
||||||
SuccessList []*msg.ExtendMsgResp `json:"successList"`
|
SuccessList []*msg.ExtendMsgResp `json:"successList"`
|
||||||
FailedList []*msg.ExtendMsgResp `json:"failedList"`
|
FailedList []*msg.ExtendMsgResp `json:"failedList"`
|
||||||
@ -97,7 +91,6 @@ type SetMessageReactionExtensionsCallbackResp ModifyMessageReactionExtensionsRes
|
|||||||
//type GetMessageListReactionExtensionsReq OperateMessageListReactionExtensionsReq
|
//type GetMessageListReactionExtensionsReq OperateMessageListReactionExtensionsReq
|
||||||
|
|
||||||
type GetMessageListReactionExtensionsResp struct {
|
type GetMessageListReactionExtensionsResp struct {
|
||||||
CommResp
|
|
||||||
Data []*msg.SingleMessageExtensionResult `json:"data"`
|
Data []*msg.SingleMessageExtensionResult `json:"data"`
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -116,7 +109,6 @@ type DeleteMessageReactionExtensionsReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type DeleteMessageReactionExtensionsResp struct {
|
type DeleteMessageReactionExtensionsResp struct {
|
||||||
CommResp
|
|
||||||
Data []*msg.KeyValueResp
|
Data []*msg.KeyValueResp
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -16,7 +16,6 @@ type OSSCredentialRespData struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type OSSCredentialResp struct {
|
type OSSCredentialResp struct {
|
||||||
CommResp
|
|
||||||
OssData OSSCredentialRespData `json:"-"`
|
OssData OSSCredentialRespData `json:"-"`
|
||||||
Data map[string]interface{} `json:"data"`
|
Data map[string]interface{} `json:"data"`
|
||||||
}
|
}
|
||||||
|
@ -29,7 +29,6 @@ type MinioUploadFile struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type MinioUploadFileResp struct {
|
type MinioUploadFileResp struct {
|
||||||
CommResp
|
|
||||||
Data struct {
|
Data struct {
|
||||||
MinioUploadFile
|
MinioUploadFile
|
||||||
} `json:"data"`
|
} `json:"data"`
|
||||||
@ -46,7 +45,6 @@ type UploadUpdateAppReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type UploadUpdateAppResp struct {
|
type UploadUpdateAppResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
|
||||||
type GetDownloadURLReq struct {
|
type GetDownloadURLReq struct {
|
||||||
@ -56,7 +54,6 @@ type GetDownloadURLReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type GetDownloadURLResp struct {
|
type GetDownloadURLResp struct {
|
||||||
CommResp
|
|
||||||
Data struct {
|
Data struct {
|
||||||
HasNewVersion bool `json:"hasNewVersion"`
|
HasNewVersion bool `json:"hasNewVersion"`
|
||||||
ForceUpdate bool `json:"forceUpdate"`
|
ForceUpdate bool `json:"forceUpdate"`
|
||||||
@ -73,7 +70,6 @@ type GetRTCInvitationInfoReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type GetRTCInvitationInfoResp struct {
|
type GetRTCInvitationInfoResp struct {
|
||||||
CommResp
|
|
||||||
Data struct {
|
Data struct {
|
||||||
OpUserID string `json:"opUserID"`
|
OpUserID string `json:"opUserID"`
|
||||||
Invitation struct {
|
Invitation struct {
|
||||||
@ -110,7 +106,6 @@ type FcmUpdateTokenReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type FcmUpdateTokenResp struct {
|
type FcmUpdateTokenResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
type SetAppBadgeReq struct {
|
type SetAppBadgeReq struct {
|
||||||
OperationID string `json:"operationID" binding:"required"`
|
OperationID string `json:"operationID" binding:"required"`
|
||||||
@ -119,5 +114,4 @@ type SetAppBadgeReq struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type SetAppBadgeResp struct {
|
type SetAppBadgeResp struct {
|
||||||
CommResp
|
|
||||||
}
|
}
|
||||||
|
@ -10,7 +10,7 @@ import (
|
|||||||
|
|
||||||
const (
|
const (
|
||||||
singleGocMsgNum = 5000
|
singleGocMsgNum = 5000
|
||||||
msg = "msg"
|
Msg = "msg"
|
||||||
OldestList = 0
|
OldestList = 0
|
||||||
NewestList = -1
|
NewestList = -1
|
||||||
)
|
)
|
||||||
@ -38,7 +38,7 @@ type MsgDocModelInterface interface {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (MsgDocModel) TableName() string {
|
func (MsgDocModel) TableName() string {
|
||||||
return msg
|
return Msg
|
||||||
}
|
}
|
||||||
|
|
||||||
func (MsgDocModel) GetSingleGocMsgNum() int64 {
|
func (MsgDocModel) GetSingleGocMsgNum() int64 {
|
||||||
|
@ -61,7 +61,7 @@ func (m *Mongo) GetDatabase() *mongo.Database {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func (m *Mongo) CreateMsgIndex() error {
|
func (m *Mongo) CreateMsgIndex() error {
|
||||||
return m.createMongoIndex(unrelation.CChat, false, "uid")
|
return m.createMongoIndex(unrelation.Msg, false, "uid")
|
||||||
}
|
}
|
||||||
|
|
||||||
func (m *Mongo) CreateSuperGroupIndex() error {
|
func (m *Mongo) CreateSuperGroupIndex() error {
|
||||||
|
@ -9,6 +9,7 @@ type SvcDiscoveryRegistry interface {
|
|||||||
UnRegister() error
|
UnRegister() error
|
||||||
GetConns(serviceName string, opts ...grpc.DialOption) ([]*grpc.ClientConn, error)
|
GetConns(serviceName string, opts ...grpc.DialOption) ([]*grpc.ClientConn, error)
|
||||||
GetConn(serviceName string, opts ...grpc.DialOption) (*grpc.ClientConn, error)
|
GetConn(serviceName string, opts ...grpc.DialOption) (*grpc.ClientConn, error)
|
||||||
|
AddOption(opts ...grpc.DialOption)
|
||||||
|
|
||||||
RegisterConf2Registry(key string, conf []byte) error
|
RegisterConf2Registry(key string, conf []byte) error
|
||||||
GetConfFromRegistry(key string) ([]byte, error)
|
GetConfFromRegistry(key string) ([]byte, error)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user