From: Joshua Roesslein Date: Sat, 17 Aug 2013 07:55:04 +0000 (-0700) Subject: Add retweeters() method. X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=3f24fec6f1d55f2f0e9e675a816fe5310c8a5ad9;p=tweepy.git Add retweeters() method. - retweeters() -> statuses/retweeters/ids - Removed deprecated methods retweeted_by and retweeted_by_ids. --- diff --git a/tests/test_api.py b/tests/test_api.py index 7293a25..0515738 100644 --- a/tests/test_api.py +++ b/tests/test_api.py @@ -54,6 +54,9 @@ class TweepyAPITests(TweepyTestCase): def testretweets(self): self.api.retweets(test_tweet_id) + def testretweeters(self): + self.api.retweeters(test_tweet_id) + def testgetstatus(self): self.api.get_status(id=test_tweet_id) diff --git a/tweepy/api.py b/tweepy/api.py index 7418809..3466975 100644 --- a/tweepy/api.py +++ b/tweepy/api.py @@ -57,14 +57,6 @@ class API(object): require_auth = True ) - """/statuses/:id/retweeted_by.format""" - retweeted_by = bind_api( - path = '/statuses/{id}/retweeted_by.json', - payload_type = 'status', payload_list = True, - allowed_param = ['id', 'count', 'page'], - require_auth = True - ) - """/related_results/show/:id.format""" related_results = bind_api( path = '/related_results/show/{id}.json', @@ -73,14 +65,6 @@ class API(object): require_auth = False ) - """/statuses/:id/retweeted_by/ids.format""" - retweeted_by_ids = bind_api( - path = '/statuses/{id}/retweeted_by/ids.json', - payload_type = 'ids', - allowed_param = ['id', 'count', 'page'], - require_auth = True - ) - """ statuses/retweets_of_me """ retweets_of_me = bind_api( path = '/statuses/retweets_of_me.json', @@ -131,6 +115,12 @@ class API(object): require_auth = True ) + retweeters = bind_api( + path = '/statuses/retweeters/ids.json', + payload_type = 'ids', + allowed_param = ['id', 'cursor', 'stringify_ids'] + ) + """ users/show """ get_user = bind_api( path = '/users/show.json',