Warning
DEPRECATED / УСТАРЕЛО
This repository is no longer maintained. Please use our new, official .NET / C# SDK repository:
👉 CapMonsterCloud/capmonster-dotnet-captcha-solver
Official C# client library for capmonster.cloud captcha recognition service
Via Package Manager:
Install-Package Zennolab.CapMonsterCloud.Client
Via .NET CLI
dotnet add package Zennolab.CapMonsterCloud.Client
var clientOptions = new ClientOptions
{
ClientKey = "<your capmonster.cloud API key>"
};
var cmCloudClient = CapMonsterCloudClientFactory.Create(clientOptions);
// solve RecaptchaV2 (without proxy)
var recaptchaV2Request = new RecaptchaV2Request
{
WebsiteUrl = "https://lessons.zennolab.com/captchas/recaptcha/v2_simple.php?level=high",
WebsiteKey = "6Lcg7CMUAAAAANphynKgn9YAgA4tQ2KI_iqRyTwd",
};
var recaptchaV2Result = await cmCloudClient.SolveAsync(recaptchaV2Request);
// solve RecaptchaV2 (with proxy)
var recaptchaV2ProxyRequest = new RecaptchaV2Request
{
WebsiteUrl = "https://lessons.zennolab.com/captchas/recaptcha/v2_simple.php?level=high",
WebsiteKey = "6Lcg7CMUAAAAANphynKgn9YAgA4tQ2KI_iqRyTwd",
Proxy = new ProxyContainer("203.0.113.45", 8080, ProxyType.Http, "login", "password")
};
var recaptchaV2ProxyResult = await cmCloudClient.SolveAsync(recaptchaV2ProxyRequest);
// solve a CustomTask (anti-bot/WAF systems such as Tspd, Castle, DataDome, etc.)
var tspdRequest = new TspdCustomTaskRequest(
tspdCookie: "TS386a400d029=08...010245; TS386a400d029=08...01a06e; TS386a400d078=08...dbb3b0c; TSd2153684027=08...1944",
htmlPageBase64: "PCFET0NU...k+PC9odG1sPg==")
{
WebsiteUrl = "https://yourwebsite.com/page-with-tspd",
Proxy = new ProxyContainer("203.0.113.45", 8080, ProxyType.Http, "login", "password")
};
var tspdResult = await cmCloudClient.SolveAsync(tspdRequest);
Supported captcha recognition requests:
Classic captcha tasks:
- AmazonWafRequest
- BinanceTaskRequest
- FunCaptchaRequest
- GeeTestRequest
- ImageToTextRequest
- MTCaptchaTaskRequest
- ProsopoTaskRequest
- RecaptchaV2Request
- RecaptchaV2EnterpriseRequest
- RecaptchaV3ProxylessRequest
- TurnstileRequest - Cloudflare Turnstile
- TurnstileRequest - Cloudflare Challenge
- TurnstileRequest - Cloudflare Waiting Room
- YidunTaskRequest
Custom tasks (anti-bot / WAF / custom challenge systems):
- AlibabaCustomTaskRequest
- AltchaCustomTaskRequest
- BasiliskCustomTaskRequest
- DataDomeCustomTaskRequest
- FriendlyCustomTaskRequest
- HuntCustomTaskRequest
- ImpervaCustomTaskRequest
- TenDiCustomTaskRequest
- TspdCustomTaskRequest
Complex image tasks (grid / dynamic image selection tasks):