Create Download Transaction History Task¶
To download the transaction history, you must first create a download task. After the task is successfully created, a download_id is returned. This download_id is required to call the Download Task API.
Endpoint¶
Parameters¶
Path Parameters¶
| Field | Type | Description |
|---|---|---|
| b_id Required | String | Business line ID |
Body Parameters¶
| Field | Type | Description |
|---|---|---|
| start_date Required | String | The start date of the transaction query period. Format: YYYY-MM-DD |
| end_date Required | String | The end date of the transaction query period. Format: YYYY-MM-DD |
| download_id Optional | String | The download task ID. If not provided in the request body, it will be automatically generated. It must match the regex pattern ^[A-Za-z0-9_-]+$. |
The start_date and end_date parameters must be no more than 10 days apart. If the date range exceeds 10 days, the API will return error code 10380002.\
\
If the provided download_id does not match the above regex pattern, the API will return error code 10380002.
Request Body Example¶
Response¶
The transaction history download returns a ZIP file containing multiple JSON files. Transactions are grouped by day, with each day’s data stored in a separate JSON file. Each file contains detailed transaction records in the format shown here.
Response Body¶
| Field | Type | Description |
|---|---|---|
| code | Integer | Response code (0 = success) |
| message | String | Response message |
| data | String | download_id is returned after the task is successfully created. |
| successful | Boolean | Whether the request was successful |