Coder Social home page Coder Social logo

douyinlive's Introduction

wss链接抖音抓取弹幕礼物数据


项目核心来自 https://github.com/saermart/DouyinLiveWebFetcher

改写成golang测试

新增ws链接 测试在main/main.go中

go run main/main.go --room ****抖音直播间号**** --port ****端口号****(默认为18080) --unknown false(默认为false)
unknown为是否输出未知数据.因为现在源pb还不是很全.有部分消息无法解析
最终拼接为
go run main/main.go --room 933572413882 --port 18080
也可以go build main/main.go编译成二进制文件运行
最终运行命令为
`main.exe --room 933572413882`

20240528200625.png 软件通过json格式输出数据.请自行解析 链接地址为ws://127.0.0.1:18080/ws 内置了个简单的心跳包.客户端需要每隔30s发送一次ping 1716881601495.png 有能力的可以完善下proto文件 抖音的proto相关的链接在 https://lf-cdn-tos.bytescm.com/obj/static/webcast/douyin_live/chunks/live-schema.0fa7e4bc.js 或者全局搜索webcast.im.Common也可定位相关函数

douyinlive's People

Contributors

jwwsjlm avatar

Stargazers

ALSRitter avatar Charles avatar  avatar  avatar Arthur avatar  avatar  avatar  avatar flippancy avatar  avatar luffyren avatar  avatar 大河 avatar SIR洋 avatar  avatar Bruce Zhang avatar  avatar Amor avatar  avatar  avatar  avatar destiny avatar  avatar Esword618 avatar 黑黑 avatar  avatar Mr.Tang avatar Eiog avatar LiXiuHua avatar CliffordMu avatar zhangya4548 avatar  avatar 一片叶子 avatar  avatar Bad Developer avatar  avatar  avatar  avatar Mojitocean avatar

Watchers

 avatar  avatar

douyinlive's Issues

err:websocket: bad handshake

PS D:\Users\Desktop\dydm> .\douyinlive.exe --room 96294557169 --port 18080
2024/06/23 23:25:21 false
2024/06/23 23:25:21 wss服务启动成功,链接地址为:ws://127.0.0.1:18080/ws
直播地址:96294557169
2024/06/23 23:25:23 链接失败: err:websocket: bad handshake
roomid:7383669129611430656
ttwid:1%7CtWSFGo0dOE-QGlZRNK1bs2oxZY3tJELFdEcrUswUC7E%7C1719156321%7Cb1d0c05168b0d12e087b8e36803078b2574f8d6d32a2355309d4bd8d8fc51e06

部分直播间无法连接

您好!
我在使用您的项目时,发现有些直播间在浏览器中是无法观看直播的,这些直播间就无法连接弹幕(连接不成功),请问这个您有好的解决方案吗?

20多秒一次重连正常吗?

2024/07/31 02:14:52 读取消息失败- websocket: close 1006 (abnormal closure): unexpected EOF [] -1
2024/07/31 02:14:52 尝试重新连接...
2024/07/31 02:14:53 重连成功
2024/07/31 02:15:14 读取消息失败- websocket: close 1006 (abnormal closure): unexpected EOF [] -1
2024/07/31 02:15:14 尝试重新连接...
2024/07/31 02:15:14 重连成功
2024/07/31 02:15:35 读取消息失败- websocket: close 1006 (abnormal closure): unexpected EOF [] -1
2024/07/31 02:15:35 尝试重新连接...
2024/07/31 02:15:36 重连成功
2024/07/31 02:15:57 读取消息失败- websocket: close 1006 (abnormal closure): unexpected EOF [] -1
2024/07/31 02:15:57 尝试重新连接...
2024/07/31 02:15:57 重连成功
2024/07/31 02:16:18 读取消息失败- websocket: close 1006 (abnormal closure): unexpected EOF [] -1
2024/07/31 02:16:18 尝试重新连接...
2024/07/31 02:16:18 重连成功
2024/07/31 02:16:40 读取消息失败- websocket: close 1006 (abnormal closure): unexpected EOF [] -1
2024/07/31 02:16:40 尝试重新连接...
2024/07/31 02:16:40 重连成功
2024/07/31 02:17:01 读取消息失败- websocket: close 1006 (abnormal closure): unexpected EOF [] -1
2024/07/31 02:17:01 尝试重新连接...
2024/07/31 02:17:01 重连成功
2024/07/31 02:17:22 读取消息失败- websocket: close 1006 (abnormal closure): unexpected EOF [] -1
2024/07/31 02:17:22 尝试重新连接...
2024/07/31 02:17:23 重连成功
2024/07/31 02:17:44 读取消息失败- websocket: close 1006 (abnormal closure): unexpected EOF [] -1
2024/07/31 02:17:44 尝试重新连接...
2024/07/31 02:17:44 重连成功

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.