Function crypto_markets::fetch_markets
source · [−]Expand description
Fetch trading markets of a cryptocurrency exchange.
Arguments
exchange
- The exchange namemarket_type
- The market type
Example
use crypto_markets::fetch_markets;
use crypto_market_type::MarketType;
let markets = fetch_markets("binance", MarketType::Spot).unwrap();
assert!(!markets.is_empty());
println!("{}", serde_json::to_string_pretty(&markets).unwrap())