Add export_invite_link bound method (#300)
This commit is contained in:
parent
5164ea78c2
commit
c9b1e09348
@ -714,3 +714,27 @@ class Chat(Object):
|
||||
"""
|
||||
|
||||
return self._client.leave_chat(self.id)
|
||||
|
||||
|
||||
def export_invite_link(self):
|
||||
"""Bound method *export_invite_link* of :obj:`Chat`.
|
||||
|
||||
Use as a shortcut for:
|
||||
|
||||
.. code-block:: python
|
||||
|
||||
client.export_chat_invite_link(123456789)
|
||||
|
||||
Example:
|
||||
.. code-block:: python
|
||||
|
||||
chat.export_invite_link()
|
||||
|
||||
Returns:
|
||||
``str``: On success, the exported invite link is returned.
|
||||
|
||||
Raises:
|
||||
ValueError: In case the chat_id belongs to a user.
|
||||
"""
|
||||
|
||||
return self._client.export_invite_link(self.id)
|
||||
|
Loading…
Reference in New Issue
Block a user