-
Notifications
You must be signed in to change notification settings - Fork 752
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Processing PRODUCT_TYPE_DEFINITIONS_CHANGE notification #4526
Comments
Hi @franclin, In the current design, once receiving the notification, developers need to fetch the product types they are interested in for the previous and new versions, and then do comparison to know the difference. (To know what the previous productTypeVersion version was, you would have to cache the old version somewhere). The ProductTypeVersion field is not unique to a given productType or the combination of the product type and the marketplace ID. Instead, the ProductTypeVersion field represents the version of the overall product type definitions across all product types and marketplaces. Alternatively, developers can utilize the monthly announcements such as this one to find major attribute and enum value updates. Thanks |
Hi @weilinggu Thanks for your reply. Still doesn't add up. When I run a getDefinitionsProductType operation I am seeing that they're 1810 product types currently available in the US marketplace. The reported product type version is: UAAAAAAAAAAAAAAAAlYD0uo679ELJJNiIgbSk98l7i3E= When I requested the latest product types for 3 random product types (PRODUCT, WIG, and HOME), the reported product type is: UAAAAAAAAAAAAAAAAlYD0uo679ELJJNiIgbSk98l7i3E= So it isn't clear to me which product types have UAAAAAAAAAAAAAAAAlYD0uo679EOIHE4wCD-2JHWu45Q= as the product type version. Thanks for shedding some light into this issue. Regards, |
The ProductTypeVersion field represents the version of the overall product type definitions across ALL product types and marketplaces. By the time you call the product type definition with LATEST, For example, you can use In addition, you can take a look at John's response in this issue to get a better understanding of how version strings are released. Alternatively, monthly announcements such as this one could be a good way to find major attribute and enum value updates. Thanks |
Thanks for your reply @weilinggu I ran the getDefinitionsProductType operation straight after receiving the notification. I thought the whole point of the notification was to inform us about the latest version of the product type version. So if I understand correctly it means that we really shouldn't rely on the product type version reported in the notification and that we're not guaranteed to receive a notification if there is an updated product type available. In this case, it would mean that there is no guarantee that there will be a notification reporting UAAAAAAAAAAAAAAAAlYD0uo679ELJJNiIgbSk98l7i3E= as the version. So whenever we receive the PRODUCT_TYPE_DEFINITIONS_CHANGE notification, we should just manually check all the product types available (which at the moment there're 1810 of them available in the US marketplace) Also you mentioned about the monthly announcements, is it possible to leverage those programmatically? Seems to me like it will be a manual process. Does it make sense? Thanks, |
I received a PRODUCT_TYPE_DEFINITIONS_CHANGE notification which looks like the example 2 in the documentation (https://developer-docs.amazon.com/sp-api/docs/notification-type-values#product_type_definitions_change)
How do I know which product type has just been updated? Knowing the new ProductTypeVersion surely wouldn't be of great help if I can't relate it to an actual product type. This has also been raised #4172 but no reply was given.
Here is the body of the notification just in case:
Also is the ProductTypeVersion field unique to a given productType or the combination of the producttype and the marketplace ID?
Thanks
The text was updated successfully, but these errors were encountered: