enzonix / captcha
Enzonix captcha verification client
Installs: 2
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 0
Forks: 0
Open Issues: 0
pkg:composer/enzonix/captcha
Requires
- php: ^8.0
- guzzlehttp/guzzle: ^7.0
Requires (Dev)
- phpunit/phpunit: ^10.0
README
A small, lightweight PHP client for verifying captcha tokens against Enzonix's verification endpoint (https://verify.enzonix.com).
Installation
Require the package with Composer:
composer require enzonix/captcha
Usage
use Enzonix\Captcha\CaptchaClient; $client = new CaptchaClient(getenv('ENZONIX_SECRET')); $response = $client->verify($_POST['captcha_token'] ?? ''); if ($response->isSuccess()) { // accepted $score = $response->getScore(); } else { $errors = $response->getErrors(); }