Skip to content

Verifying Contracts

Below are the steps to verify a contract you deployed through JokeRace.

Determine the contract's version

First, run the below command in your terminal to download and install Foundry.

curl -L https://foundry.paradigm.xyz ​| bash && foundryup

Then run this command with the contract address and the RPC url for the chain that the contract is on (you can find a public RPC url to use on our Github here if you don't have one already) to return the version of that contract.

cast call <CONTRACT ADDRESS> "version()(string)" --rpc-url "<RPC_URL>"

Copy the flattened file of that contract version

For Contest contracts, look for the flattened filed in the respective version's folder here.

For RewardsModule contracts, look for the flattened filed in the respective version's folder here.

Verify the contract

In whatever block explorer you're using, input this information into where it enables you to verify (usually the Code tab) and you should be good to go:

  • Compiler Type: Single file
  • Compiler Version: v0.8.19
  • License Type: GNU Affero General Public License (GNU AGPLv3)
  • Optimization: Yes
  • Solidity Contract Code: Paste the copied flattened file from the previous step