Creates a token declaration datum and places it in the mempool
CLI Example
Command syntax:
token_decl
-net <net_name>
-chain <chain_name>
-token <token_ticker>
-total_supply <total_supply>
-signs_total <sign_total>
-signs_emission <signs_for_emission>
-decimals <18>
-certs <certs_list>
Options:
-net - name of the Cellframe Network. The list of networks can be found in the <Config_dir> \ etc \ network folder or received by The Cellframe-Node-CLI using command - net list
-chain - name of the chain where token was declared
-token - ticker (name) of the token
-total_supply - maximum sum of all token emissions (in datoshi)
-signs_total - quantity of authorized token signatures
-signs_emission - quantity of authorized token signatures required fot it's emission
-decimals - number accuration after comma (18 by default)
-certs - certificates which is used to sign token (you can use any certificate)
Example:
Command:
cellframe-node-cli token_decl
-net foobar
-chain zero
-token LLL
-total_supply 1000.0e+18
-signs_total 1
-signs_emission 1
-decimals 18
-certs foobar.root.pvt.0
Response:
Datum 0xFE3C0D5CEBAB54957121C01C12017164E516D60709B6BE10BC7EE98758BF4429 with token ZZZ is placed in datum pool
JSON-RPC Example
Command:
curl -X POST http://rpc.cellframe.net/connect -d '{"method":"token_decl", "params":["token_decl;-net;foobar;-chain;zero;-token;JJJ;-total_supply;0;-signs_total;1;-signs_emission;1;-decimals;18;-certs;foobar.root.pvt.0"], "id":"1"}'
Response:
{
"type": 0,
"result": "Datum 0x751E62A4B44CA3A2DE0B77FFD4DCA5F0F317365B02C3AE8A9829734354A60C20 with token JJJ is placed in datum pool",
"errors": null,
"id": 1
}