如何修复请求缺少必需的输入标签

我试图从用户的 ebay 帐户中获取一些产品,但是当我运行我的代码时,我只收到一个错误“您的应用程序遇到错误。此请求缺少必需的输入标签”或“。”


<?php


function print_d($array){    echo "<pre>\n";    print_r($array);    echo "</pre>\n";}


$mytoken = "************mytoken************";

$devId   = "************mydevId************";

$appId   = "************myappId************";

$certId  = "************mycertId************";


$wsdl_url = 'http://developer.ebay.com/webservices/latest/ebaySvc.wsdl';


$apiCall = "GetSellerList";


$credentials = array('AppId' => $appId, 'DevID' => $devId, 'AuthCert' => $certId);


$client = new SOAPClient($wsdl_url, array('trace' => 1, 'exceptions' => 0, 'location' => "https://api.ebay.com/wsapi?callname=$apiCall&appid=$appId&siteid=0&version=803&Routing=new"));


$eBayAuth = array('eBayAuthToken' => new SoapVar($mytoken, XSD_STRING, NULL, NULL, NULL, 'urn:ebay:apis:eBLBaseComponents'),

                    'Credentials' => new SoapVar ($credentials, SOAP_ENC_OBJECT, NULL, NULL, NULL, 'urn:ebay:apis:eBLBaseComponents'));  


$header_body = new SoapVar($eBayAuth, SOAP_ENC_OBJECT);    


$header = array(new SOAPHeader('urn:ebay:apis:eBLBaseComponents', 'RequesterCredentials', $header_body));                


//set the API call parameters


$params = array('UserID'=>'**sellerid**','DetailLevel'=>'ReturnAll','WarningLevel'=>'High','IncludeWatchCount'=>'true','Pagination'=>array('EntriesPerPage'=>'20','PageNumber'=>'1'),'Version' => '803', 'CreateTimeFrom'=>'2019-07-01T01:01:02.768Z', 'CreateTimeTo'=>'2019-08-22T01:01:02.768Z');  


$request = $client->__soapCall($apiCall, array($params), NULL, $header);  //make the actual API call


print_d($request);


?>


收到一只叮咚
浏览 198回答 1
1回答

qq_花开花谢_0

谢谢我只是使用邮递员,我发现 StartTimeFrom 和 StartTimeTo 是缺失的
打开App,查看更多内容
随时随地看视频慕课网APP