common.proto 11 KB

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