最终用户尚未完成Auth& Auth签到流eBay

时间:2018-05-29 10:36:43

标签: php codeigniter ebay ebay-api

我试图从交易中获取令牌>获取会话ID,交易>获取令牌,但在向Fetch令牌提供会话ID后,它说:"最终用户尚未完成Auth& Auth签到流程。"。错误如下。

SimpleXMLElement Object
(
[Timestamp] => 2018-05-29T10:21:13.879Z
[Ack] => Failure
[Errors] => SimpleXMLElement Object
    (
        [ShortMessage] => The end user has not completed Auth & Auth sign in flow.
        [LongMessage] => The end user has not completed Auth & Auth sign in flow.
        [ErrorCode] => 21916017
        [SeverityCode] => Error
        [ErrorClassification] => RequestError
    )

[Version] => 1057
[Build] => E1057_CORE_API_18682351_R1
)

我使用fetch令牌代码如下:

$requestXmlBody = '<?xml version="1.0" encoding="utf-8" ?>';
$requestXmlBody .= '<GetSessionIDRequest xmlns="urn:ebay:apis:eBLBaseComponents">';
$requestXmlBody .= "<RequesterCredentials><eBayAuthToken>".$code."</eBayAuthToken></RequesterCredentials>";
$requestXmlBody .= "<ErrorLanguage>en_US</ErrorLanguage>";
$requestXmlBody .= "<WarningLevel>High</WarningLevel>";
$requestXmlBody .= "<RuName>".$ruName."</RuName>";
$requestXmlBody .= '</GetSessionIDRequest>';
$session = new Ebaysession($code, $devID, $appID, $certID, $server_url, 967, $siteID, $verb);

$responseXml = $session->sendHttpRequest($requestXmlBody);

我已成功获得SessionID,并且我将该SessionId用于FetchTokens。但它已不再适用了。

我使用此网址登录:https://signin.sandbox.ebay.com/ws/eBayISAPI.dll?SignIn&runame='.$ruName.'&SessID='.$sessionID

1 个答案:

答案 0 :(得分:0)

在将$ sessionID附加到重定向URL时,请确保对其进行URL编码! 并且,在将其传递给FetchToken端点时,请确保未对其进行编码。