question

$$anonymous$$ avatar image
0 Likes"
$$anonymous$$ Suspended asked

error: Item.ShippingDetails missing or false

Hi there

I get the above error by calling ApiCall.AddItem(item)

 

Here is my code for shipping:

 

'shipping services

Dim shipservice1 As New ShippingServiceOptionsType()

shipservice1.ShippingService = ShippingServiceCodeType.CH_StandardversandAPostPriority

shipservice1.ShippingServicePriority = 1

shipservice1.ShippingServiceCost = New AmountType()

shipservice1.ShippingServiceCost.currencyID = CurrencyCodeType.CHF

shipservice1.ShippingServiceCost.Value = 1.0

shipservice1.ShippingServiceAdditionalCost = New AmountType()

shipservice1.ShippingServiceAdditionalCost.currencyID = CurrencyCodeType.CHF

shipservice1.ShippingServiceAdditionalCost.Value = 1.0

item.ShippingDetails.ShippingServiceOptions.Add(shipservice1)

 

This is my log-file:

 

[10/23/2012 10:42:42 AM, Informational]
https://api.sandbox.ebay.com/wsapi?callname=AddItem&siteid=193&client=ne...

[10/23/2012 10:42:46 AM, Informational]
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <soap:Header>
    <RequesterCredentials xmlns="urn:ebay:apis:eBLBaseComponents">
      <eBayAuthToken>******</eBayAuthToken>
    </RequesterCredentials>
  </soap:Header>
  <soap:Body>
    <AddItemRequest xmlns="urn:ebay:apis:eBLBaseComponents">
      <MessageID>effe317e-536d-4d93-a3dc-2b8285c5f296</MessageID>
      <Version>779</Version>
      <Item>
        <Country>CH</Country>
        <Currency>CHF</Currency>
        <Description>some description about this item</Description>
        <ListingDuration>Days_3</ListingDuration>
        <ListingType>Chinese</ListingType>
        <Location>Zürich</Location>
        <PaymentMethods>PayPal</PaymentMethods>
        <PayPalEmailAddress>me@paypal.com</PayPalEmailAddress>
        <PrimaryCategory>
          <CategoryID>1433</CategoryID>
        </PrimaryCategory>
        <Quantity>1</Quantity>
        <RegionID>0</RegionID>
        <ShippingDetails>
          <ShippingServiceOptions>
            <ShippingService>572</ShippingService>
            <ShippingServiceCost currencyID="CHF">1</ShippingServiceCost>
            <ShippingServiceAdditionalCost currencyID="CHF">1</ShippingServiceAdditionalCost>
            <ShippingServicePriority>1</ShippingServicePriority>
          </ShippingServiceOptions>
          <ShippingType>Flat</ShippingType>
        </ShippingDetails>
        <StartPrice currencyID="CHF">12.25</StartPrice>
        <Title>Damenbluse</Title>
        <BestOfferDetails>
          <BestOfferEnabled>false</BestOfferEnabled>
        </BestOfferDetails>
        <PostalCode>95125</PostalCode>
        <DispatchTimeMax>1</DispatchTimeMax>
        <ReturnPolicy>
          <Refund>MoneyBack</Refund>
          <ReturnsWithinOption>Days_14</ReturnsWithinOption>
          <ReturnsAcceptedOption>ReturnsAccepted</ReturnsAcceptedOption>
          <ReturnsAccepted>True</ReturnsAccepted>
          <ShippingCostPaidByOption>Buyer</ShippingCostPaidByOption>
          <RestockingFeeValue>2.25</RestockingFeeValue>
        </ReturnPolicy>
        <ConditionID>3000</ConditionID>
      </Item>
    </AddItemRequest>
  </soap:Body>
</soap:Envelope>

<?xml version="1.0" encoding="UTF-8"?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <soapenv:Body>
    <AddItemResponse xmlns="urn:ebay:apis:eBLBaseComponents">
      <Timestamp>2012-10-23T08:42:48.195Z</Timestamp>
      <Ack>Failure</Ack>
      <CorrelationID>effe317e-536d-4d93-a3dc-2b8285c5f296</CorrelationID>
      <Errors>
        <ShortMessage>Ungültige Eingabedaten.</ShortMessage>
        <LongMessage>Eingabedaten für Tag &lt;Item.ShippingDetails&gt; sind ungültig oder fehlen. Bitte lesen Sie die API-Dokumentation.</LongMessage>
        <ErrorCode>37</ErrorCode>
        <SeverityCode>Error</SeverityCode>
        <ErrorParameters ParamID="0">
          <Value>Item.ShippingDetails</Value>
        </ErrorParameters>
        <ErrorClassification>RequestError</ErrorClassification>
      </Errors>
      <Version>795</Version>
      <Build>E795_INTL_BUNDLED_15461292_R1</Build>
    </AddItemResponse>
  </soapenv:Body>
</soapenv:Envelope>

[10/23/2012 10:42:46 AM, Error]
Eingabedaten für Tag <Item.ShippingDetails> sind ungültig oder fehlen. Bitte lesen Sie die API-Dokumentation.

 

Thanks for any help!

 

 

shippingdetails
10 |600

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
devanathan.developersupport@ebay.com avatar image
0 Likes"
devanathan.developersupport@ebay.com answered

Hi Stephanburn

The problem is that from your log the value for shipping service is not valid.
<ShippingService>572</ShippingService>

You need to call GeteBayDetials API call with DetailName set to 'ShippingServiceDetails' to and retrive a list of available shipping services. Again not all the shipping service returned in the response as valid to use in listing. You need to identify the ValidForSellingFlow tag in the response and use that shipping service in the AddItem family of calls.

<ShippingDetails>
   <ShippingServiceOptions>
        <ShippingService>CH_StandardDispatchAPost</ShippingService>
        <ShippingServiceCost currencyID="CHF">1</ShippingServiceCost>
        <ShippingServiceAdditionalCost currencyID="CHF">1</ShippingServiceAdditionalCost>
        <ShippingServicePriority>1</ShippingServicePriority>
   </ShippingServiceOptions>
   <ShippingType>Flat</ShippingType>
</ShippingDetails>

Have a nice day.

Best Regards,
Devanathan Sampath
eBay Developer Support
 

10 |600

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.