Skip to main content

Is this a thing? Why isn’t this a thing?

 

 

I have a flow triggered when a person purchases an item. That event has some info that I can use in variable tags in an email or notification. But I can’t use those variable tags to add the event info to the person’s custom properties. Would be useful to (in other flows) be able to filter out only people who purchase a specific product (i.e. they have that product in the ProductsPurchased custom property). I think this can be achieved by creating segments based on what products were purchased, but just storing a list as a custom property would be great too.

Hi @khag ,

Welcome to the Community.

Yes, this is possible using the Update Profile Property action within a Flow. You'll want to setup a metric-triggered Flow based on the event you want to trigger the property. In your example, that would be "Placed Order". You can add filters to specify product, and more.
 
Then, you'll add a Flow action of "Update Profile Property" and either choose an existing property to update to a specific value, or create a new property to update to a new value. Here's more information on how to set this up: How to Add an Update Profile Property Action to a Flow

Are you looking for a product specific flow? Or just to tag users who have purchased a specific product? In that case would having an (update profile property) inside a product specific flow not work for your idea. You can submit an array as a property, but not an array of objects.

 

 


Wouldn’t that require you to create a separate “update profile property” for every product?

 

I know how to update profile properties. I don’t know of any way to use the event data variables like you can do in emails. {{ event.variable }}


@khag ,

I understand you are trying to update a profile property with an event variable. Unfortunately, this is not possible within the {% update_property_link %} tag, as dynamic tags cannot be included within other dynamic tags.
 
As a workaround, though, you can include a Webhook within your Flow. A Webhook Flow Action enables the ability to send a POST request to our identify endpoint with dynamic event data. This means that a Flow triggered by Ordered Product could use a Webhook Flow Action to update a profile property in Klaviyo with the dynamic event variable (i.e. {{ event.ProductID }} ), which would then be stored as a profile property. A limitation of this is is that the value would get overwritten each time a profile triggers the Flow.
 
Check out these articles for more information on using Webhooks in Flows: Understanding Klaviyo Webhooks and How to Add a Webhook Action to a Flow.


Oh I love that idea! Yeah I could write a script to do that, easy. Didn’t even think of that. Trying to do everything within a klaviyo flow isn’t necessary, I can just use the API. Thanks.


Reply