How to Create Burnable Token CRC20 Coinex Smart Chain


Burning is an activity that aims to eliminate part of the supply of cryptocurrency tokens, burning can be done automatically, for example a smart contract CRC20 Deflation, it has the characteristic of auto burning for every transfer transaction, or burning can be done manually, for example Developers delete part of token ownership.

Burning has many purposes or goals, but some people tend to aim to reduce supply and increase prices, because when supply decreases, stock will be increasingly scarce and when demand increases, token prices will INCREASE (PUMP). Almost all token developers apply burning to their tokens, usually they also have a regular burning schedule. Burning is one of the developer’s strategies to develop the community and stabilize prices, the holders really like it when developers burn regularly.

CRC20 is a standard token blockchain coinex smart chain, you can add a burning feature to the CRC20 token. In order for the burning feature to work properly on Coinex’s CRC20, you need to add the burnable feature when deploying a smart contract (or during token generation). In this article, we will provide a tutorial on how to create a burnable token crc20 blockchain coinex smart chain. please see step by step

 

 

How to Create Burnable Token CRC20 Coinex Smart Chain

1. Prepare Wallet EVM (Metamask)

I recommend that you use a metamask wallet to make the deployment process easier. Don’t forget to set your rpc wallet, setting the RPC Coinex Smart Chain

RPC URL : https://rpc.coinex.net
Network Name : Coinex Smart Chain
ChainID : 52
Symbol : CET
Block Explorer : https://www.coinex.net

 

2. Prepare Coin CET (coin native coinex smart chain)

To deploy smart contracts and transactions on the coinex smart chain, you need a native coin, namely coin CET. Coin cet is used to pay the network or pay for every transaction on the coinex smart chain blockchain. You can buy CET coins at“Coinex Exhange”.

 

3. Smart Contract

You can use open source smart contracts from openzepplin or from other sources, in this article we use smart contracts from openzepplin. There are several that you need to replace, namely “name token”, “symbol token” and “supply token”.

# Smart Contract Standart CRC20

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.4;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";

contract AlifTokenBURN2 is ERC20 {
constructor() ERC20("Alif Token BURN2", "ALB") {
_mint(msg.sender, 1000000 * 10 ** decimals());
}
}

# Burnable Feature

import "@openzeppelin/contracts/token/ERC20/extensions/ERC20Burnable.sol";

ERC20Burnable

# (Standart CRC20 dan Burnable Feature) , this smart contract that you need to enter into remixethereumIDE.

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.4;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/token/ERC20/extensions/ERC20Burnable.sol";

contract AlifTokenBURN2 is ERC20, ERC20Burnable {
constructor() ERC20("Alif Token BURN2", "ALB") {
_mint(msg.sender, 1000000 * 10 ** decimals());
}
}
4. Deploy Smart Contract

To deploy smart contracts you can use truffle, hardhat and remix ide, but in this article I will use RemixEthereumIDE.

# Visit remix.ethereum.org, create a new file and paste the smart contract

# Select compiler version 0.8.4 and click “Enable Optimization“, wait 3-6 minutes (process complie smart contract)

 

# Click the ethereum icon, select “Injected Web3” and select a smart contract, click “Deploy” and “Confirm” your wallet

# Process deploy completed

 

5. Testing Burning Token

to burn, you can use remixethereumIDE or use block explorer. in this article I will use remixethereumIDE.

# Look in the “Deployed Contracts” section you will see your smart contract, to burn, click on the “BURN” menu, enter the number of tokens you want to burn, because this token uses decimal 18, it is necessary to add 18 zeros (zero) . if you have entered the correct number of tokens, please click the “Transact” button and confirm the wallet.

# The token supply will be automatically reduced after the burning process is fully confirmed by the blockchain. An example of a token that we created is 1,000,000, and we burn 25,000 tokens, after the burn process, the supply automatically updates (decreases)


Alif Fahmi

hi , I'm Alif, I'm a blockchain & cryptocurrency lover, I love writing & learning, my job is web developer & crypto trader