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
BedrockMission!

Learn more

View all

Sign in to view all badges

SOLVED

Override MCID over cookies for mobile app implementation

Knowledgeseeker98
Level 3
Level 3

how to override the MCID over the cookies for mobile app implementation?

1 Accepted Solution
AndrewWathen
Correct answer by
Community Advisor
Community Advisor

It is a while since I looked at this so I could be wrong or might even be referring to an old version of the SDK.  Caveats aside....

 

If you are looking to set the MCID in a mobile app, I don't think you can directly overwrite the MCID but you can set a custom visitor ID which takes precedence over the MCID (the equivalent of setting s.visitorID on the web). There is some nuances which may be relevant depending on why you want to do it.

 

As mentioned setting a custom visitor ID does not overwrite the MCID.  It is an additional visitor ID that is captured as well to the MCID.  When it comes to processing the data, if a custom visitor ID is set, both MCID and custom visitor ID exist but I believe the custom visitor ID takes precedence and will be used for joining journeys together, counting visitor numbers etc.

 

At the time I was looking at this, we had been considering passing the MCID from our website to mobile app so the journey joined up as a single visitor.  However, the nuance we found was that it isn't treated exactly as thought the MCID has been replaced. So even though the custom visitor ID we were setting was the same value as the MCID on the website, the website and app journeys did not join up - i.e. it was not seen as the same visitor.  We might have got round this by setting the MCID as a custom visitor ID on the website but it was getting all too complex!

 

As mentioned things might have moved on... would be interested to hear if anyone else has experience of this!

 

View solution in original post

8 Replies
Khurshid_Alam
Employee
Employee

If my understanding is correct, you are looking for overwriting existing MCID cookies on a web page when a user arrives via a mobile app. If that is the scenario, you might want to use appendToURL function along withoverwriteCrossDomainMCIDAndAID. Refer to the below docs.

 

https://docs.adobe.com/content/help/en/mobile-services/android/sdk-reference-android/hybrid-app.html

https://docs.adobe.com/content/help/en/id-service/using/id-service-api/configurations/overwrite-visi...

 

Knowledgeseeker98
Level 3
Level 3
But we can't utilize append URL since URL have many redirection ,also final loading URL not getting the appended parameters.Can you please share your thoughts on this?
Khurshid_Alam
Employee
Employee
In that scenario, I will suggest using s.visitorID solution as @AndrewWathen suggested.
AndrewWathen
Community Advisor
Community Advisor

@ashokadiylil - if you are looking to pass the MCID from a mobile app to a website, but the query string parameter is getting lost due to redirects there is nothing that can be done from an Adobe implementation point of view.  You need to work with the people responsible for the redirects to either remove them, or to find a way to preserve the query string parameter to the point at which you can use it.

AndrewWathen
Correct answer by
Community Advisor
Community Advisor

It is a while since I looked at this so I could be wrong or might even be referring to an old version of the SDK.  Caveats aside....

 

If you are looking to set the MCID in a mobile app, I don't think you can directly overwrite the MCID but you can set a custom visitor ID which takes precedence over the MCID (the equivalent of setting s.visitorID on the web). There is some nuances which may be relevant depending on why you want to do it.

 

As mentioned setting a custom visitor ID does not overwrite the MCID.  It is an additional visitor ID that is captured as well to the MCID.  When it comes to processing the data, if a custom visitor ID is set, both MCID and custom visitor ID exist but I believe the custom visitor ID takes precedence and will be used for joining journeys together, counting visitor numbers etc.

 

At the time I was looking at this, we had been considering passing the MCID from our website to mobile app so the journey joined up as a single visitor.  However, the nuance we found was that it isn't treated exactly as thought the MCID has been replaced. So even though the custom visitor ID we were setting was the same value as the MCID on the website, the website and app journeys did not join up - i.e. it was not seen as the same visitor.  We might have got round this by setting the MCID as a custom visitor ID on the website but it was getting all too complex!

 

As mentioned things might have moved on... would be interested to hear if anyone else has experience of this!

 

View solution in original post

Knowledgeseeker98
Level 3
Level 3

Thanks for the reply,But we can't utilize append URL since URL have many redirection ,also final loading URL not getting the appended parameters.Can you please share your thoughts on this?Can you give a solution for achieving it? If possible could you please give a step by step process?

AndrewWathen
Community Advisor
Community Advisor
@ashokadiylil - if you are looking to pass the MCID from a mobile app to a website, but the query string parameter is getting lost due to redirects there is nothing that can be done from an Adobe implementation point of view. You need to work with the people responsible for the redirects to either remove them, or to find a way to preserve the query string parameter to the point at which you can use it.