common.proto 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244
  1. syntax = "proto3";
  2. package api.common;
  3. //import "google/api/annotations.proto";
  4. //import "google/protobuf/struct.proto";
  5. //import "google/protobuf/empty.proto";
  6. option go_package = "git.ikuban.com/server/pw-protobuf/api/common;common";
  7. option java_multiple_files = true;
  8. option java_package = "api.common";
  9. message UserAndPartnerIdParam {
  10. string partnerId = 1;
  11. string userId = 2;
  12. }
  13. message UserAndPartnerParam {
  14. string partnerId = 1;
  15. string partnerIdentifyID = 2; // 身份ID
  16. string userId = 3;
  17. string userIdentifyID = 4; // 身份ID
  18. }
  19. message User1AndUser2IdParam {
  20. string user1 = 1;
  21. string user2 = 2;
  22. }
  23. message PartnerIDParam {
  24. string partnerID = 1;
  25. }
  26. message PersonIDParam {
  27. string personID = 1;
  28. }
  29. message PersonParam{
  30. string personID = 1; // 查询目标的ID
  31. string personType = 2; // 类型
  32. }
  33. message UserIDParam {
  34. string userId = 1;
  35. }
  36. message WxConfReq {
  37. string url = 1;
  38. }
  39. message WxConfResponse{
  40. string appId = 1; // 必填,公众号的唯一标识
  41. int64 timestamp = 2; // 必填,生成签名的时间戳
  42. string nonceStr = 3;// 必填,生成签名的随机串
  43. string signature = 4;// 必填,签名
  44. string url = 5;// 传入的url
  45. }
  46. // 主页信息
  47. message HomeInfo{
  48. string id = 1; // id
  49. string nickname = 2;// 昵称
  50. string avatarUrl =3;// 头像链接
  51. int64 sex = 4;// 性别
  52. repeated string pictures = 5; // 图片
  53. int64 age = 6; // 年龄
  54. string constellation = 7; // 星座
  55. repeated TagList tagList = 8; // 标签
  56. string signature = 9; // 签名
  57. string introduceVoice = 10; // 介绍语音
  58. string province = 11;// 省
  59. string city = 12;// 市
  60. string area = 13;// 区
  61. }
  62. message PersonMsg {
  63. string id = 1; // id
  64. string nickname = 2;// 昵称
  65. string avatarUrl =3;// 头像链接
  66. int64 sex = 4;// 性别
  67. repeated string pictures = 5; // 图片
  68. int64 age = 6; // 年龄
  69. string constellation = 7; // 星座
  70. repeated int64 tagList = 8; // 标签
  71. string signature = 9; // 签名
  72. string introduceVoice = 10; // 介绍语音
  73. string province = 11;// 省
  74. string city = 12;// 市
  75. string area = 13;// 区
  76. }
  77. message LookedAndLikedNum{
  78. string id = 1; // id
  79. int64 lookedNum = 2; // 看过ta的数量
  80. int64 likedNum = 3;// 喜欢ta的数量
  81. }
  82. // 添加好友页面信息
  83. message AddFriendMessageInfo{
  84. string id = 1; // id
  85. string nickname = 2;// 昵称
  86. string avatarUrl =3;// 头像链接
  87. int64 sex = 4;// 性别
  88. repeated string pictures = 5; // 图片
  89. string fromOpenId = 6;// 来源公众号对应的openID
  90. bool isRegister = 7;// 是否注册
  91. bool isChat = 8;// 是否聊天
  92. bool isFromUs = 9;// 是否是来源我们
  93. string fromAppId = 10;// 来源公众号对应的appID
  94. string fromName = 11;// 来源公众号对应的公众号名称
  95. string constellation = 12; // 星座
  96. string signature = 13;// 介绍(签名)
  97. string province = 14;// 省
  98. string city = 15;// 市
  99. string area = 16;// 区
  100. }
  101. message PersonIDList{
  102. repeated string personIds = 1;
  103. }
  104. message PersonDBReply{
  105. repeated PersonDB list = 1;
  106. }
  107. message PersonDB{
  108. string id = 1; // id
  109. string nickname = 2;// 昵称
  110. string avatarUrl =3;// 头像链接
  111. int64 sex = 4;// 性别
  112. repeated string pictures = 5; // 图片
  113. int64 age = 6; // 年龄
  114. string constellation = 7; // 星座
  115. string introduceVoice = 8; // 介绍语音
  116. string province = 9;// 省
  117. string city = 10;// 市
  118. string area = 11;// 区
  119. string signature = 12;//介绍
  120. }
  121. message ListPageRequest{
  122. int64 nextId = 1;
  123. int64 offset = 2;
  124. }
  125. message ListPage2Request{
  126. string nextId = 1;
  127. int64 offset = 2;
  128. }
  129. message ListPageAndPersonRequest{
  130. string nextId = 1;
  131. int64 offset = 2;
  132. string personID = 3; // 查询目标的ID
  133. string personType = 4; // 类型
  134. }
  135. message SendPhoneCodeRequest {
  136. string phone = 1;
  137. }
  138. message CheckPhoneCodeRequest {
  139. string phone = 1;
  140. string code = 2;
  141. }
  142. message UploadMaterialResponse{
  143. string link = 1;
  144. }
  145. message Ids {
  146. repeated int64 ids = 1;// 标签ID
  147. }
  148. message TagListReply{
  149. repeated TagList list = 1;// 标签列表
  150. }
  151. message TagList{
  152. int64 id = 1; // 标签ID
  153. string name = 2;// 分组名
  154. }
  155. message SexReq{
  156. int64 sex = 1;
  157. }
  158. message RandomIntroduceReply{
  159. string introduce = 1;
  160. }
  161. message UpdateInformationRequest {
  162. string nickname = 1; // 昵称
  163. string avatarUrl = 2;// 头像
  164. int64 sex = 3; // 性别
  165. int64 birthday = 4;// 出生日期(毫秒级时间戳)
  166. repeated int64 tagList = 5;// 标签id列表
  167. string introduceVoice = 6;// 介绍语音的链接
  168. string signature = 7;// 介绍(签名)
  169. repeated string pictures = 8;// 相册(主页图片)
  170. string province = 9;// 省
  171. string city = 10;// 市
  172. string area = 11;// 区
  173. }
  174. message OnlinePersonListReply{
  175. repeated OnlinePersonInfo list = 1;
  176. string nextId = 2;
  177. }
  178. message OnlinePersonInfo{
  179. string personID = 1; // 查询目标的ID
  180. string personType = 2; // 类型
  181. string nickname = 3;// 昵称
  182. string avatarUrl =4;// 头像链接
  183. int64 sex = 5;// 性别
  184. int64 age = 6; // 年龄
  185. string constellation = 7; // 星座
  186. string signature = 8; // 签名
  187. string province = 9;// 省
  188. string city = 10;// 市
  189. string area = 11;// 区
  190. }
  191. message ChatRecordListReply{
  192. repeated ChatRecordInfo list = 1;
  193. int64 nextId = 2;
  194. }
  195. message ChatRecordInfo{
  196. int64 messageId = 1; // 消息的ID
  197. string msgType = 2; // 消息类型
  198. Message message = 3; // 消息的结构
  199. int64 roomId = 4; // 房间ID
  200. bool isSelf = 5; // 是否是自己
  201. int64 sendTime = 6; // 发送时间
  202. string status = 7; // 消息状态
  203. }
  204. message Message{
  205. string content = 1; // 文本内容
  206. string materialUrl = 2; // 素材链接
  207. int64 second = 3;// 音频的秒数
  208. }