LoginSignup
1
0

More than 5 years have passed since last update.

twitter ユーザ指定検索

Last updated at Posted at 2018-09-11

twitterの検索時に指定するqueryの指定方法については、

に詳しく書いてある。投稿者指定の検索方法は、query に
from:xxx を指定すれば良い。

tweepyの場合。

tweet = api.search(q='xxx from:yyy', ..., tweet_mode='extended')
tweet[0].full_text

でも検索文字列に日本語を指定するとうまくいかないんだよな。文字コードの問題なんだろうか? でもfromを設定しなければ日本語でもちゃんと検索できるのでそういう問題ではない気がしている。

あちらを立てればこちらが立たずばっかり。

python-twitterの場合。

tweet = api.GetSearch(term='from:xxx', ...)
tweet[0].text
1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0