// code from goatstore // api: https://store.agi.bd const fs = require("fs-extra"); const request = require("request"); const path = require("path"); module.exports = { config: { name: "owner", version: "1.3.0", author: "Abir", role: 0, shortDescription: "Owner information with image", category: "Information", guide: { en: "owner" } }, onStart: async function ({ api, event }) { const ownerText = `╭─ 👑 Oᴡɴᴇʀ Iɴғᴏ 👑 ─╮ │ 👤 Nᴀᴍᴇ : Abir Ahmed │ 🧸 Nɪᴄᴋ : Abir │ 🎂 Aɢᴇ : bolbo na │ 💘 Rᴇʟᴀᴛɪᴏɴ : Sɪɴɢʟᴇ │ 🎓 Pʀᴏғᴇssɪᴏɴ : Sᴛᴜᴅᴇɴᴛ │ 📚 Eᴅᴜᴄᴀᴛɪᴏɴ : bolbo na │ 🏡 Lᴏᴄᴀᴛɪᴏɴ : Mymenshing ├─ 🔗 Cᴏɴᴛᴀᴄᴛ ─╮ │ 📘 Facebook : https://www.facebook.com/profile.php?id=61595143940414 │ 💬 Messenger: https://www.facebook.com/profile.php?id=61595143940414 │ 📞 WhatsApp : wa.me/01332301530 ╰────────────────╯`; const cacheDir = path.join(__dirname, "cache"); const imgPath = path.join(cacheDir, "owner.jpg"); if (!fs.existsSync(cacheDir)) fs.mkdirSync(cacheDir); const imgLink = "https://i.imgur.com/1G4ZhU7.jpeg"; const send = () => { api.sendMessage( { body: ownerText, attachment: fs.createReadStream(imgPath) }, event.threadID, () => fs.unlinkSync(imgPath), event.messageID ); }; request(encodeURI(imgLink)) .pipe(fs.createWriteStream(imgPath)) .on("close", send); } };