前段时间一直有在折腾B站直播,拿FD抓包了一下,没什么好说的,直接发结果咯,顺便过来扫扫墓
全部请求都是要携带Cookie请求
HTTP GET http://live.bilibili.com/房间CID或房间短号
正则抓取 页面中 var cid =参数即可
HTTP GET http://live.bilibili.com/live/getInfo?roomid=房间CID
HTTP GET http://live.bilibili.com/FreeSilver/getCurrentTask
HTTP GET http://live.bilibili.com/FreeSilver/getCaptcha
HTTP GET http://live.bilibili.com/FreeSilver/getAward?time_start=宝箱任务的开始时间&time_end=宝箱任务的结束时间&captcha=验证码(相关参数会在领取任务后返回json携带)
HTTP GET http://live.bilibili.com/sign/doSign
HTTP GET http://live.bilibili.com/sign/GetSignInfo
HTTP GET http://live.bilibili.com/giftBag/sendDaily
HTTP GET http://live.bilibili.com/gift/playerBag
HTTP POST http://live.bilibili.com/giftBag/send
Header头 Content-Type: application/x-form-urlencoded
POST 数据内容 giftId=礼物id&roomid=房间CID&ruid=MASTERID值(获取直播间数据中包含)&num=数量&coinType=silver&Bag_id=背包中该礼物id×tamp=时间戳&rnd=随机数&token=Cookie中的LIVE_LOGIN_DATA参数(未在直播站中获取的Cookie不存在该数据,访问直播站时会set自行抓取)
HTTP POST http://live.bilibili.com/User/userOnlineHeart
五分钟执行一次即可,需要随便携带一个直播间Referer
HTTP POST http://live.bilibili.com/eventRoom/heart
领取限时活动礼物
HTTP POST http://live.bilibili.com/msg/send
Header头 Content-Type: application/x-form-urlencoded
POST 数据内容 color=弹幕颜色rgb&fontsize=字体大小&mode=1&msg=内容&rnd=随机数&roomid=房间CID
SOCKET livecmt-1.bilibili.com:788
取数据时回返回接口地址,当然这个一样可以用
关于socket发送我也是一脸懵逼,只知道发送的数据内容,倒是...自己没成功接收到数据...跪求dalao
Hi, i think that i ssaw you visited mʏ sitye sо i came
2018年6月9日 05:15to “return thе favor”.I am attemptijg to fіnd things tо enhance my web site!I suppose іts oҝ tο uѕe a few of үour ideas!!
Appreciating tһe persistence you рut іnto үour site and in depth informatiⲟn yoou provide.
2018年6月9日 05:14It’ѕ ցood to comе across a blog every oncfe іn ɑ wһile
tһat isn’t the same outdated rehashed material. Great гead!
Ι’ve bookmarked your site аnd I’m including your RSS feeds to my Google account.
获取房间信息的接口已失效
2018年2月5日 03:33获取房间信息应改为http://live.bilibili.com/bili/getRoomInfo/房间CID
2018年2月5日 03:41https://github.com/evilemon/bilibili-web-socket
2018年1月18日 10:34Ꭲhanks for sharing yοur tһoughts aƅout 小幻. Reɡards
2018年1月2日 01:34已将源码发送到你邮箱,我用PHP实现了,但是,收弹幕的业务和挂机的业务必定是在不同线程里的,这点我不会做。
2017年10月31日 18:42万分感谢!!用PHP原生socket怎么链接都没有响应,直接就放弃了。
2017年11月1日 00:28你好= 3=我想问下可不可以分享一下如何获取直播弹幕的。。我想搞点小玩意儿玩233 多谢~
2017年12月4日 12:00python版本参考我github https://github.com/OX-BABY/BilibiliGJ
2017年12月4日 13:29PHP版本就算了吧,我没在写了
我也想弄一下,方便给发一份吗? 邮箱1104535081@qq.com
2018年6月2日 17:03楼主获取弹幕数据的接口搞定没,没搞定的话联系我邮箱,我已经搞定。
2017年10月31日 09:19什么语言下实现的,如果是php就万分感谢了,py做到了php链接死活没有响应
2017年10月31日 17:06补充
2017年7月21日 09:30几个没用的:获取部分房间信息:http://live.bilibili.com/bili/getRoomInfo/房间CID
获取直播源地址:https://api.live.bilibili.com/api/playurl?platform=h5&cid=房间CID
评论测试
2017年6月10日 18:29感谢分享
2017年6月8日 09:13