跳到正文
QMT

get_closed_compacts

获取已了结负债合约明细

用法

get_closed_compacts(accountID,accountType)

释义

获取已了结负债合约明细

参数

  • accountID:str,资金账号

  • accountType:str,账号类型,这里应该填'CREDIT'

返回值

list([ CStkUnclosedCompacts, ... ]) 负债列表,CStkUnclosedCompacts属性如下:

字段名 类型 描述
m_strAccountID string 账号ID
m_nBrokerType int 账号类型
1-期货账号
2-股票账号
3-信用账号
5-期货期权账号
6-股票期权账号
7-沪港通账号
11-深港通账号
m_strExchangeID string 市场
m_strInstrumentID string 证券代码
m_eCompactType int 合约类型
32-不限制
48-融资
49-融券
m_eCashgroupProp int 头寸来源
32-不限制
48-普通头寸
49-专项头寸
m_nOpenDate int 开仓日期(如'20201231')
m_nBusinessVol int 合约证券数量
m_nRetEndDate int 到期日(如'20201231')
m_nDateClear int 了结日期(如'20201231')
m_nEntrustVol int 委托数量
m_dEntrustBalance float 委托金额
m_dBusinessBalance float 合约金额
m_dBusinessFare float 合约息费
m_dRepaidFare float 已还息费
m_dRepaidBalance float 已还金额
m_strCompactId string 合约编号
m_strEntrustNo string 委托编号
m_strPositionStr string 定位串

示例

get_closed_compacts('6000000248', 'CREDIT')

官方来源

QMT 官方文档:获取已了结负债合约明细。网页核对日期:2026-10-11。

本页目录