Skip to main content

List of Enumerations

Class

Class

Condition Object

ParameterTypeMeaning
marketTypeTradingTypeMonitoring Type Optional: REFERENCE Auto Reference Object, SCHEDULED Time
symbolstringStock Symbol
triggerTriggerContentTrigger Condition Optional: BID_PRICE Bid Price, ASK_PRICE Ask Price, MATCHED_PRICE Matched Price, TOTAL_QUANTITY Total Quantity, TIME Time
triggerValuestringMonitoring Condition Value (If Time, use format HHMMSS)
comparisonOperatorComparison Operator Optional: GREATER_THAN_OR_EQUAL, LESS_THAN_OR_EQUAL, GREATER_THAN, LESS_THAN
info
  1. When selecting REFERENCE, trigger can be combined with BID_PRICE, ASK_PRICE, MATCHED_PRICE, TOTAL_QUANTITY, TIME. If trigger uses TIME, it triggers when the time condition is met AND there is a transaction for the commodity within the time range.
  2. When selecting SCHEDULED, symbol must be empty "", trigger must be TIME. It will use system time and trigger when time condition is met.

ConditionOrder Object

ParameterTypeMeaning
buySellBsActionBuy/Sell Action
symbolstringStock Symbol
pricestringOrder Price
quantityintOrder Quantity
marketTypeConditionMarketTypeMarket Type Optional: COMMON Round Lot, FIXING Fixed Price, INTRADAY_ODD Intraday Odd Lot, ODD After-hours Odd Lot
priceTypeConditionPriceTypePrice Type : Optional: BID_PRICE Bid Price, ASK_PRICE Ask Price, MATCHED_PRICE Matched Price, LIMIT Limit Price, LIMIT_UP Limit Up, LIMIT_DOWN Limit Down, MARKET Market Price, REFERENCE Reference Price (Flat Price)
timeInForceTimeInForceTime In Force Optional: ROD, FOK, IOC
orderTypeConditionOrderTypeOrder Type : Optional: STOCK Stock, MARGIN Margin Trading, SHORT Short Selling

ConditionDayTrade Object

ParameterTypeMeaning
dayTradeEndTimestringDay Trade Closing Time, format "HHMMSS" (e.g. "130000"); range 130100 ~ 132000
autoCancelboolWhether to delete triggered orders after washing prices
pricestringOrder Price (If no specific price, e.g., Market Order, leave blank "")
priceTypeConditionPriceTypePrice Type : Optional: BID_PRICE Bid Price, ASK_PRICE Ask Price, MATCHED_PRICE Matched Price, LIMIT Limit Price, LIMIT_UP Limit Up, LIMIT_DOWN Limit Down, MARKET Market Price, REFERENCE Reference Price (Flat Price)
About Day Trade Closing Time

Range can be set 130100 ~ 132000

TpslOrder Object

ParameterTypeMeaning
timeInForceTimeInforceTime In Force : Optional: ROD, IOC, FOK
priceTypeConditionPriceTypePrice Type : Optional: BID_PRICE Bid Price, ASK_PRICE Ask Price, MATCHED_PRICE Matched Price, LIMIT Limit Price, LIMIT_UP Limit Up, LIMIT_DOWN Limit Down, MARKET Market Price, REFERENCE Reference Price (Flat Price)
orderTypeConditionOrderTypeOrder Type : Optional: STOCK Stock, MARGIN Margin Trading, SHORT Short Selling
targetPricestringTPSL Trigger Price
pricestringTPSL Order Price
triggerTriggerContentTPSL Trigger Condition (See details at end of table)
info

If priceType is LIMIT, price must be filled; otherwise set price to std::nullopt

TPSL Trigger Condition

New in version 2.2.0 (Not available in 2.1.1 and earlier), TPSL trigger price type can be set to 1. MATCHED_PRICE 2. Best Bid (BID_PRICE); 3. Best Ask (ASK_PRICE)

If not set, fill this field with null, defaults to Matched Price (MATCHED_PRICE)

TpslWrapper Object

ParameterTypeMeaning
stopSignStopSignStop Sign : Optional: FULL Until Full Execution, PARTIAL Until Partial Execution, UNTIL_END Until Expiry
tpTpslOrder Object (Optional)Take Profit Condition
slTpslOrder Object (Optional)Stop Loss Condition
endDatestring (Optional : Same as parent StartDate if empty)Condition End Date
intradaybool (Optional)Intraday Day Trade after Full Execution (* Must be set to true when used with Day Trade Condition Order)
Intraday Day Trade

When using Day Trade Condition Order, intraday must be set to true

TrailOrder

ParameterTypeMeaning
symbolstringStock Symbol
pricestringBase Price (Note: Max 2 decimal places, system wash price will fail if exceeded)
directionDirectionDirection : Optional: UP, DOWN
percentageintUp / Down %
buysellBsActionBuy/Sell : Optional: BUY, SELL
quantityintOrder Quantity
PriceTypeConditionPriceTypePrice Type : Optional BID_PRICE Bid Price, ASK_PRICE Ask Price, MATCHED_PRICE Matched Price, MARKET Market Price, LIMIT_UP Limit Up, LIMIT_DOWN Limit Down, REFERENCE Reference Price (Flat Price)
diffintOrder Price Ticks (Add/Subtract ticks based on priceType), positive adds ticks upwards, negative adds ticks downwards
timeInForceTimeInForceTime In Force Optional: ROD, FOK, IOC
orderTypeConditionOrderTypeOrder Type Optional: STOCK Stock, MARGIN Margin Trading, SHORT Short Selling

SplitDescription

ParameterTypeMeaning
methodSliceTypeSlice Condition : Optional:
TYPE1 From startTime, send one order every few seconds, total totalQuantity, each order singleQuantity
TYPE2 From startTime to endTime, send one order every interval seconds, total totalQuantity, remaining quantity added to the last order
TYPE3 From startTime to endTime, send one order every interval seconds, total totalQuantity, remaining quantity distributed from the last order backwards.

intervalintOrder Interval (Seconds)
singleQuantityintSingle Order Quantity (Shares)
totalQuantityint (Optional)Total Order Quantity (Shares)
startTimestringStart Time
endTimestring (Optional)End Time
caution

Note: Total order quantity must be greater than single order quantity.

ConditionOrderResult

ParameterTypeMeaning
guidstringCondition Order GUID

Constants (Field Value Mapping)

BsAction

Buy/Sell Action

NameValueMeaning
BUY1Buy
SELL2Sell
UN_SUPPORTED3Unsupported Type
UN_DEFINED4Undefined Type

ConditionMarketType

Market Type

NameValueMeaning
COMMON1Common
FIXING2Fixing
INTRADAY_ODD3Intraday Odd
ODD4Odd Lot

TradingType

Monitoring Type

NameValueMeaning
REFERENCE1Auto Reference Object
SCHEDULED3Time

TriggerContent

Trigger Condition

NameValueMeaning
BID_PRICE1Bid Price
ASK_PRICE2Ask Price
MATCHED_PRICE3Matched Price
TOTAL_QUANTITY4Total Quantity
TIME5Time

Operator

NameValueMeaning
GREATER_THAN_OR_EQUAL1Greater Than or Equal
LESS_THAN_OR_EQUAL2Less Than or Equal
GREATER_THAN3Greater Than
LESS_THAN4Less Than

StopSign

NameValueMeaning
FULL1Until Full Execution
PARTIAL2Until Partial Execution
UNTIL_END3Until Expiry

TimeInForce

Time In Force (TimeInForce)

NameValueMeaning
ROD1Rest of Day (ROD)
FOK2Fill-or-Kill (FOK)
IOC3Immediate-or-Cancel (IOC)
UN_SUPPORTED4Unsupported Type
UN_DEFINED5Undefined Type

ConditionPriceType

Price Type (ConditionPriceType)

NameValueMeaning
LINIT1Limit
BID_PRICE2Bid Price
ASK_PRICE3Ask Price
MARKET4Market
MATCHED_PRICE5Matched Price
LIMIT_UP6Limit Up
LIMIT_DOWN7Limit Down
REFERENCE8Reference Price

ConditionOrderType

Order Type (orderType)

NameValueMeaning
STOCK1Stock
MARGIN2Margin
SHORT3Short Selling
DAY_TRADE4Day Trade

Direction

Trailing Stop Up/Down (direction)

NameValueMeaning
Up1Up
Down2Down

SliceType

Slice Type (SliceType)

NameMeaning
Type1From Start Time, send one order every few seconds, total N orders, M shares each
Type2From Start to End, send one order every X seconds, total N shares, remaining shares added to last order
Type3From Start to End, send one order every X seconds, total N shares, remaining shares distributed from last backwards

ConditionStatus

Condition Status (ConditionStatus)

NameMeaning
Type1Today's Query
Type2Valid Orders
Type3Comparing Conditions
Type4Order Processing
Type5Order Success
Type6Notified
Type7Order Failed
Type8Has Match
Type9Delete Success
Type10Abnormal
Type11Invalid

HistoryStatus

History Status (HistoryStatus)

NameMeaning
Type1All Condition Orders (Excluding Deleted, Invalid)
Type2Full Match Orders in Period
Type3Partial Match Orders in Period
Type4Deleted Orders in Period
Type5Invalid Orders in Period
Type6Triggered Records in Period