RemoveProduct

Definition

Use this call to remove an existing product. You can remove some SKUs in one product, or remove all SKUs in one product. System supports a maximum number of 50 SellerSkus in one request.

Request URI: https://api.sellercenter.lazada.sg?Action=RemoveProduct

Parameters

FieldTypeDescription
ActionstringRemoveProduct
Name of the API that is to be called. Mandatory.
FormatstringThe response format, with XML as the default. Can be XML or JSON. Optional.
TimestampdatetimeThe current time in ISO8601 format (e.g., Timestamp=2016-04-01T10:00:00+02:00 for Berlin). Mandatory.
UserIDstringThe ID of the user making the call. Mandatory.
VersionstringThe API version against which this call is to be executed. The current version is "1.0". Mandatory.
SignaturestringThe cryptographic signature, authenticating the request. You must create this value by computing the SHA256 hash of the request, using the API key of the user specified in the UserID parameter. Mandatory.

Code sample

# RemoveProduct cURL example
# to run, update Timestamp and recompute Signature
#
url = "https://api.sg.ali-lazada.com/"
post
data-urlencode Action=RemoveProduct
data-urlencode Timestamp=2016-07-18T11:11+0000
data-urlencode [email protected]
data-urlencode Version=1.0
data-urlencode Signature=9ade00fb4b9ab9ed1b8a4d189f1a13e1029edc25dd963235480ec69226fd9f39

Request body

The following request body shows how to remove some SKUs that belong to an existing product.

<?xml version="1.0" encoding="UTF-8" ?>
<Request>
  <Product>
    <Skus>
      <Sku>
        <SellerSku>Apple-SG-Black-128G</SellerSku>
        <SellerSku>Apple-SG-Glod-64G</SellerSku>
        <SellerSku>Apple-SG-RoseGlod-128G</SellerSku>
      </Sku>
    </Skus>
  </Product>
</Request>
try {
  //construct request by seller sku list
  RemoveProduct request = new RemoveProduct(Arrays.asList("yucheng-test-sku-2017020305",
                                                          "yucheng-test-sku-2017020306"));
  ModifyProductResponse response = request.execute();
  System.out.println(String.format("RemoveProduct succeeded?%b",response.getBody()));
} catch (LazadaException e) {
  System.out.println(e.getResponseStr());
}

Business parameters

NameTypeDescription
SkussubsectionAn array contains at least one SKU. Mandatory
SellerSkustringA unique identifier for the product within the Seller Center instance that is to be added to the system. This identifier is usually freely assigned. Harmonized identifiers, such as UPC or EAN can be set via ProductId. Mandatory

Result sample

A success example is as follows.

<?xml version="1.0" encoding="UTF-8"?>
<SuccessResponse>
     <Head>
          <RequestId/>
          <RequestAction>RemoveProduct</RequestAction>
          <ResponseType>Product</ResponseType>
          <Timestamp>2016-07-07T20:12:14+0700</Timestamp>
     </Head>
     <Body/>
</SuccessResponse>
{
    "SuccessResponse": {
        "Head": {
            "RequestId": "",
            "RequestAction": "RemoveProduct",
            "ResponseType": "Product",
            "Timestamp": "2016-07-07T20:12:14+0700"
        },
        "Body": {
            "Warnings": []
        }
    }
}

Error messages

Error codeMessage
5E005: Invalid Request Format
6E006: Unexpected internal error
30E030: Empty Request
204E204: Too many SKU in one request
503E503: Remove product failed
1000Internal Application Error