coinmarket 0.1.2

Coin Market is a simple library designed to make it easy get market information for cryptocurrencies from exchanges like Shapeshift.
Documentation

Coin Market

Coin Market is a simple library designed to make it easy get market information for cryptocurrencies from exchanges like Shapeshift.

Installation

[dependencies]
coinmarket = "0.1"`

Example

 extern crate coinmarket;
 use coinmarket::exchange::CoinExchange;

 pub fn main() {
      // Tell the exchange we want to pair against Bitcoin and Monero
     let exchange = CoinExchange::new("btc", "xmr");
     // Get the market info of Bitcoin in Monero
     let market_info = exchange.get_market_info().expect("parsing error");

     // Print the market rate
     println!("{}", market_info.rate);
}