pub struct ClosedPnl {Show 18 fields
pub symbol: String,
pub order_id: String,
pub order_link_id: Option<String>,
pub side: Side,
pub qty: Decimal,
pub order_price: Decimal,
pub order_type: OrderType,
pub exec_type: ExecType,
pub closed_size: Decimal,
pub cum_entry_value: Decimal,
pub avg_entry_price: Decimal,
pub cum_exit_value: Decimal,
pub avg_exit_price: Decimal,
pub closed_pnl: Decimal,
pub fill_count: i64,
pub leverage: Decimal,
pub created_time: Timestamp,
pub updated_time: Timestamp,
}Expand description
Item of the list returned by GET /v5/position/closed-pnl (Client::get_closed_pnl).
Fields§
§symbol: StringSymbol name.
order_id: StringOrder ID.
order_link_id: Option<String>User customised order ID.
side: SideBuy, Sell.
qty: DecimalOrder qty.
order_price: DecimalOrder price.
order_type: OrderTypeOrder type. Market, Limit.
exec_type: ExecTypeExec type Trade, BustTrade SessionSettlePnL Settle, MovePosition ForwardSplitSettle, ReverseSplitSettle.
closed_size: DecimalClosed size.
cum_entry_value: DecimalCumulated Position value.
avg_entry_price: DecimalAverage entry price.
cum_exit_value: DecimalCumulated exit position value.
avg_exit_price: DecimalAverage exit price.
closed_pnl: DecimalClosed PnL.
fill_count: i64The number of fills in a single order.
leverage: DecimalLeverage.
created_time: TimestampThe created time (ms).
updated_time: TimestampThe updated time (ms).
Trait Implementations§
Source§impl<'de> Deserialize<'de> for ClosedPnl
impl<'de> Deserialize<'de> for ClosedPnl
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for ClosedPnl
Auto Trait Implementations§
impl Freeze for ClosedPnl
impl RefUnwindSafe for ClosedPnl
impl Send for ClosedPnl
impl Sync for ClosedPnl
impl Unpin for ClosedPnl
impl UnsafeUnpin for ClosedPnl
impl UnwindSafe for ClosedPnl
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more