From 0ccc2ba6147c9809b7ae93a6b0d1fcfb7f2950f5 Mon Sep 17 00:00:00 2001 From: Harmon Date: Thu, 28 Jan 2021 20:14:42 -0600 Subject: [PATCH] Replace API.retweet id allowed_param with status_id parameter --- tweepy/api.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/tweepy/api.py b/tweepy/api.py index 18d7f43..9d80f46 100644 --- a/tweepy/api.py +++ b/tweepy/api.py @@ -278,16 +278,15 @@ class API: require_auth=True, **kwargs ) - def retweet(self, *args, **kwargs): + def retweet(self, status_id, *args, **kwargs): """ :reference: https://developer.twitter.com/en/docs/tweets/post-and-engage/api-reference/post-statuses-retweet-id - :allowed_param: 'id' + :allowed_param: """ return bind_api( *args, api=self, - path='/statuses/retweet/{id}.json', + path=f'/statuses/retweet/{status_id}.json', method='POST', payload_type='status', - allowed_param=['id'], require_auth=True, **kwargs ) -- 2.25.1