[英]Can't access twitter profile URL - using STTwitter Wrapper
I'm using the STTwitter wrapper to connect with Twitter and I'm running AppOnly and I'm able to retrieve the tweet text with no problems. 我正在使用STTwitter包装程序与Twitter连接,并且正在运行AppOnly,并且能够毫无问题地检索推文文本。 I'm using the getStatusesUserTimelineForUserID
method for that. 我正在使用getStatusesUserTimelineForUserID
方法。
The problem is that I can't access "twitter_profile_url" or "profile_banner_url" but I can access text and tweet time and tweet ID perfectly fine. 问题是我无法访问“ twitter_profile_url”或“ profile_banner_url”,但可以很好地访问文本和tweet时间以及tweet ID。
I did however manage to get the twitter_profile_url by using the getUsersShowForUserID
method. 但是,我确实使用getUsersShowForUserID
方法来获取twitter_profile_url。
My question is that am I doing something wrong when trying to access twitter_profile_url with getStatusesUserTimelineForUserID
? 我的问题是,尝试使用getStatusesUserTimelineForUserID
访问twitter_profile_url时,我做错什么了吗? I looked over Twitter's documents and I think the reason why getUsersShowForUserID
works is because of the includeEntities property. 我查看了Twitter的文档,我认为getUsersShowForUserID
起作用的原因是因为includeEntities属性。 I'm not 100% sure on that so I was wondering if someone could clarify that for me? 我对此不确定100%,所以我想知道是否有人可以为我澄清一下?
The endpoint statuses/user_timeline.json returns a list of tweets. 端点状态/user_timeline.json返回鸣叫列表。
Each of these tweets has a user
dictionary, and this dictionary should have keys such as profile_image_url
, profile_image_url_https
, profile_banner_url
, profile_background_image_url
or profile_background_image_url_https
. 这些推文中的每一个都有一个user
字典,并且该字典应具有诸如profile_image_url
, profile_image_url_https
, profile_banner_url
, profile_background_image_url
或profile_background_image_url_https
。
So yes, it should be working, and if not then please open an issue on STTwitter project and post the exact code you're using. 所以是的,它应该可以工作,如果不能,请在STTwitter项目上打开一个问题,并发布您正在使用的确切代码。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.