I am trying to integrate Marketing Cloud with Salesforce.

   //I set the accessToken which I get via the REST Auth service
Map<String, String> headerMap = new Map<String, String>();

//I search for Data extension records for a data extension named "RespondedCustomers" with the following properties : SubscriberKey and Phone

exacttargetComWsdlPartnerapi.RetrieveRequest vRetrieveRequest = new exacttargetComWsdlPartnerapi.RetrieveRequest();
String s = 'DataExtensionObject[RespondedCustomers]';
vRetrieveRequest.ObjectType = s;

String p1 = 'SubscriberKey';
String p2 = 'Phone';
String[] arrP = new String[]{p1,p2};
vRetrieveRequest.Properties = arrP;

exacttargetComWsdlPartnerapi.Soap ins = new exacttargetComWsdlPartnerapi.Soap();

ins.inputHttpHeaders_x = headerMap;



I am getting a SOAP fault shown below stating that security requirements are not satisfied.

enter image description here

Can someone let me know what needs to be done in this case ?

Working example from Postman

enter image description here

  • 1
    Step 1: understand what XML is being generated by your Apex code, compare and contrast to working example.
    – identigral
    Nov 20 at 17:41


You must log in to answer this question.

Browse other questions tagged .