Mediabot is an open source discord bot that can speak user-sent media (audio files, PDFs, Images, text) in a voice channel.

Mediabot is a bot that can, you probably guessed it, do stuff with media in Discord. The prefix is |, and most of the commands work by just specifying a message ID after the command. Message IDs can be obtained by enabling “Developer Mode” in the Discord appearance settings. You then can right click (hold down on mobile) on any message and click “Copy ID” to copy the message ID. More about commands can be viewed by running the |help command after inviting it to your server.

Source Code