Closed MillesC closed 2 months ago
else if (msg.body === '!mediainfo' && msg.hasMedia) {
const attachmentData = await msg.downloadMedia();
msg.reply(`
*Media info*
MimeType: ${attachmentData.mimetype}
Filename: ${attachmentData.filename}
Data (length): ${attachmentData.data.length}
`);
**The console response is:**
(node:18132) UnhandledPromiseRejectionWarning: TypeError: msg.downloadMedia is not a function
In fact, the API responds, but what I need is to download the image or document
Is there an existing issue for this?
Is your feature request related to a problem? Please describe.
I have tried several ways to save received images or files to a file, but I have not been able to do so. Thanks for your answers.
Describe the solution you'd like.
Save received images and documents
Describe an alternate solution.
No response
Additional context
No response