1
這是eBay API的第一次測試。 我附上所需時間的代碼。它給了我下面的錯誤:致電Ebay API調用「GeteBayTime」在此版本中無效或不受支持
2016-02-13 11:10:22FailureUnsupported API call.The API call "GeteBayTime" is invalid or not supported in this release.2ErrorRequestError92117790382
代碼:
$EndPoint='https://api.sandbox.ebay.com/ws/api.dll';
$header= array(
'Content-Type: text/xml',
'X-EBAY-API-COMPATIBILITY-LEVEL: 921',
'X-EBAY-API-DEV-NAME: ' . $devId,
'X-EBAY-API-APP-NAME: ' . $appId,
'X-EBAY-API-CERT-NAME: ' . $certId,
'X-EBAY-API-CALL-NAME: ' . 'GeteBayTime',
'X-EBAY-API-SITEID: ' . '101',
'X-EBAY-API-REQUEST-ENCODING:XML'
);
$xml='<?xml version="1.0" encoding="utf-8"?>
<GeteBayTimeRequest xmlns="urn:ebay:apis:eBLBaseComponents">
</GeteBayTimeRequest>';
$connection = curl_init();
curl_setopt($connection, CURLOPT_URL, $EndPoint);
curl_setopt($connection, CURLOPT_SSL_VERIFYPEER, 0);
curl_setopt($connection, CURLOPT_SSL_VERIFYHOST, 0);
curl_setopt($connection, CURLOPT_HTTPHEADER, $header);
curl_setopt($connection, CURLOPT_POST, 1);
curl_setopt($connection, CURLOPT_POSTFIELDS, $xml);
curl_setopt($connection, CURLOPT_RETURNTRANSFER, 1);
$response = curl_exec($connection);
curl_close($connection);
echo $response;
你能告訴我,我錯了嗎? 謝謝