Changes since
the last release

com.ebay.sdk.call
Class CompleteSaleCall

java.lang.Object
  extended by com.ebay.sdk.ApiCall
      extended by com.ebay.sdk.call.CompleteSaleCall

public class CompleteSaleCall
extends ApiCall

Wrapper class of the CompleteSale call of eBay SOAP API.

Title: SOAP API wrapper library.

Description: Contains wrapper classes for eBay SOAP APIs.

Copyright: Copyright (c) 2009

Company: eBay Inc.


Input property: ItemID - Unique identifier for an eBay listing. An ItemID value can be paired up with a corresponding TransactionID value in a CompleteSale request to identify a single order line item. Alternatively, the OrderLineItemID value for the order line item can be used.

Unless an OrderLineItemID value is used to identify a single order line item, or the OrderID value is used to identify a single or multiple line item order, the ItemID/TransactionID pair must be specified. To perform an action on an entire multiple line item order, the OrderID field must be used. If an OrderID or OrderLineItemID value is specified, an ItemID/TransactionID pair will be ignored (if present in the same request).
Input property: TransactionID - Unique identifier for a sales transaction. A TransactionID identifier is created once there is a commitment to buy (bidder wins the auction, buyer clicks buy button, or buyer purchases item through PlaceOffer call). The TransactionID can be paired up with the corresponding ItemID value in a CompleteSale request to identify a single order line item. Alternatively, the OrderLineItemID value for the order line item can be used.

Unless an OrderLineItemID value is used to identify a single order line item, or the OrderID value is used to identify a single or multiple line item order, the ItemID/TransactionID pair must be specified. To perform an action on an entire multiple line item order, the OrderID field must be used. If an OrderID or OrderLineItemID value is specified, an ItemID/TransactionID pair will be ignored (if present in the same request).
Input property: FeedbackInfo - This container is used by the seller to leave feedback for the buyer for the order line item identified in the call request. The seller must include and specify all fields of this type, including the buyer's eBay User ID, the Feedback rating (a seller can only leave a buyer a 'Positive' rating), and a comment, which helps justify the Feedback rating. The eBay User ID must match the buyer who bought the order line item, or an error will occur. An error will also occur if Feedback has already been left for the buyer (either through API or the Web flow).

To determine if Feedback has already been left for an order line item, you can call GetFeedback, passing in the OrderLineItemID value in the call request.

Note: Feedback entries are submitted at the order line item level, so either an OrderLineItemID value or an ItemID/TransactionID pair should be specified to identify the order line item (and not an OrderLineItemID value). To leave Feedback for all line items in a multiple line item order, the seller would need a separate CompleteSale request for each order line item.
Input property: Shipped - The seller includes and sets this field to true if the order or order line item has been shipped. If the call is successful, the order line item(s) are marked as Shipped in My eBay.

If the seller includes and sets this field to false, the order or order line item are marked (or remain) as 'Not Shipped' in eBay's system.

If this field is not included, the shipped status of the order or order line item remain unchanged in My eBay.

If shipment tracking information is provided for an order or order line item through the Shipment container in the same request, the Shipped status is set to true automatically, and the Shipped field is not necessary.
Input property: Paid - The seller includes and sets this field to true if the order has been paid for by the buyer. If the call is successful, the order line item(s) are marked as 'Paid' in eBay's system.

If the seller includes and sets this field to false, the order line item(s) are marked (or remain) as 'Not Paid' in eBay's system.

If this field is not included, the paid status of the order line item(s) remain unchanged in eBay's system.
Input property: ListingType - Note: DO NOT USE THIS FIELD. Previously, this field's only purpose was to classify the order to be updated as a Half.com order. However, since the Half.com site has been shut down, this field is no longer applicable.
Input property: Shipment - Container consisting of shipment tracking information, shipped time, and an optional text field to provide additional details to the buyer. Setting the tracking number and shipping carrier automatically marks the order line item as shipped and the Shipped field is not necessary.

If you supply ShipmentTrackingNumber, you must also supply ShippingCarrierUsed; otherwise you will get an error.

To modify the shipping tracking number and/or shipping carrier, supply the new number in the ShipmentTrackingNumber field or supply the value for ShippingCarrierUsed, or both. The old number and carrier are deleted and the new ones are added.

To simply delete the current tracking details altogether, supply empty Shipment tags.

Note: Top-Rated sellers must have a record of uploading shipment tracking information (through site or through API) for at least 95 percent of their order line items (purchased by U.S. buyers) to keep their status as Top-Rated sellers. For more information on the requirements to becoming a Top-Rated Seller, see the Becoming a Top-Rated Seller and qualifying for Top-Rated Plus customer support page.

Input property: OrderID - A unique identifier for an eBay order. An OrderID value should only be used in a CompleteSale call for a single line item order. For a multiple line item order, the OrderLineItemID or ItemID/TransactionID pair must be used to identify an order line item within the order.

OrderID overrides an OrderLineItemID or ItemID/TransactionID pair if these fields are also specified in the same request.

Note: As of June 2019, eBay has changed the format of order identifier values. The new format is a non-parsable string, globally unique across all eBay marketplaces, and consistent for both single line item and multiple line item orders. Unlike in the past, instead of just being known and exposed to the seller, these unique order identifiers will also be known and used/referenced by the buyer and eBay customer support.

For developers and sellers who are already integrated with the Trading API's order management calls, this change shouldn't impact your integration unless you parse the existing order identifiers (e.g., OrderID or OrderLineItemID), or otherwise infer meaning from the format (e.g., differentiating between a single line item order versus a multiple line item order). Because we realize that some integrations may have logic that is dependent upon the old identifier format, eBay is rolling out this Trading API change with version control to support a transition period of approximately 9 months before applications must switch to the new format completely.

During the transition period, for developers/sellers using a Trading WSDL older than Version 1113, they can use the X-EBAY-API-COMPATIBILITY-LEVEL HTTP header in API calls to control whether the new or old OrderID format is returned in call response payloads. To get the new OrderID format, the value of the X-EBAY-API-COMPATIBILITY-LEVEL HTTP header must be set to 1113. During the transition period and even after, the new and old OrderID formats will still be supported/accepted in all Trading API call request payloads. After the transition period (which will be announced), only the new OrderID format will be returned in all Trading API call response payloads, regardless of the Trading WSDL version used or specified compatibility level.

Note: For sellers integrated with the new order ID format, please note that the identifier for an order will change as it goes from unpaid to paid status. Sellers can check to see if an order has been paid by looking for a value of 'Complete' in the CheckoutStatus.Status field in the response of GetOrders or GetOrderTransactions call, or in the Status.CompleteStatus field in the response of GetItemTransactions or GetSellerTransactions call. Sellers should not fulfill orders until buyer has made payment. When using a CompleteSale call, either of these order IDs (paid or unpaid status) can be used to update an order. Similarly, either of these order IDs (paid or unpaid status) can be used in GetOrders or GetOrderTransactions call to retrieve specific order(s).
Input property: OrderLineItemID - A unique identifier for an eBay order line item. OrderLineItemID values are returned (at the order line item level) in Trading API's order management calls. This identifier is created once there is a commitment to buy (bidder wins the auction, buyer clicks buy button, or buyer purchases item through PlaceOffer call). An OrderLineItemID value can be used in a CompleteSale request to identify a line item within an order. Alternatively, an ItemID/TransactionID pair can also be used to identify a line item.

Unless an ItemID/TransactionID pair is used to identify an order line item, or an OrderID value is used to identify an order, the OrderLineItemID must be specified. If OrderLineItemID is specified, the ItemID/TransactionID pair are ignored if present in the same request.

Version:
1.0
Author:
Ron Murphy

Field Summary
 
Fields inherited from class com.ebay.sdk.ApiCall
apiException, sendReqListeners
 
Constructor Summary
CompleteSaleCall()
          Constructor.
CompleteSaleCall(ApiContext apiContext)
          Constructor.
 
Method Summary
 void completeSale()
          Enables a seller to perform various tasks with a single or multiple line item order.
 FeedbackInfoType getFeedbackInfo()
          Gets the CompleteSaleRequestType.feedbackInfo.
 java.lang.String getItemID()
          Gets the CompleteSaleRequestType.itemID.
 ListingTypeCodeType getListingType()
          Gets the CompleteSaleRequestType.listingType.
 java.lang.String getOrderID()
          Gets the CompleteSaleRequestType.orderID.
 java.lang.String getOrderLineItemID()
          Gets the CompleteSaleRequestType.orderLineItemID.
 java.lang.Boolean getPaid()
          Gets the CompleteSaleRequestType.paid.
 ShipmentType getShipment()
          Gets the CompleteSaleRequestType.shipment.
 java.lang.Boolean getShipped()
          Gets the CompleteSaleRequestType.shipped.
 java.lang.String getTransactionID()
          Gets the CompleteSaleRequestType.transactionID.
 void setFeedbackInfo(FeedbackInfoType feedbackInfo)
          Sets the CompleteSaleRequestType.feedbackInfo.
 void setItemID(java.lang.String itemID)
          Sets the CompleteSaleRequestType.itemID.
 void setListingType(ListingTypeCodeType listingType)
          Sets the CompleteSaleRequestType.listingType.
 void setOrderID(java.lang.String orderID)
          Sets the CompleteSaleRequestType.orderID.
 void setOrderLineItemID(java.lang.String orderLineItemID)
          Sets the CompleteSaleRequestType.orderLineItemID.
 void setPaid(java.lang.Boolean paid)
          Sets the CompleteSaleRequestType.paid.
 void setShipment(ShipmentType shipment)
          Sets the CompleteSaleRequestType.shipment.
 void setShipped(java.lang.Boolean shipped)
          Sets the CompleteSaleRequestType.shipped.
 void setTransactionID(java.lang.String transactionID)
          Sets the CompleteSaleRequestType.transactionID.
 
Methods inherited from class com.ebay.sdk.ApiCall
addDetailLevel, addSendRequestListener, execute, executeByApiName, getApiContext, getApiException, getBotBlock, getCallRetry, getDetailLevel, getEnableCompression, getEndUserIP, getErrorHandling, getInvocationID, getMessageID, getOutputSelector, getRequestXml, getResponseObject, getResponseXml, getSite, getWarningLevel, hasError, hasWarning, isEnableoAuthTokenHTTPHeader, removeSendRequestListener, setApiContext, setBotBlock, setCallRetry, setDetailLevel, setEnableCompression, setEnableoAuthTokenHTTPHeader, setEndUserIP, setErrorHandling, setInvocationID, setMessageID, setOutputSelector, setSite, setWarningLevel
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CompleteSaleCall

public CompleteSaleCall()
Constructor.


CompleteSaleCall

public CompleteSaleCall(ApiContext apiContext)
Constructor.

Parameters:
apiContext - The ApiContext object to be used to make the call.
Method Detail

completeSale

public void completeSale()
                  throws ApiException,
                         SdkException,
                         java.lang.Exception
Enables a seller to perform various tasks with a single or multiple line item order. Tasks available with this call include marking the order as paid, marking the order as shipped, providing shipment tracking details to the buyer, and leaving feedback for the buyer.

Throws:
ApiException
SdkException
java.lang.Exception

getFeedbackInfo

public FeedbackInfoType getFeedbackInfo()
Gets the CompleteSaleRequestType.feedbackInfo.

Returns:
FeedbackInfoType

setFeedbackInfo

public void setFeedbackInfo(FeedbackInfoType feedbackInfo)
Sets the CompleteSaleRequestType.feedbackInfo.

Parameters:
feedbackInfo - FeedbackInfoType

getItemID

public java.lang.String getItemID()
Gets the CompleteSaleRequestType.itemID.

Returns:
String

setItemID

public void setItemID(java.lang.String itemID)
Sets the CompleteSaleRequestType.itemID.

Parameters:
itemID - String

getListingType

public ListingTypeCodeType getListingType()
Gets the CompleteSaleRequestType.listingType.

Returns:
ListingTypeCodeType

setListingType

public void setListingType(ListingTypeCodeType listingType)
Sets the CompleteSaleRequestType.listingType.

Parameters:
listingType - ListingTypeCodeType

getOrderID

public java.lang.String getOrderID()
Gets the CompleteSaleRequestType.orderID.

Returns:
String

setOrderID

public void setOrderID(java.lang.String orderID)
Sets the CompleteSaleRequestType.orderID.

Parameters:
orderID - String

getOrderLineItemID

public java.lang.String getOrderLineItemID()
Gets the CompleteSaleRequestType.orderLineItemID.

Returns:
String

setOrderLineItemID

public void setOrderLineItemID(java.lang.String orderLineItemID)
Sets the CompleteSaleRequestType.orderLineItemID.

Parameters:
orderLineItemID - String

getPaid

public java.lang.Boolean getPaid()
Gets the CompleteSaleRequestType.paid.

Returns:
Boolean

setPaid

public void setPaid(java.lang.Boolean paid)
Sets the CompleteSaleRequestType.paid.

Parameters:
paid - Boolean

getShipment

public ShipmentType getShipment()
Gets the CompleteSaleRequestType.shipment.

Returns:
ShipmentType

setShipment

public void setShipment(ShipmentType shipment)
Sets the CompleteSaleRequestType.shipment.

Parameters:
shipment - ShipmentType

getShipped

public java.lang.Boolean getShipped()
Gets the CompleteSaleRequestType.shipped.

Returns:
Boolean

setShipped

public void setShipped(java.lang.Boolean shipped)
Sets the CompleteSaleRequestType.shipped.

Parameters:
shipped - Boolean

getTransactionID

public java.lang.String getTransactionID()
Gets the CompleteSaleRequestType.transactionID.

Returns:
String

setTransactionID

public void setTransactionID(java.lang.String transactionID)
Sets the CompleteSaleRequestType.transactionID.

Parameters:
transactionID - String

Changes since
the last release

The information contained in this document is proprietary and confidential. Use of this information and the eBay API requires a Non-Disclosure Agreement (NDA) between the user and eBay Inc. For information regarding a qualifying NDA, contact Developer Relations: developer-relations@ebay.com
© 2004-2009 eBay Inc. All rights reserved.