Skip to main content

A Basic YouTube Music scrapper For Python Programming Language

Project description

YouTube-Music-API

What's new in version 1.9?

  • Stable release.
  • Updated getsonginfo() function.
  • Updated Code Format.

How To Use

  • To play the song, Create the code like this:
# import the module

import YouTubeMusicAPI

# Use .play for playing song

# Type The Song Name inside the brackets eg: ("Faded Alan Walker")

YouTubeMusicAPI.play("Song Name")
  • To play the song in VLC Media Player without downloading, Create the code like this:
# import the module

import YouTubeMusicAPI

# Use .playonvlc for streaming song in VLC Media Player

# Type The Song Name inside the brackets eg: ("Faded Alan Walker")

YouTubeMusicAPI.playonvlc("Song Name")
  • To get song meta data, Create the code like this:
# import the module

import YouTubeMusicAPI

# Use .getsonginfo to get song information

# Type The Song Name inside the brackets eg: ("Faded")

YouTubeMusicAPI.getsonginfo("Song Name")

# Output

{
    'song_name': 'Faded', 
    'total_listeners': '29947694', 
    'duration': 213, 
    'artist': 'Alan Walker - Topic', 
    'album_art': 'https://i.ytimg.com/vi_webp/d0eUMnJ5kTA/maxresdefault.webp', 
    'artist_url': 'http://music.youtube.com/channel/UCaXJEi-wOOVe2eZZHzyz4mQ', 
    'track_url': 'https://music.youtube.com/watch?v=d0eUMnJ5kTA', 
    'track_id': 'd0eUMnJ5kTA'
}

MIT License | Copyright (c) 2021 Sijey

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

YouTubeMusicAPI-1.9.tar.gz (4.2 kB view hashes)

Uploaded Source

Built Distribution

YouTubeMusicAPI-1.9-py3-none-any.whl (4.1 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page