Alipay+ DocsAlipay+ Docs

Overview

When a consumer pays for goods from a cross-border e-commerce merchant (hereinafter referred to as "the merchant"), for legal or compliance reasons of the country or region where the consumer locates, the merchant might need to declare the payment at customs. Thus, such merchants need to obtain the capability of customs declaration, so as to avoid the failure in customs clearance of shipped products and the risk of product-related disputes between consumers and merchants.

Within the scope of Alipay+'s business, only for payments that are processed by the AlipayCN wallet and for products that are to be exported to mainland China, customs declarations are required. According to the requirements of China Customs (hereinafter referred to as "the Customs"), four electronic documents need to be provided for customs declaration. The table below lists the document details and who needs to provide these documents.

Item

Detail

Provider

Transaction order

Contains the buyer's information, the order ID, the payment ID, the logistics ID, the goods information, and so on.

Merchant

Payment order

Contains the payer's information, the order ID, the payment amount, the payment ID, and so on.

AlipayCN

Logistics order

Contains the shipping ID, the order ID, the goods information, the consignee's information, and so on.

Logistics enterprise

Import list

Contains the order ID, the payment ID, the logistics ID, the buyer's information, the goods information, and so on.

Merchant

For more information about the technical specifications of these documents, refer to Announcement No. 113 of the General Administration of Customs.

To help Acquiring Service Partners (ACQPs) and their merchants transfer the payment order to AlipayCN, Alipay+ provides the following two APIs:

  • declare: This API is used by the ACQP to initiate a declaration request to Alipay+. Alipay+ then forwards the declaration request to AlipayCN.
  • inquiryDeclarationRequests: This API is used by the ACQP to inquire about the check results of declared payments at the Customs.

This topic introduces the overall workflow of the customs declaration and guides you through how to use Alipay+ APIs to execute operations in the workflow.

Workflow

The following figure illustrates how the merchants, the ACQP, Alipay+/AlipayCN, and the Customs coordinate to implement customs declaration:

image

Figure 1. Customs declaration flow

The customs declaration flow consists of the following step:

  1. The consumer places an order on the merchant's website or app and pays with the AlipayCN wallet. (Step 1)
  2. The merchant sends the following electronic documents to the Customs by taking different actions:
    • Transaction order: The merchant directly sends the transaction order to the Customs. (Step 2.1)
    • Payment order:
      • The merchant initiates a declaration request to the ACQP. (Step 2.2.1)
      • The ACQP initiates a declaration request to Alipay+ by calling the declare API. (Step 2.2.2)
      • Alipay+ encapsulates the payment order and forwards it to AlipayCN. AlipayCN then sends the payment order to the Customs. (Step 2.2.3)
    • Logistics order:
      • The merchant initiates a declaration request to the logistics enterprise. (Step 2.3.1)
      • The logistics enterprise sends the logistic order to the Customs. (Step 2.3.2)
  1. After sending the three documents above to the Customs, the merchant sends the import list to the Customs. (Step 3)
  2. The Customs logically compares the transaction order, the payment order, and the logistics order with the import list, and decides whether the declaration succeeds. For more information, see Customs check logic. (Step 4)

To track the status of declared payments, the ACQP can regularly call the inquireDeclarationRequests API and forward the response from Alipay+ to the merchant.

  1. The Customs completes the customs clearance. (Step 5)
  2. The logistics enterprise delivers the goods to the consumer. (Step 6)

API interaction

The following diagram shows the interaction between the ACQP, Alipay+, and AlipayCN when using Alipay+ APIs:

image

Figure 2. API interaction

The interaction consists of the following parts:

  1. declare

1.1 The ACQP calls the declare API to initiate a declaration request to Alipay+.

1.2 Alipay+ initiates a declaration request to AlipayCN.

1.3 AlipayCN returns the processing result to Alipay+.

1.4 Alipay+ returns the processing result to the ACQP in the response body of the declare API.

  1. inquireDeclarationRequests

2.1 The ACQP calls the inquireDeclarationRequests API to inquire about the status of declared payments from Alipay+.

2.2 Alipay+ inquires about the status of declared payments from AlipayCN.

2.3 AlipayCN returns the status of declared payments to Alipay+.

2.4 Alipay+ returns the status of declared payments to the ACQP in the response body of the inquireDeclarationRequests API.

Related links

  • To get started with the Alipay+ customs declaration service, make sure all the prerequisites are met. For more information, see Prerequisites.
  • To implement Alipay+ APIs regarding customs declaration, read the following topics: