Skip to content
echisan edited this page Aug 30, 2018 · 11 revisions

获取首页信息

  • 请求URL

/index

  • 请求方式

GET

  • 请求参数
  • 请求示例

/index

  • 返回结果
{
    "code": 0,
    "msg": "OK",
    "data": {
        "index_recommend": [
            {
                "id": 2,
                "title": "小美真好看~小美我老婆",
                "linkUrl": "/#/bangumi/22",
                "imageUrl": "https://i.imgur.com/nEAdTRs.jpg",
                "createTime": 1535560074000,
                "modifyTime": 1535560406000,
                "recommendStatus": "NORMAL",
                "publisherId": 0,
                "showIndex": true
            },
            {
                "id": 4,
                "title": "ElderDriverBroken♂Man",
                "linkUrl": "/#/bangumi/2",
                "imageUrl": "https://i.imgur.com/VXuX60F.jpg",
                "createTime": 1535560153000,
                "modifyTime": 1535560153000,
                "recommendStatus": "NORMAL",
                "publisherId": 0,
                "showIndex": true
            },
            {
                "id": 3,
                "title": "蕉忍♂疾风传",
                "linkUrl": "/#/bangumi/35",
                "imageUrl": "http://ws1.sinaimg.cn/large/7fa15162ly1fupnfaxlejj20x90imtx2.jpg",
                "createTime": 1535560117000,
                "modifyTime": 1535560117000,
                "recommendStatus": "NORMAL",
                "publisherId": 0,
                "showIndex": true
            },
            {
                "id": 1,
                "title": "【兄贵漂♂移】 重出江湖",
                "linkUrl": "/#/bangumi/36",
                "imageUrl": "http://ws1.sinaimg.cn/large/7fa15162ly1fupp6q0y6fj20dc0a0mxg.jpg",
                "createTime": 1535559909000,
                "modifyTime": 1535559909000,
                "recommendStatus": "NORMAL",
                "publisherId": 0,
                "showIndex": true
            }
        ],
        "index_sentence": "AAABBB",
        "online_watch_count": 1
    }
}

获取在观看视频的在线用户数量列表

  • 请求URL

/index/online

  • 请求方式

GET

  • 请求参数

没有

  • 请求示例

/index/online

  • 返回结果
{
    "code": 0,
    "msg": "OK",
    "data": [
        {
            "onlineCount": 1,
            "bangumiName": "ElderDriverBroken♂Man",
            "danmakuCount": 10,
            "episodeViewCount": 248,
            "epId": 13,
            "epIndex": 1,
            "bangumiId": 2,
            "title": "ElderDriverBroken♂Man"
        },
        {
            "onlineCount": 2,
            "bangumiName": "eee",
            "danmakuCount": 0,
            "episodeViewCount": 379,
            "epId": 47,
            "epIndex": 1,
            "bangumiId": 22,
            "title": "eee 第1集"
        }
    ]
}

当没有人在观看时的响应

{
    "code": 5001,
    "msg": "暂时没有人在观看视频",
    "data": []
}
Clone this wiki locally