upload.getWebfile

Returns content of an HTTP file or a part, by proxying the request through telegram.

upload.webFile#21e753bc size:int mime_type:string file_type:storage.FileType mtime:int bytes:bytes = upload.WebFile;
---functions---
upload.getWebFile#24e6818d location:InputWebFileLocation offset:int limit:int = upload.WebFile;

Parameters

Name Type Description
location InputWebFileLocation The file to download
offset int Number of bytes to be skipped
limit int Number of bytes to be returned

Result

upload.WebFile

Possible errors

Code Type Description
400 LOCATION_INVALID The provided location is invalid
400 BOT_METHOD_INVALID This method can't be used by a bot