eosio.tokencontract that is important for this section. Navigate to the
createaction with the correct parameters. This action accepts 1 argument, it consists of:
alice. This issuer will be the one with the authority to call
issueand/or perform other actions such as closing accounts or retiring tokens.
assettype composed of two pieces of data, a floating-point number sets the maximum supply and a
symbolin capitalized alpha characters which represents the asset. For example, "1.0000 SYS".
SYSwith a precision of 4 decimals and a maximum supply of 1000000000.0000 SYS. It also designates
aliceas the issuer. To create this token, the contract requires the permission of the
eosio.tokenaccount. For this reason,
-p [email protected]was passed to authorize this action.
issueaction and three
transferactions. While the only action signed was
issueaction performed an
inline transferand the
inline transfernotified the sender and receiver accounts. The output indicates all the action handlers that were called, the order they were called in, and whether any output was generated by the action.
eosio.tokencontract could have skipped the
inline transferand opted to just modify the balances directly. However, in this case the
eosio.tokencontract is following a token convention that requires that all account balances be derivable by the sum of the transfer actions that reference them. It also requires that the sender and receiver of funds be notified so they can automate handling deposits and withdrawals.
-d -joptions, which indicate "don't broadcast" and "return the transaction as json", which you may find useful during development.
alicehas been issued tokens, transfer some of them to account
alice's balance. Notice that tokens were deducted from the account.