pub struct GetTradesParams {
pub category: Category,
pub symbol: Option<String>,
pub base_coin: Option<String>,
pub option_type: Option<OptionType>,
pub limit: Option<u64>,
}Expand description
Query parameters of GET /v5/market/recent-trade (Client::get_public_recent_trading_history).
Fields§
§category: CategoryProduct type. spot, linear, inverse, option.
symbol: Option<String>required for spot/linear/inverse optional for option
base_coin: Option<String>Apply to option only If the field is not passed, return BTC data by default
option_type: Option<OptionType>Option type. Apply to option only
limit: Option<u64>spot: [1, 60], default: 60
others: [1, 1000], default: 500
Implementations§
Source§impl GetTradesParams
impl GetTradesParams
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: required for spot/linear/inverse optional for option.
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: apply to option only If the field is not passed, return BTC data by default.
Sourcepub fn with_option_type(self, v: OptionType) -> Self
pub fn with_option_type(self, v: OptionType) -> Self
Set option_type: option type. Apply to option only.
Sourcepub fn with_limit(self, v: u64) -> Self
pub fn with_limit(self, v: u64) -> Self
Set limit: spot: [1, 60], default: 60 others: [1, 1000], default: 500.
Trait Implementations§
Source§impl Clone for GetTradesParams
impl Clone for GetTradesParams
Source§impl Debug for GetTradesParams
impl Debug for GetTradesParams
Auto Trait Implementations§
impl Freeze for GetTradesParams
impl RefUnwindSafe for GetTradesParams
impl Send for GetTradesParams
impl Sync for GetTradesParams
impl Unpin for GetTradesParams
impl UnsafeUnpin for GetTradesParams
impl UnwindSafe for GetTradesParams
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