robtic-discord-startup
Version:
easily set up a Discord bot with configurable settings
19 lines (15 loc) • 621 B
TypeScript
import { Client, Collection, SlashCommandBuilder, SlashCommandSubcommandsOnlyBuilder, CommandInteraction } from 'discord.js';
declare class RoBoClient extends Client {
commands: Collection<string, CommandProps>;
cooldowns: Collection<string, number>;
constructor(intents: number[]);
}
interface CommandProps {
data:
| SlashCommandBuilder
| SlashCommandSubcommandsOnlyBuilder
| Omit<SlashCommandBuilder, "addSubcommand" | "addSubcommandGroup">;
admin?: boolean;
run: (interaction: CommandInteraction, client: RoBoClient) => Promise<void>;
}
export type { CommandProps as C };