You need to sign in to do that
Don't have an account?
Stefaan Somers
Use of PHP Toolkit making use of ESB
We do our communication with Salesfore not directly, but through Enterprise Solution Bus. So we don't need to login anymore to salesforce, but just the API-request to the ESB who will do his communication with Salesforce. But the ESB needs a special soap-header.
So I try to modify SfBaseClient, the method
But when doing this, I always get
Fatal error: SoapClient::__setSoapHeaders(): Invalid SOAP header in C:\var\sourceRepositories\salesforce\Force.com-Toolkit-for-PHP-master\soapclient\SforceBaseClient.php on line 337
How can I obtain this functionality
<soapenv:Header> <ns1:header soapenv:actor=“http://schemas.xmlsoap.org/soap/actor/next” soapenv:mustUnderstand=“0” xmlns:ns1=“http://www.xxxx.com/xsd/esb/ESBCommonTypes”> <ns1:message_type>SF_ENTPRISE_Interface</ns1:message_type> <ns1:version>01.80</ns1:version> <ns1:source_entity>xxxx</ns1:source_entity> <ns1:source_application>xxx</ns1:source_application> <ns1:destination_entity>xxx</ns1:destination_entity> <ns1:destination_application>xxx</ns1:destination_application> <ns1:message_id></ns1:message_id> </ns1:header> </soapenv:Header>
So I try to modify SfBaseClient, the method
private function setHeaders($call=NULL) { ...... $soapHeader=new SoapHeader('http://www.leaseplan.com/xsd/esb/ESBCommonTypes', 'header', array ( 'client'=> 'test', 'defaultNamespace'=> 'test', 'message_type' => 'xxxx', 'version' => '01.80', 'source_entity' => 'xxx' , 'source_application' => 'LNOTES', 'destination_entity'=> 'xx', 'destination_application'=> 'SFxxxBE' )); array_push($header_array, $soapHeader); $this->sforce->__setSoapHeaders($header_array);
But when doing this, I always get
Fatal error: SoapClient::__setSoapHeaders(): Invalid SOAP header in C:\var\sourceRepositories\salesforce\Force.com-Toolkit-for-PHP-master\soapclient\SforceBaseClient.php on line 337
How can I obtain this functionality