diff options
Diffstat (limited to 'mastodon')
-rw-r--r-- | mastodon/Mastodon.py | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/mastodon/Mastodon.py b/mastodon/Mastodon.py index c22cabe..0304b8f 100644 --- a/mastodon/Mastodon.py +++ b/mastodon/Mastodon.py | |||
@@ -1650,13 +1650,23 @@ class Mastodon: | |||
1650 | # Reading data: Bookmarks | 1650 | # Reading data: Bookmarks |
1651 | ### | 1651 | ### |
1652 | @api_version("3.1.0", "3.1.0", __DICT_VERSION_STATUS) | 1652 | @api_version("3.1.0", "3.1.0", __DICT_VERSION_STATUS) |
1653 | def bookmarks(self): | 1653 | def bookmarks(self, max_id=None, min_id=None, since_id=None, limit=None): |
1654 | """ | 1654 | """ |
1655 | Get a list of statuses bookmarked by the logged-in user. | 1655 | Get a list of statuses bookmarked by the logged-in user. |
1656 | 1656 | ||
1657 | Returns a list of `toot dicts`_. | 1657 | Returns a list of `toot dicts`_. |
1658 | """ | 1658 | """ |
1659 | return self.__api_request('GET', '/api/v1/bookmarks') | 1659 | if max_id != None: |
1660 | max_id = self.__unpack_id(max_id) | ||
1661 | |||
1662 | if min_id != None: | ||
1663 | min_id = self.__unpack_id(min_id) | ||
1664 | |||
1665 | if since_id != None: | ||
1666 | since_id = self.__unpack_id(since_id) | ||
1667 | |||
1668 | params = self.__generate_params(locals()) | ||
1669 | return self.__api_request('GET', '/api/v1/bookmarks', params) | ||
1660 | 1670 | ||
1661 | ### | 1671 | ### |
1662 | # Writing data: Statuses | 1672 | # Writing data: Statuses |
@@ -3247,7 +3257,7 @@ class Mastodon: | |||
3247 | if (key in json_object and isinstance(json_object[key], six.text_type)): | 3257 | if (key in json_object and isinstance(json_object[key], six.text_type)): |
3248 | if json_object[key].lower() == 'true': | 3258 | if json_object[key].lower() == 'true': |
3249 | json_object[key] = True | 3259 | json_object[key] = True |
3250 | if json_object[key].lower() == 'False': | 3260 | if json_object[key].lower() == 'false': |
3251 | json_object[key] = False | 3261 | json_object[key] = False |
3252 | return json_object | 3262 | return json_object |
3253 | 3263 | ||