mtproto-core icon indicating copy to clipboard operation
mtproto-core copied to clipboard

How to Download File to Stream

Open a4smanjorg5 opened this issue 3 years ago • 0 comments

I want to get large file by fileId and download it to stream.

const MTProto = require('@mtproto/core');
var mtp = new MTProto(...);
var dest = fs.createWriteStream('/path/to/file');
... // statements about 'mtp' download file to 'dest'

How to do it?

a4smanjorg5 avatar May 17 '21 01:05 a4smanjorg5