SetInvoiceNumber

Definition

Use this call to set the invoice access key.

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

Parameters

FieldTypeDescription
ActionstringSetInvoiceNumber
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.
OrderItemIdlongIdentifier of the order item.
InvoiceNumberstringThe invoice number.

Code sample

# OrderItemUpdate cURL example
# to run, update Timestamp and recompute Signature
#
url = "https://api.sg.ali-lazada.com/"
get
data-urlencode Action=SetInvoiceNumber
data-urlencode OrderItemId=1
data-urlencode InvoiceNumber=12345678912345678912345678912345678912345678
data-urlencode Timestamp=2015-07-01T11:11+0000
data-urlencode [email protected]
data-urlencode Version=1.0
data-urlencode Signature=d4ff93cccb165295ed8357fe42082208b781a3b576bbb7d3fe7a624270b047b9
//init request with invoice number and order item id
SetInvoiceNumber request = new SetInvoiceNumber("12349989", 102612420L);
//fire request and check result
try {
  UpdateResponse response = request.execute();
  System.out.println("SetInvoiceNumber succeed?" + response.isSucceed());
} catch (LazadaException e) {
  System.out.println(e.getResponseStr());
}

Result sample

<?xml version="1.0" encoding="UTF-8"?>
<SuccessResponse>
  <Head>
    <RequestId/>
    <RequestAction>SetInvoiceNumber</RequestAction>
    <ResponseType/>
    <Timestamp>2015-06-04T09:35:37+0200</Timestamp>
  </Head>
  <Body>
      <OrderItemId>1</OrderItemId>
      <InvoiceNumber>INV-20</InvoiceNumber>
  </Body>
</SuccessResponse>

Documentation

πŸ“˜

Note

Invoice will be changed for all order items in the package.