I am trying to verify a smart contract in Ropsten automatically with Python but Cloudflare is blocking me (I get a 403 asking me to complete a Captcha). Is there a way to bypass this?
url = 'https://api-ropsten.etherscan.io/api'
data = {
'apikey': ETHERSCAN_API_KEY,
'module': 'contract',
'action': 'verifysourcecode',
'contractaddress': address,
'sourceCode': content,
'contractname': 'MyToken',
'compilerversion': 'v0.8.4+commit.c7e474f2',
'optimizationUsed': '1',
'evmversion': '',
'licenseType': '3',
}
headers = {'Content-Type': 'application/x-www-form-urlencoded;charset=utf-8'}
result = requests.post(url, data=data, headers=headers)