Welcome to discord-ext-music’s documentation!¶
An easy to use music extension for discord.py
Features:¶
It’s easy to use and can be used for complex process.
Complete playback controls and thread-safe.
The audio source can be used in discord.py audio library.
Quick Usage¶
from discord.ext.commands import Bot
from discord.ext.music import MusicClient, WAVAudio, Track
bot = Bot()
@bot.command()
async def play(ctx):
voice_user = ctx.message.author.voice
music_client = await voice_user.channel.connect(cls=MusicClient)
track = Track(
WAVAudio('audio.wav'), # AudioSource
'This is audio' # name
)
await music_client.play(track)
bot.run('token')