2020-03-04 18:55:14 +08:00
|
|
|
|
# 视频状态数
|
|
|
|
|
|
2022-09-18 00:54:17 +08:00
|
|
|
|
- [视频状态数(仅avid)](#视频状态数仅avid)
|
|
|
|
|
- [视频状态数(bvid/avid)](#视频状态数bvid/avid)
|
2020-11-20 20:13:12 +08:00
|
|
|
|
|
|
|
|
|
---
|
|
|
|
|
|
2021-07-12 21:31:27 +08:00
|
|
|
|
## 视频状态数(仅avid)
|
2020-03-23 16:46:13 +08:00
|
|
|
|
> http://api.bilibili.com/archive_stat/stat
|
2020-03-04 18:55:14 +08:00
|
|
|
|
|
2020-07-14 18:44:44 +08:00
|
|
|
|
*请求方式:GET*
|
2020-03-04 18:55:14 +08:00
|
|
|
|
|
2020-06-08 22:44:46 +08:00
|
|
|
|
**url参数:**
|
2020-04-16 18:47:19 +08:00
|
|
|
|
|
2020-04-02 16:53:01 +08:00
|
|
|
|
| 参数名 | 类型 | 内容 | 必要性 | 备注 |
|
|
|
|
|
| ------ | ---- | -------- | ------ | ---- |
|
2021-07-12 21:31:27 +08:00
|
|
|
|
| aid | num | 稿件avid | 必要 | |
|
2020-03-04 18:55:14 +08:00
|
|
|
|
|
2020-03-04 19:40:19 +08:00
|
|
|
|
**json回复:**
|
2020-03-16 00:28:23 +08:00
|
|
|
|
|
2020-04-16 18:47:19 +08:00
|
|
|
|
根对象:
|
|
|
|
|
|
2020-03-25 12:05:53 +08:00
|
|
|
|
| 字段 | 类型 | 内容 | 备注 |
|
|
|
|
|
| ------- | ---- | -------- | ----------------------------------------------- |
|
|
|
|
|
| code | num | 返回值 | 0:成功<br />40001:请求错误<br />40003:无视频 |
|
|
|
|
|
| message | str | 错误信息 | 默认为0 |
|
2020-07-17 23:50:28 +08:00
|
|
|
|
| ttl | num | 1 | |
|
2020-03-25 12:05:53 +08:00
|
|
|
|
| data | obj | 信息本体 | |
|
2020-03-04 18:55:14 +08:00
|
|
|
|
|
2020-03-21 14:37:55 +08:00
|
|
|
|
`data`对象:
|
|
|
|
|
|
2020-04-08 16:20:28 +08:00
|
|
|
|
| 字段 | 类型 | 内容 | 备注 |
|
|
|
|
|
| ---------- | ------------------------ | ------------------------------ | -------------------- |
|
2021-07-12 21:31:27 +08:00
|
|
|
|
| aid | num | 稿件avid | |
|
2020-04-08 16:20:28 +08:00
|
|
|
|
| view | 正常:num<br />屏蔽:str | 正常:播放次数<br />屏蔽:"--" | |
|
|
|
|
|
| danmaku | num | 弹幕条数 | |
|
|
|
|
|
| reply | num | 评论条数 | |
|
|
|
|
|
| favorite | num | 收藏人数 | |
|
|
|
|
|
| coin | num | 投币枚数 | |
|
|
|
|
|
| share | num | 分享次数 | |
|
|
|
|
|
| now_rank | num | 0 | 作用尚不明确 |
|
|
|
|
|
| his_rank | num | 历史最高排行 | |
|
|
|
|
|
| like | num | 获赞次数 | |
|
|
|
|
|
| dislike | num | 0 | 作用尚不明确 |
|
|
|
|
|
| no_reprint | num | 禁止转载标志 | 0:无<br />1:禁止 |
|
|
|
|
|
| copyright | num | 版权标志 | 1:自制<br />2:转载 |
|
2020-03-04 18:55:14 +08:00
|
|
|
|
|
2020-04-16 18:47:19 +08:00
|
|
|
|
**示例:**
|
2020-03-04 18:55:14 +08:00
|
|
|
|
|
2020-04-08 16:20:28 +08:00
|
|
|
|
查询视频`av91572143`的状态数
|
|
|
|
|
|
2021-07-12 21:31:27 +08:00
|
|
|
|
avid方式:
|
2020-07-14 18:44:44 +08:00
|
|
|
|
|
|
|
|
|
```shell
|
2020-10-16 19:31:41 +08:00
|
|
|
|
curl -G 'http://api.bilibili.com/archive_stat/stat' \
|
2020-07-14 18:44:44 +08:00
|
|
|
|
--data-urlencode 'aid=91572143'
|
|
|
|
|
```
|
2020-03-23 16:46:13 +08:00
|
|
|
|
|
2020-08-31 16:37:38 +08:00
|
|
|
|
<details>
|
|
|
|
|
<summary>查看响应示例:</summary>
|
|
|
|
|
|
2020-03-06 17:23:49 +08:00
|
|
|
|
```json
|
2020-03-04 18:55:14 +08:00
|
|
|
|
{
|
|
|
|
|
"code": 0,
|
|
|
|
|
"message": "0",
|
|
|
|
|
"ttl": 1,
|
|
|
|
|
"data": {
|
|
|
|
|
"aid": 91572143,
|
|
|
|
|
"view": 2236510,
|
|
|
|
|
"danmaku": 37856,
|
|
|
|
|
"reply": 5723,
|
|
|
|
|
"favorite": 131317,
|
|
|
|
|
"coin": 143389,
|
|
|
|
|
"share": 44598,
|
|
|
|
|
"now_rank": 0,
|
|
|
|
|
"his_rank": 4,
|
|
|
|
|
"like": 264314,
|
|
|
|
|
"dislike": 0,
|
|
|
|
|
"no_reprint": 1,
|
|
|
|
|
"copyright": 1
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
```
|
|
|
|
|
|
2020-08-31 16:37:38 +08:00
|
|
|
|
</details>
|
|
|
|
|
|
2021-07-12 21:31:27 +08:00
|
|
|
|
## 视频状态数(bvid/avid)
|
2020-04-08 16:20:28 +08:00
|
|
|
|
|
2020-03-23 16:46:13 +08:00
|
|
|
|
> http://api.bilibili.com/x/web-interface/archive/stat
|
2020-03-04 18:55:14 +08:00
|
|
|
|
|
2020-07-14 18:44:44 +08:00
|
|
|
|
*请求方式:GET*
|
2020-03-07 16:14:18 +08:00
|
|
|
|
|
2020-07-14 18:44:44 +08:00
|
|
|
|
此接口请求头中UA值存在`python`字串,会返回-412错误
|
2020-03-04 18:55:14 +08:00
|
|
|
|
|
2020-06-08 22:44:46 +08:00
|
|
|
|
**url参数:**
|
2020-04-16 18:47:19 +08:00
|
|
|
|
|
2020-06-21 15:38:08 +08:00
|
|
|
|
| 参数名 | 类型 | 内容 | 必要性 | 备注 |
|
|
|
|
|
| ------ | ---- | -------- | ------------ | ------------------ |
|
2021-07-12 21:31:27 +08:00
|
|
|
|
| aid | num | 稿件avid | 必要(可选) | avid与bvid任选一个 |
|
|
|
|
|
| bvid | str | 稿件bvid | 必要(可选) | avid与bvid任选一个 |
|
2020-03-04 18:55:14 +08:00
|
|
|
|
|
2020-03-21 14:37:55 +08:00
|
|
|
|
**json回复:**
|
2020-03-16 00:28:23 +08:00
|
|
|
|
|
2020-04-16 18:47:19 +08:00
|
|
|
|
根对象:
|
|
|
|
|
|
2020-07-14 18:44:44 +08:00
|
|
|
|
| 字段 | 类型 | 内容 | 备注 |
|
|
|
|
|
| ------- | ---- | -------- | ------------------------------------------------------------ |
|
|
|
|
|
| code | num | 返回值 | 0:成功 <br />-400:请求错误<br />-412:请求被拦截<br />40003:无视频 |
|
|
|
|
|
| message | str | 错误信息 | 默认为0 |
|
2020-07-17 23:50:28 +08:00
|
|
|
|
| ttl | num | 1 | |
|
2020-07-14 18:44:44 +08:00
|
|
|
|
| data | obj | 信息本体 | |
|
2020-03-04 18:55:14 +08:00
|
|
|
|
|
2020-03-21 14:37:55 +08:00
|
|
|
|
`data`对象:
|
|
|
|
|
|
2020-04-08 16:20:28 +08:00
|
|
|
|
| 字段 | 类型 | 内容 | 备注 |
|
|
|
|
|
| ---------- | ------------------------ | ------------------------------ | -------------------- |
|
2021-07-12 21:31:27 +08:00
|
|
|
|
| aid | num | 稿件avid | |
|
|
|
|
|
| bvid | str | 稿件bvid | |
|
2020-04-08 16:20:28 +08:00
|
|
|
|
| view | 正常:num<br />屏蔽:str | 正常:播放次数<br />屏蔽:"--" | |
|
|
|
|
|
| danmaku | num | 弹幕条数 | |
|
|
|
|
|
| reply | num | 评论条数 | |
|
|
|
|
|
| favorite | num | 收藏人数 | |
|
|
|
|
|
| coin | num | 投币枚数 | |
|
|
|
|
|
| share | num | 分享次数 | |
|
|
|
|
|
| now_rank | num | 0 | 作用尚不明确 |
|
|
|
|
|
| his_rank | num | 历史最高排行 | |
|
|
|
|
|
| like | num | 获赞次数 | |
|
|
|
|
|
| dislike | num | 0 | 作用尚不明确 |
|
|
|
|
|
| no_reprint | num | 禁止转载标志 | 0:无<br />1:禁止 |
|
|
|
|
|
| copyright | num | 版权标志 | 1:自制<br />2:转载 |
|
|
|
|
|
| argue_msg | str | 警告信息 | 默认为空 |
|
|
|
|
|
| evaluation | str | 视频评分 | 默认为空 |
|
2020-03-04 18:55:14 +08:00
|
|
|
|
|
2020-04-16 18:47:19 +08:00
|
|
|
|
**示例:**
|
2020-03-04 18:55:14 +08:00
|
|
|
|
|
2020-04-08 16:20:28 +08:00
|
|
|
|
查询视频`av2271112`/`BV1es411D7sW`的状态数
|
|
|
|
|
|
2021-07-12 21:31:27 +08:00
|
|
|
|
avid方式:
|
2020-03-23 16:46:13 +08:00
|
|
|
|
|
2020-07-14 18:44:44 +08:00
|
|
|
|
```shell
|
2020-10-16 19:31:41 +08:00
|
|
|
|
curl -G 'http://api.bilibili.com/x/web-interface/archive/stat' \
|
2020-07-14 18:44:44 +08:00
|
|
|
|
--data-urlencode 'aid=2271112'
|
|
|
|
|
```
|
|
|
|
|
|
2021-07-12 21:31:27 +08:00
|
|
|
|
bvid方式:
|
2020-07-14 18:44:44 +08:00
|
|
|
|
|
|
|
|
|
```shell
|
2020-10-16 19:31:41 +08:00
|
|
|
|
curl -G 'http://api.bilibili.com/x/web-interface/archive/stat' \
|
2020-07-14 18:44:44 +08:00
|
|
|
|
--data-urlencode 'bvid=BV1es411D7sW'
|
|
|
|
|
```
|
2020-03-23 16:46:13 +08:00
|
|
|
|
|
2020-08-31 16:37:38 +08:00
|
|
|
|
<details>
|
|
|
|
|
<summary>查看响应示例:</summary>
|
|
|
|
|
|
2020-03-07 16:14:18 +08:00
|
|
|
|
```json
|
2020-03-04 18:55:14 +08:00
|
|
|
|
{
|
|
|
|
|
"code": 0,
|
|
|
|
|
"message": "0",
|
|
|
|
|
"ttl": 1,
|
|
|
|
|
"data": {
|
|
|
|
|
"aid": 2271112,
|
2020-03-23 16:46:13 +08:00
|
|
|
|
"bvid": "BV1es411D7sW",
|
|
|
|
|
"view": 26408224,
|
|
|
|
|
"danmaku": 161919,
|
|
|
|
|
"reply": 52825,
|
|
|
|
|
"favorite": 892560,
|
|
|
|
|
"coin": 599649,
|
|
|
|
|
"share": 240573,
|
|
|
|
|
"like": 628592,
|
2020-03-04 18:55:14 +08:00
|
|
|
|
"now_rank": 0,
|
|
|
|
|
"his_rank": 4,
|
|
|
|
|
"no_reprint": 0,
|
|
|
|
|
"copyright": 1,
|
|
|
|
|
"argue_msg": "",
|
|
|
|
|
"evaluation": ""
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
```
|
|
|
|
|
|
2020-08-31 16:37:38 +08:00
|
|
|
|
</details>
|
|
|
|
|
|
2020-07-14 18:44:44 +08:00
|
|
|
|
当UA为`2333python2333`时,则无法访问此接口:
|
|
|
|
|
|
|
|
|
|
```shell
|
2020-10-16 19:31:41 +08:00
|
|
|
|
curl -G 'http://api.bilibili.com/x/web-interface/archive/stat' \
|
|
|
|
|
--data-urlencode 'aid=2271112' \
|
2020-07-14 18:44:44 +08:00
|
|
|
|
-A '2333python2333'
|
|
|
|
|
```
|
2020-03-04 18:55:14 +08:00
|
|
|
|
|
2020-08-31 16:37:38 +08:00
|
|
|
|
<details>
|
|
|
|
|
<summary>查看响应示例:</summary>
|
|
|
|
|
|
2020-07-14 18:44:44 +08:00
|
|
|
|
```json
|
|
|
|
|
{
|
|
|
|
|
"code":-412,
|
|
|
|
|
"message":"请求被拦截",
|
|
|
|
|
"ttl":1,
|
|
|
|
|
"data":null
|
|
|
|
|
}
|
|
|
|
|
```
|
2020-03-04 18:55:14 +08:00
|
|
|
|
|
2020-08-31 16:37:38 +08:00
|
|
|
|
</details>
|