对象模型¶
成交对象¶
TradeObject¶
业务字段参见 fclib::model_future::TradeBase todo fclib 在重构,正式发版前应该重新确认字段 |
|||
type |
object |
||
properties |
|||
|
Investor Id |
||
投资者代码 |
|||
type |
string |
||
|
经纪公司 |
||
#/$defs/Broker |
|||
|
Session Id |
||
会话ID |
|||
type |
string |
||
|
Unique Session Id |
||
唯一会话ID |
|||
type |
string |
||
|
Trading Day |
||
type |
string |
||
format |
date |
||
|
Exchange Trade Id |
||
交易所成交编号,在每次成交时, 交易所会生成两条对应的成交记录(买方卖方各一条), 这两条成交记录的 exchange_trade_id 是相同的 |
|||
type |
string |
||
|
Exchange Id |
||
交易所代码 |
|||
type |
string |
||
|
Product Id |
||
品种代码 |
|||
anyOf |
type |
string |
|
type |
null |
||
|
Instrument Id |
||
成交合约代码 (合约) |
|||
type |
string |
||
|
Direction |
||
买卖方向 (买卖) |
|||
type |
string |
||
|
Offset |
||
开平标志 (开平) |
|||
type |
string |
||
|
Hedge Flag |
||
投保标志 (投保) |
|||
type |
string |
||
|
Volume |
||
成交手数 |
|||
type |
integer |
||
|
Volume Close Today |
||
平今手数,当 offset 为 CLOSE 或 CLOSE_TODAY 时,此值才不为0 |
|||
anyOf |
type |
integer |
|
type |
null |
||
|
Volume Close Yesterday |
||
平昨手数,当 offset 为 CLOSE 或 CLOSE_YESTERDAY 时,此值才不为0 |
|||
anyOf |
type |
integer |
|
type |
null |
||
|
Price |
||
成交价格 |
|||
anyOf |
type |
number |
|
type |
null |
||
|
Amount |
||
成交额 |
|||
anyOf |
type |
number |
|
type |
null |
||
|
Commission |
||
手续费,仅在以下后台提供: otg-sim |
|||
anyOf |
type |
number |
|
type |
null |
||
|
Close Profit |
||
平仓盈亏,逐日 |
|||
anyOf |
type |
number |
|
type |
null |
||
|
Close Profit By Open |
||
平仓盈亏,逐笔 |
|||
anyOf |
type |
number |
|
type |
null |
||
|
Premium |
||
权利金 |
|||
anyOf |
type |
number |
|
type |
null |
||
|
Trade Type |
||
成交类型 |
|||
anyOf |
type |
string |
|
type |
null |
Broker¶
type |
object |
|||
properties |
||||
|
Broker Id |
|||
anyOf |
type |
string |
||
type |
null |
|||
|
Broker Name |
|||
anyOf |
type |
string |
||
type |
null |
|||
|
Seat |
|||
anyOf |
type |
string |
||
type |
null |
|||
|
Fronts |
|||
anyOf |
type |
array |
||
items |
type |
string |
||
type |
null |
合约对象¶
InstrumentObject¶
合约 Object, 目前只记录全部的期货和期权合约
Example: "SHFE.rb2407": {
"product_id": "rb",
"product_short_name": "螺纹",
}
"SHFE.rb2407C3950": {
"product_id": "rb",
"product_short_name": "螺纹期权",
}
"CFFEX.IH2403": {
"product_id": "IH",
"product_short_name": "上证",
}
"CFFEX.HO2409-C-2000": {
"product_id": "SSE.000016",
"product_short_name": "上证50指数期权",
}
|
|||
type |
object |
||
properties |
|||
|
Exchange Id |
||
交易所代码 |
|||
type |
string |
||
|
Product Id |
||
品种代码 |
|||
type |
string |
||
|
Product Short Name |
||
品种名称 |
|||
type |
string |
||
|
Instrument Id |
||
交易所内的合约代码 |
|||
type |
string |
||
|
Instrument Name |
||
合约中文名 |
|||
type |
string |
||
|
Ins Class |
||
合约类型 |
|||
type |
string |
||
|
Price Tick |
||
合约价格变动单位 |
|||
anyOf |
type |
number |
|
type |
null |
||
|
Price Decs |
||
合约价格小数位数 |
|||
type |
integer |
||
|
Volume Multiple |
||
合约乘数 |
|||
type |
integer |
||
|
Expired |
||
合约是否已下市 |
|||
type |
boolean |
||
|
Expire Datetime |
||
到期具体日,以秒为单位的 timestamp 值 |
|||
anyOf |
type |
number |
|
type |
null |
||
|
Underlying Symbol |
||
标的合约, exchange_id.instrument_id |
|||
anyOf |
type |
string |
|
type |
null |
||
|
Strike Price |
||
行权价 |
|||
anyOf |
type |
number |
|
type |
null |
||
|
Option Class |
||
期权方向 |
|||
anyOf |
type |
string |
|
type |
null |
||
|
Exercise Type |
||
期权行权方式,美式:'A',欧式:'E' |
|||
anyOf |
type |
string |
|
type |
null |
||
|
Categories Id |
||
板块代码 |
|||
anyOf |
type |
string |
|
type |
null |
||
|
Categories Name |
||
板块名称 |
|||
anyOf |
type |
string |
|
type |
null |