项目作者: dermasmid

项目描述 :
Get all videos from a youtube channel, get all videos from a playlist, get all videos that match a search
高级语言: Python
项目地址: git://github.com/dermasmid/scrapetube.git
创建时间: 2021-06-25T00:04:55Z
项目社区:https://github.com/dermasmid/scrapetube

开源协议:MIT License

下载


Scrapetube

This module will help you scrape youtube without the official youtube api and without selenium.

With this module you can:

  • Get all videos from a Youtube channel.
  • Get all videos from a playlist.
  • Search youtube.

Installation

  1. pip3 install scrapetube

Usage

Here’s a few short code examples.

Get all videos for a channel

  1. import scrapetube
  2. videos = scrapetube.get_channel("UCCezIgC97PvUuR4_gbFUs5g")
  3. for video in videos:
  4. print(video['videoId'])

Get all videos for a playlist

  1. import scrapetube
  2. videos = scrapetube.get_playlist("PL-osiE80TeTt2d9bfVyTiXJA-UTHn6WwU")
  3. for video in videos:
  4. print(video['videoId'])
  1. import scrapetube
  2. videos = scrapetube.get_search("python")
  3. for video in videos:
  4. print(video['videoId'])

Full Documentation

https://scrapetube.readthedocs.io/en/latest/