Creating a new asset object

Creating an asset object on the Stellar network is an easy affair. All you need to do is use the Asset method of the Stellar SDK, as shown in the following code. The Asset method has two input parameters—Asset Code and Issuer Account. Asset Code is an alphanumeric code that's used to refer to the asset. The Issuer Account is the account that is used to create the asset:

Asset = new StellarSdk.Asset(<Code>,<Issuing Account>).
var USD = new StellarSdk.Asset('USD', 'GBUM3XRJKUVEQA4UF63CUCS3P72C5AZTRYI2VKELS7T7DVCCLV3DODNE');

The preceding code shows how we'll do this for the USD asset.

..................Content has been hidden....................

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