From b97038e070f0139c8bad093d5b1f95fc38706b57 Mon Sep 17 00:00:00 2001 From: Josh Roesslein Date: Wed, 14 Oct 2009 16:42:13 -0500 Subject: [PATCH] Add API.report_spam method. --- CHANGES | 1 + tweepy/api.py | 18 ++++++++++++++++++ 2 files changed, 19 insertions(+) diff --git a/CHANGES b/CHANGES index 7440869..22415d1 100644 --- a/CHANGES +++ b/CHANGES @@ -18,6 +18,7 @@ during upgrade will be listed here. Parser updated to handle cursor responses. See above. + Fix Status.source_url parsing + Fix search result 'source' parsing to properly unescape html and extract source + + Added report_spam method + Cursor Added the Cursor object to help with pagination within the API. diff --git a/tweepy/api.py b/tweepy/api.py index c5c917d..ef42553 100644 --- a/tweepy/api.py +++ b/tweepy/api.py @@ -848,6 +848,24 @@ class API(object): require_auth = True ) + """ report_spam + + The user specified in the id is blocked by the authenticated user + and reported as a spammer. + + Parameters: id or user_id or screen_name + Returns: User + + http://apiwiki.twitter.com/Twitter-REST-API-Method%3A-report_spam + """ + report_spam = bind_api( + path = '/report_spam.json', + method = 'POST', + parser = parse_user, + allowed_param = ['id', 'user_id', 'screen_name'], + require_auth = True + ) + """ saved_searches Returns the authenticated user's saved search queries. -- 2.25.1