Skip to content

Latest commit

 

History

History
24 lines (18 loc) · 726 Bytes

README.md

File metadata and controls

24 lines (18 loc) · 726 Bytes

Easy to use, tested reCaptcha library. Allows to check send data against reCaptcha service. There are other libs to do this, but my returns errors n RecaptchaResponse object so You know what went wrong ;).

Usage of lib

Build Status

recaptcha := gorecaptcha.NewRecaptcha("recaptcha private key")

captchaResponse, err := recaptcha.Verify(
	ip,
	challenge_from_request_form,
	response_from_request_form,
)

if err != nil {
	// error (http request error for example)
	fmt.Println(err)
}

fmt.Println(captchaResponse.Status) // true or false
fmt.Println(captchaResponse.Err) // actual reason if false