TikTokAPI-Python icon indicating copy to clipboard operation
TikTokAPI-Python copied to clipboard

downloadVideoByIdNoWatermark downloads empty file

Open khazidhea opened this issue 5 years ago • 5 comments

The "vid:" part is gone from the watermarked videofile. Is there another way to get hiddent video_id?

khazidhea avatar Sep 10 '20 09:09 khazidhea

Ill see if I can find any other way to get that hidden video_id

avilash avatar Sep 11 '20 08:09 avilash

Hi, any update to this?

naumanmunir avatar Apr 22 '21 04:04 naumanmunir

Not currently used

eos1209 avatar Oct 29 '21 04:10 eos1209

@avilash In the TikTokApi, the noWatermark part code, I am not able to find the vid: part for other videos. It shows pos = -1. So, will you please help me with this please?

bhargavsonagara avatar Jun 16 '22 06:06 bhargavsonagara

i found a solution for download video without watermark :--> ex url = https://www.tiktok.com/@blood.chan/video/7109888542192536875

url = self.request.headers['Url'] if "@" in url and "/video/" in url: id = url.split("/video/")[1].split("?")[0] api = 'https://toolav.herokuapp.com/id/?video_id='+id r = requests.get(api, headers = {'user-agent': 'okhttp'})

response = r.json()

aweme_id = response.get('item', '').get('aweme_id', '') video_url_no_wm = f"https://api.tiktokv.com/aweme/v1/play/?video_id{aweme_id}&vr_type=0&is_play_url=1&source=PackSourceEnum_PUBLISH&media_type=4" video_data_no_wm = get_req_content(video_url_no_wm, params=None, headers=self.headers) with open(f'media/without{id}.mp4', 'wb') as f: f.write(video_data_no_wm)

bhargavsonagara avatar Jun 17 '22 06:06 bhargavsonagara