How to bypass image captcha using python selenium automation.

1. Register on fast captcha with your email id, mobile number and password of your choice.

2. Activate your account by entering OTP received on email and mobile number.

3. Generate API Secret Key.

4. Call Fast Captcha service to solve recaptcha.

    import requests
    url = "https://thedataextractors.com/fast-captcha/api/solve/image"
    files={ 'file' : open('imageFile.jpg', 'rb') }
    headers = {
      'apiSecretKey': 'api-secret-key'
    }
    response = requests.request("POST", url, headers=headers, data={}, files=files)
    print(response.text)

5. Inject obtained recaptcha token or image captcha solution into automated web page.

    solution = response.solution;
    //enter it in text area
    captchaSolutionElement = chromeDriver.find_element(By.ID, "captchaText");
    captchaSolutionElement.send_keys(solution);

6. Submit the page and done.