Ensuring you’re using the latest version of Foundry, via
foundryupDeploy and Verify
Verify an Existing Contract
Custom Chains
Most chains with an Etherscan explorer are supported using the--chain flag.
For (very) new chains that aren’t natively supported by Foundry, you can use a custom --verifier-url
Append the Etherscan V2 base path and the new chainId, in this example for Stable Testnet(2201).
This open source integration was shipped by @iainnash and the Foundry team