telegram.ext.Defaults¶
-
class
telegram.ext.
Defaults
(parse_mode: str = None, disable_notification: bool = None, disable_web_page_preview: bool = None, timeout: Union[float, telegram.utils.helpers.DefaultValue] = <telegram.utils.helpers.DefaultValue object>, quote: bool = None, tzinfo: pytz.tzinfo.BaseTzInfo = <UTC>)¶ Bases:
object
Convenience Class to gather all parameters with a (user defined) default value
-
parse_mode
¶ Optional. Send Markdown or HTML, if you want Telegram apps to show bold, italic, fixed-width text or URLs in your bot’s message.
Type: str
-
disable_notification
¶ Optional. Sends the message silently. Users will receive a notification with no sound.
Type: bool
-
disable_web_page_preview
¶ Optional. Disables link previews for links in this message.
Type: bool
-
timeout
¶ Optional. If this value is specified, use it as the read timeout from the server (instead of the one specified during creation of the connection pool).
Type: int
|float
-
quote
¶ Optional. If set to
True
, the reply is sent as an actual reply to the message. Ifreply_to_message_id
is passed inkwargs
, this parameter will be ignored. Default:True
in group chats andFalse
in private chats.Type: bool
Parameters: - parse_mode (
str
, optional) – Send Markdown or HTML, if you want Telegram apps to show bold, italic, fixed-width text or URLs in your bot’s message. - disable_notification (
bool
, optional) – Sends the message silently. Users will receive a notification with no sound. - disable_web_page_preview (
bool
, optional) – Disables link previews for links in this message. - timeout (
int
|float
, optional) – If this value is specified, use it as the read timeout from the server (instead of the one specified during creation of the connection pool). - quote (
bool
, optional) – If set toTrue
, the reply is sent as an actual reply to the message. Ifreply_to_message_id
is passed inkwargs
, this parameter will be ignored. Default:True
in group chats andFalse
in private chats. - tzinfo (
tzinfo
, optional) – A timezone to be used for all date(time) inputs appearing throughout PTB, i.e. if a timezone naive date(time) object is passed somewhere, it will be assumed to be intzinfo
. Must be a timezone provided by thepytz
module. Defaults to UTC.
-