I have tweepy installed with python3.6.3. Just do this in python.
# coding: utf-8
import tweepy
CONSUMER_KEY = "Consumer key"
CONSUMER_SECRET = "Consumer secret key"
auth = tweepy.OAuthHandler(CONSUMER_KEY, CONSUMER_SECRET)
ACCESS_TOKEN = "Access token"
ACCESS_SECRET = "Access secret token"
auth.set_access_token(ACCESS_TOKEN, ACCESS_SECRET)
api = tweepy.API(auth)
for tweet in api.search(q=u"iphone"):
print(tweet.text)
Information modification source: https://gist.github.com/kurozumi/fee149ff02a968b5990e98f63c049320
Click here for parts written in Japanese such as "consumer key" and "access token"! https://qiita.com/kngsym2018/items/2524d21455aac111cdee
Recommended Posts