Discord Quran Bot

Node / Discord Bot

Tech Stack

Discord.jsTypeScriptNode.jsFFmpeg

Gallery

Discord Quran Bot screenshot 1

Overview

A feature-rich, optimized Discord bot built with Discord.js and TypeScript designed to stream high-quality Quranic recitations directly into server voice channels.

The bot supports dynamic reciter queries from over 238 reciters worldwide, parsing and presenting complex narration styles (Murattal, Mojawwad, Mo'lim) through interactive Discord select menus. Settings are persistently stored per-guild to ensure a seamless experience.

Key technical achievements include: 1. Direct OggOpus Transcoding: Spawns optimized, single-threaded native FFmpeg/FFprobe processes to stream pre-encoded OggOpus files, lowering CPU and bandwidth usage by up to 50%. 2. Automated Friday Al-Kahf Broadcasts: Features a timezone-optimized cron scheduler that automatically creates dedicated voice channels, applies server-wide mute controls for a quiet listening environment, and cleans up resources post-broadcast. 3. Interactive Audio Controller: Built with symmetric 2-row button layouts, seeking controls, volume adjustments, and a math-calculated real-time visual progress bar updated asynchronously. 4. Gateway De-duplication & Resilience: Implements gateway interaction deduplication and retry handlers to gracefully manage common Discord API timeout codes.