I tried to verify my contract that has been deployed on Polygon Amoy. But all it does is verifies another contract on polygon mainnet.
Submitted contract for verification:
Response: `OK`
GUID: `minfutd9rrduuhp4qdj5stehw4d9k5vmcpu1tmnn6azjyexifv`
URL: https://www.oklink.com/address/0x1935aba6ea495a3dd1d84f8dd6cab96ca005e751
It returns this on the terminal which takes me to a different explorer and on the mainnet chain.
This is how my foundry.toml looks like
[profile.default]
src = "src"
out = "out"
libs = ["lib"]
solc_version = "0.8.25"
optimizer = true
optimizer_runs = 200
remappings = [
"@chainlink/contracts/=lib/chainlink-brownie-contracts/contracts/",
"@openzeppelin/contracts/=lib/openzeppelin-contracts/contracts",
]
fs_permissions = [{ access = "read", path = "./" }]
[etherscan]
polygon-amoy = { key = "${AMOY_API_KEY}", url = "https://api-amoy.polygonscan.com/api" }
# See more config options https://github.com/foundry-rs/foundry/blob/master/crates/config/README.md#all-options
This is how my Makefile looks like
-include .env
.PHONY: deploy
deploy :; @forge script script/DeployDTsla.s.sol --private-key ${PRIVATE_KEY} --rpc-url ${POLYGON_RPC_URL} --broadcast
verify :; @forge verify-contract ${CONTRACT_ADDRESS} src/dTsla.sol:dTsla --chain polygon-amoy
I would appreciate any help