Transaction file

Last updated: 2019-12-30

The transaction files obtained from SFTP and Alipay global open platform are slightly different in contents.


Transaction file obtained from SFTP

The transaction file obtained from SFTP consists of two parts, which are the file header and the record details.


File header 

The following table lists the fields in the file header:

No.Field

Type

(length)

Description
1PartnerString(16)

The unique ID that is assigned by Alipay to identify a partner. The ID is composed of 16 digits beginning with 2088.

2Payment_timeString(10)

The date when the transaction is completed. Format: YYYY-MM-DD

3Total_countNumber(9)

The total number of records in the file


Record details

The record details contain the following fields:

No.FieldDescription
1Partner_transaction_id

The unique ID that is assigned by the partner to identify a transaction in the partner system.

  • When the Transaction_type is PAYMENT, REVERSAL or CANCEL, the value is same as that of partner_trans_id.
  • When the Transaction_type is REFUND, the value is same as that of partner_refund_id.

Example: 124************************025

2Transaction_id

The unique ID that is composed of digits and assigned by Alipay to identify a transaction

Example: 2018*********************911

3Transaction_amount

The transaction amount in foreign currency

Example: 7.50

4Charge_amount

The commission fee that is charged for the transaction in foreign currency

Example: 0.01

5Currency

Settlement currency

Example: EUR

6Payment_time

The date and time when the transaction is completed. Format: YYYY-MM-DD HH:MM:SS

Example: 2019-08-07 17:11:00

7Transaction_type

The transaction type. The value can be:

  • PAYMENT
  • REVERSAL
  • REFUND
  • CANCEL

Example: PAYMENT

8RemarkRemarks
9Secondary_merchant_industry

The merchant category code that is assigned by Alipay to identify an industry. See MCC list for details.

Example: 5812

10Secondary_merchant_name

Secondary merchant name

Example: Apple store

11Operator_name

Operator name, such as a store name or a taxi driver name

Example: Apple store

12Order_scene

The business scenario where the transaction is completed. The value can be:

  • shopQrCode: Merchant QR mode
  • paymentQrCode: Barcode payment mode
  • transactionQrCode: Transaction QR mode
  • externalCreateOrder: Third-party Merchant QR Code (Standard mode)
  • transactionQrCode: Third-party Merchant QR Code (Simple mode)

Example: externalCreateOrder

13Trans_currency

The pricing currency

Example: EUR

14Trans_amount

The order amount in the pricing currency

Example: 7.50

15Trans_forex_rate

Exchange rate between the settlement currency and the pricing currency

Example: 1


Sample

Partner:208800000000|Payment_time: 2013-12-02|Total_count:4
Partner_transaction_id|Transaction_id|Transaction_amount|Charge_amount|Currency|Payment_time|Transaction_type|Remark|Secondary_merchant_industry|Secondary_merchant_name|Operator_name|Order_scene|Trans_currency|Trans_amount|Trans_forex_rate 
0001|201312020445|100|3|HKD|2013-12-02 10:45:42|PAYMENT||5812|xxx|xxx|shopQrCode|TWD|100|0.031 
0002|201312020446|100|3|HKD|2013-12-02 10:45:13|REVERSAL||5812|xxx|xxx|shopQrCode|TWD|100|0.031 
0003|201312020448|100|3|HKD|2013-12-02 10:45:09|REFUND|Refund|5812|xxx|xxx|shopQrCode|TWD|100|0.031 


Transaction file obtained from Alipay global open platform

When you view transaction information on Alipay global open platform, you can see the following fields:

No.

FieldDescription

1

Time

The date and time when the transaction is completed. Format: YYYY.MM.DD HH:MM:SS

Example: 2018.08.26 17:21:47

2

Transaction ID/Partner transaction ID

The unique ID that is composed of digits and assigned by Alipay to identify a transaction / The unique ID that is assigned by the partner to identify a transaction in the partner system. When Type is P, the value is same as that of partner_trans_id. When Type is R, the value is same as that of transaction_id.

Example: 2018*********************911/FOREXREFUND_2018*********043

3

Gross Amount

The transaction amount in foreign currency and in CNY currency. When the transaction is a refund, the amount is a minus number.

Example: $-0.01/¥-0.06

4

Settlement

The settlement amount in foreign currency and in CNY currency.

Example: $ 2.00/¥12.00

5

Fee

The commission fee that is charged for the transaction in foreign currency and in CNY currency.

Example: $ 0.00/¥0.00

6

Discount Amount

Amount of the discount voucher in foreign currency and in CNY currency.

Example: $ 2.00/¥12.00

7

Currency

Settlement currency

Example: USD 6.352371

8

Product

In-store payment product. The value is fixed as SPOT.

Example: SPOT

9

TypeThe transaction type. The value can be:

P: Payment transaction

R: Refund transaction

Example: R

10

Status

Transaction status.

When Type is P, the value can be:

P: Payment succeeds

When Type is R, the value can be:

S: Refund succeeds

F: Refund failed

W: Refund process has not completed

Note: The value W is only available in the async refund process.

Example: P

11

RemarksRemarks

12

Operation

Action to process a transaction

Example: Refund


Sample

在线交易3.png

If you have any question, please contact us