# Transaction Detail Report

## Overview

Transaction Detail Reports are provided by Alipay+ to the MPPs and include all the transaction details to be cleared in a clearing cycle.

Specifically:

-   Only transactions to be settled, including successful payments and refunds, are included in the Transaction Detail Report.
-   Only the transactions that are completed within the clearing cycle are included in the Transaction Detail Report. The transaction completion time is specified by the _transactionTime_ parameter.

For every clearing cycle, a Transaction Detail Report is created with other reports in the same clearing cycle, such as the Transaction Summary Report and the Fee Report. The reports are uploaded to a specific directory on the SFTP server. The MPP can download and use them for reconciliation.

### File location and naming convention

The Transaction Detail Report is a UTF-8 encoded text file.

In the production environment, the file is saved by default in the directory `/v1/settlements/clearing/<participantId>/<date>`. And in the sandbox environment, the file is saved in the directory `/sandbox/settlements/clearing/<participantId>/<date>`.

The default file name is `transactionItems_<participantId>_<settlementCurrency>_<clearingBatchId>_<participantAgreementId>_<seq>.csv`. For the detailed information of each field in the file name, refer to the following table:

| **Field Name** | **Details** |
| --- | --- |
| participantId | The unique ID that Alipay+ assigns to the MPP, also known as the "Partner ID". This field identifies the receiver of the file. |
| date | The date when the report is generated, not the date of the transactions. For example, a report with a date of 20220319 is generated on 2022.03.19. |
| settlementCurrency | The currency that is used in the settlement, as agreed in the contract. This is the same currency as the one that is stated in the Settlement Report. |
| ClearingBatchId | Clearing cycle index, used to indicate a unique clearing cycle. A clearing cycle is from 00:00 to 23:59:59, UTC+8. |
| participantAgreementId | The unique ID that is assigned by Alipay+ to identify a settlement agreement between Alipay+ and the MPP. The value of the _participantAgreementId_ parameter is determined by the value of the _participantId_ parameter and the settlement currency used by the MPP. The ID represents the fund flow when MPP performs settlement to Alipay+. |
| seq | The sequence number used as a file index. The field is used when multiple files exist in the clearing cycle. The file index is ordered in the range of `000-999`. |

### Report structure

The Transaction Detail Report consists of two parts:

-   Summary section, which displays the summary information about the transactions, for example, the total number of transactions and net total amount.
-   Detail section, which displays the transaction details, for example, transaction data details.

If no transaction exists in a clearing cycle, the Transaction Detail Report is still generated. The report summary section displays 0 total count and 0 total amount, and the report detail section displays no transaction details.

## Structure

### Summary section

| **No.** | **Parameter** | **Description** |
| --- | --- | --- |
| 1 | totalCount | **Required** String The total number of items in the Transaction Detail Report file. |
| 2 | fundDirection | **Required** String Fund direction. Valid values are: - `CREDIT`: specifies the fund direction that is from Alipay+ to the MPP. - `DEBIT`: specifies the fund direction that is from the MPP to Alipay+. |
| 3 | settlementCurrency | **Required** String (3) The currency of the net settlement amount. The value is specified by using the 3-character [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) currency code. |
| 4 | netSettlementAmountValue | **Required** Integer The gross settlement amount of all the transactions, excluding the fee settlement amount. The value is provided in the smallest unit of the corresponding currency. For example, if the currency is USD and the amount is $1.00, the value of this parameter is 100; if the currency is JPY and the amount is ￥1, the value of this parameter is 1. Value range: 0 - unlimited. |
| 5 | transactionCurrency | **Optional** String (3) The currency of the net transaction amount. The currency here is the same as the currency of the transactions in the clearing cycle, which is the value of the _payToAmount.currency_ parameter in the **pay**/**userInitiatedPay** API. The value is specified by using the 3-character [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) currency code. > **Note**: This parameter is empty when no transaction occurs in the clearing cycle or multiple transaction currencies are involved in the clearing cycle. |
| 6 | netTransactionAmountValue | **Optional** Integer The gross transaction amount of all the transactions, excluding the fee amount. The value is provided in the smallest unit of the corresponding currency. For example, if the currency is USD and the amount is $1.00, the value of this parameter is 100; if the currency is JPY and the amount is ￥1, the value of this parameter is 1. Value range: 0 - unlimited. > **Note**: This parameter is empty when no transaction occurs in the clearing cycle or multiple transaction currencies are involved in the clearing cycle. |
| 7 | extendInfo | **Optional** String (2048) The extended information. |

### Detail section

| **No.** | **Parameter** | **Description** |
| --- | --- | --- |
| 1 | clearingBatchId | **Required** String (32) The unique ID that is assigned by Alipay+ to identify a clearing cycle. A clearing cycle is from 00:00 to 23:59:59, UTC+8. |
| 2 | participantId | **Required** String (64) The unique ID that is assigned by Alipay+ to identify an MPP. |
| 3 | counterParticipantId | **Required** String (64) The unique ID that is assigned by Alipay+ to identify an Acquiring Service Provider. |
| 4 | transactionRequestId | **Required** String (64) The unique ID that is assigned by Alipay+ to identify a transaction. - For a payment, the value of this parameter is identical to that of the _paymentRequestId_ parameter_._ - For a refund, the value of this parameter is identical to that of the _refundRequestId_ parameter. |
| 5 | originalTransactionRequestId | **Optional** String (64) An identifier for the original payment order of a refund. - For a payment, the value of this parameter is empty. - For a refund, the value of this parameter is identical to that of the _paymentRequestId_ parameter. |
| 6 | transactionType | **Required** String The transaction type. Valid values are: - `PAYMENT`: Payment - `REFUND`: Refund |
| 7 | transactionTime | **Required** Datetime The date and time when the transaction reaches a final state of success or failure. The transaction time can be obtained from the _paymentTime_ parameter in the **notifyPayment** API or the **inquiryPayment** API, or the _refundTime_ parameter in the **refund** API. The value follows the [ISO 8601 standard](https://www.iso.org/iso-8601-date-and-time-format.html). |
| 8 | fundDirection | **Required** String The fund direction. Valid values are: - `CREDIT`: specifies the fund direction that is from Alipay+ to MPP. - `DEBIT`: specifies the fund direction that is from MPP to Alipay+. |
| 9 | settlementCurrency | **Required** String (3) The currency of the settlement amount. The value is specified by using the three-character [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) currency code. |
| 10 | settlementAmountValue | **Required** Integer The settlement amount of a transaction. - For most MPPs, the settlement currency is the transaction currency specified by _transactionCurrency_ and the settlement amount is identical to the value of _transactionAmountValue_ parameter. - For certain MPPs whose actual settlement currency is not the transaction currency specified by _transactionCurrency_, the actual settlement amount is calculated in the formula: _settlementAmountValue_ = _transactionAmountValue_ \* FX rate, where the FX rate is the foreign exchange rate between the actual settlement currency and the transaction currency. The value is provided in the smallest unit of the corresponding currency. For example, if the currency is USD and the amount is $1.00, the value of this parameter is 100; if the currency is JPY and the amount is ￥1, the value of this parameter is 1. Value range: 0 - unlimited. |
| 11 | transactionCurrency | **Required** String (3) The currency of the transaction amount. The value is specified by using the three-character [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) currency code. The currency here is the same as the currency of the transactions in the clearing cycle, which is the value of the _payToAmount.currency_ parameter in the **pay**/**userInitiatedPay** API. |
| 12 | transactionAmountValue | **Required** Integer The transaction amount. - For a payment, the value of this parameter is specified by the _payToAmount.value_ parameter in the **pay**/**userInitiatedPay** API. - For a refund, the value of this parameter is specified by the _refundFromAmount__.value_ parameter in the **refund** API. The value is provided in the smallest unit of the corresponding currency. For example, if the currency is USD and the amount is $1.00, the value of this parameter is 100; if the currency is JPY and the amount is ￥1, the value of this parameter is 1. Value range: 0 - unlimited. |
| 13 | feeDirection | **Required** String The fee direction. Valid values are: - `CREDIT`: specifies the fee direction that is from Alipay+ to MPP. - `DEBIT`: specifies the fee direction that is from MPP to Alipay+. |
| 14 | feeCurrency | **Optional** String (3) The currency of the net fee amount. The value is specified by using the 3-character [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) currency code, and the same as the value of _transactionCurrency_. > **Note**: This parameter is only passed if the fee is calculated in the transaction currency. |
| 15 | netFeeAmountValue | **Optional** Integer The net fee amount of all the fees that are charged for the transaction. The value is provided in the smallest unit of the corresponding currency and rounded with [Banker's rounding](bank_rounding). For example, if the currency is USD and the amount is $1.00, the value of this parameter is 100; if the currency is JPY and the amount is ￥1, the value of this parameter is 1. If the fee settlement amount is less than the smallest unit of the fee settlement currency, the value of this parameter will be 0. Value range: 0 - unlimited. > **Note**: This parameter is only passed if the fee is calculated in the transaction currency. |
| 16 | feeSettlementCurrency | **Optional** String (3) The currency of the net fee settlement amount. The value is specified by using the 3-character [ISO 4217](https://en.wikipedia.org/wiki/ISO_4217) currency code. > **Note**: This parameter is only passed if the fee is calculated in the settlement currency. |
| 17 | netFeeSettlementAmountValue | **Optional** Integer The net fee settlement amount of all the clearing fees that are charged for the transaction. The value is provided in the smallest unit of the corresponding currency and rounded with [Banker's rounding](bank_rounding). For example, if the currency is USD and the amount is $1.00, the value of this parameter is 100; if the currency is JPY and the amount is ￥1, the value of this parameter is 1. If the fee settlement amount is less than the smallest unit of the fee settlement currency, the value of this parameter will be 0. Value range: 0 - unlimited. > **Note**: This parameter is only passed if the fee is calculated in the settlement currency. |
| 18 | extendInfo | **Optional** String (2048) The extended information. |

## Samples

This section contains sample reports for different scenarios.

### Payment only

The following sample assumes that the MPP with an ID of `A1234567890` has **two** payments on 2022-04-19. The payments are made and settled in EUR.

You can view the sample in the following window or download the sample file: 

[📎transactionItems\_A1234567890\_EUR\_202204190000200000\_20210001\_000.csv](https://idocs-assets.marmot-cloud.com/storage/idocs87c36dc8dac653c1/yuque/idocs/2025/csv/fb3d0be5-f7ff-4265-8085-5991d2a5e573.csv)

[transactionItems\_A1234567890\_EUR\_202204190000200000\_20210001\_000.xlsx](https://idocs.alipay.com/file-preview?param=storage%2Fidocs87c36dc8dac653c1%2Fyuque%2Fidocs%2F2025%2Fxlsx%2F3c2eb295-71d5-4bf2-abc8-a5f09f92957a.xlsx)

See the following section for details:

-   **Summary section**: the MPP is to be debited a settlement fund of **20 EUR** in total, as a result of **two** payments that net **20 EUR** in total.
-   **Detail section**:

-   A **payment** of **10 EUR** is made, which leads to **10 EUR** in the settlement amount, and **0.2 EUR** in the fee settlement amount for the MPP.
-   Another **payment** of the same amount is made and leads to the same result in settlement and fees.

### Payment & refund

The following sample assumes that the MPP with an ID of `A1234567890` has **14** transactions on 2022-04-28. The transactions are made and settled in EUR.

You can view the sample in the following window or download the sample file: 

[📎transactionItems\_A1234567890\_EUR\_202204280000200000\_20210000\_000.csv](https://idocs-assets.marmot-cloud.com/storage/idocs87c36dc8dac653c1/yuque/idocs/2025/csv/a115bd92-257d-4555-ad6b-f3b7b8a71e5f.csv)

[transactionItems\_A1234567890\_EUR\_202204280000200000\_20210000\_000.xlsx](https://idocs.alipay.com/file-preview?param=storage%2Fidocs87c36dc8dac653c1%2Fyuque%2Fidocs%2F2025%2Fxlsx%2F02f56021-fd6c-4f74-991c-120d4c75b0a1.xlsx)

See the following section for details:

-   **Summary section**: the MPP is to be debited a settlement fund of **82 EUR** in total, as a result of **14** transactions that net **82 EUR** in total.
-   **Detail section**:

-   **Seven payments** are made, each of **23 EUR**. Each payment leads to **0.46 EUR** in the fee settlement amount for the MPP.
-   **Seven refunds** are made for **5 payments**, in different amounts.

### Payment & refund in multiple currencies

The following sample assumes that the MPP with an ID of `A1234567890` has **11** transactions on 2022-01-10. All transactions are settled in **EUR**. On the ACQP side, the orders are placed in different currencies, but on the MPP side, only one transaction currency is used. Therefore, in the sample below, the currency of all transactions is the same (**EUR** in this case).

You can view the sample in the following window or download the sample file: 

[📎transactionItems\_A1234567890\_EUR\_202201101107957472\_202109171107900901003800022697\_000.csv](https://idocs-assets.marmot-cloud.com/storage/idocs87c36dc8dac653c1/yuque/idocs/2025/csv/1ff156f7-1fee-4853-a7fd-6f2caaeabaf8.csv)

[transactionItems\_A1234567890\_EUR\_202201101107957472\_202109171107900901003800022697\_000.xlsx](https://idocs.alipay.com/file-preview?param=storage%2Fidocs87c36dc8dac653c1%2Fyuque%2Fidocs%2F2025%2Fxlsx%2Feb272888-4f88-4678-b617-e411dbdda890.xlsx)

See the following section for details:

-   **Summary section**: the MPP gets a settlement fund of **0.5 EUR** in total, as a result of **11** transactions.
-   **Detail section**:

-   **5 payments** are made in different amounts in **EUR**.
-   **6 refunds** are made for **4 payments**. The refunds are also made in different amounts in **EUR**.
-   The fee amounts are too low to be settled in EUR. Therefore, all the fees are 0.