Created
November 2, 2020 22:41
-
-
Save kushti/e02128c511831f2c476919c79bdd0da3 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pub use ergo_node_interface::node_interface::{NodeInterface, NodeError}; | |
fn main() { | |
let api_key= "..."; | |
let ip = "127.0.0.1"; | |
let port= "9053"; | |
let node = NodeInterface::new(api_key, ip, port); | |
let h: Result<u64, NodeError> = node.current_block_height(); | |
println!("Current height: {}", h.unwrap_or_default()); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment