Optional accountThe account the trade will be allocated to.
Optional actionIdentifies the side.
Generally available values are BUY, SELL.
Additionally, SSHORT, SLONG are available in some institutional-accounts only.
For general account types, a SELL order will be able to enter a short position automatically if the order quantity is larger than your current long position.
SSHORT is only supported for institutional account configured with Long/Short account segments or clearing with a separate account.
SLONG is available in specially-configured institutional accounts to indicate that long position not yet delivered is being sold.
Optional activeFor GTC orders.
Optional activeFor GTC orders.
Optional adjustableAdjusted Stop orders: specifies where the trailing unit is an amount (set to 0) or a percentage (set to 1)
Optional adjustedAdjusted Stop orders: the parent order will be adjusted to the given type when the adjusted trigger price is penetrated.
Optional adjustedAdjusted Stop orders: specifies the stop limit price of the adjusted (STPL LMT) parent.
Optional adjustedAdjusted Stop orders: specifies the stop price of the adjusted (STP) parent.
Optional adjustedAdjusted Stop orders: specifies the trailing amount of the adjusted (TRAIL) parent.
Optional advancedAccepts a list with parameters obtained from advancedOrderRejectJson
Optional algoTODO document.
Optional algoThe list of parameters for the IB algorithm.
For more information about IB's API algorithms, refer to https://www.interactivebrokers.com/en/software/api/apiguide/tables/ibalgo_parameters.htm.
Optional algoThe algorithm strategy.
As of API version 9.6, the following algorithms are supported:
For more information about IB's API algorithms, refer to https://www.interactivebrokers.com/en/software/api/apiguide/tables/ibalgo_parameters.htm.
Optional allIndicates whether or not all the order has to be filled on a single execution.
Optional auctionFor BOX orders only.
Possible values:
Optional autoTODO: document
Optional autoTODO: document
Optional auxGeneric field to contain the stop price for STP LMT orders, trailing amount, etc.
Optional basisTODO document. For EFP orders only.
Optional basisTODO document. For EFP orders only.
Optional blockIf set to true, specifies that the order is an ISE Block order.
Optional cashThe native cash quantity.
Optional clearingSpecifies the true beneficiary of the order.
For IBExecution customers.
This value is required for FUT/FOP orders for reporting to the exchange.
Optional clearingFor execution-only clients to know where do they want their shares to be cleared at. Valid values are: IB, Away, and PTA (post trade allocation).
Optional clientThe API client id which placed the order.
Optional competeSpecifies the offset Off The Midpoint that will be applied to the order. For IBKRATS orders.
Optional conditionsConditions determining when the order will be activated or canceled.
Optional conditionsConditions can determine if an order should become active or canceled.
Optional conditionsIndicates whether or not conditions will also be valid outside Regular Trading Hours.
Optional continuousSpecifies whether TWS will automatically update the limit price of the order as the underlying price moves.
VOL orders only.
Optional deltaThe stock's Delta. For orders on BOX only.
Optional deltaUse this field to enter a value if the value in the deltaNeutralOrderType field is an order type that requires an Aux price, such as a REL order.
VOL orders only.
Optional deltaTODO document
Optional deltaTODO document
Optional deltaTODO document
Optional deltaUsed only when [[deltaNeutralShortSaleSlot]] = 2.
Optional deltaSpecifies whether the order is an Open or a Close order and is used when the hedge involves a CFD and and the order is clearing away.
Optional deltaEnter an order type to instruct TWS to submit a delta neutral trade on full or partial execution of the VOL order.
VOL orders only.
For no hedge delta order to be sent, specify NONE.
Optional deltaTODO document
Optional deltaUsed when the hedge involves a stock and indicates whether or not it is sold short.
Optional deltaHas a value of 1 (the clearing broker holds shares) or 2 (delivered from a third party). If you use 2, then you must specify a [[deltaNeutralDesignatedLocation]].
Optional designatedUsed only when shortSaleSlot is 2.
For institutions only.
Indicates the location where the shares to short come from. Used only when short sale slot is set to 2 (which means that the shares to short are held elsewhere and not with IB).
Optional discretionaryThe amount off the limit price allowed for discretionary orders.
Optional discretionarySet to true to convert order of type 'Primary Peg' to 'D-Peg'.
Optional displayThe publicly disclosed order size, used when placing Iceberg orders.
Optional dontDon't use auto price for hedge.
Optional durationSpecifies the duration of the order. Format: yyyymmdd hh:mm:ss TZ. For GTD orders.
Optional eTrade with electronic quotes.
Optional exemptOnly available with IB Execution-Only accounts with applicable securities Mark order as exempt from short sale uptick rule.
Optional extThis is a regulatory attribute that applies to all US Commodity (Futures) Exchanges, provided to allow client to comply with CFTC Tag 50 Rules.
Optional faThe Financial Advisor group the trade will be allocated to. Use an empty string if not applicable.
Optional faThe Financial Advisor allocation method the trade will be allocated to. Use an empty string if not applicable.FaMethod
Optional faThe Financial Advisor percentage concerning the trade's allocation. Use an empty string if not applicable.
Optional faThe Financial Advisor allocation profile the trade will be allocated to. Use an empty string if not applicable.
Optional filledTODO: document
Optional firmTrade with firm quotes.
Optional goodSpecifies the date and time after which the order will be active. Format: yyyymmdd hh:mm:ss {optional Timezone}.
Optional goodThe date and time until the order will be active. You must enter GTD as the time in force to use this string. The trade's "Good Till Date," format "YYYYMMDD hh:mm:ss (optional time zone)".
Optional hedgeBeta = x for Beta hedge orders, ratio = y for Pair hedge order
Optional hedgeFor hedge orders.
Possible values include:
Optional hiddenIf set to true, the order will not be visible when viewing the market depth.
This option only applies to orders routed to the ISLAND exchange.
Optional imbalanceTODO: document
Optional isSet to true to create tickets from API orders when TWS is used as an OMS.
Optional isPegged-to-benchmark orders: indicates whether the order's pegged price should increase or decreases.
Optional lmtThe LIMIT price.
Used for limit, stop-limit and relative orders. In all other cases specify zero. For relative orders with no limit price, also specify zero.
Optional lmtTODO: document
Optional manualUsed by brokers and advisors when manually entering, modifying or cancelling orders at the direction of a client. Only used when allocating orders to specific groups or accounts. Excluding "All" group.
Optional midThis offset is applied when the spread is an odd number of cents wide. This offset must be in half-penny increments. For IBKRATS orders.
Optional midThis offset is applied when the spread is an even number of cents wide. This offset must be in whole-penny increments or zero. For IBKRATS orders.
Optional mifid2Identifies the algorithm responsible for investment decisions within the firm. Orders covered under MiFID 2 must include either [[mifid2DecisionMaker]] or [[mifid2DecisionAlgo]], but cannot have both.
Requires TWS 969+.
Optional mifid2Identifies a person as the responsible party for investment decisions within the firm.
Orders covered by MiFID 2 (Markets in Financial Instruments Directive 2) must include either [[mifid2DecisionMaker]] or [[mifid2DecisionAlgo]] field (but not both).
Requires TWS 969+.
Optional mifid2For MiFID 2 reporting; identifies the algorithm responsible for the execution of a transaction within the firm.
Requires TWS 969+.
Optional mifid2For MiFID 2 reporting; identifies a person as the responsible party for the execution of a transaction within the firm.
Requires TWS 969+.
Optional minDefines the minimum size to compete. For IBKRATS orders.
Optional minIdentifies a minimum quantity order type.
Optional minDefines the minimum trade quantity to fill. For IBKRATS orders.
Optional modelOptional nbboMaximum smart order distance from the NBBO.
Optional notOrders routed to IBDARK are tagged as “post only” and are held in IB's order book, where incoming SmartRouted orders from other IB customers are eligible to trade against them.
For IBDARK orders only.
Optional ocaOne-Cancels-All group identifier.
Optional ocaTells how to handle remaining orders in an OCA group when one order or part of an order executes.
Valid values are:
If you use a value "with block" it gives the order overfill protection. This means that only one order in the group will be routed at a time to remove the possibility of an overfill.
Optional openFor institutional customers only.
Valid values are O (open), C (close).
Available for institutional clients to determine if this order is to open or close a position.
When Action = "BUY" and OpenClose = "O" this will open a new position.
When Action = "BUY" and OpenClose = "C" this will close and existing short position.
Optional optUse to opt out of default SmartRouting for orders routed directly to ASX.
This attribute defaults to false unless explicitly set to true.
When set to false, orders routed directly to ASX will NOT use SmartRouting.
When set to true, orders routed directly to ASX orders WILL use SmartRouting.
Optional orderList of Per-leg price following the same sequence combo legs are added.
The combo price must be left unspecified when using per-leg prices.
Optional orderThe API client's order id.
Optional orderTODO document
Optional orderThe order reference.
Intended for institutional customers only, although all customers may use it to identify the API client that sent the order when multiple API clients are running.
Optional orderThe order's type.
Optional originThe order's origin. Same as TWS "Origin" column.
Identifies the type of customer from which the order originated.
Valid values are 0 (customer), 1 (firm).
Optional outsideIf set to true, allows orders to also trigger or fill outside of regular trading hours.
Optional overrideOverrides TWS constraints. Precautionary constraints are defined on the TWS Presets page, and help ensure that your price and size order values are reasonable. Orders sent from the API are also validated against these safety constraints, and may be rejected if any constraint is violated.
To override validation, set this parameter’s value to true.
Optional parentThe order ID of the parent order, used for bracket and auto trailing stop orders.
Optional parentTODO: document
Optional peggedPegged-to-benchmark orders: amount by which the order's pegged price should move.
Optional percentThe percent offset amount for relative orders.
Optional permThe Host order identifier.
Optional postValue must be positive, and it is number of seconds that SMART order would be parked for at IBKRATS before being routed to exchange.
Optional randomizeTODO: document
Optional randomizeTODO: document
Optional refTODO: document
Optional referencePegged-to-benchmark orders: the amount the reference contract needs to move to adjust the pegged order.
Optional referencePegged-to-benchmark orders: this attribute will contain the conId of the contract against which the order will be pegged.
Optional referencePegged-to-benchmark orders: the exchange against which we want to observe the reference contract.
Optional referenceSpecifies how you want TWS to calculate the limit price for options, and for stock range price monitoring.
VOL orders only.
Valid values include:
Optional routeTODO: document
Optional rule80APossible values:
Optional scaleTODO document. For extended Scale orders.
Optional scaleTODO document. For extended Scale orders.
Optional scaleDefines the size of the first, or initial, order component.
For Scale orders only.
Optional scaleTODO document. For extended Scale orders.
Optional scaleTODO document. For extended Scale orders.
Optional scaleTODO document. For extended Scale orders.
Optional scaleDefines the price increment between scale components.
For Scale orders only. This value is compulsory.
Optional scaleTODO document. For extended Scale orders.
Optional scaleTODO document. For extended Scale orders.
Optional scaleDefines the order size of the subsequent scale order components.
For Scale orders only. Used in conjunction with scaleInitLevelSize().
Optional scaleUsed for scale orders.
Optional settlingInstitutions only.
Indicates the firm which will settle the trade.
Optional shareholderTODO: document
Optional shortFor institutions only. Valid values are:
Optional smartAdvanced parameters for Smart combo routing.
These features are for both guaranteed and non-guaranteed combination orders routed to Smart, and are available based on combo type and order type. SmartComboRoutingParams is similar to AlgoParams in that it makes use of tag/value pairs to add parameters to combo orders.
Make sure that you fully understand how Advanced Combo Routing works in TWS itself first: https://www.interactivebrokers.com/en/software/tws/usersguidebook/specializedorderentry/advanced_combo_routing.htm
The parameters cover the following capabilities:
Tag = NonGuaranteed
Value = 0: The order is guaranteed
Value = 1: The order is non-guaranteed
Tag = LeginPrio
Value = -1: No priority is assigned to either combo leg
Value = 0: Priority is assigned to the first leg being added to the comboLeg
Value = 1: Priority is assigned to the second leg being added to the comboLeg
Note: The LeginPrio parameter can only be applied to two-legged combo.
Tag = MaxSegSize
Value = Unit of combo size
Tag = DontLeginNext
Value = 0: Start next leg-in even if previous leg-in did not finish Value = 1: Do not start next leg-in if previous leg-in did not finish
Tag = PriceCondConid: The ContractID of the combo leg to specify price condition on
Value = The ContractID
Tag = CondPriceMin: The lower price range of the price condition
Value = The lower price
Tag = CondPriceMax: The upper price range of the price condition
Value = The upper price
Optional softDefine the Soft Dollar Tier used for the order. Only provided for registered professional advisors and hedge and mutual funds.
Optional solicitedTODO document
Optional startingThe auction's starting price. For BOX orders only.
Optional stockThe lower value for the acceptable underlying stock price range. For price improvement option orders on BOX and VOL orders with dynamic management.
Optional stockThe upper value for the acceptable underlying stock price range. For price improvement option orders on BOX and VOL orders with dynamic management.
Optional stockThe stock's reference price. The reference price is used for VOL orders to compute the limit price sent to an exchange (whether or not Continuous Update is selected), and for price range monitoring.
Optional sweepIf set to true, specifies that the order is a Sweep-to-Fill order.
Optional tierDefine the Soft Dollar Tier used for the order. Only provided for registered professional advisors and hedge and mutual funds.
Optional tifThe time in force.
Valid values are:
Optional totalThe number of positions being bought/sold.
Optional trailTrail stop price for TRAILIMIT orders.
Optional trailingSpecifies the trailing amount of a trailing stop order as a percentage.
This field is mutually exclusive with the existing trailing amount. That is, the API client can send one or the other but not both.
This field is read AFTER the stop price (barrier price) as follows: deltaNeutralAuxPrice stopPrice, trailingPercent, scale order attributes
The field will also be sent to the API in the openOrder message if the API client version is >= 56. It is sent after the stopPrice field as follows: stopPrice, trailingPct, basisPoint
Optional transmitSpecifies whether the order will be transmitted by TWS. If set to false`, the order will be created at TWS but will not be sent.
Optional triggerSpecifies how Simulated Stop, Stop-Limit and Trailing Stop orders are triggered.
Valid values are:
Optional triggerTODO: document
Optional useTODO: document
Optional volatilityThe option price in volatility, as calculated by TWS' Option Analytics. This value is expressed as a percent and is used to calculate the limit price sent to the exchange.
Optional volatilityValues include:
Optional whatAllows to retrieve the commissions and margin information.
When placing an order with this attribute set to `true, the order will not be placed as such. Instead it will used to request the commissions and margin information that would result from this order.
Generated using TypeDoc
The order's description.