January 2020
Intermediate to advanced
530 pages
11h 11m
English
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.
Read now
Unlock full access