update 【gRPC API】 proto files

This commit is contained in:
社会易姐QwQ 2022-09-17 23:53:09 +08:00
parent 17eee20dce
commit 990bb68919
2 changed files with 225 additions and 91 deletions

View File

@ -7,7 +7,7 @@ service DM {
// //
rpc DmSegMobile (DmSegMobileReq) returns (DmSegMobileReply); rpc DmSegMobile (DmSegMobileReq) returns (DmSegMobileReply);
// //
rpc DmView (DmViewReq) returns (DmViewReply); rpc DmView(DmViewReq) returns (DmViewReply);
// //
rpc DmPlayerConfig (DmPlayerConfigReq) returns (Response); rpc DmPlayerConfig (DmPlayerConfigReq) returns (Response);
// ott弹幕列表 // ott弹幕列表
@ -15,7 +15,7 @@ service DM {
// SDK弹幕列表 // SDK弹幕列表
rpc DmSegSDK(DmSegSDKReq) returns(DmSegSDKReply); rpc DmSegSDK(DmSegSDKReq) returns(DmSegSDKReply);
// //
rpc DmExpoReport (DmExpoReportReq) returns (DmExpoReportRes); rpc DmExpoReport(DmExpoReportReq) returns (DmExpoReportRes);
} }
// //
@ -42,6 +42,27 @@ message Bubble {
string url = 2; string url = 2;
} }
//
enum BubbleType {
BubbleTypeNone = 0; //
BubbleTypeClickButton = 1; //
BubbleTypeDmSettingPanel = 2; //
}
//
message BubbleV2 {
//
string text = 1;
//
string url = 2;
//
BubbleType bubble_type = 3;
//
bool exposure_once = 4;
//
ExposureType exposure_type = 5;
}
// //
message Button { message Button {
// //
@ -91,6 +112,16 @@ enum CheckboxType {
CheckboxTypeColorDM = 2; // CheckboxTypeColorDM = 2; //
} }
//
message CheckBoxV2 {
//
string text = 1;
//
int32 type = 2;
//
bool default_value = 3;
}
// //
message ClickButton { message ClickButton {
// //
@ -109,6 +140,26 @@ message ClickButton {
Bubble bubble = 7; Bubble bubble = 7;
} }
//
message ClickButtonV2 {
//
repeated string portrait_text = 1;
//
repeated string landscape_text = 2;
//
repeated string portrait_text_focus = 3;
//
repeated string landscape_text_focus = 4;
//
int32 render_type = 5;
//
bool text_input_post = 6;
//
bool exposure_once = 7;
//
int32 exposure_type = 8;
}
// //
message CommandDm { message CommandDm {
// id // id
@ -145,7 +196,7 @@ message DanmakuElem {
int64 id = 1; int64 id = 1;
// (ms) // (ms)
int32 progress = 2; int32 progress = 2;
// // 1 2 3: 4: 5: 6: 7: 8: 9:BAS弹幕(pool必须为2)
int32 mode = 3; int32 mode = 3;
// //
int32 fontsize = 4; int32 fontsize = 4;
@ -157,11 +208,11 @@ message DanmakuElem {
string content = 7; string content = 7;
// //
int64 ctime = 8; int64 ctime = 8;
// :[1,10] // :[1,10]
int32 weight = 9; int32 weight = 9;
// //
string action = 10; string action = 10;
// // 0: 1: 2:(/BAS弹幕)
int32 pool = 11; int32 pool = 11;
// dmid str // dmid str
string idStr = 12; string idStr = 12;
@ -237,6 +288,12 @@ message DanmuPlayerConfig {
map<int32, int32> player_danmaku_ai_recommended_level_v2_map = 22; // map<int32, int32> player_danmaku_ai_recommended_level_v2_map = 22; //
} }
//
message DanmuPlayerConfigPanel {
//
string selection_text = 1;
}
// //
message DanmuPlayerDynamicConfig { message DanmuPlayerDynamicConfig {
// //
@ -253,6 +310,8 @@ message DanmuPlayerViewConfig {
DanmuPlayerConfig danmuku_player_config = 2; DanmuPlayerConfig danmuku_player_config = 2;
// //
repeated DanmuPlayerDynamicConfig danmuku_player_dynamic_config = 3; repeated DanmuPlayerDynamicConfig danmuku_player_dynamic_config = 3;
//
DanmuPlayerConfigPanel danmuku_player_config_panel = 4;
} }
// web端用户弹幕配置 // web端用户弹幕配置
@ -300,9 +359,7 @@ message DmExpoReportReq {
} }
// //
message DmExpoReportRes { message DmExpoReportRes {}
}
// - // -
message DmPlayerConfigReq { message DmPlayerConfigReq {
@ -453,6 +510,8 @@ message DmViewReply {
repeated PostPanel post_panel = 17; repeated PostPanel post_panel = 17;
// //
repeated string activity_meta = 18; repeated string activity_meta = 18;
//
repeated PostPanelV2 post_panel2 = 19;
} }
// - // -
@ -471,6 +530,7 @@ message DmViewReq {
} }
// web端弹幕元数据- // web端弹幕元数据-
// https://api.bilibili.com/x/v2/dm/web/view
message DmWebViewReply { message DmWebViewReply {
// //
// 0: 1: // 0: 1:
@ -509,6 +569,12 @@ message ExpoReport {
bool should_report_at_end = 1; bool should_report_at_end = 1;
} }
//
enum ExposureType {
ExposureTypeNone = 0; //
ExposureTypeDMSend = 1; //
}
// //
message Expression { message Expression {
// //
@ -525,6 +591,12 @@ message Expressions {
repeated Expression data = 1; repeated Expression data = 1;
} }
//
message InlinePlayerDanmakuSwitch {
//
bool value = 1;
}
// //
message Label { message Label {
// //
@ -533,6 +605,18 @@ message Label {
repeated string content = 2; repeated string content = 2;
} }
//
message LabelV2 {
//
string title = 1;
//
repeated string content = 2;
//
bool exposure_once = 3;
//
int32 exposure_type = 4;
}
// //
message Period { message Period {
// //
@ -541,44 +625,24 @@ message Period {
int64 end = 2; int64 end = 2;
} }
// message PlayerDanmakuAiRecommendedLevel {bool value = 1;} //
message InlinePlayerDanmakuSwitch {bool value = 1;} message PlayerDanmakuAiRecommendedLevelV2 {int32 value = 1;} //
// message PlayerDanmakuAiRecommendedSwitch {bool value = 1;} //
message PlayerDanmakuAiRecommendedLevel {bool value = 1;} message PlayerDanmakuBlockbottom {bool value = 1;} //
// message PlayerDanmakuBlockcolorful {bool value = 1;} //
message PlayerDanmakuAiRecommendedLevelV2 {int32 value = 1;} message PlayerDanmakuBlockrepeat {bool value = 1;} //
// message PlayerDanmakuBlockscroll {bool value = 1;} //
message PlayerDanmakuAiRecommendedSwitch {bool value = 1;} message PlayerDanmakuBlockspecial {bool value = 1;} //
// message PlayerDanmakuBlocktop {bool value = 1;} //
message PlayerDanmakuBlockbottom {bool value = 1;} message PlayerDanmakuDomain {float value = 1;} //
// message PlayerDanmakuEnableblocklist {bool value = 1;} //
message PlayerDanmakuBlockcolorful {bool value = 1;} message PlayerDanmakuOpacity {float value = 1;} //
// message PlayerDanmakuScalingfactor {float value = 1;} //
message PlayerDanmakuBlockrepeat {bool value = 1;} message PlayerDanmakuSeniorModeSwitch {int32 value = 1;} //
// message PlayerDanmakuSpeed {int32 value = 1;} //
message PlayerDanmakuBlockscroll {bool value = 1;} message PlayerDanmakuSwitch {bool value = 1; bool can_ignore = 2;} //
// message PlayerDanmakuSwitchSave {bool value = 1;} //
message PlayerDanmakuBlockspecial {bool value = 1;} message PlayerDanmakuUseDefaultConfig {bool value = 1;} // 使
//
message PlayerDanmakuBlocktop {bool value = 1;}
//
message PlayerDanmakuDomain {float value = 1;}
//
message PlayerDanmakuEnableblocklist {bool value = 1;}
//
message PlayerDanmakuOpacity {float value = 1;}
//
message PlayerDanmakuScalingfactor {float value = 1;}
//
message PlayerDanmakuSeniorModeSwitch {int32 value = 1;}
//
message PlayerDanmakuSpeed {int32 value = 1;}
//
message PlayerDanmakuSwitch {bool value = 1;bool canIgnore = 2;}
//
message PlayerDanmakuSwitchSave {bool value = 1;}
// 使
message PlayerDanmakuUseDefaultConfig {bool value = 1;}
// //
message PostPanel { message PostPanel {
@ -612,6 +676,30 @@ enum PostPanelBizType {
PostPanelBizTypeRecommend = 5; // PostPanelBizTypeRecommend = 5; //
} }
//
message PostPanelV2 {
//
int64 start = 1;
//
int64 end = 2;
//
int32 biz_type = 3;
//
ClickButtonV2 click_button = 4;
//
TextInputV2 text_input = 5;
//
CheckBoxV2 check_box = 6;
//
ToastV2 toast = 7;
//
BubbleV2 bubble = 8;
//
LabelV2 label = 9;
//
int32 post_status = 10;
}
// //
enum PostStatus { enum PostStatus {
PostStatusNormal = 0; // PostStatusNormal = 0; //
@ -695,6 +783,22 @@ message TextInput {
Label label = 8; Label label = 8;
} }
//
message TextInputV2 {
//
repeated string portrait_placeholder = 1;
//
repeated string landscape_placeholder = 2;
//
RenderType render_type = 3;
//
bool placeholder_post = 4;
//
repeated Avatar avatar = 5;
//
int32 text_input_limit = 6;
}
// //
message Toast { message Toast {
// //
@ -707,12 +811,30 @@ message Toast {
Button button = 4; Button button = 4;
} }
//
message ToastButtonV2 {
//
string text = 1;
//
int32 action = 2;
}
// //
enum ToastFunctionType { enum ToastFunctionType {
ToastFunctionTypeNone = 0; // ToastFunctionTypeNone = 0; //
ToastFunctionTypePostPanel = 1; // ToastFunctionTypePostPanel = 1; //
} }
//
message ToastV2 {
//
string text = 1;
//
int32 duration = 2;
//
ToastButtonV2 toast_button_v2 = 3;
}
// //
message UserInfo { message UserInfo {
// mid // mid

View File

@ -22,7 +22,7 @@ service Reply {
rpc AtSearch(AtSearchReq) returns (AtSearchReply); rpc AtSearch(AtSearchReq) returns (AtSearchReply);
// //
rpc ReplyInfo(ReplyInfoReq) returns (ReplyInfoReply); rpc ReplyInfo(ReplyInfoReq) returns (ReplyInfoReply);
// //
rpc UserCallback(UserCallbackReq) returns (UserCallbackReply); rpc UserCallback(UserCallbackReq) returns (UserCallbackReply);
// //
rpc ShareRepliesInfo(ShareRepliesInfoReq) returns (ShareRepliesInfoResp); rpc ShareRepliesInfo(ShareRepliesInfoReq) returns (ShareRepliesInfoResp);
@ -344,16 +344,28 @@ message MainListReq {
// //
message Member { message Member {
// //
message Region { enum RegionType {
// DEFAULT = 0; //
int32 type = 1; MAINLAND = 1; //
// GAT = 2; //
string icon = 2;
//
int32 show_status = 3;
} }
// //
enum ShowStatus {
SHOWDEFAULT = 0; //
ZOOMINMAINLAND = 1; //
RAW = 2; //
}
// NFT地区
message Region {
//
RegionType type = 1;
// url
string icon = 2;
//
ShowStatus show_status = 3;
}
// NFT信息
message NftInteraction { message NftInteraction {
// //
string itype = 1; string itype = 1;
@ -361,7 +373,7 @@ message Member {
string metadata_url = 2; string metadata_url = 2;
// //
string nft_id = 3; string nft_id = 3;
// // NFT地区
Region region = 4; Region region = 4;
} }
/**********基础信息**********/ /**********基础信息**********/
@ -430,11 +442,11 @@ message Member {
int64 fans_guard_level = 29; int64 fans_guard_level = 29;
// //
int32 face_nft = 30; int32 face_nft = 30;
// // NFT头像
int32 face_nft_new = 31; int32 face_nft_new = 31;
// //
int32 is_senior_member = 32; int32 is_senior_member = 32;
// // NFT信息
NftInteraction nft_interaction = 33; NftInteraction nft_interaction = 33;
// //
string fans_guard_icon = 34; string fans_guard_icon = 34;
@ -522,22 +534,28 @@ message MemberV2 {
// //
int64 level_bg_color = 11; int64 level_bg_color = 11;
} }
// //
enum RegionType { enum RegionType {
DEFAULT = 0; // DEFAULT = 0; //
MAINLAND = 1; // MAINLAND = 1; //
GAT = 2; // GAT = 2; //
} }
// //
enum ShowStatus {
SHOWDEFAULT = 0; //
ZOOMINMAINLAND = 1; //
RAW = 2; //
}
// NFT地区
message Region { message Region {
// //
RegionType type = 1; RegionType type = 1;
// // url
string icon = 2; string icon = 2;
// //
int32 show_status = 3; ShowStatus show_status = 3;
} }
// // NFT信息
message Interaction { message Interaction {
// //
string itype = 1; string itype = 1;
@ -545,7 +563,7 @@ message MemberV2 {
string metadata_url = 2; string metadata_url = 2;
// //
string nft_id = 3; string nft_id = 3;
// // NFT地区
Region region = 4; Region region = 4;
} }
@ -563,17 +581,11 @@ message MemberV2 {
} }
// //
message Contractor { message Contractor {
// // up签订契约
bool is_contractor = 1; bool is_contractor = 1;
// //
string contract_desc = 2; string contract_desc = 2;
} }
//
enum ShowStatus {
SHOWDEFAULT = 0; //
ZOOMINMAINLAND = 1; //
RAW = 2; //
}
// //
Basic basic = 1; Basic basic = 1;
// //
@ -594,10 +606,10 @@ message MemberV2 {
// //
enum Mode { enum Mode {
DEFAULT = 0; // DEFAULT = 0; //
UNSPECIFIED = 1; // UNSPECIFIED = 1; //
MAIN_LIST_TIME = 2; // MAIN_LIST_TIME = 2; //
MAIN_LIST_HOT = 3; // MAIN_LIST_HOT = 3; //
} }
// //
@ -714,7 +726,7 @@ message ReplyCardLabel {
string label_color_night = 5; string label_color_night = 5;
// //
string image = 6; string image = 6;
// // 0:UP主觉得很赞 1:
int32 type = 7; int32 type = 7;
// url // url
string background = 8; string background = 8;
@ -775,7 +787,7 @@ message ReplyControl {
string sub_reply_entry_text = 20; string sub_reply_entry_text = 20;
// "相关回复共x条" // "相关回复共x条"
string sub_reply_title_text = 21; string sub_reply_title_text = 21;
// //
string contract_desc = 22; string contract_desc = 22;
// "x天前发布" // "x天前发布"
string time_desc = 23; string time_desc = 23;
@ -856,13 +868,13 @@ message RichText {
// //
message RichTextNote { message RichTextNote {
// //
string summary = 1; string summary = 1;
// // url列表
repeated string images = 2; repeated string images = 2;
// // url
string click_url = 3; string click_url = 3;
// // YYYY-mm-dd
string last_mtime_text = 4; string last_mtime_text = 4;
} }
@ -1146,11 +1158,11 @@ message Url {
string app_name = 5; string app_name = 5;
// //
string app_package_name = 6; string app_package_name = 6;
// id //
string click_report = 7; string click_report = 7;
// //
bool is_half_screen = 8; bool is_half_screen = 8;
// //
string exposure_report = 9; string exposure_report = 9;
// //
Extra extra = 10; Extra extra = 10;
@ -1169,20 +1181,20 @@ enum UserCallbackAction {
Dismiss = 0; // Dismiss = 0; //
} }
// // -
message UserCallbackReply {} message UserCallbackReply {}
// // -
message UserCallbackReq { message UserCallbackReq {
// // mid
int64 mid = 1; int64 mid = 1;
// //
UserCallbackScene scene = 2; UserCallbackScene scene = 2;
// //
UserCallbackAction action = 3; UserCallbackAction action = 3;
// // id
int64 oid = 4; int64 oid = 4;
// // type
int64 type = 5; int64 type = 5;
} }