Medusa/modules/Music

Music

Voice channel music streaming with a Discord Activity, live synced lyrics, discovery charts, moderated playlists, audio filters, and a dashboard controller. Runs on Lavalink.

Members queue songs, albums, and playlists, and control playback with commands, buttons on the player message, the dashboard, or the Discord Activity in the voice channel.

Music needs a Lavalink v4 node. Run your own and enter its details under Lavalink Connection, or use Lavalink Hosting and switch Connection to Hosted.

Discord Activity

Launch a responsive embedded music application directly inside any Discord voice channel with the Activity button on the player card.

  • Stream and control playback straight in the voice channel.
  • Synchronized live lyrics with fluid animated gradient background.
  • Explore global charts, country top songs, and trending albums.
  • Create and manage community and private playlists.
  • Accessible directly on desktop, mobile, and web clients.

Setting Up Activities on Discord Application

To enable the Music Activity to run directly in Discord voice channels:

  1. Enable Activities in Discord Developer Portal:

    • Open the Discord Developer Portal and select your application.
    • Select Embedded App SDK (Activities) in the sidebar.
    • Toggle Enable Activities on.
  2. Configure URL Mappings:

    • Under URL Mappings, add a root mapping:
      • Prefix: /
      • Target: api.yourdomain.com/api/modules/music/activity (or local tunnel mapping to port 3001).
    • Discord proxies all iframe assets and requests via https://<application-id>.discordsays.com to your target.
  3. Configure OAuth2 Redirects:

    • In OAuth2 > General, add the redirect URI:
      • https://<application-id>.discordsays.com/.proxy/api/modules/music/activity
    • Grant the identify and guilds scopes.
  4. Bot Voice Permissions:

    • Ensure the bot has Create Instant Invite (CREATE_INSTANT_INVITE) and Send Messages in voice channels so it can generate embedded application invites (targetType: 2).

Live Lyrics

Apple Music-inspired live synchronized lyrics are accessible from the player card, the dashboard, and the Discord Activity:

  • Dynamic fluid aurora mesh backdrop that pulses smoothly during playback.
  • Synchronized karaoke-style lyric lines with active line glowing emphasis.
  • Interactive line jumping: click or tap any line to seek playback to that timestamp.
  • Automatic fallback to plain lyrics when synced LRC timestamps are unavailable.

Discovery and Albums

Both the dashboard and Discord Activity feature integrated music discovery:

  • Picked For You: Personalized recommendations and trending hits.
  • Top Tracks: Global chart songs streamed worldwide.
  • Billboard Hot 100: The premier billboard chart hits.
  • Hot Songs in Countries: Regional charts across 14 countries (United States, United Kingdom, Canada, Germany, France, Japan, Australia, Brazil, South Korea, Spain, Italy, Netherlands, Sweden, Mexico).
  • Featured Albums: Browse entire albums, view complete tracklists, durations, and queue the entire album with one click.
  • Universal Search: Instant search for songs and albums.

Playlists

Create and manage custom playlists:

  • Private Playlists: Personal playlists visible and playable only by the creator.
  • Server Playlists: Community playlists shared across the guild.
  • Channel Moderation: When Moderate Server Playlists is enabled, community playlists enter a pending state and post an approval card to the configured moderation channel. Moderators click Approve or Deny buttons to finalize visibility.

Settings

Music

SettingDefaultWhat it does
Player DisplayCardShow the player as an image card or plain text.
Default Playback Volume100Volume a new player starts at.
Auto Leave When EmptyOnLeaves when the voice channel empties.
Moderate Server PlaylistsOffRequire moderator approval for server-wide playlists.
Playlist Moderation ChannelNoneChannel where playlist approval cards are delivered.

Lavalink Connection

SettingDefaultWhat it does
ConnectionSelf-hostedSelf-hosted or Hosted. Hosted needs the Lavalink Hosting extra.
Lavalink HostlocalhostAddress of your node.
Lavalink Port2333Port of your node.
Lavalink PasswordyoushallnotpassPassword of your node.
SSL / TLS EncryptionOffConnect over a secure connection.

Commands

You must be in a voice channel to use these.

CommandWhat it does
/music play <query>Play a song, playlist or link, or add it to the queue.
/music lyricsDisplay lyrics for the currently playing song.
/music shuffleShuffle the upcoming tracks in the queue.
/music playlist <action> [name]List playlists or play a saved playlist.
/music pausePause playback.
/music resumeResume playback.
/music skipSkip the current track.
/music stopStop playback and clear the queue.
/music volume <level>Set the volume from 1 to 100.
/music seek <seconds>Jump to a point in the track.
/music loop <mode>Loop off, the track, or the queue.
/music filter <effect>Apply an audio effect preset.
/music queueShow the upcoming queue.
/music nowplaying [mode]Show the current track as a card or plain text.
Play TrackRight-click a message, then Apps > Play Track, to play its link or text.

The Music Events log records tracks starting and finishing, and the queue ending.