Deploying smart contract on METABENZnet

Steps on deploying a smart contract on METABENZnet through Remix.

METABENZ Blockchain is an EVM compatible network, every tool for Ethereum can be used for the METABENZ Blockchain network too.

Remix is a powerful, open source tool that helps you write Solidity contracts straight from the browser. Written in JavaScript, Remix supports both usage in the browser and locally.

Remix also supports testing, debugging and deploying of smart contracts and much more.

Pre-requisites:

Since we interact with remix using Metamask, you need to change the network to METABENZ Blockchain network by adding a custom RPC. Please follow the steps in this tutorial to do that.

You need to have a small balance of METABENZ on the METABENZnet wallet you are using which will be used as Gas for the transactions.

Step 1:

Navigate to remix.ethereum.org and you should select the environment as “Solidity”.

Step 2:

Next step is creating/importing the contract. You can write the contract using “Create” or you can import the contract from various options like Github etc.

In the below example I will be creating a new sample contract.

Step 3:

We will now compile the contract created using the Solidity compiler which you can find on the left hand side. You can choose the version of compiler you want using the drop down.

Step 4:

Once compiled you should see a tick mark next to the compiler and we are good to deploy the contract into METABENZnet. Please click on “Deploy and run transaction” below the compiler option. Select “Injected Web3” from the drop down of Environment and adjust the gas value and click on “Deploy”. You should confirm the transaction on your Metamask and wait for the transaction to be confirmed on-chain.

Step 5:

Wait for a few seconds and you can see that your smart contract is deployed and you should be able to interact with it.

Last updated