RoomRecommend.proto 5.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150
  1. syntax = "proto3";
  2. package room.v1;
  3. option go_package = "v1";
  4. import "github.com/gogo/protobuf/gogoproto/gogo.proto";
  5. service RoomRecommend {
  6. /** app关播播放器推荐
  7. *
  8. */
  9. rpc getPlayerList (RoomRecommendGetPlayerListReq) returns (RoomRecommendGetPlayerListResp);
  10. /** 获取首页推荐主播数据,可强推可刷新
  11. *
  12. */
  13. rpc clientRecStrong (RoomRecommendClientRecStrongReq) returns (RoomRecommendClientRecStrongResp);
  14. }
  15. message RoomRecommendGetPlayerListReq {
  16. // 二级分区
  17. int64 area_v2_id = 1 [(gogoproto.jsontag) = "area_v2_id"];
  18. // roomid
  19. int64 roomid = 2 [(gogoproto.jsontag) = "roomid"];
  20. // 0.默认old 1.新文本
  21. int64 is_new = 3 [(gogoproto.jsontag) = "is_new"];
  22. }
  23. message RoomRecommendGetPlayerListResp {
  24. // code
  25. int64 code = 1 [(gogoproto.jsontag) = "code"];
  26. // msg
  27. string msg = 2 [(gogoproto.jsontag) = "msg"];
  28. //
  29. Data data = 3 [(gogoproto.jsontag) = "data"];
  30. message RoomInfo {
  31. // 房间id
  32. int64 roomid = 1 [(gogoproto.jsontag) = "roomid"];
  33. // 房间标题
  34. string title = 2 [(gogoproto.jsontag) = "title"];
  35. // 用户名
  36. string uname = 3 [(gogoproto.jsontag) = "uname"];
  37. // 在线人数
  38. int64 online = 4 [(gogoproto.jsontag) = "online"];
  39. // 封面,封面现在有3种:关键帧、封面图、秀场封面(正方形的),返回哪个由后端决定
  40. string cover = 5 [(gogoproto.jsontag) = "cover"];
  41. // 链接
  42. string link = 6 [(gogoproto.jsontag) = "link"];
  43. // 主播头像
  44. string face = 7 [(gogoproto.jsontag) = "face"];
  45. // 父分区id
  46. int64 area_v2_parent_id = 8 [(gogoproto.jsontag) = "area_v2_parent_id"];
  47. // 父分区名称
  48. string area_v2_parent_name = 9 [(gogoproto.jsontag) = "area_v2_parent_name"];
  49. // 二级分区id
  50. int64 area_v2_id = 10 [(gogoproto.jsontag) = "area_v2_id"];
  51. // 二级分区名
  52. string area_v2_name = 11 [(gogoproto.jsontag) = "area_v2_name"];
  53. // 秒开播放串
  54. string play_url = 12 [(gogoproto.jsontag) = "play_url"];
  55. // 当前清晰度,清晰度 0:默认码率, 2:800 3:1500 4:原画
  56. int64 current_quality = 13 [(gogoproto.jsontag) = "current_quality"];
  57. // 当前拥有清晰度列表
  58. repeated int64 accept_quality = 14 [(gogoproto.jsontag) = "accept_quality"];
  59. // 横竖屏 0:横屏 1:竖屏 -1:异常情况
  60. int64 broadcast_type = 15 [(gogoproto.jsontag) = "broadcast_type"];
  61. // 是否关注 0未关注 1已关注
  62. int64 is_focus = 16 [(gogoproto.jsontag) = "is_focus"];
  63. }
  64. message Data {
  65. // 播放器文本
  66. string title = 1 [(gogoproto.jsontag) = "title"];
  67. // 关播推荐房间列表
  68. repeated RoomInfo list = 2 [(gogoproto.jsontag) = "list"];
  69. }
  70. }
  71. message RoomRecommendClientRecStrongReq {
  72. // 强推第几刷
  73. int64 rec_page = 1 [(gogoproto.jsontag) = "rec_page"];
  74. }
  75. message RoomRecommendClientRecStrongResp {
  76. // code
  77. int64 code = 1 [(gogoproto.jsontag) = "code"];
  78. // msg
  79. string msg = 2 [(gogoproto.jsontag) = "msg"];
  80. //
  81. Data data = 3 [(gogoproto.jsontag) = "data"];
  82. message Result {
  83. // 房间id
  84. int64 roomid = 1 [(gogoproto.jsontag) = "roomid"];
  85. // 房间标题
  86. string title = 2 [(gogoproto.jsontag) = "title"];
  87. // 用户名
  88. string uname = 3 [(gogoproto.jsontag) = "uname"];
  89. // 在线人数
  90. int64 online = 4 [(gogoproto.jsontag) = "online"];
  91. // 封面,封面现在有3种:关键帧、封面图、秀场封面(正方形的),返回哪个由后端决定
  92. string cover = 5 [(gogoproto.jsontag) = "cover"];
  93. // 封面图
  94. string user_cover = 6 [(gogoproto.jsontag) = "user_cover"];
  95. // 关键帧
  96. string system_cover = 7 [(gogoproto.jsontag) = "system_cover"];
  97. // 链接
  98. string link = 8 [(gogoproto.jsontag) = "link"];
  99. // 主播头像
  100. string face = 9 [(gogoproto.jsontag) = "face"];
  101. // 父分区id
  102. int64 area_v2_parent_id = 10 [(gogoproto.jsontag) = "area_v2_parent_id"];
  103. // 父分区名称
  104. string area_v2_parent_name = 11 [(gogoproto.jsontag) = "area_v2_parent_name"];
  105. // 二级分区id
  106. int64 area_v2_id = 12 [(gogoproto.jsontag) = "area_v2_id"];
  107. // 二级分区名
  108. string area_v2_name = 13 [(gogoproto.jsontag) = "area_v2_name"];
  109. // 秒开播放串
  110. string play_url = 14 [(gogoproto.jsontag) = "play_url"];
  111. // 当前清晰度,清晰度 0:默认码率, 2:800 3:1500 4:原画
  112. int64 current_quality = 15 [(gogoproto.jsontag) = "current_quality"];
  113. // 当前拥有清晰度列表
  114. repeated int64 accept_quality = 16 [(gogoproto.jsontag) = "accept_quality"];
  115. // 横竖屏 0:横屏 1:竖屏 -1:异常情况
  116. int64 broadcast_type = 17 [(gogoproto.jsontag) = "broadcast_type"];
  117. // 新版角标-右上 默认为空 只能是文字!!!@古月 【5.29显示更新】:服务端还是吐右上(兼容老版),5.29显示在左上
  118. string pendent_ru = 18 [(gogoproto.jsontag) = "pendent_ru"];
  119. // 【5.29显示更新】:服务端还是吐右上,5.29客户端显示在左上,对应的背景图片
  120. string pendent_ru_pic = 19 [(gogoproto.jsontag) = "pendent_ru_pic"];
  121. // 新版移动端角标色值-右上
  122. string pendent_ru_color = 20 [(gogoproto.jsontag) = "pendent_ru_color"];
  123. // 推荐类型 1:人气 2:营收 3:运营强推 4:天马推荐(暂定)用于客户端打点
  124. int64 rec_type = 21 [(gogoproto.jsontag) = "rec_type"];
  125. // 当前房间pk_id,默认0 用于客户端打点
  126. int64 pk_id = 22 [(gogoproto.jsontag) = "pk_id"];
  127. }
  128. message Data {
  129. //
  130. map<int64, Result> result = 1 [(gogoproto.jsontag) = "result"];
  131. }
  132. }