The problem is in this line:
itemSearch = self.api.item_search(*args, **params)
Apparently, the item_search
function requires a positional argument first. Positional arguments are filled from args
but args
is an empty list as you call the itemsearch
function only with a unpacked dictionary:
amazonsearch.itemsearch(**params)
So you need to provide at least that first parameter too (like in your commented-out example: 'Books'
).