SOAP Authentication for amazon

From: Date: Sat, 10 Sep 2005 01:48:21 +0000
Subject: SOAP Authentication for amazon
Groups: php.soap 
Request: Send a blank email to php-soap+get-1985@lists.php.net to get a copy of this message
I am trying to implement a SOAP client for Amazon but haven't been successful for a week already. I have used both PEAR and NuSoap without success. For NuSoap, I am having this problem by simply implementing a getproxy call: Parse error: parse error, unexpected T_STRING in ....../nusoap.php(6983) : eval()'d code on line 1 Fatal error: Cannot instantiate non-existent class: soap_proxy_1665726584 in ......nusoap.php(6985) : eval()'d code on line 1 Here's the very short and simple code: // include class include("nusoap.php"); // create a instance of the SOAP client object $client = new soapclient("https://merchant-api-qa.amazon.com/gateway/merchant-interface-mime",true); $proxy = $client->getProxy(); $proxy->setCredentials($username, $password); I should have at least got a Authentication error not the error I mentioned above. ############# Similarly, using Pear::Soap, am getting an empty response from the server with the following code: include("SOAP/Client.php"); $proxy = array('user'=>$username,'pass'=>$password); $soapclient = new SOAP_Client("$url", true, false, $proxy); $v = new SOAP_Attachment('SWA','text/xml','attachment.xml'); $params = array('merchant'=>$merchantName,'messageType'=> '_POST_PRODUCT_DATA_','doc' => $v); #$options = array('namespace' => 'urn:http://www.amazon.com/merchants/merchant-interface','trace' => 1); $ret = $soapclient->call('postDocument',$params); print_r($ret);echo "<br>\n"; Thanks in advance.

« previous php.soap (#1985) next »