-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] 可以正常解析,正常返回,但是下载的视频是个403文件,详情请见…… #500
Comments
请提供更多上下文信息。 |
了解,尝试一下使用APP接口获取数据,Web的返回数据有限制。 |
不对,你这个是抖音的接口,那你使用响应中的其他key尝试下载一下。 |
只有TikTok可用,抖音不可用。 |
怎么解决403问题? |
解决不了,只能用没有跨域验证的url,或者3xx moved的链接 |
问题一: |
别人的接口可能是用的ios或者安卓客户端的API,而且是付费的,我也暂时没找到douyin App的解析接口,大佬上面也说了目前4.09的版本抖音用的是web解析接口。 |
感谢大佬解惑,一直郁闷为啥人家的地址不一样,app端和web分开的啊 |
是的,目前APP的API可以付费调用,如果有需要可以看看这个项目: |
这问个问题,还被你打个广告… |
各取所需,不需要忽略即可,开源的Web接口使用这个JSON Path取播放链接也可以正常获取视频资源:
附带上来自演示站点的请求CURL:
例子: 请求代码: import http.client
conn = http.client.HTTPSConnection("www.douyin.com")
payload = ''
headers = {
}
conn.request("GET", "/aweme/v1/play/?video_id=v0300fg10000cp856k7og65v9dtsd470&line=0&file_id=69d0639ea2a44ccc8a8c1c05a0134ef2&sign=9dc3d39482d5a99c1bece975da135bc3&is_play_url=1&source=PackSourceEnum_AWEME_DETAIL", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8")) |
403 Forbidden
openresty
Date: 2024/11/13 12:31:59
Node_info: 2308-CACHE14
Request_id: c305545f97701c59e2c90c84c6c22bf1
Client_ip: 2408:8469:900:2213:49:fccf:3c2d:2e70
Forbid_code: 020200
Hit-status: MISS
The text was updated successfully, but these errors were encountered: