| 5 | description: 'Get a random Rose Day message/quote', |
| 6 | usage: '.roseday', |
| 7 | async handler(sock, message, args, context) { |
| 8 | const chatId = context.chatId || message.key.remoteJid; |
| 9 | try { |
| 10 | const res = await fetch(`https://api.princetechn.com/api/fun/roseday?apikey=prince`); |
| 11 | if (!res.ok) { |
| 12 | throw await res.text(); |
| 13 | } |
| 14 | const json = await res.json(); |
| 15 | const rosedayMessage = json.result; |
| 16 | await sock.sendMessage(chatId, { text: rosedayMessage }, { quoted: message }); |
| 17 | } |
| 18 | catch (error) { |
| 19 | console.error('RoseDay Command Error:', error); |
| 20 | await sock.sendMessage(chatId, { text: '❌ Failed to get Rose Day quote. Please try again later!' }, { quoted: message }); |
| 21 | } |
| 22 | } |
| 23 | }; |