Rust API bindings for the Opennode v1 HTTP API. This library rely on rust Futures to allow asynchronous usage.
Put this in your Cargo.toml
:
toml
[dependencies]
opennode = "0.1.0"
And this in your crate root:
rust
extern crate opennode;
cargo test
Run file from examples with:
cargo run --example <example> -- <example flags> <example args>
To get started, create a client:
rust
let client = opennode::client::Client::new("OPENNODE-TOKEN");
Let's create a new charge using an actor system like actix_rt:
```rust use opennode::charge;
// opennode::charge::create signature:
// (client: &Client, payload: Payload) -> impl Future
let charge: charge::Charge = System::new("test").block_on(lazy(|| { charge::create(&client, charge::Payload::new(1000)) })).unwrap(); ```