Coder Social home page Coder Social logo

upekshaip / tg-ytdlp-bot Goto Github PK

View Code? Open in Web Editor NEW
21.0 1.0 9.0 39 KB

This is a telegram deployable bot for downloading any private video files from any site (Intergrated with yt-dlp). Also can download private video or playlist with cookies too

Home Page: https://upekshaip.me/projects/telegram-ytdlp-bot

License: GNU General Public License v3.0

Dockerfile 0.70% Python 99.30%
manage-cookies playlist-downloader telegram telegram-bot user-management video-downloader yt-dlp

tg-ytdlp-bot's Introduction

cookiebot - tg-ytdlp-bot

download private youtube/ videos using cookie file

Full documentation available on - https://upekshaip.me/projects

Deploy on VM

  • First, You need to add your bot to the logging channel and subscription channel. Both are required.
  • Give me a strar and fork this repository. Then change the _config.py file to config.py
  • Add your configuration for the config.py file.

Setup debian/any for docker

  • sudo apt-get update
  • sudo apt -y install apt-transport-https ca-certificates curl gnupg2 software-properties-common
  • curl -fsSL https://download.docker.com/linux/debian/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg
  • echo "deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/debian $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list
  • sudo apt update
  • sudo apt install -y docker-ce docker-ce-cli containerd.io
  • docker -v

Setting the config.py file

  • git clone https://github.com/upekshaip/tg-ytdlp-bot.git
  • cd tg-ytdlp-bot
  • sudo mv _config.py config.py
  • nano config.py
  • Now you can edit your config before the deployment
  • After your edit process please follow as below

Install Dockerfile

  • sudo docker build . -t tg-public-bot
  • sudo docker ps -a
  • sudo docker run tg-public-bot

additions

  • added Config obj for configurations
  • can add custom name for playlist. 1st video will start "bla bla - Part 1" and so on. It must give a range if you need the custom name like -> (https://blabla.blaa*1*3*name)
  • no need to give a range for videos for only one. simply give the url (https://blabla.blaa)
  • if you give only a playlist url, bot will download the first video of that playlist.
  • if you want to download a range of videos, give a specific rang like -> (https://blabla.blaa*1*3)

User commands

  • /check_cookie - Check cookie file
  • /help - Help message
  • /start - start the bot
  • /clean - clean your working directory
  • /usage - See your usage

Admin commands

  • start - Start the bot
  • help - Send help text
  • run_time - Show bot runtime
  • log - Get user logs (ex: /log 10101010)
  • broadcast - Send message to all users (You needs to reply any message with this command. then that message will be broadcasteds)
  • clean - clean your working directory
  • usage - Get all logs
  • check_cookie - Check cookie file
  • save_as_cookie - Save txt as cookie (save text as cookie)
  • download_cookie - Download the cookie file
  • block_user - Block user (ex: /block_user 10101010)
  • unblock_user - Unblock user (ex: /unblock_user 10101010)
  • all_users - Get all users
  • all_blocked - Get all blocked users
  • all_unblocked - Get all unblocked users

Link command pattern spec (Just send the link)

https://blabla.blaa

  • download video with real name
  • download only the 1st video of the playlist

https://blabla.blaa*1*3

  • download the given range of playlist with real name

https://blabla.blaa*1*3*name

  • download the given range of playlist with coustom name
  • video names are like this ->
    • "name - Part 1"
    • "name - Part 2"

Added new

  • Added cookie download feature for each user
  • added db per user

TODO:

  • Need to add custom formatter selector for download
  • Need to add mp3 support
  • Need to add Google drive support to store files

tg-ytdlp-bot's People

Contributors

upekshaip avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

tg-ytdlp-bot's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.