Hi everyone,
I’m trying to implement a Soap Client for Amazon Seller Central, and get this error when trying to run a document request:
[CODE]Fatal error: Uncaught SoapFault exception: [HTTP] Authorization Required
I’m not sure if it’s actually sending the request and this is the result, or if there’s a problem with the request?
Anyway, Amazon’s documentation is lacking (I’m being generous when I say that) and they don’t explain how to authenticate… if that’s even the issue.
Here’s the code I’m using:
[code=php]
$ACS = new AmazonSellerCentral();
$ACS->DoSomething();
class AmazonSellerCentral {
const WSDL = ‘AMZ.wsdl.xml’;
private $Soap;
function __construct()
{
$this->Soap = new SoapClient(self::WSDL, array(‘login’ => “MY_SELLER_TOKEN”,
‘password’ => “MyPassword”));
}
function DoSomething()
{
echo $this->Soap->getAllPendingDocumentInfo(‘MY_SELLER_TOKEN’, ‘_GET_ORDERS_DATA_’);
}
} // END Class
Any help is appreciated.
Thanks,
Nick