You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Open-IM-Server/pkg/proto/user/user.proto

155 lines
3.4 KiB

syntax = "proto3";
2 years ago
package OpenIMServer.user;
2 years ago
import "sdkws/sdkws.proto";
import "conversation/conversation.proto";
option go_package = "github.com/OpenIMSDK/Open-IM-Server/pkg/proto/user";
3 years ago
message getAllUserIDReq{
2 years ago
sdkws.RequestPagination pagination = 1;
3 years ago
}
message getAllUserIDResp{
int32 total = 1;
2 years ago
repeated string userIDs = 2;
3 years ago
}
3 years ago
message accountCheckReq{
repeated string checkUserIDs = 1;
3 years ago
}
message accountCheckResp{
message singleUserStatus {
3 years ago
string userID = 1;
string accountStatus = 2;
}
repeated singleUserStatus results = 1;
}
3 years ago
message getDesignateUsersReq{
repeated string userIDs = 1;
}
message getDesignateUsersResp{
2 years ago
repeated sdkws.UserInfo usersInfo = 1;
}
message updateUserInfoReq{
2 years ago
sdkws.UserInfo userInfo = 1;
3 years ago
}
message updateUserInfoResp{
}
message setGlobalRecvMessageOptReq{
string userID = 1;
int32 globalRecvMsgOpt = 3;
}
message setGlobalRecvMessageOptResp{
}
3 years ago
message setConversationReq{
2 years ago
OpenIMServer.conversation.Conversation conversation = 1;
int32 notificationType = 2;
string operationID = 3;
3 years ago
}
3 years ago
message setConversationResp{
3 years ago
}
3 years ago
message setRecvMsgOptReq {
string ownerUserID = 1;
string conversationID = 2;
int32 recvMsgOpt = 3;
int32 notificationType = 4;
string operationID = 5;
3 years ago
}
message setRecvMsgOptResp {
3 years ago
}
message getConversationReq{
string conversationID = 1;
string ownerUserID = 2;
string operationID = 3;
}
3 years ago
message getConversationResp{
2 years ago
OpenIMServer.conversation.Conversation conversation = 2;
}
message getConversationsReq{
string ownerUserID = 1;
repeated string conversationIDs = 2;
string operationID = 3;
}
3 years ago
message getConversationsResp{
2 years ago
repeated OpenIMServer.conversation.Conversation conversations = 2;
}
message getAllConversationsReq{
string ownerUserID = 1;
string operationID = 2;
}
3 years ago
message getAllConversationsResp{
2 years ago
repeated OpenIMServer.conversation.Conversation conversations = 2;
3 years ago
}
message batchSetConversationsReq{
2 years ago
repeated OpenIMServer.conversation.Conversation conversations = 1;
3 years ago
string OwnerUserID = 2;
int32 notificationType = 3;
string OperationID = 4;
3 years ago
}
message batchSetConversationsResp{
3 years ago
repeated string Success = 2;
repeated string Failed = 3;
}
3 years ago
message getPaginationUsersReq {
2 years ago
sdkws.RequestPagination pagination = 2;
3 years ago
}
message getPaginationUsersResp{
int32 total = 1;
2 years ago
repeated sdkws.UserInfo users = 2;
3 years ago
}
message userRegisterReq {
2 years ago
repeated sdkws.UserInfo users = 1;
}
message userRegisterResp {
}
message getGlobalRecvMessageOptReq{
string userID = 1;
}
message getGlobalRecvMessageOptResp{
int32 globalRecvMsgOpt = 1;
}
3 years ago
service user {
//获取指定的用户信息 全字段
rpc getDesignateUsers(getDesignateUsersReq) returns(getDesignateUsersResp);
//更新用户信息
rpc updateUserInfo(updateUserInfoReq) returns(updateUserInfoResp);
//设置用户消息接收选项
rpc setGlobalRecvMessageOpt(setGlobalRecvMessageOptReq) returns(setGlobalRecvMessageOptResp);
//获取用户消息接收选项 没找到不返回错误
rpc getGlobalRecvMessageOpt(getGlobalRecvMessageOptReq) returns(getGlobalRecvMessageOptResp);
//检查userID是否存在
rpc accountCheck(accountCheckReq) returns (accountCheckResp);
//翻页或指定userID昵称拉取用户信息 全字段
rpc getPaginationUsers(getPaginationUsersReq) returns (getPaginationUsersResp);
//用户注册
rpc userRegister(userRegisterReq) returns (userRegisterResp);
2 years ago
//获取所有用户ID
rpc getAllUserID(getAllUserIDReq) returns (getAllUserIDResp);
}
2 years ago