我正在使用https://github.com/yoavaviram/python-amazon-simple-product-api。 每次返回的项目数为50,即使我使用了search_n(100,...)。谁知道为什么?在哪里设置最大数量?感谢
amazon = AmazonAPI('key',
'key2',
'key3',
MaxQPS=0.9,
Region='US')
try:
products = amazon.search_n(100, Keywords='drone', SearchIndex='All')
for i, product in enumerate(products):
print_statement
except Exception as e:
print "Exception while searching Amazon:"+str(e)
答案 0 :(得分:1)
亚马逊documentation关于ItemPage参数:
有效值:1到10(搜索索引为全部时为1到5)
答案 1 :(得分:0)
我面临同样的问题,似乎是因为亚马逊将页数限制为10.因此,您最多可以获得100个产品。您可以尝试优化搜索范围,然后缩小搜索范围并获得更多您真正感兴趣的产品。
您在那里进行的搜索过于宽泛。尝试将其更改为:
products = amazon.search(Keywords='Drone', Title='Drone', SearchIndex='Electronics')
希望这会有所帮助......
答案 2 :(得分:0)
您可以找到返回页面的最大数量here ItemLookup操作的最大页数为150,而ItemSearch的最大页数为10页。