pub struct OrderRequest {Show 21 fields
pub order_id: Option<String>,
pub instrument_name: String,
pub amount: Option<f64>,
pub contracts: Option<f64>,
pub type_: Option<OrderType>,
pub label: Option<String>,
pub price: Option<f64>,
pub time_in_force: Option<TimeInForce>,
pub display_amount: Option<f64>,
pub post_only: Option<bool>,
pub reject_post_only: Option<bool>,
pub reduce_only: Option<bool>,
pub trigger_price: Option<f64>,
pub trigger_offset: Option<f64>,
pub trigger: Option<Trigger>,
pub advanced: Option<AdvancedOrderType>,
pub mmp: Option<bool>,
pub valid_until: Option<i64>,
pub linked_order_type: Option<LinkedOrderType>,
pub trigger_fill_condition: Option<TriggerFillCondition>,
pub otoco_config: Option<Vec<String>>,
}Expand description
Order request structure for placing orders on Deribit
Fields§
§order_id: Option<String>Unique order identifier
instrument_name: StringName of the instrument to trade
amount: Option<f64>Order amount (for futures and perpetuals)
contracts: Option<f64>Number of contracts (for options)
type_: Option<OrderType>Order type (market, limit, etc.)
label: Option<String>User-defined label for the order
price: Option<f64>Limit price for the order
time_in_force: Option<TimeInForce>Time in force specification
display_amount: Option<f64>Amount to display in the order book
post_only: Option<bool>Whether the order should only be posted (not taken)
reject_post_only: Option<bool>Whether to reject if the order would be posted only
reduce_only: Option<bool>Whether this order only reduces position
trigger_price: Option<f64>Trigger price for conditional orders
trigger_offset: Option<f64>Trigger offset for conditional orders
trigger: Option<Trigger>Trigger type for conditional orders
advanced: Option<AdvancedOrderType>Advanced order type (USD or implied volatility)
mmp: Option<bool>Market maker protection flag
valid_until: Option<i64>Order validity timestamp (Unix timestamp)
linked_order_type: Option<LinkedOrderType>Type of linked order (OTO, OCO, OTOCO)
trigger_fill_condition: Option<TriggerFillCondition>Trigger fill condition for linked orders
otoco_config: Option<Vec<String>>Configuration for OTOCO (One-Triggers-One-Cancels-Other) orders
Trait Implementations§
Source§impl Clone for OrderRequest
impl Clone for OrderRequest
Source§fn clone(&self) -> OrderRequest
fn clone(&self) -> OrderRequest
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more