| Crates.io | crypto-client |
| lib.rs | crypto-client |
| version | 0.1.0 |
| created_at | 2020-12-30 09:20:38.263545+00 |
| updated_at | 2020-12-30 09:20:38.263545+00 |
| description | An unified restful client for all cryptocurrency exchanges. |
| homepage | https://github.com/soulmachine/crypto-crawler-rs/tree/main/crypto-client |
| repository | https://github.com/soulmachine/crypto-crawler-rs/tree/main/crypto-client |
| max_upload_size | |
| id | 329178 |
| size | 2,587 |
An unified client for all cryptocurrency exchanges.
use crypto_client::{CryptoClient, MarketType};
fn main() {
let config: HashMap<&str, &str> = vec![
("eosAccount", "your-eos-account"),
("eosPrivateKey", "your-eos-private-key"),
].into_iter().collect();
let crypto_client = CryptoClient::new(config);
// buy
let transaction_id = crypto_client.place_order(
{ exchange: "Newdex", pair: "EIDOS_EOS", market_type: "Spot" },
0.00121,
9.2644,
false,
);
println!("{}", transactionId);
}