Skip to content

Latest commit

 

History

History

AmazonProductAdvtApiSamplePerl

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>

<title>Amazon Product Advertising API - Signed Requests Sample Code - Perl</title>
<style type="text/css">
body,div,p,td,th {
	font-family: helvetica, sans-serif, arial;
	font-size: 12px;
	color: #000000;
}

.aws-h1,h1 {
	font-family: verdana, arial, helvetica, sans-serif;
	font-size: 18px;
	font-weight: bold;
	color: #000000;
}

.aws-h2,h2 {
	font-family: verdana, arial, helvetica, sans-serif;
	font-size: 14px;
	color: #c60;
}

.aws-h3,h3 {
	font-family: verdana, arial, helvetica, sans-serif;
	font-size: 12px;
	font-weight: bold;
	color: #333333;
}

/*table ID selector styles*/
#aws-table {
	border-top: 1px solid #cccccc;
	border-left: 1px solid #cccccc;
	width: 95%;
}

#aws-table td {
	font-size: 12px;
	padding: 5px 5px 5px 5px;
	border-bottom: 1px solid #cccccc;
	border-right: 1px solid #cccccc;
	vertical-align: top;
}

#aws-table th {
	font-size: 12px;
	padding: 5px 5px 5px 5px;
	border-bottom: 1px solid #cccccc;
	border-right: 1px solid #cccccc;
	vertical-align: top;
	background-color: #eeeeee;
	color: #333333;
	font-size: 12px;
	font-weight: bold;
	text-align: left;
}

/*code, note, and example styles*/
pre {
	font-size: 12px;
	margin-top: 5px;
	margin-bottom: 5px;
	color: #000066;
	padding: 12px;
	background-color: #eff7ff;
	border: 1px dashed #333;
	width: 75%;
	display: block;
}
</style>
</head>
<body>
<h2>About this Sample</h2>
<ul>
	<li>Based on the 2009-03-31 API version.</li>
	<li>This sample shows how to send an authenticated REST request to the Amazon Product Advertising API using Perl</li>
</ul>

<h2>Prerequisites</h2>
<ul>
	<li>
	    <b>Amazon Product Advertising API Account</b> (<a href="http://associates.amazon.com/gp/advertising/api/detail/main.html">http://associates.amazon.com/gp/advertising/api/detail/main.html/</a>).
	</li>
	<li>Perl version 5.8.8 or later</li>
	<li>The following Perl Modules:
	    <ol>
		<li>Data::Dumper <a href="http://search.cpan.org/perldoc?Data::Dumper">http://search.cpan.org/perldoc?Data::Dumper</a></li>
		<li>Digest::SHA  <a href="http://search.cpan.org/perldoc?Digest::SHA" >http://search.cpan.org/perldoc?Digest::SHA </a></li>
		<li>URI::Escape  <a href="http://search.cpan.org/perldoc?URI::Escape" >http://search.cpan.org/perldoc?URI::Escape </a></li>
		<li>LWP::Simple  <a href="http://search.cpan.org/perldoc?LWP::Simple" >http://search.cpan.org/perldoc?LWP::Simple </a></li>
		<li>XML::Simple  <a href="http://search.cpan.org/perldoc?XML::Simple" >http://search.cpan.org/perldoc?XML::Simple </a></li>
	    </ol>
	</li>
</ul>

<h2>Reference Documentation</h2>
<ul>
	<li><a href="http://associates.amazon.com/gp/advertising/api/detail/main.html/">Online Reference
	Documentation</a></li>
</ul>

<h2>Quick Start</h2>
Sample comes with a Perl Module with the signature logic and a Perl script that uses the module to perform a simple ItemLookup operation.
To get started with the sample, follow these steps:
<ol>
	<li>Ensure the pre-requisite Perl Modules are installed and usable</li>
	<li>Log in to the AWS portal at <a href="http://aws.amazon.com/">http://aws.amazon.com/</a> and copy your AWS Access Key ID and your AWS Secret Key. 
	    You can find them under the Your Account -&gt; Access Identifiers menu after you log in.</li>
	<li>Extract the <strong>amazon-product-advt-api-sample-perl-query.zip</strong> file into a working directory.</li>
	<li>Open the <strong>SignedRequestSample.pl</strong> file in an editor and change the <tt>myAWSId</tt> and <tt>myAWSSecret</tt> values
	    to match the ones you obtained from AWS.
	<li>
	    Run the script:
	    <pre>
    ./SignedRequestSample.pl
	    </pre>
	    Or,
	    <pre>
    ./SignedRequestSample.pl [insert ASIN here]
	    </pre>
	</li>
</ol>


<h2>Comments, Questions or Feedback</h2>
If you have any comments, questions or feedback on the library, please visit the
<a href="http://developer.amazonwebservices.com/connect/forum.jspa?forumID=9">Amazon
Amazon Product Advertising API discussion forums</a>.
</body>
</html>