telegram.InputTextMessageContent¶
-
class
telegram.
InputTextMessageContent
(message_text: str, parse_mode: Union[str, telegram.utils.helpers.DefaultValue] = <telegram.utils.helpers.DefaultValue object>, disable_web_page_preview: Union[bool, telegram.utils.helpers.DefaultValue] = <telegram.utils.helpers.DefaultValue object>, entities: Union[Tuple[telegram.messageentity.MessageEntity, ...], List[telegram.messageentity.MessageEntity]] = None, **_kwargs)¶ Bases:
telegram.inline.inputmessagecontent.InputMessageContent
Represents the content of a text message to be sent as the result of an inline query.
Objects of this class are comparable in terms of equality. Two objects of this class are considered equal, if their
message_text
is equal.-
message_text
¶ Text of the message to be sent, 1-4096 characters after entities parsing.
Type: str
-
parse_mode
¶ Optional. Send Markdown or HTML, if you want Telegram apps to show bold, italic, fixed-width text or inline URLs in your bot’s message. See the constants in
telegram.ParseMode
for the available modes.Type: str
-
entities
¶ Optional. List of special entities that appear in the caption, which can be specified instead of
parse_mode
.Type: List[ telegram.MessageEntity
]
-
disable_web_page_preview
¶ Optional. Disables link previews for links in the sent message.
Type: bool
Parameters: - message_text (
str
) – Text of the message to be sent, 1-4096 characters after entities parsing. Also found astelegram.constants.MAX_MESSAGE_LENGTH
. - parse_mode (
str
, optional) – Send Markdown or HTML, if you want Telegram apps to show bold, italic, fixed-width text or inline URLs in your bot’s message. See the constants intelegram.ParseMode
for the available modes. - entities (List[
telegram.MessageEntity
], optional) – List of special entities that appear in the caption, which can be specified instead ofparse_mode
. - disable_web_page_preview (
bool
, optional) – Disables link previews for links in the sent message. - **kwargs (
dict
) – Arbitrary keyword arguments.
-