pegnetd

Crates.iopegnetd
lib.rspegnetd
version0.1.2
sourcesrc
created_at2019-12-13 00:47:19.266583
updated_at2019-12-16 00:48:01.94787
descriptionPegnetd API client
homepagehttps://github.com/kompendium-llc/pegnetd-rust-client
repositoryhttps://github.com/kompendium-llc/pegnetd-rust-client
max_upload_size
id188952
size89,103
Mitchell Berry (mberry)

documentation

README

Pegnetd Client

Crates.io Released API docs Discord

Usage

In cargo.toml:

pegnetd = "0.1.2"

Quickstart

#[tokio::main]
async fn main() -> Result<(), reqwest::Error> {
  let api = Pegnetd::open_node();
  let response = sync_status(&api).await;
  assert!(response.result.syncheight > 0);
  Ok(())
}

Configuration

// Local Node Configuration
// http://localhost:8070/v1
let api = Pegnetd::new();

// Public Node Configuration
// https://api.pegnetd.com
let api = Pegnetd::open_node();

// Custom Node Configuration
let api = Pegnetd::custom_node("http://192.168.1.42:8070/v1");

Documentation

Contributing

PR's welcome. Fork the library and submit to dev branch. By contributing to this library you agree to it being Apache 2.0 licensed

Commit count: 24

cargo fmt