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.

How to debug (view what's being logged) in Category Affinity

Avatar

Level 3

I'm getting started with Category Affinity using Launch, and I think I've got it set up correctly based on the documentation I've found. 

However, I'm not finding a way to validate that categories are being captured properly, view what my visitor ID category affinity is, etc.

I've looked at the Target and Network tabs of the Adobe Experience Cloud debugger, as well as the Console and Network tabs of my browser DevTools, but I'm not finding any way to get visibility into what's being tracked. 

Please note: I'm not a web developer so the direction of "You can use user.categoryAffinities[] in a profile script to return an array of the affinities that a visitor has populated." found here isn't something that I know what to do with.  I'm not trying to get this displayed on a page; I'm trying to make sure these values are being tracked as expected. 

Thanks much!

4 Replies

Avatar

Level 10

Hey Matt,

To make sure that values get tracked (captured on the page), you just need to debug the Target mbox call. You may want to use Adobe debugger or browser developer tools (network tab). Just check that the parameter categoryId is set with the right value(s).

The rest is the backend algorithm that sets weights to each value as per the documentation you mentioned.

Avatar

Level 3

Thank you for the response.

I've been looking through the Adobe Debugger and haven't seen anything related to Category Affinity being captured there.

On second pass, now I'm seeing where I should be looking in my Browser Network tab.  I was originally looking at /b/ss/, which I see now is just for Analytics debugging.  Now that I'm looking at /m2/, I'm seeing Target information but, as above, no logging of Category Affinity being captured. 

I suspect this is a misconfiguration on my part.  If you are able to assist with troubleshooting my configuration, that would be very much appreciated.  Below is an outline of what I have put together in Launch. 

  • Data Element
    • Name "Target - Category Affinity"
    • Mapped to Javascript variable digitalData.tags.categories to capture value in our Data Layer
      • Duration: Pageview
      • Default Value, Force Lowercase, and Clean Text are all left blank/unchecked
    • Validated that the pages I'm testing have values in the data layer in this location (digitalData.tags.categories)
  • Rules
    • All Pages rule
    • Action for Target Extension
    • Action Type: Add Params to Global Mbox
      • user.categoryId = %Target - Category Affinity%
      • "Don't send if empty value" is checked

Any ideas on what might be going wrong here?

Avatar

Level 10

Matt,

I have taken a look at the page. If I was able to parse the library correctly, the problem is in the rules configuration.

You have two rules:

  • All Pages
    • AT load library > AT fire mbox
  • All Pages - Top of Page
    • AA set vars > AA send beacon > AT add params

What you need to do is to move the "AT add params" action from "All Pages - Top of Page" to "All Pages" and put it in between "AT load library" and "AT fire mbox".

BTW, to avoid experience flickering effect, you may want to run all AT actions on the event "Library loaded". If this event is set for the rule "All Page - Top of Page", then I would recommend to move everything in this rule as follows:

  • AT load library > AT add params > AT fire mbox > AA set vars > AA send beacon

Let me know if this resolves the issue?

Avatar

Level 3

That makes sense; I made the requested change & implemented the updated rule on Production. 

However, currently the results are the same.  I'll send you another page of our site as a test for comparison. 

Thanks