ERC721 Token
ERC-721 is an open standard that describes how to build Non-Fungible tokens on EVM (Ethereum Virtual Machine) compatible blockchains; it is a standard interface for Non-Fungible tokens; it has a set of rules which make it easy to work with NFTs. NFTs are not only of ERC-721 type; they can also be ERC-1155tokens
Prerequisite
- Connect your Web3 wallet to ONUS Chain mainnet or testnet
- Have some ONUS in your wallet to use as transaction fees
Deploying a new ERC721 token can be done by using Remix and ERC721 contracts from Open Zeppelin open source.
Step 1: Connect to ONUS Chain
Step 2: Code your token in Remix
// SPDX-License-Identifier: MIT
pragma solidity 0.8.0;
import "https://github.com/0xcert/ethereum-erc721/src/contracts/tokens/nf-token-metadata.sol";
import "https://github.com/0xcert/ethereum-erc721/src/contracts/ownership/ownable.sol";
contract newNFT is NFTokenMetadata, Ownable {
constructor() {
//define nft name of choice and symbol
nftName = "SectionTest NFT";
nftSymbol = "STNF";
}
function mint(address _to, uint256 _tokenId, string calldata _uri) external onlyOwner {
super._mint(_to, _tokenId);
super._setTokenUri(_tokenId, _uri);
}
}
Step 3: Compile contract
Once that is done, we can click on Compile. If we get no error, we should see a green check button on the compiler button.

compile contract
Step 4: Deploy the contract
Now that it is compiled, we are ready to deploy the contract to the blockchain and actually create our tokens.
Before we start, make sure your Web3 wallet is connected to ONUS Chain.
Click on the [Deploy] button

In a few seconds, you should see the confirmation message in the bottom part of your Remix window.

Indicating your contract, and your token is now written onto the Blockchain and is ready to go!
Last modified 1yr ago