Net::Spotify - Perl interface to the Spotify Metadata API
use Net::Spotify; my $spotify = Net::Spotify->new(); # lookup a track my $track_xml = $spotify->lookup( uri => 'spotify:track:6NmXV4o6bmp704aPGyTVVG' ); # search an artist my $artist_xml = $spotify->search( 'artist', q => 'hendrix' );
This module provides a simple interface to the Spotify Metadata API https://developer.spotify.com/technologies/web-api/. The API allows to explore Spotify's music catalogue. It is possible to lookup a specific Spotify URI and retrieve various information about the resource it represents, and search for artists, albums and tracks. The output is in XML format.
Performs a lookup on a specific Spotify URI. Net::Spotify::Lookup is used for handling the request.
Mandatory, represents the Spotify URI. Example:
Optional, a comma separated list of words that defines the detail level in the response. Allowed values depend on the Spotify URI type.
# lookup an album and retrieve detailed information about all its tracks $spotify->lookup( uri => 'spotify:album:6G9fHYDCoyEErUkHrFYfs4', extras => 'trackdetail' );
Performs a search. Net::Spotify::Search is used for handling the request.
Mandatory, represent the type of search. Possible values are:
Mandatory, it's the search string.
Optional, represent the page of the resultset to return, defaults to 1.
# search all the tracks where the track name, artist or album matches the # the query string (purple) and return the results in page 2 $spotify->search( 'track', q => 'purple', page => 2 );
<edoardo at cpan.org>
Please report any bugs or feature requests to
bug-net-spotify at rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Net-Spotify. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
You can find documentation for this module with the perldoc command.
You can also look for information at:
This product uses a SPOTIFY API but is not endorsed, certified or otherwise approved in any way by Spotify. Spotify is the registered trade mark of the Spotify Group.
Copyright 2009 Edoardo Sabadelli, all rights reserved.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.