Skip to main content
Published: February 02 2007, 3:14:00 PMUpdated: August 08 2022, 4:03:38 AM

I am calling getCategories api as below

  <?xml version="1.0" encoding="utf-8" ?>
     <getCategoriesRequest xmlns="urn:ebay:apis:eBLBaseComponents">
       <RequesterCredentials>
                  <eBayAuthToken>xxx</eBayAuthToken>
            </RequesterCredentials>
        <DetailLevel>ReturnAll</DetailLevel>
       <Item>
                    <Site>0</Site>
            </Item>
                <ViewAllNodes>1</ViewAllNodes>
                <Version>487</Version>
        </getCategoriesRequest>
Which returns error 20170:
 
  <?xml version="1.0" encoding="UTF-8" ?>
   <GetCategoriesResponsexmlns="urn:ebay:apis:eBLBaseComponents">
      <Timestamp>2007-02-02T22:02:05.968Z</Timestamp>
      <Ack>Failure</Ack>
    <Errors>
            <ShortMessage>Schema XML request error.</ShortMessage>
            <LongMessage>Schema XML request error: SimpleDeserializer encountered a child element, which is NOT expected, in something it was trying to deserialize..</LongMessage>
           <ErrorCode>20170</ErrorCode>
           <SeverityCode>Error</SeverityCode>
     <ErrorParameters ParamID="0">
               <Value>SimpleDeserializer encountered a child element, which is NOT expected, in something it was trying to deserialize.</Value>
       </ErrorParameters>
           <ErrorClassification>RequestError</ErrorClassification>
     </Errors>
         <Version>499</Version>
         <Build>e499_core_Bundled_4177367_R1</Build>
  </GetCategoriesResponse>
What is going on? How do I fix the problem?

Detailed Description

 CAUSE

   The possible cause for this error is:
   --- The given root element in your request xml document does not match any Element Declarations in eBay Schema.
  

RESOLUTION 

     To work around this problem, check of the following suggestion.

      --- Check the root element in your API request xml document  in this line and make sure the element name marked blue can be found in API document or eBay Schema
      <GetCategoriesRequest xmlns="urn:ebay:apis:eBLBaseComponents">

     Keep in mind that XML elements are case sensitive. The element <getCategoriesRequest> is different from the element <GetCategoriesRequest>. Opening and closing elements are required to be written with same case.


Additional Resources

  Documentation: eBay Schema 

 

How well did this answer your question?
Answers others found helpful