How can Downloading a big fIle from Telegram bot API

Ok, I know in telegram bot API we can get the file_id and send it to getFile method and it will give us the file path so we can download it with an URL.

BUT it has a maximum limit of the file size of 20MB for each file.

Here is my question:

How can this bot bypass the size limitation?

Personally wouldn't believe that until tested it with a 200MB sized file and it worked very fast. I want to make one like that.

Upvotes: 4

Views: 10536

Answers (1)

rufanov
rufanov

Reputation: 3276

I assume, they bypass this limit by using client api, where getFile method have no size restrictions.

There must be another, "private" bot, that use telegram client api. Public bot just sends file_id (or whole message with attached file by calling forwardMessage) to private bot, which do actual work of downloading files.

Upvotes: 5

Related Questions