sc_events in a utag.link call

Rookie Contributor

I have to use a utag.link() call in a javascript extension for various reasons. I have to pass an event within the utag.link call as well but not sure how to do that given the necessity of using sc_events. If I pass it as "sc_events":"event125" then I get the usual events = "0,1,2,3,4,5,6" but there is no way to set the correct way of "sc_events":{"event125":"1"} like you are supposed to follow in a Set Data extension.




sc_events in a utag.link call

Tealium Employee

Unless you've modified anything, you should be able to just map a variable to send the event when the correct value is populated. For example, let's say I want to send "event125" when the "event_name" variable equals "cart_view". I would add a mapping to the Adobe tag to send "event125" when "event_name" equals "cart_view". The mapping would look like this when complete: "cart_view:event125". 

Once you have the mapping set up, you would ensure that your link event contains the variable with the correct value:


When this event sends, the mapping will then trigger the event and it will be added to sc_events.