为什么我可以在调用eBay API时看到任何列表?
我已经设法进行了身份验证并调用eBay API,但是当我尝试获取卖方帐户项目的列表时,我会得到一个空的项目array对象。我使用用于调用GetSellerList的同一日期范围来调用Analytics API,并返回流量和转换率,因此我知道此帐户在此日期范围内列出了一些项目。
这是请求的正文:
<?xml version="1.0" encoding="utf-8"?>
<GetSellerListRequest xmlns="urn:ebay:apis:eBLBaseComponents">
<RequesterCredentials>
<eBayAuthToken>access_token</eBayAuthToken>
</RequesterCredentials>
<!-- Call-specific Input Fields -->
<AdminEndedItemsOnly>False</AdminEndedItemsOnly>
<GranularityLevel>Coarse</GranularityLevel>
<IncludeVariations>True</IncludeVariations>
<IncludeWatchCount>True</IncludeWatchCount>
<Pagination> PaginationType
<EntriesPerPage>100</EntriesPerPage>
<PageNumber>1</PageNumber>
</Pagination>
<Sort>1</Sort>
<StartTimeFrom>2022-04-15T19:09:02.768Z</StartTimeFrom>
<StartTimeTo>2022-04-21T16:09:02.768Z</StartTimeTo>
<!-- Standard Input Fields -->
<DetailLevel>ReturnAll</DetailLevel>
<!-- ... more DetailLevel values allowed here ... -->
<ErrorLanguage> string </ErrorLanguage>
<MessageID> string </MessageID>
<WarningLevel>Low</WarningLevel>
</GetSellerListRequest>
以下是标题:
X-EBAY-API-APP-NAME: app_name
X-EBAY-API-CALL-NAME: GetSellerList
X-EBAY-API-REQUEST-ENCODING: XML
X-EBAY-API-SITEID: 0
X-EBAY-API-DEV-NAME: some_code
X-EBAY-API-CERT-NAME: some code
X-EBAY-API-COMPATIBILITY-LEVEL: 825
Content-Type: text/xml
和URL: https:// https:// api .ebay.com/ws/api.dll
方法:获取。
我无法弄清楚为什么我不在没有项目的情况下得到以下响应:
<?xml version="1.0" encoding="UTF-8"?>
<GetSellerListResponse xmlns="urn:ebay:apis:eBLBaseComponents">
<Timestamp>2022-04-21T14:44:03.680Z</Timestamp>
<Ack>Success</Ack>
<CorrelationID> string </CorrelationID>
<Version>1173</Version>
<Build>E1173_CORE_APISELLING_19187371_R1</Build>
<ItemArray/>
</GetSellerListResponse>
任何帮助将不胜感激。
I have managed to authenticate and to call the ebay api, but when I try to get a list of my seller account's items I get an empty ItemArray object. I have called the analytics api using the same date range I use to call GetSellerList, and it returns traffic and conversion rates, so I know there were some items listed by this account for this date range.
Here is the body of the request:
<?xml version="1.0" encoding="utf-8"?>
<GetSellerListRequest xmlns="urn:ebay:apis:eBLBaseComponents">
<RequesterCredentials>
<eBayAuthToken>access_token</eBayAuthToken>
</RequesterCredentials>
<!-- Call-specific Input Fields -->
<AdminEndedItemsOnly>False</AdminEndedItemsOnly>
<GranularityLevel>Coarse</GranularityLevel>
<IncludeVariations>True</IncludeVariations>
<IncludeWatchCount>True</IncludeWatchCount>
<Pagination> PaginationType
<EntriesPerPage>100</EntriesPerPage>
<PageNumber>1</PageNumber>
</Pagination>
<Sort>1</Sort>
<StartTimeFrom>2022-04-15T19:09:02.768Z</StartTimeFrom>
<StartTimeTo>2022-04-21T16:09:02.768Z</StartTimeTo>
<!-- Standard Input Fields -->
<DetailLevel>ReturnAll</DetailLevel>
<!-- ... more DetailLevel values allowed here ... -->
<ErrorLanguage> string </ErrorLanguage>
<MessageID> string </MessageID>
<WarningLevel>Low</WarningLevel>
</GetSellerListRequest>
Here are the headers:
X-EBAY-API-APP-NAME: app_name
X-EBAY-API-CALL-NAME: GetSellerList
X-EBAY-API-REQUEST-ENCODING: XML
X-EBAY-API-SITEID: 0
X-EBAY-API-DEV-NAME: some_code
X-EBAY-API-CERT-NAME: some code
X-EBAY-API-COMPATIBILITY-LEVEL: 825
Content-Type: text/xml
And the url : https://api.ebay.com/ws/api.dll
method: GET.
I can't figure out why I keep getting the following response with no items:
<?xml version="1.0" encoding="UTF-8"?>
<GetSellerListResponse xmlns="urn:ebay:apis:eBLBaseComponents">
<Timestamp>2022-04-21T14:44:03.680Z</Timestamp>
<Ack>Success</Ack>
<CorrelationID> string </CorrelationID>
<Version>1173</Version>
<Build>E1173_CORE_APISELLING_19187371_R1</Build>
<ItemArray/>
</GetSellerListResponse>
Any help would be much appreciated.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
方法必须是发布。
Compat Level 825也许不再支持:在任何情况下,您都必须使用最新的1247。
尝试在此旁边删除“ starttime”和“ starttimeto”
,每个月,ebay ebay Decommissions ereversions eris(Old)交易APIS:
我认为开始使用Trading API开发新应用是不明智的:最好使用新的API。
Method has to be POST.
Compat level 825 perhaps is not supported anymore: In anycase you have to use latest that should be 1247.
Try removing 'StartTimeFrom' and 'StartTimeTo'
Beside this, every month eBay decommissions some (old) Trading APIs:
I think it's not wise to start developing new apps using Trading APIs: better to use new APIs.