我正在尝试使用stamps.com API和php验证用户,我收到以下错误:
: Uncaught SoapFault exception: [soap:Server] Server was unable to process request. ---> The remote server returned an error: (404) Not Found.
这是我的PHP代码:
//Authenticate Stamps.com SOAP API
$IntegrationID = "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX";
$Username = "XXXXXXXXXXXXXXX";
$Password = "XXXXXXXXXXXXXXX";
$wsdl = "https://swsim.testing.stamps.com/swsim/swsimv50.asmx?wsdl";
//Authenticate User
$authData = array(
"Credentials" => array(
"IntegrationID" => $IntegrationID,
"Username" => $Username,
"Password" => $Password
)
);
$client = new SoapClient($wsdl);
$auth = $client->AuthenticateUser($authData);
$AuthenticatorToken = $auth->Authenticator;
我似乎无法在任何地方找到解决方案,任何想法可能导致错误?
答案 0 :(得分:1)
Stamps.com API要求您注册为开发人员并提供您的IP地址,以便他们可以在使用API之前将其添加到API白名单中。
如果您还没有使用Stamps.com注册开发者帐户,可以在此处注册:http://developer.stamps.com/developer/register/