One of our business requirements is to know which product is in which partition in each of our adgroups every day.
My current implementation "v1.0" of the service I have written works well. It works by getting all partitions for an adgroup via the API and building the partition tree for the adgroup. It then downloads the feed we sent and traverses the tree for each product in the feed to figure out where it lives.
The limitations here are obvious: we can only map the current set of products in the feed, and only for the current partition tree.
My thoughts on a second iteration of this service would allow us to figure out this mapping for every day, including in the past. It seems like it should work, but I have a few questions. The v2.0 goes as follows:
1. Get ALL partitions for an adgroup (including removed partitions, as they may be used on previous dates but non-existent in current partition tree)
2. Download PartitionPerformance report for a given date and use it to build the partition tree with parent criterion ID field
3. Since PartitionPerformance doesn't give us dimension type and value, we match up partitions from the second step to the partitions from the API in step 1.
4. Download ShoppingPerformance report and use each product record in that report to traverse the tree and figure out where the product lives.
Question 1: am I guaranteed to get every partition from all time for an adgroup by requesting enabled and removed partitions? Will every partition from the adgroup be available from the API even if we restructure our adgroup?
Question 2: will all partitions be in the PartitionPerformance report and will all products be in the ShoppingPerformance report?
Can you see anything that would be wrong/missing in the second iteration of this service? I plan on open sourcing it when it's stable :)
Thanks!