This guide is aimed at developers willing to integrate their software with Witnet and the Wit coin in such a way that they can manage addresses, balances, and create and verify transactions.
Witnet-Rust can be easily run:
Witnet-Rust contains two different components that provide different degrees of wallet functionality:
nodecomponent is standalone — you can run it on its own and it will provide full-node functionality: syncing up the Witnet block chain, validate transactions and blocks in real time, and (optionally) propose blocks.
[YOUR APP] → [WITNET-RUST NODE] → [WITNET NETWORK]
docker run -d \
--name witnet_node \
--volume ~/.witnet:/.witnet \
--publish 21337:21337 \
--publish 21338:21338 \
--restart always \
Here is a quick guide on how to interact with a node using the JSON-RPC interface and any TCP client:
walletcomponent is NOT standalone. It requires a connection to an instance of the
nodecomponent that will act as its "backend":
[YOUR APP] → [WITNET-RUST WALLET] → [WITNET-RUST NODE] → [WITNET NETWORK]
Witnet Foundation operates a cluster of publicly available
nodeinstances that act as the backend for the
walletcomponent contained within the Sheikah Witnet wallet desktop app, which follows exactly the same architecture:
Sheikah Wallet app architecture:
[SHEIKAH UI*] → [WITNET-RUST WALLET*] → [WITNET-RUST NODE] → [WITNET NETWORK]
* The Sheikah UI and the Witnet-Rust wallet are run in the user's computer.
For users looking for the maximum degree of privacy, it is recommended that they run their own instance of the
nodecomponent, because otherwise they may be disclosing their addresses and balances to 3rd parties, as the queries between the
nodecomponents need to be sent over the Internet.
The JSON-RPC API of the
walletcomponent is different than the one from the
nodenot because it has much more advanced wallet functionality, and uses a WebSockets transport instead of plain TCP (this is to enable web wallets and similar apps).