mirror of
https://github.com/aiogram/aiogram.git
synced 2025-12-06 07:50:32 +00:00
Add KeyboardButtonPollTypeType enum (#1398)
* Add KeyboardButtonPollTypeType enum A new enum, KeyboardButtonPollType, has been added and documented. This enum holds types of polls that can be created and sent when the corresponding button is pressed. It is now imported and included in the aiogram enums documentation. * Added changelog
This commit is contained in:
parent
eeafe4696c
commit
d3c63797b0
6 changed files with 33 additions and 0 deletions
8
.butcher/enums/KeyboardButtonPollTypeType.yml
Normal file
8
.butcher/enums/KeyboardButtonPollTypeType.yml
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
name: KeyboardButtonPollTypeType
|
||||
description: |
|
||||
This object represents type of a poll, which is allowed to be created and sent when the corresponding button is pressed.
|
||||
|
||||
Source: https://core.telegram.org/bots/api#keyboardbuttonpolltype
|
||||
static:
|
||||
QUIZ: "quiz"
|
||||
REGULAR: "regular"
|
||||
1
CHANGES/1398.feature.rst
Normal file
1
CHANGES/1398.feature.rst
Normal file
|
|
@ -0,0 +1 @@
|
|||
A new enum :code:`KeyboardButtonPollTypeType` for :code:`KeyboardButtonPollTypeType.type` field has bed added.
|
||||
|
|
@ -9,6 +9,7 @@ from .dice_emoji import DiceEmoji
|
|||
from .encrypted_passport_element import EncryptedPassportElement
|
||||
from .inline_query_result_type import InlineQueryResultType
|
||||
from .input_media_type import InputMediaType
|
||||
from .keyboard_button_poll_type_type import KeyboardButtonPollTypeType
|
||||
from .mask_position_point import MaskPositionPoint
|
||||
from .menu_button_type import MenuButtonType
|
||||
from .message_entity_type import MessageEntityType
|
||||
|
|
@ -34,6 +35,7 @@ __all__ = (
|
|||
"EncryptedPassportElement",
|
||||
"InlineQueryResultType",
|
||||
"InputMediaType",
|
||||
"KeyboardButtonPollTypeType",
|
||||
"MaskPositionPoint",
|
||||
"MenuButtonType",
|
||||
"MessageEntityType",
|
||||
|
|
|
|||
12
aiogram/enums/keyboard_button_poll_type_type.py
Normal file
12
aiogram/enums/keyboard_button_poll_type_type.py
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
from enum import Enum
|
||||
|
||||
|
||||
class KeyboardButtonPollTypeType(str, Enum):
|
||||
"""
|
||||
This object represents type of a poll, which is allowed to be created and sent when the corresponding button is pressed.
|
||||
|
||||
Source: https://core.telegram.org/bots/api#keyboardbuttonpolltype
|
||||
"""
|
||||
|
||||
QUIZ = "quiz"
|
||||
REGULAR = "regular"
|
||||
|
|
@ -21,6 +21,7 @@ Here is list of all available enums:
|
|||
encrypted_passport_element
|
||||
inline_query_result_type
|
||||
input_media_type
|
||||
keyboard_button_poll_type_type
|
||||
mask_position_point
|
||||
menu_button_type
|
||||
message_entity_type
|
||||
|
|
|
|||
9
docs/api/enums/keyboard_button_poll_type_type.rst
Normal file
9
docs/api/enums/keyboard_button_poll_type_type.rst
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
##########################
|
||||
KeyboardButtonPollTypeType
|
||||
##########################
|
||||
|
||||
|
||||
.. automodule:: aiogram.enums.keyboard_button_poll_type_type
|
||||
:members:
|
||||
:member-order: bysource
|
||||
:undoc-members: True
|
||||
Loading…
Add table
Add a link
Reference in a new issue