2

We are using the new Behavioral triggers block and we are having an issue...

Most of the time, the product is showing twice. It appears to be showing the Master and Variant from the catalog. But I only need the Variant. I don't see a way of editing the block either. I'd be happy to create my own via AmpScript, but I am unsure how to convert the data column in the Abandoned Cart data extension to something I can use. Here's what it looks like:

enter image description here

I even tried taking the SSJS from the code and editing that. I didn't have much luck there either...

Has anyone had this issue?

Update: I was able to modify the code and add an if statement to limit this to just the IsVariant products. But I'd still much rather get to the root of this problem and use the out of the box block.

Update2: All of this is done by commerce cloud so I don't think it's the mismatch, although I haven't checked.

I do notice that I have master products and variants and the master is shared. Could that be an issue? See this screenshot.Product Codes

I've added an example of the trackCart code for the product show below:

{"cart":[{"item":"a056g00000URaMoAAL","unique_id":"a046g00000PI0u9AAD","name":"Developing a Leading Edge Operations Strategy","url":"https://production-na01-mitsloanschoolexeced.demandware.net/s/MSEE/course/developing-a-leading-edge-operations-strategy/a046g00000PI0u9AAD.html","price":3900,"sale_price":3900,"item_type":"product"}],"url":"https://production-na01-mitsloanschoolexeced.demandware.net/s/MSEE/course/developing-a-leading-edge-operations-strategy/a056g00000URaMoAAL.html","user_info":{"email":"abXaUub0FMgVhW3HhHLDqkAvwz"}}

If it helps, I'll add that I am also getting a red ampscript/ssjs error when previewing if I add the ProductCode to the display.

1
  • 1
    I believe your issue is a Skuid(uniqueid) and Productcode(item) mismatch in your cart call
    – EazyE
    Mar 18, 2021 at 21:23

1 Answer 1

1

I replicated this behavior and my comment was correct.

Example cart call:

{"cart":[
        {"item":"ABCDEF","unique_id":"12345","quantity":"1","price":"3.59"}
        ],
   "url":"https://www.buymystuff.com/shopping-cart", 
   "user_info":("email":"shopperid1"}
}

The values for item and unique_id should match exactly to ProductCode and SkuID in your catalog. When these match exactly you get one item, when the unique_id matches a different item you get two items. One for the matching master product of item and one for the matching unique_id

To resolve the issue update your cart call to pass the correct values that are in your catalog. Or update your catalog

EDIT: I believe you could also simply update your cart call to pass only unique_id

9
  • This is amazing. Let me make this update and see if it solves my issue. If so I'll mark it as correct! Mar 19, 2021 at 16:48
  • @garek007 did it resolve your issue?
    – EazyE
    Mar 22, 2021 at 13:41
  • so I have no SkuID in my catalog, could that be an issue? I believe unique_id and item should match. This is all commerce cloud, and that system also delivers the catalog, so I can't imagine they got it wrong. I am wondering if it has to do with having the product multiple times. I'm going to update my post with a screenshot Mar 22, 2021 at 18:02
  • It's odd, when I add ProductCode to my output to try to troubleshoot, I'm getting an ampscript error. Mar 22, 2021 at 19:51
  • @garek007 When I talk about catalog I mean reporting >> admin tools >> product catalog not your flat file. Every item has a skuid and its the value you pass as unique_id in the call
    – EazyE
    Mar 22, 2021 at 19:53

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .