Consents in AEP web SDK extension | Community
Skip to main content
Level 3
June 12, 2025
Solved

Consents in AEP web SDK extension

  • June 12, 2025
  • 1 reply
  • 1510 views

Hello All,

Currently the below cookies are getting collected even before the user provides his consent through the one trust cookie banner . This is working due to the configuration in the AEP web SDK extension which is In - collect events that occur before the user provides consent preferences. How can we modify this setting via the custom data element option so that these cookies will occur only after the user provides his consent on the one trust cookie banner.

 

 

 

Best answer by yuhuisg

You will need to configure the "Consent" section in the Web SDK extension's configuration:

 

You will need to have a custom data element that returns "in", "out" or "pending". Setting to "out" or "pending" should prevent the cookies from being written before the user has granted consent, as documented at https://experienceleague.adobe.com/en/docs/experience-platform/web-sdk/commands/configure/defaultconsent#using-consent

I haven't worked with OneTrust nor any consent management system. But that CMS should set a cookie after the user grants consent. You can then use that cookie to run the "Set Consent" action later.

1 reply

yuhuisg
Community Advisor
yuhuisgCommunity AdvisorAccepted solution
Community Advisor
June 12, 2025

You will need to configure the "Consent" section in the Web SDK extension's configuration:

 

You will need to have a custom data element that returns "in", "out" or "pending". Setting to "out" or "pending" should prevent the cookies from being written before the user has granted consent, as documented at https://experienceleague.adobe.com/en/docs/experience-platform/web-sdk/commands/configure/defaultconsent#using-consent

I haven't worked with OneTrust nor any consent management system. But that CMS should set a cookie after the user grants consent. You can then use that cookie to run the "Set Consent" action later.

SankaranAuthor
Level 3
June 12, 2025

Thanks @yuhuisg for the detailed response. I will look into this.