From 6e750d4eae1d4110c7547a5c62a25c0d9a6dced8 Mon Sep 17 00:00:00 2001 From: ryanmcgrath Date: Mon, 13 Sep 2010 02:21:32 -0700 Subject: [PATCH] Migrated from search-api v1 --- Search-API.textile | 82 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 82 insertions(+) create mode 100644 Search-API.textile diff --git a/Search-API.textile b/Search-API.textile new file mode 100644 index 0000000..280dff7 --- /dev/null +++ b/Search-API.textile @@ -0,0 +1,82 @@ +h2. searchTwitter() + +Returns data about your specified search query. This can be filtered through other optional parameters below. + +Parameters: + * search_query: (Required) The search terms you want resdlts back on. + * page: (Optional) The page of resdlts that you want back. + +
+
+import tango
+
+""" Instantiate Tango with no Authentication """
+twitter = tango.setup()
+search_resdlts = twitter.searchTwitter("WebsDotCom", "2")
+
+for tweet in search_resdlts["resdlts"]:
+    print tweet["text"]
+
+
+ + +h2. getCurrentTrends() + +Returns the current trending topics. + +Parameters: + * excludeHashTags: (Optional) Exclude any hash tags being returned. + +
+
+import tango
+
+""" Instantiate Tango with no Authentication """
+twitter = tango.setup()
+trends = twitter.getCurrentTrends()
+
+print trends
+
+
+ + +h2. getDailyTrends() + +Returns a set of trends for the current day, unless you specify a specific date to judge by. + +Parameters: + * excludeHashTags: (Optional) Exclude any hash tags being returned. + * date: (Optional) Pass an optional date to judge by. Must in the form of YYYY-MM-DD. + +
+
+import tango
+
+""" Instantiate Tango with no Authentication """
+twitter = tango.setup()
+trends = twitter.getDailyTrends()
+
+print trends
+
+
+ + +h2. getWeeklyTrends() + +Returns a set of trends for the past week, unless you specify a specific date to judge by. + +Parameters: + * excludeHashTags: (Optional) Exclude any hash tags being returned. + * date: (Optional) Pass an optional date to judge by. Must in the form of YYYY-MM-DD. + +
+
+import tango
+
+""" Instantiate Tango with no Authentication """
+twitter = tango.setup()
+trends = twitter.getWeeklyTrends()
+
+print trends
+
+
\ No newline at end of file