no-phpunit/capmonstercloud.client 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

no-phpunit/capmonstercloud.client

Composer 安装命令:

composer require no-phpunit/capmonstercloud.client

包简介

API client for capmonster.cloud

README 文档

README

Usage

    include './client/Client.php';
    include './client/src/captcha/ImageToText.php';
    include './client/src/captcha/RecaptchaV2.php';
    include './client/src/captcha/HCaptcha.php';
    
    $client = new Client("your_client_key");

    //solve image captcha
    $body = "base64_captcha_image";
    $imageRequest = new ImageToTextRequest($body);
    $imageResult = $client->solve($imageRequest);
    
    //solve Recaptcha 2 (without proxy)
    $websiteURL = "https://lessons.zennolab.com/captchas/recaptcha/v2_simple.php?level=high";
    $websiteKey = "6Lcg7CMUAAAAANphynKgn9YAgA4tQ2KI_iqRyTwd";
    $recaptchaV2Request = new RecaptchaV2Request($websiteURL, $websiteKey);
    $recaptchaV2Result = $client->solve($recaptchaV2Request);
    
    // solve HCaptcha (without proxy)
    $websiteUrl = "https://lessons.zennolab.com/captchas/hcaptcha/?level=easy";
    $websiteKey = "472fc7af-86a4-4382-9a49-ca9090474471";
    $hcatpchaRequest = new HCaptchaRequest($websiteURL, $websiteKey);
    $hcaptchaResult = $client->solve($hcatpchaRequest);

Response format

The result of the solve method always contains two fields: bool result, a request success indicator, and a mixed message field containing a text description of the error or an object of a successful response from the server.

Supported captchas

  • FunCaptchaTask
  • FunCaptchaTaskProxyless
  • GeeTestTask
  • GeeTestTaskProxyless
  • HCaptchaTask
  • HCaptchaTaskProxyless
  • ImageToTextTask
  • RecaptchaV2Task
  • RecaptchaV2TaskProxyless
  • RecaptchaV3TaskProxyless
  • RecaptchaV2EnterpriseTask
  • RecaptchaV2EnterpriseTaskProxyless
  • TurnstileTask
  • TurnstileTaskProxyless
  • ComplexImageRecaptcha
  • ComplexImageHCaptcha
  • ComplexImageFuncaptcha

统计信息

  • 总下载量: 2
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 15
  • 开发语言: PHP

其他信息

  • 授权协议: Unknown
  • 更新时间: 2023-07-12