Expand my Community achievements bar.

Join us for the next Community Q&A Coffee Break on Tuesday April 23, 2024 with Eric Matisoff, Principal Evangelist, Analytics & Data Science, who will join us to discuss all the big news and announcements from Summit 2024!

Fetching Marketing Cloud Visitor ID in API

Avatar

Level 2

Hello everyone,

We have a use case where we have integrated Target and analytics audience to deliver content through delivery API. For this request, we need to pass the marketing cloud visitor ID in API request alongwith the customer ID to fetch the relevant target content. But currently we are reading the MCID from the web and using it in API. We want to dynamically fetch the mcid in API request.  We are currently using Postman application for the API requests. We tried using the getMarketingCloudVisitorID function in the pre-request script to populate the mcid; but it does not works and throws error.

Can anyone please suggest a way to dynamically fetch the MCID in Target API through the pre-request scripts or some other modifications that we can make in the API request?

Thanks in advance.

Regards,

Richa

0 Replies