profile update (via the Server-Side Delivery API) | Community
Skip to main content
broman__pl
Level 3
June 4, 2022
Solved

profile update (via the Server-Side Delivery API)

  • June 4, 2022
  • 2 replies
  • 1452 views

I'm reading target docs about server side integrating with 3rd party data sources and there are some limitations and there is mention that i should integrate though adobe.io to pass them but then on adobe.io docs I see same description about profile update with same limitations and link to "Server-Side Delivery API" which is top of same documentation. Where I can find real documentation where single updates will be processed faster than 1-24h?

 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Rajneesh_Gautam_

hi @broman__pl  - documentation can be found here: https://developers.adobetarget.com/api/delivery-api/#section/Getting-Started 

hope this helps,

 

Regards

Rajneesh

2 replies

Rajneesh_Gautam_
Community Advisor
Community Advisor
June 7, 2022

hi @broman__pl  - If you use single-profile update API then the delay will remain same regardless the implementation approach. To make profile-updates much faster, solution is Server side delivery API as you mentioned. Server-side API implementation requires:

1. An execution environment which can make calls to API - there are SDKs for Java and NodeJS though you may use any other languages
2. Way to get Experience Cloud ID or PCID - the easiest way is to pass these from client-side to execution environment

3. Generate the session-id: You can either pass the session-id from client-side or generate your own following these guidelines: 
4. Pass user data as mbox call - here's a code sample below:

5. In Adobe Target - you can use Profile Scripts to read the parameters and use in Audiences as per your use-cases. 

var targetURL = 'https://<your-client-code>.tt.omtrdc.net/rest/v1/delivery?client=<your-client-code>&sessionId='+<session-id>;

var targetData = {
"context":{
"channel":"web"
},
"id": {
"marketingCloudVisitorId": <ECID>,
"tntId": <PCID>
},
"experienceCloud" : {
"analytics": {
"logging": "client_side"
}
},
"execute": {
"mboxes" : [
{
"name" : "<mbox-name>",
"index" : 1,
"parameters": {"param1":"value1"}
}
]
}
}

let targetHeaders = new Headers();
targetHeaders.append('Content-Type','application/json');

let targetRequest = new Request(targetURL, {
method: 'POST',
headers: targetHeaders,
mode: 'cors',
cache: 'default',
body: JSON.stringify(targetData)
});

fetch(targetRequest)
.then(response => {
if (!response.ok) {
throw new Error(`Network response was not ok. Status code: ${JSON.stringify(response)}.`);
}
return response.json();
})
.then(data => yourFunctionToProcessTargetResponse(data))
.catch(error => console.log("Error:" + error.message));
}
broman__pl
Level 3
June 7, 2022

Hi @rajneesh_gautam_ but where I can find documentation about this Server-side API? IN two places I see same details

1 https://experienceleague.adobe.com/docs/target/using/implement-target/before-implement/methods/single-profile-update-api.html?lang=en

2 http://developers.adobetarget.com/api/#updating-profiles

On second page there is mention about server side with link but it just points to top of this page 😞

 

Rajneesh_Gautam_
Community Advisor
Rajneesh_Gautam_Community AdvisorAccepted solution
Community Advisor
June 8, 2022

hi @broman__pl  - documentation can be found here: https://developers.adobetarget.com/api/delivery-api/#section/Getting-Started 

hope this helps,

 

Regards

Rajneesh