Skip to main content
Published: January 16 2014, 11:55:00 AMUpdated: August 10 2022, 1:34:52 PM

How to add/update the <ShipmentTrackingDetails> using CompleteSale API call.?

 

After a seller has processed a transaction, they can use this call to leave feedback for the buyer, change the paid status of the item, or set the item's shipment tracking information.

Adding Shipment Tracking Information:

 

Note: For CompleteSale call both ItemID and TransactionID are mandatory input parameters.

 

  1. To add Shipment tracking information you can use CompleteSale call with the details in the <ShipmentTrackingDetails> container as follows.

<?xml version='1.0' encoding='utf-8'?>

<CompleteSaleRequest xmlns='urn:ebay:apis:eBLBaseComponents'>

  <WarningLevel>High</WarningLevel>

  <ItemID>110043584632</ItemID>

  <TransactionID>24727824001</TransactionID>

  <Paid>true</Paid>

  <Shipped>true</Shipped>

  <Shipment>

    <ShipmentTrackingDetails>

<ShipmentTrackingNumber>11111111112222222222333333333344

</ShipmentTrackingNumber>

<ShippingCarrierUsed>UPSGround</ShippingCarrierUsed>

    </ShipmentTrackingDetails>

    <ShippedTime>2010-02-18T11:17:47.432Z</ShippedTime>

  </Shipment>

  <RequesterCredentials>

<eBayAuthToken>****</eBayAuthToken>

  </RequesterCredentials>

</CompleteSaleRequest>

 

  1. To modify an existing Shipment tracking information you can use CompleteSale call with the same ItemID and TransactionID but with different <ShipmentTrackingDetails> container as follows.

<?xml version='1.0' encoding='utf-8'?>

<CompleteSaleRequest xmlns='urn:ebay:apis:eBLBaseComponents'>

  <WarningLevel>High</WarningLevel>

  <ItemID>110043584632</ItemID>

  <TransactionID>24727824001</TransactionID>

  <Paid>true</Paid>

  <Shipped>true</Shipped>

  <Shipment>

    <ShipmentTrackingDetails>

<ShipmentTrackingNumber>12345678901234567890123456789011

</ShipmentTrackingNumber>

<ShippingCarrierUsed>UPSGround</ShippingCarrierUsed>

    </ShipmentTrackingDetails>

    <ShippedTime>2010-02-18T11:17:47.432Z</ShippedTime>

  </Shipment>

  <RequesterCredentials>

<eBayAuthToken>****</eBayAuthToken>

  </RequesterCredentials>

</CompleteSaleRequest>

 

  1. If an item is Shipped in multiple shipments/packages you can use multiple <ShipmentTrackingDetails> container to specifty the tracking details.

<?xml version='1.0' encoding='utf-8'?>

<CompleteSaleRequest xmlns='urn:ebay:apis:eBLBaseComponents'>

  <WarningLevel>High</WarningLevel>

  <ItemID>110043584632</ItemID>

  <TransactionID>24727824001</TransactionID>

  <Paid>true</Paid>

  <Shipped>true</Shipped>

  <Shipment>

    <ShipmentTrackingDetails>

<ShipmentTrackingNumber>11223344556677889900112233445566

</ShipmentTrackingNumber>

<ShippingCarrierUsed>UPSGround</ShippingCarrierUsed>

    </ShipmentTrackingDetails>

    <ShipmentTrackingDetails>

<ShipmentTrackingNumber>12345678901234567890123456789011

</ShipmentTrackingNumber>

<ShippingCarrierUsed>UPSGround</ShippingCarrierUsed>

    </ShipmentTrackingDetails>

    <ShippedTime>2010-02-18T11:17:47.432Z</ShippedTime>

  </Shipment>

  <RequesterCredentials>

<eBayAuthToken>****</eBayAuthToken>

  </RequesterCredentials>

</CompleteSaleRequest>

 

  1. To add Shipment tracking information for a completed order you can use CompleteSale call with the <OrderID> and the <ShipmentTrackingDetails> container as shown the following sample. It is not necessary to inlude the <ItemID> and the <TransactionID> in the request (ItemID and TransactionID will be ignored if a call includes OrderID). The order as a whole will be marked as paid and shipped. 

<?xml version='1.0' encoding='utf-8'?>

<CompleteSaleRequest xmlns='urn:ebay:apis:eBLBaseComponents'>

  <WarningLevel>High</WarningLevel>

  <OrderID>71339897012</OrderID>

  <Paid>true</Paid>

  <Shipped>true</Shipped>

  <Shipment>

    <ShipmentTrackingDetails>

<ShipmentTrackingNumber>11111222223333344444555556666677

</ShipmentTrackingNumber>

<ShippingCarrierUsed>UPSGround</ShippingCarrierUsed>

    </ShipmentTrackingDetails>

    <ShippedTime>2010-02-18T11:17:47.432Z</ShippedTime>

  </Shipment>

  <RequesterCredentials>

<eBayAuthToken>****</eBayAuthToken>

  </RequesterCredentials>

</CompleteSaleRequest>


Note : For a combined order, you should always use <OrderID> as mentioned above. If you update <ShippedTime> for each OrderLineItemID individually, then GetOrders api might not show <ShippedTime> at order level.

 

  1. Remember that to update the shipment tracking details with multiple shipment information, you need to pass both the existing and the new Shipment Transaction Information in the same call.

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