{"id":503,"date":"2018-08-24T15:52:51","date_gmt":"2018-08-24T15:52:51","guid":{"rendered":"https:\/\/www.digitaldatatactics.com\/?p=503"},"modified":"2020-09-17T21:15:19","modified_gmt":"2020-09-17T21:15:19","slug":"cross-post-from-33-sticks-direct-call-rules-in-launch-have-a-new-power-passing-additional-info-in-_satellite-track","status":"publish","type":"post","link":"https:\/\/www.digitaldatatactics.com\/index.php\/2018\/08\/24\/cross-post-from-33-sticks-direct-call-rules-in-launch-have-a-new-power-passing-additional-info-in-_satellite-track\/","title":{"rendered":"Cross-post from 33 sticks: Direct Call Rules in Launch have a new power: passing additional info in _satellite.track"},"content":{"rendered":"<p><em>(FYI, this is a cross-post from <a href=\"https:\/\/33sticks.com\/direct-call-rules-launch-new-power-passing-additional-info-_satellite-track\/\">33 Sticks&#8217; blog<\/a>. )<\/em><\/p>\n<p>Adobe&#8217;s <a href=\"https:\/\/marketing.adobe.com\/resources\/help\/en_US\/dtm\/c_overview.html\" target=\"_blank\" rel=\"noopener noreferrer\">Dynamic Tag Manager<\/a> has always given developers a chance to define exactly when a rule was called, by firing <code>_satellite.track(\"insert rule name here\")<\/code>. This is called a Direct Call Rule (or DCR). They didn&#8217;t always get a ton of product love- after all, Event Based Rules don&#8217;t require work from developers and have so many more options- but <em>many<\/em> DTM users used them heavily because of the control they provided and how incredibly straightforward they were.<\/p>\n<p>From my view, they historically had a few major downsides:<\/p>\n<ol>\n<li>Multiple DCRs couldn&#8217;t &#8220;stack&#8221; to form a single Adobe Analytics beacon,\u00a0<span style=\"font-weight: 400;\">meaning you couldn\u2019t have one DCR set your global variables and another set more user-action-specific variables.<\/span><\/li>\n<li>You couldn&#8217;t apply additional conditions (e.g. &#8220;don&#8217;t fire on the page with this URL&#8221;)<\/li>\n<li>There was no good way to clear out your variables so they wouldn&#8217;t persist from beacon to beacon<\/li>\n<li>You couldn&#8217;t pass additional information specifically scoped for\u00a0Direct Call Rule.\u00a0<span style=\"font-weight: 400;\">For example, if you fired <code>_satellite.track(\u201cadd to cart\u201d)<\/code>, you had to make sure your overall data layer\/data elements were already set up properly to show WHICH product was added to cart.<\/span><\/li>\n<\/ol>\n<p>I&#8217;ve talked about how happy I am that Launch solved the first three\u00a0points (<a href=\"https:\/\/www.digitaldatatactics.com\/index.php\/2018\/01\/30\/dtm-launchs-rule-ordering-is-a-big-deal-for-single-page-apps\/\" target=\"_blank\" rel=\"noopener noreferrer\">here<\/a> and <a href=\"https:\/\/www.digitaldatatactics.com\/index.php\/2017\/11\/20\/adobe-dtm-launch-improvements-for-single-page-apps\/\" target=\"_blank\" rel=\"noopener noreferrer\">here<\/a>) but I&#8217;ve finally had a reason to try out how Launch handles #4.<\/p>\n<p><span style=\"font-weight: 400;\">You can now pass <\/span><a href=\"https:\/\/docs.adobelaunch.com\/client-side-information\/launch-object-reference\"><span style=\"font-weight: 400;\">extra parameters into your <code>_satellite.track<\/code> function<\/span><\/a><span style=\"font-weight: 400;\">, like this:<\/span><\/p>\n<pre>_satellite.track(\"add to cart\",{name:\"wug\",price:\"12.99\",color:\"red\"})<\/pre>\n<p><span style=\"font-weight: 400;\">Then, when you set up a rule that fires off that direct call:<\/span><\/p>\n<p><a href=\"https:\/\/www.digitaldatatactics.com\/wp\/wp-content\/uploads\/2018\/08\/DCRcondition.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-506\" src=\"https:\/\/www.digitaldatatactics.com\/wp\/wp-content\/uploads\/2018\/08\/DCRcondition.png\" alt=\"\" width=\"638\" height=\"349\" srcset=\"https:\/\/www.digitaldatatactics.com\/wp\/wp-content\/uploads\/2018\/08\/DCRcondition.png 638w, https:\/\/www.digitaldatatactics.com\/wp\/wp-content\/uploads\/2018\/08\/DCRcondition-300x164.png 300w\" sizes=\"(max-width: 638px) 100vw, 638px\" \/><\/a><\/p>\n<p>You can access the information on those parameters like you would access a data element, by referencing <code>%event.detail.<i><span style=\"font-weight: 400;\">yourObjectHere<\/span><\/i><span style=\"font-weight: 400;\">%:<\/span><\/code><\/p>\n<p><a href=\"https:\/\/www.digitaldatatactics.com\/wp\/wp-content\/uploads\/2018\/08\/interfaceAsDe.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-505\" src=\"https:\/\/www.digitaldatatactics.com\/wp\/wp-content\/uploads\/2018\/08\/interfaceAsDe.png\" alt=\"\" width=\"612\" height=\"78\" srcset=\"https:\/\/www.digitaldatatactics.com\/wp\/wp-content\/uploads\/2018\/08\/interfaceAsDe.png 612w, https:\/\/www.digitaldatatactics.com\/wp\/wp-content\/uploads\/2018\/08\/interfaceAsDe-300x38.png 300w, https:\/\/www.digitaldatatactics.com\/wp\/wp-content\/uploads\/2018\/08\/interfaceAsDe-604x78.png 604w\" sizes=\"(max-width: 612px) 100vw, 612px\" \/><\/a><\/p>\n<p><span style=\"font-weight: 400;\">Or, if needed, in your custom code for that rule by just accessing event.detail:<\/span><span style=\"font-weight: 400;\"><br \/>\n<\/span><\/p>\n<p><a href=\"https:\/\/www.digitaldatatactics.com\/wp\/wp-content\/uploads\/2018\/08\/customCodeAsObject.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-504\" src=\"https:\/\/www.digitaldatatactics.com\/wp\/wp-content\/uploads\/2018\/08\/customCodeAsObject.png\" alt=\"\" width=\"641\" height=\"111\" srcset=\"https:\/\/www.digitaldatatactics.com\/wp\/wp-content\/uploads\/2018\/08\/customCodeAsObject.png 641w, https:\/\/www.digitaldatatactics.com\/wp\/wp-content\/uploads\/2018\/08\/customCodeAsObject-300x52.png 300w\" sizes=\"(max-width: 641px) 100vw, 641px\" \/><\/a><\/p>\n<p><span style=\"font-weight: 400;\">You could even have a multi-leveled object:<\/span><\/p>\n<pre>_satellite.track(\"add to cart\",{product:{name:\"wug\",price:\"12.99\",color:\"red\"},location:\"cart recommendations\"})<\/pre>\n<p><span style=\"font-weight: 400;\">In which case you could reference %event.detail.product.name% or %event.detail.location%.<\/span><\/p>\n<p><span style=\"font-weight: 400;\">That\u2019s all there is to it! Go ahead, fire this off in your console, and see our rule at work:<\/span><\/p>\n<pre>_satellite.track(\"add to cart\",{name:\"wug\",price:\"12.99\",color:\"red\"})<\/pre>\n<p><span style=\"font-weight: 400;\">I\u2019ve seen this work in DTM recently, too, though I\u2019m under the impression that may not be fully supported, perhaps. Either way, this great enhancement can simplify data layers and Launch implementations and removes the need for a lot of previous workarounds.<\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>(FYI, this is a cross-post from 33 Sticks&#8217; blog. ) Adobe&#8217;s Dynamic Tag Manager has always given developers a chance to define exactly when a rule was called, by firing _satellite.track(&#8220;insert rule name here&#8221;). This is called a Direct Call Rule (or DCR). They didn&#8217;t always get a ton of product love- after all, Event &#8230; <a title=\"Cross-post from 33 sticks: Direct Call Rules in Launch have a new power: passing additional info in _satellite.track\" class=\"read-more\" href=\"https:\/\/www.digitaldatatactics.com\/index.php\/2018\/08\/24\/cross-post-from-33-sticks-direct-call-rules-in-launch-have-a-new-power-passing-additional-info-in-_satellite-track\/\" aria-label=\"Read more about Cross-post from 33 sticks: Direct Call Rules in Launch have a new power: passing additional info in _satellite.track\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[23],"tags":[57],"_links":{"self":[{"href":"https:\/\/www.digitaldatatactics.com\/index.php\/wp-json\/wp\/v2\/posts\/503"}],"collection":[{"href":"https:\/\/www.digitaldatatactics.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.digitaldatatactics.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.digitaldatatactics.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.digitaldatatactics.com\/index.php\/wp-json\/wp\/v2\/comments?post=503"}],"version-history":[{"count":4,"href":"https:\/\/www.digitaldatatactics.com\/index.php\/wp-json\/wp\/v2\/posts\/503\/revisions"}],"predecessor-version":[{"id":586,"href":"https:\/\/www.digitaldatatactics.com\/index.php\/wp-json\/wp\/v2\/posts\/503\/revisions\/586"}],"wp:attachment":[{"href":"https:\/\/www.digitaldatatactics.com\/index.php\/wp-json\/wp\/v2\/media?parent=503"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.digitaldatatactics.com\/index.php\/wp-json\/wp\/v2\/categories?post=503"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.digitaldatatactics.com\/index.php\/wp-json\/wp\/v2\/tags?post=503"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}