pub struct GetDepth { /* private fields */ }Expand description
Request builder for GET /api/v3/depth.
Implementations§
Source§impl GetDepth
impl GetDepth
Sourcepub fn limit(self, limit: u32) -> Self
pub fn limit(self, limit: u32) -> Self
Levels per side, sent as given. Any value is accepted, and a limit past 5000 returns 5000 levels. Sets the weight: up to 100 costs 5, up to 500 costs 25, up to 1000 costs 50, more costs 250.
Sourcepub async fn send(self) -> Result<Depth, SpotError>
pub async fn send(self) -> Result<Depth, SpotError>
Waits for the budget, sends, and decodes the response.
A 429 holds every request on the budget, then this request is
retried on the client’s schedule; with no retry left and no
Retry-After, the hold runs to the next UTC minute. A 418 holds
every request for its Retry-After, or 2 minutes, and is not retried.
The wait has no deadline of its own: a request can wait out a minute’s
spent budget or a ban, which Binance documents at up to 3 days. Wrap
the call in tokio::time::timeout where a caller needs a deadline.
Auto Trait Implementations§
impl !RefUnwindSafe for GetDepth
impl !UnwindSafe for GetDepth
impl Freeze for GetDepth
impl Send for GetDepth
impl Sync for GetDepth
impl Unpin for GetDepth
impl UnsafeUnpin for GetDepth
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