HowTo – Programming Your Amazon Store Ap For Different Locals

Filed under: Site Management

amazon_logoAmazon has Six different servers to feed your xml and other data requests that you need for building your store and serving your customers.

The available locations are Canada, France, Germany, Japan, United Kingdom, United States.

Amazon also has a China Store but no information about affiliate programs has been released for that local … that we have seen.

The first thing you should understand is that you need an Affiliate ID for each of Amazons Locations if you expect to be paid for purchases.

You should also understand that allowing your visitors in say Japan to access your UK store will restrict delivery at time of purchase based on that affiliate stores shipping policy. UK only serves Ireland England and Scotland and although they may have the same or different products shipping outside of their service area is not allowed.

To understand Shipping Restrictions based on Local and Affiliate visit.
http://www.amazon.com/gp/help/customer/display.html?nodeId=468634

You will also need AWSAccessKeyIds to grab the feed from the xml Server.

Access IDs are required whether you are building a store to sell products or if you are designing an application that pulls data from their sever for other reasons. However if you are pulling info from Amazon and you are not also selling their products I have to expect they won’t be quite as quick to approve your application as they would if you were hosting a store frontend.  The reason Amazon is now requiring both a private and secret key is that too many people are sucking their database for access to their dvd covers and product info to build non sales generating sites.

Making the Local Decision Before You Start Coding

So, you have a decision to make will your ap support only one local or will it support all locals.

If you are thinking about developing an ap that would support all of the Amazon Stores then you will have to build in a way to allow your visitor to change the Local and have that setting persistent throughout their browsing and at the time of final purchase.

On the other hand you could build a Store Ap that has all of the information in it to support all of the locations and then at configuration time pick the Local that this individual store will support.

When writing your code

You will need to connect to each of the ECS Servers individually to pull back  data.

At the time of Writing the correct servers are

Locale Endpoint
CA http://ecs.amazonaws.ca/onca/xml

https://aws.amazonaws.ca/onca/xml

DE http://ecs.amazonaws.de/onca/xml

https://aws.amazonaws.de/onca/xml

FR http://ecs.amazonaws.fr/onca/xml

https://aws.amazonaws.fr/onca/xml

JP http://ecs.amazonaws.jp/onca/xml

https://aws.amazonaws.jp/onca/xml

UK http://ecs.amazonaws.co.uk/onca/xml

https://aws.amazonaws.co.uk/onca/xml

US http://ecs.amazonaws.com/onca/xml

https://aws.amazonaws.com/onca/xml

When you pull back the data you will need to format it for your visitor.

This means you need to get a list of possible xml containers and format the label of the data that is inside it to match your local stores language needs.

You will also need to translate things like sort lists for different browsenode categories like dvd books office products. Each search index will have its own way to sort products by price, release date, alphabetical and not all are available in each store category.

Basically you need to make sure you show the description titles to visitors in their language.

There are probably about 100 descriptors that you will need to handel and translate to each language that you want to support. google language tools are your friend here heheh.

An easy way to do this is load the different refference lists based on local.

if local = “us” … { include us-vars.inc
if local = “jp” … { include jp-vars.inc

You will find a method that suits you. Rhen when your exl response is returned convert the lables into human readable descriptors.

It is really best that you get the current list from Amazon and start compiling your directory of descriptors. It does not change that often but grabing it out of some sample code thats 5 years old just won’t cut it.

http://docs.amazonwebservices.com

Anyway those are your choices when you build an Amazon Store.

The best way seems to build in support for all the store locations and then set the local for a number of installs.

Most people will only want one location and that will be their own or possibly a site owner who lives in the UK that supports a store in the USA to sell to US customers.