common.proto 6.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290
  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 UserAndPartnerIdentifyIdParam {
  10. string partnerIdentifyId = 1;
  11. string userIdentifyId = 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. bool isFinishInformation = 13;//是否完善消息
  121. repeated int64 tagList = 14;// 标签列表
  122. }
  123. message ListPageRequest{
  124. int64 nextId = 1;
  125. int64 offset = 2;
  126. }
  127. message ListPage2Request{
  128. string nextId = 1;
  129. int64 offset = 2;
  130. }
  131. message ListPageAndPersonRequest{
  132. string nextId = 1;
  133. int64 offset = 2;
  134. string personID = 3; // 查询目标的ID
  135. string personType = 4; // 类型
  136. }
  137. message SendPhoneCodeRequest {
  138. string phone = 1;
  139. }
  140. message CheckPhoneCodeRequest {
  141. string phone = 1;
  142. string code = 2;
  143. }
  144. message UploadMaterialResponse{
  145. string link = 1;
  146. }
  147. message Ids {
  148. repeated int64 ids = 1;// 标签ID
  149. }
  150. message TagListReply{
  151. repeated TagList list = 1;// 标签列表
  152. }
  153. message TagList{
  154. int64 id = 1; // 标签ID
  155. string name = 2;// 分组名
  156. }
  157. message SexReq{
  158. int64 sex = 1;
  159. }
  160. message RandomIntroduceReply{
  161. string introduce = 1;
  162. }
  163. message UpdateInformationRequest {
  164. string nickname = 1; // 昵称
  165. string avatarUrl = 2;// 头像
  166. int64 sex = 3; // 性别
  167. int64 birthday = 4;// 出生日期(毫秒级时间戳)
  168. repeated int64 tagList = 5;// 标签id列表
  169. string introduceVoice = 6;// 介绍语音的链接
  170. string signature = 7;// 介绍(签名)
  171. repeated string pictures = 8;// 相册(主页图片)
  172. string province = 9;// 省
  173. string city = 10;// 市
  174. string area = 11;// 区
  175. }
  176. message OnlinePersonListReply{
  177. repeated OnlinePersonInfo list = 1;
  178. string nextId = 2;
  179. }
  180. message OnlinePersonInfo{
  181. string personID = 1; // 查询目标的ID
  182. string personType = 2; // 类型
  183. string nickname = 3;// 昵称
  184. string avatarUrl =4;// 头像链接
  185. int64 sex = 5;// 性别
  186. int64 age = 6; // 年龄
  187. string constellation = 7; // 星座
  188. string signature = 8; // 签名
  189. string province = 9;// 省
  190. string city = 10;// 市
  191. string area = 11;// 区
  192. string introduceVoice = 12;// 介绍语音
  193. repeated string tagList = 13;// 标签
  194. }
  195. message ChatRecordListReply{
  196. repeated ChatRecordInfo list = 1;
  197. int64 nextId = 2;
  198. }
  199. message ChatRoomMsg{
  200. int64 roomId = 1; // 房间ID
  201. ChatPersonMsg self = 2; // 自己的信息
  202. ChatPersonMsg other = 3; // 对方的信息
  203. int64 likeability = 5; // 对对方的好感度
  204. }
  205. message ChatPersonMsg{
  206. string id = 1; // id
  207. string type = 2; // 类型
  208. string nickname = 3; // 昵称
  209. string avatar = 4; // 头像
  210. }
  211. message ChatRecordInfo{
  212. int64 messageId = 1; // 消息的ID
  213. string msgType = 2; // 消息类型
  214. Message message = 3; // 消息的结构
  215. int64 roomId = 4; // 房间ID
  216. bool isSelf = 5; // 是否是自己
  217. int64 sendTime = 6; // 发送时间
  218. string status = 7; // 消息状态
  219. string statusMsg = 8;// 状态说明
  220. bool isRead = 9;// 对方是否已读
  221. }
  222. message ChatIsReadInfo{
  223. int64 messageId = 1; // 消息的ID
  224. int64 roomId = 4; // 房间ID
  225. }
  226. message Message{
  227. string content = 1; // 文本内容
  228. string materialUrl = 2; // 素材链接
  229. }
  230. message FindChatRoomMsgRequest{
  231. int64 roomId = 1;
  232. }
  233. message FindChatRecordListRequest{
  234. int64 nextId = 1;
  235. int64 offset = 2;
  236. int64 roomId = 3;
  237. }
  238. message IsLike{
  239. bool isLike = 1;// 是否喜欢(关注)
  240. }
  241. message BalanceRequest{
  242. string personID = 1; // 查询目标的ID
  243. string personType = 2; // 类型
  244. int64 balance = 3;// 充值或者减少的金额
  245. }