[BUG] - by_username() TikTok returned a response indicating the entity is invalid
See original GitHub issueDescribe the bug
Using the by_username() function to get a dict of a users videos causes the error “TikTok returned a response indicating the entity is invalid”
The buggy code
video_dict = api.by_username(user, count=count, custom_did=did, custom_verifyFp=verifyFp)
Error Trace (if any)
Put the error trace below if there’s any error thrown.
Traceback (most recent call last):
File "C:/Users/kevin/PycharmProjects/tiktokcompilations/main.py", line 125, in main
download_videos(chosen_user, number_of_videos)
File "C:/Users/kevin/PycharmProjects/tiktokcompilations/main.py", line 21, in download_videos
video_dict = api.by_username(user, count=count, custom_did=did, custom_verifyFp=verifyFp)
File "C:\Users\kevin\tiktokcompilations\lib\site-packages\TikTokApi\tiktok.py", line 635, in by_username
**kwargs,
File "C:\Users\kevin\tiktokcompilations\lib\site-packages\TikTokApi\tiktok.py", line 595, in user_posts
res = self.get_data(url=api_url, send_tt_params=True, **kwargs)
File "C:\Users\kevin\tiktokcompilations\lib\site-packages\TikTokApi\tiktok.py", line 302, in get_data
"TikTok returned a response indicating the entity is invalid"
TikTokApi.exceptions.TikTokNotFoundError: TikTok returned a response indicating the entity is invalid
Desktop (please complete the following information):
- OS: Windows 10
- TikTokApi Version 4.0.4
Issue Analytics
- State:
- Created 2 years ago
- Comments:9 (5 by maintainers)
Top Results From Across the Web
Error Handling - TikTok for Developers
Starting with TikTok API 2.0, error responses include error codes represented as readable ... The access token is invalid or not found in...
Read more >Unofficial TikTok API in Python - TikTokApi · PyPI
This method returns a user object, primarily used for other methods within the package. def getUserObject(self, username, language='en', proxy=None). The ...
Read more >tiktok api get video url from post, video not showing
it is returning the json below, but all the urls there are not showing the actual video url that plays. it just shows...
Read more >TikAPI REST API
TikAPI is an unofficial API platform on top of TikTok. Our API is RESTful. It has predictable resource URLs. It uses HTTP response...
Read more >CHANGELOG.md · Gitee 极速下载/groupoffice - Gitee.com
Newsletter: Bug when an image was both attached as attachment and inline. ActiveSync: duplicate Reference and in-reply-to header; Core: Added Kosovo to the ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Just set your custom aid for trending, and keep lib default for user_pager and it will work.
aid=1284
was working for a few weeks with no issues. Setting it back to 1988 does fix demo_user_pager.py, but setting 'aid=1284` is to fix the bug where by_trending() only returns videos from @tiktok. So I guess I can get trending users, or download videos, but not both?