A simple guide to setting up an Elements Blockchain or Sidechain solution
This guide will take you step-by-step through the process of installing and using Elements
The code examples will show you how to
-
Configure two nodes that can send transactions between one another.
-
Use some basic wallet functionality to send assets between nodes, query balances, view transactions etc.
-
Understand how Confidential Transactions work and how to view amounts and asset types sent between two participants by unblinding them.
-
Issue your own native blockchain assets.
-
Send the new assets between network participants.
-
Reissue more of the assets.
-
Destroy an amount of the assets.
-
Create blocks using the Strong Federation block signing process.
If you choose to run Elements as a sidechain
-
Send assets from a main chain (Bitcoin) to an Elements blockchain using the Federated 2-Way Peg feature.
-
Send assets from an Elements blockchain back to the Bitcoin main chain.
Note: Once you have followed the code tutorial through, you can run all the code within it again without having to type/copy and paste it in line-by-line by following the instructions in the An easy way to run the main tutorial code section. That contains the same code as the tutorial, grouped into one code block, that can be executed one line at a time. The Advanced Examples section shows you how to manually issue an asset using the rawissueasset command, how to prove that you were the one who issued the asset using the contract hash parameter, and how to issue to and spend from a multi-sig address.
The tutorial is divided up into logical parts
Setting up your working environment
Using Elements to perform basic operations
Using Confidential Transactions
Block creation in a Strong Federation
Elements as a standalone Blockchain
Developing applications on Elements
Desktop application example in Python
Web application example in Python using Flask
Desktop application example in C# using .NET Core
MVC Web application example in C# using .NET Core
An easy way to run the main tutorial code
If you want to just run the code and not follow the tutorial you can skip to the An easy way to run the main tutorial code section, although this code is not annotated and steps are not explained.
The instructions have been tested against newly installed Ubuntu 16.04, 17.10.1 and 18.04.1 machines using the “Minimal Installation” Ubuntu install option.
Please note that the terminal commands
used within the tutorial may wrap over more than one line and that each line should be run in its entirety.
By following the guide through to completion you should have enough knowledge to build and deploy your own Elements based blockchain.