Expand description
§xtp
xtp
is a Rust binding for the XTP SDK,
which is an interface for trading on the Chinese stock market.
§Current status
All APIs are implemented but are partially tested/documented. USE AT YOUR OWN RISK!
§Dependencies
-
This crate depends on
libxtpquoteapi
andlibxtptraderapi
from the bundled XTP SDK. Please install them first. (The Installation here means adding the path to the correponding libs toLD_LIBRARY
on linux, or%PATH%
on windows.) The version of the installed lib should be same as the one in the bundled sdk in case of incompatibility. -
Only 64 bit of the SDK is implemented.
-
For windows users, please install 64bit rust compiler and llvm (required by rust-bindgen).
§Usage
Please check out the examples folder for detail usage.
Structs§
Enums§
- ETF_REPLACE_TYPE现金替代标识定义
- TXTPOrderTypeType是报单类型类型
- TXTPTradeTypeType是成交类型类型
- 账户类型
- 证券业务类型
- Error type for this library.
- XTP_EXCHANGE_TYPE是交易所类型
- XTP_FUND_OPER_STATUS柜台资金操作结果
- 资金流转方向类型
- XTP_LOG_LEVEL是日志输出级别类型
- XTP_MARKET_TYPE市场类型
- XTP_OPT_CALL_OR_PUT_TYPE是一个认沽或认购类型
- XTP_OPT_EXERCISE_TYPE_TYPE是一个行权方式类型
- XTP_ORDER_ACTION_STATUS_TYPE是报单操作状态类型
- XTP_ORDER_STATUS_TYPE是报单状态类型
- XTP_ORDER_SUBMIT_STATUS_TYPE是报单提交状态类型
- XTP_POSITION_DIRECTION_TYPE是一个持仓方向类型
- XTP_POSITION_EFFECT_TYPE是开平标识类型
- XTP_PRICE_TYPE是价格类型
- XTP_PROTOCOL_TYPE是通讯传输协议方式
- XTP_SIDE_TYPE是买卖方向类型
- XTP_SPLIT_MERGE_STATUS是一个基金当天拆分合并状态类型
- XTP_TBT_TYPE是一个逐笔回报类型
- XTP_TE_RESUME_TYPE是公有流(订单响应、成交回报)重传方式
- 证券类型