question

d.b.metals avatar image
0 Likes"
d.b.metals asked

I can't seem to run a call correctly (GetBestOffers)

I'm trying to make a call for all of the current active offers sellers have sent to me on my eBay account.


I read in the API documentation that if I don't include and itemID that it should return all of them. The problem is that I don't seem to understand how to run an api call correctly.


I took out my AuthToken because I am not sure what to put there. I have several codes but I don't know what to put there. Regardless of whatever I put there though, I keep getting the same output (see beneath code)


import requests

x = """<?xml version="1.0" encoding="utf-8"?>
<GetBestOffersRequest xmlns="urn:ebay:apis:eBLBaseComponents">
  <RequesterCredentials>
    <eBayAuthToken></eBayAuthToken>
  </RequesterCredentials>
  <ItemID></ItemID>
  <DetailLevel>ReturnAll</DetailLevel>
  <BestOfferStatus>All</BestOfferStatus>
</GetBestOffersRequest>"""

hi = requests.post("https://api.ebay.com/ws/api.dll", data=x)


print(hi)


Output.

"

<?xml version="1.0" encoding="UTF-8" ?><GeteBayOfficialTimeResponse xmlns="urn:ebay:apis:eBLBaseComponents"><Timestamp>2020-12-23 03:24:23</Timestamp><Ack>Failure</Ack><Errors><ShortMessage>Unsupported API call.</ShortMessage><LongMessage>The API call "GeteBayOfficialTime" is invalid or not supported in this release.</LongMessage><ErrorCode>2</ErrorCode><SeverityCode>Error</SeverityCode><ErrorClassification>RequestError</ErrorClassification></Errors><Build>19110890</Build></GeteBayOfficialTimeResponse>'

"

api callxmloffers
10 |600 characters needed characters left characters exceeded

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

1 Answer

· Write an Answer
sagar_developersupport avatar image
0 Likes"
sagar_developersupport answered

Hi @d.b.metals,

Please remove <ItemID></ItemID> container from the request and try the call.


<?xml version="1.0" encoding="utf-8"?>
<GetBestOffersRequest xmlns="urn:ebay:apis:eBLBaseComponents">
<DetailLevel>ReturnAll</DetailLevel>
<BestOfferStatus>All</BestOfferStatus>
</GetBestOffersRequest>

Note: GetBestOffers request requires User access token.

Best Regards ,
eBay Developer Support

· 1
10 |600 characters needed characters left characters exceeded

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

I made that adjustment and I have my token in there, figured I shouldn't post it.

However, I'm getting the same output.

0 Likes 0 ·

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.