Skip to main content
Every media method accepts a path, a valid URL, a Telegram file ID, in-memory bytes, or an open file object. The examples below use a path or URL; see uploads and files for the full source rules.

Voice

Audio

Use thumbnail_file_name when the thumbnail comes from memory or an open file object.

Photos

Videos

Set has_spoiler = True to hide the preview until the recipient taps it.

Documents

Set disable_content_type_detection = True only when Telegram’s automatic media type detection is not desired.

Stickers

emoji is optional and is only used when a sticker is uploaded for the first time.

Animations

Telegram treats a video as an animation when it is muted or when it is a GIF. A video with an audio track may come back as a normal video message.

Video notes

Video notes are the round, circular videos shown in Telegram chats.

Send more than one file

Passing a list to send_audio(), send_video(), send_photo(), or send_document() sends a media group. See media groups for per-item captions, file names, and chunking.
All media sends return a parsed Message object. Media groups return a list of Message objects.