Crates.io | helius-rust-client |
lib.rs | helius-rust-client |
version | 0.1.0 |
source | src |
created_at | 2023-04-26 06:04:22.149709 |
updated_at | 2023-04-26 06:04:22.149709 |
description | A rust client wrapping Helius APIs and the standard Solana RPC client |
homepage | |
repository | |
max_upload_size | |
id | 849068 |
size | 59,748 |
Rust client for Helius's Solana APIs and standard Solana RPC calls. Read more about Helius's APIs here.
Available on crates.io.
Add the crate to your Cargo.toml
.
helius-rust-client = "0.1.0"
let client = HeliusClient::new(
"your-api-key".to_string(),
solana_sdk::genesis_config::ClusterType::MainnetBeta,
);
let token_balances = client
.get_token_balances("YourAddress".to_string())
.await.unwrap();
println!("token balances: {:?}", token_balances);
More examples can be found in the [tests
] directory (in the form of tests). Provide an API key and addresses and run them with -- --nocapture
in order to see the printed outputs.