&tag(Twitter, TwitterAPI, SearchAPI);
*目次 [#xf5e98c6]
#contents

*参考情報 [#j1696e96]
-[[Twitter API Wiki / Twitter Search API Method: search:http://apiwiki.twitter.com/Twitter-Search-API-Method%3A-search]]

*パラメータ [#l52f804a]
**q: [#odd6ea86]
-検索語を指定する。
-URLエンコードが必要。
-OR検索したい場合は"+OR+"で結合する。例えば「@twitterapi OR @twitter」だと
 http://search.twitter.com/search.atom?q=%40twitterapi+OR+%40twitter

*レスポンス [#k791b5a1]
JSON形式のレスポンス
#pre{{
{"results":[
     {"text":"@twitterapi  http:\/\/tinyurl.com\/ctrefg",
     "to_user_id":396524,
     "to_user":"TwitterAPI",
     "from_user":"jkoum",
     "metadata":
     {
      "result_type":"popular",
      "recent_retweets": 109
 
     },
     "id":1478555574,   
     "from_user_id":1833773,
     "iso_language_code":"nl",
     "source":"<a href="http:\/\/twitter.com\/">twitter<\/a>",
     "profile_image_url":"http:\/\/s3.amazonaws.com\/twitter_production\/profile_images\/118412707\/2522215727_a5f07da155_b_normal.jpg",
     "created_at":"Wed, 08 Apr 2009 19:22:10 +0000"},
     ... truncated ...],
     "since_id":0,
     "max_id":1480307926,
     "refresh_url":"?since_id=1480307926&q=%40twitterapi",
     "results_per_page":15,
     "next_page":"?page=2&max_id=1480307926&q=%40twitterapi",
     "completed_in":0.031704,
     "page":1,
     "query":"%40twitterapi"}
}
}}

*注意点 [#f71263be]
**レスポンスのfrom_user_idとto_user_idがuser_idではない問題 [#pfec8e0e]
-[[Issue 214 - twitter-api - Search API "from_user_id" doesn't match up with the proper Twitter "user_id" - Project Hosting on Google Code:http://code.google.com/p/twitter-api/issues/detail?id=214]]
-[[Twitterの検索APIのやっかいな問題 - func09:http://www.func09.com/wordpress/archives/876]]
-[[[Mi]みたいなもの &#187; Blog Archive &#187; Twitterのユーザーを特定する方法:http://game5.jp/blog/2010/06/04/twitter%E3%81%AE%E3%83%A6%E3%83%BC%E3%82%B6%E3%83%BC%E3%82%92%E7%89%B9%E5%AE%9A%E3%81%99%E3%82%8B%E6%96%B9%E6%B3%95/]]
-



トップ   新規 一覧 検索 最終更新   ヘルプ   最終更新のRSS