You need standard libraries and Aegis.cpp for this.
git clone https://github.com/gerdoe-jr/teeworlds-bridge
cd teeworlds-bridge
mkdir build && cd build
cmake ..
make
sv_discord_token "token"
sv_discord_server "15351155461346"
sv_discord_channel "12345567899765"
Invite bot on your Discord Server and launch server. Good! Now you can chat via Discord.