Struct ib_client::models::order_request::OrderRequest[][src]

pub struct OrderRequest {
    pub acct_id: Option<String>,
    pub conid: Option<i32>,
    pub sec_type: Option<String>,
    pub c_oid: Option<String>,
    pub parent_id: Option<String>,
    pub order_type: Option<String>,
    pub listing_exchange: Option<String>,
    pub outside_rth: Option<bool>,
    pub price: Option<f32>,
    pub side: Option<String>,
    pub ticker: Option<String>,
    pub tif: Option<String>,
    pub referrer: Option<String>,
    pub quantity: Option<f32>,
    pub fx_qty: Option<f32>,
    pub use_adaptive: Option<bool>,
    pub is_currency_conversion: Option<bool>,
    pub allocation_method: Option<String>,
}

Fields

acct_id: Option<String>

acctId is optional. It should be one of the accounts returned by /iserver/accounts. If not passed, the first one in the list is selected.

conid: Option<i32>

conid is the identifier of the security you want to trade, you can find the conid with /iserver/secdef/search.

sec_type: Option<String>

conid:type for example 265598:STK

c_oid: Option<String>

Customer Order ID. An arbitraty string that can be used to identify the order, e.g "my-fb-order". The value must be unique for a 24h span. Please do not set this value for child orders when placing a bracket order.

parent_id: Option<String>

When placing bracket orders, the child parentId must be equal to the cOId (customer order id) of the parent.

order_type: Option<String>

orderType can be one of MKT (Market), LMT (Limit), STP (Stop) or STP_LIMIT (stop limit)

listing_exchange: Option<String>

listingExchange is optional. By default we use "SMART" routing. Possible values are available via this end point: /v1/portal/iserver/contract/{{conid}}/info, see valid_exchange: e.g: SMART,AMEX,NYSE, CBOE,ISE,CHX,ARCA,ISLAND,DRCTEDGE,BEX,BATS,EDGEA,CSFBALGO,JE FFALGO,BYX,IEX,FOXRIVER,TPLUS1,NYSENAT,PSX

outside_rth: Option<bool>

set to true if the order can be executed outside regular trading hours.

price: Option<f32>

optional if order is MKT, for LMT, this is the limit price. For STP this is the stop price.

side: Option<String>

SELL or BUY

ticker: Option<String>
tif: Option<String>

GTC (Good Till Cancel) or DAY. DAY orders are automatically cancelled at the end of the Day or Trading hours.

referrer: Option<String>

for example QuickTrade

quantity: Option<f32>

usually integer, for some special cases can be float numbers

fx_qty: Option<f32>

double number, this is the cash quantity field which can only be used for FX conversion order.

use_adaptive: Option<bool>

If true, the system will use the Adaptive Algo to submit the order https://www.interactivebrokers.com/en/index.php?f=19091

is_currency_conversion: Option<bool>

set to true if the order is a FX conversion order

allocation_method: Option<String>

Set the allocation method when placing an order using an FA account for a group Possible allocation methods are "NetLiquidity", "AvailableEquity", "EqualQuantity" and "PctChange".

Implementations

impl OrderRequest[src]

Trait Implementations

impl Clone for OrderRequest[src]

impl Debug for OrderRequest[src]

impl<'de> Deserialize<'de> for OrderRequest[src]

impl PartialEq<OrderRequest> for OrderRequest[src]

impl Serialize for OrderRequest[src]

impl StructuralPartialEq for OrderRequest[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T> Instrument for T[src]

impl<T> Instrument for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.