Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

Tutorial Discussion: Implement Adobe Experience Cloud in mobile apps

Avatar

Employee

Use this thread to ask any questions related to the Implement Adobe Experience Cloud in mobile apps  tutorial on Experience League. Experts are monitoring this thread to ensure your questions are answered.

4 Replies

Avatar

Level 1

Could you pls provide equivalent android Java code for the below code.

 

        let stateName = "luma: content: ios: us: en: home"
        var xdmData: [String: Any] = [:]
        //Page View
        xdmData["_techmarketingdemos"] = [
            "appInformation": [
                "appStateDetails": [
                    "screenType": "App",
                    "screenName": stateName,
                    "screenView": [
                        "value": 1
                    ]
                ]
            ]
        ]
        let experienceEvent = ExperienceEvent(xdm: xdmData)
        Edge.sendEvent(experienceEvent: experienceEvent)

 

 

Map<String, Object> XdmData = new HashMap<>();
??????????????
????????????
ExperienceEvent experienceEvent = new ExperienceEvent.Builder()
                .setXdmSchema(xdmData)
                .build();

 

 

 

Avatar

Employee

Hi @kag1516 , We hope to provide more Android content in the future. I think what you are looking for can be found in the Mobile SDK documentation:

https://aep-sdks.gitbook.io/docs/getting-started/initialize-the-sdk

 

Map<String, Object> reviewXdmData = new HashMap<>();
reviewXdmData.put("productSku", "demo123");
reviewXdmData.put("rating", 5);
reviewXdmData.put("reviewText", "I love this demo!");
reviewXdmData.put("reviewerId", "Anonymous user");

Map<String, Object> xdmData = new HashMap<>();
xdmData.put("eventType", "MyFirstXDMExperienceEvent");
xdmData.put(_yourTenantId, reviewXdmData);

ExperienceEvent experienceEvent = new ExperienceEvent.Builder()
                .setXdmSchema(xdmData)
                .build();
Edge.sendEvent(experienceEvent, null);

 

 

Avatar

Level 1

Thanks @dwright additional question- So is it correct to say to use edge n/w:---

 

1)Is it recommended to use Identity extension to set up custom identity in app?

2)Is it good to have lifecycle extension. ?

3) Consent extension is optional. ?

3) Profile extension is also optional. ?

Avatar

Employee

Hi,

1. In addition to setting customer ids, I believe the Identity extension is also required for ECID management.

2. Yes, from what i understand most customers find the lifecycle metrics pretty fundamental to understanding how customers are use their mobile apps, so in that sense it is very good to have.

3. The consent extension is often used in conjunction with third-party Consent Management Platforms (CMPs) to support regulations like GDPR. If your mobile app doesn't have any requirements to support privacy regulations like that, then perhaps it the Consent extension is optional.

4. Profile extension is optional. No need to install it if you don't have a use case that requires it.

 

@cprasad @stcheng1991 do you agree?

Avatar

Level 1


thanks  @dwright  @cprasad @stcheng1991

Once we defined the schema and add a custom field of userid. Do we need to mark it as primary identity? as mentioned in the https://aep-sdks.gitbook.io/docs/resources/user-guides/getting-started-with-adobe-experience-platfor... where they enabled reviewerid as primary?
And use the identitymap code to include the userid. ?

Avatar

Level 1

Hi Dwright,

 

we're having trouble with the adobe_mc parameters in webviews to get the ECID in Android, this is an example of the parameter passed to the webview URL: 

TS%3D1660981679%7CMCMID%3D67579004973751132215752525457293482498%7CMCORGID%[...]%40AdobeOrg

 

where on iOS we have it decoded: 

TS=1660985964|MCMID=25673402669707913044806099111595030088|MCORGID=[...]@AdobeOrg

 

As far as i know the encoded parameter should work, but till now only in iOS the Api is getting the MCMID ID.

This is the only difference we have noticed  in the two systems. This two datas are taken from an eVar on the pageview beacon.

 

Regards

G.

Avatar

Employee

Hi,

Just got back from vacation and saw your note. Please let me know if I am understanding your question correctly.

  1. You went through the Web Views lesson of the tutorial in which you pass the identity values to the html page as query string parameters: https://experienceleague.adobe.com/docs/platform-learn/implement-mobile-sdk/app-implementation/web-v...
  2. You were able to validate that things were working correctly in iOS
  3. You tried to do the same in a separate Android app (not part of the tutorial). You are not seeing the query string params with the identities being passed in your evars?

D