Creating the user accounts

Before we can create our assets and exchange, we need to create our user accounts. Stellar accounts are similar to Ethereum accounts, and they allow users to interact with the Stellar network through transactions. They contain a public key (which is referred to as an account ID) and a secret key or private key, which is used to sign transactions submitted to the ledger.

The stellar-sdk provides a utility called Keypair.random, which generates a random ed25519 public-private key pair that can be used as a Stellar account. For a public-private key pair to be a valid account on the Stellar network, it needs a minimum balance of 20 lumens.

To create an account on our private network, we'll generate a new public-private key pair and fund it with a balance of more than 20 lumens. 

To do so, we'll write a small node-js application that will generate a new key pair, and fund it.

Lumens is the native currency of the Stellar network. By default, the private instance issues 100 billion lumens and assigns it to a root account on the network. It is referred to by the symbol XLM. The minimum Stellar amount is referred to as stroop. It is one ten-millionth, 1/10000000, or 0.0000001. The term stroop is used as a convenient way to refer to these small measurements of amounts. The plural form is stroops (for example, 100 stroops).
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.149.251.155