aiogram/docs2/source/api/methods/get_chat_members_count.rst
2020-06-15 02:22:24 +03:00

46 lines
841 B
ReStructuredText

###################
getChatMembersCount
###################
Use this method to get the number of members in a chat. Returns Int on success.
Returns: :obj:`int`
.. automodule:: aiogram.api.methods.get_chat_members_count
:members:
Usage
=====
As bot method
-------------
.. code-block::
result: int = await bot.get_chat_members_count(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods import GetChatMembersCount`
- :code:`from aiogram.api.methods import GetChatMembersCount`
- :code:`from aiogram.api.methods.get_chat_members_count import GetChatMembersCount`
In handlers with current bot
----------------------------
.. code-block::
result: int = await GetChatMembersCount(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block::
result: int = await bot(GetChatMembersCount(...))