How to have visitor badge unassign X days after originally assigned

Michael_Kim_shc
Visitor
Michael_Kim_shc

I'm having trouble identifing a good way to unassign a badge after a number of days have passed since itw as first assigned.

ie. I assign the badge on monday, and I want it to get Unassigned after 5 days.  

I've tried:

- creating a Date attribute that gets set when the bade is assigned. then creating a rule for unassigning the badge when that date is > 5 days ago.

But that creates a cyclical logic error when saving the badge.  (bug fix?  i know it's somewhat cyclical, but i woulnd't expect it to cause issues).

 

My next try to to create duplicate badges.  create the date off of one badge, and then have the expiration apply to the 2nd badge.  I tihnk this should work - but it's a silly way to implement...

8 REPLIES 8

How to have visitor badge unassign X days after originally assigned

Tealium Employee

@Michael_Kim_shc

 

You'll probably need to reference a Timeline. You'll move the logic to assign the Badge to the Timeline, use a Number to count the number of entries in the Timeline, then assign a Badge if the Number is greater than or equal to 1.

 

You might want to add additional logic to the Timeline rule to only add an entry if the Metric equals 0. This all depends if you want to let the Badge be assigned if they've done something in the last 5 rolling days no matter how many times the rule was evaluated to true, or if they should only be in the audience for 5 days no matter what.

 

Hope this helps!

 

Cheers,

-Dan

How to have visitor badge unassign X days after originally assigned

Michael_Kim_shc
Visitor
Michael_Kim_shc

Hey @dan_george,

Thx for reply.  I've tried the timeline approach, but am still having isues with the expiration.  I'm trying to for the "can only be in the timeline once every 5 days".  

I have:

Timeline captuing valid behavior
Number capturing count of hits in timeline

Problem: when I try to make the number part of the rules in capturing events in the timeline, I get a cyclic logic error and am unable to save/publish.  

Any other options?

How to have visitor badge unassign X days after originally assigned

Tealium Employee

@Michael_Kim_shc just letting you know i'm looking into this

How to have visitor badge unassign X days after originally assigned

Michael_Kim_shc
Visitor
Michael_Kim_shc

To ping back on this thread - there is not an ability to currently do this cleanly in Audience stream.  

However, there are some hacks, below:

 

1. You can use AudineceSTream in conjunction with iQ.  

---> Create your audience in AS as normal, 

---> find in the enhanced datalayer in iQ the timestamp for when teh audience was entered.

--> chckin an JS extensionin iQ if the current date is X days after the audience join date.  if so, set a datalayer flag for AS to pick up as an event variable.

--- in AS, make a Remove Audience condition based around that flag.

 

2. (havent' tried this one, but it should work).  Use AudienceStream webhook connectors to create a GET request hitting your own AudienceStream implementation.

--> set up the conector to fire when a user enters an audience. and have the GET request send the tealium ID, as well as some kinda flag designating that the audience was entered.

--> set up a Date attribute that gets set to teh current date when the above flag is found.

--> set up removal from the audience when the current date is more than 5 days ( or X days) after the Date attribute you created.

 

Or, I suppose you could send the connector/Webhook action 5 day safter the audience is joined, and use the flag to remove the person from the audience as well.  

 

Hope this helps other people.. was a bit of a pain to figure outSmiley Happy

 

How to have visitor badge unassign X days after originally assigned

kathleen_jo
Employee Emeritus
kathleen_jo

@Michael_Kim_shc Excellent! Thank you for this ping back! Great stuff. 

Remember to give me a kudo if you like my post! Accepting my post as a solution is even better! Also remember that search is your friend.
Highlighted

How to have visitor badge unassign X days after originally assigned

Tealium Employee

@Michael_Kim_shc

 

I know it's been a little while since you asked, so sorry for the delay in responding

 

I believe the requirement is 
 
Assign badge when it first happens.
Remove 5 days later
If happens during the 5 days, ignore
If happens after the 5 days, start again (assign again)
 
Using the following pattern will do this.  We have tested this.
 
image (1).png
image (2).png

How to have visitor badge unassign X days after originally assigned

AndrewFenn
Occasional Contributor
AndrewFenn

@mark_reddin would this still work if no events come in for that particular visitor? My understanding is that the badge will remain assigned until an event for that visitor comes in. The problem being, if your visitor goes away and no more new events are coming in for them you still want the badge to be unassigned after X days.

.

How to have visitor badge unassign X days after originally assigned

Tealium Employee

@AndrewFenn You are correct.  The above requirement and pattern were for the case where the visitor is returning to the site or there is some other event (omnichannel or collect API) that "wakes up" the visitor profile and recalculates everything.

Depending on what you are doing, there are two things to consider;

1. A filter in Audience Sizing based on the Date you've stored in Visitor Profiles versus the date now will work correctly.  So you could use Sizing to find visitors whose Date is more than X days ago.

2. Delayed connectors may also suit what you are doing.