projek1 / plugins /downloader-mediafire.js
devstok's picture
Upload folder using huggingface_hub
d8a4b7b verified
let { mediafiredl } = require('@bochilteam/scraper')
let handler = async (m, { conn, args, usedPrefix, command }) => {
if (!args[0]) throw `Use example ${usedPrefix}${command} https://www.mediafire.com/file/941xczxhn27qbby/GBWA_V12.25FF-By.SamMods-.apk/file`
let res = await mediafiredl(args[0])
let { url, url2, filename, ext, aploud, filesize, filesizeH } = res
let caption = `
*πŸ’Œ Name:* ${filename}
*πŸ“Š Size:* ${filesizeH}
*πŸ—‚οΈ Extension:* ${ext}
*πŸ“¨ Uploaded:* ${aploud}
`.trim()
m.reply(caption)
conn.sendMessage(m.chat, { document: { url: url }, mimetype: ext, fileName: filename }, { quoted: m })
}
handler.help = ['mediafire'].map(v => v + ' <url>')
handler.tags = ['downloader']
handler.command = /^(mediafire|mf)$/i
handler.limit = true
module.exports = handler