Solved

Can Klaviyo scrape for keywords in Customer's Message Cards on Shopify

  • 21 February 2023
  • 6 replies
  • 99 views

Badge +2

Context: I have a gifting business with customers who purchase gifts for special occasions. I would like to send occasion reminder emails to customers who have bought gifts and attached a message card with specific keywords, i.e. Birthday, Anniversary, etc

 

Example: John buys a birthday gift on 31st March 2020 and attaches a message card with the words “Happy Birthday”. Can I have Klaviyo scrape all orders with message card that has keyword: “Birthday” and send them a reminder email to repurchase another birthday gift the following year. So John would then receive the reminder email sometime before 31st March 2021.

 

I know how to use Date Property-Triggered Flows to enable the scheduling and have it recur every year. However, am I able to only send to orders who’s message card contains keywords “ Birthday” / “Anniversary” / etc.

icon

Best answer by alex.hong 24 February 2023, 21:44

View original

6 replies

Userlevel 7
Badge +36

Hi @Francisco Johannes Yung and welcome to the Community!

 

This is a cool idea! It’s potentially possible, but in order to do it, you would likely have to create a custom Placed Order metric that includes an additional string property containing the message. Then, you could use a flow that’s triggered by the Placed Order event, and a trigger filter to find messages that contain “birthday”. Here’s the format for the suggested Placed Order metric:

If you check under the “properties” header in that Placed Order metric, you’ll see the following fields, like Brands, Categories, ProductNames:

"properties": {
"OrderId": "1234567890",
"Categories": ["Fiction", "Classics", "Children"],
"ItemNames": ["Winnie the Pooh", "A Tale of Two Cities"],
"Brands": ["Kids Books", "Harcourt Classics"],
"DiscountCode": "Free Shipping",
"DiscountValue": 5,
"Items": [{
"ProductID": "1111",
"SKU": "WINNIEPOOH",
"ProductName": "Winnie the Pooh",
"Quantity": 1,
"ItemPrice": 9.99,
"RowTotal": 9.99,
"ProductURL": "http://www.example.com/path/to/product",
"ImageURL": "http://www.example.com/path/to/product/image.png",
"Categories": ["Fiction", "Children"],
"Brand": "Kids Books"
},

 

If you include an additional field that passes in the message from the order (“Message”: “Happy Birthday”), you could be able to then filter a flow by this property:

  1. Create flow from scratch
  2. Trigger with custom Placed Order metric:

 

 

 

 

 

 

 

 

 

 

 

 

  1. Add a Trigger Filter that specifies the new property and includes the “contains” birthday logic (replace “Dimension” with Message property name):

 

 

 

 

 

 

 

 

 

  1. Finally, pull in an “Update Profile Property” block to add the Birthday date to the flow recipient’s profiles (make sure to check the “Use current date...” box):
     

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Now, the date will be added to the profile under a new “Birthday” profile, which you can use later to set reminder flows. I understand that this task may involve some extensive development, so you can always reach out to one of our Official Klaviyo Partners for further help.

 

Thanks for using the Community!

- Brian

Badge +2

Hi @Francisco Johannes Yung and welcome to the Community!

 

This is a cool idea! It’s potentially possible, but in order to do it, you would likely have to create a custom Placed Order metric that includes an additional string property containing the message. Then, you could use a flow that’s triggered by the Placed Order event, and a trigger filter to find messages that contain “birthday”. Here’s the format for the suggested Placed Order metric:

If you check under the “properties” header in that Placed Order metric, you’ll see the following fields, like Brands, Categories, ProductNames:

"properties": {
"OrderId": "1234567890",
"Categories": ["Fiction", "Classics", "Children"],
"ItemNames": ["Winnie the Pooh", "A Tale of Two Cities"],
"Brands": ["Kids Books", "Harcourt Classics"],
"DiscountCode": "Free Shipping",
"DiscountValue": 5,
"Items": [{
"ProductID": "1111",
"SKU": "WINNIEPOOH",
"ProductName": "Winnie the Pooh",
"Quantity": 1,
"ItemPrice": 9.99,
"RowTotal": 9.99,
"ProductURL": "http://www.example.com/path/to/product",
"ImageURL": "http://www.example.com/path/to/product/image.png",
"Categories": ["Fiction", "Children"],
"Brand": "Kids Books"
},

 

If you include an additional field that passes in the message from the order (“Message”: “Happy Birthday”), you could be able to then filter a flow by this property:

 

 

Hey Brian, 

Thanks for getting back to me! Hmmm I see the approach you’re trying, I used a similar methos to create first purchase anniversaries for my customers as well. Thanks for the tip! However, I can foresee that I will have issues the moment customers start buying birthday gifts for multiple different people and dates. This is something that I need to figure out how to work around. 

 

I do have a question regarding your first step: “you would likely have to create a custom Placed Order metric that includes an additional string property containing the message.”

Could you provide more instruction on this step? I’m not sure how to create a new place order metric that includes an additional string properties. 

 

Also not sure where is this “properties” for the place order metric mentioned here: “If you check under the “properties” header in that Placed Order metric, you’ll see the following fields, like Brands, Categories, ProductNames:”.

 

So sorry to trouble you for more info. Your help is greatly appreciated! :)

Badge +2

Hey Brian, 

Not too sure if this is what you were talking about in the first step (what I asked about in the last reply.) However, I’ve found something on my user’s Placed Order Activity Details. In this screenshot, I can find the order note (labelled “note”)  in the Activity Details, under the “extra” section. 

 

 

Seeing as this data is already in Klaviyo’s system, do I still need to do the first step you mentioned above? Oddly, I’m not able to find this property anywhere else and am not able to use it in flows as yet.

Is there any way that I can make that user property/info usable, so I can filter through it for the specific keywords?

Userlevel 7
Badge +58

Hi @Francisco Johannes Yung 

Unfortunately it's not possible to refer to this event property within a Trigger filter, as it is nested too deep within the event. 
An option would be instead to create a custom property that can be synced to the profile to use in this use-case, to help filter your profiles in the flow. 

Again, I would refer to the resource shared regarding creating a Placed Order metric and then tagging users as they place an order with a flow.

 

Badge +2

Hey @alex.hong 

Thanks for answering my question! Noted on that :( 

 

Could you provide more instruction on creating a custom Placed Order metric? I know how to use a flow to tag customers, but am unsure how to create this custom metric.

 

This is the section I’m not clear about: @Brian Turcotte 

you would likely have to create a custom Placed Order metric that includes an additional string property containing the message. Then, you could use a flow that’s triggered by the Placed Order event, and a trigger filter to find messages that contain “birthday”. Here’s the format for the suggested Placed Order metric:

If you check under the “properties” header in that Placed Order metric, you’ll see the following fields, like Brands, Categories, ProductNames:

"properties": {
"OrderId": "1234567890",
"Categories": ["Fiction", "Classics", "Children"],
"ItemNames": ["Winnie the Pooh", "A Tale of Two Cities"],
"Brands": ["Kids Books", "Harcourt Classics"],
"DiscountCode": "Free Shipping",
"DiscountValue": 5,
"Items": [{
"ProductID": "1111",
"SKU": "WINNIEPOOH",
"ProductName": "Winnie the Pooh",
"Quantity": 1,
"ItemPrice": 9.99,
"RowTotal": 9.99,
"ProductURL": "http://www.example.com/path/to/product",
"ImageURL": "http://www.example.com/path/to/product/image.png",
"Categories": ["Fiction", "Children"],
"Brand": "Kids Books"
},

 

If you include an additional field that passes in the message from the order (“Message”: “Happy Birthday”), you could be able to then filter a flow by this property:

Userlevel 7
Badge +58

@Francisco Johannes Yung ,

Custom metrics setup is entirely up to your developer team on what the feasibility is and how exactly the setup should work.

Tracking people and the events or actions they perform on your store is possible by building custom events using Klaviyo’s open APIs. You can get familiar with the basics of working with our APIs here: https://help.klaviyo.com/hc/en-us/articles/360045726811-Getting-Started-with-Klaviyo-APIs

We have both Javascript and server-side endpoints for our Track API (for sending events) and Identify API (for creating and updating profile properties). Here is some more specific information about our APIs that can be used to build out such events:
 


To learn more about this, I would suggest taking a look at the following API documentation:
 


If your team does not have a developer, I would highly suggest reaching out to one of our partner team who can better help set up tailored custom metrics: https://klaviyo.partnerpage.io/ 

Reply