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/office/office.proto

304 lines
6.5 KiB

3 years ago
syntax = "proto3";
import "Open_IM/pkg/proto/sdk_ws/ws.proto";
option go_package = "./office;office";
package office;
message CommonResp{
int32 errCode = 1;
string errMsg = 2;
}
message TagUser {
string userID = 1;
string userName = 2;
}
message Tag {
string tagID = 1;
string tagName = 2;
repeated TagUser userList = 3;
}
message GetUserTagsReq{
string userID = 1;
string operationID = 2;
}
message GetUserTagsResp{
CommonResp commonResp = 1;
repeated Tag tags = 2;
}
message CreateTagReq {
string tagName = 1;
string userID = 2;
repeated string userIDList = 3;
string operationID = 4;
}
message CreateTagResp {
CommonResp commonResp = 1;
}
message DeleteTagReq {
string userID = 1;
string tagID = 2;
string operationID = 3;
}
message DeleteTagResp {
CommonResp commonResp = 1;
}
message SetTagReq {
string userID = 1;
string tagID = 2;
string newName = 3;
repeated string increaseUserIDList = 4;
repeated string reduceUserIDList = 5;
string operationID = 6;
}
message SetTagResp {
CommonResp commonResp = 1;
}
message SendMsg2TagReq {
3 years ago
repeated string tagList = 1;
repeated string UserList = 2;
repeated string GroupList = 3;
string sendID = 4;
int32 senderPlatformID = 5;
string content = 6;
string operationID = 7;
3 years ago
}
message SendMsg2TagResp {
CommonResp commonResp = 1;
}
message GetTagSendLogsReq {
server_api_params.RequestPagination Pagination = 1;
string userID = 2;
string operationID = 3;
}
message TagSendLog {
repeated TagUser userList = 1;
string content = 2;
int64 sendTime = 3;
3 years ago
}
message GetTagSendLogsResp {
CommonResp commonResp = 1;
server_api_params.ResponsePagination Pagination = 2;
repeated TagSendLog tagSendLogs = 3;
}
message GetUserTagByIDReq {
string userID = 1;
string tagID = 2;
string operationID = 3;
}
message GetUserTagByIDResp {
CommonResp commonResp = 1;
Tag tag = 2;
}
3 years ago
/// WorkMoment
message LikeUser {
string userID = 1;
string userName = 2;
}
3 years ago
message NotificationUser {
string userID = 1;
string userName = 2;
}
3 years ago
message Comment {
string userID = 1;
string userName = 2;
3 years ago
string faceURL = 3;
string replyUserID = 4;
string replyUserName = 5;
string contentID = 6;
string content = 7;
int32 createTime = 8;
3 years ago
}
3 years ago
message PermissionGroup {
string groupName = 1;
string groupID = 2;
}
message WorkMomentUser {
string userID = 1;
string userName = 2;
}
3 years ago
message WorkMoment {
string workMomentID = 1;
string userID = 2;
3 years ago
string userName = 3;
string faceURL = 4;
string content = 5;
3 years ago
repeated WorkMomentUser likeUserList = 6;
3 years ago
repeated Comment comments = 7;
int32 permission = 8;
3 years ago
repeated WorkMomentUser permissionUserList = 9;
repeated PermissionGroup permissionGroupList = 10;
repeated WorkMomentUser atUserList = 11;
3 years ago
int32 createTime = 12;
3 years ago
}
message CreateOneWorkMomentReq {
WorkMoment workMoment = 1;
3 years ago
string operationID = 2;
3 years ago
}
message CreateOneWorkMomentResp {
CommonResp commonResp = 1;
}
message DeleteOneWorkMomentReq {
string workMomentID = 1;
string userID = 2;
string operationID = 3;
}
message DeleteOneWorkMomentResp {
CommonResp commonResp = 1;
}
message LikeOneWorkMomentReq {
string userID = 1;
string WorkMomentID = 2;
string operationID = 3;
}
message LikeOneWorkMomentResp {
CommonResp commonResp = 1;
}
message CommentOneWorkMomentReq {
string userID = 1;
string workMomentID = 2;
3 years ago
string replyUserID = 3;
string content = 4;
string operationID = 5;
3 years ago
}
message CommentOneWorkMomentResp {
CommonResp commonResp = 1;
}
3 years ago
message DeleteCommentReq {
string workMomentID = 1;
string contentID = 2;
string opUserID = 3;
string operationID = 4;
}
message DeleteCommentResp {
CommonResp commonResp = 1;
}
3 years ago
message GetWorkMomentByIDReq {
string workMomentID = 1;
string opUserID = 2;
string operationID = 3;
}
message GetWorkMomentByIDResp {
CommonResp commonResp = 1;
WorkMoment workMoment = 2;
}
3 years ago
message ChangeWorkMomentPermissionReq {
string workMomentID = 1;
string opUserID = 2;
int32 permission = 3;
repeated string permissionUserIDList = 4;
string operationID = 5;
}
message ChangeWorkMomentPermissionResp {
CommonResp commonResp = 1;
}
3 years ago
message GetUserWorkMomentsReq {
string userID = 1;
3 years ago
string opUserID = 2;
server_api_params.RequestPagination Pagination = 3;
string operationID = 4;
3 years ago
}
message GetUserWorkMomentsResp {
CommonResp commonResp = 1;
repeated WorkMoment workMoments = 2;
server_api_params.ResponsePagination Pagination = 3;
}
message GetUserFriendWorkMomentsReq {
string userID = 1;
server_api_params.RequestPagination Pagination = 2;
string operationID = 3;
}
message GetUserFriendWorkMomentsResp {
CommonResp commonResp = 1;
repeated WorkMoment workMoments = 2;
server_api_params.ResponsePagination Pagination = 3;
}
3 years ago
message WorkMomentNotificationMsg {
int32 notificationMsgType = 1;
3 years ago
string replyUserName = 2;
string replyUserID = 3;
string content = 4;
string contentID = 5;
string workMomentID = 6;
string userID = 7;
string userName = 8;
string faceURL = 9;
string workMomentContent = 10;
int32 createTime = 11;
3 years ago
}
message SetUserWorkMomentsLevelReq {
string userID = 1;
int32 level = 2;
string operationID = 3;
}
message SetUserWorkMomentsLevelResp {
CommonResp commonResp = 1;
}
3 years ago
service OfficeService {
rpc GetUserTags(GetUserTagsReq) returns(GetUserTagsResp);
rpc CreateTag(CreateTagReq) returns(CreateTagResp);
rpc DeleteTag(DeleteTagReq) returns(DeleteTagResp);
rpc SetTag(SetTagReq) returns(SetTagResp);
rpc SendMsg2Tag(SendMsg2TagReq) returns(SendMsg2TagResp);
rpc GetTagSendLogs(GetTagSendLogsReq) returns(GetTagSendLogsResp);
rpc GetUserTagByID(GetUserTagByIDReq) returns(GetUserTagByIDResp);
3 years ago
rpc CreateOneWorkMoment(CreateOneWorkMomentReq) returns(CreateOneWorkMomentResp);
rpc DeleteOneWorkMoment(DeleteOneWorkMomentReq) returns(DeleteOneWorkMomentResp);
rpc LikeOneWorkMoment(LikeOneWorkMomentReq) returns(LikeOneWorkMomentResp);
rpc CommentOneWorkMoment(CommentOneWorkMomentReq) returns(CommentOneWorkMomentResp);
3 years ago
rpc DeleteComment(DeleteCommentReq) returns(DeleteCommentResp);
3 years ago
rpc GetWorkMomentByID(GetWorkMomentByIDReq) returns(GetWorkMomentByIDResp);
3 years ago
rpc ChangeWorkMomentPermission(ChangeWorkMomentPermissionReq) returns(ChangeWorkMomentPermissionResp);
3 years ago
/// user self
rpc GetUserWorkMoments(GetUserWorkMomentsReq) returns(GetUserWorkMomentsResp);
/// users friend
rpc GetUserFriendWorkMoments(GetUserFriendWorkMomentsReq) returns(GetUserFriendWorkMomentsResp);
rpc SetUserWorkMomentsLevel(SetUserWorkMomentsLevelReq) returns(SetUserWorkMomentsLevelResp);
3 years ago
}