Skip to content

PrivateCaptcha/private-captcha-java

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Private Captcha Java Client

CI

Maven Central

Official Java client for the Private Captcha API.

Please check the official documentation for the in-depth and up-to-date information.

Quick Start

  • Install private-captcha-java using Maven (in pom.xml) or Gradle (in build.gradle)
  • Instantiate PrivateCaptchaClient and call verify() method
    import com.privatecaptcha.*;
    
    PrivateCaptchaClient client = new PrivateCaptchaClient(
        new PrivateCaptchaConfiguration("pc_your_api_key")
    );
    
    try {
        VerifyOutput output = client.verify(new VerifyInput(solution));
    
        if (output.ok()) {
            System.out.println("Verification successful!");
        } else {
            System.out.println("Verification failed: " + output.getErrorMessage());
        }
    } catch (PrivateCaptchaHttpException e) {
        System.err.println("HTTP error: " + e.getStatusCode());
    } catch (VerificationFailedException e) {
        System.err.println("Verification failed after " + e.getAttempts() + " attempts");
    }

License

This project is licensed under the MIT License - see the LICENSE file for details.

Support

For issues with this Java client, please open an issue on GitHub.

For Private Captcha service questions, visit privatecaptcha.com.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors