correct support for sending files via the bot

This commit is contained in:
Raven Scott
2024-06-15 02:52:20 -04:00
parent 49f4cc88ed
commit 2cf819553a
4 changed files with 46 additions and 20 deletions

View File

@ -1,7 +1,10 @@
// ping.js
export default {
handler: function(bot, args, message) {
bot.sendTextMessage('Pong!');
}
handler: function(bot, args, message) {
// Specify the path to the file you want to send
const filePath = '/Users/raven/chat/chatBot/commands/ping.js'; // Replace with the actual file path
const fileType = 'text/html'; // Specify the correct file type
// Send the file message using the bot instance
bot.sendFileMessage(filePath, fileType);
}
};