@@ -174,35 +174,25 @@ def __init__(
174
174
175
175
```json
176
176
{
177
- "act_reserve_create": "const int: 0",
178
- "copyright": "int, 投稿类型。1 自制,2 转载。",
179
- "source": "str: 视频来源。投稿类型为转载时注明来源,为原创时为空。",
180
- "cover": "str: 封面 URL",
181
- "desc": "str: 视频简介。",
182
- "desc_format_id": "const int: 0",
183
- "dynamic": "str: 动态信息。",
184
- "interactive": "const int: 0",
185
- "no_reprint": "int: 显示未经作者授权禁止转载,仅当为原创视频时有效。1 为启用,0 为关闭。",
186
- "open_elec": "int: 是否展示充电信息。1 为是,0 为否。",
187
- "origin_state": "const int: 0",
188
- "subtitles # 字幕设置": {
189
- "lan": "str: 字幕投稿语言,不清楚作用请将该项设置为空",
190
- "open": "int: 是否启用字幕投稿,1 or 0"
177
+ "title": "",
178
+ "copyright": 1,
179
+ "tid": 130,
180
+ "tag": "",
181
+ "desc_format_id": 9999,
182
+ "desc": "",
183
+ "recreate": -1,
184
+ "dynamic": "",
185
+ "interactive": 0,
186
+ "act_reserve_create": 0,
187
+ "no_disturbance": 0,
188
+ "no_reprint": 1,
189
+ "subtitle": {
190
+ "open": 0,
191
+ "lan": "",
191
192
},
192
- "tag": "str: 视频标签。使用英文半角逗号分隔的标签组。示例:标签 1,标签 1,标签 1",
193
- "tid": "int: 分区 ID (不能是主分区)。可以使用 channel 模块进行查询。",
194
- "title": "str: 视频标题",
195
- "up_close_danmaku": "bool: 是否关闭弹幕。",
196
- "up_close_reply": "bool: 是否关闭评论。",
197
- "up_selection_reply": "bool: 是否开启评论精选",
198
- "videos # 分 P 列表": [
199
- {
200
- "title": "str: 标题",
201
- "desc": "str: 简介",
202
- "filename": "str: preupload 时返回的 filename"
203
- }
204
- ],
205
- "dtime": "int?: 可选,定时发布时间戳(秒)"
193
+ "dolby": 0,
194
+ "lossless_music": 0,
195
+ "web_os": 1,
206
196
}
207
197
```
208
198
@@ -735,13 +725,17 @@ async def _submit(self, videos: list, cover_url: str = "") -> dict:
735
725
meta ["videos" ] = videos
736
726
737
727
self .dispatch (VideoUploaderEvents .PRE_SUBMIT .value , deepcopy (meta ))
728
+
729
+ meta ["csrf" ] = self .credential .bili_jct # csrf 不需要 print
738
730
api = _API ["submit" ]
739
731
740
732
try :
741
- params = {"csrf" : self .credential .bili_jct }
733
+ params = {"csrf" : self .credential .bili_jct , "t" : time . time () * 1000 }
742
734
headers = {"content-type" : "application/json" }
743
735
resp = (
744
- await Api (** api , credential = self .credential , no_csrf = True )
736
+ await Api (
737
+ ** api , credential = self .credential , no_csrf = True , json_body = True
738
+ )
745
739
.update_params (** params )
746
740
.update_data (** meta )
747
741
.update_headers (** headers )
0 commit comments