Struct crypto_rest_client::ZbgSwapRestClient
source · pub struct ZbgSwapRestClient { /* private fields */ }
Expand description
The RESTful client for ZBG swap markets.
- RESTful API doc: https://zbgapi.github.io/docs/future/v1/en/
- Trading at: https://futures.zbg.com/
Implementations§
source§impl ZbgSwapRestClient
impl ZbgSwapRestClient
pub fn new(api_key: Option<String>, api_secret: Option<String>) -> Self
sourcepub fn fetch_l2_snapshot(symbol: &str) -> Result<String, Error>
pub fn fetch_l2_snapshot(symbol: &str) -> Result<String, Error>
Get the latest Level2 snapshot of orderbook.
Top 200 bids and asks are returned.
For example: https://www.zbg.com/exchange/api/v1/future/market/depth?symbol=BTC_USD-R&size=200