Is there a way to use Direct Call in custom code, e.g. _satellite function?
Hi,
Looking for the best way to set a dynamic data element using setVar right before triggering Direct Call. Can this be done? Is there a better way to do it?
Tx,
Hans
Hi,
Looking for the best way to set a dynamic data element using setVar right before triggering Direct Call. Can this be done? Is there a better way to do it?
Tx,
Hans
Hi Hans,
You may not have heard, but _satellite.track is much improved in Launch (compared to DTM).
The first big improvement is that you can trigger a rule with a call to _satellite.track AND add any additional conditions. In DTM, you could not pair conditions with a direct call rule.
The second big improvement (and the one that will help answer your question) is the ability to pass a JSON object on the call!
_satellite.track('contact_submit', { name: 'John Doe' });
https://docs.adobelaunch.com/client-side-information/launch-object-reference
This allows you to pass any bits of context into the rule and you are guaranteed that they will be there for you in the rule's conditions and actions.
So...
Let's say that you want to grab 'name', and use it in an Adobe Analytics Set Variables action in the same rule.
If you've called _satellite.track as shown above, you can dip into the payload using data element syntax like so:
%event.detail.name%
You can use this syntax in any Launch UI field that is expecting a string or data element reference.
If you want to get at the value from within a custom condition, AA custom code, or 3rd party JS, you can reference it directly as event.detail.name.
Hope that this helps.
-Stew
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.