Skip to main content

Hi, I would like to add a custom field in the profile of each customer that purchase.

For example, if he buys a top then categorize this customer with a custom field that says "top".

If he buys a legging, then categorize this customer with a custom field that classify as come from “legging” colecction. 

Same for sizes. If he buys a XS, then a custom field that categorize this customer with a custom field that says XS. 

I use shopify plus. 

@jorgehostalet - One approach is to use the “Update Profile Property Action” in a Flow.  It seems a bit unconventional, but you can have a Flow that doesn’t send any emails! 

Here’s how I would do it: 

Setup a Flow based on an “Ordered Product” event and then do a “Trigger Split” based on the Collection(s) of the product.  Then, for each “Collection” path, use the “Update Profile Property” action and set the Custom Profile Property to a specified field name and value. 

Here’s an example, where I check if the product is from the collection “Accessories” and set a profile property called “skin_tone” to “fair.”  Of course, you would use something like “legging” to “XS” etc.

 

You can continue to add additional Trigger Splits for each of your Collections and what field name and value you want to set. Notice, this Flow does NOT send any emails! 

Hope this helps!

 

Here’s some additional Klaviyo Documentation that might be helpful!

How to Add an Update Profile Property Action to a Flow


Okey it works but for size I think is different. How can I set up a trigger split like: If he has purchased an item with size XS, create property: Size - XS

Can you help me with that?

 

 


@jorgehostalet - You can create another “Utility Flow” like the one above except that it splits based on the variant of the Size field instead of the “Collection” like my example above.


What if I’d like to create a user profile attribute that is an array

Use case a person can buy a shirt from multiple teams and I’d like to have an array that is just “purchased teams”

 

"Purchased": c

"Auburn",

"Alabama",

"Texas"

]

But I want to add a new team if they purchase a new team, not just a single value.

I know i could do a value for each team like hasPurchasedTexas=true
but there are over 200 teams, and thats a lot of extra attributes to add to a rpofile

Seems like an array I could update would be much more useful in that I could do show/hides based on a contains or something


Hey @tbjconsulting,

You can achieve what you described simply by using the Update Existing Property option when setting up the update profile property flow step. 

In case you missed it in our How to add an update profile property action to a flow Help Center article:

  • Update Existing Property
    This option allows you to update the value of an existing custom property. If the property you select is a list of values, you can choose to add or remove a value from the list. If the property doesn’t yet exist for a recipient profile, the property will first be created and then the value will be updated.
    Klaviyo automatically detects and validates the data type of the property you choose. For example, if you have a property like "Age" and all the existing values are numbers, then you try to update the value to "tom" we'll display an error because "tom" is not a number.

The key here is to ensure that the property you’re updating is a list data type. Else, the data type will be understood as text type which would override the existing property. 

David


Reply