Anyone using Profile Scripts with AEP Web SDK implementation? | Community
Skip to main content
Level 2
December 21, 2021
Solved

Anyone using Profile Scripts with AEP Web SDK implementation?

  • December 21, 2021
  • 1 reply
  • 3034 views

I've recently been working on a new implementation of Analytics/Target via the AEP Web SDK, and am in the process of configuring some new activities.  In the past, I've used profile scripts as an easy way to handle complex audience parameters that need some sort of calculation or persistence, but I don't see anything in the documentation that addresses how to reference XDM data in the profile script editor.  Is this even an option with the Web SDK, and if so how would I reference the XDM data when building a script?

Best answer by wgharper

Cross posting an answer from @moses_maxen in a recent AT Community Q&A Coffee Break:

 

@wgharper - I love this question!  XDM data can be leveraged within a profile script following a similar syntax seen below.  It is very similar to referencing a Target mbox parameter within the script.  In fact, if you start typing mbox.param into the profile script UI, you should see a drop down list of all mbox params including XDM fields to select from.  

 

mbox.param('productListItems.SKU') 

1 reply

wgharperAuthorAccepted solution
Level 2
August 8, 2022

Cross posting an answer from @moses_maxen in a recent AT Community Q&A Coffee Break:

 

@wgharper - I love this question!  XDM data can be leveraged within a profile script following a similar syntax seen below.  It is very similar to referencing a Target mbox parameter within the script.  In fact, if you start typing mbox.param into the profile script UI, you should see a drop down list of all mbox params including XDM fields to select from.  

 

mbox.param('productListItems.SKU') 

Amelia_Waliany
Adobe Employee
Adobe Employee
October 28, 2022

Thanks so much for cross-promoting, posting, and closing out your original question @wgharper ! 🌟🙌