Token Types – NFTs, FTs, NTTs

Non-Fungible Tokens (NFTs)

NFTs are the most common type of digital assets. They are used to express unique tokens.

NFT Structure

Simple Asset NFTs are divided into mdata (data which the author can update at any time, regardless of ownership), and idata (data which is set upon the NFT’s creation and can never be updated).

Both are stringified JSONs. For example: {\”key1\”:\”some-string\”, \”key2\”:5}

Category is an optional field that lets you group your NFTs for convenience. Category names must be less than or equal to 12 characters (a-z, 1-5).

Offer/Claim versus Transfer – If you transfer an NFT, the sender pays for RAM. As an alternative, you can simply offer the NFT, and the user claiming will pay for their RAM. (Note: we are working toward a feature that allows NFT authors to reserve a lot of RAM which will spare users for paying for transfers.)

RAM usage

RAM usage for NFTs depends on how much data is stored in the idata and mdata fields. If they both empty, each NFT takes up 276 bytes.

Each symbol in idata and mdata is +1 byte.

 

Fungible Tokens (FTs)

Dapps which need Fungible tokens should decide between using the standard eosio.token contract, and the Simple Assets contract. Here are the differences:

In Simple Assets,

  • Scope is Author instead of Symbol
  • Stat table includes also additional data about each FT (see Currency Stats below)
  • For transfers you need to use transferf action from SA contract.
  • If author sets authorcontrol flag, the author can transfers/burn/etc user’s FTs independent of user’s consent.
  • The table which tracks FTs includes the author’s account name, allowing different dapps to have FTs with the same name. (Example: https://bloks.io/contract?tab=Tables&table=accounts&account=simpleassets&scope=bohdanbohdan&limit=100)

(Note: Fungible Tokens also have offer/claim functionality as an alternative to transfers. For FTs, the only time the sender would pay for RAM would be if the receiver never before held those FTs. It uses approximately 300 bytes to create the FT table.)

 

Non-Transferrable Tokens (NTTs)

The two most likely use cases for NTTs are

licenses which can be granted to an account, but not transfered.
prizes and awards given to a particular account.

The reasons for using NTTs are:

the NTTs appearing in third party asset explorers.
some functionality is handled by Simple Assets.

More on NTTs: https://medium.com/@cryptolions/introducing-non-transferable-tokens-ntts-2f1a532bf170