Solved

New segment from "Placed order event" with case "where [items] contains"....

  • 29 November 2023
  • 5 replies
  • 91 views

Badge +2

Hello,

I have just made custom integration and imported web shop orders to klaviyo profiles and they are visible in profiles activity feed:
 

 

When creating new segment when someone has “Placed order” i get no autocomplete-options if i select where “Items”. All other cases(brands, categories….) works fine and offer some options.

I’m new to klaviyo and I’m not sure what should even appear here? Is everything ok or am I missing something?

I would appreciate any help.

Thanks

icon

Best answer by saulblum 29 November 2023, 15:19

View original

5 replies

Badge +2

EDIT: I have found some other options/conditions are not up to date. I was importing and deleting profiles with history events a lot. It looks like segmentation options/conditions are still cached and showing old data. How long does it take for conditions to update from imported events?

Userlevel 5
Badge +7

Hi! It’s because Items is an array of JSON objects, vs. an array if strings, like Categories and Item Names. You can see in the example event body in the integration guide — https://developers.klaviyo.com/en/docs/guide_to_integrating_a_platform_without_a_pre_built_klaviyo_integration#placed-order — that you can have top-level string arrays of any order values you want, and you can then segment on those top-level properties.

Badge +2

  

Hi! It’s because Items is an array of JSON objects, vs. an array if strings, like Categories and Item Names. You can see in the example event body in the integration guide — https://developers.klaviyo.com/en/docs/guide_to_integrating_a_platform_without_a_pre_built_klaviyo_integration#placed-order — that you can have top-level string arrays of any order values you want, and you can then segment on those top-level properties.

 

Hi!

I noticed the difference between “array of objects” vs “array of strings”. I included “Items” as array of objects in my API call because it is documented in example in the link you’ve sent me. I thought I could use that data somehow. I’m a bit confused what is its use then? 

How often do segmentation options/conditions update from recorded events?

thank you!

Userlevel 5
Badge +7

You could loop through the Items array in an email and pull out properties such as productID and SKU (and do catalog lookups too with those properties, to, say, include thumbnails).

Badge +2

You could loop through the Items array in an email and pull out properties such as productID and SKU (and do catalog lookups too with those properties, to, say, include thumbnails).

Thank you Saul.

The more I work with Klaviyo the more i love it :)

Reply