Skip to main content

Query subscription transaction history(USER_DATA)

API Description

Query subscription transaction history of a plan

HTTP Request

GET /sapi/v1/lending/auto-invest/history/list

Request Weight(IP)

1

Request Parameters

NameTypeMandatoryDescription
planIdLONGNOPlan identifier
startTimeLONGNO
endTimeLONGNO
targetAssetLONGNOPlan identifier
planTypeLONGNOSINGLE, PORTFOLIO, INDEX, ALL
sizeLONGNODefault:10, Max:100
currentLONGNOCurrently querying page. Start from 1. Default:1
recvWindowLONGNOno more than 60000
timestampLONGYES
  • Max span between startTime and endTime is 30days
  • If both startTime and endTime are null,then default is 30days

Response Example

[
{
"id":1111,
"targetAsset":"BTC", //name of the asset
"planType":"SINGLE", //plan type of which this transaction is from
"planName":"BTC", // plan name of which this transaction is from
"planId":1234, // plan identifier of which this transaction is from
"transactionDateTime":1648378800000, //transaction timestamp
"transactionStatus":"SUCCESS", //status of the transaction: "SUCCESS","FAILED","PENDING"
"failedType":"INSUFFICIENT_BALANCE",// only show when transactionStatus = FAILED, INSUFFICIENT_BALANCE,TRANSACTION_REJECT/GCC_RJECT
"sourceAsset":"BUSD", //source asset of the transaction
"sourceAssetAmount":"297.12345", //amount of source asset used
"targetAssetAmount":"0.005", //purchased amount of the asset
"sourceWallet":"SPOT_WALLET", // SPOT_WALLET,FLEXIBLE_SAVINGS,SPOT_WALLET_FLEXIBLE_SAVINGS,REWARDS
"flexibleUsed":"false", //whether simple earn wallet is used
"transactionFee":"0.002", //transaction fee amount
"transactionFeeUnit":"BUSD", //denominated coin of the transaction fee
"executionPrice":"2342" //price of the subscription price. It's amount of source asset equivilent of 1 unit of target asset
"executionType":"RECURRING", //ONE_TIME,RECURRING
"subscriptionCycle": "WEEKLY"
}
]