7. lyrics module

This module contains higher level classes to query Musixmatch API and build simple dictionary-like objects representing a track lyrics.

>>> from musixmatch.lyrics import Lyrics
>>> import musixmatch.api
>>> 
>>> try:
...     lyrics = Lyrics(lyrics_id=292)
... except musixmatch.api.Error, e:
...     pass
class Lyrics(dictionary=None, **keywords)

Bases: musixmatch.base.Item

This class builds a dict object representing a the lyrics of a track. It can get lyrics through the musixmatch.api.Method track.lyrics.get or from an already well-formed dict. Create a Track object based on a given keyword argument:

Parameters:
  • track_id – musiXmatch track ID
  • musicbrainz_id – Musicbrainz track ID
  • track_echonest_id – Echonest track ID
  • lyrics_data – an already well-formed dict of track data
Raises :

musixmatch.api.Error if musixmatch.api.ResponseStatusCode is not 200

Once information are collected, the following keys are available:

Parameters:
  • lyrics_body – the lyrics text
  • lyrics_id – the Musixmatch lyrics id
  • lyrics_language – the lyrics language
  • lyrics_copyright – the lyrics copyright statement
  • pixel_tracking_url – the pixel tracking url
  • script_tracking_url – the script tracking url

Previous topic

6. album module

Next topic

8. subtitle module

This Page