Slash Command : How to set the type channel option to voice only
public override registerApplicationCommands(registry: Command.Registry) { registry.registerChatInputCommand((builder) => builder .setName(this.name) .setDescription(this.description) .addStringOption(option => option.setName('music') .setDescription(`The music name to play`) .setRequired(true) ) .addChannelOption(option => option.setName('channel') .setDescription(`The voice channel where to play the music`) .setRequired(true) ) ); }
public override registerApplicationCommands(registry: Command.Registry) { registry.registerChatInputCommand((builder) => builder .setName(this.name) .setDescription(this.description) .addStringOption(option => option.setName('music') .setDescription(`The music name to play`) .setRequired(true) ) .addChannelOption(option => option.setName('channel') .setDescription(`The voice channel where to play the music`) .setRequired(true) ) ); }