jellyfin-discord-bot/server/commands/echo.ts

21 lines
542 B
TypeScript
Raw Normal View History

2023-04-15 22:06:35 +02:00
import { ApplicationCommandOptionType } from 'discord.js'
import { Command } from '../structures/command'
import { RunOptions } from '../types/commandTypes'
2023-10-21 14:56:15 +02:00
import { logger } from '../logger'
2023-04-15 22:06:35 +02:00
export default new Command({
name: 'echo',
description: 'Echoes a text',
options: [
{
name: 'echo',
description: 'The text to echo',
type: ApplicationCommandOptionType.String,
required: true
}
],
run: async (interaction: RunOptions) => {
2023-10-21 14:56:15 +02:00
logger.info('echo called')
2023-04-15 22:06:35 +02:00
interaction.interaction.reply(interaction.toString())
}
})