tiktok-scraper icon indicating copy to clipboard operation
tiktok-scraper copied to clipboard

Downloaded video files are empty (0 bytes)

Open buggy1985 opened this issue 1 year ago • 7 comments

When using downloadAllVideosFromUser, the created files are all empty. I tried with different usernames, and also with a cookies.txt file, but I'm getting the same results. There are no errors on the console.

EDIT: After some debugging, it turns out that the URLs return a 403 status code. Any ideas how to get around this?

Let me know if I can help with any further details.

buggy1985 avatar Mar 09 '23 12:03 buggy1985

Are you using a VPN?

SwissAlps2 avatar Mar 10 '23 10:03 SwissAlps2

Using the fetchVideo method, I get downloadUrl and when I try to go to the address, I get a 403 response. Perhaps I somehow download the resource wrong, who in the topic show your implementation in the documentation of the solution did not see.

dsedinkin avatar Mar 11 '23 10:03 dsedinkin

Is there a dependence on the region? If there is a vpn with which region should I use?

dsedinkin avatar Mar 11 '23 10:03 dsedinkin

Using the fetchVideo method, I get downloadUrl and when I try to go to the address, I get a 403 response. Perhaps I somehow download the resource wrong, who in the topic show your implementation in the documentation of the solution did not see.

I was able to reproduce this issue and you are right. I will be looking into it. Thanks for the feedback

naseif avatar Mar 11 '23 14:03 naseif

When using downloadAllVideosFromUser, the created files are all empty. I tried with different usernames, and also with a cookies.txt file, but I'm getting the same results. There are no errors on the console.

EDIT: After some debugging, it turns out that the URLs return a 403 status code. Any ideas how to get around this?

Let me know if I can help with any further details.

I guess this has something to do with the tiktok api endpoint that the library is using to get the videos. I guess they have added extra authentication to the links. I still did not look into it but from your feedback I guess this is the case. I will look into it and give you updates. Thanks for the feedback

naseif avatar Mar 11 '23 14:03 naseif

Is there a dependence on the region? If there is a vpn with which region should I use?

As far as I know, you do not need vpn to access specific videos on tiktok so no

naseif avatar Mar 11 '23 14:03 naseif

Any updates here by chance?

j0hnm4r5 avatar Apr 14 '23 20:04 j0hnm4r5