KIP | Title | Author | Status | Type | Category | Created |
---|---|---|---|---|---|---|
2 |
fungible-v1 |
Stuart Popejoy stuart@kadena.io |
Final |
Standard |
Chainweb |
2019-10-08 |
Define and implement a Pact interface to provide a fungible coin or token standard, drawing inspiration from ERC-20 and related token standards.
The outstanding motivation at time of writing is to ensure interoperability between the Kadena token, as implemented in the "coin contract", and tokens that will exist on the system.
Otherwise, ERC-20 and related standards have proved their worth many times over. However Pact has
it's own way of doing things and fungible
reflects that.
This can be specified in a separate interface, but for the coin contract, this is an expensive feature that is unnecessary for runtime operation, and is better handled by off-chain market data.
This fits with Pact's embrace of arbitrary-precision Decimal which is safe and expressive to use. However there is no practical limit on precision, so this is an important specification for a token, and indeed for the coin contract.
Things like name
, symbol
and other asset metadata are not relevant here.
As noted above, managed capabilities allow for safe inter-contract transfer within a single transaction. This addresses one need of on-behalf-of in a single transaction.
The ability to lock up an amount for another party in a later transaction is not specified. This can be easily achieved by creating dedicated escrow accounts with multisig and/or a user guard if features like timeouts are desired.
Whitelisting/blacklisting and other security token standards are not specified.
N/A
See fungible-v1.pact