NAME

Net::iTMS - Interface to the information within the iTunes Music Store (iTMS)

SYNOPSIS

my $iTMS = Net::iTMS->new;

my $artist = $iTMS->get_artist(2893902);
print "Artist: ", $artist->name, "\n";

for my $album ($artist->discography) {
    print $album->title, "\n";

    for my $track ($album->tracks) {
        print "\t ", $track->number, ": ", $track->title, "\n";
    }
}

DESCRIPTION

Net::iTMS is the main class (that is, the one you should be using) for interacting with Apple's iTunes Music Store (http://apple.com/itunes/store/).

Currently, it provides means to access individual artist, album, and song information in the iTMS.

Methods

All methods return undef on error and (should) set an error message, which is available through the error method.

new([ debug => 1, [...] ])

Takes an argument list of key = value> pairs. The options available are:

tmpdir => '/some/path'

Used to specify the path to the directory where temporary files should be created. Defaults to File::Temp's default.

debug => 0 or 1

If set to a true value, debug messages to be printed to STDERR.

show_xml => 0 or 1

If set to a true value, Net::iTMS::Request will print to STDERR the XML fetched during each request.

Returns a blessed hashref (object) for Net::iTMS.

get_artist($artistId)

Takes an artistId and returns a Net::iTMS::Artist object.

get_genre($genreId)

Takes a genreId and returns a Net::iTMS::Genre object.

get_album($albumId)

Takes an albumId and returns a Net::iTMS::Album object.

get_song($songId)

Takes a songId and returns a Net::iTMS::Song object.

search_for($terms)

Takes a search string (query) and returns a Net::iTMS::Search object.

TODO

Net::iTMS::Artist
    * biography
    * influencers

Net::iTMS::Genre
    * browse, etc

Net::iTMS::Album
    * browseAlbum URL... see what information
    
Net::iTMS::Song
    * songMetaData... how to use this?  keep getting server errors

Programmatic tests, instead of hand testing by me.

Better caching (more selective updates)

Redo SYNOPSISes

BUGS

None known at the current time, but there are bound to be some.

Please report all bugs via RT at https://rt.cpan.org/NoAuth/ReportBug.html?Queue=Net-iTMS.

LICENSE

Copyright 2004, Thomas R. Sibley.

This work is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike License. To view a copy of this license, visit http://creativecommons.org/licenses/by-nc-sa/2.0/ or send a letter to:

Creative Commons
559 Nathan Abbott Way
Stanford, California 94305, USA.

AUTHOR

Thomas R. Sibley, http://zulutango.org:82/