You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Jan 4, 2025. It is now read-only.
Hello i tried lots of things but i couldnt manage to reach attributes :( i'm trying with this code;
from mws import mws
access_key = 'xxxxx'#replace with your access key
seller_id = 'xxxxx'#replace with your seller id
secret_key = 'xxxxxx'#replace with your secret key
marketplace_usa = 'ATVPDKIKX0DER'
products_api = mws.Products(access_key, secret_key, seller_id, region='US')
products = products_api.get_product_categories_for_asin(marketplaceid=marketplace_usa, asin='B086DPR1G2')
print(products.parsed)
for self_category in products.parsed:
print(self_category.ProductCategoryId, self_category.ProductCategoryName)
product.parsed return "{'Self': {'ProductCategoryId': {'value': '3422301'}, 'ProductCategoryName': {'value': 'Mats'}, 'Parent': {'ProductCategoryId': {'value': '3422251'}, 'ProductCategoryName': {'value': 'Yoga'}, 'Parent': {'ProductCategoryId': {'value': '3407731'}, 'ProductCategoryName': {'value': 'Exercise & Fitness'}, 'Parent': {'ProductCategoryId': {'value': '10971181011'}, 'ProductCategoryName': {'value': 'Sports & Fitness'}, 'Parent': {'ProductCategoryId': {'value': '3375301'}, 'ProductCategoryName': {'value': 'Categories'}, 'Parent': {'ProductCategoryId': {'value': '3375251'}, 'ProductCategoryName': {'value': 'Sports & Outdoors'}}}}}}}}" it has ProductCategoryId but it still give me error AttributeError: 'str' object has no attribute 'ProductCategoryId'