Skip to content

Commit

Permalink
Add debugging tip
Browse files Browse the repository at this point in the history
  • Loading branch information
e271828- authored Mar 24, 2022
1 parent ec5215e commit ce1ed44
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
![CI](https://github.com/hCaptcha/hcaptcha-android-sdk/workflows/Android%20SDK%20CI/badge.svg)
[![Release](https://jitpack.io/v/hCaptcha/hcaptcha-android-sdk.svg)](https://jitpack.io/#hCaptcha/hcaptcha-android-sdk)

###### [Installation](#installation) | [Basic usage](#basic-usage) | [Example](#display-a-hcaptcha-challenge) | [Customization](#config-params) | [Error handling](#error-handling) | [Testing](#testing) | [Publishing](#publishing)
###### [Installation](#installation) | [Basic usage](#basic-usage) | [Example](#display-a-hcaptcha-challenge) | [Customization](#config-params) | [Error handling](#error-handling) | [Debugging](#debugging-tips) | [Testing](#testing) | [Publishing](#publishing)

This SDK provides a wrapper for [hCaptcha](https://www.hcaptcha.com), and is a drop-in replacement for the SafetyNet reCAPTCHA API. You will need to configure a `site key` and a `secret key` from your hCaptcha account in order to use it.

Expand Down Expand Up @@ -110,6 +110,11 @@ In some scenarios in which the human verification process cannot be completed, y
* ERROR (29): general failure


#### Debugging Tips

Useful error messages are often rendered on the hCaptcha checkbox. For example, if the sitekey within your config is invalid, you'll see a message there. To quickly debug your local instance using this tool, set `.size(HCaptchaSize.NORMAL)`


#### Verify the completed challenge

After retrieving a `token`, you should pass it to your backend in order to verify the validity of the token by doing a [server side check](https://docs.hcaptcha.com/#server) using the hCaptcha secret linked to your sitekey.
Expand Down

0 comments on commit ce1ed44

Please sign in to comment.