SUBZERO-MD / plugins /fun-quote.js
mrfrank-ofc's picture
Upload 63 files
8d8b0ad verified
raw
history blame
1.33 kB
/*╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺
⭐PROJECT NAME:
SUBZERO WHATSAPP MD BOT
⭐DEVELOPER
MR FRANK
⭐ MY TEAM
XERO CODERS
⭐ OUR WEBSITE
https://github.com/ZwSyntax/SUBZERO-MD
© TRY DECRYPTING IF YOU CAN⚠
╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺╺*/
const axios = require('axios');
const { cmd } = require('../command');
cmd({
pattern: "quote",
desc: "Get a random inspiring quote.",
category: "fun",
react: "💬",
filename: __filename
},
async (conn, mek, m, { from, reply }) => {
try {
const response = await axios.get('https://api.gifted.my.id/api/fun/quotes?apikey=gifted');
const quote = response.data;
const message = `
💬 "${quote.content}"
- ${quote.author}
*QUOTES BY MR FRANK OFC*
`;
return reply(message);
} catch (e) {
console.error("Error fetching quote:", e);
reply("¢συℓ∂ ησт ƒєт¢н α qυσтє. ρℓєαѕє тяу αgαιη ℓαтєя.");
}
});