pub struct GetOrderHistoryParams {
pub category: Category,
pub symbol: Option<String>,
pub base_coin: Option<String>,
pub settle_coin: Option<String>,
pub order_id: Option<String>,
pub order_link_id: Option<String>,
pub order_filter: Option<OrderFilter>,
pub order_status: Option<OrderStatus>,
pub start_time: Option<Timestamp>,
pub end_time: Option<Timestamp>,
pub limit: Option<i32>,
pub cursor: Option<String>,
}Expand description
Query parameters of GET /v5/order/history (Client::get_order_history).
Fields§
§category: CategoryProduct type linear, inverse, spot, option.
symbol: Option<String>Symbol name, like BTCUSDT, uppercase only.
base_coin: Option<String>Base coin, uppercase only.
settle_coin: Option<String>Settle coin, uppercase only.
order_id: Option<String>Order ID.
order_link_id: Option<String>User customised order ID.
order_filter: Option<OrderFilter>Order: active order StopOrder: conditional order for Futures and Spot tpslOrder: spot TP/SL order OcoOrder: spot OCO orders BidirectionalTpslOrder: Spot bidirectional TPSL order all kinds of orders are returned by default.
order_status: Option<OrderStatus>Order status.
start_time: Option<Timestamp>Start timestamp (ms)
end_time: Option<Timestamp>End timestamp (ms)
limit: Option<i32>[1, 50]. Default: 20
cursor: Option<String>Cursor. Use the nextPageCursor token from the response to retrieve the next page of the result set.
Implementations§
Source§impl GetOrderHistoryParams
impl GetOrderHistoryParams
Sourcepub fn new(category: Category) -> Self
pub fn new(category: Category) -> Self
Create with the required fields; set the optional ones with the with_* methods.
Sourcepub fn with_symbol(self, v: impl Into<String>) -> Self
pub fn with_symbol(self, v: impl Into<String>) -> Self
Set symbol: symbol name, like BTCUSDT, uppercase only.
Sourcepub fn with_base_coin(self, v: impl Into<String>) -> Self
pub fn with_base_coin(self, v: impl Into<String>) -> Self
Set base_coin: base coin, uppercase only.
Sourcepub fn with_settle_coin(self, v: impl Into<String>) -> Self
pub fn with_settle_coin(self, v: impl Into<String>) -> Self
Set settle_coin: settle coin, uppercase only.
Sourcepub fn with_order_id(self, v: impl Into<String>) -> Self
pub fn with_order_id(self, v: impl Into<String>) -> Self
Set order_id: order ID.
Sourcepub fn with_order_link_id(self, v: impl Into<String>) -> Self
pub fn with_order_link_id(self, v: impl Into<String>) -> Self
Set order_link_id: user customised order ID.
Sourcepub fn with_order_filter(self, v: OrderFilter) -> Self
pub fn with_order_filter(self, v: OrderFilter) -> Self
Set order_filter: order: active order StopOrder: conditional order for Futures and Spot tpslOrder: spot TP/SL order OcoOrder: spot OCO orders BidirectionalTpslOrder: Spot bidirectional TPSL order all kinds of orders are returned by default.
Sourcepub fn with_order_status(self, v: OrderStatus) -> Self
pub fn with_order_status(self, v: OrderStatus) -> Self
Set order_status: order status.
Sourcepub fn with_start_time(self, v: Timestamp) -> Self
pub fn with_start_time(self, v: Timestamp) -> Self
Set start_time: start timestamp (ms).
Sourcepub fn with_end_time(self, v: Timestamp) -> Self
pub fn with_end_time(self, v: Timestamp) -> Self
Set end_time: end timestamp (ms).
Sourcepub fn with_limit(self, v: i32) -> Self
pub fn with_limit(self, v: i32) -> Self
Set limit: [1, 50]. Default: 20.
Sourcepub fn with_cursor(self, v: impl Into<String>) -> Self
pub fn with_cursor(self, v: impl Into<String>) -> Self
Set cursor: cursor. Use the nextPageCursor token from the response to retrieve the next page of the result set.