Socket
Socket
Sign inDemoInstall

fastgenius

Package Overview
Dependencies
9
Maintainers
1
Alerts
File Explorer

Install Socket

Protect your apps from supply chain attacks

Install

fastgenius

A Python wrapper around the Genius API for large scale applications

    0.0.3

Maintainers
1

Readme

fastgenius



Code style: black

Installation

pip install fastgenius

Usage

>>> import fastgenius
>>> genius = fastgenius.Genius('client_access_token')

>>> genius.get_artist('Madonna')
Artist(Madonna)

>>> genius.get_artist('Madona')
Artist(Madona (D’Lamotta))

>>> genius.get_artist(['Madonna', 'TuPac'])
{'Madonna': Artist(Madonna), 'TuPac': Artist(2Pac)}

>>> artists = genius.get_artist(['Madonna', 'TuPac'])
>>> artists['Madonna'].songs
[]

>>> artists = genius.get_artist(['Madonna', 'TuPac'], get_songs=True)
>>> artists['Madonna'].songs
[Song(Madonna - Into the Groove (Extended Remix)),
 Song(Leo The Kind - Material Girl),
 Song(Madonna - Masterpiece - MDNA World Tour / Live 2012),
 Song(Genius Polska Tłumaczenia - Madonna & Quavo - Future),
 ...]

>>> artists['Madonna'].songs[0].lyrics
"\\nAnd you can dance\\nFor inspiration\\nCome on\\nI'm waiting\\nCome, ..."

>>> big_syke = genius.get_artist('Big Syke', get_songs=True)
>>> len(big_syke.songs)
78

>>> big_syke = genius.get_artist('Big Syke', get_songs=True, primary_artist_only=True)
>>> len(big_syke.songs)
17

Keywords

FAQs


Did you know?

Socket installs a GitHub app to automatically flag issues on every pull request and report the health of your dependencies. Find out what is inside your node modules and prevent malicious activity before you update the dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc