chat.proto 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. syntax = "proto3";
  2. package api.chat;
  3. //import "google/api/annotations.proto";
  4. //import "google/protobuf/struct.proto";
  5. import "google/protobuf/empty.proto";
  6. import "api/common/common.proto";
  7. option go_package = "git.ikuban.com/server/pw-protobuf/api/chat;chat";
  8. option java_multiple_files = true;
  9. option java_package = "api.chat";
  10. service Chat {
  11. // 检查用户是否与接待员聊天
  12. rpc CheckUserPartnerIsRelationship (common.UserAndPartnerIdParam) returns (CheckUserPartnerIsRelationshipReply);
  13. // 创建用户与接待员的聊天
  14. rpc CreateUserPartnerIsRelationship (common.UserAndPartnerIdParam) returns (CreateUserPartnerIsRelationshipReply);
  15. // 查询在线人的列表
  16. rpc FindOnlinePersonList (common.PersonParam) returns (OnlinePersonListReply);
  17. }
  18. message OnlinePersonListReply{
  19. repeated OnlinePersonInfo list = 1;
  20. }
  21. message OnlinePersonInfo{
  22. string personID = 1; // 查询目标的ID
  23. string personType = 2; // 类型
  24. string nickname = 3;// 昵称
  25. string avatarUrl =4;// 头像链接
  26. int64 sex = 5;// 性别
  27. int64 age = 6; // 年龄
  28. string constellation = 7; // 星座
  29. string signature = 8; // 签名
  30. string province = 9;// 省
  31. string city = 10;// 市
  32. string area = 11;// 区
  33. }
  34. message CheckUserPartnerIsRelationshipReply{
  35. bool isBuildRelationship = 1;
  36. int64 roomId = 2;
  37. }
  38. message CreateUserPartnerIsRelationshipReply{
  39. int64 roomId = 1;
  40. }