import type { SlashCommandCallbackParams } from '@rocket.chat/core-typings'; import { slashCommands } from '../../lib/utils/slashCommand'; import { executeSendMessage } from '../../meteor-methods/messages/sendMessage'; /* * Shrug is a named function that will replace /shrug commands * @param {Object} message - The message object */ slashCommands.add({ command: 'shrug', callback: async ({ message, params, userId }: SlashCommandCallbackParams<'shrug'>): Promise => { const msg = message; msg.msg = `${params} ¯\\\\_(ツ)_/¯`; await executeSendMessage(userId, msg); }, options: { description: 'Slash_Shrug_Description', params: 'your_message_optional', clientOnly: true, }, });