项目作者: michielpost

项目描述 :
Nano RPC Client library in C#
高级语言: C#
项目地址: git://github.com/michielpost/NanoRPC.git
创建时间: 2018-03-03T21:09:35Z
项目社区:https://github.com/michielpost/NanoRPC

开源协议:MIT License

下载


Build .NET

NanoRPC

Nano RPC Client and Nano Wallet library in C#

Easily communicate with a Nano Node using C#
This library includes a programmable wallet to easily receive and send Nano. It can be used in ASP.Net, Desktop apps and also in the browser using Blazor WebAssembly.

Donation address: nano_14ezmbmoj5zqzoj7g99bec1rfr7woe1d7bsa87wmsbfpt4u4mnur8183oqtm

Live Blazor WebAssembly Wallet Demo

How To install?

Download the source from GitHub or get the compiled assembly from NuGet NanoRPC on NuGet.

Example Usage

  1. var client = NanoClient.GetClient("http://url_to_nano_node:port");
  2. var balanceResult = await _client.AccountBalance(new AccountBalanceRequest() { Account = "xrb_1cyca8x1u4bdi3m6aqjx1ouwayrnais7aucc33w9zxdtrwqaoxdt8yfdzm94" });

Wallet

  1. var client = NanoClient.GetClient(A"http://url_to_nano_node:port");
  2. var manager = new NanoAccountManager(client, "nano_default_representative_address", "HEX SEED STRING");
  3. var wallet = manager.GetNanoWallet(i);
  4. var balance = await wallet.GetBalanceAsync();
  5. //Send Nano
  6. await wallet.SendNano("To Address", amount);

Supported RPC methods

All RPC methods are supported.
List of RPC methods: https://docs.nano.org/commands/rpc-protocol/

Please create an issue if something is not working as expected. Pull Requests are also welcome!

License

NanoRPC is licensed under MIT. Refer to LICENSE for more information.

Contributions

Contributions are welcome. Fork this repository and send a pull request if you have something useful to add.

Open Source Project Credits

This library uses RestEase https://github.com/canton7/RestEase