150 lines
5.9 KiB
Protocol Buffer
150 lines
5.9 KiB
Protocol Buffer
syntax = "proto3";
|
||
|
||
package room.v1;
|
||
|
||
option go_package = "v1";
|
||
|
||
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
|
||
|
||
service RoomRecommend {
|
||
|
||
/** app关播播放器推荐
|
||
*
|
||
*/
|
||
rpc getPlayerList (RoomRecommendGetPlayerListReq) returns (RoomRecommendGetPlayerListResp);
|
||
|
||
/** 获取首页推荐主播数据,可强推可刷新
|
||
*
|
||
*/
|
||
rpc clientRecStrong (RoomRecommendClientRecStrongReq) returns (RoomRecommendClientRecStrongResp);
|
||
}
|
||
|
||
|
||
|
||
message RoomRecommendGetPlayerListReq {
|
||
// 二级分区
|
||
int64 area_v2_id = 1 [(gogoproto.jsontag) = "area_v2_id"];
|
||
// roomid
|
||
int64 roomid = 2 [(gogoproto.jsontag) = "roomid"];
|
||
// 0.默认old 1.新文本
|
||
int64 is_new = 3 [(gogoproto.jsontag) = "is_new"];
|
||
}
|
||
|
||
message RoomRecommendGetPlayerListResp {
|
||
// code
|
||
int64 code = 1 [(gogoproto.jsontag) = "code"];
|
||
// msg
|
||
string msg = 2 [(gogoproto.jsontag) = "msg"];
|
||
//
|
||
Data data = 3 [(gogoproto.jsontag) = "data"];
|
||
|
||
message RoomInfo {
|
||
// 房间id
|
||
int64 roomid = 1 [(gogoproto.jsontag) = "roomid"];
|
||
// 房间标题
|
||
string title = 2 [(gogoproto.jsontag) = "title"];
|
||
// 用户名
|
||
string uname = 3 [(gogoproto.jsontag) = "uname"];
|
||
// 在线人数
|
||
int64 online = 4 [(gogoproto.jsontag) = "online"];
|
||
// 封面,封面现在有3种:关键帧、封面图、秀场封面(正方形的),返回哪个由后端决定
|
||
string cover = 5 [(gogoproto.jsontag) = "cover"];
|
||
// 链接
|
||
string link = 6 [(gogoproto.jsontag) = "link"];
|
||
// 主播头像
|
||
string face = 7 [(gogoproto.jsontag) = "face"];
|
||
// 父分区id
|
||
int64 area_v2_parent_id = 8 [(gogoproto.jsontag) = "area_v2_parent_id"];
|
||
// 父分区名称
|
||
string area_v2_parent_name = 9 [(gogoproto.jsontag) = "area_v2_parent_name"];
|
||
// 二级分区id
|
||
int64 area_v2_id = 10 [(gogoproto.jsontag) = "area_v2_id"];
|
||
// 二级分区名
|
||
string area_v2_name = 11 [(gogoproto.jsontag) = "area_v2_name"];
|
||
// 秒开播放串
|
||
string play_url = 12 [(gogoproto.jsontag) = "play_url"];
|
||
// 当前清晰度,清晰度 0:默认码率, 2:800 3:1500 4:原画
|
||
int64 current_quality = 13 [(gogoproto.jsontag) = "current_quality"];
|
||
// 当前拥有清晰度列表
|
||
repeated int64 accept_quality = 14 [(gogoproto.jsontag) = "accept_quality"];
|
||
// 横竖屏 0:横屏 1:竖屏 -1:异常情况
|
||
int64 broadcast_type = 15 [(gogoproto.jsontag) = "broadcast_type"];
|
||
// 是否关注 0未关注 1已关注
|
||
int64 is_focus = 16 [(gogoproto.jsontag) = "is_focus"];
|
||
}
|
||
|
||
message Data {
|
||
// 播放器文本
|
||
string title = 1 [(gogoproto.jsontag) = "title"];
|
||
// 关播推荐房间列表
|
||
repeated RoomInfo list = 2 [(gogoproto.jsontag) = "list"];
|
||
}
|
||
}
|
||
|
||
|
||
|
||
message RoomRecommendClientRecStrongReq {
|
||
// 强推第几刷
|
||
int64 rec_page = 1 [(gogoproto.jsontag) = "rec_page"];
|
||
}
|
||
|
||
message RoomRecommendClientRecStrongResp {
|
||
// code
|
||
int64 code = 1 [(gogoproto.jsontag) = "code"];
|
||
// msg
|
||
string msg = 2 [(gogoproto.jsontag) = "msg"];
|
||
//
|
||
Data data = 3 [(gogoproto.jsontag) = "data"];
|
||
|
||
message Result {
|
||
// 房间id
|
||
int64 roomid = 1 [(gogoproto.jsontag) = "roomid"];
|
||
// 房间标题
|
||
string title = 2 [(gogoproto.jsontag) = "title"];
|
||
// 用户名
|
||
string uname = 3 [(gogoproto.jsontag) = "uname"];
|
||
// 在线人数
|
||
int64 online = 4 [(gogoproto.jsontag) = "online"];
|
||
// 封面,封面现在有3种:关键帧、封面图、秀场封面(正方形的),返回哪个由后端决定
|
||
string cover = 5 [(gogoproto.jsontag) = "cover"];
|
||
// 封面图
|
||
string user_cover = 6 [(gogoproto.jsontag) = "user_cover"];
|
||
// 关键帧
|
||
string system_cover = 7 [(gogoproto.jsontag) = "system_cover"];
|
||
// 链接
|
||
string link = 8 [(gogoproto.jsontag) = "link"];
|
||
// 主播头像
|
||
string face = 9 [(gogoproto.jsontag) = "face"];
|
||
// 父分区id
|
||
int64 area_v2_parent_id = 10 [(gogoproto.jsontag) = "area_v2_parent_id"];
|
||
// 父分区名称
|
||
string area_v2_parent_name = 11 [(gogoproto.jsontag) = "area_v2_parent_name"];
|
||
// 二级分区id
|
||
int64 area_v2_id = 12 [(gogoproto.jsontag) = "area_v2_id"];
|
||
// 二级分区名
|
||
string area_v2_name = 13 [(gogoproto.jsontag) = "area_v2_name"];
|
||
// 秒开播放串
|
||
string play_url = 14 [(gogoproto.jsontag) = "play_url"];
|
||
// 当前清晰度,清晰度 0:默认码率, 2:800 3:1500 4:原画
|
||
int64 current_quality = 15 [(gogoproto.jsontag) = "current_quality"];
|
||
// 当前拥有清晰度列表
|
||
repeated int64 accept_quality = 16 [(gogoproto.jsontag) = "accept_quality"];
|
||
// 横竖屏 0:横屏 1:竖屏 -1:异常情况
|
||
int64 broadcast_type = 17 [(gogoproto.jsontag) = "broadcast_type"];
|
||
// 新版角标-右上 默认为空 只能是文字!!!@古月 【5.29显示更新】:服务端还是吐右上(兼容老版),5.29显示在左上
|
||
string pendent_ru = 18 [(gogoproto.jsontag) = "pendent_ru"];
|
||
// 【5.29显示更新】:服务端还是吐右上,5.29客户端显示在左上,对应的背景图片
|
||
string pendent_ru_pic = 19 [(gogoproto.jsontag) = "pendent_ru_pic"];
|
||
// 新版移动端角标色值-右上
|
||
string pendent_ru_color = 20 [(gogoproto.jsontag) = "pendent_ru_color"];
|
||
// 推荐类型 1:人气 2:营收 3:运营强推 4:天马推荐(暂定)用于客户端打点
|
||
int64 rec_type = 21 [(gogoproto.jsontag) = "rec_type"];
|
||
// 当前房间pk_id,默认0 用于客户端打点
|
||
int64 pk_id = 22 [(gogoproto.jsontag) = "pk_id"];
|
||
}
|
||
|
||
message Data {
|
||
//
|
||
map<int64, Result> result = 1 [(gogoproto.jsontag) = "result"];
|
||
}
|
||
} |