Use doPlugins and implementation plug-ins in Experience Platform tags
Last update: February 1, 2024
- Topics:
- Tags
CREATED FOR:
- Beginner
- Developer
Learn about the benefits of using the doPlugins function, and add Analytics implementation plug-ins to enrich data collection. This video covers where to find the code, and where to add it in Experience Platforms tags. Review the documentation for doPlugins and Analytics implementation plug-ins for more details.
Transcript
In this video, I’ll review using the Do Plugins function along with implementation plugins using Experience Platform tags. This is what I’ll cover. I’ll start by explaining what the Do Plugins function and implementation plugins are used for. I’ll show you where to grab the code from documentation, where to add it in the analytics extension and tags, and finish with an example including testing the code on a website. The Do Plugins function is automatically called as part of every analytics call, whether for a page view, custom link, exit link, or download link. It’s the ideal place to set variables that you want to capture for all analytics hits, again regardless of type, as well as setting variables from implementation plugins. Now implementation plugins are code blocks that extend the capabilities of the analytics app measurement code. If you’ve worked with Adobe Consulting, chances are you’ve seen a few already. These plugins perform functions like getting the query string parameter value from a URL, formatting time values, appending a variable to a hit, and many more. In my browser, I’m displaying the documentation for implementation plugins. This is found in the analytics implementation guide. The left rail contains links to specific plugins, which I’ll be showing you more of coming up. I’ll start with Do Plugins because this is the starting point. Now to reiterate, this function runs right before the image beacon is sent to Adobe servers for any type of image request. This code isn’t automatically included in app measurement, so you do have to add it manually, and this is what we’re going to be doing next. I have a tags property open here. I’ll open the analytics extension configuration. Now I’ll open the custom code section further down, and I’ll have a look at the contents in the editor. To start with, I have a single line of code that outputs a log statement to the browser’s console. Now I’ll go to the Adobe website, and I’ll open the browser’s developer tools. I have debug statements turned on, and that’s done by typing in underscore satellite set debug true in parentheses, but I’ve already done that. I can see which rules are firing. The all pages rule right here fires for every page view. I also see the logger statement included in the custom code editor I just showed you. At the bottom of this page, there’s a link to Facebook in the footer. This opens Adobe’s Facebook page in another tab. This is considered an exit link. Now it doesn’t fire the all pages rule because it’s an exit link, and also it doesn’t fire the logger statement I added in my custom code in the analytics extension. Again, this is expected because we need to add the do plugins function plus any code we want to execute within it for all image request types, including links. All right, I’m going to go back to the documentation for do plugins, and I’m going to copy and paste the do plugins function from this page. It’s the block of code under sdo plugins in app measurement and custom code. There’s a copy command in the right corner. Now going back to tags, I’ll paste that code into the custom code editor in the analytics extension configuration. Okay, now there’s another variable I need to add above this function. It’s mentioned at the top of the documentation right here. If use plugins is enabled. I’ll click on the link and pop it open in a new tab. It explains right here that the variable needs to be enabled. This means I need to set that variable to true because it’s initialized to false by default. Now I’ll hit the copy link here. I’ll go back to tags, and I’ll paste it into the custom code editor right above the do plugins function. Now that my do plugins code shell is in place, I’ll talk about next steps. I want to set a variable on every image request. This is going to be for both page views and any sort of link. For demonstration, I’ll set prop four with the beacon type sent to Adobe servers. All right, so I already have that code that accomplishes that task, and I’m going to add it to the editor now. I’m going to put it within, of course, the do plugins function. And basically this logic sets prop four with the link type if the variable link type is not undefined. Otherwise it’s a page view beacon. Now this code alone won’t set prop four for link beacons. That’s because the variables you want to send with links must be included in the link track bars variable. So I need to use another block of code called an implementation plugin to append prop four to the request. All right, now let’s look at the help documentation for implementation plugins. In the left navigation area, you’ll see the plugins listed. I’m going to scroll up to the top to find the APL plugin, which is the one I’m going to be using for my example. This plugin allows you to add new listed limited variables like events, link track bars, and lists. There’s also a set of conditions for adding variables in the bulleted list. I’ll also mention that these plugins were created by Adobe Consulting and that customer care doesn’t provide support for these. So just be aware of that in case you need further help with them. Below it provides instructions for using the plugin in the Adobe Analytics extension and tags. This is what I’ll be showing you. And then further down there’s a section for copying the plugin code. Now back in tags, I’m going to copy this plugin to my code. I don’t want the plugin code to execute until it’s called. So notice that I’m putting it outside of and below the do plugins function. All right, so last I need to call the plugin. I’ll go back to the documentation to see how to do this. Now the arguments are listed below the plugin code. The first two are required. The LV argument is the variable that contains a delimited list of new values that you want to add. So in my case, it’s s.linktrapvars because that’s the one specific to link begins. Next, the VTA argument should pass the value or values you want to add to the value of the LV argument. And then the last three are optional, but I won’t be using any of these in my code. Further down below the arguments are examples for calling the function. Now coincidentally, I’m setting Prop4 in my example, but I’ll be using slightly different arguments than you see here. All right, now back to the custom code editor. I’m going to add the call to the APL plugin to my custom code, and then I’m going to save the code. Now I’ll save and build it to my current library. All right, now that my library is built, let’s get this code tested on the Adobe site. I’ll refresh the page and in the image beacon for the page view, here I see C4, which is Prop4 set to PV, which is what I’d expect. Now I’ll scroll down to the exit link for Facebook at the bottom. Looking at the beacon fire from that click, I see C4 set to E for exit link. And again, that’s what I’d expect. All right, let me go back to the code and review the logic again. Here I’m setting Prop4 to the link type if the beacon is in fact a link. Otherwise I’m setting Prop4 to PV, which is the only other type of beacon. And then last, in order to append the value of Prop4 to the link beacon, I’m calling the APL, which is Append to List, implementation plugin. The logic to set Prop4 is included in the do plugins function because I need it to execute for all analytics beacons. This concludes using the analytics do plugins function and implementation plugins and tags. You should now feel comfortable adding this code to the Adobe Analytics extension. Good luck.
Previous pageUse a data layer to set variables
Next pageConfigure easy download link tracking
Analytics
- Analytics tutorials
- Introduction to Analytics
- What is analytics
- What Can Adobe Analytics Do For Me?
- How Adobe Analysis Workspace Can Change Your Business
- It’s More Than Data. It’s Customer Intelligence
- Adobe Sensei and Adobe Analytics
- Customer Use Case - ServiceNow
- Customer Use Case - Accent Group
- Customer Use Case - The Home Depot
- Summit 2019 Super Session - Travel and Hospitality
- Summit 2019 Super Session - Retail
- Summit 2019 Super Session - High Tech
- Strategy & thought leadership
- Transitioning from other platforms
- Analytics Basics
- Customizing the UI
- Getting Help
- Analysis Workspace
- Analysis Workspace Basics
- Analysis Workspace quick intro
- Analysis Workspace overview
- Navigate the new landing page
- Start your analysis with a pre-built report
- Building a Workspace project from scratch
- Create and manage custom templates in Analysis Workspace
- Understanding how data gets into your Analysis Workspace project
- Foundational metrics in Adobe Analytics
- Component management in Analysis Workspace
- Selecting a report suite in Analysis Workspace
- View Analysis Workspace performance metrics
- Create bot reports
- Tips and Tricks
- Navigating Workspace Projects
- Data Dictionary in Analysis Workspace
- Starting your first project
- Training tutorial template
- Use folders in Analysis Workspace
- Copy and insert panels and visualizations
- Create a table of contents
- Right-click for Workspace efficiency
- Keyboard shortcuts
- Annotations
- View density
- Use filters
- Use multi-select drop-down filters
- Real-time reports
- Using Panels
- Using Tables, Visualizations, and Panels in Analysis Workspace
- Quick Insights Panel in Analysis Workspace
- Using the Attribution IQ Panel
- Media Concurrent Viewers Panel in Analysis Workspace
- Media Playback Time Spent Panel
- Using Drop-down Filters
- Using Panels to Organize your Analysis Workspace Projects
- Choose segments for a panel
- Multiple Report Suites in Analysis Workspace
- Next/Previous and Page Summary Workspace Panels & Reports
- Understanding attribution panel and lookback windows
- Building Freeform Tables
- Understand your data–freeform tables
- Use the left rail to build freeform tables
- Easy drag and drop to blank projects
- Work with dimensions in a freeform table
- Work with metrics in a freeform table
- Row and column settings in freeform tables
- Freeform table totals
- Use the freeform table builder
- Right-click for workspace efficiency
- Reorder static rows
- Use Attribution IQ in freeform tables
- Cross-sell analysis
- Freeform table filters
- Time-parting dimensions
- Visualizations
- Visualization types and overview
- Visualization use cases
- Data visualization playbook
- Getting data into visualizations
- Using component drop-downs in Workspace
- Area and area stacked visualizations
- Bar and bar stacked visualizations
- Bullet graph visualization
- Donut visualization
- Histogram visualization
- Unlocking insights with histograms
- Line visualization
- Combo charts
- Adding trend lines to line visualizations
- Map visualization
- Summary number and summary change visualizations
- Key metric summary visualization
- Text visualization
- More than words - Using text visualizations and descriptions
- Scatterplot visualization
- Treemap visualization
- Venn diagram visualization
- Use the cumulative average function to apply metric smoothing
- Flexible layouts
- Changing the scale/axis on visualizations
- Dimension-graph live linking
- Set the granularity for visualizations
- Link inside or outside of your project
- Customize visualization legends
- 100% stacked visualizations
- Table and visualization data source settings
- Build a time-parting heatmap
- Analyzing Customer Journeys
- Applying Segments
- Apply segments to your Analysis Workspace project
- Apply ad hoc segments
- Use different Attribution IQ models with segments
- Choose segments for a panel
- Use segments as Dimensions in Analysis Workspace
- Use segments to limit data in Analysis Workspace
- Quick segments in Analysis Workspace
- Building Customer Journey Segments
- Building Customer Journey Segments - Part 2
- Metrics
- Dimensions
- Calendar and Date Ranges
- Curate and Share Projects
- Attribution IQ
- Using Cross-tab Analysis to Explore Basic Marketing Attribution
- Adding side-by-side comparisons of Attribution IQ Models
- Attribution IQ in Calculated Metrics
- Using Attribution IQ in Freeform Tables
- Using the Attribution IQ Panel
- Using different Attribution IQ models with segments
- Algorithmic Model in Attribution IQ
- Custom Look-back Windows in Attribution IQ
- Cohort Analysis
- Cohort Analysis in Analysis Workspace
- Understand your data–Cohort Tables
- Overview of Cohort Tables
- Cohort Table Settings
- Churn Analysis with Cohort Tables
- Cohort Analysis Using Any Dimension
- Latency Analysis with Cohort Tables
- Calculate Rolling Retention in Cohort Tables
- Use Cohort Analysis to Understand Customer Behavior
- Voice Analytics
- How to Manage and Track Your Voice Assistant App Data
- Understand Differences Across Voice-Enabled Devices
- Finding Opportunities To Increase Engagement for Voice Apps
- Reducing Error Rates and Improving Success Rates in Your Voice App
- Understand User Behavior on Voice Assistants
- Understanding the User’s Voice Journey
- Analysis Workspace Basics
- Administration
- Key Admin Skills
- Creating an empowered community
- Simplify and spend less time training users
- Getting the Right People on Your Analytics Team
- Gaining a seat at the table
- Telling impactful stories with data
- Translating Adobe Analytics technical language in a non-technical way
- Working cross-functionally
- Are you asking the right questions?
- Admin Tips and Best Practices
- Download the implementation playbook
- Audit your data dictionary
- Create standardized naming conventions
- Create standardized code templates
- Create basic videos and training
- Create an internal Adobe Analytics site
- Use a global report suite
- Create a news & announcements project
- Drive success with executive summary dashboards
- Create operational dashboards
- Company Settings
- User Management
- Manage Report Suites
- Configure general account settings
- Customize calendar settings
- Configure paid search detection
- Set up marketing channels
- Create marketing channel processing rules
- Manipulate incoming data with processing rules
- Configure traffic variables (props)
- Configure traffic classifications
- Configure hierarchy variables
- Configure events and variables
- Configure conversion classifications
- Configure list variables
- Configure finding methods
- Set internal URL filters
- Configuring zip and postal code settings
- Enable the timestamp optional setting
- Configure bot rules in Analytics
- Data Governance and GDPR
- Traffic Management
- Logs
- Key Admin Skills
- Implementation
- Implementation Basics
- Experience Platform Tags
- Implement Experience Cloud solutions in websites using Tags
- Basic configuration of the Analytics extension
- Configure library management in the Analytics extension
- Configure general settings in the Analytics extension
- Configure global variable settings in the Analytics extension
- Use custom code in the Analytics extension
- Use a data layer to set variables
- Use doPlugins and implementation plug-ins
- Configure easy download link tracking
- Configure easy exit link tracking
- Prepare Tags for your Analytics implementation
- Create data elements for the Analytics implementation
- Create a global page load rule
- Validate the global page load rule
- Create rules for special pages
- Create rules for success events
- Publish Tags libraries to stage and production
- Using JavaScript
- Components
- Segmentation
- Segment builder overview
- Finding and creating segments
- Rolling date ranges in segments
- Segment comparison in Analysis Workspace
- Segment containers
- Segment management and sharing
- Applying segments in Analysis Workspace
- Using segments as dimensions
- Using segments to limit data
- Differences between the segment builder and quick segments
- Sequential segmentation
- Before/After sequences in sequential segmentation
- Segmentation on distinct dimension counts
- Dimension models in segmentation
- Use ‘equals any of’ in segmentation
- Analytics Insider Webinar - Customer Segmentation Strategies
- Now just wait a segment… Using segmentation to discover new insights
- Calculated Metrics
- Calculated metric builder overview
- Calculated metrics - implementation-less metrics
- Calculated metrics - segmented metrics
- Calculated metrics - functions
- Approximate count distinct function in calculated metrics
- Quick calculated metrics in Analysis Workspace
- Manage your calculated metrics
- Attribution IQ in calculated metrics
- Use dimensions in calculated metrics
- Take your data analysis to the next level with calculated metrics
- Classifications
- Virtual Report Suites
- Activity Map
- Segmentation
- Additional Tools
- Exporting
- From the UI
- Data Warehouse
- Data Feeds
- Report Builder
- Upgrade and reschedule workbooks
- Add Segments to Multiple Requests at Once in Report Builder
- Anomaly Detection in Report Builder
- Edit Metrics across Requests
- Using Report Builder to learn the Adobe Analytics API
- Get started with Report Builder
- Schedule a Report Builder request
- Use Report Builder advanced delivery options for Power BI
- Integrations
- Experience Cloud
- Audience Manager
- Target
- Adobe Advertising DSP
- Configuring Advertising Analytics
- Implementing tracking templates into search engines
- Introduction to the Adobe Advertising DSP integration
- Create a Pre-launch campaign analysis
- Report on Advertising DSP marketing channels
- Create Analytics site journey profiles
- Create Analytics segments for activation and reporting
- Create Advertising DSP alerts with Adobe Analytics
- Create Analytics custom metrics with Advertising DSP data
- Create Advertising DSP site entry reports
- Create Advertising DSP dashboards
- Ad Hoc Analytics
- Power BI
- Magento
- Data Science
- Vertical-Specific
- Media Analytics
- Mobile App Analytics
- APIs
- Analysis Use Cases