How to get the media url for a particular image from a tweet status.
I am using python-twitter library 0.8.
statuses = api.GetUserTimeline(count=1, include_entities=True)
Status structure provided by Twitter is
status.created_at
status.created_at_in_seconds # read only
status.favorited
status.in_reply_to_screen_name
status.in_reply_to_user_id
status.in_reply_to_status_id
status.truncated
status.source
status.id
status.text
status.location
status.relative_created_at # read only
status.user
status.urls
status.user_mentions
status.hashtags
status.geo
status.place
status.coordinates
status.contributorsstatus.text提供了包含图像的文本和推特页面url,但我对获取图像url本身很感兴趣。我在哪里可以得到它?
发布于 2012-04-20 11:20:16
api代码不包含Status对象中的media node元素。我们可以重写库,或者修改和更新库的git代码库,以确保Status对象也包含媒体元素。
https://stackoverflow.com/questions/9988281
复制相似问题