Commit c34a3f73 authored by Josh Roesslein's avatar Josh Roesslein
Browse files

Added retweet API methods.

parent 73ac94d8
......@@ -5,6 +5,7 @@ during upgrade will be listed here.
=======================
+ Fixes
+ Google App Engine fixes (thanks Thomas Bohmbach, Jr)
+ Added Retweet API methods
1.0 -> 1.0.1
============
......
......@@ -3,6 +3,6 @@ The plan of attack for the next version of Tweepy.
1.0.1 -> 1.0.2
============
+ implement win32 file locking for FileCache
+ merge retweet API methods into master
+ implement retweet streaming API method
+ add retweet API methods [DONE]
+ add retweet streaming method
......@@ -43,6 +43,14 @@ class API(object):
allowed_param = []
)
"""Get home timeline"""
home_timeline = bind_api(
path = '/statuses/home_timeline.json',
parser = parse_statuses,
allowed_param = ['since_id', 'max_id', 'count', 'page'],
require_auth = True
)
"""Get friends timeline"""
friends_timeline = bind_api(
path = '/statuses/friends_timeline.json',
......@@ -67,6 +75,30 @@ class API(object):
require_auth = True
)
"""Get Retweets posted by user"""
retweeted_by_me = bind_api(
path = '/statuses/retweeted_by_me.json',
parser = parse_statuses,
allowed_param = ['since_id', 'max_id', 'count', 'page'],
require_auth = True
)
"""Get Retweets posted by user's friends"""
retweeted_to_me = bind_api(
path = '/statuses/retweeted_to_me.json',
parser = parse_statuses,
allowed_param = ['since_id', 'max_id', 'count', 'page'],
require_auth = True
)
"""Get Retweets of the user's tweets posted by others"""
retweets_of_me = bind_api(
path = '/statuses/retweets_of_me.json',
parser = parse_statuses,
allowed_param = ['since_id', 'max_id', 'count', 'page'],
require_auth = True
)
"""Show status"""
get_status = bind_api(
path = '/statuses/show.json',
......@@ -92,6 +124,15 @@ class API(object):
require_auth = True
)
"""Retweet a tweet"""
retweet = bind_api(
path = '/statuses/retweet/id.json',
method = 'POST',
parser = parse_status,
allowed_param = ['id'],
require_auth = True
)
"""Show user"""
get_user = bind_api(
path = '/users/show.json',
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment