Skip to content

Commit 4d482e0

Browse files
abhijeetbodas2001timabbott
authored andcommitted
zulip: Replace GET realm/filters with realm/linkifiers.
In zulip/zulip@3947b0c, we replaced the legacy endpoint to use the term "linkifier" instead of "filter" and to return the data in a dictionary format. None of the official clients currently actually use this endpoint.
1 parent 3c3c361 commit 4d482e0

File tree

1 file changed

+14
-4
lines changed

1 file changed

+14
-4
lines changed

zulip/zulip/__init__.py

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -900,15 +900,25 @@ def delete_custom_emoji(self, emoji_name: str) -> Dict[str, Any]:
900900
method='DELETE',
901901
)
902902

903-
def get_realm_filters(self) -> Dict[str, Any]:
903+
def get_realm_linkifiers(self) -> Dict[str, Any]:
904904
'''
905905
Example usage:
906906
907-
>>> client.get_realm_filters()
908-
{'result': 'success', 'msg': '', 'filters': [['#(?P<id>[0-9]+)', 'https://github.com/zulip/zulip/issues/%(id)s', 1]]}
907+
>>> client.get_realm_linkifiers()
908+
{
909+
'result': 'success',
910+
'msg': '',
911+
'linkifiers': [
912+
{
913+
'id': 1,
914+
'pattern': #(?P<id>[0-9]+)',
915+
'url_format': 'https://github.com/zulip/zulip/issues/%(id)s',
916+
},
917+
]
918+
}
909919
'''
910920
return self.call_endpoint(
911-
url='realm/filters',
921+
url='realm/linkifiers',
912922
method='GET',
913923
)
914924

0 commit comments

Comments
 (0)