易趣错误无效的ShipToLocation

时间:2014-11-08 13:44:49

标签: xml api ebay ebay-api

我试图在英国网站上列出新产品,但会出现一些错误。我将从我的数据库中获取数据并发送给ebay。

这里请求XML:

<AddFixedPriceItemRequest xmlns="urn:ebay:apis:eBLBaseComponents">
     <RequesterCredentials>
        <eBayAuthToken>Ebay TOken</eBayAuthToken>
    </RequesterCredentials>
    <DetailLevel>ReturnAll</DetailLevel>
    <ErrorLanguage>en_US</ErrorLanguage>
    <Version>551</Version>
    <WarningLevel>High</WarningLevel>
    <Item>
        <Site>UK</Site><PrimaryCategory><CategoryID>164306</CategoryID></PrimaryCategory><StartPrice currencyID="GBP">120.99</StartPrice><BuyItNowPrice>0</BuyItNowPrice>       
        <BestOfferDetails>
            <BestOfferEnabled>false</BestOfferEnabled>
        </BestOfferDetails>
        <Country>GB</Country>
        <Currency>GBP</Currency>
        <DispatchTimeMax>10</DispatchTimeMax>
        <ListingDuration>Days_3</ListingDuration>
        <ListingType>FixedPriceItem</ListingType>
        <PaymentMethods>PayPal</PaymentMethods>
        <PayPalEmailAddress>abc@gmail.com</PayPalEmailAddress>
        <PictureDetails><PhotoDisplay>PicturePack</PhotoDisplay><PictureURL>http://i.ebayimg.sandbox.ebay.com/00/s/NTUwWDU1MA==/z/pRQAAOSwZDVUXafi/$_1.JPG?set_id=8800005007</PictureURL></PictureDetails>
        <Location><![CDATA[SURAT, GUJARAT]]></Location><Quantity>1</Quantity>
        <ReturnPolicy>
          <ReturnsAcceptedOption>ReturnsAccepted</ReturnsAcceptedOption>
          <RefundOption>MoneyBack</RefundOption>
          <ReturnsWithinOption>Days_14</ReturnsWithinOption>
          <Description>If you are not satisfied, return the item for refund.</Description>
          <ShippingCostPaidByOption>Buyer</ShippingCostPaidByOption>
        </ReturnPolicy>
        <ShippingDetails>
        <ShippingServiceOptions>
          <ShippingService>UK_StandardShippingFromOutside</ShippingService>
          <ShippingServiceCost currencyID="GBP">0.0</ShippingServiceCost>
          <ShippingServicePriority>1</ShippingServicePriority>
          <ExpeditedService>false</ExpeditedService>
          <ShippingTimeMin>5</ShippingTimeMin>
          <ShippingTimeMax>10</ShippingTimeMax>
          <FreeShipping>true</FreeShipping>
        </ShippingServiceOptions>

        <InternationalShippingServiceOption>
          <ShippingService>UK_SellersStandardInternationalRate</ShippingService>
          <ShippingServiceCost currencyID="GBP">0.0</ShippingServiceCost>
          <ShippingServicePriority>1</ShippingServicePriority>
          <ShipToLocation>Americas</ShipToLocation>
          <ShipToLocation>CA</ShipToLocation>
          <ShipToLocation>GB</ShipToLocation>
          <ShipToLocation>AU</ShipToLocation>
          <ShipToLocation>Europe</ShipToLocation>
          <ShipToLocation>Asia</ShipToLocation>
          <ShipToLocation>CN</ShipToLocation>
          <ShipToLocation>MX</ShipToLocation>
          <ShipToLocation>DE</ShipToLocation>
          <ShipToLocation>JP</ShipToLocation>
          <ShipToLocation>BR</ShipToLocation>
          <ShipToLocation>FR</ShipToLocation>
          <ShipToLocation>RU</ShipToLocation>
        </InternationalShippingServiceOption>
        <ShippingType>Flat</ShippingType><SellerExcludeShipToLocationsPreference>true</SellerExcludeShipToLocationsPreference>
        </ShippingDetails>
        <ShipToLocations>Worldwide</ShipToLocations><RegionID>0</RegionID><ShippingTermsInDescription>True</ShippingTermsInDescription>
        <ConditionID>1000</ConditionID>
    </Item>
</AddFixedPriceItemRequest>

我收到上述请求的错误回复。

<?xml version="1.0" encoding="UTF-8"?>
<AddFixedPriceItemResponse xmlns="urn:ebay:apis:eBLBaseComponents">
  <Timestamp>2014-11-08T12:54:21.441Z</Timestamp>
  <Ack>Failure</Ack>
  <Errors>
    <ShortMessage>Invalid ShipToLocation.</ShortMessage>
    <LongMessage>Some of the ShipTo locations provided are not valid for this site. They have been dropped from your listing.</LongMessage>
    <ErrorCode>17520</ErrorCode>
    <SeverityCode>Warning</SeverityCode>
    <ErrorParameters ParamID="0">
      <Value>&lt;InternationalShippingServiceOptions&gt;</Value>
    </ErrorParameters>
    <ErrorClassification>RequestError</ErrorClassification>
  </Errors>
  <Version>891</Version>
  <Build>E891_UNI_API5_17051033_R1</Build>
</AddFixedPriceItemResponse>

现在我不知道该改变什么。

1 个答案:

答案 0 :(得分:1)

响应XML中的<LongMessage>标记内容是自解释的

  

提供的某些ShipTo位置对此站点无效。它们已从您的商家信息中删除。

查看请求XML

中的<ShipToLocation>标记
<ShipToLocation>Americas</ShipToLocation>
<ShipToLocation>CA</ShipToLocation>
<ShipToLocation>GB</ShipToLocation>
<ShipToLocation>AU</ShipToLocation>
<ShipToLocation>Europe</ShipToLocation>
<ShipToLocation>Asia</ShipToLocation>
<ShipToLocation>CN</ShipToLocation>
<ShipToLocation>MX</ShipToLocation>
<ShipToLocation>DE</ShipToLocation>
<ShipToLocation>JP</ShipToLocation>
<ShipToLocation>BR</ShipToLocation>
<ShipToLocation>FR</ShipToLocation>
<ShipToLocation>RU</ShipToLocation>

根据eBay API DocumentationBRRU无效。尝试从请求XML中删除<ShipToLocation>BR</ShipToLocation><ShipToLocation>RU</ShipToLocation>