Reputation: 3927
I'm trying to 'favorite' a tweet using Twython given that I know the tweet's ID, as described in "https://dev.twitter.com/docs/api/1.1" under the "POST favorites/create" section.
There seams to be a lot of documentation on how to search, update status, etc using Twython but I have not been able to find documentation on how to use the rest of the Twitter API using Twython (other than the search, get_home_timeline, and update_status methods).
I would really appreciate if someone could help me find documentation to use all of Twitter's API methods with Twython, more specifically how to "favorite"
Thank you
Upvotes: 2
Views: 803
Reputation: 28292
Yes, there's a favorite function available. Once you retrieve a tweet with it's informations, you should be able to retweet it using Twython.create_favorite
:
twitter = Twython(APP_KEY, APP_SECRET
OAUTH_TOKEN, OAUTH_TOKEN_SECRET)
#obtain the id of tweet you want to favorite
...
tweet_id = xxx
#done obtaining it
twitter.create_favorite(id=tweet_id)
Source: Twython 3.1.1 Documentation
Upvotes: 2