keepa
keepa copied to clipboard
api.search_for_categories()
I want to get "category numbers" for the Main Categories Like Home&Kitchen etc (Categories with most sales) but I don't know how to use this function as it takes "search word" and returns subcategories.
print(Initializing Keepa API\n')
api = keepa.Keepa(mykey)
categories = api.search_for_categories()
print(categories)
If I understand you right, I think you're looking for something like:
Query for the best sellers among the ``"movies"`` category.
>>> import keepa
>>> key = '<REAL_KEEPA_KEY>'
>>> api = keepa.Keepa(key)
>>> categories = api.search_for_categories("movies")
>>> category = list(categories.items())[0][0]
>>> asins = api.best_sellers_query(category)
>>> asins
['B0BF3P5XZS',
'B08JQN5VDT',
'B09SP8JPPK',
'0999296345',
'B07HPG684T',
'1984825577',
...