Update yy.go

pull/51/head
肥羊 3 years ago committed by GitHub
parent 757acb69e1
commit d327f8f392
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      Golang/liveurls/yy.go

@ -57,7 +57,7 @@ func (y *Yy) GetLiveUrl() any {
}
millis_13 := time.Now().UnixNano() / int64(time.Millisecond)
millis_10 := time.Now().Unix()
data := fmt.Sprintf(`{"head":{"seq":%d,"appidstr":"0","bidstr":"121","cidstr":"%s","sidstr":"%s","uid64":0,"client_type":108,"client_ver":"5.11.0-alpha.4","stream_sys_ver":1,"app":"yylive_web","playersdk_ver":"5.11.0-alpha.4","thundersdk_ver":"0","streamsdk_ver":"5.11.0-alpha.4"},"client_attribute":{"client":"web","model":"","cpu":"","graphics_card":"","os":"chrome","osversion":"106.0.0.0","vsdk_version":"","app_identify":"","app_version":"","business":"","width":"1536","height":"864","scale":"","client_type":8,"h265":0},"avp_parameter":{"version":1,"client_type":8,"service_type":0,"imsi":0,"send_time":%d,"line_seq":-1,"gear":%s,"ssl":1,"stream_format":0}}`, millis_13, rid, rid, millis_10, quality)
data := fmt.Sprintf(`{"head":{"seq":%d,"appidstr":"0","bidstr":"121","cidstr":"%s","sidstr":"%s","uid64":0,"client_type":108,"client_ver":"5.14.13","stream_sys_ver":1,"app":"yylive_web","playersdk_ver":"5.14.13","thundersdk_ver":"0","streamsdk_ver":"5.14.13"},"client_attribute":{"client":"web","model":"","cpu":"","graphics_card":"","os":"chrome","osversion":"106.0.0.0","vsdk_version":"","app_identify":"","app_version":"","business":"","width":"1536","height":"864","scale":"","client_type":8,"h265":0},"avp_parameter":{"version":1,"client_type":8,"service_type":0,"imsi":0,"send_time":%d,"line_seq":-1,"gear":%s,"ssl":1,"stream_format":0}}`, millis_13, rid, rid, millis_10, quality)
url := "https://stream-manager.yy.com/v3/channel/streams?uid=0&cid=" + rid + "&sid=" + rid + "&appid=0&sequence=" + strconv.FormatInt(millis_13, 10) + "&encode=json"
req, _ = http.NewRequest("POST", url, bytes.NewBuffer([]byte(data)))
req.Header.Set("Content-Type", "text/plain;charset=UTF-8")

Loading…
Cancel
Save