Amazon Product Advertising API Best Practices

The following checklist of best practices describes how you can increase the effectiveness of your Amazon Product Advertising API applications.


Created On: November 16, 2007


Use the Latest API Version

The Amazon Product Advertising API makes frequent releases. Each release either adds functionality or increases the accuracy, speed, and stability of the Amazon Product Advertising API. Most releases do both. Check https://aws.amazon.com/resources frequently for documentation about the latest release.

To use the latest version of the API, you must include the version parameter in your requests. Otherwise, the Amazon Product Advertising API uses the default API version, which is from 2005-10-05.

Use the Right Response Group

One of the great features of the Amazon Product Advertising API is the control you have over the amount of information returned in responses. The Amazon Product Advertising API has over 55 response groups. So, you can get exactly the information you need and no more.

We recommend that you specify response groups that return only the information your application needs. Response groups, such as Large, ItemAttributes, and MerchantItemAttributes, return lots of data. Such large data sets sometimes incur performance penalties both in the Amazon Product Advertising API fulfilling the request, and in your application's processing of the response.

Use Your Associate Tag in Amazon Product Advertising API Requests

To make requests to the API you must register with Amazon Associates at https://affiliate-program.amazon.com/gp/flex/associates/apply-login.html. In return, you receive an Associate tag, which identifies your Associate Account. You must include your AssociateTag with every Product Advertising API request.

Associate tags in:

  • North America end with -20
  • Europe end with -21
  • Japan end with -22

Handling Errors

The Amazon Product Advertising API returns errors in three categories so that you can easily determine how best to handle the problem:

  • 2XX errors are caused by mistakes in the request. For example, your request might be missing a required parameter. The error message in the response gives a clear indication what is wrong.
  • 4XX errors are non-transient errors. Upon receiving this error, resubmit the request.
  • 5XX errors are transient errors reflecting an error internal to Amazon. A 503 error means that you are submitting requests too quickly and your requests are being throttled. If this is the case, you need to slow your request rate to one request per second.

Use Caches Carefully

Amazon Product Advertising API product data changes often. Prices can change hourly, Browsenode values change without notice, and product availability is volatile. For these reasons, we recommend that you not cache product data.

It is illegal to cache customer information derived from Amazon.

What you can cache that enhances performance is identifiers, such as CartId, HMAC, and the PurchaseURL.

Use the Correct AWSAccessKeyId

To become an Amazon Product Advertising API developer, you must register with Product Advertising API at https://affiliate-program.amazon.com/gp/flex/advertising/api/sign-in.html. Each account contains an AWSAccessKeyId and a SecretKey. Every Amazon Product Advertising API request you submit must include an AWSAccessKeyId and a Signature generated from your SecretKey. It is important that you register with the same email address used by your Associate Account, so that your call volume limits are correctly set by your affiliate sales.

Read the Amazon Product Advertising API Terms and Conditions

The Amazon Product Advertising API Terms and Conditions spell out in detail the limitations that Amazon enforces on all Amazon Product Advertising API applications. The Amazon Product Advertising API is a free web service. Use restrictions are enforced to ensure that all developer applications benefit equally from the Amazon Product Advertising API. Before starting, make sure your proposed Amazon Product Advertising API application falls within the guidelines of the Amazon Product Advertising API Terms and Conditions. For more information, go to https://affiliate-program.amazon.com/gp/advertising/api/detail/agreement.html.