NEP-5 Token Standard
NEP-5 gives developers a standardized workflow and template to build decentralized applications. All tokens using the NEP-5 standard are automatically able to transact with any other token using the NEP-5 standard which allows for applications such as decentralized exchanges and other more advanced cross token communication.
Developed in 2017, NEP-5 outlines a token standard for the NEO blockchain that will provide systems with a generalized interaction mechanism for tokenized Smart Contract. It is similar in ecosystem usage as ERC-20 Ethereum tokens in that they are used to extend the core assets to provide standardised token formats. Since the launch of NEP-5 there have been a number of further improvement proposals to the token format, but NEP-5 remains the most commonly used token format for NEO.
An NEP-5 token must have the following methods:
name() returns string: returns the token name
symbol() returns string: returns the token symbol
decimals() returns byte: returns the number of decimals used by the token - how much the token is divisible
totalSupply() returns BigInteger: Get the total token supply deployed in the system
balanceOf(byte account) returns BigInteger: Get the account balance of another account
transfer(byte from, byte to, BigInteger amount) returns bool: Send the amountof tokens from address from to address to
As outlined in the System Fees it costs 490 GAS to deploy an NEP-5 smart contract:
The initial 10 GAS during each execution of every smart contract is always free, including smart contract deployment and invoking. That is, fees that sum up to 10 GAS or less will not require a service fee.
The cost of creating or migrating a smart contract is the basic 100 GAS plus fees of functions the contract requires. If the storage area is required, the function fee is 400 GAS, and if the dynamic call is needed, the function fee is 500 GAS.