pub struct Order {Show 29 fields
pub account_id: String,
pub order_id: String,
pub exchange_order_id: Option<String>,
pub parent_order_id: Option<String>,
pub status: OrderStatus,
pub status_message: Option<String>,
pub status_message_raw: Option<String>,
pub order_timestamp: DateTime<Utc>,
pub exchange_timestamp: Option<DateTime<Utc>>,
pub exchange_update_timestamp: Option<DateTime<Utc>>,
pub trading_symbol: String,
pub exchange: Exchange,
pub instrument_token: u32,
pub order_type: OrderType,
pub transaction_type: TransactionType,
pub validity: Validity,
pub product: Product,
pub quantity: u32,
pub disclosed_quantity: u32,
pub price: f64,
pub trigger_price: f64,
pub average_price: f64,
pub filled_quantity: u32,
pub pending_quantity: u32,
pub cancelled_quantity: u32,
pub market_protection: f64,
pub meta: Option<OrderMeta>,
pub tag: Option<String>,
pub guid: String,
}Expand description
Order data structure as returned by KiteConnect API
Fields§
§account_id: StringAccount ID
order_id: StringOrder ID assigned by the system
exchange_order_id: Option<String>Exchange order ID
parent_order_id: Option<String>Parent order ID for bracket/cover orders
status: OrderStatusOrder status
status_message: Option<String>Status message from exchange
status_message_raw: Option<String>Status message from OMS
order_timestamp: DateTime<Utc>Order timestamp
exchange_timestamp: Option<DateTime<Utc>>Exchange timestamp
exchange_update_timestamp: Option<DateTime<Utc>>Exchange update timestamp
trading_symbol: StringTrading symbol
exchange: ExchangeExchange
instrument_token: u32Instrument token
order_type: OrderTypeOrder type
transaction_type: TransactionTypeTransaction type (BUY/SELL)
validity: ValidityValidity
product: ProductProduct type
quantity: u32Quantity
disclosed_quantity: u32Disclosed quantity
price: f64Price
trigger_price: f64Trigger price for SL orders
average_price: f64Average price at which the order was executed
filled_quantity: u32Filled quantity
pending_quantity: u32Pending quantity
cancelled_quantity: u32Cancelled quantity
market_protection: f64Market protection percentage
meta: Option<OrderMeta>Meta information
tag: Option<String>Tag for the order
guid: StringGUID for idempotency
Implementations§
Source§impl Order
impl Order
Sourcepub fn is_complete(&self) -> bool
pub fn is_complete(&self) -> bool
Check if order is completed
Sourcepub fn is_cancelled(&self) -> bool
pub fn is_cancelled(&self) -> bool
Check if order is cancelled
Sourcepub fn is_rejected(&self) -> bool
pub fn is_rejected(&self) -> bool
Check if order is rejected
Sourcepub fn remaining_quantity(&self) -> u32
pub fn remaining_quantity(&self) -> u32
Get remaining quantity
Sourcepub fn is_partially_filled(&self) -> bool
pub fn is_partially_filled(&self) -> bool
Check if order is partially filled
Sourcepub fn fill_percentage(&self) -> f64
pub fn fill_percentage(&self) -> f64
Get fill percentage