Retrieve Tracking Data from Marketing Cloud using ExtractRequest SOAP API and following XML Payload is being used. Salesforce documentation didn't provided a way to find the ID parameter value to input into the xml request body.

GET / HTTP/1.1
Host: xxxxx.soap.marketingcloudapis.com
content-type: text/xml
SOAPAction: "Extract"

<?xml version="1.0" encoding="UTF-8"?>
<s:Envelope xmlns:s="http://schemas.xmlsoap.org/soap/envelope/">
     <fueloauth>[token provided by REST token Endpoint]<fueloauth>
<s:Body xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
      <ExtractRequestMsg xmlns="http://exacttarget.com/wsdl/partnerAPI">
                  <Value>09/01/2019 12:00:00 AM</Value>
                  <Value>01/01/2020 12:00:00 AM</Value>



Please help me share your tips. Thank you in advance.

2 Answers 2


The ID field in the SOAP request should be the External Key for the Extract Activity found in the Extract (Email Studio -> Interactions -> Data Extract or Journey Builder -> Automation Studio -> Activities -> Data Extract).

enter image description here

enter image description here

  • Thanks for the response, Can't we create an Data Extract Activity and get the .csv/txt document using SOAP API ? Could you please help me clarify from your stand-point of view if you happened to know of anything.
    – Yesh
    Jan 21, 2021 at 0:22
  • The SOAP call will not respond with a CSV/TXT document to download. The SOAP function effectively performs the Extract activity delivering the file as defined in the Extract configuration. Jan 21, 2021 at 2:26
  • If you're a Postman user, my team manages a collection available at api.mcexperts.ninja. The REST collection is more built out than the SOAP but there are multiple SOAP examples that may help you get started. Jan 21, 2021 at 2:33
  • Yeah, I already went through the portal and other websites, couldn't find a good article full filling my request and that's one of a reason, I approached the salesforce.stackexchange.com in getting to know from others more about the details and understanding of the request and response of extracting the data through soap api. Anyway, thanks for your time and suggestions.
    – Yesh
    Jan 22, 2021 at 12:01

The value you are looking for is ObjectID. It can be retrieved via:

SFMC Interface - you can retrieve from inside SFMC by creating a tracking extract and using the dev console to get the "data-value" for tracking extracts in the "Extract Type" drop-down. enter image description here Use SOAP - and look for the extract description called "Tracking Extract."

<s:Envelope xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:a="http://schemas.xmlsoap.org/ws/2004/08/addressing" xmlns:u="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd">
            <a:Action s:mustUnderstand="1">Retrieve</a:Action>
            <a:To s:mustUnderstand="1">XXXXXXXXService.asmx</a:To>
            <fueloauth xmlns="http://exacttarget.com">XXXXXXXXX</fueloauth>
            <s:Body xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
        <RetrieveRequestMsg xmlns="http://exacttarget.com/wsdl/partnerAPI">
                <Filter xsi:type="SimpleFilterPart">
                    <Value>ExternalKey ofRealTrackingExtract</Value>

enter image description here

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .