telegram.constants module¶
Constants in the Telegram network.
-
telegram.constants.MAX_MESSAGE_LENGTH¶ int – from https://core.telegram.org/method/messages.sendMessage#return-errors
-
telegram.constants.MAX_CAPTION_LENGTH¶ int – from https://core.telegram.org/bots/api#sendphoto
The following constants were extracted from the Telegram Bots FAQ.
-
telegram.constants.SUPPORTED_WEBHOOK_PORTS¶ List[int]
-
telegram.constants.MAX_FILESIZE_DOWNLOAD¶ int – In bytes.
-
telegram.constants.MAX_FILESIZE_UPLOAD¶ int – Official limit, the actual limit can be a bit higher.
-
telegram.constants.MAX_MESSAGES_PER_SECOND_PER_CHAT¶ int – Telegram may allow short bursts that go over this limit, but eventually you’ll begin receiving 429 errors.
-
telegram.constants.MAX_MESSAGES_PER_SECOND¶ int
-
telegram.constants.MAX_MESSAGES_PER_MINUTE_PER_GROUP¶ int
The following constant have been found by experimentation:
-
telegram.constants.MAX_MESSAGE_ENTITIES¶ int – Max number of entities that can be in a message. (Beyond this cap telegram will simply ignore further formatting styles)