Skip to content

Discord bot do download youtube videos (Using Py-Cord and yt_dlp)

Notifications You must be signed in to change notification settings

lhwe/ytdl-pycord

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

YouTube Downloader Bot

A simple discord bot that lets you download YouTube video's over discord.

Features

  • Download videos in mp4 format.
  • Download audio in mp3 format.
  • Slash commands for easy interaction.

Prerequisites

  • Python 3.8 or higher
  • discord.py library
  • yt-dlp library

Installation

  1. Clone this repository:

    git clone https://github.com/lhwe/ytdl-pycord.git
  2. Navigate to the project directory:

    cd ytdl-pycord
  3. Install the required Python packages:

    pip install discord.py yt-dlp
  4. Change the contents of tokenHandler.py to have your bot token:

    TOKEN = 'Your token goes here'

Usage

  1. Run the bot:
    python3 ytdl-bot.py
  2. In Discord, use the following commands:
  • /help - Displays a help message.
  • /download <url> [format] - Downloads the video or audio from the specified YouTube URL. Format can be mp3 or mp4 (default is mp4).

Example

  • To download a video:
/download https://www.youtube.com/watch?v=dQw4w9WgXcQ
  • To download audio:
/download https://www.youtube.com/watch?v=dQw4w9WgXcQ format:mp3

About

Discord bot do download youtube videos (Using Py-Cord and yt_dlp)

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages