http://qs1969.pair.com?node_id=461690


in reply to Music CD Data

A scanner I bought on an auction site arrived today, and I've been playing with scanning my book and CD barcodes and getting the details off Amazon. The following code seems to work on about 50% of the CDs I've tried:
use Net::Amazon; my $ua = Net::Amazon->new( token => '<your amazon id>' ); while ( my $upc = <> ) { my $response = $ua->search( upc => $upc, mode => 'music' ); if ( $response->is_success() ) { print $response->as_string(), "\n"; } else { print "Error: ", $response->message(), "\n"; } }