cd ..

[ project / 10 ] · Discord Bot

TingBot.

A Discord bot with YouTube music, TTS with pitch control, games and bilingual commands — my first real experience consuming an external API.

PythonDiscord.pyyt-dlpgTTSFFmpegDocker
tingbot: #geral

canais

# geral
# bots
# música

voz

🔊 voice-1
tiago
TingBot
tiago

$tocar million dollar baby

TingBot

♪ adicionado · Million Dollar Baby - Tommy Richman

tiago

$falar olá mundo | 0.8

TingBot

🔊 falando no canal de voz

tiago

$jokenpo

TingBot

escolha: 🪨 📄 ✂️

Million Dollar Baby - Tommy Richman1:36 / 2:35

interface sketch · see it on GitHub

about the project

TingBot is one of my favorite projects to talk about, partly because it's genuinely funny to use and partly because it was my first real experience consuming an external API: the Discord API through discord.py. Before this, APIs were a concept. After this, they were something I understood from the inside out.

The bot runs a full YouTube music player via yt-dlp: queue management, skip, loop, volume control and a now-playing display. On top of that it has a TTS command that converts text to speech using gTTS, with optional pitch control so you can make it sound deeper or higher. The part I liked most: TTS works simultaneously with music playback. Both audio streams go through FFmpeg, mixed and played in the voice channel at the same time.

Commands are bilingual by design: every feature has a Portuguese and an English alias ($tocar / $play, $falar / $speak, $jokenpo / $rps). The bot is containerized with Docker, which handles the FFmpeg dependency automatically so setup is just cloning the repo, adding the Discord token to .env and running docker-compose up.

project.meta

type
Discord Bot
stack
Python · Discord.py · yt-dlp · gTTS · FFmpeg · Docker
source
repo

what it does

Key features

01

Full YouTube music player

Stream any YouTube URL or search query. Queue, skip, loop, volume, now playing — the full set of controls.

02

TTS with pitch control

$falar <text> | <pitch> converts text to speech and plays it in the voice channel, with an optional pitch shift parameter.

03

Simultaneous audio

TTS plays alongside music without interrupting it. Both streams go through FFmpeg and mix in the voice channel.

04

Bilingual commands

Every command has a Portuguese and English alias. The bot works the same way regardless of which you use.

05

Games

$dado / $dice rolls a die up to a configurable max. $jokenpo / $rps runs a reaction-based rock-paper-scissors with a timeout.

06

Docker deployment

Docker Compose setup includes FFmpeg. No manual PATH config: clone, fill .env with the Discord token, docker-compose up.