Amazon Web Service ItemSearch DetailPageURL's with Associate IDs?
-
06-07-2019 - |
Question
DetailPageURL's returned by ItemSearch seem to include an incorrect ID/tag rather than the associate ID I requested the search with.
I'm getting:
When I expect:
How do I get the correct tag? (Note that SO rewrites the above links to their own Associate ID if you click either of the above)
I'm using Python and PyAWS 0.3.0, although I think the problem is with my request, rather than with the API wrapper.
(As an aside, The Amazon Associates Link Checker (U.K. store)/U.S. store is invaluable in testing these links)
Solution
Simple error in the end..... I was including the tag in the initial search:
for searchResult in ecs.ItemSearch(item, SearchIndex=index, AssociateTag='wwwmydomain-12')
But not in the secondary loop that steps through each result getting more details:
for item in ecs.ItemSearch(searchResult.ASIN, ResponseGroup='Medium'):
should be:
for item in ecs.ItemSearch(searchResult.ASIN, ResponseGroup='Medium', AssociateTag='wwwodbodycom-21'):
The tag is needed in both - it seems it's not carried over.