Skip to content

rockfly830/ytb_dl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

YouTube downloader

Table of Contents

About

YouTube downloader lets you downloader videos from youtube easely.

Getting Started

Prerequisites

This project needs google client and yt-dlp to works properlly.

Installing

clone this repository.

git clone https://github.com/rockfly830/you_dl.git

and install

pip install .

Usage

    from dotenv import load_dotenv
    from youtube_dl import Youtube
    import os

    # you need google api key
    API_KEY = os.getenv("API_KEY")
    
    CHANNEL_NAME = 'Google'

    youtube = Youtube(API_KEY)

    youtube.set_channel(CHANNEL_NAME)

    # To download all playlist, it is not necessary to save the return
    playlists = youtube.get_playlists().items

    first_playlist = playlists[0].title

    youtube.download_playlist(playlist_name=first_playlist,
                                output_path=f"./videos/{first_playlist}", 
                                download_thumbnail=True)

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages