bpx_api_types/
futures.rs

1use serde::{Deserialize, Serialize};
2
3use crate::margin::MarginFunction;
4
5#[derive(Debug, Clone, Serialize, Deserialize)]
6#[serde(rename_all = "camelCase")]
7pub struct FuturePosition {
8    pub break_even_price: String,
9    pub cumulative_funding_payment: String,
10    pub cumulative_interest: String,
11    pub entry_price: String,
12    pub est_liquidation_price: String,
13    pub imf: String,
14    pub imf_function: MarginFunction,
15    pub mark_price: String,
16    pub mmf: String,
17    pub mmf_function: MarginFunction,
18    pub net_cost: String,
19    pub net_exposure_notional: String,
20    pub net_exposure_quantity: String,
21    pub net_quantity: String,
22    pub pnl_realized: String,
23    pub pnl_unrealized: String,
24    pub position_id: String,
25    pub subaccount_id: Option<u64>,
26    pub symbol: String,
27    pub user_id: u64,
28}