Deploy using Remix IDE

Remix IDE is an online no-setup platform maintained by the Ethereum Foundation with a GUI for developing smart contracts. You can check the Remix IDE docs to learn more about deployment.

Before you Begin

Learn more about claiming test tokens from here.

Deploying your Contract

Let's write a simple one-of-one NFT contract based on OpenZeppelin's open-source ERC-721 implementation to tokenize our CBO's prized Rolex watch on Plume Testnet for instance.

1

Create a file on Remix IDE

Go to Remix IDE and create a new file. We are using a sample file named RolexYachtMaster40.sol.

2

Add your code to the file

To demonstrate we are using this sample smart contract code, you can add your own code.

RolexYachtMaster40.sol
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.25;

import {Ownable} from "@openzeppelin/contracts/access/Ownable.sol";
import {ERC721} from "@openzeppelin/contracts/token/ERC721/ERC721.sol";

contract RolexYachtMaster40 is Ownable, ERC721 {
    error NFTAlreadyMinted();
    bool private _minted;

    constructor() Ownable(msg.sender) ERC721("Rolex Yacht-Master 40", "") {}

    function mint() public onlyOwner returns (uint256) {
        if (_minted) {
            revert NFTAlreadyMinted();
        }
        _safeMint(owner(), 0);
        _minted = true;
        return 0;
    }
}
3

Compile the Contract

Go to the Solidity Compiler tab on the IDE, choose the compiler version if you wish to and click on the blue Compile <file_name> button.

4

Deploying the contract using MetaMask

Make sure you are on Plume Testnet network in MetaMask.

Select Injected Provider - MetaMask in the Environment dropdown and select the account which has sufficient ETH to pay to gas fees. As for our sample contract, no need to change other fields and click on Deploy button

There will be a pop-up on MetaMask to confirm the transaction (asking for gas fees), on confirming the contract will be deployed.

5

Contract Deployed

Check the console for the transaction info and deployed contract on the left-side panel.

Last updated