common.proto 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413
  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 ChatCardInfo{
  34. string id = 1; // id
  35. string nickname = 2;// 昵称
  36. string avatarUrl =3;// 头像链接
  37. int64 sex = 4;// 性别
  38. int64 age = 6; // 年龄
  39. string constellation = 7; // 星座
  40. repeated common.TagList tagList = 9; // 标签列表
  41. string introduceVoice = 10; // 介绍语音
  42. string province = 11;// 省
  43. string city = 12;// 市
  44. string area = 13;// 区
  45. bool isFinishInformation = 14;//是否完善资料
  46. }
  47. message PartnerChatCardInfo{
  48. string id = 1; // id
  49. string nickname = 2;// 昵称
  50. string avatarUrl =3;// 头像链接
  51. int64 sex = 4;// 性别
  52. int64 age = 6; // 年龄
  53. string type = 7;// 类型(新客:new,付费:pay)
  54. int64 benefit = 8;// 收益
  55. bool isUnlockVoice = 9;// 是否解锁语音
  56. bool isUnlockPicture = 10;// 是否解锁图片
  57. int64 unlockVoicePrice = 11;// 解锁语音奖励
  58. int64 unlockPicturePrice = 12;// 解锁图片奖励
  59. bool isGetVoicePrice = 13; // 是否领取了语音奖励
  60. bool isGetPicturePrice = 14; // 是否领取了图片奖励
  61. }
  62. message UserIDParam {
  63. string userId = 1;
  64. }
  65. message WxConfReq {
  66. string url = 1;
  67. }
  68. message WxConfResponse{
  69. string appId = 1; // 必填,公众号的唯一标识
  70. int64 timestamp = 2; // 必填,生成签名的时间戳
  71. string nonceStr = 3;// 必填,生成签名的随机串
  72. string signature = 4;// 必填,签名
  73. string url = 5;// 传入的url
  74. }
  75. // 主页信息
  76. message HomeInfo{
  77. string id = 1; // id
  78. string nickname = 2;// 昵称
  79. string avatarUrl =3;// 头像链接
  80. int64 sex = 4;// 性别
  81. repeated string pictures = 5; // 图片
  82. int64 age = 6; // 年龄
  83. string constellation = 7; // 星座
  84. repeated TagList tagList = 8; // 标签
  85. string signature = 9; // 签名
  86. string introduceVoice = 10; // 介绍语音
  87. string province = 11;// 省
  88. string city = 12;// 市
  89. string area = 13;// 区
  90. bool isBlack = 14;// 是否被封号
  91. }
  92. message PersonMsg {
  93. string id = 1; // id
  94. string nickname = 2;// 昵称
  95. string avatarUrl =3;// 头像链接
  96. int64 sex = 4;// 性别
  97. repeated string pictures = 5; // 图片
  98. int64 age = 6; // 年龄
  99. string constellation = 7; // 星座
  100. repeated int64 tagList = 8; // 标签
  101. string signature = 9; // 签名
  102. string introduceVoice = 10; // 介绍语音
  103. string province = 11;// 省
  104. string city = 12;// 市
  105. string area = 13;// 区
  106. bool isFinishInformation = 14; // 是否完成注册
  107. bool isBlack = 15;// 是否被封禁
  108. }
  109. message LookedAndLikedNum{
  110. string id = 1; // id
  111. int64 lookedNum = 2; // 看过ta的数量
  112. int64 likedNum = 3;// 喜欢ta的数量
  113. }
  114. // 添加好友页面信息
  115. message AddFriendMessageInfo{
  116. string id = 1; // id
  117. string nickname = 2;// 昵称
  118. string avatarUrl =3;// 头像链接
  119. int64 sex = 4;// 性别
  120. repeated string pictures = 5; // 图片
  121. string fromOpenId = 6;// 来源公众号对应的openID
  122. bool isRegister = 7;// 是否注册
  123. bool isChat = 8;// 是否聊天
  124. bool isFromUs = 9;// 是否是来源我们
  125. string fromAppId = 10;// 来源公众号对应的appID
  126. string fromName = 11;// 来源公众号对应的公众号名称
  127. string constellation = 12; // 星座
  128. string signature = 13;// 介绍(签名)
  129. string province = 14;// 省
  130. string city = 15;// 市
  131. string area = 16;// 区
  132. }
  133. message PersonIDList{
  134. repeated string personIds = 1;
  135. }
  136. message PersonDBReply{
  137. repeated PersonDB list = 1;
  138. }
  139. message PersonDB{
  140. string id = 1; // id
  141. string nickname = 2;// 昵称
  142. string avatarUrl =3;// 头像链接
  143. int64 sex = 4;// 性别
  144. repeated string pictures = 5; // 图片
  145. int64 age = 6; // 年龄
  146. string constellation = 7; // 星座
  147. string introduceVoice = 8; // 介绍语音
  148. string province = 9;// 省
  149. string city = 10;// 市
  150. string area = 11;// 区
  151. string signature = 12;//介绍
  152. bool isFinishInformation = 13;//是否完善消息
  153. repeated int64 tagList = 14;// 标签列表
  154. }
  155. message ListPageRequest{
  156. int64 nextId = 1;
  157. int64 offset = 2;
  158. }
  159. message ListPageAndSexRequest{
  160. int64 nextId = 1;
  161. int64 offset = 2;
  162. int64 sex = 3;// 对方的性别
  163. }
  164. message FindChatTopicRequest{
  165. string type = 1;// 话题类型
  166. int64 sex = 2;// 对方的性别
  167. }
  168. message ListPage2Request{
  169. string nextId = 1;
  170. int64 offset = 2;
  171. }
  172. message ListPageAndPersonRequest{
  173. string nextId = 1;
  174. int64 offset = 2;
  175. string personID = 3; // 查询目标的ID
  176. string personType = 4; // 类型
  177. }
  178. message SendPhoneCodeRequest {
  179. string phone = 1;
  180. }
  181. message CheckPhoneCodeRequest {
  182. string phone = 1;
  183. string code = 2;
  184. }
  185. message UploadMaterialResponse{
  186. string link = 1;
  187. }
  188. message Ids {
  189. repeated int64 ids = 1;// 标签ID
  190. }
  191. message TagListReply{
  192. repeated TagList list = 1;// 标签列表
  193. }
  194. message TagList{
  195. int64 id = 1; // 标签ID
  196. string name = 2;// 分组名
  197. }
  198. message SexReq{
  199. int64 sex = 1;
  200. }
  201. message RandomIntroduceReply{
  202. string introduce = 1;
  203. }
  204. message UpdateInformationRequest {
  205. string nickname = 1; // 昵称
  206. string avatarUrl = 2;// 头像
  207. int64 sex = 3; // 性别
  208. int64 birthday = 4;// 出生日期(毫秒级时间戳)
  209. repeated int64 tagList = 5;// 标签id列表
  210. string introduceVoice = 6;// 介绍语音的链接
  211. string signature = 7;// 介绍(签名)
  212. repeated string pictures = 8;// 相册(主页图片)
  213. string province = 9;// 省
  214. string city = 10;// 市
  215. string area = 11;// 区
  216. }
  217. message OnlinePersonListReply{
  218. repeated OnlinePersonInfo list = 1;
  219. string nextId = 2;
  220. }
  221. message OnlinePersonInfo{
  222. string personID = 1; // 查询目标的ID
  223. string personType = 2; // 类型
  224. string nickname = 3;// 昵称
  225. string avatarUrl =4;// 头像链接
  226. int64 sex = 5;// 性别
  227. int64 age = 6; // 年龄
  228. string constellation = 7; // 星座
  229. string signature = 8; // 签名
  230. string province = 9;// 省
  231. string city = 10;// 市
  232. string area = 11;// 区
  233. string introduceVoice = 12;// 介绍语音
  234. repeated string tagList = 13;// 标签
  235. }
  236. message ChatRecordListReply{
  237. repeated ChatRecordInfo list = 1;
  238. int64 nextId = 2;
  239. }
  240. message ChatRoomMsg{
  241. int64 roomId = 1; // 房间ID
  242. ChatPersonMsg self = 2; // 自己的信息
  243. ChatPersonMsg other = 3; // 对方的信息
  244. int64 likeability = 5; // 对对方的好感度
  245. }
  246. message ChatPersonMsg{
  247. string id = 1; // id
  248. string type = 2; // 类型
  249. string nickname = 3; // 昵称
  250. string avatar = 4; // 头像
  251. int64 sex = 5;// 性别
  252. }
  253. message ChatRecordInfo{
  254. int64 messageId = 1; // 消息的ID
  255. string msgType = 2; // 消息类型
  256. Message message = 3; // 消息的结构
  257. int64 roomId = 4; // 房间ID
  258. bool isSelf = 5; // 是否是自己
  259. int64 sendTime = 6; // 发送时间
  260. string status = 7; // 消息状态
  261. string statusMsg = 8;// 状态说明
  262. bool isRead = 9;// 对方是否已读
  263. }
  264. message ChatIsReadInfo{
  265. int64 messageId = 1; // 消息的ID
  266. int64 roomId = 4; // 房间ID
  267. }
  268. message GoToRoom{
  269. int64 roomId = 1; // 房间ID
  270. }
  271. message Message{
  272. string content = 1; // 文本内容
  273. string materialUrl = 2; // 素材链接
  274. }
  275. message FindChatRoomMsgRequest{
  276. int64 roomId = 1;
  277. }
  278. message RoomIDRequest{
  279. int64 roomId = 1;
  280. }
  281. message FindChatRecordListRequest{
  282. int64 nextId = 1;
  283. int64 offset = 2;
  284. int64 roomId = 3;
  285. }
  286. message IsLike{
  287. bool isLike = 1;// 是否喜欢(关注)
  288. }
  289. message BalanceRequest{
  290. string personID = 1; // 查询目标的ID
  291. string personType = 2; // 类型
  292. int64 balance = 3;// 充值或者减少的金额
  293. }
  294. message RandomNum {
  295. int64 num = 1; // 随机的数量
  296. }
  297. message RandomNumAndSex {
  298. int64 num = 1; // 随机的数量
  299. int64 sex = 2; // 对方的性别
  300. }
  301. message MemeRequest{
  302. int64 nextId = 1;
  303. int64 offset = 2;
  304. string type = 3;
  305. }
  306. message CommonTextList {
  307. repeated string list = 1;// 需要的数据集合(随机表情包、随机打招呼)
  308. }
  309. message MemeTitleList {
  310. repeated MemeTitle list = 1;// 需要的数据集合(随机表情包、随机打招呼)
  311. }
  312. message MemeTitle{
  313. string name = 1;// 名称
  314. string type = 2;// 类型
  315. }
  316. message MemeList {
  317. repeated string list = 1;// 表情包列表
  318. int64 nextId = 2;
  319. }
  320. message ChatTopicList {
  321. repeated string list = 1;// 话题列表
  322. }
  323. message ReportChatRequest{
  324. string reportMsg = 1;// 举报的详情
  325. string reportedPersonId = 4; // 被举报的人的ID
  326. string reportedPersonType = 5; // 被举报的人的类型
  327. string contactInformation = 6; // 联系方式
  328. repeated string picture = 7; // 图片
  329. repeated string category = 8; // 类别
  330. }
  331. message ReportRequest{
  332. string identifyId = 1;// 发起举报的人的身份ID
  333. string personId = 2; // 发起举报的人的ID
  334. string personType = 3; // 发起举报的人的类型
  335. string reportedIdentifyId = 4; // 被举报的人的身份ID
  336. string reportedPersonId = 5; // 被举报的人的ID
  337. string reportedPersonType = 6; // 被举报的人的类型
  338. string contactInformation = 7; // 联系方式
  339. repeated string picture = 8; // 图片
  340. repeated string category = 9; // 类别
  341. string reportMsg = 10;// 举报的详情
  342. }
  343. message RoomChatMsg{
  344. string type = 7;// 类型(新客:new,付费:pay)
  345. int64 benefit = 8;// 收益
  346. bool isUnlockVoice = 9;// 是否解锁语音
  347. bool isUnlockPicture = 10;// 是否解锁图片
  348. int64 unlockVoicePrice = 11;// 解锁语音奖励
  349. int64 unlockPicturePrice = 12;// 解锁图片奖励
  350. bool isGetVoicePrice = 13; // 是否领取了语音奖励
  351. bool isGetPicturePrice = 14; // 是否领取了图片奖励
  352. }