OptionalabortOptionaldcDC id from which the file will be downloaded.
If provided DC is not the one storing the file, redirection will be handled automatically.
OptionalfileTotal file size, if known.
Used to determine upload part size.
In some cases can be inferred from file automatically.
OptionallimitNumber of bytes to be downloaded. By default, downloads the entire file
OptionaloffsetOffset in bytes. Must be divisible by 4096 (4 KB).
OptionalpartDownload part size (in KB). By default, automatically selected depending on the file size (or 64, if not provided). Must not be bigger than 512, must not be a fraction, and must be divisible by 4.
OptionalprogressFunction that will be called after some part has been downloaded.
Total file size (Infinity if not available)
Abort signal that can be used to cancel the download.