Events
The events emitted by a DisTube instance.
Enumeration Members
Section titled “Enumeration Members”ADD_LIST
Section titled “ADD_LIST”ADD_LIST: "addList";Emitted after a new playlist is added to a Queue.
ADD_SONG
Section titled “ADD_SONG”ADD_SONG: "addSong";Emitted after a new song is added to a Queue.
CHANGE_FILTER
Section titled “CHANGE_FILTER”CHANGE_FILTER: "changeFilter";Emitted when the audio filters of a Queue are changed.
DEBUG: "debug";Emitted to provide debug information from DisTube’s operation.
DELETE_QUEUE
Section titled “DELETE_QUEUE”DELETE_QUEUE: "deleteQueue";Emitted when a Queue is deleted.
DISCONNECT
Section titled “DISCONNECT”DISCONNECT: "disconnect";Emitted when the bot is disconnected from a voice channel.
EMPTY: "empty";Emitted when a Queue runs out of songs to play.
ERROR: "error";Emitted when DisTube encounters an error while playing songs.
It is the only special event: Node.js crashes the process when the
"error" event is emitted without any listener. DisTube handles it
gracefully instead, following DisTubeOptions.unhandledError.
FFMPEG_DEBUG
Section titled “FFMPEG_DEBUG”FFMPEG_DEBUG: "ffmpegDebug";Emitted for logging FFmpeg debug information.
FINISH
Section titled “FINISH”FINISH: "finish";Emitted when a Queue is finished, and its autoplay mode is disabled.
FINISH_SONG
Section titled “FINISH_SONG”FINISH_SONG: "finishSong";Emitted when a song finished playing.
INIT_QUEUE
Section titled “INIT_QUEUE”INIT_QUEUE: "initQueue";Emitted when a Queue is initialized, to change its default properties.
NO_RELATED
Section titled “NO_RELATED”NO_RELATED: "noRelated";Emitted when the autoplay mode is enabled and no related song could be found.
PAUSE_SONG
Section titled “PAUSE_SONG”PAUSE_SONG: "pauseSong";Emitted when a guild stream is paused.
PLAY_SONG
Section titled “PLAY_SONG”PLAY_SONG: "playSong";Emitted when a song starts playing.
PRELOAD_ERROR
Section titled “PRELOAD_ERROR”PRELOAD_ERROR: "preloadError";Emitted when pre-buffering the next song in a Queue fails.
PRELOAD_SONG
Section titled “PRELOAD_SONG”PRELOAD_SONG: "preloadSong";Emitted when DisTube starts pre-buffering / pre-fetching the next song in a Queue.
PRELOADED_SONG
Section titled “PRELOADED_SONG”PRELOADED_SONG: "preloadedSong";Emitted when the next song in a Queue has been pre-buffered and is ready.
RESUME_SONG
Section titled “RESUME_SONG”RESUME_SONG: "resumeSong";Emitted when a paused guild stream is resumed.
SEEK_SONG
Section titled “SEEK_SONG”SEEK_SONG: "seekSong";Emitted when a guild stream is seeked to a new position.
SET_VOLUME
Section titled “SET_VOLUME”SET_VOLUME: "setVolume";Emitted when the volume of a guild stream is changed.
SHUFFLE_QUEUE
Section titled “SHUFFLE_QUEUE”SHUFFLE_QUEUE: "shuffleQueue";Emitted after the songs of a Queue have been shuffled.
SKIP_SONG
Section titled “SKIP_SONG”SKIP_SONG: "skipSong";Emitted when a song is skipped.
VOICE_CHANNEL_CHANGE
Section titled “VOICE_CHANNEL_CHANGE”VOICE_CHANNEL_CHANGE: "voiceChannelChange";Emitted when the bot is moved to another voice channel.