Closed brycemolder closed 7 years ago
The Product Advertising API is available in the following locales:
Locale URL
Brazil
http://webservices.amazon.com.br
Canada
http://webservices.amazon.ca
China
http://webservices.amazon.cn
France
http://webservices.amazon.fr
Germany http://webservices.amazon.de
India
http://webservices.amazon.in/
Italy
http://webservices.amazon.it
Japan
http://webservices.amazon.co.jp
Mexico
http://webservices.amazon.com.mx
Spain
http://webservices.amazon.es
United Kingdom
http://webservices.amazon.co.uk/
United States
http://webservices.amazon.com
So this would probably work:
client.itemLookup({
browseNodeId: '549726',
responseGroup: 'NewReleases',
domain: 'webservices.amazon.com.mx'
}, function (err, results) {
if (err) {
console.log(err);
} else {
console.log(results);
}
Hi @brycemolder @adamrogas
I am working on similar lines.. can you guys confirm if this worked?
Update : I tried and it worked. domain: "required domain"
Hi, I tried this code and I get : [ { Error: [ [Object], [Object] ] } ] `client.itemLookup({
browseNodeId: '549726', responseGroup: 'NewReleases', domain: 'webservices.amazon.com.mx'
}, function (err, results) { if (err) { console.log(err); } else { console.log(results); } });`
Can you explain me how to do this ?
Hi there,
To use a different endpoint in your request, you need the choose it from the Endpoints list. Then pass the domain of the endpoint in the domain params of your query.
Example:
I want to query the Canadian store 🇨🇦 . The endpoint is https://webservices.amazon.ca/onca/xml. The domain of the endpoint is webservices.amazon.ca.
var query = {
artist: 'Radiohead',
searchIndex: 'Music',
sort: 'relevancerank',
itemPage: 1,
availability: 'Available',
responseGroup: 'OfferFull,Large,Images',
domain: 'webservices.amazon.ca'
};
client.itemSearch(query, function (error, results) {
if (error) {
console.log(error);
} else {
console.log(results);
}
})
Note: when you use a different locales, the available params values change. Checkout the doc.
@jaribu maybe the error is not a domain problem. Can you log the error message?
I didn't see instructions on how to set the Locale. Can I do: