Using Twython to 'favorite' a tweet

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

Answers


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


Need Your Help

Include rows even if count is zero

sql sql-server sql-server-2008

I'm listing out how many cases each person has in a table. I would like to include everyone that has a case at all (there is no separate user-table), even if they have no cases this week.

Git clone: Protocol https not supported or disabled in libcurl

git https network-protocols

I got an error message showing Protocol https not supported or disabled in libcurl