update 【gRPC API】 proto files

This commit is contained in:
社会易姐QwQ 2022-01-31 00:33:38 +08:00
parent 83cfcc80d6
commit 57c5621b5d
14 changed files with 1114 additions and 565 deletions

View File

@ -11,15 +11,13 @@ service Privacy {
} }
// //
message NoArgRequest{} message NoArgRequest{
}
// //
message NoReply{} message NoReply{
// -
message PrivacyConfigReply {
//
PrivacyConfigItem privacy_config_item = 1;
} }
// //
@ -36,20 +34,22 @@ message PrivacyConfigItem {
string sub_title_uri = 5; string sub_title_uri = 5;
} }
// // -
enum PrivacyConfigType { message PrivacyConfigReply {
// //
none = 0; PrivacyConfigItem privacy_config_item = 1;
//
dynamic_city = 1;
} }
// //
enum PrivacyConfigState { enum PrivacyConfigState {
// close = 0; //
close = 0; open = 1; //
// }
open = 1;
//
enum PrivacyConfigType {
none = 0; //
dynamic_city = 1; //
} }
// - // -

View File

@ -8,14 +8,23 @@ service Module {
rpc List(ListReq) returns (ListReply); rpc List(ListReq) returns (ListReply);
} }
//
enum CompressType {
Unzip = 0; // unzip
Original = 1; //
}
// //
enum EnvType { enum EnvType {
Unknown = 0; //
Release = 1; //
Test = 2; //
}
// //
Unknown = 0; enum IncrementType {
// Total = 0; //
Release = 1; Incremental = 1; //
//
Test = 2;
} }
// //
@ -26,6 +35,15 @@ enum LevelType {
Low = 3; // 使 Low = 3; // 使
} }
message ListReply {
//
string env = 1;
//
repeated PoolReply pools = 2;
//
int64 list_version = 3;
}
// //
message ListReq { message ListReq {
// //
@ -42,50 +60,11 @@ message ListReq {
int32 scale = 6; int32 scale = 6;
// //
int32 arch = 7; int32 arch = 7;
//
int64 list_version = 8;
} }
// //
message VersionListReq {
//
string pool_name = 1;
//
repeated VersionReq versions = 2;
}
//
message VersionReq {
//
string module_name = 1;
//
int64 version = 2;
}
//
enum IncrementType {
Total = 0; //
Incremental = 1; //
}
//
enum CompressType {
Unzip = 0; // unzip
Original = 1; //
}
message ListReply {
//
string env = 1;
//
repeated PoolReply pools = 2;
}
message PoolReply {
//
string name = 1;
//
repeated ModuleReply modules = 2;
}
message ModuleReply { message ModuleReply {
// //
string name = 1; string name = 1;
@ -124,3 +103,26 @@ message ModuleReply {
// //
bool zip_check = 18; bool zip_check = 18;
} }
message PoolReply {
//
string name = 1;
//
repeated ModuleReply modules = 2;
}
//
message VersionListReq {
//
string pool_name = 1;
//
repeated VersionReq versions = 2;
}
//
message VersionReq {
//
string module_name = 1;
//
int64 version = 2;
}

View File

@ -11,50 +11,14 @@ service Popular {
rpc Index (PopularResultReq) returns (PopularReply); rpc Index (PopularResultReq) returns (PopularReply);
} }
// - //
message PopularResultReq { message Bubble {
// ididx //
int64 idx = 1; string bubble_content = 1;
//
// 1: 2:
int32 login_event = 2;
// ()
int32 qn = 3;
// ()
int32 fnver = 4;
// ()
int32 fnval = 5;
// 使()
int32 force_host = 6;
// 4K()
int32 fourk = 7;
// spm
string spmid = 8;
// param
string last_param = 9;
// ver
string ver = 10;
// ID
int64 entrance_id = 11;
// id集合
string location_ids = 12;
// 0:tag页 1:
int32 source_id = 13;
//
// 0: 1:
int32 flush = 14;
//
bilibili.app.archive.middleware.v1.PlayerArgs player_args = 15;
}
// -
message PopularReply {
//
repeated bilibili.app.card.v1.Card items = 1;
//
Config config = 2;
// //
string ver = 3; int32 version = 2;
//
int64 stime = 3;
} }
// //
@ -97,12 +61,56 @@ message EntranceShow {
int32 entrance_type = 8; int32 entrance_type = 8;
} }
// // -
message Bubble { message PopularReply {
// //
string bubble_content = 1; repeated bilibili.app.card.v1.Card items = 1;
//
Config config = 2;
// //
int32 version = 2; string ver = 3;
//
int64 stime = 3;
} }
// -
message PopularResultReq {
// ididx
int64 idx = 1;
//
// 1: 2:
int32 login_event = 2;
// ()
int32 qn = 3;
// ()
int32 fnver = 4;
// ()
int32 fnval = 5;
// 使()
int32 force_host = 6;
// 4K()
int32 fourk = 7;
// spm
string spmid = 8;
// param
string last_param = 9;
// ver
string ver = 10;
// ID
int64 entrance_id = 11;
// id集合
string location_ids = 12;
// 0:tag页 1:
int32 source_id = 13;
//
// 0: 1:
int32 flush = 14;
//
bilibili.app.archive.middleware.v1.PlayerArgs player_args = 15;
}

View File

@ -10,37 +10,6 @@ service Rank {
rpc RankRegion (RankRegionResultReq) returns (RankListReply); rpc RankRegion (RankRegionResultReq) returns (RankListReply);
} }
// -
message RankAllResultReq {
// "all"
string order = 1;
//
// 1
int32 pn = 2;
//
// 100100
int32 ps = 3;
}
// -
message RankRegionResultReq {
// tid()
// 0:
int32 rid = 1;
//
// 1
int32 pn = 2;
//
// 100100
int32 ps = 3;
}
// -
message RankListReply {
//
repeated Item items = 1;
}
// //
message Item { message Item {
// //
@ -108,6 +77,37 @@ message OfficialVerify {
string desc = 2; string desc = 2;
} }
// -
message RankAllResultReq {
// "all"
string order = 1;
//
// 1
int32 pn = 2;
//
// 100100
int32 ps = 3;
}
// -
message RankListReply {
//
repeated Item items = 1;
}
// -
message RankRegionResultReq {
// tid()
// 0:
int32 rid = 1;
//
// 1
int32 pn = 2;
//
// 100100
int32 ps = 3;
}
// //
message Relation { message Relation {
// id // id

View File

@ -8,18 +8,6 @@ service Region {
rpc Region (RegionReq) returns (RegionReply); rpc Region (RegionReq) returns (RegionReply);
} }
//
message RegionReq {
//
string lang = 1;
}
//
message RegionReply {
//
repeated RegionInfo regions = 1;
}
// //
message RegionConfig { message RegionConfig {
// //
@ -53,3 +41,15 @@ message RegionInfo {
// //
repeated RegionConfig config = 11; repeated RegionConfig config = 11;
} }
//
message RegionReply {
//
repeated RegionInfo regions = 1;
}
//
message RegionReq {
//
string lang = 1;
}

View File

@ -8,18 +8,6 @@ service Space {
rpc Archive (ArchiveReq) returns (ArchiveReply); rpc Archive (ArchiveReq) returns (ArchiveReply);
} }
//-
message ArchiveReq {
//
int64 vmid = 1;
//
int32 pn = 2;
//
int32 ps = 3;
//
string order = 4;
}
//- //-
message ArchiveReply { message ArchiveReply {
// //
@ -32,6 +20,18 @@ message ArchiveReply {
repeated OrderConfig order = 4; repeated OrderConfig order = 4;
} }
//-
message ArchiveReq {
//
int64 vmid = 1;
//
int32 pn = 2;
//
int32 ps = 3;
//
string order = 4;
}
// //
message Badge { message Badge {
// //

View File

@ -10,34 +10,6 @@ service Splash {
rpc List (SplashReq) returns (SplashReply); rpc List (SplashReq) returns (SplashReply);
} }
//-
message SplashReq {
//
int32 width = 1;
//
int32 height = 2;
//
string birth = 3;
//
string ad_extra = 4;
//
string network = 5;
}
//-
message SplashReply {
//
int32 max_time = 1;
//
int32 min_interval = 2;
//
int32 pull_interval = 3;
//
repeated SplashItem list = 4;
//
repeated ShowStrategy show = 5;
}
// //
message ShowStrategy { message ShowStrategy {
// //
@ -129,3 +101,31 @@ message SplashItem {
// //
bool enable_background_download = 39; bool enable_background_download = 39;
} }
//-
message SplashReply {
//
int32 max_time = 1;
//
int32 min_interval = 2;
//
int32 pull_interval = 3;
//
repeated SplashItem list = 4;
//
repeated ShowStrategy show = 5;
}
//-
message SplashReq {
//
int32 width = 1;
//
int32 height = 2;
//
string birth = 3;
//
string ad_extra = 4;
//
string network = 5;
}

View File

@ -0,0 +1,396 @@
syntax = "proto3";
package bilibili.app.topic.v1;
import "bilibili/app/dynamic/v2/dynamic.proto";
import "bilibili/app/card/v1/common.proto";
import "bilibili/app/archive/middleware/v1/preload.proto";
//
service Topic {
//
rpc TopicDetailsAll(TopicDetailsAllReq) returns (TopicDetailsAllReply);
//
rpc TopicDetailsFold(TopicDetailsFoldReq) returns (TopicDetailsFoldReply);
}
//
message DetailsTopInfo {
//
TopicInfo topic_info = 1;
//
User user = 2;
//
string stats_desc = 3;
//
bool has_create_jurisdiction = 4;
//
OperationContent operation_content = 5;
//
string head_img_url = 6;
//
string head_img_backcolor = 7;
//
int32 word_color = 8;
}
//
message FoldCardItem {
//
int32 is_show_fold = 1;
//
int64 fold_count = 2;
//
string card_show_desc = 3;
//
string fold_desc = 4;
}
//
message FunctionalCard {
//
repeated TopicCapsule capsules = 1;
//
TrafficCard traffic_card = 2;
//
GameCard game_card = 3;
}
//
message GameCard {
//
int64 game_id = 1;
//
string game_icon = 2;
//
string game_name = 3;
//
string score = 4;
//
string game_tags = 5;
//
string notice = 6;
//
string game_link = 7;
}
//
message InlineProgressBar {
//
string icon_drag = 1;
//
string icon_drag_hash = 2;
//
string icon_stop = 3;
//
string icon_stop_hash = 4;
}
//
message LargeCoverInline {
//
bilibili.app.card.v1.Base base = 1;
//
string cover_left_text1 = 2;
//
int32 cover_left_icon1 = 3;
//
string cover_left_text2 = 4;
//
int32 cover_left_icon2 = 5;
//
RightTopLiveBadge right_top_live_badge = 6;
//
string extra_uri = 7;
//
InlineProgressBar inline_progress_bar = 8;
//
TopicThreePoint topic_three_point = 9;
//
string cover_left_desc = 10;
//
bool hide_danmu_switch = 11;
//
bool disable_danmu = 12;
//
int32 can_play = 13;
//
string duration_text = 14;
//
RelationData relation_data = 15;
}
//
message LiveBadgeResource {
//
string text = 1;
//
string animation_url = 2;
//
string animation_url_hash = 3;
//
string background_color_light = 4;
//
string background_color_night = 5;
//
int64 alpha_light = 6;
//
int64 alpha_night = 7;
//
string font_color = 8;
}
//
message OperationCard {
oneof card {
//
LargeCoverInline large_cover_inline = 1;
}
}
//
message OperationContent {
//
OperationCard operation_card = 1;
}
//
message RelationData {
//
bool is_fav = 1;
//
bool is_coin = 2;
//
bool is_follow = 3;
//
bool is_like = 4;
//
int64 like_count = 5;
}
//
message RightTopLiveBadge {
//
int64 live_status = 1;
//
LiveBadgeResource in_live = 2;
//
string live_stats_desc = 3;
}
//
message SortContent {
//
int64 sort_by = 1;
//
string sort_name = 2;
}
//
message ThreePointItem {
//
string title = 1;
//
string jump_url = 2;
}
//
message TopicActivities {
//
repeated TopicActivity activity = 1;
//
string act_list_title = 2;
}
//
message TopicActivity {
//
int64 activity_id = 1;
//
string activity_name = 2;
//
string jump_url = 3;
//
string icon_url = 4;
}
//
message TopicCapsule {
//
string name = 1;
//
string jump_url = 2;
//
string icon_url = 3;
}
//
message TopicCardItem {
//
int32 type = 1;
//
bilibili.app.dynamic.v2.DynamicItem dynamic_item = 2;
//
FoldCardItem ford_card_item = 3;
}
//
message TopicCardList {
//
repeated TopicCardItem topic_card_items = 1;
//
string offset = 2;
//
bool has_more = 3;
//
TopicSortByConf topic_sort_by_conf = 4;
}
//
enum TopicCardType {
ILLEGAL_TYPE = 0; //
DYNAMIC = 1; //
FOLD = 2; //
}
//
message TopicDetailsAllReply {
//
DetailsTopInfo details_top_info = 1;
//
TopicActivities topic_activities = 2;
//
TopicCardList topic_card_list = 3;
//
FunctionalCard functional_card = 4;
}
//
message TopicDetailsAllReq {
//
int64 topic_id = 1;
//
int64 sort_by = 2;
//
string offset = 3;
//
int32 page_size = 4;
//
int32 local_time = 5;
//
bilibili.app.archive.middleware.v1.PlayerArgs player_args = 6;
//
int32 need_refresh = 7;
//
string source = 8;
}
//
message TopicDetailsFoldReply {
//
TopicCardList topic_card_list = 1;
//
int64 fold_count = 2;
}
//
message TopicDetailsFoldReq {
//
int64 topic_id = 1;
//
string offset = 2;
//
int32 page_size = 3;
//
int32 local_time = 4;
//
bilibili.app.archive.middleware.v1.PlayerArgs player_args = 5;
//
int64 from_sort_by = 6;
}
//
message TopicInfo {
//
int64 id = 1;
//
string name = 2;
//
int64 uid = 3;
//
int64 view = 4;
//
int64 discuss = 5;
//
int64 fav = 6;
//
int64 dynamics = 7;
//
int32 state = 8;
//
string jump_url = 9;
//
string backcolor = 10;
//
bool is_fav = 11;
//
string description = 12;
//
int32 create_source = 13;
//
string share_pic = 14;
//
int64 share = 15;
//
int64 like = 16;
//
string share_url = 17;
//
bool is_like = 18;
}
//
message TopicSortByConf {
//
int64 default_sort_by = 1;
//
repeated SortContent all_sort_by = 2;
//
int64 show_sort_by = 3;
}
//
message TopicThreePoint {
//
repeated ThreePointItem dyn_three_point_items = 1;
}
//
message TrafficCard {
//
string name = 1;
//
string jump_url = 2;
//
string icon_url = 3;
//
string base_pic = 4;
//
string benefit_point = 5;
//
string card_desc = 6;
//
string jump_title = 7;
}
//
message User {
//
int64 uid = 1;
//
string face = 2;
//
string name = 3;
//
string name_desc = 4;
}

View File

@ -26,6 +26,13 @@ service BroadcastTunnel {
rpc CreateTunnel(stream BroadcastFrame) returns (stream BroadcastFrame); rpc CreateTunnel(stream BroadcastFrame) returns (stream BroadcastFrame);
} }
//
enum Action {
UNKNOWN = 0; //
UPDATE = 1; //
DELETE = 2; //
}
// authorization验证绑定用户mid // authorization验证绑定用户mid
message AuthReq { message AuthReq {
// iduuid // iduuid
@ -35,28 +42,21 @@ message AuthReq {
// id // id
int64 last_msg_id = 3; int64 last_msg_id = 3;
} }
// //
message AuthResp {} message AuthResp {
//
message HeartbeatReq{}
//
message HeartbeatResp{}
// target_path
message TargetPath {
// target_paths
repeated string target_paths = 1;
} }
// // target_path:
message MessageAckReq { // "/" Service-Name "/" {method name} gRPC Request Path
// id message BroadcastFrame {
int64 ack_id = 1; //
// ack来源 FrameOption options = 1;
string ack_origin = 2; // target_path
// target_path便 string target_path = 2;
string target_path = 3; // pb内容
google.protobuf.Any body = 3;
} }
// message_id: // message_id:
@ -80,17 +80,32 @@ message FrameOption {
bilibili.rpc.Status status = 4; bilibili.rpc.Status status = 4;
// ack来源, downstream时候由服务端填写. // ack来源, downstream时候由服务端填写.
string ack_origin = 5; string ack_origin = 5;
//
int64 timestamp = 6;
} }
// target_path: //
// "/" Service-Name "/" {method name} gRPC Request Path message HeartbeatReq{
message BroadcastFrame {
//
FrameOption options = 1;
// target_path
string target_path = 2;
// pb内容
google.protobuf.Any body = 3;
} }
//
message HeartbeatResp{
}
//
message MessageAckReq {
// id
int64 ack_id = 1;
// ack来源
string ack_origin = 2;
// target_path便
string target_path = 3;
}
// target_path
message TargetPath {
// target_paths
repeated string target_paths = 1;
}

View File

@ -4,10 +4,24 @@ package bilibili.broadcast.v1;
import "google/protobuf/empty.proto"; import "google/protobuf/empty.proto";
message ModResourceResp {}
// ModManager // ModManager
service ModManager { service ModManager {
// //
rpc WatchResource(google.protobuf.Empty) returns (stream ModResourceResp); rpc WatchResource(google.protobuf.Empty) returns (stream ModResourceResp);
} }
//
message ModResourceResp {
//
int32 atcion = 1;
//
string app_key = 2;
//
string pool_name = 3;
//
string module_name = 4;
//
int64 module_version = 5;
//
int64 list_version = 6;
}

View File

@ -9,6 +9,26 @@ service Push {
rpc WatchMessage(google.protobuf.Empty) returns (stream PushMessageResp); rpc WatchMessage(google.protobuf.Empty) returns (stream PushMessageResp);
} }
//
enum LinkType {
LINK_TYPE_UNKNOWN = 0; //
LINK_TYPE_BANGUMI = 1; //
LINK_TYPE_VIDEO = 2; //
LINK_TYPE_LIVE = 3; //
}
//
message PageBlackList {
//
string id = 1;
}
//
message PageView {
//
string id = 1;
}
// //
message PushMessageResp { message PushMessageResp {
// //
@ -78,30 +98,14 @@ message PushMessageResp {
repeated PageView page_view = 13; repeated PageView page_view = 13;
// //
TargetResource target_resource = 14; TargetResource target_resource = 14;
}
// //
message PageBlackList { int32 image_frame = 15;
// //
string id = 1; int32 image_marker = 16;
}
// //
message PageView { int32 image_position = 17;
// //
string id = 1; int64 job = 18;
}
//
enum LinkType {
//
LINK_TYPE_UNKNOWN = 0;
//
LINK_TYPE_BANGUMI = 1;
//
LINK_TYPE_VIDEO = 2;
//
LINK_TYPE_LIVE = 3;
} }
// //

View File

@ -12,15 +12,19 @@ service BroadcastRoom {
} }
// //
message RoomJoinEvent {} message RoomErrorEvent {
//
bilibili.rpc.Status status = 1;
}
// //
message RoomLeaveEvent {} message RoomJoinEvent {
}
// //
message RoomOnlineEvent { message RoomLeaveEvent {
//
int32 online = 1;
} }
// //
@ -32,9 +36,11 @@ message RoomMessageEvent {
} }
// //
message RoomErrorEvent { message RoomOnlineEvent {
// //
bilibili.rpc.Status status = 1; int32 online = 1;
//
int32 all_online = 2;
} }
// //

View File

@ -14,13 +14,33 @@ service Test {
rpc WatchTestEvent(google.protobuf.Empty) returns (stream TestResp); rpc WatchTestEvent(google.protobuf.Empty) returns (stream TestResp);
} }
//
service Test2 {
//
rpc Test(AddParams) returns (google.protobuf.Empty);
}
//
message AddParams {
//
int32 a = 1;
//
int32 b = 2;
}
//
message AddResult {
//
int32 r = 1;
}
message TestResp { message TestResp {
// id // id
int64 taskid = 1 [json_name="taskid"]; int64 taskid = 1;
// //
int64 timestamp = 2 [json_name="timestamp"]; int64 timestamp = 2;
// //
string message = 3 [json_name="message"]; string message = 3;
// //
google.protobuf.Any extra = 4; google.protobuf.Any extra = 4;
} }

View File

@ -18,147 +18,26 @@ service DM {
rpc DmExpoReport (DmExpoReportReq) returns (DmExpoReportRes); rpc DmExpoReport (DmExpoReportReq) returns (DmExpoReportRes);
} }
// SDK-
message DmSegSDKReq {
// 稿avid/epid
int64 pid = 1;
// cid/cid
int64 oid = 2;
//
// 1: 2:
int32 type = 3;
// (6min)
int64 segment_index = 4;
}
// SDK-
message DmSegSDKReply {
//
// 0: 1:
bool closed = 1;
//
repeated DanmakuElem elems = 2;
}
// ott弹幕列表-
message DmSegOttReq {
// 稿avid/epid
int64 pid = 1;
// cid/cid
int64 oid = 2;
//
// 1: 2:
int32 type = 3;
// (6min)
int64 segment_index = 4;
}
// ott弹幕列表-
message DmSegOttReply {
//
// 0: 1:
bool closed = 1;
//
repeated DanmakuElem elems = 2;
}
// -
message DmSegMobileReq {
// 稿avid/epid
int64 pid = 1;
// cid/cid
int64 oid = 2;
//
// 1: 2:
int32 type = 3;
// (6min)
int64 segment_index = 4;
//
int32 teenagers_mode = 5;
}
// -
message DmSegMobileReply {
//
repeated DanmakuElem elems = 1;
//
// 0: 1:
int32 state = 2;
// ai评分值
DanmakuAIFlag ai_flag = 3;
}
// -
message DmViewReq {
// 稿avid/epid
int64 pid = 1;
// cid/cid
int64 oid = 2;
//
// 1: 2:
int32 type = 3;
// spm
string spmid = 4;
//
int32 is_hard_boot = 5;
}
// -
message DmViewReply {
//
// 0: 1:
bool closed = 1;
//
VideoMask mask = 2;
//
VideoSubtitle subtitle = 3;
// url(bfs)
repeated string special_dms = 4;
//
DanmakuFlagConfig ai_flag = 5;
//
DanmuPlayerViewConfig player_config = 6;
//
int32 send_box_style = 7;
//
bool allow = 8;
// check box
string check_box = 9;
// check box
string check_box_show_msg = 10;
//
string text_placeholder = 11;
//
string input_placeholder = 12;
// cid维度屏蔽的正则规则
repeated string report_filter_content = 13;
}
// web端弹幕元数据-
message DmWebViewReply {
//
// 0: 1:
int32 state = 1;
// //
string text = 2; message BuzzwordConfig {
// //
string text_side = 3; repeated BuzzwordShowConfig keywords = 1;
// }
DmSegConfig dm_sge = 4;
// //
DanmakuFlagConfig flag = 5; message BuzzwordShowConfig {
// url(bfs) //
repeated string special_dms = 6; string name = 1;
// check box //
bool check_box = 7; string schema = 2;
// //
int64 count = 8; int32 source = 3;
// //
repeated CommandDm commandDms = 9; int64 id = 4;
// //
DanmuWebPlayerConfig player_config = 10; int64 buzzword_id = 5;
// cid维度屏蔽 //
repeated string report_filter_content = 11; int32 schema_type = 6;
} }
// //
@ -185,93 +64,17 @@ message CommandDm {
string idStr = 10; string idStr = 10;
} }
// //
message DmSegConfig { enum DMAttrBit {
// DMAttrBitProtect = 0; //
int64 page_size = 1; DMAttrBitFromLive = 1; //
// DMAttrHighLike = 2; //
int64 total = 2;
} }
// // ai云屏蔽列表
message VideoMask { message DanmakuAIFlag {
// cid // ai云屏蔽条目
int64 cid = 1; repeated DanmakuFlag dm_flags = 1;
//
// 0:web端 1:
int32 plat = 2;
//
int32 fps = 3;
//
int64 time = 4;
// url
string mask_url = 5;
}
//
message VideoSubtitle {
//
string lan = 1;
//
string lanDoc = 2;
//
repeated SubtitleItem subtitles = 3;
}
// web端用户弹幕配置
message DanmuWebPlayerConfig {
bool dm_switch = 1; //
bool ai_switch = 2; //
int32 ai_level = 3; //
bool blocktop = 4; //
bool blockscroll = 5; //
bool blockbottom = 6; //
bool blockcolor = 7; //
bool blockspecial = 8; //
bool preventshade = 9; //
bool dmask = 10; //
float opacity = 11; //
int32 dmarea = 12; //
float speedplus = 13; //
float fontsize = 14; //
bool screensync = 15; //
bool speedsync = 16; //
string fontfamily = 17; //
bool bold = 18; // 使
int32 fontborder = 19; //
string draw_type = 20; //
}
//
message SubtitleItem {
// id
int64 id = 1;
// id str
string id_str = 2;
//
string lan = 3;
//
string lan_doc = 4;
// url
string subtitle_url = 5;
//
UserInfo author = 6;
}
//
message UserInfo {
// mid
int64 mid = 1;
//
string name = 2;
//
string sex = 3;
// url
string face = 4;
//
string sign = 5;
//
int32 rank = 6;
} }
// //
@ -305,52 +108,10 @@ message DanmakuElem {
int32 attr = 13; int32 attr = 13;
} }
//
enum DMAttrBit {
//
DMAttrBitProtect = 0;
//
DMAttrBitFromLive = 1;
//
DMAttrHighLike = 2;
}
// -
message DmPlayerConfigReq {
int64 ts = 1; //
PlayerDanmakuSwitch switch = 2; //
PlayerDanmakuSwitchSave switch_save = 3; //
PlayerDanmakuUseDefaultConfig use_default_config = 4; // 使
PlayerDanmakuAiRecommendedSwitch ai_recommended_switch = 5; //
PlayerDanmakuAiRecommendedLevel ai_recommended_level = 6; //
PlayerDanmakuBlocktop blocktop = 7; //
PlayerDanmakuBlockscroll blockscroll = 8; //
PlayerDanmakuBlockbottom blockbottom = 9; //
PlayerDanmakuBlockcolorful blockcolorful = 10; //
PlayerDanmakuBlockrepeat blockrepeat = 11; //
PlayerDanmakuBlockspecial blockspecial = 12; //
PlayerDanmakuOpacity opacity = 13; //
PlayerDanmakuScalingfactor scalingfactor = 14; //
PlayerDanmakuDomain domain = 15; //
PlayerDanmakuSpeed speed = 16; //
PlayerDanmakuEnableblocklist enableblocklist = 17; //
InlinePlayerDanmakuSwitch inlinePlayerDanmakuSwitch = 18; //
}
// -
message Response {
//
int32 code = 1;
//
string message = 2;
}
// ai云屏蔽条目 // ai云屏蔽条目
message DanmakuFlag { message DanmakuFlag {
// dmid int64 dmid = 1; // dmid
int64 dmid = 1; uint32 flag = 2; //
//
uint32 flag = 2;
} }
// //
@ -363,22 +124,6 @@ message DanmakuFlagConfig {
int32 rec_switch = 3; int32 rec_switch = 3;
} }
// ai云屏蔽列表
message DanmakuAIFlag {
// ai云屏蔽条目
repeated DanmakuFlag dm_flags = 1;
}
//
message DanmuPlayerViewConfig {
//
DanmuDefaultPlayerConfig danmuku_default_player_config = 1;
//
DanmuPlayerConfig danmuku_player_config = 2;
//
repeated DanmuPlayerDynamicConfig danmuku_player_dynamic_config = 3;
}
// //
message DanmuDefaultPlayerConfig { message DanmuDefaultPlayerConfig {
bool player_danmaku_use_default_config = 1; // 使 bool player_danmaku_use_default_config = 1; // 使
@ -395,6 +140,7 @@ message DanmuDefaultPlayerConfig {
float player_danmaku_domain = 14; // float player_danmaku_domain = 14; //
int32 player_danmaku_speed = 15; // int32 player_danmaku_speed = 15; //
bool inline_player_danmaku_switch = 16; // bool inline_player_danmaku_switch = 16; //
int32 player_danmaku_senior_mode_switch = 17; //
} }
// //
@ -417,6 +163,8 @@ message DanmuPlayerConfig {
bool player_danmaku_enableblocklist = 16; // bool player_danmaku_enableblocklist = 16; //
bool inline_player_danmaku_switch = 17; // bool inline_player_danmaku_switch = 17; //
int32 inline_player_danmaku_config = 18; // int32 inline_player_danmaku_config = 18; //
int32 player_danmaku_ios_switch_save = 19; //
int32 player_danmaku_senior_mode_switch = 20; //
} }
// //
@ -424,40 +172,376 @@ message DanmuPlayerDynamicConfig {
// //
int32 progress = 1; int32 progress = 1;
// //
float player_danmaku_domain = 2; float player_danmaku_domain = 14;
}
//
message DanmuPlayerViewConfig {
//
DanmuDefaultPlayerConfig danmuku_default_player_config = 1;
//
DanmuPlayerConfig danmuku_player_config = 2;
//
repeated DanmuPlayerDynamicConfig danmuku_player_dynamic_config = 3;
}
// web端用户弹幕配置
message DanmuWebPlayerConfig {
bool dm_switch = 1; //
bool ai_switch = 2; //
int32 ai_level = 3; //
bool blocktop = 4; //
bool blockscroll = 5; //
bool blockbottom = 6; //
bool blockcolor = 7; //
bool blockspecial = 8; //
bool preventshade = 9; //
bool dmask = 10; //
float opacity = 11; //
int32 dmarea = 12; //
float speedplus = 13; //
float fontsize = 14; //
bool screensync = 15; //
bool speedsync = 16; //
string fontfamily = 17; //
bool bold = 18; // 使
int32 fontborder = 19; //
string draw_type = 20; //
int32 senior_mode_switch = 21; //
}
//
message DmExpoReportReq {
//
string session_id = 1;
//
int64 oid = 2;
//
string spmid = 4;
}
//
message DmExpoReportRes {
}
// -
message DmPlayerConfigReq {
int64 ts = 1; //
PlayerDanmakuSwitch switch = 2; //
PlayerDanmakuSwitchSave switch_save = 3; //
PlayerDanmakuUseDefaultConfig use_default_config = 4; // 使
PlayerDanmakuAiRecommendedSwitch ai_recommended_switch = 5; //
PlayerDanmakuAiRecommendedLevel ai_recommended_level = 6; //
PlayerDanmakuBlocktop blocktop = 7; //
PlayerDanmakuBlockscroll blockscroll = 8; //
PlayerDanmakuBlockbottom blockbottom = 9; //
PlayerDanmakuBlockcolorful blockcolorful = 10; //
PlayerDanmakuBlockrepeat blockrepeat = 11; //
PlayerDanmakuBlockspecial blockspecial = 12; //
PlayerDanmakuOpacity opacity = 13; //
PlayerDanmakuScalingfactor scalingfactor = 14; //
PlayerDanmakuDomain domain = 15; //
PlayerDanmakuSpeed speed = 16; //
PlayerDanmakuEnableblocklist enableblocklist = 17; //
InlinePlayerDanmakuSwitch inlinePlayerDanmakuSwitch = 18; //
PlayerDanmakuSeniorModeSwitch senior_mode_switch = 19; //
}
//
message DmSegConfig {
//
int64 page_size = 1;
//
int64 total = 2;
}
// -
message DmSegMobileReply {
//
repeated DanmakuElem elems = 1;
//
// 0: 1:
int32 state = 2;
// ai评分值
DanmakuAIFlag ai_flag = 3;
}
// -
message DmSegMobileReq {
// 稿avid/epid
int64 pid = 1;
// cid/cid
int64 oid = 2;
//
// 1: 2:
int32 type = 3;
// (6min)
int64 segment_index = 4;
//
int32 teenagers_mode = 5;
}
// ott弹幕列表-
message DmSegOttReply {
//
// 0: 1:
bool closed = 1;
//
repeated DanmakuElem elems = 2;
}
// ott弹幕列表-
message DmSegOttReq {
// 稿avid/epid
int64 pid = 1;
// cid/cid
int64 oid = 2;
//
// 1: 2:
int32 type = 3;
// (6min)
int64 segment_index = 4;
}
// SDK-
message DmSegSDKReply {
//
// 0: 1:
bool closed = 1;
//
repeated DanmakuElem elems = 2;
}
// SDK-
message DmSegSDKReq {
// 稿avid/epid
int64 pid = 1;
// cid/cid
int64 oid = 2;
//
// 1: 2:
int32 type = 3;
// (6min)
int64 segment_index = 4;
}
// -
message DmViewReply {
//
// 0: 1:
bool closed = 1;
//
VideoMask mask = 2;
//
VideoSubtitle subtitle = 3;
// url(bfs)
repeated string special_dms = 4;
//
DanmakuFlagConfig ai_flag = 5;
//
DanmuPlayerViewConfig player_config = 6;
//
int32 send_box_style = 7;
//
bool allow = 8;
// check box
string check_box = 9;
// check box
string check_box_show_msg = 10;
//
string text_placeholder = 11;
//
string input_placeholder = 12;
// cid维度屏蔽的正则规则
repeated string report_filter_content = 13;
//
ExpoReport expo_report = 14;
//
BuzzwordConfig buzzword_config = 15;
//
repeated Expressions expressions = 16;
}
// -
message DmViewReq {
// 稿avid/epid
int64 pid = 1;
// cid/cid
int64 oid = 2;
//
// 1: 2:
int32 type = 3;
// spm
string spmid = 4;
//
int32 is_hard_boot = 5;
}
// web端弹幕元数据-
message DmWebViewReply {
//
// 0: 1:
int32 state = 1;
//
string text = 2;
//
string text_side = 3;
//
DmSegConfig dm_sge = 4;
//
DanmakuFlagConfig flag = 5;
// url(bfs)
repeated string special_dms = 6;
// check box
bool check_box = 7;
//
int64 count = 8;
//
repeated CommandDm commandDms = 9;
//
DanmuWebPlayerConfig player_config = 10;
// cid维度屏蔽
repeated string report_filter_content = 11;
//
repeated Expressions expressions = 12;
}
//
message ExpoReport {
//
bool should_report_at_end = 1;
}
//
message Expression {
//
repeated string keyword = 1;
//
string url = 2;
//
repeated Period period = 3;
}
//
message Expressions {
//
repeated Expression data = 1;
}
//
message Period {
//
int64 start = 1;
//
int64 end = 2;
} }
// //
message PlayerDanmakuSwitch {bool value = 1;bool canIgnore = 2;} message InlinePlayerDanmakuSwitch {bool value = 1;}
//
message PlayerDanmakuSwitchSave {bool value = 1;}
// 使
message PlayerDanmakuUseDefaultConfig {bool value = 1;}
//
message PlayerDanmakuAiRecommendedSwitch {bool value = 1;}
// //
message PlayerDanmakuAiRecommendedLevel {bool value = 1;} message PlayerDanmakuAiRecommendedLevel {bool value = 1;}
// //
message PlayerDanmakuBlocktop {bool value = 1;} message PlayerDanmakuAiRecommendedSwitch {bool value = 1;}
//
message PlayerDanmakuBlockscroll {bool value = 1;}
// //
message PlayerDanmakuBlockbottom {bool value = 1;} message PlayerDanmakuBlockbottom {bool value = 1;}
// //
message PlayerDanmakuBlockcolorful {bool value = 1;} message PlayerDanmakuBlockcolorful {bool value = 1;}
// //
message PlayerDanmakuBlockrepeat {bool value = 1;} message PlayerDanmakuBlockrepeat {bool value = 1;}
//
message PlayerDanmakuBlockscroll {bool value = 1;}
// //
message PlayerDanmakuBlockspecial {bool value = 1;} message PlayerDanmakuBlockspecial {bool value = 1;}
//
message PlayerDanmakuBlocktop {bool value = 1;}
//
message PlayerDanmakuDomain {float value = 1;}
//
message PlayerDanmakuEnableblocklist {bool value = 1;}
// //
message PlayerDanmakuOpacity {float value = 1;} message PlayerDanmakuOpacity {float value = 1;}
// //
message PlayerDanmakuScalingfactor {float value = 1;} message PlayerDanmakuScalingfactor {float value = 1;}
// //
message PlayerDanmakuDomain {float value = 1;} message PlayerDanmakuSeniorModeSwitch {int32 value = 1;}
// //
message PlayerDanmakuSpeed {int32 value = 1;} message PlayerDanmakuSpeed {int32 value = 1;}
//
message PlayerDanmakuEnableblocklist {bool value = 1;}
// //
message InlinePlayerDanmakuSwitch {bool value = 1;} message PlayerDanmakuSwitch {bool value = 1;bool canIgnore = 2;}
//
message PlayerDanmakuSwitchSave {bool value = 1;}
// 使
message PlayerDanmakuUseDefaultConfig {bool value = 1;}
// -
message Response {
//
int32 code = 1;
//
string message = 2;
}
//
message SubtitleItem {
// id
int64 id = 1;
// id str
string id_str = 2;
//
string lan = 3;
//
string lan_doc = 4;
// url
string subtitle_url = 5;
//
UserInfo author = 6;
//
SubtitleType type = 7;
}
enum SubtitleType {
CC = 0; // CC字幕
AI = 1; // AI生成字幕
}
//
message UserInfo {
// mid
int64 mid = 1;
//
string name = 2;
//
string sex = 3;
// url
string face = 4;
//
string sign = 5;
//
int32 rank = 6;
}
//
message VideoMask {
// cid
int64 cid = 1;
//
// 0:web端 1:
int32 plat = 2;
//
int32 fps = 3;
//
int64 time = 4;
// url
string mask_url = 5;
}
//
message VideoSubtitle {
//
string lan = 1;
//
string lanDoc = 2;
//
repeated SubtitleItem subtitles = 3;
}