跳到主要内容

查询成交记录

获取用户的交易历史。

时间范围限制:

  • startTime + endTime:最多 7 天
  • startTime:开始时间后 7 天
  • endTime:结束时间前 7 天
  • 均未指定:当前时间前 7 天

请求参数

名称类型是否必填描述
symbolString市场符号
startTimeLong开始时间(例如:1624987283000)
endTimeLong结束时间(例如:1624987283000)
beforeSerialIdLong用于分页检索记录,适用于订单量每毫秒超过 500 的情况
afterSerialIdLong用于分页检索记录,适用于订单量每毫秒超过 500 的情况
countLong返回的记录数量
includeOldBoolean检索过去 7 天的交易历史记录
orderIDString通过订单 ID 查询交易历史
clOrderIDString通过自定义订单 ID 查询交易历史

响应内容

名称类型描述
symbolString市场符号
sideString交易方向: [BUY, SELL]
priceDouble成交价格
sizeLong原始订单数量
serialIdLong序列号,连续的序列号
tradeIdString交易标识符
orderIdString订单 ID
clOrderIDString自定义订单 ID
timestampLong成交时间戳
baseString基础货币
quoteString报价货币
walletString钱包名称:CROSS@(全仓钱包)或 ISOLATED@{symbol}-USDT(隔离钱包)
feeCurrencyString费用货币
feeAmountDouble费用金额
filledPriceDouble平均成交价格
avgFilledPriceDouble平均成交价格
filledSizeLong成交大小
orderTypeInteger订单类型
realizedPnLDouble现货中未使用
positionIdString当前订单属于的仓位 ID
contractSizeDouble交易合约规模
example
GEThttps://api.btse.com/futures/api/v2.3/user/trade_history