Giter Club home page Giter Club logo

youtube-downloader-website's Introduction

youtube-downloader-website

Flask server to download for free YouTube videos and music directly from the browser.

screenshot

Just paste the URL of the YouTube video and select the desired format. Make sure to have ffmpeg installed if you want to convert the videos in mp3.

Dependencies

This project relies on the following dependencies:

  • Flask: A web framework for Python. Install it using pip install flask

  • pytube: A lightweight, dependency-free Python library to download YouTube videos. Install it using pip install pytube

  • ffmpeg: (only if you want mp3) Required for converting audio and video formats. Install it based on your operating system. ffmpg

Ensure all dependencies are installed before running the application.

API REST

The application also provides a simple REST API for fetching information about YouTube videos.

Response

The response is in JSON format and includes the following information:

  • status: Indicates the status of the request (ok or error).
  • title: Title of the YouTube video.
  • views: Number of views.
  • author: Author of the video.
  • length: Duration of the video.
  • description: Video description.
  • thumbnail: URL of the video thumbnail.
  • publish_date: Date of video publication.
  • url: URL to watch the video.
  • rating: Video rating.

Example

/api/yt/info?url=https%3A%2F%2Fyoutu.be%2FNrQkdDVupQE

{
  "author": "GitHub",
  "description": null,
  "length": 2785,
  "publish_date": "Wed, 08 Nov 2023 00:00:00 GMT",
  "raiting": null,
  "status": "ok",
  "thumbnail": "https://i.ytimg.com/vi/NrQkdDVupQE/hq720.jpg",
  "title": "GitHub Universe 2023 opening keynote- Copilot in the Age of AI",
  "url": "https://youtube.com/watch?v=NrQkdDVupQE",
  "views": 280537
}

example of use:

import requests

url = "/api/yt/info"
video_url = "https://youtu.be/NrQkdDVupQE"

response = requests.get(url, params={"url": video_url})
data = response.json()
print(data)

youtube-downloader-website's People

Contributors

azachia avatar

Watchers

 avatar

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.