All Downloads are FREE. Search and download functionalities are using the official Maven repository.

examples.GeeTestOptionsExample Maven / Gradle / Ivy

package examples;

import com.twocaptcha.TwoCaptcha;
import com.twocaptcha.captcha.GeeTest;

public class GeeTestOptionsExample {

    public static void main(String[] args) {
        TwoCaptcha solver = new TwoCaptcha("YOUR_API_KEY");

        GeeTest captcha = new GeeTest();
        captcha.setGt("f2ae6cadcf7886856696502e1d55e00c");
        captcha.setApiServer("api-na.geetest.com");
        captcha.setChallenge("12345678abc90123d45678ef90123a456b");
        captcha.setUrl("https://mysite.com/captcha.html");
        captcha.setProxy("HTTPS", "login:password@IP_address:PORT");

        try {
            solver.solve(captcha);
            System.out.println("Captcha solved: " + captcha.getCode());
        } catch (Exception e) {
            System.out.println("Error occurred: " + e.getMessage());
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy