问题
I want to get all orders from my ebay seller account. Using the GetOrders
call works fine.
All of my orders are marked as ACTIVE
or COMPLETE
depending on the status of the order. But when I mark them as shipped (through API or on the website) the orders stay ACTIVE
or COMPLETE
after re-crawling. I expected the order status' to be SHIPPED
.
- I use the eBay Java SDK Version 797
- every API call returns "Success"
How do I figure out if an order is marked as shipped?
Does this depend on the country?
- I'm using the German eBay sandbox ( the Webgui is a german/english mix ;) )
- I'm using the .com API-URLs
Here's my code:
GetOrdersCall call = new GetOrdersCall(context);
DetailLevelCodeType[] detailLevels = new DetailLevelCodeType[]{
DetailLevelCodeType.RETURN_ALL
};
call.setDetailLevel(detailLevels);
call.setOrderRole(TradingRoleCodeType.SELLER);
call.setNumberOfDays(30);
OrderType[] orders;
try {
orders = call.getOrders();
for(OrderType order : orders)
System.out.println(order.getOrderStatus().name());
} catch (Exception e) {}
System.out
never prints SHIPPED
回答1:
You could either check the field
<ShippedTime>2013-02-22T13:22:04.000Z</ShippedTime>
or you can use the information from the transaction array:
<TransactionArray>
<Transaction>
<Buyer>
<Email>test.test.test</Email>
</Buyer>
<ShippingDetails>
<SellingManagerSalesRecordNumber>1234</SellingManagerSalesRecordNumber>
<ShipmentTrackingDetails>
<ShippingCarrierUsed>DHL</ShippingCarrierUsed>
<ShipmentTrackingNumber>123456798</ShipmentTrackingNumber>
</ShipmentTrackingDetails>
</ShippingDetails>
...
来源:https://stackoverflow.com/questions/14844391/ebay-trading-api-getorders-check-if-order-is-marked-as-shipped