Skip to main content
Contributor IV
October 15, 2021
Solved

Empty Custom Properties issue and workaround

  • October 15, 2021
  • 2 replies
  • 762 views

In our specific situation we have some users who have sales reps and many who do not.

On our end we typical set the field’s value to an empty string.

A property with an empty string does not get stored on profiles in Klaviyo.

My proposed workaround was to use two properties with one being a hasRep flag if you will and the other being a rep name.

What I am curious about is, is there a way to set a property to either an empty or null value to avoid the dual property solution?

 

    This topic has been closed for replies.
    Best answer by Mailbox Manny

    I don’t believe it can be empty.  But, what about putting the rep name as “None” instead of the 2 property solution?

    2 replies

    Mailbox Manny
    Partner - Silver
    Partner - Silver
    October 16, 2021

    I don’t believe it can be empty.  But, what about putting the rep name as “None” instead of the 2 property solution?

    Subscribe. Segment. Send. Repeat.
    macAuthor
    Contributor IV
    October 18, 2021

    Thank you for the suggestion, we did discuss such a solution internally and decided we would rather have to deal with the clunkiness of a two part solution in our Klaviyo abstraction layer rather than rewrite our own established API.

    I figured empty was a no go when we tested and discovered keys with empty strings were dropped. I was hoping there was a mechanism we could leverage that was perhaps not well documented but known by a Klaviyo guru.

    Thank you for taking the time to propose a solution.