Dezio/README.md
2026-12-02 16:25:57 -06:00

69 lines
3.3 KiB
Markdown

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<p align="center"><img src="assets/images/banner.jpg" alt="Dezio" width="720"></p>
<h1 align="center">Dezio</h1>
<p align="center">
An all-in-one Discord bot written in Rust — music with a live player, ListenBrainz stats, video downloads, games, AI chat,
moderation, logging and a web dashboard.
</p>
<p align="center">
<a href="https://discord.com/oauth2/authorize?client_id=1387839600017412106&scope=bot%20applications.commands&permissions=8"><b>➕ Add to your server</b></a> ·
<a href="https://astar76.com">Website</a> ·
<a href="https://discord.gg/UnSga5DmR7">Support server</a>
</p>
---
## What it does
| | |
|---|---|
| 🎵 **Music** | Songs and playlists from a search or link, a live player with buttons, `/music`, vote-skip, read-ahead buffering for slow connections, auto-leave |
| 📊 **Music stats** (ListenBrainz) | Now playing, top artists/albums/tracks, collages, "Who knows?" charts, lyrics, Pixel Jumble |
| ⬇️ **Downloads** | TikTok, Instagram, YouTube, X, Reddit and more — converted while downloading, sized for Discord |
| 🛡️ **Moderation & logs** | Kick, ban, timeout, purge (15 filters), locks, slowmode, full event logging |
| 👋 **Server setup** | Welcome cards, autoroles, sticky roles, reaction roles, role menus, media-only and voting channels |
| 🎮 **Games & casino** | Chess, Connect 4, Wordle, Akinator, Cookie Clicker, blackjack, slots, roulette … |
| 🤖 **Fun** | AI chat, GIF actions, confessions, phone calls between servers, styled quotes |
| 🕹️ **Game Boy** | A Game Boy you can play inside Discord (Activity) |
| ⚙️ **Dashboard** | Sign in with Discord to change settings, quote style and role menus |
Every command works as a slash command and most with the `D!` prefix. Run `/help` for the full list.
## Built with
[twilight](https://github.com/twilight-rs/twilight) (gateway, HTTP, cache) · [songbird](https://github.com/serenity-rs/songbird) (voice) ·
tokio · axum (dashboard) · ratatui (console) · cosmic-text (text and emoji drawing) · yt-dlp and ffmpeg (media)
## Run it yourself
You need Rust, `ffmpeg`, `yt-dlp` and `curl` on the host (plus `libopus`).
```bash
cp .env.example .env # DISCORD_BOT_TOKEN=… (and optional keys, see below)
cargo build --release
DEZIO_LIVE=1 ./target/release/dezio # console UI in a terminal
DEZIO_LIVE=1 ./target/release/dezio --headless # plain logs (for a service)
```
Without `DEZIO_LIVE=1` it only lists its commands and exits, so tests never touch Discord.
`cargo test` runs the unit tests (some live tests are `#[ignore]`d and need the internet).
Optional settings (environment or `.env`): `OPENROUTER_KEY` (AI chat), `STEAMGRIDDB_API_KEY` (Game Boy
covers), `DASHBOARD_URL`, `DASHBOARD_CLIENT_SECRET`, `DASHBOARD_HOST` / `DASHBOARD_PORT`, `IG_COOKIES`.
Data lives in `data/*.json`. Game Boy ROMs are **not** included — put your own in `assets/roms/<group>/`.
## Layout
```
src/commands/ one folder or file per feature (music, lastfm, media, games, fun, logs …)
src/web/ dashboard + Game Boy Activity server
src/tui.rs terminal console
assets/ fonts, images, word lists, presets
web/ website, dashboard and Activity pages
docs/ Top.gg listing text
```
Project history and decisions are in [ROADMAP.md](ROADMAP.md).