Upgrade architecture + 5.0 Bot API (#469)

Upgrade architecture + 5.0 Bot API (#469)
* Moved `methods`, `types` and `client` to root package
* Removed update handler from routers to dispatcher
* Reworked events propagation mechanism to handlers
* Reworked inner middlewares logic (very small change)
* Updated to Bot API 5.0
* Initial migration from MkDocs to Sphinx + config for readthedocs
This commit is contained in:
Alex Root Junior 2021-01-26 21:20:52 +02:00 committed by GitHub
parent 566b7ff282
commit 4008a3114d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
608 changed files with 12537 additions and 6427 deletions

17
docs2/api/bot.rst Normal file
View file

@ -0,0 +1,17 @@
###
Bot
###
Bot instance can be created from :code:`aiogram.Bot` (:code:`from aiogram import Bot`) and
you can't use methods without instance of bot with configured token.
This class has aliases for all methods and named in :code:`lower_camel_case`.
For example :code:`sendMessage` named :code:`send_message` and has the same specification with all class-based methods.
.. autoclass:: aiogram.client.bot.Bot
:members:
:show-inheritance:
:member-order: bysource
:special-members: __init__
:undoc-members: True

View file

@ -0,0 +1,98 @@
#####################
How to download file?
#####################
Download file manually
======================
First, you must get the `file_id` of the file you want to download.
Information about files sent to the bot is contained in `Message <types/message.html>`__.
For example, download the document that came to the bot.
.. code-block::
file_id = message.document.file_id
Then use the `getFile <methods/get_file.html>`__ method to get `file_path`.
.. code-block::
file = await bot.get_file(file_id)
file_path = file.file_path
After that, use the `download_file <#download-file>`__ method from the bot object.
download_file(...)
------------------
Download file by `file_path` to destination.
If you want to automatically create destination (:obj:`io.BytesIO`) use default
value of destination and handle result of this method.
.. autoclass:: aiogram.client.bot.Bot
:members: download_file
:exclude-members: __init__
There are two options where you can download the file: to **disk** or to **binary I/O object**.
Download file to disk
---------------------
To download file to disk, you must specify the file name or path where to download the file.
In this case, the function will return nothing.
.. code-block::
await bot.download_file(file_path, "text.txt")
Download file to binary I/O object
----------------------------------
To download file to binary I/O object, you must specify an object with the
:obj:`typing.BinaryIO` type or use the default (:obj:`None`) value.
In the first case, the function will return your object:
.. code-block::
my_object = MyBinaryIO()
result: MyBinaryIO = await bot.download_file(file_path, my_object)
# print(result is my_object) # True
If you leave the default value, an :obj:`io.BytesIO` object will be created and returned.
.. code-block::
result: io.BytesIO = await bot.download_file(file_path)
Download file in short way
==========================
Getting `file_path` manually every time is boring, so you should use the `download <#download>`__ method.
download(...)
-------------
Download file by `file_id` or `Downloadable` object to destination.
If you want to automatically create destination (:obj:`io.BytesIO`) use default
value of destination and handle result of this method.
.. autoclass:: aiogram.client.bot.Bot
:members: download
:exclude-members: __init__
It differs from `download_file <#download-file>`__ **only** in that it accepts `file_id`
or an `Downloadable` object (object that contains the `file_id` attribute) instead of `file_path`.
You can download a file to `disk <#download-file-to-disk>`__ or to a `binary I/O <#download-file-to-binary-io-object>`__ object in the same way.
Example:
.. code-block::
document = message.document
await bot.download(document)

15
docs2/api/index.rst Normal file
View file

@ -0,0 +1,15 @@
#######
Bot API
#######
**aiogram** now is fully support of `Telegram Bot API <https://core.telegram.org/bots/api>`_
All methods and types is fully autogenerated from Telegram Bot API docs by parser with code-generator.
.. toctree::
bot
session/index
types/index
methods/index
download_file
upload_file

View file

@ -0,0 +1,51 @@
###############
addStickerToSet
###############
Returns: :obj:`bool`
.. automodule:: aiogram.methods.add_sticker_to_set
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.add_sticker_to_set(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.add_sticker_to_set import AddStickerToSet`
- alias: :code:`from aiogram.methods import AddStickerToSet`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await AddStickerToSet(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(AddStickerToSet(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return AddStickerToSet(...)

View file

@ -0,0 +1,51 @@
###################
answerCallbackQuery
###################
Returns: :obj:`bool`
.. automodule:: aiogram.methods.answer_callback_query
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.answer_callback_query(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.answer_callback_query import AnswerCallbackQuery`
- alias: :code:`from aiogram.methods import AnswerCallbackQuery`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await AnswerCallbackQuery(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(AnswerCallbackQuery(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return AnswerCallbackQuery(...)

View file

@ -0,0 +1,51 @@
#################
answerInlineQuery
#################
Returns: :obj:`bool`
.. automodule:: aiogram.methods.answer_inline_query
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.answer_inline_query(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.answer_inline_query import AnswerInlineQuery`
- alias: :code:`from aiogram.methods import AnswerInlineQuery`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await AnswerInlineQuery(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(AnswerInlineQuery(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return AnswerInlineQuery(...)

View file

@ -0,0 +1,51 @@
######################
answerPreCheckoutQuery
######################
Returns: :obj:`bool`
.. automodule:: aiogram.methods.answer_pre_checkout_query
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.answer_pre_checkout_query(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.answer_pre_checkout_query import AnswerPreCheckoutQuery`
- alias: :code:`from aiogram.methods import AnswerPreCheckoutQuery`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await AnswerPreCheckoutQuery(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(AnswerPreCheckoutQuery(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return AnswerPreCheckoutQuery(...)

View file

@ -0,0 +1,51 @@
###################
answerShippingQuery
###################
Returns: :obj:`bool`
.. automodule:: aiogram.methods.answer_shipping_query
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.answer_shipping_query(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.answer_shipping_query import AnswerShippingQuery`
- alias: :code:`from aiogram.methods import AnswerShippingQuery`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await AnswerShippingQuery(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(AnswerShippingQuery(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return AnswerShippingQuery(...)

View file

@ -0,0 +1,51 @@
#####
close
#####
Returns: :obj:`bool`
.. automodule:: aiogram.methods.close
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.close(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.close import Close`
- alias: :code:`from aiogram.methods import Close`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await Close(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(Close(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return Close(...)

View file

@ -0,0 +1,51 @@
###########
copyMessage
###########
Returns: :obj:`MessageId`
.. automodule:: aiogram.methods.copy_message
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: MessageId = await bot.copy_message(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.copy_message import CopyMessage`
- alias: :code:`from aiogram.methods import CopyMessage`
In handlers with current bot
----------------------------
.. code-block:: python
result: MessageId = await CopyMessage(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: MessageId = await bot(CopyMessage(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return CopyMessage(...)

View file

@ -0,0 +1,51 @@
###################
createNewStickerSet
###################
Returns: :obj:`bool`
.. automodule:: aiogram.methods.create_new_sticker_set
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.create_new_sticker_set(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.create_new_sticker_set import CreateNewStickerSet`
- alias: :code:`from aiogram.methods import CreateNewStickerSet`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await CreateNewStickerSet(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(CreateNewStickerSet(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return CreateNewStickerSet(...)

View file

@ -0,0 +1,51 @@
###############
deleteChatPhoto
###############
Returns: :obj:`bool`
.. automodule:: aiogram.methods.delete_chat_photo
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.delete_chat_photo(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.delete_chat_photo import DeleteChatPhoto`
- alias: :code:`from aiogram.methods import DeleteChatPhoto`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await DeleteChatPhoto(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(DeleteChatPhoto(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return DeleteChatPhoto(...)

View file

@ -0,0 +1,51 @@
####################
deleteChatStickerSet
####################
Returns: :obj:`bool`
.. automodule:: aiogram.methods.delete_chat_sticker_set
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.delete_chat_sticker_set(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.delete_chat_sticker_set import DeleteChatStickerSet`
- alias: :code:`from aiogram.methods import DeleteChatStickerSet`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await DeleteChatStickerSet(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(DeleteChatStickerSet(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return DeleteChatStickerSet(...)

View file

@ -0,0 +1,51 @@
#############
deleteMessage
#############
Returns: :obj:`bool`
.. automodule:: aiogram.methods.delete_message
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.delete_message(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.delete_message import DeleteMessage`
- alias: :code:`from aiogram.methods import DeleteMessage`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await DeleteMessage(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(DeleteMessage(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return DeleteMessage(...)

View file

@ -0,0 +1,51 @@
####################
deleteStickerFromSet
####################
Returns: :obj:`bool`
.. automodule:: aiogram.methods.delete_sticker_from_set
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.delete_sticker_from_set(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.delete_sticker_from_set import DeleteStickerFromSet`
- alias: :code:`from aiogram.methods import DeleteStickerFromSet`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await DeleteStickerFromSet(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(DeleteStickerFromSet(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return DeleteStickerFromSet(...)

View file

@ -0,0 +1,51 @@
#############
deleteWebhook
#############
Returns: :obj:`bool`
.. automodule:: aiogram.methods.delete_webhook
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.delete_webhook(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.delete_webhook import DeleteWebhook`
- alias: :code:`from aiogram.methods import DeleteWebhook`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await DeleteWebhook(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(DeleteWebhook(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return DeleteWebhook(...)

View file

@ -0,0 +1,51 @@
##################
editMessageCaption
##################
Returns: :obj:`Union[Message, bool]`
.. automodule:: aiogram.methods.edit_message_caption
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Union[Message, bool] = await bot.edit_message_caption(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.edit_message_caption import EditMessageCaption`
- alias: :code:`from aiogram.methods import EditMessageCaption`
In handlers with current bot
----------------------------
.. code-block:: python
result: Union[Message, bool] = await EditMessageCaption(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Union[Message, bool] = await bot(EditMessageCaption(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return EditMessageCaption(...)

View file

@ -0,0 +1,51 @@
#######################
editMessageLiveLocation
#######################
Returns: :obj:`Union[Message, bool]`
.. automodule:: aiogram.methods.edit_message_live_location
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Union[Message, bool] = await bot.edit_message_live_location(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.edit_message_live_location import EditMessageLiveLocation`
- alias: :code:`from aiogram.methods import EditMessageLiveLocation`
In handlers with current bot
----------------------------
.. code-block:: python
result: Union[Message, bool] = await EditMessageLiveLocation(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Union[Message, bool] = await bot(EditMessageLiveLocation(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return EditMessageLiveLocation(...)

View file

@ -0,0 +1,51 @@
################
editMessageMedia
################
Returns: :obj:`Union[Message, bool]`
.. automodule:: aiogram.methods.edit_message_media
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Union[Message, bool] = await bot.edit_message_media(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.edit_message_media import EditMessageMedia`
- alias: :code:`from aiogram.methods import EditMessageMedia`
In handlers with current bot
----------------------------
.. code-block:: python
result: Union[Message, bool] = await EditMessageMedia(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Union[Message, bool] = await bot(EditMessageMedia(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return EditMessageMedia(...)

View file

@ -0,0 +1,51 @@
######################
editMessageReplyMarkup
######################
Returns: :obj:`Union[Message, bool]`
.. automodule:: aiogram.methods.edit_message_reply_markup
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Union[Message, bool] = await bot.edit_message_reply_markup(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.edit_message_reply_markup import EditMessageReplyMarkup`
- alias: :code:`from aiogram.methods import EditMessageReplyMarkup`
In handlers with current bot
----------------------------
.. code-block:: python
result: Union[Message, bool] = await EditMessageReplyMarkup(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Union[Message, bool] = await bot(EditMessageReplyMarkup(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return EditMessageReplyMarkup(...)

View file

@ -0,0 +1,51 @@
###############
editMessageText
###############
Returns: :obj:`Union[Message, bool]`
.. automodule:: aiogram.methods.edit_message_text
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Union[Message, bool] = await bot.edit_message_text(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.edit_message_text import EditMessageText`
- alias: :code:`from aiogram.methods import EditMessageText`
In handlers with current bot
----------------------------
.. code-block:: python
result: Union[Message, bool] = await EditMessageText(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Union[Message, bool] = await bot(EditMessageText(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return EditMessageText(...)

View file

@ -0,0 +1,51 @@
####################
exportChatInviteLink
####################
Returns: :obj:`str`
.. automodule:: aiogram.methods.export_chat_invite_link
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: str = await bot.export_chat_invite_link(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.export_chat_invite_link import ExportChatInviteLink`
- alias: :code:`from aiogram.methods import ExportChatInviteLink`
In handlers with current bot
----------------------------
.. code-block:: python
result: str = await ExportChatInviteLink(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: str = await bot(ExportChatInviteLink(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return ExportChatInviteLink(...)

View file

@ -0,0 +1,51 @@
##############
forwardMessage
##############
Returns: :obj:`Message`
.. automodule:: aiogram.methods.forward_message
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Message = await bot.forward_message(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.forward_message import ForwardMessage`
- alias: :code:`from aiogram.methods import ForwardMessage`
In handlers with current bot
----------------------------
.. code-block:: python
result: Message = await ForwardMessage(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Message = await bot(ForwardMessage(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return ForwardMessage(...)

View file

@ -0,0 +1,45 @@
#######
getChat
#######
Returns: :obj:`Chat`
.. automodule:: aiogram.methods.get_chat
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Chat = await bot.get_chat(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.get_chat import GetChat`
- alias: :code:`from aiogram.methods import GetChat`
In handlers with current bot
----------------------------
.. code-block:: python
result: Chat = await GetChat(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Chat = await bot(GetChat(...))

View file

@ -0,0 +1,45 @@
#####################
getChatAdministrators
#####################
Returns: :obj:`List[ChatMember]`
.. automodule:: aiogram.methods.get_chat_administrators
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: List[ChatMember] = await bot.get_chat_administrators(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.get_chat_administrators import GetChatAdministrators`
- alias: :code:`from aiogram.methods import GetChatAdministrators`
In handlers with current bot
----------------------------
.. code-block:: python
result: List[ChatMember] = await GetChatAdministrators(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: List[ChatMember] = await bot(GetChatAdministrators(...))

View file

@ -0,0 +1,45 @@
#############
getChatMember
#############
Returns: :obj:`ChatMember`
.. automodule:: aiogram.methods.get_chat_member
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: ChatMember = await bot.get_chat_member(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.get_chat_member import GetChatMember`
- alias: :code:`from aiogram.methods import GetChatMember`
In handlers with current bot
----------------------------
.. code-block:: python
result: ChatMember = await GetChatMember(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: ChatMember = await bot(GetChatMember(...))

View file

@ -0,0 +1,45 @@
###################
getChatMembersCount
###################
Returns: :obj:`int`
.. automodule:: aiogram.methods.get_chat_members_count
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: int = await bot.get_chat_members_count(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.get_chat_members_count import GetChatMembersCount`
- alias: :code:`from aiogram.methods import GetChatMembersCount`
In handlers with current bot
----------------------------
.. code-block:: python
result: int = await GetChatMembersCount(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: int = await bot(GetChatMembersCount(...))

View file

@ -0,0 +1,45 @@
#######
getFile
#######
Returns: :obj:`File`
.. automodule:: aiogram.methods.get_file
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: File = await bot.get_file(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.get_file import GetFile`
- alias: :code:`from aiogram.methods import GetFile`
In handlers with current bot
----------------------------
.. code-block:: python
result: File = await GetFile(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: File = await bot(GetFile(...))

View file

@ -0,0 +1,45 @@
#################
getGameHighScores
#################
Returns: :obj:`List[GameHighScore]`
.. automodule:: aiogram.methods.get_game_high_scores
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: List[GameHighScore] = await bot.get_game_high_scores(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.get_game_high_scores import GetGameHighScores`
- alias: :code:`from aiogram.methods import GetGameHighScores`
In handlers with current bot
----------------------------
.. code-block:: python
result: List[GameHighScore] = await GetGameHighScores(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: List[GameHighScore] = await bot(GetGameHighScores(...))

View file

@ -0,0 +1,45 @@
#####
getMe
#####
Returns: :obj:`User`
.. automodule:: aiogram.methods.get_me
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: User = await bot.get_me(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.get_me import GetMe`
- alias: :code:`from aiogram.methods import GetMe`
In handlers with current bot
----------------------------
.. code-block:: python
result: User = await GetMe(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: User = await bot(GetMe(...))

View file

@ -0,0 +1,45 @@
#############
getMyCommands
#############
Returns: :obj:`List[BotCommand]`
.. automodule:: aiogram.methods.get_my_commands
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: List[BotCommand] = await bot.get_my_commands(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.get_my_commands import GetMyCommands`
- alias: :code:`from aiogram.methods import GetMyCommands`
In handlers with current bot
----------------------------
.. code-block:: python
result: List[BotCommand] = await GetMyCommands(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: List[BotCommand] = await bot(GetMyCommands(...))

View file

@ -0,0 +1,45 @@
#############
getStickerSet
#############
Returns: :obj:`StickerSet`
.. automodule:: aiogram.methods.get_sticker_set
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: StickerSet = await bot.get_sticker_set(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.get_sticker_set import GetStickerSet`
- alias: :code:`from aiogram.methods import GetStickerSet`
In handlers with current bot
----------------------------
.. code-block:: python
result: StickerSet = await GetStickerSet(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: StickerSet = await bot(GetStickerSet(...))

View file

@ -0,0 +1,45 @@
##########
getUpdates
##########
Returns: :obj:`List[Update]`
.. automodule:: aiogram.methods.get_updates
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: List[Update] = await bot.get_updates(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.get_updates import GetUpdates`
- alias: :code:`from aiogram.methods import GetUpdates`
In handlers with current bot
----------------------------
.. code-block:: python
result: List[Update] = await GetUpdates(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: List[Update] = await bot(GetUpdates(...))

View file

@ -0,0 +1,45 @@
####################
getUserProfilePhotos
####################
Returns: :obj:`UserProfilePhotos`
.. automodule:: aiogram.methods.get_user_profile_photos
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: UserProfilePhotos = await bot.get_user_profile_photos(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.get_user_profile_photos import GetUserProfilePhotos`
- alias: :code:`from aiogram.methods import GetUserProfilePhotos`
In handlers with current bot
----------------------------
.. code-block:: python
result: UserProfilePhotos = await GetUserProfilePhotos(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: UserProfilePhotos = await bot(GetUserProfilePhotos(...))

View file

@ -0,0 +1,45 @@
##############
getWebhookInfo
##############
Returns: :obj:`WebhookInfo`
.. automodule:: aiogram.methods.get_webhook_info
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: WebhookInfo = await bot.get_webhook_info(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.get_webhook_info import GetWebhookInfo`
- alias: :code:`from aiogram.methods import GetWebhookInfo`
In handlers with current bot
----------------------------
.. code-block:: python
result: WebhookInfo = await GetWebhookInfo(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: WebhookInfo = await bot(GetWebhookInfo(...))

139
docs2/api/methods/index.rst Normal file
View file

@ -0,0 +1,139 @@
#######
Methods
#######
Here is list of all available API methods:
Getting updates
===============
.. toctree::
:maxdepth: 1
get_updates
set_webhook
delete_webhook
get_webhook_info
Available methods
=================
.. toctree::
:maxdepth: 1
get_me
log_out
close
send_message
forward_message
copy_message
send_photo
send_audio
send_document
send_video
send_animation
send_voice
send_video_note
send_media_group
send_location
edit_message_live_location
stop_message_live_location
send_venue
send_contact
send_poll
send_dice
send_chat_action
get_user_profile_photos
get_file
kick_chat_member
unban_chat_member
restrict_chat_member
promote_chat_member
set_chat_administrator_custom_title
set_chat_permissions
export_chat_invite_link
set_chat_photo
delete_chat_photo
set_chat_title
set_chat_description
pin_chat_message
unpin_chat_message
unpin_all_chat_messages
leave_chat
get_chat
get_chat_administrators
get_chat_members_count
get_chat_member
set_chat_sticker_set
delete_chat_sticker_set
answer_callback_query
set_my_commands
get_my_commands
Updating messages
=================
.. toctree::
:maxdepth: 1
edit_message_text
edit_message_caption
edit_message_media
edit_message_reply_markup
stop_poll
delete_message
Stickers
========
.. toctree::
:maxdepth: 1
send_sticker
get_sticker_set
upload_sticker_file
create_new_sticker_set
add_sticker_to_set
set_sticker_position_in_set
delete_sticker_from_set
set_sticker_set_thumb
Inline mode
===========
.. toctree::
:maxdepth: 1
answer_inline_query
Payments
========
.. toctree::
:maxdepth: 1
send_invoice
answer_shipping_query
answer_pre_checkout_query
Telegram Passport
=================
.. toctree::
:maxdepth: 1
set_passport_data_errors
Games
=====
.. toctree::
:maxdepth: 1
send_game
set_game_score
get_game_high_scores

View file

@ -0,0 +1,51 @@
##############
kickChatMember
##############
Returns: :obj:`bool`
.. automodule:: aiogram.methods.kick_chat_member
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.kick_chat_member(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.kick_chat_member import KickChatMember`
- alias: :code:`from aiogram.methods import KickChatMember`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await KickChatMember(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(KickChatMember(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return KickChatMember(...)

View file

@ -0,0 +1,51 @@
#########
leaveChat
#########
Returns: :obj:`bool`
.. automodule:: aiogram.methods.leave_chat
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.leave_chat(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.leave_chat import LeaveChat`
- alias: :code:`from aiogram.methods import LeaveChat`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await LeaveChat(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(LeaveChat(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return LeaveChat(...)

View file

@ -0,0 +1,51 @@
######
logOut
######
Returns: :obj:`bool`
.. automodule:: aiogram.methods.log_out
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.log_out(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.log_out import LogOut`
- alias: :code:`from aiogram.methods import LogOut`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await LogOut(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(LogOut(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return LogOut(...)

View file

@ -0,0 +1,51 @@
##############
pinChatMessage
##############
Returns: :obj:`bool`
.. automodule:: aiogram.methods.pin_chat_message
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.pin_chat_message(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.pin_chat_message import PinChatMessage`
- alias: :code:`from aiogram.methods import PinChatMessage`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await PinChatMessage(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(PinChatMessage(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return PinChatMessage(...)

View file

@ -0,0 +1,51 @@
#################
promoteChatMember
#################
Returns: :obj:`bool`
.. automodule:: aiogram.methods.promote_chat_member
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.promote_chat_member(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.promote_chat_member import PromoteChatMember`
- alias: :code:`from aiogram.methods import PromoteChatMember`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await PromoteChatMember(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(PromoteChatMember(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return PromoteChatMember(...)

View file

@ -0,0 +1,51 @@
##################
restrictChatMember
##################
Returns: :obj:`bool`
.. automodule:: aiogram.methods.restrict_chat_member
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.restrict_chat_member(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.restrict_chat_member import RestrictChatMember`
- alias: :code:`from aiogram.methods import RestrictChatMember`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await RestrictChatMember(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(RestrictChatMember(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return RestrictChatMember(...)

View file

@ -0,0 +1,51 @@
#############
sendAnimation
#############
Returns: :obj:`Message`
.. automodule:: aiogram.methods.send_animation
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Message = await bot.send_animation(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.send_animation import SendAnimation`
- alias: :code:`from aiogram.methods import SendAnimation`
In handlers with current bot
----------------------------
.. code-block:: python
result: Message = await SendAnimation(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Message = await bot(SendAnimation(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SendAnimation(...)

View file

@ -0,0 +1,51 @@
#########
sendAudio
#########
Returns: :obj:`Message`
.. automodule:: aiogram.methods.send_audio
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Message = await bot.send_audio(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.send_audio import SendAudio`
- alias: :code:`from aiogram.methods import SendAudio`
In handlers with current bot
----------------------------
.. code-block:: python
result: Message = await SendAudio(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Message = await bot(SendAudio(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SendAudio(...)

View file

@ -0,0 +1,51 @@
##############
sendChatAction
##############
Returns: :obj:`bool`
.. automodule:: aiogram.methods.send_chat_action
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.send_chat_action(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.send_chat_action import SendChatAction`
- alias: :code:`from aiogram.methods import SendChatAction`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await SendChatAction(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(SendChatAction(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SendChatAction(...)

View file

@ -0,0 +1,51 @@
###########
sendContact
###########
Returns: :obj:`Message`
.. automodule:: aiogram.methods.send_contact
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Message = await bot.send_contact(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.send_contact import SendContact`
- alias: :code:`from aiogram.methods import SendContact`
In handlers with current bot
----------------------------
.. code-block:: python
result: Message = await SendContact(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Message = await bot(SendContact(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SendContact(...)

View file

@ -0,0 +1,51 @@
########
sendDice
########
Returns: :obj:`Message`
.. automodule:: aiogram.methods.send_dice
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Message = await bot.send_dice(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.send_dice import SendDice`
- alias: :code:`from aiogram.methods import SendDice`
In handlers with current bot
----------------------------
.. code-block:: python
result: Message = await SendDice(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Message = await bot(SendDice(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SendDice(...)

View file

@ -0,0 +1,51 @@
############
sendDocument
############
Returns: :obj:`Message`
.. automodule:: aiogram.methods.send_document
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Message = await bot.send_document(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.send_document import SendDocument`
- alias: :code:`from aiogram.methods import SendDocument`
In handlers with current bot
----------------------------
.. code-block:: python
result: Message = await SendDocument(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Message = await bot(SendDocument(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SendDocument(...)

View file

@ -0,0 +1,51 @@
########
sendGame
########
Returns: :obj:`Message`
.. automodule:: aiogram.methods.send_game
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Message = await bot.send_game(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.send_game import SendGame`
- alias: :code:`from aiogram.methods import SendGame`
In handlers with current bot
----------------------------
.. code-block:: python
result: Message = await SendGame(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Message = await bot(SendGame(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SendGame(...)

View file

@ -0,0 +1,51 @@
###########
sendInvoice
###########
Returns: :obj:`Message`
.. automodule:: aiogram.methods.send_invoice
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Message = await bot.send_invoice(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.send_invoice import SendInvoice`
- alias: :code:`from aiogram.methods import SendInvoice`
In handlers with current bot
----------------------------
.. code-block:: python
result: Message = await SendInvoice(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Message = await bot(SendInvoice(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SendInvoice(...)

View file

@ -0,0 +1,51 @@
############
sendLocation
############
Returns: :obj:`Message`
.. automodule:: aiogram.methods.send_location
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Message = await bot.send_location(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.send_location import SendLocation`
- alias: :code:`from aiogram.methods import SendLocation`
In handlers with current bot
----------------------------
.. code-block:: python
result: Message = await SendLocation(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Message = await bot(SendLocation(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SendLocation(...)

View file

@ -0,0 +1,51 @@
##############
sendMediaGroup
##############
Returns: :obj:`List[Message]`
.. automodule:: aiogram.methods.send_media_group
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: List[Message] = await bot.send_media_group(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.send_media_group import SendMediaGroup`
- alias: :code:`from aiogram.methods import SendMediaGroup`
In handlers with current bot
----------------------------
.. code-block:: python
result: List[Message] = await SendMediaGroup(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: List[Message] = await bot(SendMediaGroup(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SendMediaGroup(...)

View file

@ -0,0 +1,51 @@
###########
sendMessage
###########
Returns: :obj:`Message`
.. automodule:: aiogram.methods.send_message
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Message = await bot.send_message(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.send_message import SendMessage`
- alias: :code:`from aiogram.methods import SendMessage`
In handlers with current bot
----------------------------
.. code-block:: python
result: Message = await SendMessage(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Message = await bot(SendMessage(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SendMessage(...)

View file

@ -0,0 +1,51 @@
#########
sendPhoto
#########
Returns: :obj:`Message`
.. automodule:: aiogram.methods.send_photo
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Message = await bot.send_photo(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.send_photo import SendPhoto`
- alias: :code:`from aiogram.methods import SendPhoto`
In handlers with current bot
----------------------------
.. code-block:: python
result: Message = await SendPhoto(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Message = await bot(SendPhoto(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SendPhoto(...)

View file

@ -0,0 +1,51 @@
########
sendPoll
########
Returns: :obj:`Message`
.. automodule:: aiogram.methods.send_poll
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Message = await bot.send_poll(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.send_poll import SendPoll`
- alias: :code:`from aiogram.methods import SendPoll`
In handlers with current bot
----------------------------
.. code-block:: python
result: Message = await SendPoll(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Message = await bot(SendPoll(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SendPoll(...)

View file

@ -0,0 +1,51 @@
###########
sendSticker
###########
Returns: :obj:`Message`
.. automodule:: aiogram.methods.send_sticker
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Message = await bot.send_sticker(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.send_sticker import SendSticker`
- alias: :code:`from aiogram.methods import SendSticker`
In handlers with current bot
----------------------------
.. code-block:: python
result: Message = await SendSticker(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Message = await bot(SendSticker(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SendSticker(...)

View file

@ -0,0 +1,51 @@
#########
sendVenue
#########
Returns: :obj:`Message`
.. automodule:: aiogram.methods.send_venue
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Message = await bot.send_venue(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.send_venue import SendVenue`
- alias: :code:`from aiogram.methods import SendVenue`
In handlers with current bot
----------------------------
.. code-block:: python
result: Message = await SendVenue(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Message = await bot(SendVenue(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SendVenue(...)

View file

@ -0,0 +1,51 @@
#########
sendVideo
#########
Returns: :obj:`Message`
.. automodule:: aiogram.methods.send_video
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Message = await bot.send_video(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.send_video import SendVideo`
- alias: :code:`from aiogram.methods import SendVideo`
In handlers with current bot
----------------------------
.. code-block:: python
result: Message = await SendVideo(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Message = await bot(SendVideo(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SendVideo(...)

View file

@ -0,0 +1,51 @@
#############
sendVideoNote
#############
Returns: :obj:`Message`
.. automodule:: aiogram.methods.send_video_note
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Message = await bot.send_video_note(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.send_video_note import SendVideoNote`
- alias: :code:`from aiogram.methods import SendVideoNote`
In handlers with current bot
----------------------------
.. code-block:: python
result: Message = await SendVideoNote(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Message = await bot(SendVideoNote(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SendVideoNote(...)

View file

@ -0,0 +1,51 @@
#########
sendVoice
#########
Returns: :obj:`Message`
.. automodule:: aiogram.methods.send_voice
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Message = await bot.send_voice(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.send_voice import SendVoice`
- alias: :code:`from aiogram.methods import SendVoice`
In handlers with current bot
----------------------------
.. code-block:: python
result: Message = await SendVoice(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Message = await bot(SendVoice(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SendVoice(...)

View file

@ -0,0 +1,51 @@
###############################
setChatAdministratorCustomTitle
###############################
Returns: :obj:`bool`
.. automodule:: aiogram.methods.set_chat_administrator_custom_title
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.set_chat_administrator_custom_title(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.set_chat_administrator_custom_title import SetChatAdministratorCustomTitle`
- alias: :code:`from aiogram.methods import SetChatAdministratorCustomTitle`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await SetChatAdministratorCustomTitle(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(SetChatAdministratorCustomTitle(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SetChatAdministratorCustomTitle(...)

View file

@ -0,0 +1,51 @@
##################
setChatDescription
##################
Returns: :obj:`bool`
.. automodule:: aiogram.methods.set_chat_description
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.set_chat_description(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.set_chat_description import SetChatDescription`
- alias: :code:`from aiogram.methods import SetChatDescription`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await SetChatDescription(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(SetChatDescription(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SetChatDescription(...)

View file

@ -0,0 +1,51 @@
##################
setChatPermissions
##################
Returns: :obj:`bool`
.. automodule:: aiogram.methods.set_chat_permissions
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.set_chat_permissions(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.set_chat_permissions import SetChatPermissions`
- alias: :code:`from aiogram.methods import SetChatPermissions`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await SetChatPermissions(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(SetChatPermissions(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SetChatPermissions(...)

View file

@ -0,0 +1,45 @@
############
setChatPhoto
############
Returns: :obj:`bool`
.. automodule:: aiogram.methods.set_chat_photo
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.set_chat_photo(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.set_chat_photo import SetChatPhoto`
- alias: :code:`from aiogram.methods import SetChatPhoto`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await SetChatPhoto(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(SetChatPhoto(...))

View file

@ -0,0 +1,51 @@
#################
setChatStickerSet
#################
Returns: :obj:`bool`
.. automodule:: aiogram.methods.set_chat_sticker_set
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.set_chat_sticker_set(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.set_chat_sticker_set import SetChatStickerSet`
- alias: :code:`from aiogram.methods import SetChatStickerSet`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await SetChatStickerSet(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(SetChatStickerSet(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SetChatStickerSet(...)

View file

@ -0,0 +1,51 @@
############
setChatTitle
############
Returns: :obj:`bool`
.. automodule:: aiogram.methods.set_chat_title
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.set_chat_title(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.set_chat_title import SetChatTitle`
- alias: :code:`from aiogram.methods import SetChatTitle`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await SetChatTitle(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(SetChatTitle(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SetChatTitle(...)

View file

@ -0,0 +1,51 @@
############
setGameScore
############
Returns: :obj:`Union[Message, bool]`
.. automodule:: aiogram.methods.set_game_score
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Union[Message, bool] = await bot.set_game_score(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.set_game_score import SetGameScore`
- alias: :code:`from aiogram.methods import SetGameScore`
In handlers with current bot
----------------------------
.. code-block:: python
result: Union[Message, bool] = await SetGameScore(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Union[Message, bool] = await bot(SetGameScore(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SetGameScore(...)

View file

@ -0,0 +1,51 @@
#############
setMyCommands
#############
Returns: :obj:`bool`
.. automodule:: aiogram.methods.set_my_commands
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.set_my_commands(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.set_my_commands import SetMyCommands`
- alias: :code:`from aiogram.methods import SetMyCommands`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await SetMyCommands(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(SetMyCommands(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SetMyCommands(...)

View file

@ -0,0 +1,51 @@
#####################
setPassportDataErrors
#####################
Returns: :obj:`bool`
.. automodule:: aiogram.methods.set_passport_data_errors
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.set_passport_data_errors(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.set_passport_data_errors import SetPassportDataErrors`
- alias: :code:`from aiogram.methods import SetPassportDataErrors`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await SetPassportDataErrors(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(SetPassportDataErrors(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SetPassportDataErrors(...)

View file

@ -0,0 +1,51 @@
#######################
setStickerPositionInSet
#######################
Returns: :obj:`bool`
.. automodule:: aiogram.methods.set_sticker_position_in_set
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.set_sticker_position_in_set(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.set_sticker_position_in_set import SetStickerPositionInSet`
- alias: :code:`from aiogram.methods import SetStickerPositionInSet`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await SetStickerPositionInSet(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(SetStickerPositionInSet(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SetStickerPositionInSet(...)

View file

@ -0,0 +1,51 @@
##################
setStickerSetThumb
##################
Returns: :obj:`bool`
.. automodule:: aiogram.methods.set_sticker_set_thumb
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.set_sticker_set_thumb(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.set_sticker_set_thumb import SetStickerSetThumb`
- alias: :code:`from aiogram.methods import SetStickerSetThumb`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await SetStickerSetThumb(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(SetStickerSetThumb(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SetStickerSetThumb(...)

View file

@ -0,0 +1,51 @@
##########
setWebhook
##########
Returns: :obj:`bool`
.. automodule:: aiogram.methods.set_webhook
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.set_webhook(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.set_webhook import SetWebhook`
- alias: :code:`from aiogram.methods import SetWebhook`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await SetWebhook(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(SetWebhook(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return SetWebhook(...)

View file

@ -0,0 +1,51 @@
#######################
stopMessageLiveLocation
#######################
Returns: :obj:`Union[Message, bool]`
.. automodule:: aiogram.methods.stop_message_live_location
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Union[Message, bool] = await bot.stop_message_live_location(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.stop_message_live_location import StopMessageLiveLocation`
- alias: :code:`from aiogram.methods import StopMessageLiveLocation`
In handlers with current bot
----------------------------
.. code-block:: python
result: Union[Message, bool] = await StopMessageLiveLocation(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Union[Message, bool] = await bot(StopMessageLiveLocation(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return StopMessageLiveLocation(...)

View file

@ -0,0 +1,51 @@
########
stopPoll
########
Returns: :obj:`Poll`
.. automodule:: aiogram.methods.stop_poll
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: Poll = await bot.stop_poll(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.stop_poll import StopPoll`
- alias: :code:`from aiogram.methods import StopPoll`
In handlers with current bot
----------------------------
.. code-block:: python
result: Poll = await StopPoll(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: Poll = await bot(StopPoll(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return StopPoll(...)

View file

@ -0,0 +1,51 @@
###############
unbanChatMember
###############
Returns: :obj:`bool`
.. automodule:: aiogram.methods.unban_chat_member
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.unban_chat_member(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.unban_chat_member import UnbanChatMember`
- alias: :code:`from aiogram.methods import UnbanChatMember`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await UnbanChatMember(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(UnbanChatMember(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return UnbanChatMember(...)

View file

@ -0,0 +1,51 @@
####################
unpinAllChatMessages
####################
Returns: :obj:`bool`
.. automodule:: aiogram.methods.unpin_all_chat_messages
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.unpin_all_chat_messages(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.unpin_all_chat_messages import UnpinAllChatMessages`
- alias: :code:`from aiogram.methods import UnpinAllChatMessages`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await UnpinAllChatMessages(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(UnpinAllChatMessages(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return UnpinAllChatMessages(...)

View file

@ -0,0 +1,51 @@
################
unpinChatMessage
################
Returns: :obj:`bool`
.. automodule:: aiogram.methods.unpin_chat_message
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: bool = await bot.unpin_chat_message(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.unpin_chat_message import UnpinChatMessage`
- alias: :code:`from aiogram.methods import UnpinChatMessage`
In handlers with current bot
----------------------------
.. code-block:: python
result: bool = await UnpinChatMessage(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: bool = await bot(UnpinChatMessage(...))
As reply into Webhook in handler
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. code-block:: python
return UnpinChatMessage(...)

View file

@ -0,0 +1,45 @@
#################
uploadStickerFile
#################
Returns: :obj:`File`
.. automodule:: aiogram.methods.upload_sticker_file
:members:
:member-order: bysource
:undoc-members: True
Usage
=====
As bot method
-------------
.. code-block::
result: File = await bot.upload_sticker_file(...)
Method as object
----------------
Imports:
- :code:`from aiogram.methods.upload_sticker_file import UploadStickerFile`
- alias: :code:`from aiogram.methods import UploadStickerFile`
In handlers with current bot
----------------------------
.. code-block:: python
result: File = await UploadStickerFile(...)
With specific bot
~~~~~~~~~~~~~~~~~
.. code-block:: python
result: File = await bot(UploadStickerFile(...))

View file

@ -0,0 +1,95 @@
#######
aiohttp
#######
AiohttpSession represents a wrapper-class around `ClientSession` from `aiohttp <https://pypi.org/project/aiohttp/>`_
Currently `AiohttpSession` is a default session used in `aiogram.Bot`
.. autoclass:: aiogram.client.session.aiohttp.AiohttpSession
Usage example
=============
.. code-block::
from aiogram import Bot
from aiogram.session.aiohttp import AiohttpSession
session = AiohttpSession()
Bot('42:token', session=session)
Proxy requests in AiohttpSession
================================
In order to use AiohttpSession with proxy connector you have to install `aiohttp-socks <https://pypi.org/project/aiohttp-socks>`_
Binding session to bot:
.. code-block::
from aiogram import Bot
from aiogram.client.session.aiohttp import AiohttpSession
session = AiohttpSession(proxy="protocol://host:port/")
Bot(token="bot token", session=session)
.. note::
Only following protocols are supported: http(tunneling), socks4(a), socks5
as aiohttp_socks `documentation <https://github.com/romis2012/aiohttp-socks/blob/master/README.md>`_ claims.
Authorization
-------------
Proxy authorization credentials can be specified in proxy URL or come as an instance of :obj:`aiohttp.BasicAuth` containing
login and password.
Consider examples:
.. code-block::
from aiohttp import BasicAuth
from aiogram.client.session.aiohttp import AiohttpSession
auth = BasicAuth(login="user", password="password")
session = AiohttpSession(proxy=("protocol://host:port", auth))
or simply include your basic auth credential in URL
.. code-block::
session = AiohttpSession(proxy="protocol://user:password@host:port")
.. note::
Aiogram prefers `BasicAuth` over username and password in URL, so
if proxy URL contains login and password and `BasicAuth` object is passed at the same time
aiogram will use login and password from `BasicAuth` instance.
Proxy chains
------------
Since `aiohttp-socks <https://pypi.org/project/aiohttp-socks/>`_ supports proxy chains, you're able to use them in aiogram
Example of chain proxies:
.. code-block::
from aiohttp import BasicAuth
from aiogram.client.session.aiohttp import AiohttpSession
auth = BasicAuth(login="user", password="password")
session = AiohttpSession(
proxy={
"protocol0://host0:port0",
"protocol1://user:password@host1:port1",
("protocol2://host2:port2", auth),
} # can be any iterable if not set
)

View file

@ -0,0 +1,8 @@
####
Base
####
Abstract session for all client sessions
.. autoclass:: aiogram.client.session.base.BaseSession
:members:

View file

@ -0,0 +1,13 @@
Use Custom API server
=====================
.. autoclass:: aiogram.client.telegram.TelegramAPIServer
:members:
For example, if you want to use self-hosted API server:
.. code-block:: python3
session = AiohttpSession()
session.api = TelegramAPIServer.from_base('http://localhost:8082')
bot = Bot(..., session=session)

View file

@ -0,0 +1,10 @@
##############
Client session
##############
Client sessions is used for interacting with API server.
.. toctree::
custom_server
base
aiohttp

View file

@ -0,0 +1,9 @@
#########
Animation
#########
.. automodule:: aiogram.types.animation
:members:
:member-order: bysource
:undoc-members: True

View file

@ -0,0 +1,9 @@
#####
Audio
#####
.. automodule:: aiogram.types.audio
:members:
:member-order: bysource
:undoc-members: True

View file

@ -0,0 +1,9 @@
##########
BotCommand
##########
.. automodule:: aiogram.types.bot_command
:members:
:member-order: bysource
:undoc-members: True

View file

@ -0,0 +1,9 @@
############
CallbackGame
############
.. automodule:: aiogram.types.callback_game
:members:
:member-order: bysource
:undoc-members: True

View file

@ -0,0 +1,9 @@
#############
CallbackQuery
#############
.. automodule:: aiogram.types.callback_query
:members:
:member-order: bysource
:undoc-members: True

9
docs2/api/types/chat.rst Normal file
View file

@ -0,0 +1,9 @@
####
Chat
####
.. automodule:: aiogram.types.chat
:members:
:member-order: bysource
:undoc-members: True

View file

@ -0,0 +1,9 @@
############
ChatLocation
############
.. automodule:: aiogram.types.chat_location
:members:
:member-order: bysource
:undoc-members: True

View file

@ -0,0 +1,9 @@
##########
ChatMember
##########
.. automodule:: aiogram.types.chat_member
:members:
:member-order: bysource
:undoc-members: True

View file

@ -0,0 +1,9 @@
###############
ChatPermissions
###############
.. automodule:: aiogram.types.chat_permissions
:members:
:member-order: bysource
:undoc-members: True

View file

@ -0,0 +1,9 @@
#########
ChatPhoto
#########
.. automodule:: aiogram.types.chat_photo
:members:
:member-order: bysource
:undoc-members: True

View file

@ -0,0 +1,9 @@
##################
ChosenInlineResult
##################
.. automodule:: aiogram.types.chosen_inline_result
:members:
:member-order: bysource
:undoc-members: True

View file

@ -0,0 +1,9 @@
#######
Contact
#######
.. automodule:: aiogram.types.contact
:members:
:member-order: bysource
:undoc-members: True

9
docs2/api/types/dice.rst Normal file
View file

@ -0,0 +1,9 @@
####
Dice
####
.. automodule:: aiogram.types.dice
:members:
:member-order: bysource
:undoc-members: True

View file

@ -0,0 +1,9 @@
########
Document
########
.. automodule:: aiogram.types.document
:members:
:member-order: bysource
:undoc-members: True

View file

@ -0,0 +1,9 @@
####################
EncryptedCredentials
####################
.. automodule:: aiogram.types.encrypted_credentials
:members:
:member-order: bysource
:undoc-members: True

View file

@ -0,0 +1,9 @@
########################
EncryptedPassportElement
########################
.. automodule:: aiogram.types.encrypted_passport_element
:members:
:member-order: bysource
:undoc-members: True

9
docs2/api/types/file.rst Normal file
View file

@ -0,0 +1,9 @@
####
File
####
.. automodule:: aiogram.types.file
:members:
:member-order: bysource
:undoc-members: True

View file

@ -0,0 +1,9 @@
##########
ForceReply
##########
.. automodule:: aiogram.types.force_reply
:members:
:member-order: bysource
:undoc-members: True

Some files were not shown because too many files have changed in this diff Show more