How to Save and Share Different Files using Telegram Bots?

R Updated
how to save and share different files using telegram bots (1)
Enter the title for the tutorial
How to Save and Share Different Files using Telegram Bots?
Enter the detailed description of the tutorial


Watch Video



Telegram has a limit of 2 GB per file. This is a pretty high limit, and will accommodate the sending of compressed images, documents, and things of that nature. However, if you need to send a file that's larger than 2 GB, there is a workaround.

If the file is already stored somewhere on the Telegram servers, you don't need to upload it again, each file object has a file-id field, simply pass this file-id as a parameter instead of uploading. There are no limits for files sent this way. Provide Telegram with an HTTP URL for the file to be sent. Telegram will download and send the file. 5 MB max size for photos and 20 MB max for other types of content. Post the file using multipart/form-data in the usual way that files are uploaded via the browser. 10 MB max size for photos, 50 MB for other files. Sending by file-id

 It is not possible to change the file type when resending by file-id. I.e. a video can't be sent as a photo, a photo can't be sent as a document, etc. It is not possible to resend thumbnails. Resending a photo by file-id will send all of its sizes. File-id is unique for each individual bot and can't be transferred from one bot to another. Sending by URL


User reviews

1 review
Overall rating
 
5.0
Usefulness
 
5.0(1)
Quality
 
5.0(1)
Accuracy of Information
 
5.0(1)
Already have an account? or Create an account
Overall rating
 
5.0
Usefulness
 
5.0
Quality
 
5.0
Accuracy of Information
 
5.0
When sending by URL the target file must have the correct MIME type (e.g., audio/mpeg for send Audio, etc.). In send Document, sending by URL will currently only work for gif, pdf and zip files. To use send Voice, the file must have the type audio/ogg and be no more than 1MB in size. 1–20MB voice notes will be sent as files. Other configurations may work but we can't guarantee that they will.
R
Report this review Comments (0) | Was this review helpful? 0 0