TeamSpeak 3 MusicBot in Java

1.2k Views Asked by At

I want to make a TeamSpeak 3 Musicbot in Java. But I don't find any Protocol from Teamspeak for the Voice transmission. And after searching for a Client API, for Java, I didn't find anything. Only for a ServerQuery but that doesn't help me I think. I only want the Client to connect to the Server and then plays a Song, though that wouldn't be that hard!

Maybe you Guys can help me?

2

There are 2 best solutions below

0
On

Teamspeak does not have an official client-api. You can only use the Query-API and create plugins. As the Query-API does not support any voice-communication, that's not the way you should go. The (most) official way of creating a Teamspeak3 MusicBot would be to run a client on your server which has a plugin installed which allows you to play music (more or less a soundboard). Sinusbot is exactly built this way.

Another "unofficial" option would be to make use of unofficial reverses of the teamspeak-protocol and built you own client from these. If you want more information about this, this repository might help you (and look for other projects the creator pushed, they might help you too).

0
On

I'm not quite sure if this helps, but have been developing a TeamSpeak 3 music bot using Kotlin, which is compatible with Java as it runs on the JVM (Java Virtual Machine)

The way it works is that it first launches the TeamSpeak client and connects to the desired server and channel, then it starts monitoring the chat log -> the bot can be controlled by entering commands into the chat. The bot uses the TeamSpeak ClientQuery via Netcat to send messages to the chat. It is completely client-side so you don't need to be server admin to get it working.

The bot currently supports Spotify, YouTube, and SoundCloud. You can check it out at https://gitlab.com/Bettehem/ts3-musicbot