Expand my Community achievements bar.

Applications for the 2024 Adobe Target Community Mentorship Program are open! Click to the right to learn more about participating as either an Aspirant, to professionally level up with a new Certification, or as a Mentor, to share your Adobe Target expertise and inspire through your leadership! Submit your application today.
SOLVED

What is the most fastest way to update a users profile which includes mbox3rdPartyId?

Avatar

Level 3

I'd like to try updating user's profile attributes as way to use them in experience targeting  (hide/show different content if they've seen it in the past x-amount of days).  It seems there's always a undetermined delay.  I've tried using the Profile API directly and the trackEvent() function.

I'm using mbox3rdPartyId and then trying to fetch the profile by the mbox3rdPartyId.

This is also all happening client side in the browser.

 

Any recommendations?

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

You can write values into the UserProfile. These are then real time on the client side and in the calls with Adobe Target. Think that if you want to retrieve these values via the API - it's probably not real time (not sure about that). But if you write client-side in the profile - okay user has seen this and that - or should see the respective content at the next page load or request - then it works.

 

adobe.target.trackEvent({ mbox: 'sb113_track', params: { 'profile.sb113_viewed': 'true' } });

How Do I Use the adobe.target.trackEvent() Function?

 

Here you write the value sb113_viewed and write true as value. Of course you can write something completely different here. It is only important to know that the value is a string. But you can use this again to generate audiences in Adobe Target that meet the corresponding profile value.

View solution in original post

3 Replies

Avatar

Correct answer by
Community Advisor

You can write values into the UserProfile. These are then real time on the client side and in the calls with Adobe Target. Think that if you want to retrieve these values via the API - it's probably not real time (not sure about that). But if you write client-side in the profile - okay user has seen this and that - or should see the respective content at the next page load or request - then it works.

 

adobe.target.trackEvent({ mbox: 'sb113_track', params: { 'profile.sb113_viewed': 'true' } });

How Do I Use the adobe.target.trackEvent() Function?

 

Here you write the value sb113_viewed and write true as value. Of course you can write something completely different here. It is only important to know that the value is a string. But you can use this again to generate audiences in Adobe Target that meet the corresponding profile value.

Avatar

Level 3

@Perrin_Ennen do you know if only strings or other primitives are acceptable values?  I seem to get 400s if I try to pass json objects as the value of any profile parameter.

Avatar

Community Advisor

Hope I understand you correctly. If you pass values with adobe.target.trackEvent via params - these can also be numbers etc. - this is only rewritten as a string by target accordingly.

 

But you can rewrite it in the ProfileScript (if you use one) - again accordingly e.g. by Number() and compare.

 

if (page.domain == 'www.example.com' && mbox.name == 'target-global-mbox') {
var value = mbox.param('sb113_value');

	if (typeof value !== 'undefined' && value) {
	  return (Number(value) >= 100) ? true : false;
	}

	return false;
}