@@ -36,6 +36,7 @@ const config = {
3636 datastreamId: ' abcde123-abcd-1234-abcd-abcde1234567' ,
3737 orgId: ' ADB3LETTERSANDNUMBERS@AdobeOrg' ,
3838 edgeBasePath: ' ee' ,
39+ edgeDomain: ' my.domain.com' ,
3940 debugEnabled: true ,
4041 },
4142 mobile: {
@@ -58,7 +59,7 @@ const customIdentityMap = {
5859}
5960
6061const App = () => {
61- const [adobe, initAdobe] = useAdobe (config , customIdentityMap );
62+ const [adobe, initAdobe] = useAdobe (config , /* optional */ customIdentityMap );
6263
6364 const onPlayerReady = (player : THEOplayer ) => {
6465 // Initialize Adobe connector
@@ -87,3 +88,39 @@ const onUpdateMetadata = () => {
8788 adobe .current ?.updateMetadata (metadata );
8889};
8990```
91+
92+ ### Setting an custom identity map
93+
94+ Besides passing a custom identity map during initialization, you can also set or update the identity map at any time:
95+
96+ ``` typescript
97+ import {AdobeIdentityMap } from " @theoplayer/react-native-analytics-adobe-edge" ;
98+
99+ const onUpdateIdentityMap = () => {
100+ const identityMap: AdobeIdentityMap = {
101+ CUSTOMER_ID: [
102+ {
103+ id: ' customer-12345' ,
104+ authenticatedState: ' authenticated' ,
105+ primary: true ,
106+ },
107+ ],
108+ };
109+ adobe .current ?.setIdentityMap (identityMap );
110+ };
111+ ```
112+
113+ ### Starting a new session during a live stream
114+
115+ By default, the connector will start a new session when a new asset is loaded. However, during live streams, you might
116+ want to start a new session
117+ periodically when a new program starts. You can do this by calling ` stopAndStartNewSession ` with the new program's
118+ metadata:
119+
120+ ``` typescript
121+ const onNewProgram = () => {
122+ adobe .current ?.stopAndStartNewSession ({
123+ ' friendlyName' : ' Evening News' ,
124+ });
125+ };
126+ ```
0 commit comments