diff --git a/src/commands/moderation/clear.js b/src/commands/moderation/clear.js new file mode 100644 index 0000000..813ac78 --- /dev/null +++ b/src/commands/moderation/clear.js @@ -0,0 +1,23 @@ +import { PermissionFlagsBits, SlashCommandBuilder } from 'discord.js'; +import { ACCESS_LEVELS } from '../../config/constants.js'; +import { notImplementedEmbed } from '../../ui/embeds.js'; + +export const access = ACCESS_LEVELS.STAFF; + +export const data = new SlashCommandBuilder() + .setName('clear') + .setDescription('Supprimer des messages') + .setDefaultMemberPermissions(PermissionFlagsBits.ManageMessages) + .addIntegerOption((option) => + option + .setName('amount') + .setDescription('Nombre de messages') + .setRequired(true) + .setMinValue(1) + .setMaxValue(100), + ); + +// TODO(M8-T05): channel.bulkDelete(amount, true) and log the action. +export async function execute(interaction) { + await interaction.reply({ embeds: [notImplementedEmbed('/clear')] }); +}