How to use API.statuses_lookup in Tweepy

2019-09-20 12:19发布

I am looking an example how to use "API.statuses_lookup".

1条回答
\"骚年 ilove
2楼-- · 2019-09-20 12:50

use

tweets = self.api.statuses_lookup(tweetIDs)

tweetIDs is a list of your tweet ids ,which u have from ur database or somewhere else in response you will get a status object now use for loop

**for tweet in tweets:
   #tweet obtained
   print(str(tweet['id'])+str(tweet['text']))**

u can provide maximum 100 tweets

查看更多
登录 后发表回答