Multiple mbox requests on a page sending the same entity.id to Target Recommendations? | Adobe Higher Education
Skip to main content
kirill_techZone
Level 2
May 8, 2020
Risolto

Multiple mbox requests on a page sending the same entity.id to Target Recommendations?

  • May 8, 2020
  • 2 risposte
  • 5714 visualizzazioni

Hi, community.

We have pages on our site which we consider as "product view" in case of being visited by a user. Those pages may send not only one "global" mbox requests, they can also send several "not global" mbox requests related to AEM target components included on the page. All mbox requests utilize the same "targetPageParams" function returning entity.id and entity.categoryId values.

 

Now the question:

If a page sends, for example, 3 mbox requests having the same entity.* values, will this fact be treated by Target as if a user has viewed this product page 3 times ?

Questo argomento è stato chiuso alle risposte.
Migliore risposta di ryanr7

Yes, each request that contains an entity.id will be understood by Recommendations as a view. Are you using the targetPageParams() or the targetPageParamsAll()? One only applies the global mbox request (or pageLoad request). The "all" version should apply to any request from the page including later getOffers(), or trackEvent() requests. So if you only want the entity.id, entity.categories to get passed on the global request consider moving them to the targetPageParams instead of the targetPageParamsAll.

2 risposte

ryanr7Adobe EmployeeRisposta
Adobe Employee
May 8, 2020

Yes, each request that contains an entity.id will be understood by Recommendations as a view. Are you using the targetPageParams() or the targetPageParamsAll()? One only applies the global mbox request (or pageLoad request). The "all" version should apply to any request from the page including later getOffers(), or trackEvent() requests. So if you only want the entity.id, entity.categories to get passed on the global request consider moving them to the targetPageParams instead of the targetPageParamsAll.

Community Advisor
May 13, 2020

Agreed with @ryanr7 

 

You can also look at getOffers and only pass entity to the request that you care about:

 

adobe.target.getOffers({
  request: {
    execute: {
      mboxes: [
        {
          index: 0,
          name: "first-mbox"
        },
        {
          index: 1,
          name: "second-mbox",
          parameters: {
            a: 1
          },
          profileParameters: {
            b: 2
          }
        }
      ]
    }
  }
});

 

however, it will require you updating to the latest version of Adobe Target.