From e1a1592575d2aa8d5d719269bca4ca3effc8dc31 Mon Sep 17 00:00:00 2001 From: Lorenz Diener Date: Tue, 21 Nov 2017 14:33:04 +0100 Subject: [PATCH] Documented report dicts --- docs/index.rst | 14 ++++++++++++++ mastodon/Mastodon.py | 3 +++ 2 files changed, 17 insertions(+) diff --git a/docs/index.rst b/docs/index.rst index 5fc47ac..c74f8f6 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -329,6 +329,20 @@ Instance dicts 'urls': # Additional URLs dict, presently only 'streaming_api' with the stream websocket address. } +Report dicts +~~~~~~~~~~~~ +.. code-block:: python + + mastodon.reports()[0] + # Returns the folowing dictionary + { + 'id': # Numerical id of the report + 'action_taken': # True if a moderator or admin has processed the + # report, False otherwise. Note that no indication as to what action was taken is given + # and that an admin simply marking the report as processed and not doing anything else + # will set this field to True. + } + App registration and user authentication ---------------------------------------- Before you can use the mastodon API, you have to register your diff --git a/mastodon/Mastodon.py b/mastodon/Mastodon.py index 9456495..49d7e9b 100644 --- a/mastodon/Mastodon.py +++ b/mastodon/Mastodon.py @@ -470,6 +470,9 @@ class Mastodon: Fetch a list of reports made by the authenticated user. Returns a list of report dicts. + + Warning: According to the official API documentation, this + method is to be treated as not finalized as of Mastodon 2.0.0. """ return self.__api_request('GET', '/api/v1/reports')