سؤال

I've been using this code:

defined('AWS_API_KEY') or define('AWS_API_KEY', 'AGGAVZCVASDG123A');
defined('AWS_API_SECRET_KEY') or define('AWS_API_SECRET_KEY', '132131235151asdfaGFfasdf');
defined('AWS_ASSOCIATE_TAG') or define('AWS_ASSOCIATE_TAG', 'test05-12');
$amazonEcs = new AmazonECS(AWS_API_KEY, AWS_API_SECRET_KEY, 'com', AWS_ASSOCIATE_TAG);
$amazonEcs->associateTag(AWS_ASSOCIATE_TAG);
$amazonEcs->returnType(AmazonECS::RETURN_TYPE_ARRAY);

$response = $amazonEcs->responseGroup('TopSellers')->browseNodeLookup($node);

Unfortunately this code does not return the product's Price, Images and other attributes. It only returns this result:

<TopItemSet>
   <Type>TopSellers</Type>
   <TopItem>
            <ASIN>0553576399</ASIN>
            <Title>Distraction</Title>
            <ProductGroup>Book</ProductGroup>
            <Author>Bruce Sterling</Author>
       </TopItem>
       <TopItem>
        ....
       .....
</TopItemSet>

Is there a way I can show those when calling the TopSellers response group?

I have a solution before that everytime I call TopSellers, I get the ASIN of the items that the TopSellers produced(they produced 10 top seller items), then I use this code:

$response = $amazonEcs->responseGroup('Images,ItemAttributes')->page(1)->category('All')->search($asin);

That would do a searching of the product that is based on the ASIN that the TopSeller response group produced. The only problem with this code is that it will cause a throttled error. Throttled Error means the my request limit on amazon api have exceeded, because obviously that code is kinda exhausting to call because it keeps on requesting data from API.

I've been reading the docs of Product Advertising API here http://docs.aws.amazon.com/AWSECommerceService/latest/DG/RG_TopSellers.html

Your thoughts will be greatly appreciated!

هل كانت مفيدة؟

المحلول

I already have an answer on my own question:

It can be found here: https://forums.aws.amazon.com/thread.jspa?messageID=435522&#435522

Thanks! :)

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top