Soundboard
Send Soundboard Sound
PostAPISendSoundboardSound
Send a soundboard sound to a voice channel the user is connected to.
import { sendSound } from "dressed";
await sendSound(channelId, data);Requires the SPEAK and USE_SOUNDBOARD permissions, and also the USE_EXTERNAL_SOUNDS permission if the sound is from a different server. Additionally, requires the user to be connected to the voice channel, having a voice state without deaf, self_deaf, mute, or suppress enabled.
List Default Soundboard Sounds
GetAPISoundboardDefaultSounds
Returns an array of soundboard sound objects that can be used by all users.
import { listSounds } from "dressed";
const sounds = await listSounds(guildId);Includes user fields if the bot has the CREATE_GUILD_EXPRESSIONS or MANAGE_GUILD_EXPRESSIONS permission.
Get Guild Soundboard Sound
GetAPIGuildSoundboardSound
Returns a soundboard sound object for the given sound id.
import { getSound } from "dressed";
const sound = await getSound(guildId, soundId);Includes the user field if the bot has the CREATE_GUILD_EXPRESSIONS or MANAGE_GUILD_EXPRESSIONS permission.
Create Guild Soundboard Sound
PostAPIGuildSoundboardSound
Create a new soundboard sound for the guild.
import { createSound } from "dressed";
await createSound(guildId, data);- Requires the
CREATE_GUILD_EXPRESSIONSpermission. - Soundboard sounds have a max file size of 512kb and a max duration of 5.2 seconds.
Modify Guild Soundboard Sound
PatchAPIGuildSoundboardSound
Modify the given soundboard sound.
import { modifySound } from "dressed";
await modifySound(guildId, soundId, data);- For sounds created by the current user, requires either the
CREATE_GUILD_EXPRESSIONSorMANAGE_GUILD_EXPRESSIONSpermission. - For other sounds, requires the
MANAGE_GUILD_EXPRESSIONSpermission.
Delete Guild Soundboard Sound
DeleteAPIGuildSoundboardSound
Delete the given soundboard sound.
import { deleteSound } from "dressed";
await deleteSound(guildId, soundId);- For sounds created by the current user, requires either the
CREATE_GUILD_EXPRESSIONSorMANAGE_GUILD_EXPRESSIONSpermission. - For other sounds, requires the
MANAGE_GUILD_EXPRESSIONSpermission.